From c60bf843815004f3824b11d5ba7faea47a7e9f12 Mon Sep 17 00:00:00 2001 From: Christian Oliff Date: Wed, 17 Apr 2024 00:11:21 +0900 Subject: [PATCH] Release v1.12.1 (#403) --- app-components/preview/app-components.js | 85556 +-------------------- docs/assets/js/app-components.js | 85556 +-------------------- fonts/css.hbs | 2 +- hugo.yml | 2 +- package-lock.json | 4 +- package.json | 2 +- 6 files changed, 11 insertions(+), 171111 deletions(-) diff --git a/app-components/preview/app-components.js b/app-components/preview/app-components.js index 861443d..c0aa4d9 100644 --- a/app-components/preview/app-components.js +++ b/app-components/preview/app-components.js @@ -1,85553 +1,3 @@ -/******/ (function(modules) { // webpackBootstrap -/******/ // install a JSONP callback for chunk loading -/******/ function webpackJsonpCallback(data) { -/******/ var chunkIds = data[0]; -/******/ var moreModules = data[1]; -/******/ var executeModules = data[2]; -/******/ -/******/ // add "moreModules" to the modules object, -/******/ // then flag all "chunkIds" as loaded and fire callback -/******/ var moduleId, chunkId, i = 0, resolves = []; -/******/ for(;i < chunkIds.length; i++) { -/******/ chunkId = chunkIds[i]; -/******/ if(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) { -/******/ resolves.push(installedChunks[chunkId][0]); -/******/ } -/******/ installedChunks[chunkId] = 0; -/******/ } -/******/ for(moduleId in moreModules) { -/******/ if(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) { -/******/ modules[moduleId] = moreModules[moduleId]; -/******/ } -/******/ } -/******/ if(parentJsonpFunction) parentJsonpFunction(data); -/******/ -/******/ while(resolves.length) { -/******/ resolves.shift()(); -/******/ } -/******/ -/******/ // add entry modules from loaded chunk to deferred list -/******/ deferredModules.push.apply(deferredModules, executeModules || []); -/******/ -/******/ // run deferred modules when all chunks ready -/******/ return checkDeferredModules(); -/******/ }; -/******/ function checkDeferredModules() { -/******/ var result; -/******/ for(var i = 0; i < deferredModules.length; i++) { -/******/ var deferredModule = deferredModules[i]; -/******/ var fulfilled = true; -/******/ for(var j = 1; j < deferredModule.length; j++) { -/******/ var depId = deferredModule[j]; -/******/ if(installedChunks[depId] !== 0) fulfilled = false; -/******/ } -/******/ if(fulfilled) { -/******/ deferredModules.splice(i--, 1); -/******/ result = __webpack_require__(__webpack_require__.s = deferredModule[0]); -/******/ } -/******/ } -/******/ -/******/ return result; -/******/ } -/******/ -/******/ // The module cache -/******/ var installedModules = {}; -/******/ -/******/ // object to store loaded and loading chunks -/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched -/******/ // Promise = chunk loading, 0 = chunk loaded -/******/ var installedChunks = { -/******/ "runtime": 0 -/******/ }; -/******/ -/******/ var deferredModules = []; -/******/ -/******/ // The require function -/******/ function __webpack_require__(moduleId) { -/******/ -/******/ // Check if module is in cache -/******/ if(installedModules[moduleId]) { -/******/ return installedModules[moduleId].exports; -/******/ } -/******/ // Create a new module (and put it into the cache) -/******/ var module = installedModules[moduleId] = { -/******/ i: moduleId, -/******/ l: false, -/******/ exports: {} -/******/ }; -/******/ -/******/ // Execute the module function -/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__); -/******/ -/******/ // Flag the module as loaded -/******/ module.l = true; -/******/ -/******/ // Return the exports of the module -/******/ return module.exports; -/******/ } -/******/ -/******/ -/******/ // expose the modules object (__webpack_modules__) -/******/ __webpack_require__.m = modules; -/******/ -/******/ // expose the module cache -/******/ __webpack_require__.c = installedModules; -/******/ -/******/ // define getter function for harmony exports -/******/ __webpack_require__.d = function(exports, name, getter) { -/******/ if(!__webpack_require__.o(exports, name)) { -/******/ Object.defineProperty(exports, name, { enumerable: true, get: getter }); -/******/ } -/******/ }; -/******/ -/******/ // define __esModule on exports -/******/ __webpack_require__.r = function(exports) { -/******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) { -/******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' }); -/******/ } -/******/ Object.defineProperty(exports, '__esModule', { value: true }); -/******/ }; -/******/ -/******/ // create a fake namespace object -/******/ // mode & 1: value is a module id, require it -/******/ // mode & 2: merge all properties of value into the ns -/******/ // mode & 4: return value when already ns object -/******/ // mode & 8|1: behave like require -/******/ __webpack_require__.t = function(value, mode) { -/******/ if(mode & 1) value = __webpack_require__(value); -/******/ if(mode & 8) return value; -/******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value; -/******/ var ns = Object.create(null); -/******/ __webpack_require__.r(ns); -/******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value }); -/******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key)); -/******/ return ns; -/******/ }; -/******/ -/******/ // getDefaultExport function for compatibility with non-harmony modules -/******/ __webpack_require__.n = function(module) { -/******/ var getter = module && module.__esModule ? -/******/ function getDefault() { return module['default']; } : -/******/ function getModuleExports() { return module; }; -/******/ __webpack_require__.d(getter, 'a', getter); -/******/ return getter; -/******/ }; -/******/ -/******/ // Object.prototype.hasOwnProperty.call -/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); }; -/******/ -/******/ // __webpack_public_path__ -/******/ __webpack_require__.p = ""; -/******/ -/******/ var jsonpArray = window["webpackJsonp"] = window["webpackJsonp"] || []; -/******/ var oldJsonpFunction = jsonpArray.push.bind(jsonpArray); -/******/ jsonpArray.push = webpackJsonpCallback; -/******/ jsonpArray = jsonpArray.slice(); -/******/ for(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]); -/******/ var parentJsonpFunction = oldJsonpFunction; -/******/ -/******/ -/******/ // run deferred modules from other chunks -/******/ checkDeferredModules(); -/******/ }) -/************************************************************************/ -/******/ ([]); -(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["polyfills"],{ - -/***/ 1: -/*!********************************!*\ - !*** multi ./src/polyfills.ts ***! - \********************************/ -/*! no static exports found */ -/***/ (function(module, exports, __webpack_require__) { - -module.exports = __webpack_require__(/*! C:\devel\checkout\modus-icons\app-components\src\polyfills.ts */"hN/g"); - - -/***/ }), - -/***/ "KJ4T": -/*!***********************************************************************************!*\ - !*** ./node_modules/document-register-element/build/document-register-element.js ***! - \***********************************************************************************/ -/*! no static exports found */ -/***/ (function(module, exports) { - -/*! (C) Andrea Giammarchi - @WebReflection - ISC Style License */ -!function(e,t){"use strict";function n(){var e=A.splice(0,A.length);for(et=0;e.length;)e.shift().call(null,e.shift())}function r(e,t){for(var n=0,r=e.length;n1)&&H(this)}}}),_e(l,j,{value:function(e){-1>0,_="__"+R+U,k="addEventListener",x="attached",q="Callback",B="detached",Z="extends",j="attributeChanged"+q,G=x+q,z="connected"+q,K="disconnected"+q,X="created"+q,$=B+q,Q="ADDITION",W="REMOVAL",Y="DOMAttrModified",J="DOMContentLoaded",ee="DOMSubtreeModified",te="<",ne="=",re=/^[A-Z][._A-Z0-9]*-[-._A-Z0-9]*$/,oe=["ANNOTATION-XML","COLOR-PROFILE","FONT-FACE","FONT-FACE-SRC","FONT-FACE-URI","FONT-FACE-FORMAT","FONT-FACE-NAME","MISSING-GLYPH"],le=[],ae=[],ie="",ue=y.documentElement,ce=le.indexOf||function(e){for(var t=this.length;t--&&this[t]!==e;);return t},se=C.prototype,me=se.hasOwnProperty,fe=se.isPrototypeOf,de=C.defineProperty,pe=[],he=C.getOwnPropertyDescriptor,Te=C.getOwnPropertyNames,Le=C.getPrototypeOf,Me=C.setPrototypeOf,Ee=!!C.__proto__,ve=!1,He="__dreCEv1",ge=e.customElements,be=!/^force/.test(t.type)&&!!(ge&&ge.define&&ge.get&&ge.whenDefined),ye=C.create||C,Ce=e.Map||function(){var e,t=[],n=[];return{get:function(e){return n[ce.call(t,e)]},set:function(r,o){e=ce.call(t,r),e<0?n[t.push(r)-1]=o:n[e]=o}}},we=e.Promise||function(e){function t(e){for(r=!0;n.length;)n.shift()(e)}var n=[],r=!1,o={"catch":function(){return o},then:function(e){return n.push(e),r&&setTimeout(t,1),o}};return e(t),o},Ae=!1,Oe=ye(null),Ne=ye(null),De=new Ce,Ie=function(e){return e.toLowerCase()},Fe=C.create||function ct(e){return e?(ct.prototype=e,new ct):this},Se=Me||(Ee?function(e,t){return e.__proto__=t,e}:Te&&he?function(){function e(e,t){for(var n,r=Te(t),o=0,l=r.length;o
",new Ve(function(e,t){if(e[0]&&"childList"==e[0].type&&!e[0].removedNodes[0].childNodes.length){P=he(Re,"innerHTML");var n=P&&P.set;n&&de(Re,"innerHTML",{set:function(e){for(;this.lastChild;)this.removeChild(this.lastChild);n.call(this,e)}})}t.disconnect(),P=null}).observe(P,{childList:!0,subtree:!0}),P.innerHTML=""),tt||(Me||Ee?(S=function(e,t){fe.call(t,e)||d(e,t)},V=d):(S=function(e,t){e[_]||(e[_]=C(!0),d(e,t))},V=S),Ue?(ot=!1,function(){var e=he(Re,k),t=e.value,n=function(e){var t=new CustomEvent(Y,{bubbles:!0});t.attrName=e,t.prevValue=Ge.call(this,e),t.newValue=null,t[W]=t.attrChange=2,Ke.call(this,e),je.call(this,t)},r=function(e,t){var n=ze.call(this,e),r=n&&Ge.call(this,e),o=new CustomEvent(Y,{bubbles:!0});Xe.call(this,e,t),o.attrName=e,o.prevValue=n?r:null,o.newValue=t,n?o.MODIFICATION=o.attrChange=1:o[Q]=o.attrChange=0,je.call(this,o)},o=function(e){var t,n=e.currentTarget,r=n[_],o=e.propertyName;r.hasOwnProperty(o)&&(r=r[o],t=new CustomEvent(Y,{bubbles:!0}),t.attrName=r.name,t.prevValue=r.value||null,t.newValue=r.value=n[o]||null,null==t.prevValue?t[Q]=t.attrChange=0:t.MODIFICATION=t.attrChange=1,je.call(n,t))};e.value=function(e,l,a){e===Y&&this[j]&&this.setAttribute!==r&&(this[_]={className:{name:"class",value:this.className}},this.setAttribute=r,this.removeAttribute=n,t.call(this,"propertychange",o)),t.call(this,e,l,a)},de(Re,k,e)}()):Ve||(ue[k](Y,Je),ue.setAttribute(_,1),ue.removeAttribute(_),ot&&(O=function(e){var t,n,r,o=this;if(o===e.target){t=o[_],o[_]=n=D(o);for(r in n){if(!(r in t))return N(0,o,r,t[r],n[r],Q);if(n[r]!==t[r])return N(1,o,r,t[r],n[r],"MODIFICATION")}for(r in t)if(!(r in n))return N(2,o,r,t[r],n[r],W)}},N=function(e,t,n,r,o,l){var a={attrChange:e,currentTarget:t,attrName:n,prevValue:r,newValue:o};a[l]=e,u(a)},D=function(e){for(var t,n,r={},o=e.attributes,l=0,a=o.length;l$");if(n[Z]="a",t.prototype=Fe(Pe.prototype),t.prototype.constructor=t,e.customElements.define(r,t,n),!o.test(y.createElement("a",{is:r}).outerHTML)||!o.test((new t).outerHTML))throw n}(function st(){return Reflect.construct(Pe,[],st)},{},"document-register-element-a"+U)}catch(it){b()}if(!t.noBuiltIn)try{if($e.call(y,"a","a").outerHTML.indexOf("is")<0)throw{}}catch(ut){Ie=function(e){return{is:e.toLowerCase()}}}}(window); - - -/***/ }), - -/***/ "hN/g": -/*!**************************!*\ - !*** ./src/polyfills.ts ***! - \**************************/ -/*! no exports provided */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony import */ var zone_js_dist_zone__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! zone.js/dist/zone */ "pDpN"); -/* harmony import */ var zone_js_dist_zone__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(zone_js_dist_zone__WEBPACK_IMPORTED_MODULE_0__); -/* harmony import */ var document_register_element__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! document-register-element */ "KJ4T"); -/* harmony import */ var document_register_element__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(document_register_element__WEBPACK_IMPORTED_MODULE_1__); -/* harmony import */ var _webcomponents_webcomponentsjs_custom_elements_es5_adapter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @webcomponents/webcomponentsjs/custom-elements-es5-adapter.js */ "vU8d"); -/* harmony import */ var _webcomponents_webcomponentsjs_custom_elements_es5_adapter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(_webcomponents_webcomponentsjs_custom_elements_es5_adapter_js__WEBPACK_IMPORTED_MODULE_2__); -/** - * This file includes polyfills needed by Angular and is loaded before the app. - * You can add your own extra polyfills to this file. - * - * This file is divided into 2 sections: - * 1. Browser polyfills. These are applied before loading ZoneJS and are sorted by browsers. - * 2. Application imports. Files imported after ZoneJS that should be loaded before your main - * file. - * - * The current setup is for so-called "evergreen" browsers; the last versions of browsers that - * automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera), - * Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile. - * - * Learn more in https://angular.io/guide/browser-support - */ -/*************************************************************************************************** - * BROWSER POLYFILLS - */ -/** - * IE11 requires the following for NgClass support on SVG elements - */ -// import 'classlist.js'; // Run `npm install --save classlist.js`. -/** - * Web Animations `@angular/platform-browser/animations` - * Only required if AnimationBuilder is used within the application and using IE/Edge or Safari. - * Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0). - */ -// import 'web-animations-js'; // Run `npm install --save web-animations-js`. -/** - * By default, zone.js will patch all possible macroTask and DomEvents - * user can disable parts of macroTask/DomEvents patch by setting following flags - * because those flags need to be set before `zone.js` being loaded, and webpack - * will put import in the top of bundle, so user need to create a separate file - * in this directory (for example: zone-flags.ts), and put the following flags - * into that file, and then add the following code before importing zone.js. - * import './zone-flags'; - * - * The flags allowed in zone-flags.ts are listed here. - * - * The following flags will work for all browsers. - * - * (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame - * (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick - * (window as any).__zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames - * - * in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js - * with the following flag, it will bypass `zone.js` patch for IE/Edge - * - * (window as any).__Zone_enable_cross_context_check = true; - * - */ -/*************************************************************************************************** - * Zone JS is required by default for Angular itself. - */ - // Included with Angular CLI. -/*************************************************************************************************** - * APPLICATION IMPORTS - */ - - - - -/***/ }), - -/***/ "pDpN": -/*!*****************************************************!*\ - !*** ./node_modules/zone.js/dist/zone-evergreen.js ***! - \*****************************************************/ -/*! no static exports found */ -/***/ (function(module, exports, __webpack_require__) { - -"use strict"; - -/** - * @license Angular v14.2.0-next.0 - * (c) 2010-2022 Google LLC. https://angular.io/ - * License: MIT - */ -/** - * @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 (global) { - const performance = global['performance']; - function mark(name) { - performance && performance['mark'] && performance['mark'](name); - } - function performanceMeasure(name, label) { - performance && performance['measure'] && performance['measure'](name, label); - } - mark('Zone'); - // Initialize before it's accessed below. - // __Zone_symbol_prefix global can be used to override the default zone - // symbol prefix with a custom one if needed. - const symbolPrefix = global['__Zone_symbol_prefix'] || '__zone_symbol__'; - function __symbol__(name) { - return symbolPrefix + name; - } - const checkDuplicate = global[__symbol__('forceDuplicateZoneCheck')] === true; - if (global['Zone']) { - // if global['Zone'] already exists (maybe zone.js was already loaded or - // some other lib also registered a global object named Zone), we may need - // to throw an error, but sometimes user may not want this error. - // For example, - // we have two web pages, page1 includes zone.js, page2 doesn't. - // and the 1st time user load page1 and page2, everything work fine, - // but when user load page2 again, error occurs because global['Zone'] already exists. - // so we add a flag to let user choose whether to throw this error or not. - // By default, if existing Zone is from zone.js, we will not throw the error. - if (checkDuplicate || typeof global['Zone'].__symbol__ !== 'function') { - throw new Error('Zone already loaded.'); - } - else { - return global['Zone']; - } - } - class Zone { - constructor(parent, zoneSpec) { - this._parent = parent; - this._name = zoneSpec ? zoneSpec.name || 'unnamed' : ''; - this._properties = zoneSpec && zoneSpec.properties || {}; - this._zoneDelegate = - new _ZoneDelegate(this, this._parent && this._parent._zoneDelegate, zoneSpec); - } - static assertZonePatched() { - if (global['Promise'] !== patches['ZoneAwarePromise']) { - throw new Error('Zone.js has detected that ZoneAwarePromise `(window|global).Promise` ' + - 'has been overwritten.\n' + - 'Most likely cause is that a Promise polyfill has been loaded ' + - 'after Zone.js (Polyfilling Promise api is not necessary when zone.js is loaded. ' + - 'If you must load one, do so before loading zone.js.)'); - } - } - static get root() { - let zone = Zone.current; - while (zone.parent) { - zone = zone.parent; - } - return zone; - } - static get current() { - return _currentZoneFrame.zone; - } - static get currentTask() { - return _currentTask; - } - // tslint:disable-next-line:require-internal-with-underscore - static __load_patch(name, fn, ignoreDuplicate = false) { - if (patches.hasOwnProperty(name)) { - // `checkDuplicate` option is defined from global variable - // so it works for all modules. - // `ignoreDuplicate` can work for the specified module - if (!ignoreDuplicate && checkDuplicate) { - throw Error('Already loaded patch: ' + name); - } - } - else if (!global['__Zone_disable_' + name]) { - const perfName = 'Zone:' + name; - mark(perfName); - patches[name] = fn(global, Zone, _api); - performanceMeasure(perfName, perfName); - } - } - get parent() { - return this._parent; - } - get name() { - return this._name; - } - get(key) { - const zone = this.getZoneWith(key); - if (zone) - return zone._properties[key]; - } - getZoneWith(key) { - let current = this; - while (current) { - if (current._properties.hasOwnProperty(key)) { - return current; - } - current = current._parent; - } - return null; - } - fork(zoneSpec) { - if (!zoneSpec) - throw new Error('ZoneSpec required!'); - return this._zoneDelegate.fork(this, zoneSpec); - } - wrap(callback, source) { - if (typeof callback !== 'function') { - throw new Error('Expecting function got: ' + callback); - } - const _callback = this._zoneDelegate.intercept(this, callback, source); - const zone = this; - return function () { - return zone.runGuarded(_callback, this, arguments, source); - }; - } - run(callback, applyThis, applyArgs, source) { - _currentZoneFrame = { parent: _currentZoneFrame, zone: this }; - try { - return this._zoneDelegate.invoke(this, callback, applyThis, applyArgs, source); - } - finally { - _currentZoneFrame = _currentZoneFrame.parent; - } - } - runGuarded(callback, applyThis = null, applyArgs, source) { - _currentZoneFrame = { parent: _currentZoneFrame, zone: this }; - try { - try { - return this._zoneDelegate.invoke(this, callback, applyThis, applyArgs, source); - } - catch (error) { - if (this._zoneDelegate.handleError(this, error)) { - throw error; - } - } - } - finally { - _currentZoneFrame = _currentZoneFrame.parent; - } - } - runTask(task, applyThis, applyArgs) { - if (task.zone != this) { - throw new Error('A task can only be run in the zone of creation! (Creation: ' + - (task.zone || NO_ZONE).name + '; Execution: ' + this.name + ')'); - } - // https://github.com/angular/zone.js/issues/778, sometimes eventTask - // will run in notScheduled(canceled) state, we should not try to - // run such kind of task but just return - if (task.state === notScheduled && (task.type === eventTask || task.type === macroTask)) { - return; - } - const reEntryGuard = task.state != running; - reEntryGuard && task._transitionTo(running, scheduled); - task.runCount++; - const previousTask = _currentTask; - _currentTask = task; - _currentZoneFrame = { parent: _currentZoneFrame, zone: this }; - try { - if (task.type == macroTask && task.data && !task.data.isPeriodic) { - task.cancelFn = undefined; - } - try { - return this._zoneDelegate.invokeTask(this, task, applyThis, applyArgs); - } - catch (error) { - if (this._zoneDelegate.handleError(this, error)) { - throw error; - } - } - } - finally { - // if the task's state is notScheduled or unknown, then it has already been cancelled - // we should not reset the state to scheduled - if (task.state !== notScheduled && task.state !== unknown) { - if (task.type == eventTask || (task.data && task.data.isPeriodic)) { - reEntryGuard && task._transitionTo(scheduled, running); - } - else { - task.runCount = 0; - this._updateTaskCount(task, -1); - reEntryGuard && - task._transitionTo(notScheduled, running, notScheduled); - } - } - _currentZoneFrame = _currentZoneFrame.parent; - _currentTask = previousTask; - } - } - scheduleTask(task) { - if (task.zone && task.zone !== this) { - // check if the task was rescheduled, the newZone - // should not be the children of the original zone - let newZone = this; - while (newZone) { - if (newZone === task.zone) { - throw Error(`can not reschedule task to ${this.name} which is descendants of the original zone ${task.zone.name}`); - } - newZone = newZone.parent; - } - } - task._transitionTo(scheduling, notScheduled); - const zoneDelegates = []; - task._zoneDelegates = zoneDelegates; - task._zone = this; - try { - task = this._zoneDelegate.scheduleTask(this, task); - } - catch (err) { - // should set task's state to unknown when scheduleTask throw error - // because the err may from reschedule, so the fromState maybe notScheduled - task._transitionTo(unknown, scheduling, notScheduled); - // TODO: @JiaLiPassion, should we check the result from handleError? - this._zoneDelegate.handleError(this, err); - throw err; - } - if (task._zoneDelegates === zoneDelegates) { - // we have to check because internally the delegate can reschedule the task. - this._updateTaskCount(task, 1); - } - if (task.state == scheduling) { - task._transitionTo(scheduled, scheduling); - } - return task; - } - scheduleMicroTask(source, callback, data, customSchedule) { - return this.scheduleTask(new ZoneTask(microTask, source, callback, data, customSchedule, undefined)); - } - scheduleMacroTask(source, callback, data, customSchedule, customCancel) { - return this.scheduleTask(new ZoneTask(macroTask, source, callback, data, customSchedule, customCancel)); - } - scheduleEventTask(source, callback, data, customSchedule, customCancel) { - return this.scheduleTask(new ZoneTask(eventTask, source, callback, data, customSchedule, customCancel)); - } - cancelTask(task) { - if (task.zone != this) - throw new Error('A task can only be cancelled in the zone of creation! (Creation: ' + - (task.zone || NO_ZONE).name + '; Execution: ' + this.name + ')'); - task._transitionTo(canceling, scheduled, running); - try { - this._zoneDelegate.cancelTask(this, task); - } - catch (err) { - // if error occurs when cancelTask, transit the state to unknown - task._transitionTo(unknown, canceling); - this._zoneDelegate.handleError(this, err); - throw err; - } - this._updateTaskCount(task, -1); - task._transitionTo(notScheduled, canceling); - task.runCount = 0; - return task; - } - _updateTaskCount(task, count) { - const zoneDelegates = task._zoneDelegates; - if (count == -1) { - task._zoneDelegates = null; - } - for (let i = 0; i < zoneDelegates.length; i++) { - zoneDelegates[i]._updateTaskCount(task.type, count); - } - } - } - // tslint:disable-next-line:require-internal-with-underscore - Zone.__symbol__ = __symbol__; - const DELEGATE_ZS = { - name: '', - onHasTask: (delegate, _, target, hasTaskState) => delegate.hasTask(target, hasTaskState), - onScheduleTask: (delegate, _, target, task) => delegate.scheduleTask(target, task), - onInvokeTask: (delegate, _, target, task, applyThis, applyArgs) => delegate.invokeTask(target, task, applyThis, applyArgs), - onCancelTask: (delegate, _, target, task) => delegate.cancelTask(target, task) - }; - class _ZoneDelegate { - constructor(zone, parentDelegate, zoneSpec) { - this._taskCounts = { 'microTask': 0, 'macroTask': 0, 'eventTask': 0 }; - this.zone = zone; - this._parentDelegate = parentDelegate; - this._forkZS = zoneSpec && (zoneSpec && zoneSpec.onFork ? zoneSpec : parentDelegate._forkZS); - this._forkDlgt = zoneSpec && (zoneSpec.onFork ? parentDelegate : parentDelegate._forkDlgt); - this._forkCurrZone = - zoneSpec && (zoneSpec.onFork ? this.zone : parentDelegate._forkCurrZone); - this._interceptZS = - zoneSpec && (zoneSpec.onIntercept ? zoneSpec : parentDelegate._interceptZS); - this._interceptDlgt = - zoneSpec && (zoneSpec.onIntercept ? parentDelegate : parentDelegate._interceptDlgt); - this._interceptCurrZone = - zoneSpec && (zoneSpec.onIntercept ? this.zone : parentDelegate._interceptCurrZone); - this._invokeZS = zoneSpec && (zoneSpec.onInvoke ? zoneSpec : parentDelegate._invokeZS); - this._invokeDlgt = - zoneSpec && (zoneSpec.onInvoke ? parentDelegate : parentDelegate._invokeDlgt); - this._invokeCurrZone = - zoneSpec && (zoneSpec.onInvoke ? this.zone : parentDelegate._invokeCurrZone); - this._handleErrorZS = - zoneSpec && (zoneSpec.onHandleError ? zoneSpec : parentDelegate._handleErrorZS); - this._handleErrorDlgt = - zoneSpec && (zoneSpec.onHandleError ? parentDelegate : parentDelegate._handleErrorDlgt); - this._handleErrorCurrZone = - zoneSpec && (zoneSpec.onHandleError ? this.zone : parentDelegate._handleErrorCurrZone); - this._scheduleTaskZS = - zoneSpec && (zoneSpec.onScheduleTask ? zoneSpec : parentDelegate._scheduleTaskZS); - this._scheduleTaskDlgt = zoneSpec && - (zoneSpec.onScheduleTask ? parentDelegate : parentDelegate._scheduleTaskDlgt); - this._scheduleTaskCurrZone = - zoneSpec && (zoneSpec.onScheduleTask ? this.zone : parentDelegate._scheduleTaskCurrZone); - this._invokeTaskZS = - zoneSpec && (zoneSpec.onInvokeTask ? zoneSpec : parentDelegate._invokeTaskZS); - this._invokeTaskDlgt = - zoneSpec && (zoneSpec.onInvokeTask ? parentDelegate : parentDelegate._invokeTaskDlgt); - this._invokeTaskCurrZone = - zoneSpec && (zoneSpec.onInvokeTask ? this.zone : parentDelegate._invokeTaskCurrZone); - this._cancelTaskZS = - zoneSpec && (zoneSpec.onCancelTask ? zoneSpec : parentDelegate._cancelTaskZS); - this._cancelTaskDlgt = - zoneSpec && (zoneSpec.onCancelTask ? parentDelegate : parentDelegate._cancelTaskDlgt); - this._cancelTaskCurrZone = - zoneSpec && (zoneSpec.onCancelTask ? this.zone : parentDelegate._cancelTaskCurrZone); - this._hasTaskZS = null; - this._hasTaskDlgt = null; - this._hasTaskDlgtOwner = null; - this._hasTaskCurrZone = null; - const zoneSpecHasTask = zoneSpec && zoneSpec.onHasTask; - const parentHasTask = parentDelegate && parentDelegate._hasTaskZS; - if (zoneSpecHasTask || parentHasTask) { - // If we need to report hasTask, than this ZS needs to do ref counting on tasks. In such - // a case all task related interceptors must go through this ZD. We can't short circuit it. - this._hasTaskZS = zoneSpecHasTask ? zoneSpec : DELEGATE_ZS; - this._hasTaskDlgt = parentDelegate; - this._hasTaskDlgtOwner = this; - this._hasTaskCurrZone = zone; - if (!zoneSpec.onScheduleTask) { - this._scheduleTaskZS = DELEGATE_ZS; - this._scheduleTaskDlgt = parentDelegate; - this._scheduleTaskCurrZone = this.zone; - } - if (!zoneSpec.onInvokeTask) { - this._invokeTaskZS = DELEGATE_ZS; - this._invokeTaskDlgt = parentDelegate; - this._invokeTaskCurrZone = this.zone; - } - if (!zoneSpec.onCancelTask) { - this._cancelTaskZS = DELEGATE_ZS; - this._cancelTaskDlgt = parentDelegate; - this._cancelTaskCurrZone = this.zone; - } - } - } - fork(targetZone, zoneSpec) { - return this._forkZS ? this._forkZS.onFork(this._forkDlgt, this.zone, targetZone, zoneSpec) : - new Zone(targetZone, zoneSpec); - } - intercept(targetZone, callback, source) { - return this._interceptZS ? - this._interceptZS.onIntercept(this._interceptDlgt, this._interceptCurrZone, targetZone, callback, source) : - callback; - } - invoke(targetZone, callback, applyThis, applyArgs, source) { - return this._invokeZS ? this._invokeZS.onInvoke(this._invokeDlgt, this._invokeCurrZone, targetZone, callback, applyThis, applyArgs, source) : - callback.apply(applyThis, applyArgs); - } - handleError(targetZone, error) { - return this._handleErrorZS ? - this._handleErrorZS.onHandleError(this._handleErrorDlgt, this._handleErrorCurrZone, targetZone, error) : - true; - } - scheduleTask(targetZone, task) { - let returnTask = task; - if (this._scheduleTaskZS) { - if (this._hasTaskZS) { - returnTask._zoneDelegates.push(this._hasTaskDlgtOwner); - } - // clang-format off - returnTask = this._scheduleTaskZS.onScheduleTask(this._scheduleTaskDlgt, this._scheduleTaskCurrZone, targetZone, task); - // clang-format on - if (!returnTask) - returnTask = task; - } - else { - if (task.scheduleFn) { - task.scheduleFn(task); - } - else if (task.type == microTask) { - scheduleMicroTask(task); - } - else { - throw new Error('Task is missing scheduleFn.'); - } - } - return returnTask; - } - invokeTask(targetZone, task, applyThis, applyArgs) { - return this._invokeTaskZS ? this._invokeTaskZS.onInvokeTask(this._invokeTaskDlgt, this._invokeTaskCurrZone, targetZone, task, applyThis, applyArgs) : - task.callback.apply(applyThis, applyArgs); - } - cancelTask(targetZone, task) { - let value; - if (this._cancelTaskZS) { - value = this._cancelTaskZS.onCancelTask(this._cancelTaskDlgt, this._cancelTaskCurrZone, targetZone, task); - } - else { - if (!task.cancelFn) { - throw Error('Task is not cancelable'); - } - value = task.cancelFn(task); - } - return value; - } - hasTask(targetZone, isEmpty) { - // hasTask should not throw error so other ZoneDelegate - // can still trigger hasTask callback - try { - this._hasTaskZS && - this._hasTaskZS.onHasTask(this._hasTaskDlgt, this._hasTaskCurrZone, targetZone, isEmpty); - } - catch (err) { - this.handleError(targetZone, err); - } - } - // tslint:disable-next-line:require-internal-with-underscore - _updateTaskCount(type, count) { - const counts = this._taskCounts; - const prev = counts[type]; - const next = counts[type] = prev + count; - if (next < 0) { - throw new Error('More tasks executed then were scheduled.'); - } - if (prev == 0 || next == 0) { - const isEmpty = { - microTask: counts['microTask'] > 0, - macroTask: counts['macroTask'] > 0, - eventTask: counts['eventTask'] > 0, - change: type - }; - this.hasTask(this.zone, isEmpty); - } - } - } - class ZoneTask { - constructor(type, source, callback, options, scheduleFn, cancelFn) { - // tslint:disable-next-line:require-internal-with-underscore - this._zone = null; - this.runCount = 0; - // tslint:disable-next-line:require-internal-with-underscore - this._zoneDelegates = null; - // tslint:disable-next-line:require-internal-with-underscore - this._state = 'notScheduled'; - this.type = type; - this.source = source; - this.data = options; - this.scheduleFn = scheduleFn; - this.cancelFn = cancelFn; - if (!callback) { - throw new Error('callback is not defined'); - } - this.callback = callback; - const self = this; - // TODO: @JiaLiPassion options should have interface - if (type === eventTask && options && options.useG) { - this.invoke = ZoneTask.invokeTask; - } - else { - this.invoke = function () { - return ZoneTask.invokeTask.call(global, self, this, arguments); - }; - } - } - static invokeTask(task, target, args) { - if (!task) { - task = this; - } - _numberOfNestedTaskFrames++; - try { - task.runCount++; - return task.zone.runTask(task, target, args); - } - finally { - if (_numberOfNestedTaskFrames == 1) { - drainMicroTaskQueue(); - } - _numberOfNestedTaskFrames--; - } - } - get zone() { - return this._zone; - } - get state() { - return this._state; - } - cancelScheduleRequest() { - this._transitionTo(notScheduled, scheduling); - } - // tslint:disable-next-line:require-internal-with-underscore - _transitionTo(toState, fromState1, fromState2) { - if (this._state === fromState1 || this._state === fromState2) { - this._state = toState; - if (toState == notScheduled) { - this._zoneDelegates = null; - } - } - else { - throw new Error(`${this.type} '${this.source}': can not transition to '${toState}', expecting state '${fromState1}'${fromState2 ? ' or \'' + fromState2 + '\'' : ''}, was '${this._state}'.`); - } - } - toString() { - if (this.data && typeof this.data.handleId !== 'undefined') { - return this.data.handleId.toString(); - } - else { - return Object.prototype.toString.call(this); - } - } - // add toJSON method to prevent cyclic error when - // call JSON.stringify(zoneTask) - toJSON() { - return { - type: this.type, - state: this.state, - source: this.source, - zone: this.zone.name, - runCount: this.runCount - }; - } - } - ////////////////////////////////////////////////////// - ////////////////////////////////////////////////////// - /// MICROTASK QUEUE - ////////////////////////////////////////////////////// - ////////////////////////////////////////////////////// - const symbolSetTimeout = __symbol__('setTimeout'); - const symbolPromise = __symbol__('Promise'); - const symbolThen = __symbol__('then'); - let _microTaskQueue = []; - let _isDrainingMicrotaskQueue = false; - let nativeMicroTaskQueuePromise; - function nativeScheduleMicroTask(func) { - if (!nativeMicroTaskQueuePromise) { - if (global[symbolPromise]) { - nativeMicroTaskQueuePromise = global[symbolPromise].resolve(0); - } - } - if (nativeMicroTaskQueuePromise) { - let nativeThen = nativeMicroTaskQueuePromise[symbolThen]; - if (!nativeThen) { - // native Promise is not patchable, we need to use `then` directly - // issue 1078 - nativeThen = nativeMicroTaskQueuePromise['then']; - } - nativeThen.call(nativeMicroTaskQueuePromise, func); - } - else { - global[symbolSetTimeout](func, 0); - } - } - function scheduleMicroTask(task) { - // if we are not running in any task, and there has not been anything scheduled - // we must bootstrap the initial task creation by manually scheduling the drain - if (_numberOfNestedTaskFrames === 0 && _microTaskQueue.length === 0) { - // We are not running in Task, so we need to kickstart the microtask queue. - nativeScheduleMicroTask(drainMicroTaskQueue); - } - task && _microTaskQueue.push(task); - } - function drainMicroTaskQueue() { - if (!_isDrainingMicrotaskQueue) { - _isDrainingMicrotaskQueue = true; - while (_microTaskQueue.length) { - const queue = _microTaskQueue; - _microTaskQueue = []; - for (let i = 0; i < queue.length; i++) { - const task = queue[i]; - try { - task.zone.runTask(task, null, null); - } - catch (error) { - _api.onUnhandledError(error); - } - } - } - _api.microtaskDrainDone(); - _isDrainingMicrotaskQueue = false; - } - } - ////////////////////////////////////////////////////// - ////////////////////////////////////////////////////// - /// BOOTSTRAP - ////////////////////////////////////////////////////// - ////////////////////////////////////////////////////// - const NO_ZONE = { name: 'NO ZONE' }; - const notScheduled = 'notScheduled', scheduling = 'scheduling', scheduled = 'scheduled', running = 'running', canceling = 'canceling', unknown = 'unknown'; - const microTask = 'microTask', macroTask = 'macroTask', eventTask = 'eventTask'; - const patches = {}; - const _api = { - symbol: __symbol__, - currentZoneFrame: () => _currentZoneFrame, - onUnhandledError: noop, - microtaskDrainDone: noop, - scheduleMicroTask: scheduleMicroTask, - showUncaughtError: () => !Zone[__symbol__('ignoreConsoleErrorUncaughtError')], - patchEventTarget: () => [], - patchOnProperties: noop, - patchMethod: () => noop, - bindArguments: () => [], - patchThen: () => noop, - patchMacroTask: () => noop, - patchEventPrototype: () => noop, - isIEOrEdge: () => false, - getGlobalObjects: () => undefined, - ObjectDefineProperty: () => noop, - ObjectGetOwnPropertyDescriptor: () => undefined, - ObjectCreate: () => undefined, - ArraySlice: () => [], - patchClass: () => noop, - wrapWithCurrentZone: () => noop, - filterProperties: () => [], - attachOriginToPatched: () => noop, - _redefineProperty: () => noop, - patchCallbacks: () => noop, - nativeScheduleMicroTask: nativeScheduleMicroTask - }; - let _currentZoneFrame = { parent: null, zone: new Zone(null, null) }; - let _currentTask = null; - let _numberOfNestedTaskFrames = 0; - function noop() { } - performanceMeasure('Zone', 'Zone'); - return global['Zone'] = Zone; -}))(typeof window !== 'undefined' && window || typeof self !== 'undefined' && self || global); - -/** - * @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 - */ -/** - * Suppress closure compiler errors about unknown 'Zone' variable - * @fileoverview - * @suppress {undefinedVars,globalThis,missingRequire} - */ -/// -// issue #989, to reduce bundle size, use short name -/** Object.getOwnPropertyDescriptor */ -const ObjectGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; -/** Object.defineProperty */ -const ObjectDefineProperty = Object.defineProperty; -/** Object.getPrototypeOf */ -const ObjectGetPrototypeOf = Object.getPrototypeOf; -/** Object.create */ -const ObjectCreate = Object.create; -/** Array.prototype.slice */ -const ArraySlice = Array.prototype.slice; -/** addEventListener string const */ -const ADD_EVENT_LISTENER_STR = 'addEventListener'; -/** removeEventListener string const */ -const REMOVE_EVENT_LISTENER_STR = 'removeEventListener'; -/** zoneSymbol addEventListener */ -const ZONE_SYMBOL_ADD_EVENT_LISTENER = Zone.__symbol__(ADD_EVENT_LISTENER_STR); -/** zoneSymbol removeEventListener */ -const ZONE_SYMBOL_REMOVE_EVENT_LISTENER = Zone.__symbol__(REMOVE_EVENT_LISTENER_STR); -/** true string const */ -const TRUE_STR = 'true'; -/** false string const */ -const FALSE_STR = 'false'; -/** Zone symbol prefix string const. */ -const ZONE_SYMBOL_PREFIX = Zone.__symbol__(''); -function wrapWithCurrentZone(callback, source) { - return Zone.current.wrap(callback, source); -} -function scheduleMacroTaskWithCurrentZone(source, callback, data, customSchedule, customCancel) { - return Zone.current.scheduleMacroTask(source, callback, data, customSchedule, customCancel); -} -const zoneSymbol = Zone.__symbol__; -const isWindowExists = typeof window !== 'undefined'; -const internalWindow = isWindowExists ? window : undefined; -const _global = isWindowExists && internalWindow || typeof self === 'object' && self || global; -const REMOVE_ATTRIBUTE = 'removeAttribute'; -function bindArguments(args, source) { - for (let i = args.length - 1; i >= 0; i--) { - if (typeof args[i] === 'function') { - args[i] = wrapWithCurrentZone(args[i], source + '_' + i); - } - } - return args; -} -function patchPrototype(prototype, fnNames) { - const source = prototype.constructor['name']; - for (let i = 0; i < fnNames.length; i++) { - const name = fnNames[i]; - const delegate = prototype[name]; - if (delegate) { - const prototypeDesc = ObjectGetOwnPropertyDescriptor(prototype, name); - if (!isPropertyWritable(prototypeDesc)) { - continue; - } - prototype[name] = ((delegate) => { - const patched = function () { - return delegate.apply(this, bindArguments(arguments, source + '.' + name)); - }; - attachOriginToPatched(patched, delegate); - return patched; - })(delegate); - } - } -} -function isPropertyWritable(propertyDesc) { - if (!propertyDesc) { - return true; - } - if (propertyDesc.writable === false) { - return false; - } - return !(typeof propertyDesc.get === 'function' && typeof propertyDesc.set === 'undefined'); -} -const isWebWorker = (typeof WorkerGlobalScope !== 'undefined' && self instanceof WorkerGlobalScope); -// Make sure to access `process` through `_global` so that WebPack does not accidentally browserify -// this code. -const isNode = (!('nw' in _global) && typeof _global.process !== 'undefined' && - {}.toString.call(_global.process) === '[object process]'); -const isBrowser = !isNode && !isWebWorker && !!(isWindowExists && internalWindow['HTMLElement']); -// we are in electron of nw, so we are both browser and nodejs -// Make sure to access `process` through `_global` so that WebPack does not accidentally browserify -// this code. -const isMix = typeof _global.process !== 'undefined' && - {}.toString.call(_global.process) === '[object process]' && !isWebWorker && - !!(isWindowExists && internalWindow['HTMLElement']); -const zoneSymbolEventNames$1 = {}; -const wrapFn = function (event) { - // https://github.com/angular/zone.js/issues/911, in IE, sometimes - // event will be undefined, so we need to use window.event - event = event || _global.event; - if (!event) { - return; - } - let eventNameSymbol = zoneSymbolEventNames$1[event.type]; - if (!eventNameSymbol) { - eventNameSymbol = zoneSymbolEventNames$1[event.type] = zoneSymbol('ON_PROPERTY' + event.type); - } - const target = this || event.target || _global; - const listener = target[eventNameSymbol]; - let result; - if (isBrowser && target === internalWindow && event.type === 'error') { - // window.onerror have different signature - // https://developer.mozilla.org/en-US/docs/Web/API/GlobalEventHandlers/onerror#window.onerror - // and onerror callback will prevent default when callback return true - const errorEvent = event; - result = listener && - listener.call(this, errorEvent.message, errorEvent.filename, errorEvent.lineno, errorEvent.colno, errorEvent.error); - if (result === true) { - event.preventDefault(); - } - } - else { - result = listener && listener.apply(this, arguments); - if (result != undefined && !result) { - event.preventDefault(); - } - } - return result; -}; -function patchProperty(obj, prop, prototype) { - let desc = ObjectGetOwnPropertyDescriptor(obj, prop); - if (!desc && prototype) { - // when patch window object, use prototype to check prop exist or not - const prototypeDesc = ObjectGetOwnPropertyDescriptor(prototype, prop); - if (prototypeDesc) { - desc = { enumerable: true, configurable: true }; - } - } - // if the descriptor not exists or is not configurable - // just return - if (!desc || !desc.configurable) { - return; - } - const onPropPatchedSymbol = zoneSymbol('on' + prop + 'patched'); - if (obj.hasOwnProperty(onPropPatchedSymbol) && obj[onPropPatchedSymbol]) { - return; - } - // A property descriptor cannot have getter/setter and be writable - // deleting the writable and value properties avoids this error: - // - // TypeError: property descriptors must not specify a value or be writable when a - // getter or setter has been specified - delete desc.writable; - delete desc.value; - const originalDescGet = desc.get; - const originalDescSet = desc.set; - // slice(2) cuz 'onclick' -> 'click', etc - const eventName = prop.slice(2); - let eventNameSymbol = zoneSymbolEventNames$1[eventName]; - if (!eventNameSymbol) { - eventNameSymbol = zoneSymbolEventNames$1[eventName] = zoneSymbol('ON_PROPERTY' + eventName); - } - desc.set = function (newValue) { - // in some of windows's onproperty callback, this is undefined - // so we need to check it - let target = this; - if (!target && obj === _global) { - target = _global; - } - if (!target) { - return; - } - const previousValue = target[eventNameSymbol]; - if (typeof previousValue === 'function') { - target.removeEventListener(eventName, wrapFn); - } - // issue #978, when onload handler was added before loading zone.js - // we should remove it with originalDescSet - originalDescSet && originalDescSet.call(target, null); - target[eventNameSymbol] = newValue; - if (typeof newValue === 'function') { - target.addEventListener(eventName, wrapFn, false); - } - }; - // The getter would return undefined for unassigned properties but the default value of an - // unassigned property is null - desc.get = function () { - // in some of windows's onproperty callback, this is undefined - // so we need to check it - let target = this; - if (!target && obj === _global) { - target = _global; - } - if (!target) { - return null; - } - const listener = target[eventNameSymbol]; - if (listener) { - return listener; - } - else if (originalDescGet) { - // result will be null when use inline event attribute, - // such as - // because the onclick function is internal raw uncompiled handler - // the onclick will be evaluated when first time event was triggered or - // the property is accessed, https://github.com/angular/zone.js/issues/525 - // so we should use original native get to retrieve the handler - let value = originalDescGet.call(this); - if (value) { - desc.set.call(this, value); - if (typeof target[REMOVE_ATTRIBUTE] === 'function') { - target.removeAttribute(prop); - } - return value; - } - } - return null; - }; - ObjectDefineProperty(obj, prop, desc); - obj[onPropPatchedSymbol] = true; -} -function patchOnProperties(obj, properties, prototype) { - if (properties) { - for (let i = 0; i < properties.length; i++) { - patchProperty(obj, 'on' + properties[i], prototype); - } - } - else { - const onProperties = []; - for (const prop in obj) { - if (prop.slice(0, 2) == 'on') { - onProperties.push(prop); - } - } - for (let j = 0; j < onProperties.length; j++) { - patchProperty(obj, onProperties[j], prototype); - } - } -} -const originalInstanceKey = zoneSymbol('originalInstance'); -// wrap some native API on `window` -function patchClass(className) { - const OriginalClass = _global[className]; - if (!OriginalClass) - return; - // keep original class in global - _global[zoneSymbol(className)] = OriginalClass; - _global[className] = function () { - const a = bindArguments(arguments, className); - switch (a.length) { - case 0: - this[originalInstanceKey] = new OriginalClass(); - break; - case 1: - this[originalInstanceKey] = new OriginalClass(a[0]); - break; - case 2: - this[originalInstanceKey] = new OriginalClass(a[0], a[1]); - break; - case 3: - this[originalInstanceKey] = new OriginalClass(a[0], a[1], a[2]); - break; - case 4: - this[originalInstanceKey] = new OriginalClass(a[0], a[1], a[2], a[3]); - break; - default: - throw new Error('Arg list too long.'); - } - }; - // attach original delegate to patched function - attachOriginToPatched(_global[className], OriginalClass); - const instance = new OriginalClass(function () { }); - let prop; - for (prop in instance) { - // https://bugs.webkit.org/show_bug.cgi?id=44721 - if (className === 'XMLHttpRequest' && prop === 'responseBlob') - continue; - (function (prop) { - if (typeof instance[prop] === 'function') { - _global[className].prototype[prop] = function () { - return this[originalInstanceKey][prop].apply(this[originalInstanceKey], arguments); - }; - } - else { - ObjectDefineProperty(_global[className].prototype, prop, { - set: function (fn) { - if (typeof fn === 'function') { - this[originalInstanceKey][prop] = wrapWithCurrentZone(fn, className + '.' + prop); - // keep callback in wrapped function so we can - // use it in Function.prototype.toString to return - // the native one. - attachOriginToPatched(this[originalInstanceKey][prop], fn); - } - else { - this[originalInstanceKey][prop] = fn; - } - }, - get: function () { - return this[originalInstanceKey][prop]; - } - }); - } - }(prop)); - } - for (prop in OriginalClass) { - if (prop !== 'prototype' && OriginalClass.hasOwnProperty(prop)) { - _global[className][prop] = OriginalClass[prop]; - } - } -} -function patchMethod(target, name, patchFn) { - let proto = target; - while (proto && !proto.hasOwnProperty(name)) { - proto = ObjectGetPrototypeOf(proto); - } - if (!proto && target[name]) { - // somehow we did not find it, but we can see it. This happens on IE for Window properties. - proto = target; - } - const delegateName = zoneSymbol(name); - let delegate = null; - if (proto && (!(delegate = proto[delegateName]) || !proto.hasOwnProperty(delegateName))) { - delegate = proto[delegateName] = proto[name]; - // check whether proto[name] is writable - // some property is readonly in safari, such as HtmlCanvasElement.prototype.toBlob - const desc = proto && ObjectGetOwnPropertyDescriptor(proto, name); - if (isPropertyWritable(desc)) { - const patchDelegate = patchFn(delegate, delegateName, name); - proto[name] = function () { - return patchDelegate(this, arguments); - }; - attachOriginToPatched(proto[name], delegate); - } - } - return delegate; -} -// TODO: @JiaLiPassion, support cancel task later if necessary -function patchMacroTask(obj, funcName, metaCreator) { - let setNative = null; - function scheduleTask(task) { - const data = task.data; - data.args[data.cbIdx] = function () { - task.invoke.apply(this, arguments); - }; - setNative.apply(data.target, data.args); - return task; - } - setNative = patchMethod(obj, funcName, (delegate) => function (self, args) { - const meta = metaCreator(self, args); - if (meta.cbIdx >= 0 && typeof args[meta.cbIdx] === 'function') { - return scheduleMacroTaskWithCurrentZone(meta.name, args[meta.cbIdx], meta, scheduleTask); - } - else { - // cause an error by calling it directly. - return delegate.apply(self, args); - } - }); -} -function attachOriginToPatched(patched, original) { - patched[zoneSymbol('OriginalDelegate')] = original; -} -let isDetectedIEOrEdge = false; -let ieOrEdge = false; -function isIE() { - try { - const ua = internalWindow.navigator.userAgent; - if (ua.indexOf('MSIE ') !== -1 || ua.indexOf('Trident/') !== -1) { - return true; - } - } - catch (error) { - } - return false; -} -function isIEOrEdge() { - if (isDetectedIEOrEdge) { - return ieOrEdge; - } - isDetectedIEOrEdge = true; - try { - const ua = internalWindow.navigator.userAgent; - if (ua.indexOf('MSIE ') !== -1 || ua.indexOf('Trident/') !== -1 || ua.indexOf('Edge/') !== -1) { - ieOrEdge = true; - } - } - catch (error) { - } - return ieOrEdge; -} - -/** - * @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 - */ -Zone.__load_patch('ZoneAwarePromise', (global, Zone, api) => { - const ObjectGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; - const ObjectDefineProperty = Object.defineProperty; - function readableObjectToString(obj) { - if (obj && obj.toString === Object.prototype.toString) { - const className = obj.constructor && obj.constructor.name; - return (className ? className : '') + ': ' + JSON.stringify(obj); - } - return obj ? obj.toString() : Object.prototype.toString.call(obj); - } - const __symbol__ = api.symbol; - const _uncaughtPromiseErrors = []; - const isDisableWrappingUncaughtPromiseRejection = global[__symbol__('DISABLE_WRAPPING_UNCAUGHT_PROMISE_REJECTION')] === true; - const symbolPromise = __symbol__('Promise'); - const symbolThen = __symbol__('then'); - const creationTrace = '__creationTrace__'; - api.onUnhandledError = (e) => { - if (api.showUncaughtError()) { - const rejection = e && e.rejection; - if (rejection) { - console.error('Unhandled Promise rejection:', rejection instanceof Error ? rejection.message : rejection, '; Zone:', e.zone.name, '; Task:', e.task && e.task.source, '; Value:', rejection, rejection instanceof Error ? rejection.stack : undefined); - } - else { - console.error(e); - } - } - }; - api.microtaskDrainDone = () => { - while (_uncaughtPromiseErrors.length) { - const uncaughtPromiseError = _uncaughtPromiseErrors.shift(); - try { - uncaughtPromiseError.zone.runGuarded(() => { - if (uncaughtPromiseError.throwOriginal) { - throw uncaughtPromiseError.rejection; - } - throw uncaughtPromiseError; - }); - } - catch (error) { - handleUnhandledRejection(error); - } - } - }; - const UNHANDLED_PROMISE_REJECTION_HANDLER_SYMBOL = __symbol__('unhandledPromiseRejectionHandler'); - function handleUnhandledRejection(e) { - api.onUnhandledError(e); - try { - const handler = Zone[UNHANDLED_PROMISE_REJECTION_HANDLER_SYMBOL]; - if (typeof handler === 'function') { - handler.call(this, e); - } - } - catch (err) { - } - } - function isThenable(value) { - return value && value.then; - } - function forwardResolution(value) { - return value; - } - function forwardRejection(rejection) { - return ZoneAwarePromise.reject(rejection); - } - const symbolState = __symbol__('state'); - const symbolValue = __symbol__('value'); - const symbolFinally = __symbol__('finally'); - const symbolParentPromiseValue = __symbol__('parentPromiseValue'); - const symbolParentPromiseState = __symbol__('parentPromiseState'); - const source = 'Promise.then'; - const UNRESOLVED = null; - const RESOLVED = true; - const REJECTED = false; - const REJECTED_NO_CATCH = 0; - function makeResolver(promise, state) { - return (v) => { - try { - resolvePromise(promise, state, v); - } - catch (err) { - resolvePromise(promise, false, err); - } - // Do not return value or you will break the Promise spec. - }; - } - const once = function () { - let wasCalled = false; - return function wrapper(wrappedFunction) { - return function () { - if (wasCalled) { - return; - } - wasCalled = true; - wrappedFunction.apply(null, arguments); - }; - }; - }; - const TYPE_ERROR = 'Promise resolved with itself'; - const CURRENT_TASK_TRACE_SYMBOL = __symbol__('currentTaskTrace'); - // Promise Resolution - function resolvePromise(promise, state, value) { - const onceWrapper = once(); - if (promise === value) { - throw new TypeError(TYPE_ERROR); - } - if (promise[symbolState] === UNRESOLVED) { - // should only get value.then once based on promise spec. - let then = null; - try { - if (typeof value === 'object' || typeof value === 'function') { - then = value && value.then; - } - } - catch (err) { - onceWrapper(() => { - resolvePromise(promise, false, err); - })(); - return promise; - } - // if (value instanceof ZoneAwarePromise) { - if (state !== REJECTED && value instanceof ZoneAwarePromise && - value.hasOwnProperty(symbolState) && value.hasOwnProperty(symbolValue) && - value[symbolState] !== UNRESOLVED) { - clearRejectedNoCatch(value); - resolvePromise(promise, value[symbolState], value[symbolValue]); - } - else if (state !== REJECTED && typeof then === 'function') { - try { - then.call(value, onceWrapper(makeResolver(promise, state)), onceWrapper(makeResolver(promise, false))); - } - catch (err) { - onceWrapper(() => { - resolvePromise(promise, false, err); - })(); - } - } - else { - promise[symbolState] = state; - const queue = promise[symbolValue]; - promise[symbolValue] = value; - if (promise[symbolFinally] === symbolFinally) { - // the promise is generated by Promise.prototype.finally - if (state === RESOLVED) { - // the state is resolved, should ignore the value - // and use parent promise value - promise[symbolState] = promise[symbolParentPromiseState]; - promise[symbolValue] = promise[symbolParentPromiseValue]; - } - } - // record task information in value when error occurs, so we can - // do some additional work such as render longStackTrace - if (state === REJECTED && value instanceof Error) { - // check if longStackTraceZone is here - const trace = Zone.currentTask && Zone.currentTask.data && - Zone.currentTask.data[creationTrace]; - if (trace) { - // only keep the long stack trace into error when in longStackTraceZone - ObjectDefineProperty(value, CURRENT_TASK_TRACE_SYMBOL, { configurable: true, enumerable: false, writable: true, value: trace }); - } - } - for (let i = 0; i < queue.length;) { - scheduleResolveOrReject(promise, queue[i++], queue[i++], queue[i++], queue[i++]); - } - if (queue.length == 0 && state == REJECTED) { - promise[symbolState] = REJECTED_NO_CATCH; - let uncaughtPromiseError = value; - try { - // Here we throws a new Error to print more readable error log - // and if the value is not an error, zone.js builds an `Error` - // Object here to attach the stack information. - throw new Error('Uncaught (in promise): ' + readableObjectToString(value) + - (value && value.stack ? '\n' + value.stack : '')); - } - catch (err) { - uncaughtPromiseError = err; - } - if (isDisableWrappingUncaughtPromiseRejection) { - // If disable wrapping uncaught promise reject - // use the value instead of wrapping it. - uncaughtPromiseError.throwOriginal = true; - } - uncaughtPromiseError.rejection = value; - uncaughtPromiseError.promise = promise; - uncaughtPromiseError.zone = Zone.current; - uncaughtPromiseError.task = Zone.currentTask; - _uncaughtPromiseErrors.push(uncaughtPromiseError); - api.scheduleMicroTask(); // to make sure that it is running - } - } - } - // Resolving an already resolved promise is a noop. - return promise; - } - const REJECTION_HANDLED_HANDLER = __symbol__('rejectionHandledHandler'); - function clearRejectedNoCatch(promise) { - if (promise[symbolState] === REJECTED_NO_CATCH) { - // if the promise is rejected no catch status - // and queue.length > 0, means there is a error handler - // here to handle the rejected promise, we should trigger - // windows.rejectionhandled eventHandler or nodejs rejectionHandled - // eventHandler - try { - const handler = Zone[REJECTION_HANDLED_HANDLER]; - if (handler && typeof handler === 'function') { - handler.call(this, { rejection: promise[symbolValue], promise: promise }); - } - } - catch (err) { - } - promise[symbolState] = REJECTED; - for (let i = 0; i < _uncaughtPromiseErrors.length; i++) { - if (promise === _uncaughtPromiseErrors[i].promise) { - _uncaughtPromiseErrors.splice(i, 1); - } - } - } - } - function scheduleResolveOrReject(promise, zone, chainPromise, onFulfilled, onRejected) { - clearRejectedNoCatch(promise); - const promiseState = promise[symbolState]; - const delegate = promiseState ? - (typeof onFulfilled === 'function') ? onFulfilled : forwardResolution : - (typeof onRejected === 'function') ? onRejected : - forwardRejection; - zone.scheduleMicroTask(source, () => { - try { - const parentPromiseValue = promise[symbolValue]; - const isFinallyPromise = !!chainPromise && symbolFinally === chainPromise[symbolFinally]; - if (isFinallyPromise) { - // if the promise is generated from finally call, keep parent promise's state and value - chainPromise[symbolParentPromiseValue] = parentPromiseValue; - chainPromise[symbolParentPromiseState] = promiseState; - } - // should not pass value to finally callback - const value = zone.run(delegate, undefined, isFinallyPromise && delegate !== forwardRejection && delegate !== forwardResolution ? - [] : - [parentPromiseValue]); - resolvePromise(chainPromise, true, value); - } - catch (error) { - // if error occurs, should always return this error - resolvePromise(chainPromise, false, error); - } - }, chainPromise); - } - const ZONE_AWARE_PROMISE_TO_STRING = 'function ZoneAwarePromise() { [native code] }'; - const noop = function () { }; - const AggregateError = global.AggregateError; - class ZoneAwarePromise { - static toString() { - return ZONE_AWARE_PROMISE_TO_STRING; - } - static resolve(value) { - return resolvePromise(new this(null), RESOLVED, value); - } - static reject(error) { - return resolvePromise(new this(null), REJECTED, error); - } - static any(values) { - if (!values || typeof values[Symbol.iterator] !== 'function') { - return Promise.reject(new AggregateError([], 'All promises were rejected')); - } - const promises = []; - let count = 0; - try { - for (let v of values) { - count++; - promises.push(ZoneAwarePromise.resolve(v)); - } - } - catch (err) { - return Promise.reject(new AggregateError([], 'All promises were rejected')); - } - if (count === 0) { - return Promise.reject(new AggregateError([], 'All promises were rejected')); - } - let finished = false; - const errors = []; - return new ZoneAwarePromise((resolve, reject) => { - for (let i = 0; i < promises.length; i++) { - promises[i].then(v => { - if (finished) { - return; - } - finished = true; - resolve(v); - }, err => { - errors.push(err); - count--; - if (count === 0) { - finished = true; - reject(new AggregateError(errors, 'All promises were rejected')); - } - }); - } - }); - } - ; - static race(values) { - let resolve; - let reject; - let promise = new this((res, rej) => { - resolve = res; - reject = rej; - }); - function onResolve(value) { - resolve(value); - } - function onReject(error) { - reject(error); - } - for (let value of values) { - if (!isThenable(value)) { - value = this.resolve(value); - } - value.then(onResolve, onReject); - } - return promise; - } - static all(values) { - return ZoneAwarePromise.allWithCallback(values); - } - static allSettled(values) { - const P = this && this.prototype instanceof ZoneAwarePromise ? this : ZoneAwarePromise; - return P.allWithCallback(values, { - thenCallback: (value) => ({ status: 'fulfilled', value }), - errorCallback: (err) => ({ status: 'rejected', reason: err }) - }); - } - static allWithCallback(values, callback) { - let resolve; - let reject; - let promise = new this((res, rej) => { - resolve = res; - reject = rej; - }); - // Start at 2 to prevent prematurely resolving if .then is called immediately. - let unresolvedCount = 2; - let valueIndex = 0; - const resolvedValues = []; - for (let value of values) { - if (!isThenable(value)) { - value = this.resolve(value); - } - const curValueIndex = valueIndex; - try { - value.then((value) => { - resolvedValues[curValueIndex] = callback ? callback.thenCallback(value) : value; - unresolvedCount--; - if (unresolvedCount === 0) { - resolve(resolvedValues); - } - }, (err) => { - if (!callback) { - reject(err); - } - else { - resolvedValues[curValueIndex] = callback.errorCallback(err); - unresolvedCount--; - if (unresolvedCount === 0) { - resolve(resolvedValues); - } - } - }); - } - catch (thenErr) { - reject(thenErr); - } - unresolvedCount++; - valueIndex++; - } - // Make the unresolvedCount zero-based again. - unresolvedCount -= 2; - if (unresolvedCount === 0) { - resolve(resolvedValues); - } - return promise; - } - constructor(executor) { - const promise = this; - if (!(promise instanceof ZoneAwarePromise)) { - throw new Error('Must be an instanceof Promise.'); - } - promise[symbolState] = UNRESOLVED; - promise[symbolValue] = []; // queue; - try { - const onceWrapper = once(); - executor && - executor(onceWrapper(makeResolver(promise, RESOLVED)), onceWrapper(makeResolver(promise, REJECTED))); - } - catch (error) { - resolvePromise(promise, false, error); - } - } - get [Symbol.toStringTag]() { - return 'Promise'; - } - get [Symbol.species]() { - return ZoneAwarePromise; - } - then(onFulfilled, onRejected) { - var _a; - // We must read `Symbol.species` safely because `this` may be anything. For instance, `this` - // may be an object without a prototype (created through `Object.create(null)`); thus - // `this.constructor` will be undefined. One of the use cases is SystemJS creating - // prototype-less objects (modules) via `Object.create(null)`. The SystemJS creates an empty - // object and copies promise properties into that object (within the `getOrCreateLoad` - // function). The zone.js then checks if the resolved value has the `then` method and invokes - // it with the `value` context. Otherwise, this will throw an error: `TypeError: Cannot read - // properties of undefined (reading 'Symbol(Symbol.species)')`. - let C = (_a = this.constructor) === null || _a === void 0 ? void 0 : _a[Symbol.species]; - if (!C || typeof C !== 'function') { - C = this.constructor || ZoneAwarePromise; - } - const chainPromise = new C(noop); - const zone = Zone.current; - if (this[symbolState] == UNRESOLVED) { - this[symbolValue].push(zone, chainPromise, onFulfilled, onRejected); - } - else { - scheduleResolveOrReject(this, zone, chainPromise, onFulfilled, onRejected); - } - return chainPromise; - } - catch(onRejected) { - return this.then(null, onRejected); - } - finally(onFinally) { - var _a; - // See comment on the call to `then` about why thee `Symbol.species` is safely accessed. - let C = (_a = this.constructor) === null || _a === void 0 ? void 0 : _a[Symbol.species]; - if (!C || typeof C !== 'function') { - C = ZoneAwarePromise; - } - const chainPromise = new C(noop); - chainPromise[symbolFinally] = symbolFinally; - const zone = Zone.current; - if (this[symbolState] == UNRESOLVED) { - this[symbolValue].push(zone, chainPromise, onFinally, onFinally); - } - else { - scheduleResolveOrReject(this, zone, chainPromise, onFinally, onFinally); - } - return chainPromise; - } - } - // Protect against aggressive optimizers dropping seemingly unused properties. - // E.g. Closure Compiler in advanced mode. - ZoneAwarePromise['resolve'] = ZoneAwarePromise.resolve; - ZoneAwarePromise['reject'] = ZoneAwarePromise.reject; - ZoneAwarePromise['race'] = ZoneAwarePromise.race; - ZoneAwarePromise['all'] = ZoneAwarePromise.all; - const NativePromise = global[symbolPromise] = global['Promise']; - global['Promise'] = ZoneAwarePromise; - const symbolThenPatched = __symbol__('thenPatched'); - function patchThen(Ctor) { - const proto = Ctor.prototype; - const prop = ObjectGetOwnPropertyDescriptor(proto, 'then'); - if (prop && (prop.writable === false || !prop.configurable)) { - // check Ctor.prototype.then propertyDescriptor is writable or not - // in meteor env, writable is false, we should ignore such case - return; - } - const originalThen = proto.then; - // Keep a reference to the original method. - proto[symbolThen] = originalThen; - Ctor.prototype.then = function (onResolve, onReject) { - const wrapped = new ZoneAwarePromise((resolve, reject) => { - originalThen.call(this, resolve, reject); - }); - return wrapped.then(onResolve, onReject); - }; - Ctor[symbolThenPatched] = true; - } - api.patchThen = patchThen; - function zoneify(fn) { - return function (self, args) { - let resultPromise = fn.apply(self, args); - if (resultPromise instanceof ZoneAwarePromise) { - return resultPromise; - } - let ctor = resultPromise.constructor; - if (!ctor[symbolThenPatched]) { - patchThen(ctor); - } - return resultPromise; - }; - } - if (NativePromise) { - patchThen(NativePromise); - patchMethod(global, 'fetch', delegate => zoneify(delegate)); - } - // This is not part of public API, but it is useful for tests, so we expose it. - Promise[Zone.__symbol__('uncaughtPromiseErrors')] = _uncaughtPromiseErrors; - return ZoneAwarePromise; -}); - -/** - * @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 - */ -// override Function.prototype.toString to make zone.js patched function -// look like native function -Zone.__load_patch('toString', (global) => { - // patch Func.prototype.toString to let them look like native - const originalFunctionToString = Function.prototype.toString; - const ORIGINAL_DELEGATE_SYMBOL = zoneSymbol('OriginalDelegate'); - const PROMISE_SYMBOL = zoneSymbol('Promise'); - const ERROR_SYMBOL = zoneSymbol('Error'); - const newFunctionToString = function toString() { - if (typeof this === 'function') { - const originalDelegate = this[ORIGINAL_DELEGATE_SYMBOL]; - if (originalDelegate) { - if (typeof originalDelegate === 'function') { - return originalFunctionToString.call(originalDelegate); - } - else { - return Object.prototype.toString.call(originalDelegate); - } - } - if (this === Promise) { - const nativePromise = global[PROMISE_SYMBOL]; - if (nativePromise) { - return originalFunctionToString.call(nativePromise); - } - } - if (this === Error) { - const nativeError = global[ERROR_SYMBOL]; - if (nativeError) { - return originalFunctionToString.call(nativeError); - } - } - } - return originalFunctionToString.call(this); - }; - newFunctionToString[ORIGINAL_DELEGATE_SYMBOL] = originalFunctionToString; - Function.prototype.toString = newFunctionToString; - // patch Object.prototype.toString to let them look like native - const originalObjectToString = Object.prototype.toString; - const PROMISE_OBJECT_TO_STRING = '[object Promise]'; - Object.prototype.toString = function () { - if (typeof Promise === 'function' && this instanceof Promise) { - return PROMISE_OBJECT_TO_STRING; - } - return originalObjectToString.call(this); - }; -}); - -/** - * @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 - */ -let passiveSupported = false; -if (typeof window !== 'undefined') { - try { - const options = Object.defineProperty({}, 'passive', { - get: function () { - passiveSupported = true; - } - }); - // Note: We pass the `options` object as the event handler too. This is not compatible with the - // signature of `addEventListener` or `removeEventListener` but enables us to remove the handler - // without an actual handler. - window.addEventListener('test', options, options); - window.removeEventListener('test', options, options); - } - catch (err) { - passiveSupported = false; - } -} -// an identifier to tell ZoneTask do not create a new invoke closure -const OPTIMIZED_ZONE_EVENT_TASK_DATA = { - useG: true -}; -const zoneSymbolEventNames = {}; -const globalSources = {}; -const EVENT_NAME_SYMBOL_REGX = new RegExp('^' + ZONE_SYMBOL_PREFIX + '(\\w+)(true|false)$'); -const IMMEDIATE_PROPAGATION_SYMBOL = zoneSymbol('propagationStopped'); -function prepareEventNames(eventName, eventNameToString) { - const falseEventName = (eventNameToString ? eventNameToString(eventName) : eventName) + FALSE_STR; - const trueEventName = (eventNameToString ? eventNameToString(eventName) : eventName) + TRUE_STR; - const symbol = ZONE_SYMBOL_PREFIX + falseEventName; - const symbolCapture = ZONE_SYMBOL_PREFIX + trueEventName; - zoneSymbolEventNames[eventName] = {}; - zoneSymbolEventNames[eventName][FALSE_STR] = symbol; - zoneSymbolEventNames[eventName][TRUE_STR] = symbolCapture; -} -function patchEventTarget(_global, api, apis, patchOptions) { - const ADD_EVENT_LISTENER = (patchOptions && patchOptions.add) || ADD_EVENT_LISTENER_STR; - const REMOVE_EVENT_LISTENER = (patchOptions && patchOptions.rm) || REMOVE_EVENT_LISTENER_STR; - const LISTENERS_EVENT_LISTENER = (patchOptions && patchOptions.listeners) || 'eventListeners'; - const REMOVE_ALL_LISTENERS_EVENT_LISTENER = (patchOptions && patchOptions.rmAll) || 'removeAllListeners'; - const zoneSymbolAddEventListener = zoneSymbol(ADD_EVENT_LISTENER); - const ADD_EVENT_LISTENER_SOURCE = '.' + ADD_EVENT_LISTENER + ':'; - const PREPEND_EVENT_LISTENER = 'prependListener'; - const PREPEND_EVENT_LISTENER_SOURCE = '.' + PREPEND_EVENT_LISTENER + ':'; - const invokeTask = function (task, target, event) { - // for better performance, check isRemoved which is set - // by removeEventListener - if (task.isRemoved) { - return; - } - const delegate = task.callback; - if (typeof delegate === 'object' && delegate.handleEvent) { - // create the bind version of handleEvent when invoke - task.callback = (event) => delegate.handleEvent(event); - task.originalDelegate = delegate; - } - // invoke static task.invoke - // need to try/catch error here, otherwise, the error in one event listener - // will break the executions of the other event listeners. Also error will - // not remove the event listener when `once` options is true. - let error; - try { - task.invoke(task, target, [event]); - } - catch (err) { - error = err; - } - const options = task.options; - if (options && typeof options === 'object' && options.once) { - // if options.once is true, after invoke once remove listener here - // only browser need to do this, nodejs eventEmitter will cal removeListener - // inside EventEmitter.once - const delegate = task.originalDelegate ? task.originalDelegate : task.callback; - target[REMOVE_EVENT_LISTENER].call(target, event.type, delegate, options); - } - return error; - }; - function globalCallback(context, event, isCapture) { - // https://github.com/angular/zone.js/issues/911, in IE, sometimes - // event will be undefined, so we need to use window.event - event = event || _global.event; - if (!event) { - return; - } - // event.target is needed for Samsung TV and SourceBuffer - // || global is needed https://github.com/angular/zone.js/issues/190 - const target = context || event.target || _global; - const tasks = target[zoneSymbolEventNames[event.type][isCapture ? TRUE_STR : FALSE_STR]]; - if (tasks) { - const errors = []; - // invoke all tasks which attached to current target with given event.type and capture = false - // for performance concern, if task.length === 1, just invoke - if (tasks.length === 1) { - const err = invokeTask(tasks[0], target, event); - err && errors.push(err); - } - else { - // https://github.com/angular/zone.js/issues/836 - // copy the tasks array before invoke, to avoid - // the callback will remove itself or other listener - const copyTasks = tasks.slice(); - for (let i = 0; i < copyTasks.length; i++) { - if (event && event[IMMEDIATE_PROPAGATION_SYMBOL] === true) { - break; - } - const err = invokeTask(copyTasks[i], target, event); - err && errors.push(err); - } - } - // Since there is only one error, we don't need to schedule microTask - // to throw the error. - if (errors.length === 1) { - throw errors[0]; - } - else { - for (let i = 0; i < errors.length; i++) { - const err = errors[i]; - api.nativeScheduleMicroTask(() => { - throw err; - }); - } - } - } - } - // global shared zoneAwareCallback to handle all event callback with capture = false - const globalZoneAwareCallback = function (event) { - return globalCallback(this, event, false); - }; - // global shared zoneAwareCallback to handle all event callback with capture = true - const globalZoneAwareCaptureCallback = function (event) { - return globalCallback(this, event, true); - }; - function patchEventTargetMethods(obj, patchOptions) { - if (!obj) { - return false; - } - let useGlobalCallback = true; - if (patchOptions && patchOptions.useG !== undefined) { - useGlobalCallback = patchOptions.useG; - } - const validateHandler = patchOptions && patchOptions.vh; - let checkDuplicate = true; - if (patchOptions && patchOptions.chkDup !== undefined) { - checkDuplicate = patchOptions.chkDup; - } - let returnTarget = false; - if (patchOptions && patchOptions.rt !== undefined) { - returnTarget = patchOptions.rt; - } - let proto = obj; - while (proto && !proto.hasOwnProperty(ADD_EVENT_LISTENER)) { - proto = ObjectGetPrototypeOf(proto); - } - if (!proto && obj[ADD_EVENT_LISTENER]) { - // somehow we did not find it, but we can see it. This happens on IE for Window properties. - proto = obj; - } - if (!proto) { - return false; - } - if (proto[zoneSymbolAddEventListener]) { - return false; - } - const eventNameToString = patchOptions && patchOptions.eventNameToString; - // a shared global taskData to pass data for scheduleEventTask - // so we do not need to create a new object just for pass some data - const taskData = {}; - const nativeAddEventListener = proto[zoneSymbolAddEventListener] = proto[ADD_EVENT_LISTENER]; - const nativeRemoveEventListener = proto[zoneSymbol(REMOVE_EVENT_LISTENER)] = - proto[REMOVE_EVENT_LISTENER]; - const nativeListeners = proto[zoneSymbol(LISTENERS_EVENT_LISTENER)] = - proto[LISTENERS_EVENT_LISTENER]; - const nativeRemoveAllListeners = proto[zoneSymbol(REMOVE_ALL_LISTENERS_EVENT_LISTENER)] = - proto[REMOVE_ALL_LISTENERS_EVENT_LISTENER]; - let nativePrependEventListener; - if (patchOptions && patchOptions.prepend) { - nativePrependEventListener = proto[zoneSymbol(patchOptions.prepend)] = - proto[patchOptions.prepend]; - } - /** - * This util function will build an option object with passive option - * to handle all possible input from the user. - */ - function buildEventListenerOptions(options, passive) { - if (!passiveSupported && typeof options === 'object' && options) { - // doesn't support passive but user want to pass an object as options. - // this will not work on some old browser, so we just pass a boolean - // as useCapture parameter - return !!options.capture; - } - if (!passiveSupported || !passive) { - return options; - } - if (typeof options === 'boolean') { - return { capture: options, passive: true }; - } - if (!options) { - return { passive: true }; - } - if (typeof options === 'object' && options.passive !== false) { - return Object.assign(Object.assign({}, options), { passive: true }); - } - return options; - } - const customScheduleGlobal = function (task) { - // if there is already a task for the eventName + capture, - // just return, because we use the shared globalZoneAwareCallback here. - if (taskData.isExisting) { - return; - } - return nativeAddEventListener.call(taskData.target, taskData.eventName, taskData.capture ? globalZoneAwareCaptureCallback : globalZoneAwareCallback, taskData.options); - }; - const customCancelGlobal = function (task) { - // if task is not marked as isRemoved, this call is directly - // from Zone.prototype.cancelTask, we should remove the task - // from tasksList of target first - if (!task.isRemoved) { - const symbolEventNames = zoneSymbolEventNames[task.eventName]; - let symbolEventName; - if (symbolEventNames) { - symbolEventName = symbolEventNames[task.capture ? TRUE_STR : FALSE_STR]; - } - const existingTasks = symbolEventName && task.target[symbolEventName]; - if (existingTasks) { - for (let i = 0; i < existingTasks.length; i++) { - const existingTask = existingTasks[i]; - if (existingTask === task) { - existingTasks.splice(i, 1); - // set isRemoved to data for faster invokeTask check - task.isRemoved = true; - if (existingTasks.length === 0) { - // all tasks for the eventName + capture have gone, - // remove globalZoneAwareCallback and remove the task cache from target - task.allRemoved = true; - task.target[symbolEventName] = null; - } - break; - } - } - } - } - // if all tasks for the eventName + capture have gone, - // we will really remove the global event callback, - // if not, return - if (!task.allRemoved) { - return; - } - return nativeRemoveEventListener.call(task.target, task.eventName, task.capture ? globalZoneAwareCaptureCallback : globalZoneAwareCallback, task.options); - }; - const customScheduleNonGlobal = function (task) { - return nativeAddEventListener.call(taskData.target, taskData.eventName, task.invoke, taskData.options); - }; - const customSchedulePrepend = function (task) { - return nativePrependEventListener.call(taskData.target, taskData.eventName, task.invoke, taskData.options); - }; - const customCancelNonGlobal = function (task) { - return nativeRemoveEventListener.call(task.target, task.eventName, task.invoke, task.options); - }; - const customSchedule = useGlobalCallback ? customScheduleGlobal : customScheduleNonGlobal; - const customCancel = useGlobalCallback ? customCancelGlobal : customCancelNonGlobal; - const compareTaskCallbackVsDelegate = function (task, delegate) { - const typeOfDelegate = typeof delegate; - return (typeOfDelegate === 'function' && task.callback === delegate) || - (typeOfDelegate === 'object' && task.originalDelegate === delegate); - }; - const compare = (patchOptions && patchOptions.diff) ? patchOptions.diff : compareTaskCallbackVsDelegate; - const unpatchedEvents = Zone[zoneSymbol('UNPATCHED_EVENTS')]; - const passiveEvents = _global[zoneSymbol('PASSIVE_EVENTS')]; - const makeAddListener = function (nativeListener, addSource, customScheduleFn, customCancelFn, returnTarget = false, prepend = false) { - return function () { - const target = this || _global; - let eventName = arguments[0]; - if (patchOptions && patchOptions.transferEventName) { - eventName = patchOptions.transferEventName(eventName); - } - let delegate = arguments[1]; - if (!delegate) { - return nativeListener.apply(this, arguments); - } - if (isNode && eventName === 'uncaughtException') { - // don't patch uncaughtException of nodejs to prevent endless loop - return nativeListener.apply(this, arguments); - } - // don't create the bind delegate function for handleEvent - // case here to improve addEventListener performance - // we will create the bind delegate when invoke - let isHandleEvent = false; - if (typeof delegate !== 'function') { - if (!delegate.handleEvent) { - return nativeListener.apply(this, arguments); - } - isHandleEvent = true; - } - if (validateHandler && !validateHandler(nativeListener, delegate, target, arguments)) { - return; - } - const passive = passiveSupported && !!passiveEvents && passiveEvents.indexOf(eventName) !== -1; - const options = buildEventListenerOptions(arguments[2], passive); - if (unpatchedEvents) { - // check unpatched list - for (let i = 0; i < unpatchedEvents.length; i++) { - if (eventName === unpatchedEvents[i]) { - if (passive) { - return nativeListener.call(target, eventName, delegate, options); - } - else { - return nativeListener.apply(this, arguments); - } - } - } - } - const capture = !options ? false : typeof options === 'boolean' ? true : options.capture; - const once = options && typeof options === 'object' ? options.once : false; - const zone = Zone.current; - let symbolEventNames = zoneSymbolEventNames[eventName]; - if (!symbolEventNames) { - prepareEventNames(eventName, eventNameToString); - symbolEventNames = zoneSymbolEventNames[eventName]; - } - const symbolEventName = symbolEventNames[capture ? TRUE_STR : FALSE_STR]; - let existingTasks = target[symbolEventName]; - let isExisting = false; - if (existingTasks) { - // already have task registered - isExisting = true; - if (checkDuplicate) { - for (let i = 0; i < existingTasks.length; i++) { - if (compare(existingTasks[i], delegate)) { - // same callback, same capture, same event name, just return - return; - } - } - } - } - else { - existingTasks = target[symbolEventName] = []; - } - let source; - const constructorName = target.constructor['name']; - const targetSource = globalSources[constructorName]; - if (targetSource) { - source = targetSource[eventName]; - } - if (!source) { - source = constructorName + addSource + - (eventNameToString ? eventNameToString(eventName) : eventName); - } - // do not create a new object as task.data to pass those things - // just use the global shared one - taskData.options = options; - if (once) { - // if addEventListener with once options, we don't pass it to - // native addEventListener, instead we keep the once setting - // and handle ourselves. - taskData.options.once = false; - } - taskData.target = target; - taskData.capture = capture; - taskData.eventName = eventName; - taskData.isExisting = isExisting; - const data = useGlobalCallback ? OPTIMIZED_ZONE_EVENT_TASK_DATA : undefined; - // keep taskData into data to allow onScheduleEventTask to access the task information - if (data) { - data.taskData = taskData; - } - const task = zone.scheduleEventTask(source, delegate, data, customScheduleFn, customCancelFn); - // should clear taskData.target to avoid memory leak - // issue, https://github.com/angular/angular/issues/20442 - taskData.target = null; - // need to clear up taskData because it is a global object - if (data) { - data.taskData = null; - } - // have to save those information to task in case - // application may call task.zone.cancelTask() directly - if (once) { - options.once = true; - } - if (!(!passiveSupported && typeof task.options === 'boolean')) { - // if not support passive, and we pass an option object - // to addEventListener, we should save the options to task - task.options = options; - } - task.target = target; - task.capture = capture; - task.eventName = eventName; - if (isHandleEvent) { - // save original delegate for compare to check duplicate - task.originalDelegate = delegate; - } - if (!prepend) { - existingTasks.push(task); - } - else { - existingTasks.unshift(task); - } - if (returnTarget) { - return target; - } - }; - }; - proto[ADD_EVENT_LISTENER] = makeAddListener(nativeAddEventListener, ADD_EVENT_LISTENER_SOURCE, customSchedule, customCancel, returnTarget); - if (nativePrependEventListener) { - proto[PREPEND_EVENT_LISTENER] = makeAddListener(nativePrependEventListener, PREPEND_EVENT_LISTENER_SOURCE, customSchedulePrepend, customCancel, returnTarget, true); - } - proto[REMOVE_EVENT_LISTENER] = function () { - const target = this || _global; - let eventName = arguments[0]; - if (patchOptions && patchOptions.transferEventName) { - eventName = patchOptions.transferEventName(eventName); - } - const options = arguments[2]; - const capture = !options ? false : typeof options === 'boolean' ? true : options.capture; - const delegate = arguments[1]; - if (!delegate) { - return nativeRemoveEventListener.apply(this, arguments); - } - if (validateHandler && - !validateHandler(nativeRemoveEventListener, delegate, target, arguments)) { - return; - } - const symbolEventNames = zoneSymbolEventNames[eventName]; - let symbolEventName; - if (symbolEventNames) { - symbolEventName = symbolEventNames[capture ? TRUE_STR : FALSE_STR]; - } - const existingTasks = symbolEventName && target[symbolEventName]; - if (existingTasks) { - for (let i = 0; i < existingTasks.length; i++) { - const existingTask = existingTasks[i]; - if (compare(existingTask, delegate)) { - existingTasks.splice(i, 1); - // set isRemoved to data for faster invokeTask check - existingTask.isRemoved = true; - if (existingTasks.length === 0) { - // all tasks for the eventName + capture have gone, - // remove globalZoneAwareCallback and remove the task cache from target - existingTask.allRemoved = true; - target[symbolEventName] = null; - // in the target, we have an event listener which is added by on_property - // such as target.onclick = function() {}, so we need to clear this internal - // property too if all delegates all removed - if (typeof eventName === 'string') { - const onPropertySymbol = ZONE_SYMBOL_PREFIX + 'ON_PROPERTY' + eventName; - target[onPropertySymbol] = null; - } - } - existingTask.zone.cancelTask(existingTask); - if (returnTarget) { - return target; - } - return; - } - } - } - // issue 930, didn't find the event name or callback - // from zone kept existingTasks, the callback maybe - // added outside of zone, we need to call native removeEventListener - // to try to remove it. - return nativeRemoveEventListener.apply(this, arguments); - }; - proto[LISTENERS_EVENT_LISTENER] = function () { - const target = this || _global; - let eventName = arguments[0]; - if (patchOptions && patchOptions.transferEventName) { - eventName = patchOptions.transferEventName(eventName); - } - const listeners = []; - const tasks = findEventTasks(target, eventNameToString ? eventNameToString(eventName) : eventName); - for (let i = 0; i < tasks.length; i++) { - const task = tasks[i]; - let delegate = task.originalDelegate ? task.originalDelegate : task.callback; - listeners.push(delegate); - } - return listeners; - }; - proto[REMOVE_ALL_LISTENERS_EVENT_LISTENER] = function () { - const target = this || _global; - let eventName = arguments[0]; - if (!eventName) { - const keys = Object.keys(target); - for (let i = 0; i < keys.length; i++) { - const prop = keys[i]; - const match = EVENT_NAME_SYMBOL_REGX.exec(prop); - let evtName = match && match[1]; - // in nodejs EventEmitter, removeListener event is - // used for monitoring the removeListener call, - // so just keep removeListener eventListener until - // all other eventListeners are removed - if (evtName && evtName !== 'removeListener') { - this[REMOVE_ALL_LISTENERS_EVENT_LISTENER].call(this, evtName); - } - } - // remove removeListener listener finally - this[REMOVE_ALL_LISTENERS_EVENT_LISTENER].call(this, 'removeListener'); - } - else { - if (patchOptions && patchOptions.transferEventName) { - eventName = patchOptions.transferEventName(eventName); - } - const symbolEventNames = zoneSymbolEventNames[eventName]; - if (symbolEventNames) { - const symbolEventName = symbolEventNames[FALSE_STR]; - const symbolCaptureEventName = symbolEventNames[TRUE_STR]; - const tasks = target[symbolEventName]; - const captureTasks = target[symbolCaptureEventName]; - if (tasks) { - const removeTasks = tasks.slice(); - for (let i = 0; i < removeTasks.length; i++) { - const task = removeTasks[i]; - let delegate = task.originalDelegate ? task.originalDelegate : task.callback; - this[REMOVE_EVENT_LISTENER].call(this, eventName, delegate, task.options); - } - } - if (captureTasks) { - const removeTasks = captureTasks.slice(); - for (let i = 0; i < removeTasks.length; i++) { - const task = removeTasks[i]; - let delegate = task.originalDelegate ? task.originalDelegate : task.callback; - this[REMOVE_EVENT_LISTENER].call(this, eventName, delegate, task.options); - } - } - } - } - if (returnTarget) { - return this; - } - }; - // for native toString patch - attachOriginToPatched(proto[ADD_EVENT_LISTENER], nativeAddEventListener); - attachOriginToPatched(proto[REMOVE_EVENT_LISTENER], nativeRemoveEventListener); - if (nativeRemoveAllListeners) { - attachOriginToPatched(proto[REMOVE_ALL_LISTENERS_EVENT_LISTENER], nativeRemoveAllListeners); - } - if (nativeListeners) { - attachOriginToPatched(proto[LISTENERS_EVENT_LISTENER], nativeListeners); - } - return true; - } - let results = []; - for (let i = 0; i < apis.length; i++) { - results[i] = patchEventTargetMethods(apis[i], patchOptions); - } - return results; -} -function findEventTasks(target, eventName) { - if (!eventName) { - const foundTasks = []; - for (let prop in target) { - const match = EVENT_NAME_SYMBOL_REGX.exec(prop); - let evtName = match && match[1]; - if (evtName && (!eventName || evtName === eventName)) { - const tasks = target[prop]; - if (tasks) { - for (let i = 0; i < tasks.length; i++) { - foundTasks.push(tasks[i]); - } - } - } - } - return foundTasks; - } - let symbolEventName = zoneSymbolEventNames[eventName]; - if (!symbolEventName) { - prepareEventNames(eventName); - symbolEventName = zoneSymbolEventNames[eventName]; - } - const captureFalseTasks = target[symbolEventName[FALSE_STR]]; - const captureTrueTasks = target[symbolEventName[TRUE_STR]]; - if (!captureFalseTasks) { - return captureTrueTasks ? captureTrueTasks.slice() : []; - } - else { - return captureTrueTasks ? captureFalseTasks.concat(captureTrueTasks) : - captureFalseTasks.slice(); - } -} -function patchEventPrototype(global, api) { - const Event = global['Event']; - if (Event && Event.prototype) { - api.patchMethod(Event.prototype, 'stopImmediatePropagation', (delegate) => function (self, args) { - self[IMMEDIATE_PROPAGATION_SYMBOL] = true; - // we need to call the native stopImmediatePropagation - // in case in some hybrid application, some part of - // application will be controlled by zone, some are not - delegate && delegate.apply(self, args); - }); - } -} - -/** - * @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 patchCallbacks(api, target, targetName, method, callbacks) { - const symbol = Zone.__symbol__(method); - if (target[symbol]) { - return; - } - const nativeDelegate = target[symbol] = target[method]; - target[method] = function (name, opts, options) { - if (opts && opts.prototype) { - callbacks.forEach(function (callback) { - const source = `${targetName}.${method}::` + callback; - const prototype = opts.prototype; - // Note: the `patchCallbacks` is used for patching the `document.registerElement` and - // `customElements.define`. We explicitly wrap the patching code into try-catch since - // callbacks may be already patched by other web components frameworks (e.g. LWC), and they - // make those properties non-writable. This means that patching callback will throw an error - // `cannot assign to read-only property`. See this code as an example: - // https://github.com/salesforce/lwc/blob/master/packages/@lwc/engine-core/src/framework/base-bridge-element.ts#L180-L186 - // We don't want to stop the application rendering if we couldn't patch some - // callback, e.g. `attributeChangedCallback`. - try { - if (prototype.hasOwnProperty(callback)) { - const descriptor = api.ObjectGetOwnPropertyDescriptor(prototype, callback); - if (descriptor && descriptor.value) { - descriptor.value = api.wrapWithCurrentZone(descriptor.value, source); - api._redefineProperty(opts.prototype, callback, descriptor); - } - else if (prototype[callback]) { - prototype[callback] = api.wrapWithCurrentZone(prototype[callback], source); - } - } - else if (prototype[callback]) { - prototype[callback] = api.wrapWithCurrentZone(prototype[callback], source); - } - } - catch (_a) { - // Note: we leave the catch block empty since there's no way to handle the error related - // to non-writable property. - } - }); - } - return nativeDelegate.call(target, name, opts, options); - }; - api.attachOriginToPatched(target[method], nativeDelegate); -} - -/** - * @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 filterProperties(target, onProperties, ignoreProperties) { - if (!ignoreProperties || ignoreProperties.length === 0) { - return onProperties; - } - const tip = ignoreProperties.filter(ip => ip.target === target); - if (!tip || tip.length === 0) { - return onProperties; - } - const targetIgnoreProperties = tip[0].ignoreProperties; - return onProperties.filter(op => targetIgnoreProperties.indexOf(op) === -1); -} -function patchFilteredProperties(target, onProperties, ignoreProperties, prototype) { - // check whether target is available, sometimes target will be undefined - // because different browser or some 3rd party plugin. - if (!target) { - return; - } - const filteredProperties = filterProperties(target, onProperties, ignoreProperties); - patchOnProperties(target, filteredProperties, prototype); -} -/** - * Get all event name properties which the event name startsWith `on` - * from the target object itself, inherited properties are not considered. - */ -function getOnEventNames(target) { - return Object.getOwnPropertyNames(target) - .filter(name => name.startsWith('on') && name.length > 2) - .map(name => name.substring(2)); -} -function propertyDescriptorPatch(api, _global) { - if (isNode && !isMix) { - return; - } - if (Zone[api.symbol('patchEvents')]) { - // events are already been patched by legacy patch. - return; - } - const ignoreProperties = _global['__Zone_ignore_on_properties']; - // for browsers that we can patch the descriptor: Chrome & Firefox - let patchTargets = []; - if (isBrowser) { - const internalWindow = window; - patchTargets = patchTargets.concat([ - 'Document', 'SVGElement', 'Element', 'HTMLElement', 'HTMLBodyElement', 'HTMLMediaElement', - 'HTMLFrameSetElement', 'HTMLFrameElement', 'HTMLIFrameElement', 'HTMLMarqueeElement', 'Worker' - ]); - const ignoreErrorProperties = isIE() ? [{ target: internalWindow, ignoreProperties: ['error'] }] : []; - // in IE/Edge, onProp not exist in window object, but in WindowPrototype - // so we need to pass WindowPrototype to check onProp exist or not - patchFilteredProperties(internalWindow, getOnEventNames(internalWindow), ignoreProperties ? ignoreProperties.concat(ignoreErrorProperties) : ignoreProperties, ObjectGetPrototypeOf(internalWindow)); - } - patchTargets = patchTargets.concat([ - 'XMLHttpRequest', 'XMLHttpRequestEventTarget', 'IDBIndex', 'IDBRequest', 'IDBOpenDBRequest', - 'IDBDatabase', 'IDBTransaction', 'IDBCursor', 'WebSocket' - ]); - for (let i = 0; i < patchTargets.length; i++) { - const target = _global[patchTargets[i]]; - target && target.prototype && - patchFilteredProperties(target.prototype, getOnEventNames(target.prototype), ignoreProperties); - } -} - -/** - * @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 - */ -Zone.__load_patch('util', (global, Zone, api) => { - // Collect native event names by looking at properties - // on the global namespace, e.g. 'onclick'. - const eventNames = getOnEventNames(global); - api.patchOnProperties = patchOnProperties; - api.patchMethod = patchMethod; - api.bindArguments = bindArguments; - api.patchMacroTask = patchMacroTask; - // In earlier version of zone.js (<0.9.0), we use env name `__zone_symbol__BLACK_LISTED_EVENTS` to - // define which events will not be patched by `Zone.js`. - // In newer version (>=0.9.0), we change the env name to `__zone_symbol__UNPATCHED_EVENTS` to keep - // the name consistent with angular repo. - // The `__zone_symbol__BLACK_LISTED_EVENTS` is deprecated, but it is still be supported for - // backwards compatibility. - const SYMBOL_BLACK_LISTED_EVENTS = Zone.__symbol__('BLACK_LISTED_EVENTS'); - const SYMBOL_UNPATCHED_EVENTS = Zone.__symbol__('UNPATCHED_EVENTS'); - if (global[SYMBOL_UNPATCHED_EVENTS]) { - global[SYMBOL_BLACK_LISTED_EVENTS] = global[SYMBOL_UNPATCHED_EVENTS]; - } - if (global[SYMBOL_BLACK_LISTED_EVENTS]) { - Zone[SYMBOL_BLACK_LISTED_EVENTS] = Zone[SYMBOL_UNPATCHED_EVENTS] = - global[SYMBOL_BLACK_LISTED_EVENTS]; - } - api.patchEventPrototype = patchEventPrototype; - api.patchEventTarget = patchEventTarget; - api.isIEOrEdge = isIEOrEdge; - api.ObjectDefineProperty = ObjectDefineProperty; - api.ObjectGetOwnPropertyDescriptor = ObjectGetOwnPropertyDescriptor; - api.ObjectCreate = ObjectCreate; - api.ArraySlice = ArraySlice; - api.patchClass = patchClass; - api.wrapWithCurrentZone = wrapWithCurrentZone; - api.filterProperties = filterProperties; - api.attachOriginToPatched = attachOriginToPatched; - api._redefineProperty = Object.defineProperty; - api.patchCallbacks = patchCallbacks; - api.getGlobalObjects = () => ({ - globalSources, - zoneSymbolEventNames, - eventNames, - isBrowser, - isMix, - isNode, - TRUE_STR, - FALSE_STR, - ZONE_SYMBOL_PREFIX, - ADD_EVENT_LISTENER_STR, - REMOVE_EVENT_LISTENER_STR - }); -}); - -/** - * @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 - */ -const taskSymbol = zoneSymbol('zoneTask'); -function patchTimer(window, setName, cancelName, nameSuffix) { - let setNative = null; - let clearNative = null; - setName += nameSuffix; - cancelName += nameSuffix; - const tasksByHandleId = {}; - function scheduleTask(task) { - const data = task.data; - data.args[0] = function () { - return task.invoke.apply(this, arguments); - }; - data.handleId = setNative.apply(window, data.args); - return task; - } - function clearTask(task) { - return clearNative.call(window, task.data.handleId); - } - setNative = - patchMethod(window, setName, (delegate) => function (self, args) { - if (typeof args[0] === 'function') { - const options = { - isPeriodic: nameSuffix === 'Interval', - delay: (nameSuffix === 'Timeout' || nameSuffix === 'Interval') ? args[1] || 0 : - undefined, - args: args - }; - const callback = args[0]; - args[0] = function timer() { - try { - return callback.apply(this, arguments); - } - finally { - // issue-934, task will be cancelled - // even it is a periodic task such as - // setInterval - // https://github.com/angular/angular/issues/40387 - // Cleanup tasksByHandleId should be handled before scheduleTask - // Since some zoneSpec may intercept and doesn't trigger - // scheduleFn(scheduleTask) provided here. - if (!(options.isPeriodic)) { - if (typeof options.handleId === 'number') { - // in non-nodejs env, we remove timerId - // from local cache - delete tasksByHandleId[options.handleId]; - } - else if (options.handleId) { - // Node returns complex objects as handleIds - // we remove task reference from timer object - options.handleId[taskSymbol] = null; - } - } - } - }; - const task = scheduleMacroTaskWithCurrentZone(setName, args[0], options, scheduleTask, clearTask); - if (!task) { - return task; - } - // Node.js must additionally support the ref and unref functions. - const handle = task.data.handleId; - if (typeof handle === 'number') { - // for non nodejs env, we save handleId: task - // mapping in local cache for clearTimeout - tasksByHandleId[handle] = task; - } - else if (handle) { - // for nodejs env, we save task - // reference in timerId Object for clearTimeout - handle[taskSymbol] = task; - } - // check whether handle is null, because some polyfill or browser - // may return undefined from setTimeout/setInterval/setImmediate/requestAnimationFrame - if (handle && handle.ref && handle.unref && typeof handle.ref === 'function' && - typeof handle.unref === 'function') { - task.ref = handle.ref.bind(handle); - task.unref = handle.unref.bind(handle); - } - if (typeof handle === 'number' || handle) { - return handle; - } - return task; - } - else { - // cause an error by calling it directly. - return delegate.apply(window, args); - } - }); - clearNative = - patchMethod(window, cancelName, (delegate) => function (self, args) { - const id = args[0]; - let task; - if (typeof id === 'number') { - // non nodejs env. - task = tasksByHandleId[id]; - } - else { - // nodejs env. - task = id && id[taskSymbol]; - // other environments. - if (!task) { - task = id; - } - } - if (task && typeof task.type === 'string') { - if (task.state !== 'notScheduled' && - (task.cancelFn && task.data.isPeriodic || task.runCount === 0)) { - if (typeof id === 'number') { - delete tasksByHandleId[id]; - } - else if (id) { - id[taskSymbol] = null; - } - // Do not cancel already canceled functions - task.zone.cancelTask(task); - } - } - else { - // cause an error by calling it directly. - delegate.apply(window, args); - } - }); -} - -/** - * @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 patchCustomElements(_global, api) { - const { isBrowser, isMix } = api.getGlobalObjects(); - if ((!isBrowser && !isMix) || !_global['customElements'] || !('customElements' in _global)) { - return; - } - const callbacks = ['connectedCallback', 'disconnectedCallback', 'adoptedCallback', 'attributeChangedCallback']; - api.patchCallbacks(api, _global.customElements, 'customElements', 'define', callbacks); -} - -/** - * @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 eventTargetPatch(_global, api) { - if (Zone[api.symbol('patchEventTarget')]) { - // EventTarget is already patched. - return; - } - const { eventNames, zoneSymbolEventNames, TRUE_STR, FALSE_STR, ZONE_SYMBOL_PREFIX } = api.getGlobalObjects(); - // predefine all __zone_symbol__ + eventName + true/false string - for (let i = 0; i < eventNames.length; i++) { - const eventName = eventNames[i]; - const falseEventName = eventName + FALSE_STR; - const trueEventName = eventName + TRUE_STR; - const symbol = ZONE_SYMBOL_PREFIX + falseEventName; - const symbolCapture = ZONE_SYMBOL_PREFIX + trueEventName; - zoneSymbolEventNames[eventName] = {}; - zoneSymbolEventNames[eventName][FALSE_STR] = symbol; - zoneSymbolEventNames[eventName][TRUE_STR] = symbolCapture; - } - const EVENT_TARGET = _global['EventTarget']; - if (!EVENT_TARGET || !EVENT_TARGET.prototype) { - return; - } - api.patchEventTarget(_global, api, [EVENT_TARGET && EVENT_TARGET.prototype]); - return true; -} -function patchEvent(global, api) { - api.patchEventPrototype(global, api); -} - -/** - * @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 - */ -Zone.__load_patch('legacy', (global) => { - const legacyPatch = global[Zone.__symbol__('legacyPatch')]; - if (legacyPatch) { - legacyPatch(); - } -}); -Zone.__load_patch('queueMicrotask', (global, Zone, api) => { - api.patchMethod(global, 'queueMicrotask', delegate => { - return function (self, args) { - Zone.current.scheduleMicroTask('queueMicrotask', args[0]); - }; - }); -}); -Zone.__load_patch('timers', (global) => { - const set = 'set'; - const clear = 'clear'; - patchTimer(global, set, clear, 'Timeout'); - patchTimer(global, set, clear, 'Interval'); - patchTimer(global, set, clear, 'Immediate'); -}); -Zone.__load_patch('requestAnimationFrame', (global) => { - patchTimer(global, 'request', 'cancel', 'AnimationFrame'); - patchTimer(global, 'mozRequest', 'mozCancel', 'AnimationFrame'); - patchTimer(global, 'webkitRequest', 'webkitCancel', 'AnimationFrame'); -}); -Zone.__load_patch('blocking', (global, Zone) => { - const blockingMethods = ['alert', 'prompt', 'confirm']; - for (let i = 0; i < blockingMethods.length; i++) { - const name = blockingMethods[i]; - patchMethod(global, name, (delegate, symbol, name) => { - return function (s, args) { - return Zone.current.run(delegate, global, args, name); - }; - }); - } -}); -Zone.__load_patch('EventTarget', (global, Zone, api) => { - patchEvent(global, api); - eventTargetPatch(global, api); - // patch XMLHttpRequestEventTarget's addEventListener/removeEventListener - const XMLHttpRequestEventTarget = global['XMLHttpRequestEventTarget']; - if (XMLHttpRequestEventTarget && XMLHttpRequestEventTarget.prototype) { - api.patchEventTarget(global, api, [XMLHttpRequestEventTarget.prototype]); - } -}); -Zone.__load_patch('MutationObserver', (global, Zone, api) => { - patchClass('MutationObserver'); - patchClass('WebKitMutationObserver'); -}); -Zone.__load_patch('IntersectionObserver', (global, Zone, api) => { - patchClass('IntersectionObserver'); -}); -Zone.__load_patch('FileReader', (global, Zone, api) => { - patchClass('FileReader'); -}); -Zone.__load_patch('on_property', (global, Zone, api) => { - propertyDescriptorPatch(api, global); -}); -Zone.__load_patch('customElements', (global, Zone, api) => { - patchCustomElements(global, api); -}); -Zone.__load_patch('XHR', (global, Zone) => { - // Treat XMLHttpRequest as a macrotask. - patchXHR(global); - const XHR_TASK = zoneSymbol('xhrTask'); - const XHR_SYNC = zoneSymbol('xhrSync'); - const XHR_LISTENER = zoneSymbol('xhrListener'); - const XHR_SCHEDULED = zoneSymbol('xhrScheduled'); - const XHR_URL = zoneSymbol('xhrURL'); - const XHR_ERROR_BEFORE_SCHEDULED = zoneSymbol('xhrErrorBeforeScheduled'); - function patchXHR(window) { - const XMLHttpRequest = window['XMLHttpRequest']; - if (!XMLHttpRequest) { - // XMLHttpRequest is not available in service worker - return; - } - const XMLHttpRequestPrototype = XMLHttpRequest.prototype; - function findPendingTask(target) { - return target[XHR_TASK]; - } - let oriAddListener = XMLHttpRequestPrototype[ZONE_SYMBOL_ADD_EVENT_LISTENER]; - let oriRemoveListener = XMLHttpRequestPrototype[ZONE_SYMBOL_REMOVE_EVENT_LISTENER]; - if (!oriAddListener) { - const XMLHttpRequestEventTarget = window['XMLHttpRequestEventTarget']; - if (XMLHttpRequestEventTarget) { - const XMLHttpRequestEventTargetPrototype = XMLHttpRequestEventTarget.prototype; - oriAddListener = XMLHttpRequestEventTargetPrototype[ZONE_SYMBOL_ADD_EVENT_LISTENER]; - oriRemoveListener = XMLHttpRequestEventTargetPrototype[ZONE_SYMBOL_REMOVE_EVENT_LISTENER]; - } - } - const READY_STATE_CHANGE = 'readystatechange'; - const SCHEDULED = 'scheduled'; - function scheduleTask(task) { - const data = task.data; - const target = data.target; - target[XHR_SCHEDULED] = false; - target[XHR_ERROR_BEFORE_SCHEDULED] = false; - // remove existing event listener - const listener = target[XHR_LISTENER]; - if (!oriAddListener) { - oriAddListener = target[ZONE_SYMBOL_ADD_EVENT_LISTENER]; - oriRemoveListener = target[ZONE_SYMBOL_REMOVE_EVENT_LISTENER]; - } - if (listener) { - oriRemoveListener.call(target, READY_STATE_CHANGE, listener); - } - const newListener = target[XHR_LISTENER] = () => { - if (target.readyState === target.DONE) { - // sometimes on some browsers XMLHttpRequest will fire onreadystatechange with - // readyState=4 multiple times, so we need to check task state here - if (!data.aborted && target[XHR_SCHEDULED] && task.state === SCHEDULED) { - // check whether the xhr has registered onload listener - // if that is the case, the task should invoke after all - // onload listeners finish. - // Also if the request failed without response (status = 0), the load event handler - // will not be triggered, in that case, we should also invoke the placeholder callback - // to close the XMLHttpRequest::send macroTask. - // https://github.com/angular/angular/issues/38795 - const loadTasks = target[Zone.__symbol__('loadfalse')]; - if (target.status !== 0 && loadTasks && loadTasks.length > 0) { - const oriInvoke = task.invoke; - task.invoke = function () { - // need to load the tasks again, because in other - // load listener, they may remove themselves - const loadTasks = target[Zone.__symbol__('loadfalse')]; - for (let i = 0; i < loadTasks.length; i++) { - if (loadTasks[i] === task) { - loadTasks.splice(i, 1); - } - } - if (!data.aborted && task.state === SCHEDULED) { - oriInvoke.call(task); - } - }; - loadTasks.push(task); - } - else { - task.invoke(); - } - } - else if (!data.aborted && target[XHR_SCHEDULED] === false) { - // error occurs when xhr.send() - target[XHR_ERROR_BEFORE_SCHEDULED] = true; - } - } - }; - oriAddListener.call(target, READY_STATE_CHANGE, newListener); - const storedTask = target[XHR_TASK]; - if (!storedTask) { - target[XHR_TASK] = task; - } - sendNative.apply(target, data.args); - target[XHR_SCHEDULED] = true; - return task; - } - function placeholderCallback() { } - function clearTask(task) { - const data = task.data; - // Note - ideally, we would call data.target.removeEventListener here, but it's too late - // to prevent it from firing. So instead, we store info for the event listener. - data.aborted = true; - return abortNative.apply(data.target, data.args); - } - const openNative = patchMethod(XMLHttpRequestPrototype, 'open', () => function (self, args) { - self[XHR_SYNC] = args[2] == false; - self[XHR_URL] = args[1]; - return openNative.apply(self, args); - }); - const XMLHTTPREQUEST_SOURCE = 'XMLHttpRequest.send'; - const fetchTaskAborting = zoneSymbol('fetchTaskAborting'); - const fetchTaskScheduling = zoneSymbol('fetchTaskScheduling'); - const sendNative = patchMethod(XMLHttpRequestPrototype, 'send', () => function (self, args) { - if (Zone.current[fetchTaskScheduling] === true) { - // a fetch is scheduling, so we are using xhr to polyfill fetch - // and because we already schedule macroTask for fetch, we should - // not schedule a macroTask for xhr again - return sendNative.apply(self, args); - } - if (self[XHR_SYNC]) { - // if the XHR is sync there is no task to schedule, just execute the code. - return sendNative.apply(self, args); - } - else { - const options = { target: self, url: self[XHR_URL], isPeriodic: false, args: args, aborted: false }; - const task = scheduleMacroTaskWithCurrentZone(XMLHTTPREQUEST_SOURCE, placeholderCallback, options, scheduleTask, clearTask); - if (self && self[XHR_ERROR_BEFORE_SCHEDULED] === true && !options.aborted && - task.state === SCHEDULED) { - // xhr request throw error when send - // we should invoke task instead of leaving a scheduled - // pending macroTask - task.invoke(); - } - } - }); - const abortNative = patchMethod(XMLHttpRequestPrototype, 'abort', () => function (self, args) { - const task = findPendingTask(self); - if (task && typeof task.type == 'string') { - // If the XHR has already completed, do nothing. - // If the XHR has already been aborted, do nothing. - // Fix #569, call abort multiple times before done will cause - // macroTask task count be negative number - if (task.cancelFn == null || (task.data && task.data.aborted)) { - return; - } - task.zone.cancelTask(task); - } - else if (Zone.current[fetchTaskAborting] === true) { - // the abort is called from fetch polyfill, we need to call native abort of XHR. - return abortNative.apply(self, args); - } - // Otherwise, we are trying to abort an XHR which has not yet been sent, so there is no - // task - // to cancel. Do nothing. - }); - } -}); -Zone.__load_patch('geolocation', (global) => { - /// GEO_LOCATION - if (global['navigator'] && global['navigator'].geolocation) { - patchPrototype(global['navigator'].geolocation, ['getCurrentPosition', 'watchPosition']); - } -}); -Zone.__load_patch('PromiseRejectionEvent', (global, Zone) => { - // handle unhandled promise rejection - function findPromiseRejectionHandler(evtName) { - return function (e) { - const eventTasks = findEventTasks(global, evtName); - eventTasks.forEach(eventTask => { - // windows has added unhandledrejection event listener - // trigger the event listener - const PromiseRejectionEvent = global['PromiseRejectionEvent']; - if (PromiseRejectionEvent) { - const evt = new PromiseRejectionEvent(evtName, { promise: e.promise, reason: e.rejection }); - eventTask.invoke(evt); - } - }); - }; - } - if (global['PromiseRejectionEvent']) { - Zone[zoneSymbol('unhandledPromiseRejectionHandler')] = - findPromiseRejectionHandler('unhandledrejection'); - Zone[zoneSymbol('rejectionHandledHandler')] = - findPromiseRejectionHandler('rejectionhandled'); - } -}); - - -/***/ }), - -/***/ "vU8d": -/*!************************************************************************************!*\ - !*** ./node_modules/@webcomponents/webcomponentsjs/custom-elements-es5-adapter.js ***! - \************************************************************************************/ -/*! no static exports found */ -/***/ (function(module, exports) { - -/** -@license @nocompile -Copyright (c) 2018 The Polymer Project Authors. All rights reserved. -This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt -The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt -The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt -Code distributed by Google as part of the polymer project is also -subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt -*/ -(function () { - 'use strict'; - - (function(){if(void 0===window.Reflect||void 0===window.customElements||window.customElements.polyfillWrapFlushCallback)return;const a=HTMLElement;window.HTMLElement={HTMLElement:function HTMLElement(){return Reflect.construct(a,[],this.constructor)}}.HTMLElement,HTMLElement.prototype=a.prototype,HTMLElement.prototype.constructor=HTMLElement,Object.setPrototypeOf(HTMLElement,a);})(); - -}()); - - -/***/ }) - -},[[1,"runtime"]]]); -(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["main"],{ - -/***/ "/d8p": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/repeat.js ***! - \*****************************************************************/ -/*! exports provided: repeat */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _observable_empty__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../observable/empty */ "EY2u"); - - -function repeat(count = -1) { - return (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)); - } - }; -} -class RepeatOperator { - constructor(count, source) { - this.count = count; - this.source = source; - } - call(subscriber, source) { - return source.subscribe(new RepeatSubscriber(subscriber, this.count, this.source)); - } -} -class RepeatSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, count, source) { - super(destination); - this.count = count; - this.source = source; - } - complete() { - if (!this.isStopped) { - const { source, count } = this; - if (count === 0) { - return super.complete(); - } - else if (count > -1) { - this.count = count - 1; - } - source.subscribe(this._unsubscribeAndRecycle()); - } - } -} -//# sourceMappingURL=repeat.js.map - - -/***/ }), - -/***/ "/uUt": -/*!*******************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/distinctUntilChanged.js ***! - \*******************************************************************************/ -/*! exports provided: distinctUntilChanged */ -/***/ (function(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 */ "7o/Q"); - -function distinctUntilChanged(compare, keySelector) { - return (source) => source.lift(new DistinctUntilChangedOperator(compare, keySelector)); -} -class DistinctUntilChangedOperator { - constructor(compare, keySelector) { - this.compare = compare; - this.keySelector = keySelector; - } - call(subscriber, source) { - return source.subscribe(new DistinctUntilChangedSubscriber(subscriber, this.compare, this.keySelector)); - } -} -class DistinctUntilChangedSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, compare, keySelector) { - super(destination); - this.keySelector = keySelector; - this.hasKey = false; - if (typeof compare === 'function') { - this.compare = compare; - } - } - compare(x, y) { - return x === y; - } - _next(value) { - let key; - try { - const { keySelector } = this; - key = keySelector ? keySelector(value) : value; - } - catch (err) { - return this.destination.error(err); - } - let result = false; - if (this.hasKey) { - try { - const { compare } = this; - 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); - } - } -} -//# sourceMappingURL=distinctUntilChanged.js.map - - -/***/ }), - -/***/ 0: -/*!***************************!*\ - !*** multi ./src/main.ts ***! - \***************************/ -/*! no static exports found */ -/***/ (function(module, exports, __webpack_require__) { - -module.exports = __webpack_require__(/*! C:\devel\checkout\modus-icons\app-components\src\main.ts */"zUnb"); - - -/***/ }), - -/***/ "02Lk": -/*!*******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/distinct.js ***! - \*******************************************************************/ -/*! exports provided: distinct, DistinctSubscriber */ -/***/ (function(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 _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - -function distinct(keySelector, flushes) { - return (source) => source.lift(new DistinctOperator(keySelector, flushes)); -} -class DistinctOperator { - constructor(keySelector, flushes) { - this.keySelector = keySelector; - this.flushes = flushes; - } - call(subscriber, source) { - return source.subscribe(new DistinctSubscriber(subscriber, this.keySelector, this.flushes)); - } -} -class DistinctSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleOuterSubscriber"] { - constructor(destination, keySelector, flushes) { - super(destination); - this.keySelector = keySelector; - this.values = new Set(); - if (flushes) { - this.add(Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["innerSubscribe"])(flushes, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleInnerSubscriber"](this))); - } - } - notifyNext() { - this.values.clear(); - } - notifyError(error) { - this._error(error); - } - _next(value) { - if (this.keySelector) { - this._useKeySelector(value); - } - else { - this._finalizeNext(value, value); - } - } - _useKeySelector(value) { - let key; - const { destination } = this; - try { - key = this.keySelector(value); - } - catch (err) { - destination.error(err); - return; - } - this._finalizeNext(key, value); - } - _finalizeNext(key, value) { - const { values } = this; - if (!values.has(key)) { - values.add(key); - this.destination.next(value); - } - } -} -//# sourceMappingURL=distinct.js.map - - -/***/ }), - -/***/ "04ZW": -/*!****************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/fromEventPattern.js ***! - \****************************************************************************/ -/*! exports provided: fromEventPattern */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/isArray */ "DH7j"); -/* harmony import */ var _util_isFunction__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../util/isFunction */ "n6bG"); -/* harmony import */ var _operators_map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../operators/map */ "lJxs"); - - - - -function fromEventPattern(addHandler, removeHandler, resultSelector) { - if (resultSelector) { - return fromEventPattern(addHandler, removeHandler).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_3__["map"])(args => Object(_util_isArray__WEBPACK_IMPORTED_MODULE_1__["isArray"])(args) ? resultSelector(...args) : resultSelector(args))); - } - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - const handler = (...e) => subscriber.next(e.length === 1 ? e[0] : e); - let 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 () => removeHandler(handler, retValue); - }); -} -//# sourceMappingURL=fromEventPattern.js.map - - -/***/ }), - -/***/ "05l1": -/*!************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/publishReplay.js ***! - \************************************************************************/ -/*! exports provided: publishReplay */ -/***/ (function(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 */ "jtHE"); -/* harmony import */ var _multicast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./multicast */ "oB13"); - - -function publishReplay(bufferSize, windowTime, selectorOrScheduler, scheduler) { - if (selectorOrScheduler && typeof selectorOrScheduler !== 'function') { - scheduler = selectorOrScheduler; - } - const selector = typeof selectorOrScheduler === 'function' ? selectorOrScheduler : undefined; - const subject = new _ReplaySubject__WEBPACK_IMPORTED_MODULE_0__["ReplaySubject"](bufferSize, windowTime, scheduler); - return (source) => Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(() => subject, selector)(source); -} -//# sourceMappingURL=publishReplay.js.map - - -/***/ }), - -/***/ "0EUg": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/concatAll.js ***! - \********************************************************************/ -/*! exports provided: concatAll */ -/***/ (function(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 */ "bHdf"); - -function concatAll() { - return Object(_mergeAll__WEBPACK_IMPORTED_MODULE_0__["mergeAll"])(1); -} -//# sourceMappingURL=concatAll.js.map - - -/***/ }), - -/***/ "0Pi8": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/endWith.js ***! - \******************************************************************/ -/*! exports provided: endWith */ -/***/ (function(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 */ "GyhO"); -/* harmony import */ var _observable_of__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../observable/of */ "LRne"); - - -function endWith(...array) { - return (source) => Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"])(source, Object(_observable_of__WEBPACK_IMPORTED_MODULE_1__["of"])(...array)); -} -//# sourceMappingURL=endWith.js.map - - -/***/ }), - -/***/ "128B": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/reduce.js ***! - \*****************************************************************/ -/*! exports provided: reduce */ -/***/ (function(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 */ "Kqap"); -/* harmony import */ var _takeLast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./takeLast */ "BFxc"); -/* harmony import */ var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./defaultIfEmpty */ "xbPD"); -/* harmony import */ var _util_pipe__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/pipe */ "mCNh"); - - - - -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"])((acc, value, index) => accumulator(acc, value, index + 1)), Object(_takeLast__WEBPACK_IMPORTED_MODULE_1__["takeLast"])(1))(source); - }; -} -//# sourceMappingURL=reduce.js.map - - -/***/ }), - -/***/ "1G5W": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/takeUntil.js ***! - \********************************************************************/ -/*! exports provided: takeUntil */ -/***/ (function(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 _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - -function takeUntil(notifier) { - return (source) => source.lift(new TakeUntilOperator(notifier)); -} -class TakeUntilOperator { - constructor(notifier) { - this.notifier = notifier; - } - call(subscriber, source) { - const takeUntilSubscriber = new TakeUntilSubscriber(subscriber); - const notifierSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["innerSubscribe"])(this.notifier, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleInnerSubscriber"](takeUntilSubscriber)); - if (notifierSubscription && !takeUntilSubscriber.seenValue) { - takeUntilSubscriber.add(notifierSubscription); - return source.subscribe(takeUntilSubscriber); - } - return takeUntilSubscriber; - } -} -class TakeUntilSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleOuterSubscriber"] { - constructor(destination) { - super(destination); - this.seenValue = false; - } - notifyNext() { - this.seenValue = true; - this.complete(); - } - notifyComplete() { - } -} -//# sourceMappingURL=takeUntil.js.map - - -/***/ }), - -/***/ "1Ykd": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/sampleTime.js ***! - \*********************************************************************/ -/*! exports provided: sampleTime */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../scheduler/async */ "D0XW"); - - -function sampleTime(period, scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"]) { - return (source) => source.lift(new SampleTimeOperator(period, scheduler)); -} -class SampleTimeOperator { - constructor(period, scheduler) { - this.period = period; - this.scheduler = scheduler; - } - call(subscriber, source) { - return source.subscribe(new SampleTimeSubscriber(subscriber, this.period, this.scheduler)); - } -} -class SampleTimeSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, period, scheduler) { - super(destination); - this.period = period; - this.scheduler = scheduler; - this.hasValue = false; - this.add(scheduler.schedule(dispatchNotification, period, { subscriber: this, period })); - } - _next(value) { - this.lastValue = value; - this.hasValue = true; - } - notifyNext() { - if (this.hasValue) { - this.hasValue = false; - this.destination.next(this.lastValue); - } - } -} -function dispatchNotification(state) { - let { subscriber, period } = state; - subscriber.notifyNext(); - this.schedule(state, period); -} -//# sourceMappingURL=sampleTime.js.map - - -/***/ }), - -/***/ "1uah": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/zip.js ***! - \***************************************************************/ -/*! exports provided: zip, ZipOperator, ZipSubscriber */ -/***/ (function(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 */ "yCtX"); -/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/isArray */ "DH7j"); -/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Subscriber */ "7o/Q"); -/* harmony import */ var _internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../internal/symbol/iterator */ "Lhse"); -/* harmony import */ var _innerSubscribe__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - - - - - -function zip(...observables) { - const 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)); -} -class ZipOperator { - constructor(resultSelector) { - this.resultSelector = resultSelector; - } - call(subscriber, source) { - return source.subscribe(new ZipSubscriber(subscriber, this.resultSelector)); - } -} -class ZipSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"] { - constructor(destination, resultSelector, values = Object.create(null)) { - super(destination); - this.resultSelector = resultSelector; - this.iterators = []; - this.active = 0; - this.resultSelector = (typeof resultSelector === 'function') ? resultSelector : undefined; - } - _next(value) { - const 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_3__["iterator"]] === 'function') { - iterators.push(new StaticIterator(value[_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_3__["iterator"]]())); - } - else { - iterators.push(new ZipBufferIterator(this.destination, this, value)); - } - } - _complete() { - const iterators = this.iterators; - const len = iterators.length; - this.unsubscribe(); - if (len === 0) { - this.destination.complete(); - return; - } - this.active = len; - for (let i = 0; i < len; i++) { - let iterator = iterators[i]; - if (iterator.stillUnsubscribed) { - const destination = this.destination; - destination.add(iterator.subscribe()); - } - else { - this.active--; - } - } - } - notifyInactive() { - this.active--; - if (this.active === 0) { - this.destination.complete(); - } - } - checkIterators() { - const iterators = this.iterators; - const len = iterators.length; - const destination = this.destination; - for (let i = 0; i < len; i++) { - let iterator = iterators[i]; - if (typeof iterator.hasValue === 'function' && !iterator.hasValue()) { - return; - } - } - let shouldComplete = false; - const args = []; - for (let i = 0; i < len; i++) { - let iterator = iterators[i]; - let result = iterator.next(); - if (iterator.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(); - } - } - _tryresultSelector(args) { - let result; - try { - result = this.resultSelector.apply(this, args); - } - catch (err) { - this.destination.error(err); - return; - } - this.destination.next(result); - } -} -class StaticIterator { - constructor(iterator) { - this.iterator = iterator; - this.nextResult = iterator.next(); - } - hasValue() { - return true; - } - next() { - const result = this.nextResult; - this.nextResult = this.iterator.next(); - return result; - } - hasCompleted() { - const nextResult = this.nextResult; - return Boolean(nextResult && nextResult.done); - } -} -class StaticArrayIterator { - constructor(array) { - this.array = array; - this.index = 0; - this.length = 0; - this.length = array.length; - } - [_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_3__["iterator"]]() { - return this; - } - next(value) { - const i = this.index++; - const array = this.array; - return i < this.length ? { value: array[i], done: false } : { value: null, done: true }; - } - hasValue() { - return this.array.length > this.index; - } - hasCompleted() { - return this.array.length === this.index; - } -} -class ZipBufferIterator extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_4__["SimpleOuterSubscriber"] { - constructor(destination, parent, observable) { - super(destination); - this.parent = parent; - this.observable = observable; - this.stillUnsubscribed = true; - this.buffer = []; - this.isComplete = false; - } - [_internal_symbol_iterator__WEBPACK_IMPORTED_MODULE_3__["iterator"]]() { - return this; - } - next() { - const buffer = this.buffer; - if (buffer.length === 0 && this.isComplete) { - return { value: null, done: true }; - } - else { - return { value: buffer.shift(), done: false }; - } - } - hasValue() { - return this.buffer.length > 0; - } - hasCompleted() { - return this.buffer.length === 0 && this.isComplete; - } - notifyComplete() { - if (this.buffer.length > 0) { - this.isComplete = true; - this.parent.notifyInactive(); - } - else { - this.destination.complete(); - } - } - notifyNext(innerValue) { - this.buffer.push(innerValue); - this.parent.checkIterators(); - } - subscribe() { - return Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_4__["innerSubscribe"])(this.observable, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_4__["SimpleInnerSubscriber"](this)); - } -} -//# sourceMappingURL=zip.js.map - - -/***/ }), - -/***/ "2QA8": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/symbol/rxSubscriber.js ***! - \********************************************************************/ -/*! exports provided: rxSubscriber, $$rxSubscriber */ -/***/ (function(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; }); -const rxSubscriber = /*@__PURE__*/ (() => typeof Symbol === 'function' - ? Symbol('rxSubscriber') - : '@@rxSubscriber_' + Math.random())(); -const $$rxSubscriber = rxSubscriber; -//# sourceMappingURL=rxSubscriber.js.map - - -/***/ }), - -/***/ "2QGa": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/partition.js ***! - \*********************************************************************/ -/*! exports provided: partition */ -/***/ (function(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 */ "F97/"); -/* harmony import */ var _util_subscribeTo__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/subscribeTo */ "SeVD"); -/* harmony import */ var _operators_filter__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../operators/filter */ "pLZG"); -/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../Observable */ "HDdC"); - - - - -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 - - -/***/ }), - -/***/ "2Vo4": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/BehaviorSubject.js ***! - \****************************************************************/ -/*! exports provided: BehaviorSubject */ -/***/ (function(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 */ "XNiG"); -/* harmony import */ var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./util/ObjectUnsubscribedError */ "9ppp"); - - -class BehaviorSubject extends _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"] { - constructor(_value) { - super(); - this._value = _value; - } - get value() { - return this.getValue(); - } - _subscribe(subscriber) { - const subscription = super._subscribe(subscriber); - if (subscription && !subscription.closed) { - subscriber.next(this._value); - } - return subscription; - } - getValue() { - if (this.hasError) { - throw this.thrownError; - } - else if (this.closed) { - throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_1__["ObjectUnsubscribedError"](); - } - else { - return this._value; - } - } - next(value) { - super.next(this._value = value); - } -} -//# sourceMappingURL=BehaviorSubject.js.map - - -/***/ }), - -/***/ "2fFW": -/*!*******************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/config.js ***! - \*******************************************************/ -/*! exports provided: config */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "config", function() { return config; }); -let _enable_super_gross_mode_that_will_cause_bad_things = false; -const config = { - Promise: undefined, - set useDeprecatedSynchronousErrorHandling(value) { - if (value) { - const 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 - - -/***/ }), - -/***/ "32Ea": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/skipWhile.js ***! - \********************************************************************/ -/*! exports provided: skipWhile */ -/***/ (function(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 */ "7o/Q"); - -function skipWhile(predicate) { - return (source) => source.lift(new SkipWhileOperator(predicate)); -} -class SkipWhileOperator { - constructor(predicate) { - this.predicate = predicate; - } - call(subscriber, source) { - return source.subscribe(new SkipWhileSubscriber(subscriber, this.predicate)); - } -} -class SkipWhileSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, predicate) { - super(destination); - this.predicate = predicate; - this.skipping = true; - this.index = 0; - } - _next(value) { - const destination = this.destination; - if (this.skipping) { - this.tryCallPredicate(value); - } - if (!this.skipping) { - destination.next(value); - } - } - tryCallPredicate(value) { - try { - const result = this.predicate(value, this.index++); - this.skipping = Boolean(result); - } - catch (err) { - this.destination.error(err); - } - } -} -//# sourceMappingURL=skipWhile.js.map - - -/***/ }), - -/***/ "3E0/": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/delay.js ***! - \****************************************************************/ -/*! exports provided: delay */ -/***/ (function(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 */ "D0XW"); -/* harmony import */ var _util_isDate__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/isDate */ "mlxB"); -/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Subscriber */ "7o/Q"); -/* harmony import */ var _Notification__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../Notification */ "WMd4"); - - - - -function delay(delay, scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"]) { - const absoluteDelay = Object(_util_isDate__WEBPACK_IMPORTED_MODULE_1__["isDate"])(delay); - const delayFor = absoluteDelay ? (+delay - scheduler.now()) : Math.abs(delay); - return (source) => source.lift(new DelayOperator(delayFor, scheduler)); -} -class DelayOperator { - constructor(delay, scheduler) { - this.delay = delay; - this.scheduler = scheduler; - } - call(subscriber, source) { - return source.subscribe(new DelaySubscriber(subscriber, this.delay, this.scheduler)); - } -} -class DelaySubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"] { - constructor(destination, delay, scheduler) { - super(destination); - this.delay = delay; - this.scheduler = scheduler; - this.queue = []; - this.active = false; - this.errored = false; - } - static dispatch(state) { - const source = state.source; - const queue = source.queue; - const scheduler = state.scheduler; - const destination = state.destination; - while (queue.length > 0 && (queue[0].time - scheduler.now()) <= 0) { - queue.shift().notification.observe(destination); - } - if (queue.length > 0) { - const delay = Math.max(0, queue[0].time - scheduler.now()); - this.schedule(state, delay); - } - else { - this.unsubscribe(); - source.active = false; - } - } - _schedule(scheduler) { - this.active = true; - const destination = this.destination; - destination.add(scheduler.schedule(DelaySubscriber.dispatch, this.delay, { - source: this, destination: this.destination, scheduler: scheduler - })); - } - scheduleNotification(notification) { - if (this.errored === true) { - return; - } - const scheduler = this.scheduler; - const message = new DelayMessage(scheduler.now() + this.delay, notification); - this.queue.push(message); - if (this.active === false) { - this._schedule(scheduler); - } - } - _next(value) { - this.scheduleNotification(_Notification__WEBPACK_IMPORTED_MODULE_3__["Notification"].createNext(value)); - } - _error(err) { - this.errored = true; - this.queue = []; - this.destination.error(err); - this.unsubscribe(); - } - _complete() { - this.scheduleNotification(_Notification__WEBPACK_IMPORTED_MODULE_3__["Notification"].createComplete()); - this.unsubscribe(); - } -} -class DelayMessage { - constructor(time, notification) { - this.time = time; - this.notification = notification; - } -} -//# sourceMappingURL=delay.js.map - - -/***/ }), - -/***/ "3N8a": -/*!**********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js ***! - \**********************************************************************/ -/*! exports provided: AsyncAction */ -/***/ (function(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 */ "7ve7"); - -class AsyncAction extends _Action__WEBPACK_IMPORTED_MODULE_0__["Action"] { - constructor(scheduler, work) { - super(scheduler, work); - this.scheduler = scheduler; - this.work = work; - this.pending = false; - } - schedule(state, delay = 0) { - if (this.closed) { - return this; - } - this.state = state; - const id = this.id; - const 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; - } - requestAsyncId(scheduler, id, delay = 0) { - return setInterval(scheduler.flush.bind(scheduler, this), delay); - } - recycleAsyncId(scheduler, id, delay = 0) { - if (delay !== null && this.delay === delay && this.pending === false) { - return id; - } - clearInterval(id); - return undefined; - } - execute(state, delay) { - if (this.closed) { - return new Error('executing a cancelled action'); - } - this.pending = false; - const 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); - } - } - _execute(state, delay) { - let errored = false; - let errorValue = undefined; - try { - this.work(state); - } - catch (e) { - errored = true; - errorValue = !!e && e || new Error(e); - } - if (errored) { - this.unsubscribe(); - return errorValue; - } - } - _unsubscribe() { - const id = this.id; - const scheduler = this.scheduler; - const actions = scheduler.actions; - const 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; - } -} -//# sourceMappingURL=AsyncAction.js.map - - -/***/ }), - -/***/ "3Pt+": -/*!********************************************************************!*\ - !*** ./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_bf, ɵangular_packages_forms_forms_bg, ɵangular_packages_forms_forms_bh, ɵangular_packages_forms_forms_bi, ɵangular_packages_forms_forms_bj, ɵangular_packages_forms_forms_bk, ɵangular_packages_forms_forms_bl, ɵangular_packages_forms_forms_bm, ɵangular_packages_forms_forms_bn, ɵangular_packages_forms_forms_bo, ɵangular_packages_forms_forms_bp, ɵ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(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 ɵNgNoValidate; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bb", function() { return REQUIRED_VALIDATOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bc", function() { return CHECKBOX_REQUIRED_VALIDATOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bd", function() { return EMAIL_VALIDATOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_be", function() { return MIN_LENGTH_VALIDATOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bf", function() { return MAX_LENGTH_VALIDATOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bg", function() { return PATTERN_VALIDATOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bh", function() { return minValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bi", function() { return maxValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bj", function() { return requiredValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bk", function() { return requiredTrueValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bl", function() { return emailValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bm", function() { return minLengthValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bn", function() { return maxLengthValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bo", function() { return patternValidator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_bp", function() { return nullValidator; }); -/* 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 BuiltInControlValueAccessor; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_g", function() { return DEFAULT_VALUE_ACCESSOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_h", function() { return AbstractControlStatus; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_i", function() { return ngControlStatusHost; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_j", function() { return formDirectiveProvider; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_k", function() { return formControlBinding; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_l", function() { return modelGroupProvider; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_m", function() { return NUMBER_VALUE_ACCESSOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_n", function() { return RADIO_VALUE_ACCESSOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_o", function() { return RadioControlRegistryModule; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_p", function() { return RadioControlRegistry; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_q", function() { return RANGE_VALUE_ACCESSOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_r", function() { return NG_MODEL_WITH_FORM_CONTROL_WARNING; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_s", function() { return formControlBinding$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_t", function() { return controlNameBinding; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_u", function() { return formDirectiveProvider$1; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_v", function() { return formGroupNameProvider; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_w", function() { return formArrayNameProvider; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_x", function() { return SELECT_VALUE_ACCESSOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_y", function() { return SELECT_MULTIPLE_VALUE_ACCESSOR; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_forms_forms_z", function() { return ɵNgSelectMultipleOption; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "fXoL"); -/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/common */ "ofXK"); -/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs */ "qCKp"); -/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs/operators */ "kU1M"); -/** - * @license Angular v11.2.14 - * (c) 2010-2021 Google LLC. https://angular.io/ - * License: MIT - */ - - - - -/** - * @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 - */ -/** - * Base class for all built-in ControlValueAccessor classes. We use this class to distinguish - * between built-in and custom CVAs, so that Forms logic can recognize built-in CVAs and treat - * custom ones with higher priority (when both built-in and custom CVAs are present). - * Note: this is an *internal-only* class and should not be extended or used directly in - * applications code. - */ - -class BuiltInControlValueAccessor { -} -/** - * Used to provide a `ControlValueAccessor` for form controls. - * - * See `DefaultValueAccessor` for how to implement one. - * - * @publicApi - */ -const NG_VALUE_ACCESSOR = /*@__PURE__*/ new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('NgValueAccessor'); -/** - * @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 - */ -const CHECKBOX_VALUE_ACCESSOR = { - provide: NG_VALUE_ACCESSOR, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => CheckboxControlValueAccessor), - multi: true, -}; -let CheckboxControlValueAccessor = /*@__PURE__*/ (() => { - class CheckboxControlValueAccessor extends BuiltInControlValueAccessor { - constructor(_renderer, _elementRef) { - super(); - this._renderer = _renderer; - this._elementRef = _elementRef; - /** - * The registered callback function called when a change event occurs on the input element. - * @nodoc - */ - this.onChange = (_) => { }; - /** - * The registered callback function called when a blur event occurs on the input element. - * @nodoc - */ - this.onTouched = () => { }; - } - /** - * Sets the "checked" property on the input element. - * @nodoc - */ - writeValue(value) { - this._renderer.setProperty(this._elementRef.nativeElement, 'checked', value); - } - /** - * Registers a function called when the control value changes. - * @nodoc - */ - registerOnChange(fn) { - this.onChange = fn; - } - /** - * Registers a function called when the control is touched. - * @nodoc - */ - registerOnTouched(fn) { - this.onTouched = fn; - } - /** - * Sets the "disabled" property on the input element. - * @nodoc - */ - setDisabledState(isDisabled) { - this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled); - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([CHECKBOX_VALUE_ACCESSOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return CheckboxControlValueAccessor; -})(); -/** - * @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 - */ -const DEFAULT_VALUE_ACCESSOR = { - provide: NG_VALUE_ACCESSOR, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => DefaultValueAccessor), - multi: true -}; -/** - * We must check whether the agent is Android because composition events - * behave differently between iOS and Android. - */ -function _isAndroid() { - const 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 - */ -const COMPOSITION_BUFFER_MODE = /*@__PURE__*/ new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('CompositionEventMode'); -let DefaultValueAccessor = /*@__PURE__*/ (() => { - class DefaultValueAccessor { - constructor(_renderer, _elementRef, _compositionMode) { - this._renderer = _renderer; - this._elementRef = _elementRef; - this._compositionMode = _compositionMode; - /** - * The registered callback function called when an input event occurs on the input element. - * @nodoc - */ - this.onChange = (_) => { }; - /** - * The registered callback function called when a blur event occurs on the input element. - * @nodoc - */ - this.onTouched = () => { }; - /** 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. - * @nodoc - */ - writeValue(value) { - const normalizedValue = value == null ? '' : value; - this._renderer.setProperty(this._elementRef.nativeElement, 'value', normalizedValue); - } - /** - * Registers a function called when the control value changes. - * @nodoc - */ - registerOnChange(fn) { - this.onChange = fn; - } - /** - * Registers a function called when the control is touched. - * @nodoc - */ - registerOnTouched(fn) { - this.onTouched = fn; - } - /** - * Sets the "disabled" property on the input element. - * @nodoc - */ - setDisabledState(isDisabled) { - this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled); - } - /** @internal */ - _handleInput(value) { - if (!this._compositionMode || (this._compositionMode && !this._composing)) { - this.onChange(value); - } - } - /** @internal */ - _compositionStart() { - this._composing = true; - } - /** @internal */ - _compositionEnd(value) { - this._composing = false; - this._compositionMode && this.onChange(value); - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([DEFAULT_VALUE_ACCESSOR])] }); - return DefaultValueAccessor; -})(); -/** - * @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 isEmptyInputValue(value) { - // we don't check for string here so it also works with arrays - return value == null || value.length === 0; -} -function hasValidLength(value) { - // non-strict comparison is intentional, to check for both `null` and `undefined` values - return value != null && typeof value.length === 'number'; -} -/** - * @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 - */ -const NG_VALIDATORS = /*@__PURE__*/ 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 - */ -const NG_ASYNC_VALIDATORS = /*@__PURE__*/ 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. - */ -const 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 - */ -class Validators { - /** - * @description - * Validator that requires the control's value to be greater than or equal to the provided number. - * - * @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}} - * ``` - * - * @returns A validator function that returns an error map with the - * `min` property if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static min(min) { - return minValidator(min); - } - /** - * @description - * Validator that requires the control's value to be less than or equal to the provided number. - * - * @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}} - * ``` - * - * @returns A validator function that returns an error map with the - * `max` property if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static max(max) { - return maxValidator(max); - } - /** - * @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} - * ``` - * - * @returns An error map with the `required` property - * if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static required(control) { - return requiredValidator(control); - } - /** - * @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} - * ``` - * - * @returns An error map that contains the `required` property - * set to `true` if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static requiredTrue(control) { - return requiredTrueValidator(control); - } - /** - * @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} - * ``` - * - * @returns An error map with the `email` property - * if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static email(control) { - return emailValidator(control); - } - /** - * @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 - * - * ``` - * - * @returns A validator function that returns an error map with the - * `minlength` property if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static minLength(minLength) { - return minLengthValidator(minLength); - } - /** - * @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 - * - * ``` - * - * @returns A validator function that returns an error map with the - * `maxlength` property if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static maxLength(maxLength) { - return maxLengthValidator(maxLength); - } - /** - * @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 - * - * ``` - * - * ### Pattern matching with the global or sticky flag - * - * `RegExp` objects created with the `g` or `y` flags that are passed into `Validators.pattern` - * can produce different results on the same input when validations are run consecutively. This is - * due to how the behavior of `RegExp.prototype.test` is - * specified in [ECMA-262](https://tc39.es/ecma262/#sec-regexpbuiltinexec) - * (`RegExp` preserves the index of the last match when the global or sticky flag is used). - * Due to this behavior, it is recommended that when using - * `Validators.pattern` you **do not** pass in a `RegExp` object with either the global or sticky - * flag enabled. - * - * ```typescript - * // Not recommended (since the `g` flag is used) - * const controlOne = new FormControl('1', Validators.pattern(/foo/g)); - * - * // Good - * const controlTwo = new FormControl('1', Validators.pattern(/foo/)); - * ``` - * - * @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. - * - * @returns A validator function that returns an error map with the - * `pattern` property if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static pattern(pattern) { - return patternValidator(pattern); - } - /** - * @description - * Validator that performs no operation. - * - * @see `updateValueAndValidity()` - * - */ - static nullValidator(control) { - return nullValidator(control); - } - static compose(validators) { - return compose(validators); - } - /** - * @description - * Compose multiple async validators into a single function that returns the union - * of the individual error objects for the provided control. - * - * @returns A validator function that returns an error map with the - * merged error objects of the async validators if the validation check fails, otherwise `null`. - * - * @see `updateValueAndValidity()` - * - */ - static composeAsync(validators) { - return composeAsync(validators); - } -} -/** - * Validator that requires the control's value to be greater than or equal to the provided number. - * See `Validators.min` for additional information. - */ -function minValidator(min) { - return (control) => { - if (isEmptyInputValue(control.value) || isEmptyInputValue(min)) { - return null; // don't validate empty values to allow optional controls - } - const 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; - }; -} -/** - * Validator that requires the control's value to be less than or equal to the provided number. - * See `Validators.max` for additional information. - */ -function maxValidator(max) { - return (control) => { - if (isEmptyInputValue(control.value) || isEmptyInputValue(max)) { - return null; // don't validate empty values to allow optional controls - } - const 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; - }; -} -/** - * Validator that requires the control have a non-empty value. - * See `Validators.required` for additional information. - */ -function requiredValidator(control) { - return isEmptyInputValue(control.value) ? { 'required': true } : null; -} -/** - * Validator that requires the control's value be true. This validator is commonly - * used for required checkboxes. - * See `Validators.requiredTrue` for additional information. - */ -function requiredTrueValidator(control) { - return control.value === true ? null : { 'required': true }; -} -/** - * Validator that requires the control's value pass an email validation test. - * See `Validators.email` for additional information. - */ -function emailValidator(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 }; -} -/** - * Validator that requires the length of the control's value to be greater than or equal - * to the provided minimum length. See `Validators.minLength` for additional information. - */ -function minLengthValidator(minLength) { - return (control) => { - if (isEmptyInputValue(control.value) || !hasValidLength(control.value)) { - // don't validate empty values to allow optional controls - // don't validate values without `length` property - return null; - } - return control.value.length < minLength ? - { 'minlength': { 'requiredLength': minLength, 'actualLength': control.value.length } } : - null; - }; -} -/** - * Validator that requires the length of the control's value to be less than or equal - * to the provided maximum length. See `Validators.maxLength` for additional information. - */ -function maxLengthValidator(maxLength) { - return (control) => { - return hasValidLength(control.value) && control.value.length > maxLength ? - { 'maxlength': { 'requiredLength': maxLength, 'actualLength': control.value.length } } : - null; - }; -} -/** - * Validator that requires the control's value to match a regex pattern. - * See `Validators.pattern` for additional information. - */ -function patternValidator(pattern) { - if (!pattern) - return nullValidator; - let regex; - let 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 (control) => { - if (isEmptyInputValue(control.value)) { - return null; // don't validate empty values to allow optional controls - } - const value = control.value; - return regex.test(value) ? null : - { 'pattern': { 'requiredPattern': regexStr, 'actualValue': value } }; - }; -} -/** - * Function that has `ValidatorFn` shape, but performs no operation. - */ -function nullValidator(control) { - return null; -} -function isPresent(o) { - return o != null; -} -function toObservable(r) { - const 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)) && (typeof ngDevMode === 'undefined' || ngDevMode)) { - throw new Error(`Expected validator to return Promise or Observable.`); - } - return obs; -} -function mergeErrors(arrayOfErrors) { - let res = {}; - // Not using Array.reduce here due to a Chrome 80 bug - // https://bugs.chromium.org/p/chromium/issues/detail?id=1049982 - arrayOfErrors.forEach((errors) => { - res = errors != null ? Object.assign(Object.assign({}, res), errors) : res; - }); - return Object.keys(res).length === 0 ? null : res; -} -function executeValidators(control, validators) { - return validators.map(validator => validator(control)); -} -function isValidatorFn(validator) { - return !validator.validate; -} -/** - * Given the list of validators that may contain both functions as well as classes, return the list - * of validator functions (convert validator classes into validator functions). This is needed to - * have consistent structure in validators list before composing them. - * - * @param validators The set of validators that may contain validators both in plain function form - * as well as represented as a validator class. - */ -function normalizeValidators(validators) { - return validators.map(validator => { - return isValidatorFn(validator) ? - validator : - ((c) => validator.validate(c)); - }); -} -/** - * Merges synchronous validators into a single validator function. - * See `Validators.compose` for additional information. - */ -function compose(validators) { - if (!validators) - return null; - const presentValidators = validators.filter(isPresent); - if (presentValidators.length == 0) - return null; - return function (control) { - return mergeErrors(executeValidators(control, presentValidators)); - }; -} -/** - * Accepts a list of validators of different possible shapes (`Validator` and `ValidatorFn`), - * normalizes the list (converts everything to `ValidatorFn`) and merges them into a single - * validator function. - */ -function composeValidators(validators) { - return validators != null ? compose(normalizeValidators(validators)) : null; -} -/** - * Merges asynchronous validators into a single validator function. - * See `Validators.composeAsync` for additional information. - */ -function composeAsync(validators) { - if (!validators) - return null; - const presentValidators = validators.filter(isPresent); - if (presentValidators.length == 0) - return null; - return function (control) { - const observables = executeValidators(control, presentValidators).map(toObservable); - return Object(rxjs__WEBPACK_IMPORTED_MODULE_2__["forkJoin"])(observables).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__["map"])(mergeErrors)); - }; -} -/** - * Accepts a list of async validators of different possible shapes (`AsyncValidator` and - * `AsyncValidatorFn`), normalizes the list (converts everything to `AsyncValidatorFn`) and merges - * them into a single validator function. - */ -function composeAsyncValidators(validators) { - return validators != null ? composeAsync(normalizeValidators(validators)) : - null; -} -/** - * Merges raw control validators with a given directive validator and returns the combined list of - * validators as an array. - */ -function mergeValidators(controlValidators, dirValidator) { - if (controlValidators === null) - return [dirValidator]; - return Array.isArray(controlValidators) ? [...controlValidators, dirValidator] : - [controlValidators, dirValidator]; -} -/** - * Retrieves the list of raw synchronous validators attached to a given control. - */ -function getControlValidators(control) { - return control._rawValidators; -} -/** - * Retrieves the list of raw asynchronous validators attached to a given control. - */ -function getControlAsyncValidators(control) { - return control._rawAsyncValidators; -} -let AbstractControlDirective = /*@__PURE__*/ (() => { - class AbstractControlDirective { - constructor() { - /** - * Set of synchronous validators as they were provided while calling `setValidators` function. - * @internal - */ - this._rawValidators = []; - /** - * Set of asynchronous validators as they were provided while calling `setAsyncValidators` - * function. - * @internal - */ - this._rawAsyncValidators = []; - /* - * The set of callbacks to be invoked when directive instance is being destroyed. - */ - this._onDestroyCallbacks = []; - } - /** - * @description - * Reports the value of the control if it is present, otherwise null. - */ - get value() { - 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. - */ - get valid() { - 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. - */ - get invalid() { - 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. - */ - get pending() { - 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. - */ - get disabled() { - 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. - */ - get enabled() { - return this.control ? this.control.enabled : null; - } - /** - * @description - * Reports the control's validation errors. If the control is not present, null is returned. - */ - get errors() { - 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. - */ - get pristine() { - 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. - */ - get dirty() { - 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. - */ - get touched() { - 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. - */ - get status() { - 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. - */ - get untouched() { - 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. - */ - get statusChanges() { - 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. - */ - get valueChanges() { - 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. - */ - get path() { - return null; - } - /** - * Sets synchronous validators for this directive. - * @internal - */ - _setValidators(validators) { - this._rawValidators = validators || []; - this._composedValidatorFn = composeValidators(this._rawValidators); - } - /** - * Sets asynchronous validators for this directive. - * @internal - */ - _setAsyncValidators(validators) { - this._rawAsyncValidators = validators || []; - this._composedAsyncValidatorFn = composeAsyncValidators(this._rawAsyncValidators); - } - /** - * @description - * Synchronous validator function composed of all the synchronous validators registered with this - * directive. - */ - get validator() { - return this._composedValidatorFn || null; - } - /** - * @description - * Asynchronous validator function composed of all the asynchronous validators registered with - * this directive. - */ - get asyncValidator() { - return this._composedAsyncValidatorFn || null; - } - /** - * Internal function to register callbacks that should be invoked - * when directive instance is being destroyed. - * @internal - */ - _registerOnDestroy(fn) { - this._onDestroyCallbacks.push(fn); - } - /** - * Internal function to invoke all registered "on destroy" callbacks. - * Note: calling this function also clears the list of callbacks. - * @internal - */ - _invokeOnDestroyCallbacks() { - this._onDestroyCallbacks.forEach(fn => fn()); - this._onDestroyCallbacks = []; - } - /** - * @description - * Resets the control with the provided value if the control is present. - */ - reset(value = undefined) { - if (this.control) - this.control.reset(value); - } - /** - * @description - * Reports whether the control with the given path has the error specified. - * - * @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. - * - * @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. - * - * @returns whether the given error is present in the control at the given path. - * - * If the control is not present, false is returned. - */ - hasError(errorCode, path) { - return this.control ? this.control.hasError(errorCode, path) : false; - } - /** - * @description - * Reports error data for the control with the given path. - * - * @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. - * - * @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'` - * - * @returns error data for that particular error. If the control or error is not present, - * null is returned. - */ - getError(errorCode, path) { - return this.control ? this.control.getError(errorCode, path) : null; - } - } - AbstractControlDirective.ɵfac = function AbstractControlDirective_Factory(t) { return new (t || AbstractControlDirective)(); }; - AbstractControlDirective.ɵdir = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: AbstractControlDirective }); - return AbstractControlDirective; -})(); -let ControlContainer = /*@__PURE__*/ (() => { - class ControlContainer extends AbstractControlDirective { - /** - * @description - * The top-level form directive for the control. - */ - get formDirective() { - return null; - } - /** - * @description - * The path to this group. - */ - get path() { - return null; - } - } - ControlContainer.ɵfac = function ControlContainer_Factory(t) { return ɵControlContainer_BaseFactory(t || ControlContainer); }; - ControlContainer.ɵdir = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: ControlContainer, features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return ControlContainer; -})(); -const ɵControlContainer_BaseFactory = /*@__PURE__*/ /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](ControlContainer); -/** - * @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 - */ -/** - * @description - * A base class that all `FormControl`-based directives extend. It binds a `FormControl` - * object to a DOM element. - * - * @publicApi - */ -class NgControl extends AbstractControlDirective { - constructor() { - super(...arguments); - /** - * @description - * The parent form for the control. - * - * @internal - */ - this._parent = null; - /** - * @description - * The name for the control - */ - this.name = null; - /** - * @description - * The value accessor for the control - */ - this.valueAccessor = null; - } -} -/** - * @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 AbstractControlStatus { - constructor(cd) { - this._cd = cd; - } - is(status) { - var _a, _b; - return !!((_b = (_a = this._cd) === null || _a === void 0 ? void 0 : _a.control) === null || _b === void 0 ? void 0 : _b[status]); - } -} -const ngControlStatusHost = { - '[class.ng-untouched]': 'is("untouched")', - '[class.ng-touched]': 'is("touched")', - '[class.ng-pristine]': 'is("pristine")', - '[class.ng-dirty]': 'is("dirty")', - '[class.ng-valid]': 'is("valid")', - '[class.ng-invalid]': 'is("invalid")', - '[class.ng-pending]': 'is("pending")', -}; -let NgControlStatus = /*@__PURE__*/ (() => { - class NgControlStatus extends AbstractControlStatus { - constructor(cd) { - super(cd); - } - } - NgControlStatus.ɵfac = function NgControlStatus_Factory(t) { return new (t || NgControlStatus)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](NgControl, 2)); }; - NgControlStatus.ɵdir = /*@__PURE__*/ _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.is("untouched"))("ng-touched", ctx.is("touched"))("ng-pristine", ctx.is("pristine"))("ng-dirty", ctx.is("dirty"))("ng-valid", ctx.is("valid"))("ng-invalid", ctx.is("invalid"))("ng-pending", ctx.is("pending")); - } - }, features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return NgControlStatus; -})(); -let NgControlStatusGroup = /*@__PURE__*/ (() => { - class NgControlStatusGroup extends AbstractControlStatus { - constructor(cd) { - super(cd); - } - } - NgControlStatusGroup.ɵfac = function NgControlStatusGroup_Factory(t) { return new (t || NgControlStatusGroup)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ControlContainer, 10)); }; - NgControlStatusGroup.ɵdir = /*@__PURE__*/ _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.is("untouched"))("ng-touched", ctx.is("touched"))("ng-pristine", ctx.is("pristine"))("ng-dirty", ctx.is("dirty"))("ng-valid", ctx.is("valid"))("ng-invalid", ctx.is("invalid"))("ng-pending", ctx.is("pending")); - } - }, features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return NgControlStatusGroup; -})(); -/** - * @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 - */ -const FormErrorExamples = { - formControlName: ` -
- -
- - In your class: - - this.myGroup = new FormGroup({ - firstName: new FormControl() - });`, - formGroupName: ` -
-
- -
-
- - In your class: - - this.myGroup = new FormGroup({ - person: new FormGroup({ firstName: new FormControl() }) - });`, - formArrayName: ` -
-
-
- -
-
-
- - In your class: - - this.cityArray = new FormArray([new FormControl('SF')]); - this.myGroup = new FormGroup({ - cities: this.cityArray - });`, - ngModelGroup: ` -
-
- -
-
`, - ngModelWithFormGroup: ` -
- - -
- ` -}; -/** - * @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 ReactiveErrors { - static controlParentException() { - throw new Error(`formControlName must be used with a parent formGroup directive. You'll want to add a formGroup - directive and pass it an existing FormGroup instance (you can create one in your class). - - Example: - - ${FormErrorExamples.formControlName}`); - } - static ngModelGroupException() { - throw new Error(`formControlName cannot be used with an ngModelGroup parent. It is only compatible with parents - that also have a "form" prefix: formGroupName, formArrayName, or formGroup. - - Option 1: Update the parent to be formGroupName (reactive form strategy) - - ${FormErrorExamples.formGroupName} - - Option 2: Use ngModel instead of formControlName (template-driven strategy) - - ${FormErrorExamples.ngModelGroup}`); - } - static missingFormException() { - throw new Error(`formGroup expects a FormGroup instance. Please pass one in. - - Example: - - ${FormErrorExamples.formControlName}`); - } - static groupParentException() { - throw new Error(`formGroupName must be used with a parent formGroup directive. You'll want to add a formGroup - directive and pass it an existing FormGroup instance (you can create one in your class). - - Example: - - ${FormErrorExamples.formGroupName}`); - } - static arrayParentException() { - throw new Error(`formArrayName must be used with a parent formGroup directive. You'll want to add a formGroup - directive and pass it an existing FormGroup instance (you can create one in your class). - - Example: - - ${FormErrorExamples.formArrayName}`); - } - static disabledAttrWarning() { - console.warn(` - It looks like you're using the disabled attribute with a reactive form directive. If you set disabled to true - when you set up this control in your component class, the disabled attribute will actually be set in the DOM for - you. We recommend using this approach to avoid 'changed after checked' errors. - - Example: - form = new FormGroup({ - first: new FormControl({value: 'Nancy', disabled: true}, Validators.required), - last: new FormControl('Drew', Validators.required) - }); - `); - } - static ngModelWarning(directiveName) { - console.warn(` - It looks like you're using ngModel on the same form field as ${directiveName}. - Support for using the ngModel input property and ngModelChange event with - reactive form directives has been deprecated in Angular v6 and will be removed - in a future version of Angular. - - For more information on this, see our API docs here: - https://angular.io/api/forms/${directiveName === 'formControl' ? 'FormControlDirective' : - 'FormControlName'}#use-with-ngmodel - `); - } -} -/** - * @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 controlPath(name, parent) { - return [...parent.path, name]; -} -/** - * Links a Form control and a Form directive by setting up callbacks (such as `onChange`) on both - * instances. This function is typically invoked when form directive is being initialized. - * - * @param control Form control instance that should be linked. - * @param dir Directive that should be linked with a given control. - */ -function setUpControl(control, dir) { - if (typeof ngDevMode === 'undefined' || ngDevMode) { - if (!control) - _throwError(dir, 'Cannot find control with'); - if (!dir.valueAccessor) - _throwError(dir, 'No value accessor for form control with'); - } - setUpValidators(control, dir, /* handleOnValidatorChange */ true); - dir.valueAccessor.writeValue(control.value); - setUpViewChangePipeline(control, dir); - setUpModelChangePipeline(control, dir); - setUpBlurPipeline(control, dir); - setUpDisabledChangeHandler(control, dir); -} -/** - * Reverts configuration performed by the `setUpControl` control function. - * Effectively disconnects form control with a given form directive. - * This function is typically invoked when corresponding form directive is being destroyed. - * - * @param control Form control which should be cleaned up. - * @param dir Directive that should be disconnected from a given control. - * @param validateControlPresenceOnChange Flag that indicates whether onChange handler should - * contain asserts to verify that it's not called once directive is destroyed. We need this flag - * to avoid potentially breaking changes caused by better control cleanup introduced in #39235. - */ -function cleanUpControl(control, dir, validateControlPresenceOnChange = true) { - const noop = () => { - if (validateControlPresenceOnChange && (typeof ngDevMode === 'undefined' || ngDevMode)) { - _noControlError(dir); - } - }; - // The `valueAccessor` field is typically defined on FromControl and FormControlName directive - // instances and there is a logic in `selectValueAccessor` function that throws if it's not the - // case. We still check the presence of `valueAccessor` before invoking its methods to make sure - // that cleanup works correctly if app code or tests are setup to ignore the error thrown from - // `selectValueAccessor`. See https://github.com/angular/angular/issues/40521. - if (dir.valueAccessor) { - dir.valueAccessor.registerOnChange(noop); - dir.valueAccessor.registerOnTouched(noop); - } - cleanUpValidators(control, dir, /* handleOnValidatorChange */ true); - if (control) { - dir._invokeOnDestroyCallbacks(); - control._registerOnCollectionChange(() => { }); - } -} -function registerOnValidatorChange(validators, onChange) { - validators.forEach((validator) => { - if (validator.registerOnValidatorChange) - validator.registerOnValidatorChange(onChange); - }); -} -/** - * Sets up disabled change handler function on a given form control if ControlValueAccessor - * associated with a given directive instance supports the `setDisabledState` call. - * - * @param control Form control where disabled change handler should be setup. - * @param dir Corresponding directive instance associated with this control. - */ -function setUpDisabledChangeHandler(control, dir) { - if (dir.valueAccessor.setDisabledState) { - const onDisabledChange = (isDisabled) => { - dir.valueAccessor.setDisabledState(isDisabled); - }; - control.registerOnDisabledChange(onDisabledChange); - // Register a callback function to cleanup disabled change handler - // from a control instance when a directive is destroyed. - dir._registerOnDestroy(() => { - control._unregisterOnDisabledChange(onDisabledChange); - }); - } -} -/** - * Sets up sync and async directive validators on provided form control. - * This function merges validators from the directive into the validators of the control. - * - * @param control Form control where directive validators should be setup. - * @param dir Directive instance that contains validators to be setup. - * @param handleOnValidatorChange Flag that determines whether directive validators should be setup - * to handle validator input change. - */ -function setUpValidators(control, dir, handleOnValidatorChange) { - const validators = getControlValidators(control); - if (dir.validator !== null) { - control.setValidators(mergeValidators(validators, dir.validator)); - } - else if (typeof validators === 'function') { - // If sync validators are represented by a single validator function, we force the - // `Validators.compose` call to happen by executing the `setValidators` function with - // an array that contains that function. We need this to avoid possible discrepancies in - // validators behavior, so sync validators are always processed by the `Validators.compose`. - // Note: we should consider moving this logic inside the `setValidators` function itself, so we - // have consistent behavior on AbstractControl API level. The same applies to the async - // validators logic below. - control.setValidators([validators]); - } - const asyncValidators = getControlAsyncValidators(control); - if (dir.asyncValidator !== null) { - control.setAsyncValidators(mergeValidators(asyncValidators, dir.asyncValidator)); - } - else if (typeof asyncValidators === 'function') { - control.setAsyncValidators([asyncValidators]); - } - // Re-run validation when validator binding changes, e.g. minlength=3 -> minlength=4 - if (handleOnValidatorChange) { - const onValidatorChange = () => control.updateValueAndValidity(); - registerOnValidatorChange(dir._rawValidators, onValidatorChange); - registerOnValidatorChange(dir._rawAsyncValidators, onValidatorChange); - } -} -/** - * Cleans up sync and async directive validators on provided form control. - * This function reverts the setup performed by the `setUpValidators` function, i.e. - * removes directive-specific validators from a given control instance. - * - * @param control Form control from where directive validators should be removed. - * @param dir Directive instance that contains validators to be removed. - * @param handleOnValidatorChange Flag that determines whether directive validators should also be - * cleaned up to stop handling validator input change (if previously configured to do so). - * @returns true if a control was updated as a result of this action. - */ -function cleanUpValidators(control, dir, handleOnValidatorChange) { - let isControlUpdated = false; - if (control !== null) { - if (dir.validator !== null) { - const validators = getControlValidators(control); - if (Array.isArray(validators) && validators.length > 0) { - // Filter out directive validator function. - const updatedValidators = validators.filter(validator => validator !== dir.validator); - if (updatedValidators.length !== validators.length) { - isControlUpdated = true; - control.setValidators(updatedValidators); - } - } - } - if (dir.asyncValidator !== null) { - const asyncValidators = getControlAsyncValidators(control); - if (Array.isArray(asyncValidators) && asyncValidators.length > 0) { - // Filter out directive async validator function. - const updatedAsyncValidators = asyncValidators.filter(asyncValidator => asyncValidator !== dir.asyncValidator); - if (updatedAsyncValidators.length !== asyncValidators.length) { - isControlUpdated = true; - control.setAsyncValidators(updatedAsyncValidators); - } - } - } - } - if (handleOnValidatorChange) { - // Clear onValidatorChange callbacks by providing a noop function. - const noop = () => { }; - registerOnValidatorChange(dir._rawValidators, noop); - registerOnValidatorChange(dir._rawAsyncValidators, noop); - } - return isControlUpdated; -} -function setUpViewChangePipeline(control, dir) { - dir.valueAccessor.registerOnChange((newValue) => { - control._pendingValue = newValue; - control._pendingChange = true; - control._pendingDirty = true; - if (control.updateOn === 'change') - updateControl(control, dir); - }); -} -function setUpBlurPipeline(control, dir) { - dir.valueAccessor.registerOnTouched(() => { - control._pendingTouched = true; - if (control.updateOn === 'blur' && control._pendingChange) - updateControl(control, dir); - if (control.updateOn !== 'submit') - control.markAsTouched(); - }); -} -function updateControl(control, dir) { - if (control._pendingDirty) - control.markAsDirty(); - control.setValue(control._pendingValue, { emitModelToViewChange: false }); - dir.viewToModelUpdate(control._pendingValue); - control._pendingChange = false; -} -function setUpModelChangePipeline(control, dir) { - const onChange = (newValue, emitModelEvent) => { - // control -> view - dir.valueAccessor.writeValue(newValue); - // control -> ngModel - if (emitModelEvent) - dir.viewToModelUpdate(newValue); - }; - control.registerOnChange(onChange); - // Register a callback function to cleanup onChange handler - // from a control instance when a directive is destroyed. - dir._registerOnDestroy(() => { - control._unregisterOnChange(onChange); - }); -} -/** - * Links a FormGroup or FormArray instance and corresponding Form directive by setting up validators - * present in the view. - * - * @param control FormGroup or FormArray instance that should be linked. - * @param dir Directive that provides view validators. - */ -function setUpFormContainer(control, dir) { - if (control == null && (typeof ngDevMode === 'undefined' || ngDevMode)) - _throwError(dir, 'Cannot find control with'); - setUpValidators(control, dir, /* handleOnValidatorChange */ false); -} -/** - * Reverts the setup performed by the `setUpFormContainer` function. - * - * @param control FormGroup or FormArray instance that should be cleaned up. - * @param dir Directive that provided view validators. - * @returns true if a control was updated as a result of this action. - */ -function cleanUpFormContainer(control, dir) { - return cleanUpValidators(control, dir, /* handleOnValidatorChange */ false); -} -function _noControlError(dir) { - return _throwError(dir, 'There is no FormControl instance attached to form control element with'); -} -function _throwError(dir, message) { - let messageEnd; - if (dir.path.length > 1) { - messageEnd = `path: '${dir.path.join(' -> ')}'`; - } - else if (dir.path[0]) { - messageEnd = `name: '${dir.path}'`; - } - else { - messageEnd = 'unspecified name attribute'; - } - throw new Error(`${message} ${messageEnd}`); -} -function isPropertyUpdated(changes, viewModel) { - if (!changes.hasOwnProperty('model')) - return false; - const change = changes['model']; - if (change.isFirstChange()) - return true; - return !Object.is(viewModel, change.currentValue); -} -function isBuiltInAccessor(valueAccessor) { - // Check if a given value accessor is an instance of a class that directly extends - // `BuiltInControlValueAccessor` one. - return Object.getPrototypeOf(valueAccessor.constructor) === BuiltInControlValueAccessor; -} -function syncPendingControls(form, directives) { - form._syncPendingControls(); - directives.forEach(dir => { - const control = 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 -function selectValueAccessor(dir, valueAccessors) { - if (!valueAccessors) - return null; - if (!Array.isArray(valueAccessors) && (typeof ngDevMode === 'undefined' || ngDevMode)) - _throwError(dir, 'Value accessor was not provided as an array for form control with'); - let defaultAccessor = undefined; - let builtinAccessor = undefined; - let customAccessor = undefined; - valueAccessors.forEach((v) => { - if (v.constructor === DefaultValueAccessor) { - defaultAccessor = v; - } - else if (isBuiltInAccessor(v)) { - if (builtinAccessor && (typeof ngDevMode === 'undefined' || ngDevMode)) - _throwError(dir, 'More than one built-in value accessor matches form control with'); - builtinAccessor = v; - } - else { - if (customAccessor && (typeof ngDevMode === 'undefined' || ngDevMode)) - _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; - if (typeof ngDevMode === 'undefined' || ngDevMode) { - _throwError(dir, 'No valid value accessor for form control with'); - } - return null; -} -function removeListItem(list, el) { - const index = list.indexOf(el); - if (index > -1) - list.splice(index, 1); -} -// TODO(kara): remove after deprecation period -function _ngModelWarning(name, type, instance, warningConfig) { - if (warningConfig === 'never') - return; - if (((warningConfig === null || warningConfig === 'once') && !type._ngModelWarningSentOnce) || - (warningConfig === 'always' && !instance._ngModelWarningSent)) { - ReactiveErrors.ngModelWarning(name); - type._ngModelWarningSentOnce = true; - instance._ngModelWarningSent = true; - } -} -/** - * @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 - */ -/** - * Reports that a FormControl is valid, meaning that no errors exist in the input value. - * - * @see `status` - */ -const VALID = 'VALID'; -/** - * Reports that a FormControl is invalid, meaning that an error exists in the input value. - * - * @see `status` - */ -const 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` - */ -const 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` - */ -const DISABLED = 'DISABLED'; -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 - let controlToFind = control; - path.forEach((name) => { - if (controlToFind instanceof FormGroup) { - controlToFind = controlToFind.controls.hasOwnProperty(name) ? - controlToFind.controls[name] : - null; - } - else if (controlToFind instanceof FormArray) { - controlToFind = controlToFind.at(name) || null; - } - else { - controlToFind = null; - } - }); - return controlToFind; -} -/** - * Gets validators from either an options object or given validators. - */ -function pickValidators(validatorOrOpts) { - return (isOptionsObj(validatorOrOpts) ? validatorOrOpts.validators : validatorOrOpts) || null; -} -/** - * Creates validator function by combining provided validators. - */ -function coerceToValidator(validator) { - return Array.isArray(validator) ? composeValidators(validator) : validator || null; -} -/** - * Gets async validators from either an options object or given validators. - */ -function pickAsyncValidators(asyncValidator, validatorOrOpts) { - return (isOptionsObj(validatorOrOpts) ? validatorOrOpts.asyncValidators : asyncValidator) || null; -} -/** - * Creates async validator function by combining provided async validators. - */ -function coerceToAsyncValidator(asyncValidator) { - return Array.isArray(asyncValidator) ? composeAsyncValidators(asyncValidator) : - asyncValidator || null; -} -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 - */ -class AbstractControl { - /** - * Initialize the AbstractControl instance. - * - * @param validators The function or array of functions that is used to determine the validity of - * this control synchronously. - * @param asyncValidators The function or array of functions that is used to determine validity of - * this control asynchronously. - */ - constructor(validators, asyncValidators) { - /** - * Indicates that a control has its own pending asynchronous validation in progress. - * - * @internal - */ - this._hasOwnPendingAsyncValidator = false; - /** @internal */ - this._onCollectionChange = () => { }; - this._parent = null; - /** - * A control is `pristine` if the user has not yet changed - * the value in the UI. - * - * @returns 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 = []; - this._rawValidators = validators; - this._rawAsyncValidators = asyncValidators; - this._composedValidatorFn = coerceToValidator(this._rawValidators); - this._composedAsyncValidatorFn = coerceToAsyncValidator(this._rawAsyncValidators); - } - /** - * The function that is used to determine the validity of this control synchronously. - */ - get validator() { - return this._composedValidatorFn; - } - set validator(validatorFn) { - this._rawValidators = this._composedValidatorFn = validatorFn; - } - /** - * The function that is used to determine the validity of this control asynchronously. - */ - get asyncValidator() { - return this._composedAsyncValidatorFn; - } - set asyncValidator(asyncValidatorFn) { - this._rawAsyncValidators = this._composedAsyncValidatorFn = asyncValidatorFn; - } - /** - * The parent control. - */ - get parent() { - return this._parent; - } - /** - * A control is `valid` when its `status` is `VALID`. - * - * @see {@link AbstractControl.status} - * - * @returns True if the control has passed all of its validation tests, - * false otherwise. - */ - get valid() { - return this.status === VALID; - } - /** - * A control is `invalid` when its `status` is `INVALID`. - * - * @see {@link AbstractControl.status} - * - * @returns True if this control has failed one or more of its validation checks, - * false otherwise. - */ - get invalid() { - return this.status === INVALID; - } - /** - * A control is `pending` when its `status` is `PENDING`. - * - * @see {@link AbstractControl.status} - * - * @returns True if this control is in the process of conducting a validation check, - * false otherwise. - */ - get pending() { - 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} - * - * @returns True if the control is disabled, false otherwise. - */ - get disabled() { - return this.status === DISABLED; - } - /** - * A control is `enabled` as long as its `status` is not `DISABLED`. - * - * @returns True if the control has any status other than 'DISABLED', - * false if the status is 'DISABLED'. - * - * @see {@link AbstractControl.status} - * - */ - get enabled() { - return this.status !== DISABLED; - } - /** - * A control is `dirty` if the user has changed the value - * in the UI. - * - * @returns 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. - */ - get dirty() { - 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. - */ - get untouched() { - 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'` - */ - get updateOn() { - return this._updateOn ? this._updateOn : (this.parent ? this.parent.updateOn : 'change'); - } - /** - * 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. - * - */ - setValidators(newValidator) { - this._rawValidators = newValidator; - this._composedValidatorFn = 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. - * - */ - setAsyncValidators(newValidator) { - this._rawAsyncValidators = newValidator; - this._composedAsyncValidatorFn = 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. - * - */ - 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. - * - */ - 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()` - * @see `markAsDirty()` - * @see `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. - */ - markAsTouched(opts = {}) { - this.touched = true; - if (this._parent && !opts.onlySelf) { - this._parent.markAsTouched(opts); - } - } - /** - * Marks the control and all its descendant controls as `touched`. - * @see `markAsTouched()` - */ - markAllAsTouched() { - this.markAsTouched({ onlySelf: true }); - this._forEachChild((control) => 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()` - * @see `markAsDirty()` - * @see `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. - */ - markAsUntouched(opts = {}) { - this.touched = false; - this._pendingTouched = false; - this._forEachChild((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()` - * @see `markAsUntouched()` - * @see `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. - */ - markAsDirty(opts = {}) { - 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()` - * @see `markAsUntouched()` - * @see `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. - */ - markAsPristine(opts = {}) { - this.pristine = true; - this._pendingDirty = false; - this._forEachChild((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. - * - */ - markAsPending(opts = {}) { - this.status = PENDING; - if (opts.emitEvent !== false) { - 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. - */ - disable(opts = {}) { - // If parent has been marked artificially dirty we don't want to re-calculate the - // parent's dirtiness based on the children. - const skipPristineCheck = this._parentMarkedDirty(opts.onlySelf); - this.status = DISABLED; - this.errors = null; - this._forEachChild((control) => { - control.disable(Object.assign(Object.assign({}, opts), { onlySelf: true })); - }); - this._updateValue(); - if (opts.emitEvent !== false) { - this.valueChanges.emit(this.value); - this.statusChanges.emit(this.status); - } - this._updateAncestors(Object.assign(Object.assign({}, opts), { skipPristineCheck })); - this._onDisabledChange.forEach((changeFn) => 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. - */ - enable(opts = {}) { - // If parent has been marked artificially dirty we don't want to re-calculate the - // parent's dirtiness based on the children. - const skipPristineCheck = this._parentMarkedDirty(opts.onlySelf); - this.status = VALID; - this._forEachChild((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 })); - this._onDisabledChange.forEach((changeFn) => changeFn(false)); - } - _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 - */ - 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. - */ - updateValueAndValidity(opts = {}) { - this._setInitialStatus(); - this._updateValue(); - if (this.enabled) { - this._cancelExistingSubscription(); - this.errors = this._runValidator(); - this.status = this._calculateStatus(); - if (this.status === VALID || this.status === PENDING) { - this._runAsyncValidator(opts.emitEvent); - } - } - if (opts.emitEvent !== false) { - this.valueChanges.emit(this.value); - this.statusChanges.emit(this.status); - } - if (this._parent && !opts.onlySelf) { - this._parent.updateValueAndValidity(opts); - } - } - /** @internal */ - _updateTreeValidity(opts = { emitEvent: true }) { - this._forEachChild((ctrl) => ctrl._updateTreeValidity(opts)); - this.updateValueAndValidity({ onlySelf: true, emitEvent: opts.emitEvent }); - } - _setInitialStatus() { - this.status = this._allControlsDisabled() ? DISABLED : VALID; - } - _runValidator() { - return this.validator ? this.validator(this) : null; - } - _runAsyncValidator(emitEvent) { - if (this.asyncValidator) { - this.status = PENDING; - this._hasOwnPendingAsyncValidator = true; - const obs = toObservable(this.asyncValidator(this)); - this._asyncValidationSubscription = obs.subscribe((errors) => { - this._hasOwnPendingAsyncValidator = false; - // This will trigger the recalculation of the validation status, which depends on - // the state of the asynchronous validation (whether it is in progress or not). So, it is - // necessary that we have updated the `_hasOwnPendingAsyncValidator` boolean flag first. - this.setErrors(errors, { emitEvent }); - }); - } - } - _cancelExistingSubscription() { - if (this._asyncValidationSubscription) { - this._asyncValidationSubscription.unsubscribe(); - this._hasOwnPendingAsyncValidator = false; - } - } - /** - * 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); - * ``` - */ - setErrors(errors, opts = {}) { - this.errors = errors; - this._updateControlsErrors(opts.emitEvent !== false); - } - /** - * Retrieves a child control given the control's name or path. - * - * @param path A dot-delimited string or array of string/number values that define the path to the - * control. - * - * @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']);` - * - * ### Retrieve a control in a FormArray - * - * When accessing an element inside a FormArray, you can use an element index. - * For example, to get a `price` control from the first element in an `items` array you can use: - * - * * `this.form.get('items.0.price');` - * - * -OR- - * - * * `this.form.get(['items', 0, 'price']);` - */ - get(path) { - return _find(this, path, '.'); - } - /** - * @description - * Reports error data for the control with the given path. - * - * @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. - * - * @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'` - * - * @returns error data for that particular error. If the control or error is not present, - * null is returned. - */ - getError(errorCode, path) { - const 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. - * - * @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. - * - * @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. - * - * @returns whether the given error is present in the control at the given path. - * - * If the control is not present, false is returned. - */ - hasError(errorCode, path) { - return !!this.getError(errorCode, path); - } - /** - * Retrieves the top-level ancestor of this control. - */ - get root() { - let x = this; - while (x._parent) { - x = x._parent; - } - return x; - } - /** @internal */ - _updateControlsErrors(emitEvent) { - this.status = this._calculateStatus(); - if (emitEvent) { - this.statusChanges.emit(this.status); - } - if (this._parent) { - this._parent._updateControlsErrors(emitEvent); - } - } - /** @internal */ - _initObservables() { - this.valueChanges = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.statusChanges = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - } - _calculateStatus() { - if (this._allControlsDisabled()) - return DISABLED; - if (this.errors) - return INVALID; - if (this._hasOwnPendingAsyncValidator || this._anyControlsHaveStatus(PENDING)) - return PENDING; - if (this._anyControlsHaveStatus(INVALID)) - return INVALID; - return VALID; - } - /** @internal */ - _anyControlsHaveStatus(status) { - return this._anyControls((control) => control.status === status); - } - /** @internal */ - _anyControlsDirty() { - return this._anyControls((control) => control.dirty); - } - /** @internal */ - _anyControlsTouched() { - return this._anyControls((control) => control.touched); - } - /** @internal */ - _updatePristine(opts = {}) { - this.pristine = !this._anyControlsDirty(); - if (this._parent && !opts.onlySelf) { - this._parent._updatePristine(opts); - } - } - /** @internal */ - _updateTouched(opts = {}) { - this.touched = this._anyControlsTouched(); - if (this._parent && !opts.onlySelf) { - this._parent._updateTouched(opts); - } - } - /** @internal */ - _isBoxedValue(formState) { - return typeof formState === 'object' && formState !== null && - Object.keys(formState).length === 2 && 'value' in formState && 'disabled' in formState; - } - /** @internal */ - _registerOnCollectionChange(fn) { - this._onCollectionChange = fn; - } - /** @internal */ - _setUpdateStrategy(opts) { - if (isOptionsObj(opts) && opts.updateOn != null) { - this._updateOn = opts.updateOn; - } - } - /** - * Check to see if parent has been marked artificially dirty. - * - * @internal - */ - _parentMarkedDirty(onlySelf) { - const parentDirty = this._parent && this._parent.dirty; - return !onlySelf && !!parentDirty && !this._parent._anyControlsDirty(); - } -} -/** - * 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 - */ -class FormControl extends AbstractControl { - /** - * 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 - * - */ - constructor(formState = null, validatorOrOpts, asyncValidator) { - super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts)); - /** @internal */ - this._onChange = []; - this._applyFormState(formState); - this._setUpdateStrategy(validatorOrOpts); - this._initObservables(); - this.updateValueAndValidity({ - onlySelf: true, - // If `asyncValidator` is present, it will trigger control status change from `PENDING` to - // `VALID` or `INVALID`. - // The status should be broadcasted via the `statusChanges` observable, so we set `emitEvent` - // to `true` to allow that during the control creation process. - emitEvent: !!asyncValidator - }); - } - /** - * 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. - * - */ - setValue(value, options = {}) { - this.value = this._pendingValue = value; - if (this._onChange.length && options.emitModelToViewChange !== false) { - this._onChange.forEach((changeFn) => changeFn(this.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 - */ - patchValue(value, options = {}) { - 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. - * - */ - reset(formState = null, options = {}) { - this._applyFormState(formState); - this.markAsPristine(options); - this.markAsUntouched(options); - this.setValue(this.value, options); - this._pendingChange = false; - } - /** - * @internal - */ - _updateValue() { } - /** - * @internal - */ - _anyControls(condition) { - return false; - } - /** - * @internal - */ - _allControlsDisabled() { - return this.disabled; - } - /** - * Register a listener for change events. - * - * @param fn The method that is called when the value changes - */ - registerOnChange(fn) { - this._onChange.push(fn); - } - /** - * Internal function to unregister a change events listener. - * @internal - */ - _unregisterOnChange(fn) { - removeListItem(this._onChange, fn); - } - /** - * Register a listener for disabled events. - * - * @param fn The method that is called when the disabled status changes. - */ - registerOnDisabledChange(fn) { - this._onDisabledChange.push(fn); - } - /** - * Internal function to unregister a disabled event listener. - * @internal - */ - _unregisterOnDisabledChange(fn) { - removeListItem(this._onDisabledChange, fn); - } - /** - * @internal - */ - _forEachChild(cb) { } - /** @internal */ - _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; - } - _applyFormState(formState) { - if (this._isBoxedValue(formState)) { - this.value = this._pendingValue = formState.value; - formState.disabled ? this.disable({ onlySelf: true, emitEvent: false }) : - this.enable({ onlySelf: true, emitEvent: false }); - } - else { - this.value = this._pendingValue = formState; - } - } -} -/** - * 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 - */ -class FormGroup extends AbstractControl { - /** - * 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 - * - */ - constructor(controls, validatorOrOpts, asyncValidator) { - super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts)); - this.controls = controls; - this._initObservables(); - this._setUpdateStrategy(validatorOrOpts); - this._setUpControls(); - this.updateValueAndValidity({ - onlySelf: true, - // If `asyncValidator` is present, it will trigger control status change from `PENDING` to - // `VALID` or `INVALID`. The status should be broadcasted via the `statusChanges` observable, - // so we set `emitEvent` to `true` to allow that during the control creation process. - emitEvent: !!asyncValidator - }); - } - /** - * 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 - */ - 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 - */ - 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 - */ - removeControl(name) { - if (this.controls[name]) - this.controls[name]._registerOnCollectionChange(() => { }); - 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 - */ - setControl(name, control) { - if (this.controls[name]) - this.controls[name]._registerOnCollectionChange(() => { }); - 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 - * - * @returns false for disabled controls, true otherwise. - */ - 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. - */ - setValue(value, options = {}) { - this._checkAllValuesPresent(value); - Object.keys(value).forEach(name => { - this._throwIfControlMissing(name); - this.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. - */ - patchValue(value, options = {}) { - // Even though the `value` argument type doesn't allow `null` and `undefined` values, the - // `patchValue` can be called recursively and inner data structures might have these values, so - // we just ignore such cases when a field containing FormGroup instance receives `null` or - // `undefined` as a value. - if (value == null /* both `null` and `undefined` */) - return; - Object.keys(value).forEach(name => { - if (this.controls[name]) { - this.controls[name].patchValue(value[name], { onlySelf: true, emitEvent: options.emitEvent }); - } - }); - this.updateValueAndValidity(options); - } - /** - * Resets the `FormGroup`, marks all descendants `pristine` and `untouched` and sets - * 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. - * - * @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. - * - * @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(form.value); // {last: 'last'} - * console.log(form.get('first').status); // 'DISABLED' - * ``` - */ - reset(value = {}, options = {}) { - this._forEachChild((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`. - */ - getRawValue() { - return this._reduceChildren({}, (acc, control, name) => { - acc[name] = control instanceof FormControl ? control.value : control.getRawValue(); - return acc; - }); - } - /** @internal */ - _syncPendingControls() { - let subtreeUpdated = this._reduceChildren(false, (updated, child) => { - return child._syncPendingControls() ? true : updated; - }); - if (subtreeUpdated) - this.updateValueAndValidity({ onlySelf: true }); - return subtreeUpdated; - } - /** @internal */ - _throwIfControlMissing(name) { - if (!Object.keys(this.controls).length) { - throw new Error(` - There are no form controls registered with this group yet. If you're using ngModel, - you may want to check next tick (e.g. use setTimeout). - `); - } - if (!this.controls[name]) { - throw new Error(`Cannot find form control with name: ${name}.`); - } - } - /** @internal */ - _forEachChild(cb) { - Object.keys(this.controls).forEach(key => { - // The list of controls can change (for ex. controls might be removed) while the loop - // is running (as a result of invoking Forms API in `valueChanges` subscription), so we - // have to null check before invoking the callback. - const control = this.controls[key]; - control && cb(control, key); - }); - } - /** @internal */ - _setUpControls() { - this._forEachChild((control) => { - control.setParent(this); - control._registerOnCollectionChange(this._onCollectionChange); - }); - } - /** @internal */ - _updateValue() { - this.value = this._reduceValue(); - } - /** @internal */ - _anyControls(condition) { - for (const controlName of Object.keys(this.controls)) { - const control = this.controls[controlName]; - if (this.contains(controlName) && condition(control)) { - return true; - } - } - return false; - } - /** @internal */ - _reduceValue() { - return this._reduceChildren({}, (acc, control, name) => { - if (control.enabled || this.disabled) { - acc[name] = control.value; - } - return acc; - }); - } - /** @internal */ - _reduceChildren(initValue, fn) { - let res = initValue; - this._forEachChild((control, name) => { - res = fn(res, control, name); - }); - return res; - } - /** @internal */ - _allControlsDisabled() { - for (const controlName of Object.keys(this.controls)) { - if (this.controls[controlName].enabled) { - return false; - } - } - return Object.keys(this.controls).length > 0 || this.disabled; - } - /** @internal */ - _checkAllValuesPresent(value) { - this._forEachChild((control, name) => { - if (value[name] === undefined) { - throw new Error(`Must supply a value for form control with name: '${name}'.`); - } - }); - } -} -/** - * 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 - */ -class FormArray extends AbstractControl { - /** - * 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 - * - */ - constructor(controls, validatorOrOpts, asyncValidator) { - super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts)); - this.controls = controls; - this._initObservables(); - this._setUpdateStrategy(validatorOrOpts); - this._setUpControls(); - this.updateValueAndValidity({ - onlySelf: true, - // If `asyncValidator` is present, it will trigger control status change from `PENDING` to - // `VALID` or `INVALID`. - // The status should be broadcasted via the `statusChanges` observable, so we set `emitEvent` - // to `true` to allow that during the control creation process. - emitEvent: !!asyncValidator - }); - } - /** - * Get the `AbstractControl` at the given `index` in the array. - * - * @param index Index in the array to retrieve the control - */ - at(index) { - return this.controls[index]; - } - /** - * Insert a new `AbstractControl` at the end of the array. - * - * @param control Form control to be inserted - */ - 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 - */ - 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 - */ - removeAt(index) { - if (this.controls[index]) - this.controls[index]._registerOnCollectionChange(() => { }); - 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 - */ - setControl(index, control) { - if (this.controls[index]) - this.controls[index]._registerOnCollectionChange(() => { }); - 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. - */ - get length() { - return this.controls.length; - } - /** - * 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. - */ - setValue(value, options = {}) { - this._checkAllValuesPresent(value); - value.forEach((newValue, index) => { - this._throwIfControlMissing(index); - this.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. - */ - patchValue(value, options = {}) { - // Even though the `value` argument type doesn't allow `null` and `undefined` values, the - // `patchValue` can be called recursively and inner data structures might have these values, so - // we just ignore such cases when a field containing FormArray instance receives `null` or - // `undefined` as a value. - if (value == null /* both `null` and `undefined` */) - return; - value.forEach((newValue, index) => { - if (this.at(index)) { - this.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. - */ - reset(value = [], options = {}) { - this._forEachChild((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. - */ - getRawValue() { - return this.controls.map((control) => { - return control instanceof FormControl ? control.value : 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); - * } - * ``` - */ - clear() { - if (this.controls.length < 1) - return; - this._forEachChild((control) => control._registerOnCollectionChange(() => { })); - this.controls.splice(0); - this.updateValueAndValidity(); - } - /** @internal */ - _syncPendingControls() { - let subtreeUpdated = this.controls.reduce((updated, child) => { - return child._syncPendingControls() ? true : updated; - }, false); - if (subtreeUpdated) - this.updateValueAndValidity({ onlySelf: true }); - return subtreeUpdated; - } - /** @internal */ - _throwIfControlMissing(index) { - if (!this.controls.length) { - throw new Error(` - There are no form controls registered with this array yet. If you're using ngModel, - you may want to check next tick (e.g. use setTimeout). - `); - } - if (!this.at(index)) { - throw new Error(`Cannot find form control at index ${index}`); - } - } - /** @internal */ - _forEachChild(cb) { - this.controls.forEach((control, index) => { - cb(control, index); - }); - } - /** @internal */ - _updateValue() { - this.value = - this.controls.filter((control) => control.enabled || this.disabled) - .map((control) => control.value); - } - /** @internal */ - _anyControls(condition) { - return this.controls.some((control) => control.enabled && condition(control)); - } - /** @internal */ - _setUpControls() { - this._forEachChild((control) => this._registerControl(control)); - } - /** @internal */ - _checkAllValuesPresent(value) { - this._forEachChild((control, i) => { - if (value[i] === undefined) { - throw new Error(`Must supply a value for form control at index: ${i}.`); - } - }); - } - /** @internal */ - _allControlsDisabled() { - for (const control of this.controls) { - if (control.enabled) - return false; - } - return this.controls.length > 0 || this.disabled; - } - _registerControl(control) { - control.setParent(this); - control._registerOnCollectionChange(this._onCollectionChange); - } -} -/** - * @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 - */ -const formDirectiveProvider = { - provide: ControlContainer, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => NgForm) -}; -const ɵ0 = () => Promise.resolve(null); -const resolvedPromise = /*@__PURE__*/ (ɵ0)(); -let NgForm = /*@__PURE__*/ (() => { - class NgForm extends ControlContainer { - constructor(validators, asyncValidators) { - super(); - /** - * @description - * Returns whether the form submission has been triggered. - */ - this.submitted = false; - this._directives = []; - /** - * @description - * Event emitter for the "ngSubmit" event - */ - this.ngSubmit = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.form = - new FormGroup({}, composeValidators(validators), composeAsyncValidators(asyncValidators)); - } - /** @nodoc */ - ngAfterViewInit() { - this._setUpdateStrategy(); - } - /** - * @description - * The directive instance. - */ - get formDirective() { - return this; - } - /** - * @description - * The internal `FormGroup` instance. - */ - get control() { - 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. - */ - get path() { - return []; - } - /** - * @description - * Returns a map of the controls in this group. - */ - get controls() { - return this.form.controls; - } - /** - * @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. - */ - addControl(dir) { - resolvedPromise.then(() => { - const container = this._findContainer(dir.path); - dir.control = - container.registerControl(dir.name, dir.control); - setUpControl(dir.control, dir); - dir.control.updateValueAndValidity({ emitEvent: false }); - this._directives.push(dir); - }); - } - /** - * @description - * Retrieves the `FormControl` instance from the provided `NgModel` directive. - * - * @param dir The `NgModel` directive instance. - */ - getControl(dir) { - return this.form.get(dir.path); - } - /** - * @description - * Removes the `NgModel` instance from the internal list of directives - * - * @param dir The `NgModel` directive instance. - */ - removeControl(dir) { - resolvedPromise.then(() => { - const container = this._findContainer(dir.path); - if (container) { - container.removeControl(dir.name); - } - removeListItem(this._directives, dir); - }); - } - /** - * @description - * Adds a new `NgModelGroup` directive instance to the form. - * - * @param dir The `NgModelGroup` directive instance. - */ - addFormGroup(dir) { - resolvedPromise.then(() => { - const container = this._findContainer(dir.path); - const 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. - */ - removeFormGroup(dir) { - resolvedPromise.then(() => { - const container = this._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. - */ - getFormGroup(dir) { - return 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. - */ - updateModel(dir, value) { - resolvedPromise.then(() => { - const ctrl = this.form.get(dir.path); - ctrl.setValue(value); - }); - } - /** - * @description - * Sets the value for this `FormGroup`. - * - * @param value The new value - */ - 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 - */ - onSubmit($event) { - 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. - */ - onReset() { - this.resetForm(); - } - /** - * @description - * Resets the form to an initial value and resets its submitted status. - * - * @param value The new value for the form. - */ - resetForm(value = undefined) { - this.form.reset(value); - this.submitted = false; - } - _setUpdateStrategy() { - if (this.options && this.options.updateOn != null) { - this.form._updateOn = this.options.updateOn; - } - } - /** @internal */ - _findContainer(path) { - path.pop(); - return path.length ? this.form.get(path) : this.form; - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formDirectiveProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return NgForm; -})(); -let AbstractFormGroupDirective = /*@__PURE__*/ (() => { - class AbstractFormGroupDirective extends ControlContainer { - /** @nodoc */ - ngOnInit() { - this._checkParentType(); - // Register the group with its parent group. - this.formDirective.addFormGroup(this); - } - /** @nodoc */ - ngOnDestroy() { - if (this.formDirective) { - // Remove the group from its parent group. - this.formDirective.removeFormGroup(this); - } - } - /** - * @description - * The `FormGroup` bound to this directive. - */ - get control() { - return this.formDirective.getFormGroup(this); - } - /** - * @description - * The path to this group from the top-level directive. - */ - get path() { - return controlPath(this.name == null ? this.name : this.name.toString(), this._parent); - } - /** - * @description - * The top-level directive for this group if present, otherwise null. - */ - get formDirective() { - return this._parent ? this._parent.formDirective : null; - } - /** @internal */ - _checkParentType() { } - } - AbstractFormGroupDirective.ɵfac = function AbstractFormGroupDirective_Factory(t) { return ɵAbstractFormGroupDirective_BaseFactory(t || AbstractFormGroupDirective); }; - AbstractFormGroupDirective.ɵdir = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: AbstractFormGroupDirective, features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return AbstractFormGroupDirective; -})(); -const ɵAbstractFormGroupDirective_BaseFactory = /*@__PURE__*/ /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](AbstractFormGroupDirective); -/** - * @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 TemplateDrivenErrors { - static modelParentException() { - throw new Error(` - ngModel cannot be used to register form controls with a parent formGroup directive. Try using - formGroup's partner directive "formControlName" instead. Example: - - ${FormErrorExamples.formControlName} - - Or, if you'd like to avoid registering this form control, indicate that it's standalone in ngModelOptions: - - Example: - - ${FormErrorExamples.ngModelWithFormGroup}`); - } - static formGroupNameException() { - throw new Error(` - ngModel cannot be used to register form controls with a parent formGroupName or formArrayName directive. - - Option 1: Use formControlName instead of ngModel (reactive strategy): - - ${FormErrorExamples.formGroupName} - - Option 2: Update ngModel's parent be ngModelGroup (template-driven strategy): - - ${FormErrorExamples.ngModelGroup}`); - } - static missingNameException() { - throw new Error(`If ngModel is used within a form tag, either the name attribute must be set or the form - control must be defined as 'standalone' in ngModelOptions. - - Example 1: - Example 2: `); - } - static modelGroupParentException() { - throw new Error(` - ngModelGroup cannot be used with a parent formGroup directive. - - Option 1: Use formGroupName instead of ngModelGroup (reactive strategy): - - ${FormErrorExamples.formGroupName} - - Option 2: Use a regular form tag instead of the formGroup directive (template-driven strategy): - - ${FormErrorExamples.ngModelGroup}`); - } -} -/** - * @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 - */ -const modelGroupProvider = { - provide: ControlContainer, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => NgModelGroup) -}; -let NgModelGroup = /*@__PURE__*/ (() => { - class NgModelGroup extends AbstractFormGroupDirective { - constructor(parent, validators, asyncValidators) { - super(); - this._parent = parent; - this._setValidators(validators); - this._setAsyncValidators(asyncValidators); - } - /** @internal */ - _checkParentType() { - if (!(this._parent instanceof NgModelGroup) && !(this._parent instanceof NgForm) && - (typeof ngDevMode === 'undefined' || ngDevMode)) { - TemplateDrivenErrors.modelGroupParentException(); - } - } - } - 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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: NgModelGroup, selectors: [["", "ngModelGroup", ""]], inputs: { name: ["ngModelGroup", "name"] }, exportAs: ["ngModelGroup"], features: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([modelGroupProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return NgModelGroup; -})(); -/** - * @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 - */ -const formControlBinding = { - provide: NgControl, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => NgModel) -}; -const ɵ0$1 = () => Promise.resolve(null); -/** - * `ngModel` forces an additional change detection run when its inputs change: - * E.g.: - * ``` - *
{{myModel.valid}}
- * - * ``` - * 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 an 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`s have been changed. - * - this is a general problem when using `exportAs` for directives! - */ -const resolvedPromise$1 = /*@__PURE__*/ (ɵ0$1)(); -let NgModel = /*@__PURE__*/ (() => { - class NgModel extends NgControl { - constructor(parent, validators, asyncValidators, valueAccessors) { - super(); - this.control = new FormControl(); - /** @internal */ - this._registered = false; - /** - * @description - * Event emitter for producing the `ngModelChange` event after - * the view model updates. - */ - this.update = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this._parent = parent; - this._setValidators(validators); - this._setAsyncValidators(asyncValidators); - this.valueAccessor = selectValueAccessor(this, valueAccessors); - } - /** @nodoc */ - 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; - } - } - /** @nodoc */ - 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. - */ - get path() { - return this._parent ? controlPath(this.name, this._parent) : [this.name]; - } - /** - * @description - * The top-level directive for this control if present, otherwise null. - */ - get formDirective() { - return this._parent ? this._parent.formDirective : null; - } - /** - * @description - * Sets the new value for the view model and emits an `ngModelChange` event. - * - * @param newValue The new value emitted by `ngModelChange`. - */ - viewToModelUpdate(newValue) { - this.viewModel = newValue; - this.update.emit(newValue); - } - _setUpControl() { - this._setUpdateStrategy(); - this._isStandalone() ? this._setUpStandalone() : this.formDirective.addControl(this); - this._registered = true; - } - _setUpdateStrategy() { - if (this.options && this.options.updateOn != null) { - this.control._updateOn = this.options.updateOn; - } - } - _isStandalone() { - return !this._parent || !!(this.options && this.options.standalone); - } - _setUpStandalone() { - setUpControl(this.control, this); - this.control.updateValueAndValidity({ emitEvent: false }); - } - _checkForErrors() { - if (!this._isStandalone()) { - this._checkParentType(); - } - this._checkName(); - } - _checkParentType() { - if (typeof ngDevMode === 'undefined' || ngDevMode) { - if (!(this._parent instanceof NgModelGroup) && - this._parent instanceof AbstractFormGroupDirective) { - TemplateDrivenErrors.formGroupNameException(); - } - else if (!(this._parent instanceof NgModelGroup) && !(this._parent instanceof NgForm)) { - TemplateDrivenErrors.modelParentException(); - } - } - } - _checkName() { - if (this.options && this.options.name) - this.name = this.options.name; - if (!this._isStandalone() && !this.name && (typeof ngDevMode === 'undefined' || ngDevMode)) { - TemplateDrivenErrors.missingNameException(); - } - } - _updateValue(value) { - resolvedPromise$1.then(() => { - this.control.setValue(value, { emitViewToModelChange: false }); - }); - } - _updateDisabled(changes) { - const disabledValue = changes['isDisabled'].currentValue; - const isDisabled = disabledValue === '' || (disabledValue && disabledValue !== 'false'); - resolvedPromise$1.then(() => { - if (isDisabled && !this.control.disabled) { - this.control.disable(); - } - else if (!isDisabled && this.control.disabled) { - this.control.enable(); - } - }); - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formControlBinding]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]] }); - return NgModel; -})(); -let ɵNgNoValidate = /*@__PURE__*/ (() => { - class ɵNgNoValidate { - } - ɵNgNoValidate.ɵfac = function ɵNgNoValidate_Factory(t) { return new (t || ɵNgNoValidate)(); }; - ɵNgNoValidate.ɵdir = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: ɵNgNoValidate, selectors: [["form", 3, "ngNoForm", "", 3, "ngNativeValidate", ""]], hostAttrs: ["novalidate", ""] }); - return ɵNgNoValidate; -})(); -/** - * @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 - */ -const NUMBER_VALUE_ACCESSOR = { - provide: NG_VALUE_ACCESSOR, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => NumberValueAccessor), - multi: true -}; -let NumberValueAccessor = /*@__PURE__*/ (() => { - class NumberValueAccessor extends BuiltInControlValueAccessor { - constructor(_renderer, _elementRef) { - super(); - this._renderer = _renderer; - this._elementRef = _elementRef; - /** - * The registered callback function called when a change or input event occurs on the input - * element. - * @nodoc - */ - this.onChange = (_) => { }; - /** - * The registered callback function called when a blur event occurs on the input element. - * @nodoc - */ - this.onTouched = () => { }; - } - /** - * Sets the "value" property on the input element. - * @nodoc - */ - writeValue(value) { - // The value needs to be normalized for IE9, otherwise it is set to 'null' when null - const normalizedValue = value == null ? '' : value; - this._renderer.setProperty(this._elementRef.nativeElement, 'value', normalizedValue); - } - /** - * Registers a function called when the control value changes. - * @nodoc - */ - registerOnChange(fn) { - this.onChange = (value) => { - fn(value == '' ? null : parseFloat(value)); - }; - } - /** - * Registers a function called when the control is touched. - * @nodoc - */ - registerOnTouched(fn) { - this.onTouched = fn; - } - /** - * Sets the "disabled" property on the input element. - * @nodoc - */ - setDisabledState(isDisabled) { - this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled); - } - } - 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 = /*@__PURE__*/ _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"]("input", function NumberValueAccessor_input_HostBindingHandler($event) { return ctx.onChange($event.target.value); })("blur", function NumberValueAccessor_blur_HostBindingHandler() { return ctx.onTouched(); }); - } - }, features: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([NUMBER_VALUE_ACCESSOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return NumberValueAccessor; -})(); -/** - * @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 - */ -const RADIO_VALUE_ACCESSOR = { - provide: NG_VALUE_ACCESSOR, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => RadioControlValueAccessor), - multi: true -}; -function throwNameError() { - throw new Error(` - If you define both a name and a formControlName attribute on your radio button, their values - must match. Ex: - `); -} -let RadioControlRegistryModule = /*@__PURE__*/ (() => { - class RadioControlRegistryModule { - } - RadioControlRegistryModule.ɵfac = function RadioControlRegistryModule_Factory(t) { return new (t || RadioControlRegistryModule)(); }; - RadioControlRegistryModule.ɵmod = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({ type: RadioControlRegistryModule }); - RadioControlRegistryModule.ɵinj = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({}); - return RadioControlRegistryModule; -})(); -let RadioControlRegistry = /*@__PURE__*/ (() => { - class RadioControlRegistry { - constructor() { - this._accessors = []; - } - /** - * @description - * Adds a control to the internal registry. For internal use only. - */ - add(control, accessor) { - this._accessors.push([control, accessor]); - } - /** - * @description - * Removes a control from the internal registry. For internal use only. - */ - remove(accessor) { - for (let 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. - */ - select(accessor) { - this._accessors.forEach((c) => { - if (this._isSameGroup(c, accessor) && c[1] !== accessor) { - c[1].fireUncheck(accessor.value); - } - }); - } - _isSameGroup(controlPair, accessor) { - if (!controlPair[0].control) - return false; - return controlPair[0]._parent === accessor._control._parent && - controlPair[1].name === accessor.name; - } - } - RadioControlRegistry.ɵfac = function RadioControlRegistry_Factory(t) { return new (t || RadioControlRegistry)(); }; - RadioControlRegistry.ɵprov = /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({ factory: function RadioControlRegistry_Factory() { return new RadioControlRegistry(); }, token: RadioControlRegistry, providedIn: RadioControlRegistryModule }); - return RadioControlRegistry; -})(); -let RadioControlValueAccessor = /*@__PURE__*/ (() => { - class RadioControlValueAccessor extends BuiltInControlValueAccessor { - constructor(_renderer, _elementRef, _registry, _injector) { - super(); - this._renderer = _renderer; - this._elementRef = _elementRef; - this._registry = _registry; - this._injector = _injector; - /** - * The registered callback function called when a change event occurs on the input element. - * @nodoc - */ - this.onChange = () => { }; - /** - * The registered callback function called when a blur event occurs on the input element. - * @nodoc - */ - this.onTouched = () => { }; - } - /** @nodoc */ - ngOnInit() { - this._control = this._injector.get(NgControl); - this._checkName(); - this._registry.add(this._control, this); - } - /** @nodoc */ - ngOnDestroy() { - this._registry.remove(this); - } - /** - * Sets the "checked" property value on the radio input element. - * @nodoc - */ - writeValue(value) { - this._state = value === this.value; - this._renderer.setProperty(this._elementRef.nativeElement, 'checked', this._state); - } - /** - * Registers a function called when the control value changes. - * @nodoc - */ - registerOnChange(fn) { - this._fn = fn; - this.onChange = () => { - fn(this.value); - this._registry.select(this); - }; - } - /** - * Sets the "value" on the radio input element and unchecks it. - * - * @param value - */ - fireUncheck(value) { - this.writeValue(value); - } - /** - * Registers a function called when the control is touched. - * @nodoc - */ - registerOnTouched(fn) { - this.onTouched = fn; - } - /** - * Sets the "disabled" property on the input element. - * @nodoc - */ - setDisabledState(isDisabled) { - this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled); - } - _checkName() { - if (this.name && this.formControlName && this.name !== this.formControlName && - (typeof ngDevMode === 'undefined' || ngDevMode)) { - throwNameError(); - } - if (!this.name && this.formControlName) - this.name = this.formControlName; - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([RADIO_VALUE_ACCESSOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return RadioControlValueAccessor; -})(); -/** - * @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 - */ -const RANGE_VALUE_ACCESSOR = { - provide: NG_VALUE_ACCESSOR, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => RangeValueAccessor), - multi: true -}; -let RangeValueAccessor = /*@__PURE__*/ (() => { - class RangeValueAccessor extends BuiltInControlValueAccessor { - constructor(_renderer, _elementRef) { - super(); - this._renderer = _renderer; - this._elementRef = _elementRef; - /** - * The registered callback function called when a change or input event occurs on the input - * element. - * @nodoc - */ - this.onChange = (_) => { }; - /** - * The registered callback function called when a blur event occurs on the input element. - * @nodoc - */ - this.onTouched = () => { }; - } - /** - * Sets the "value" property on the input element. - * @nodoc - */ - writeValue(value) { - this._renderer.setProperty(this._elementRef.nativeElement, 'value', parseFloat(value)); - } - /** - * Registers a function called when the control value changes. - * @nodoc - */ - registerOnChange(fn) { - this.onChange = (value) => { - fn(value == '' ? null : parseFloat(value)); - }; - } - /** - * Registers a function called when the control is touched. - * @nodoc - */ - registerOnTouched(fn) { - this.onTouched = fn; - } - /** - * Sets the "disabled" property on the range input element. - * @nodoc - */ - setDisabledState(isDisabled) { - this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled); - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([RANGE_VALUE_ACCESSOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return RangeValueAccessor; -})(); -/** - * @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 - */ -/** - * Token to provide to turn off the ngModel warning on formControl and formControlName. - */ -const NG_MODEL_WITH_FORM_CONTROL_WARNING = /*@__PURE__*/ new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('NgModelWithFormControlWarning'); -const formControlBinding$1 = { - provide: NgControl, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => FormControlDirective) -}; -let FormControlDirective = /*@__PURE__*/ (() => { - class FormControlDirective extends NgControl { - constructor(validators, asyncValidators, valueAccessors, _ngModelWarningConfig) { - super(); - this._ngModelWarningConfig = _ngModelWarningConfig; - /** @deprecated as of v6 */ - this.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 - */ - this._ngModelWarningSent = false; - this._setValidators(validators); - this._setAsyncValidators(asyncValidators); - this.valueAccessor = selectValueAccessor(this, valueAccessors); - } - /** - * @description - * Triggers a warning in dev mode that this input should not be used with reactive forms. - */ - set isDisabled(isDisabled) { - if (typeof ngDevMode === 'undefined' || ngDevMode) { - ReactiveErrors.disabledAttrWarning(); - } - } - /** @nodoc */ - ngOnChanges(changes) { - if (this._isControlChanged(changes)) { - const previousForm = changes['form'].previousValue; - if (previousForm) { - cleanUpControl(previousForm, this, /* validateControlPresenceOnChange */ false); - } - setUpControl(this.form, this); - if (this.control.disabled && this.valueAccessor.setDisabledState) { - this.valueAccessor.setDisabledState(true); - } - this.form.updateValueAndValidity({ emitEvent: false }); - } - if (isPropertyUpdated(changes, this.viewModel)) { - if (typeof ngDevMode === 'undefined' || ngDevMode) { - _ngModelWarning('formControl', FormControlDirective, this, this._ngModelWarningConfig); - } - this.form.setValue(this.model); - this.viewModel = this.model; - } - } - /** @nodoc */ - ngOnDestroy() { - if (this.form) { - cleanUpControl(this.form, this, /* validateControlPresenceOnChange */ false); - } - } - /** - * @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. - */ - get path() { - return []; - } - /** - * @description - * The `FormControl` bound to this directive. - */ - get control() { - return this.form; - } - /** - * @description - * Sets the new value for the view model and emits an `ngModelChange` event. - * - * @param newValue The new value for the view model. - */ - viewToModelUpdate(newValue) { - this.viewModel = newValue; - this.update.emit(newValue); - } - _isControlChanged(changes) { - return changes.hasOwnProperty('form'); - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _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; - return FormControlDirective; -})(); -/** - * @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 - */ -const formDirectiveProvider$1 = { - provide: ControlContainer, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => FormGroupDirective) -}; -let FormGroupDirective = /*@__PURE__*/ (() => { - class FormGroupDirective extends ControlContainer { - constructor(validators, asyncValidators) { - super(); - this.validators = validators; - this.asyncValidators = asyncValidators; - /** - * @description - * Reports whether the form submission has been triggered. - */ - this.submitted = false; - /** - * Callback that should be invoked when controls in FormGroup or FormArray collection change - * (added or removed). This callback triggers corresponding DOM updates. - */ - this._onCollectionChange = () => this._updateDomValue(); - /** - * @description - * Tracks the list of added `FormControlName` instances - */ - this.directives = []; - /** - * @description - * Tracks the `FormGroup` bound to this directive. - */ - this.form = null; - /** - * @description - * Emits an event when the form submission has been triggered. - */ - this.ngSubmit = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this._setValidators(validators); - this._setAsyncValidators(asyncValidators); - } - /** @nodoc */ - ngOnChanges(changes) { - this._checkFormPresent(); - if (changes.hasOwnProperty('form')) { - this._updateValidators(); - this._updateDomValue(); - this._updateRegistrations(); - this._oldForm = this.form; - } - } - /** @nodoc */ - ngOnDestroy() { - if (this.form) { - cleanUpValidators(this.form, this, /* handleOnValidatorChange */ false); - // Currently the `onCollectionChange` callback is rewritten each time the - // `_registerOnCollectionChange` function is invoked. The implication is that cleanup should - // happen *only* when the `onCollectionChange` callback was set by this directive instance. - // Otherwise it might cause overriding a callback of some other directive instances. We should - // consider updating this logic later to make it similar to how `onChange` callbacks are - // handled, see https://github.com/angular/angular/issues/39732 for additional info. - if (this.form._onCollectionChange === this._onCollectionChange) { - this.form._registerOnCollectionChange(() => { }); - } - } - } - /** - * @description - * Returns this directive's instance. - */ - get formDirective() { - return this; - } - /** - * @description - * Returns the `FormGroup` bound to this directive. - */ - get control() { - 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. - */ - get path() { - return []; - } - /** - * @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. - */ - addControl(dir) { - const 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. - */ - getControl(dir) { - return this.form.get(dir.path); - } - /** - * @description - * Removes the `FormControlName` instance from the internal list of directives - * - * @param dir The `FormControlName` directive instance. - */ - removeControl(dir) { - cleanUpControl(dir.control || null, dir, /* validateControlPresenceOnChange */ false); - removeListItem(this.directives, dir); - } - /** - * Adds a new `FormGroupName` directive instance to the form. - * - * @param dir The `FormGroupName` directive instance. - */ - addFormGroup(dir) { - this._setUpFormContainer(dir); - } - /** - * Performs the necessary cleanup when a `FormGroupName` directive instance is removed from the - * view. - * - * @param dir The `FormGroupName` directive instance. - */ - removeFormGroup(dir) { - this._cleanUpFormContainer(dir); - } - /** - * @description - * Retrieves the `FormGroup` for a provided `FormGroupName` directive instance - * - * @param dir The `FormGroupName` directive instance. - */ - getFormGroup(dir) { - return this.form.get(dir.path); - } - /** - * Performs the necessary setup when a `FormArrayName` directive instance is added to the view. - * - * @param dir The `FormArrayName` directive instance. - */ - addFormArray(dir) { - this._setUpFormContainer(dir); - } - /** - * Performs the necessary cleanup when a `FormArrayName` directive instance is removed from the - * view. - * - * @param dir The `FormArrayName` directive instance. - */ - removeFormArray(dir) { - this._cleanUpFormContainer(dir); - } - /** - * @description - * Retrieves the `FormArray` for a provided `FormArrayName` directive instance. - * - * @param dir The `FormArrayName` directive instance. - */ - getFormArray(dir) { - return 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. - */ - updateModel(dir, value) { - const ctrl = 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 - */ - onSubmit($event) { - 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. - */ - onReset() { - this.resetForm(); - } - /** - * @description - * Resets the form to an initial value and resets its submitted status. - * - * @param value The new value for the form. - */ - resetForm(value = undefined) { - this.form.reset(value); - this.submitted = false; - } - /** @internal */ - _updateDomValue() { - this.directives.forEach(dir => { - const oldCtrl = dir.control; - const newCtrl = this.form.get(dir.path); - if (oldCtrl !== newCtrl) { - // Note: the value of the `dir.control` may not be defined, for example when it's a first - // `FormControl` that is added to a `FormGroup` instance (via `addControl` call). - cleanUpControl(oldCtrl || null, dir); - // Check whether new control at the same location inside the corresponding `FormGroup` is an - // instance of `FormControl` and perform control setup only if that's the case. - // Note: we don't need to clear the list of directives (`this.directives`) here, it would be - // taken care of in the `removeControl` method invoked when corresponding `formControlName` - // directive instance is being removed (invoked from `FormControlName.ngOnDestroy`). - if (newCtrl instanceof FormControl) { - setUpControl(newCtrl, dir); - dir.control = newCtrl; - } - } - }); - this.form._updateTreeValidity({ emitEvent: false }); - } - _setUpFormContainer(dir) { - const ctrl = this.form.get(dir.path); - setUpFormContainer(ctrl, dir); - // NOTE: this operation looks unnecessary in case no new validators were added in - // `setUpFormContainer` call. Consider updating this code to match the logic in - // `_cleanUpFormContainer` function. - ctrl.updateValueAndValidity({ emitEvent: false }); - } - _cleanUpFormContainer(dir) { - if (this.form) { - const ctrl = this.form.get(dir.path); - if (ctrl) { - const isControlUpdated = cleanUpFormContainer(ctrl, dir); - if (isControlUpdated) { - // Run validity check only in case a control was updated (i.e. view validators were - // removed) as removing view validators might cause validity to change. - ctrl.updateValueAndValidity({ emitEvent: false }); - } - } - } - } - _updateRegistrations() { - this.form._registerOnCollectionChange(this._onCollectionChange); - if (this._oldForm) { - this._oldForm._registerOnCollectionChange(() => { }); - } - } - _updateValidators() { - setUpValidators(this.form, this, /* handleOnValidatorChange */ false); - if (this._oldForm) { - cleanUpValidators(this._oldForm, this, /* handleOnValidatorChange */ false); - } - } - _checkFormPresent() { - if (!this.form && (typeof ngDevMode === 'undefined' || ngDevMode)) { - ReactiveErrors.missingFormException(); - } - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formDirectiveProvider$1]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"], _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]] }); - return FormGroupDirective; -})(); -/** - * @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 - */ -const formGroupNameProvider = { - provide: ControlContainer, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => FormGroupName) -}; -let FormGroupName = /*@__PURE__*/ (() => { - class FormGroupName extends AbstractFormGroupDirective { - constructor(parent, validators, asyncValidators) { - super(); - this._parent = parent; - this._setValidators(validators); - this._setAsyncValidators(asyncValidators); - } - /** @internal */ - _checkParentType() { - if (_hasInvalidParent(this._parent) && (typeof ngDevMode === 'undefined' || ngDevMode)) { - ReactiveErrors.groupParentException(); - } - } - } - 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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: FormGroupName, selectors: [["", "formGroupName", ""]], inputs: { name: ["formGroupName", "name"] }, features: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formGroupNameProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return FormGroupName; -})(); -const formArrayNameProvider = { - provide: ControlContainer, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => FormArrayName) -}; -let FormArrayName = /*@__PURE__*/ (() => { - class FormArrayName extends ControlContainer { - constructor(parent, validators, asyncValidators) { - super(); - this._parent = parent; - this._setValidators(validators); - this._setAsyncValidators(asyncValidators); - } - /** - * 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. - * @nodoc - */ - ngOnInit() { - this._checkParentType(); - this.formDirective.addFormArray(this); - } - /** - * A lifecycle method called before the directive's instance is destroyed. For internal use only. - * @nodoc - */ - ngOnDestroy() { - if (this.formDirective) { - this.formDirective.removeFormArray(this); - } - } - /** - * @description - * The `FormArray` bound to this directive. - */ - get control() { - return this.formDirective.getFormArray(this); - } - /** - * @description - * The top-level directive for this group if present, otherwise null. - */ - get formDirective() { - return this._parent ? 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. - */ - get path() { - return controlPath(this.name == null ? this.name : this.name.toString(), this._parent); - } - _checkParentType() { - if (_hasInvalidParent(this._parent) && (typeof ngDevMode === 'undefined' || ngDevMode)) { - ReactiveErrors.arrayParentException(); - } - } - } - 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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: FormArrayName, selectors: [["", "formArrayName", ""]], inputs: { name: ["formArrayName", "name"] }, features: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([formArrayNameProvider]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return FormArrayName; -})(); -function _hasInvalidParent(parent) { - return !(parent instanceof FormGroupName) && !(parent instanceof FormGroupDirective) && - !(parent instanceof FormArrayName); -} -/** - * @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 - */ -const controlNameBinding = { - provide: NgControl, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => FormControlName) -}; -let FormControlName = /*@__PURE__*/ (() => { - class FormControlName extends NgControl { - constructor(parent, validators, asyncValidators, valueAccessors, _ngModelWarningConfig) { - super(); - this._ngModelWarningConfig = _ngModelWarningConfig; - this._added = false; - /** @deprecated as of v6 */ - this.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 - */ - this._ngModelWarningSent = false; - this._parent = parent; - this._setValidators(validators); - this._setAsyncValidators(asyncValidators); - this.valueAccessor = selectValueAccessor(this, valueAccessors); - } - /** - * @description - * Triggers a warning in dev mode that this input should not be used with reactive forms. - */ - set isDisabled(isDisabled) { - if (typeof ngDevMode === 'undefined' || ngDevMode) { - ReactiveErrors.disabledAttrWarning(); - } - } - /** @nodoc */ - ngOnChanges(changes) { - if (!this._added) - this._setUpControl(); - if (isPropertyUpdated(changes, this.viewModel)) { - if (typeof ngDevMode === 'undefined' || ngDevMode) { - _ngModelWarning('formControlName', FormControlName, this, this._ngModelWarningConfig); - } - this.viewModel = this.model; - this.formDirective.updateModel(this, this.model); - } - } - /** @nodoc */ - 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. - */ - 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. - */ - get path() { - return controlPath(this.name == null ? this.name : this.name.toString(), this._parent); - } - /** - * @description - * The top-level directive for this group if present, otherwise null. - */ - get formDirective() { - return this._parent ? this._parent.formDirective : null; - } - _checkParentType() { - if (typeof ngDevMode === 'undefined' || ngDevMode) { - 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(); - } - } - } - _setUpControl() { - this._checkParentType(); - this.control = this.formDirective.addControl(this); - if (this.control.disabled && this.valueAccessor.setDisabledState) { - this.valueAccessor.setDisabledState(true); - } - this._added = true; - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _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; - return FormControlName; -})(); -/** - * @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 - */ -const SELECT_VALUE_ACCESSOR = { - provide: NG_VALUE_ACCESSOR, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => SelectControlValueAccessor), - multi: true -}; -function _buildValueString(id, value) { - if (id == null) - return `${value}`; - if (value && typeof value === 'object') - value = 'Object'; - return `${id}: ${value}`.slice(0, 50); -} -function _extractId(valueString) { - return valueString.split(':')[0]; -} -let SelectControlValueAccessor = /*@__PURE__*/ (() => { - class SelectControlValueAccessor extends BuiltInControlValueAccessor { - constructor(_renderer, _elementRef) { - super(); - this._renderer = _renderer; - this._elementRef = _elementRef; - /** @internal */ - this._optionMap = new Map(); - /** @internal */ - this._idCounter = 0; - /** - * The registered callback function called when a change event occurs on the input element. - * @nodoc - */ - this.onChange = (_) => { }; - /** - * The registered callback function called when a blur event occurs on the input element. - * @nodoc - */ - this.onTouched = () => { }; - this._compareWith = Object.is; - } - /** - * @description - * Tracks the option comparison algorithm for tracking identities when - * checking for changes. - */ - set compareWith(fn) { - if (typeof fn !== 'function' && (typeof ngDevMode === 'undefined' || ngDevMode)) { - throw new Error(`compareWith must be a function, but received ${JSON.stringify(fn)}`); - } - this._compareWith = fn; - } - /** - * Sets the "value" property on the input element. The "selectedIndex" - * property is also set if an ID is provided on the option element. - * @nodoc - */ - writeValue(value) { - this.value = value; - const id = this._getOptionId(value); - if (id == null) { - this._renderer.setProperty(this._elementRef.nativeElement, 'selectedIndex', -1); - } - const valueString = _buildValueString(id, value); - this._renderer.setProperty(this._elementRef.nativeElement, 'value', valueString); - } - /** - * Registers a function called when the control value changes. - * @nodoc - */ - registerOnChange(fn) { - this.onChange = (valueString) => { - this.value = this._getOptionValue(valueString); - fn(this.value); - }; - } - /** - * Registers a function called when the control is touched. - * @nodoc - */ - registerOnTouched(fn) { - this.onTouched = fn; - } - /** - * Sets the "disabled" property on the select input element. - * @nodoc - */ - setDisabledState(isDisabled) { - this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled); - } - /** @internal */ - _registerOption() { - return (this._idCounter++).toString(); - } - /** @internal */ - _getOptionId(value) { - for (const id of Array.from(this._optionMap.keys())) { - if (this._compareWith(this._optionMap.get(id), value)) - return id; - } - return null; - } - /** @internal */ - _getOptionValue(valueString) { - const id = _extractId(valueString); - return this._optionMap.has(id) ? this._optionMap.get(id) : valueString; - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([SELECT_VALUE_ACCESSOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return SelectControlValueAccessor; -})(); -let NgSelectOption = /*@__PURE__*/ (() => { - class NgSelectOption { - constructor(_element, _renderer, _select) { - 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. - */ - set ngValue(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. - */ - set value(value) { - this._setElementValue(value); - if (this._select) - this._select.writeValue(this._select.value); - } - /** @internal */ - _setElementValue(value) { - this._renderer.setProperty(this._element.nativeElement, 'value', value); - } - /** @nodoc */ - ngOnDestroy() { - if (this._select) { - this._select._optionMap.delete(this.id); - this._select.writeValue(this._select.value); - } - } - } - 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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: NgSelectOption, selectors: [["option"]], inputs: { ngValue: "ngValue", value: "value" } }); - return NgSelectOption; -})(); -/** - * @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 - */ -const SELECT_MULTIPLE_VALUE_ACCESSOR = { - provide: NG_VALUE_ACCESSOR, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => SelectMultipleControlValueAccessor), - multi: true -}; -function _buildValueString$1(id, value) { - if (id == null) - return `${value}`; - if (typeof value === 'string') - value = `'${value}'`; - if (value && typeof value === 'object') - value = 'Object'; - return `${id}: ${value}`.slice(0, 50); -} -function _extractId$1(valueString) { - return valueString.split(':')[0]; -} -/** Mock interface for HTMLCollection */ -class HTMLCollection { -} -let SelectMultipleControlValueAccessor = /*@__PURE__*/ (() => { - class SelectMultipleControlValueAccessor extends BuiltInControlValueAccessor { - constructor(_renderer, _elementRef) { - super(); - this._renderer = _renderer; - this._elementRef = _elementRef; - /** @internal */ - this._optionMap = new Map(); - /** @internal */ - this._idCounter = 0; - /** - * The registered callback function called when a change event occurs on the input element. - * @nodoc - */ - this.onChange = (_) => { }; - /** - * The registered callback function called when a blur event occurs on the input element. - * @nodoc - */ - this.onTouched = () => { }; - this._compareWith = Object.is; - } - /** - * @description - * Tracks the option comparison algorithm for tracking identities when - * checking for changes. - */ - set compareWith(fn) { - if (typeof fn !== 'function' && (typeof ngDevMode === 'undefined' || ngDevMode)) { - throw new Error(`compareWith must be a function, but received ${JSON.stringify(fn)}`); - } - this._compareWith = fn; - } - /** - * Sets the "value" property on one or of more of the select's options. - * @nodoc - */ - writeValue(value) { - this.value = value; - let optionSelectedStateSetter; - if (Array.isArray(value)) { - // convert values to ids - const ids = value.map((v) => this._getOptionId(v)); - optionSelectedStateSetter = (opt, o) => { - opt._setSelected(ids.indexOf(o.toString()) > -1); - }; - } - else { - optionSelectedStateSetter = (opt, o) => { - opt._setSelected(false); - }; - } - this._optionMap.forEach(optionSelectedStateSetter); - } - /** - * Registers a function called when the control value changes - * and writes an array of the selected options. - * @nodoc - */ - registerOnChange(fn) { - this.onChange = (_) => { - const selected = []; - if (_.selectedOptions !== undefined) { - const options = _.selectedOptions; - for (let i = 0; i < options.length; i++) { - const opt = options.item(i); - const val = this._getOptionValue(opt.value); - selected.push(val); - } - } - // Degrade on IE - else { - const options = _.options; - for (let i = 0; i < options.length; i++) { - const opt = options.item(i); - if (opt.selected) { - const val = this._getOptionValue(opt.value); - selected.push(val); - } - } - } - this.value = selected; - fn(selected); - }; - } - /** - * Registers a function called when the control is touched. - * @nodoc - */ - registerOnTouched(fn) { - this.onTouched = fn; - } - /** - * Sets the "disabled" property on the select input element. - * @nodoc - */ - setDisabledState(isDisabled) { - this._renderer.setProperty(this._elementRef.nativeElement, 'disabled', isDisabled); - } - /** @internal */ - _registerOption(value) { - const id = (this._idCounter++).toString(); - this._optionMap.set(id, value); - return id; - } - /** @internal */ - _getOptionId(value) { - for (const id of Array.from(this._optionMap.keys())) { - if (this._compareWith(this._optionMap.get(id)._value, value)) - return id; - } - return null; - } - /** @internal */ - _getOptionValue(valueString) { - const id = _extractId$1(valueString); - return this._optionMap.has(id) ? this._optionMap.get(id)._value : valueString; - } - } - 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 = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([SELECT_MULTIPLE_VALUE_ACCESSOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return SelectMultipleControlValueAccessor; -})(); -let ɵNgSelectMultipleOption = /*@__PURE__*/ (() => { - class ɵNgSelectMultipleOption { - constructor(_element, _renderer, _select) { - 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. - */ - set ngValue(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. - */ - set value(value) { - if (this._select) { - this._value = value; - this._setElementValue(_buildValueString$1(this.id, value)); - this._select.writeValue(this._select.value); - } - else { - this._setElementValue(value); - } - } - /** @internal */ - _setElementValue(value) { - this._renderer.setProperty(this._element.nativeElement, 'value', value); - } - /** @internal */ - _setSelected(selected) { - this._renderer.setProperty(this._element.nativeElement, 'selected', selected); - } - /** @nodoc */ - ngOnDestroy() { - if (this._select) { - this._select._optionMap.delete(this.id); - this._select.writeValue(this._select.value); - } - } - } - ɵ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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: ɵNgSelectMultipleOption, selectors: [["option"]], inputs: { ngValue: "ngValue", value: "value" } }); - return ɵNgSelectMultipleOption; -})(); -/** - * @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 - */ -/** - * @description - * Provider which adds `RequiredValidator` to the `NG_VALIDATORS` multi-provider list. - */ -const REQUIRED_VALIDATOR = { - provide: NG_VALIDATORS, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => RequiredValidator), - multi: true -}; -/** - * @description - * Provider which adds `CheckboxRequiredValidator` to the `NG_VALIDATORS` multi-provider list. - */ -const CHECKBOX_REQUIRED_VALIDATOR = { - provide: NG_VALIDATORS, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => CheckboxRequiredValidator), - multi: true -}; -let RequiredValidator = /*@__PURE__*/ (() => { - class RequiredValidator { - constructor() { - this._required = false; - } - /** - * @description - * Tracks changes to the required attribute bound to this directive. - */ - get required() { - return this._required; - } - set required(value) { - this._required = value != null && value !== false && `${value}` !== 'false'; - if (this._onChange) - this._onChange(); - } - /** - * Method that validates whether the control is empty. - * Returns the validation result if enabled, otherwise null. - * @nodoc - */ - validate(control) { - return this.required ? requiredValidator(control) : null; - } - /** - * Registers a callback function to call when the validator inputs change. - * @nodoc - */ - registerOnValidatorChange(fn) { - this._onChange = fn; - } - } - RequiredValidator.ɵfac = function RequiredValidator_Factory(t) { return new (t || RequiredValidator)(); }; - RequiredValidator.ɵdir = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([REQUIRED_VALIDATOR])] }); - return RequiredValidator; -})(); -let CheckboxRequiredValidator = /*@__PURE__*/ (() => { - class CheckboxRequiredValidator extends RequiredValidator { - /** - * Method that validates whether or not the checkbox has been checked. - * Returns the validation result if enabled, otherwise null. - * @nodoc - */ - validate(control) { - return this.required ? requiredTrueValidator(control) : null; - } - } - CheckboxRequiredValidator.ɵfac = function CheckboxRequiredValidator_Factory(t) { return ɵCheckboxRequiredValidator_BaseFactory(t || CheckboxRequiredValidator); }; - CheckboxRequiredValidator.ɵdir = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([CHECKBOX_REQUIRED_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵInheritDefinitionFeature"]] }); - return CheckboxRequiredValidator; -})(); -const ɵCheckboxRequiredValidator_BaseFactory = /*@__PURE__*/ /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetInheritedFactory"](CheckboxRequiredValidator); -/** - * @description - * Provider which adds `EmailValidator` to the `NG_VALIDATORS` multi-provider list. - */ -const EMAIL_VALIDATOR = { - provide: NG_VALIDATORS, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => EmailValidator), - multi: true -}; -let EmailValidator = /*@__PURE__*/ (() => { - class EmailValidator { - constructor() { - this._enabled = false; - } - /** - * @description - * Tracks changes to the email attribute bound to this directive. - */ - set email(value) { - this._enabled = value === '' || value === true || value === 'true'; - if (this._onChange) - this._onChange(); - } - /** - * Method that validates whether an email address is valid. - * Returns the validation result if enabled, otherwise null. - * @nodoc - */ - validate(control) { - return this._enabled ? emailValidator(control) : null; - } - /** - * Registers a callback function to call when the validator inputs change. - * @nodoc - */ - registerOnValidatorChange(fn) { - this._onChange = fn; - } - } - EmailValidator.ɵfac = function EmailValidator_Factory(t) { return new (t || EmailValidator)(); }; - EmailValidator.ɵdir = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: EmailValidator, selectors: [["", "email", "", "formControlName", ""], ["", "email", "", "formControl", ""], ["", "email", "", "ngModel", ""]], inputs: { email: "email" }, features: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([EMAIL_VALIDATOR])] }); - return EmailValidator; -})(); -/** - * @description - * Provider which adds `MinLengthValidator` to the `NG_VALIDATORS` multi-provider list. - */ -const MIN_LENGTH_VALIDATOR = { - provide: NG_VALIDATORS, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => MinLengthValidator), - multi: true -}; -let MinLengthValidator = /*@__PURE__*/ (() => { - class MinLengthValidator { - constructor() { - this._validator = nullValidator; - } - /** @nodoc */ - ngOnChanges(changes) { - if ('minlength' in changes) { - this._createValidator(); - if (this._onChange) - this._onChange(); - } - } - /** - * Method that validates whether the value meets a minimum length requirement. - * Returns the validation result if enabled, otherwise null. - * @nodoc - */ - validate(control) { - return this.minlength == null ? null : this._validator(control); - } - /** - * Registers a callback function to call when the validator inputs change. - * @nodoc - */ - registerOnValidatorChange(fn) { - this._onChange = fn; - } - _createValidator() { - this._validator = minLengthValidator(typeof this.minlength === 'number' ? this.minlength : parseInt(this.minlength, 10)); - } - } - MinLengthValidator.ɵfac = function MinLengthValidator_Factory(t) { return new (t || MinLengthValidator)(); }; - MinLengthValidator.ɵdir = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([MIN_LENGTH_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]] }); - return MinLengthValidator; -})(); -/** - * @description - * Provider which adds `MaxLengthValidator` to the `NG_VALIDATORS` multi-provider list. - */ -const MAX_LENGTH_VALIDATOR = { - provide: NG_VALIDATORS, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => MaxLengthValidator), - multi: true -}; -let MaxLengthValidator = /*@__PURE__*/ (() => { - class MaxLengthValidator { - constructor() { - this._validator = nullValidator; - } - /** @nodoc */ - ngOnChanges(changes) { - if ('maxlength' in changes) { - this._createValidator(); - if (this._onChange) - this._onChange(); - } - } - /** - * Method that validates whether the value exceeds the maximum length requirement. - * @nodoc - */ - validate(control) { - return this.maxlength != null ? this._validator(control) : null; - } - /** - * Registers a callback function to call when the validator inputs change. - * @nodoc - */ - registerOnValidatorChange(fn) { - this._onChange = fn; - } - _createValidator() { - this._validator = maxLengthValidator(typeof this.maxlength === 'number' ? this.maxlength : parseInt(this.maxlength, 10)); - } - } - MaxLengthValidator.ɵfac = function MaxLengthValidator_Factory(t) { return new (t || MaxLengthValidator)(); }; - MaxLengthValidator.ɵdir = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([MAX_LENGTH_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]] }); - return MaxLengthValidator; -})(); -/** - * @description - * Provider which adds `PatternValidator` to the `NG_VALIDATORS` multi-provider list. - */ -const PATTERN_VALIDATOR = { - provide: NG_VALIDATORS, - useExisting: /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["forwardRef"])(() => PatternValidator), - multi: true -}; -let PatternValidator = /*@__PURE__*/ (() => { - class PatternValidator { - constructor() { - this._validator = nullValidator; - } - /** @nodoc */ - ngOnChanges(changes) { - if ('pattern' in changes) { - this._createValidator(); - if (this._onChange) - this._onChange(); - } - } - /** - * Method that validates whether the value matches the pattern requirement. - * @nodoc - */ - validate(control) { - return this._validator(control); - } - /** - * Registers a callback function to call when the validator inputs change. - * @nodoc - */ - registerOnValidatorChange(fn) { - this._onChange = fn; - } - _createValidator() { - this._validator = patternValidator(this.pattern); - } - } - PatternValidator.ɵfac = function PatternValidator_Factory(t) { return new (t || PatternValidator)(); }; - PatternValidator.ɵdir = /*@__PURE__*/ _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: [/*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([PATTERN_VALIDATOR]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵNgOnChangesFeature"]] }); - return PatternValidator; -})(); -/** - * @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 - */ -const SHARED_FORM_DIRECTIVES = [ - ɵNgNoValidate, - NgSelectOption, - ɵNgSelectMultipleOption, - DefaultValueAccessor, - NumberValueAccessor, - RangeValueAccessor, - CheckboxControlValueAccessor, - SelectControlValueAccessor, - SelectMultipleControlValueAccessor, - RadioControlValueAccessor, - NgControlStatus, - NgControlStatusGroup, - RequiredValidator, - MinLengthValidator, - MaxLengthValidator, - PatternValidator, - CheckboxRequiredValidator, - EmailValidator, -]; -const TEMPLATE_DRIVEN_DIRECTIVES = [NgModel, NgModelGroup, NgForm]; -const REACTIVE_DRIVEN_DIRECTIVES = [FormControlDirective, FormGroupDirective, FormControlName, FormGroupName, FormArrayName]; -let ɵInternalFormsSharedModule = /*@__PURE__*/ (() => { - class ɵInternalFormsSharedModule { - } - ɵInternalFormsSharedModule.ɵfac = function ɵInternalFormsSharedModule_Factory(t) { return new (t || ɵInternalFormsSharedModule)(); }; - ɵInternalFormsSharedModule.ɵmod = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({ type: ɵInternalFormsSharedModule }); - ɵInternalFormsSharedModule.ɵinj = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({ imports: [[RadioControlRegistryModule]] }); - return ɵInternalFormsSharedModule; -})(); -/*@__PURE__*/ (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], imports: [RadioControlRegistryModule], exports: [ɵNgNoValidate, NgSelectOption, ɵNgSelectMultipleOption, DefaultValueAccessor, NumberValueAccessor, RangeValueAccessor, CheckboxControlValueAccessor, SelectControlValueAccessor, SelectMultipleControlValueAccessor, RadioControlValueAccessor, NgControlStatus, NgControlStatusGroup, RequiredValidator, MinLengthValidator, MaxLengthValidator, PatternValidator, CheckboxRequiredValidator, EmailValidator] }); })(); -let FormsModule = /*@__PURE__*/ (() => { - class FormsModule { - } - FormsModule.ɵfac = function FormsModule_Factory(t) { return new (t || FormsModule)(); }; - FormsModule.ɵmod = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({ type: FormsModule }); - FormsModule.ɵinj = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({ imports: [ɵInternalFormsSharedModule] }); - return FormsModule; -})(); -/*@__PURE__*/ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](FormsModule, { declarations: [NgModel, NgModelGroup, NgForm], exports: [ɵInternalFormsSharedModule, NgModel, NgModelGroup, NgForm] }); })(); -let ReactiveFormsModule = /*@__PURE__*/ (() => { - class ReactiveFormsModule { - /** - * @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. - */ - static withConfig(opts) { - return { - ngModule: ReactiveFormsModule, - providers: [ - { provide: NG_MODEL_WITH_FORM_CONTROL_WARNING, useValue: opts.warnOnNgModelWithFormControl } - ] - }; - } - } - ReactiveFormsModule.ɵfac = function ReactiveFormsModule_Factory(t) { return new (t || ReactiveFormsModule)(); }; - ReactiveFormsModule.ɵmod = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({ type: ReactiveFormsModule }); - ReactiveFormsModule.ɵinj = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({ imports: [ɵInternalFormsSharedModule] }); - return ReactiveFormsModule; -})(); -/*@__PURE__*/ (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] }); })(); -/** - * @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 isAbstractControlOptions(options) { - return options.asyncValidators !== undefined || - options.validators !== undefined || - options.updateOn !== undefined; -} -let FormBuilder = /*@__PURE__*/ (() => { - class FormBuilder { - group(controlsConfig, options = null) { - const controls = this._reduceControls(controlsConfig); - let validators = null; - let asyncValidators = null; - let 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, updateOn, validators }); - } - /** - * @description - * Construct a new `FormControl` with the given state, validators and options. - * - * @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. - * - * @usageNotes - * - * ### Initialize a control as disabled - * - * The following example returns a control with an initial value in a disabled state. - * - * - * - */ - 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. - */ - array(controlsConfig, validatorOrOpts, asyncValidator) { - const controls = controlsConfig.map(c => this._createControl(c)); - return new FormArray(controls, validatorOrOpts, asyncValidator); - } - /** @internal */ - _reduceControls(controlsConfig) { - const controls = {}; - Object.keys(controlsConfig).forEach(controlName => { - controls[controlName] = this._createControl(controlsConfig[controlName]); - }); - return controls; - } - /** @internal */ - _createControl(controlConfig) { - if (controlConfig instanceof FormControl || controlConfig instanceof FormGroup || - controlConfig instanceof FormArray) { - return controlConfig; - } - else if (Array.isArray(controlConfig)) { - const value = controlConfig[0]; - const validator = controlConfig.length > 1 ? controlConfig[1] : null; - const asyncValidator = controlConfig.length > 2 ? controlConfig[2] : null; - return this.control(value, validator, asyncValidator); - } - else { - return this.control(controlConfig); - } - } - } - FormBuilder.ɵfac = function FormBuilder_Factory(t) { return new (t || FormBuilder)(); }; - FormBuilder.ɵprov = /*@__PURE__*/ Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({ factory: function FormBuilder_Factory() { return new FormBuilder(); }, token: FormBuilder, providedIn: ReactiveFormsModule }); - return FormBuilder; -})(); -/** - * @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 - */ -/** - * @publicApi - */ -const VERSION = /*@__PURE__*/ new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('11.2.14'); -/** - * @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 - */ -// This file only reexports content of the `src` folder. Keep it that way. -/** - * @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 - */ -/** - * Generated bundle index. Do not edit. - */ - -//# sourceMappingURL=forms.js.map - - -/***/ }), - -/***/ "3UWI": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/auditTime.js ***! - \********************************************************************/ -/*! exports provided: auditTime */ -/***/ (function(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 */ "D0XW"); -/* harmony import */ var _audit__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./audit */ "tnsW"); -/* harmony import */ var _observable_timer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../observable/timer */ "PqYM"); - - - -function auditTime(duration, scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"]) { - return Object(_audit__WEBPACK_IMPORTED_MODULE_1__["audit"])(() => Object(_observable_timer__WEBPACK_IMPORTED_MODULE_2__["timer"])(duration, scheduler)); -} -//# sourceMappingURL=auditTime.js.map - - -/***/ }), - -/***/ "3XJ7": -/*!*************************************************************************************************************!*\ - !*** ./node_modules/ngx-bootstrap/__ivy_ngcc__/component-loader/fesm2015/ngx-bootstrap-component-loader.js ***! - \*************************************************************************************************************/ -/*! exports provided: BsComponentRef, ComponentLoader, ComponentLoaderFactory, ContentRef */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsComponentRef", function() { return BsComponentRef; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ComponentLoader", function() { return ComponentLoader; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ComponentLoaderFactory", function() { return ComponentLoaderFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ContentRef", function() { return ContentRef; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "fXoL"); -/* harmony import */ var ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ngx-bootstrap/utils */ "lUod"); -/* harmony import */ var ngx_bootstrap_positioning__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ngx-bootstrap/positioning */ "WyaX"); - - - - - -class BsComponentRef { -} -/** - * @copyright Valor Software - * @copyright Angular ng-bootstrap team - */ -class ContentRef { - constructor( - // eslint-disable-next-line @typescript-eslint/no-explicit-any - nodes, viewRef, - // eslint-disable-next-line @typescript-eslint/no-explicit-any - componentRef) { - this.nodes = nodes; - this.viewRef = viewRef; - this.componentRef = componentRef; - } -} -// todo: add delay support -class ComponentLoader { - /** - * Do not use this directly, it should be instanced via - * `ComponentLoadFactory.attach` - * @internal - */ - constructor(_viewContainerRef, _renderer, _elementRef, _injector, _componentFactoryResolver, _ngZone, _applicationRef, _posService) { - this._viewContainerRef = _viewContainerRef; - this._renderer = _renderer; - this._elementRef = _elementRef; - this._injector = _injector; - this._componentFactoryResolver = _componentFactoryResolver; - this._ngZone = _ngZone; - this._applicationRef = _applicationRef; - this._posService = _posService; - this.onBeforeShow = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.onShown = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.onBeforeHide = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.onHidden = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this._providers = []; - this._isHiding = false; - /** - * A selector used if container element was not found - */ - this.containerDefaultSelector = 'body'; - this._listenOpts = {}; - this._globalListener = Function.prototype; - } - get isShown() { - if (this._isHiding) { - return false; - } - return !!this._componentRef; - } - attach(compType) { - this._componentFactory = this._componentFactoryResolver - .resolveComponentFactory(compType); - return this; - } - // todo: add behaviour: to target element, `body`, custom element - to(container) { - this.container = container || this.container; - return this; - } - position(opts) { - if (!opts) { - return this; - } - this.attachment = opts.attachment || this.attachment; - this._elementRef = opts.target || this._elementRef; - return this; - } - provide(provider) { - this._providers.push(provider); - return this; - } - // todo: appendChild to element or document.querySelector(this.container) - show(opts = {}) { - this._subscribePositioning(); - this._innerComponent = void 0; - if (!this._componentRef) { - this.onBeforeShow.emit(); - this._contentRef = this._getContentRef(opts.content, opts.context, opts.initialState); - const injector = _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"].create({ - providers: this._providers, - parent: this._injector - }); - if (!this._componentFactory) { - return; - } - this._componentRef = this._componentFactory.create(injector, this._contentRef.nodes); - this._applicationRef.attachView(this._componentRef.hostView); - // this._componentRef = this._viewContainerRef - // .createComponent(this._componentFactory, 0, injector, this._contentRef.nodes); - this.instance = this._componentRef.instance; - Object.assign(this._componentRef.instance, opts); - if (this.container instanceof _angular_core__WEBPACK_IMPORTED_MODULE_0__["ElementRef"]) { - this.container.nativeElement.appendChild(this._componentRef.location.nativeElement); - } - if (typeof this.container === 'string' && typeof document !== 'undefined') { - const selectedElement = document.querySelector(this.container) || - document.querySelector(this.containerDefaultSelector); - if (!selectedElement) { - return; - } - selectedElement.appendChild(this._componentRef.location.nativeElement); - } - if (!this.container && - this._elementRef && - this._elementRef.nativeElement.parentElement) { - this._elementRef.nativeElement.parentElement.appendChild(this._componentRef.location.nativeElement); - } - // we need to manually invoke change detection since events registered - // via - // Renderer::listen() are not picked up by change detection with the - // OnPush strategy - if (this._contentRef.componentRef) { - this._innerComponent = this._contentRef.componentRef.instance; - this._contentRef.componentRef.changeDetectorRef.markForCheck(); - this._contentRef.componentRef.changeDetectorRef.detectChanges(); - } - this._componentRef.changeDetectorRef.markForCheck(); - this._componentRef.changeDetectorRef.detectChanges(); - this.onShown.emit(opts.id ? { id: opts.id } : this._componentRef.instance); - } - this._registerOutsideClick(); - return this._componentRef; - } - hide(id) { - var _a, _b, _c; - if (!this._componentRef) { - return this; - } - this._posService.deletePositionElement(this._componentRef.location); - this.onBeforeHide.emit(this._componentRef.instance); - const componentEl = this._componentRef.location.nativeElement; - componentEl.parentNode.removeChild(componentEl); - if ((_a = this._contentRef) === null || _a === void 0 ? void 0 : _a.componentRef) { - this._contentRef.componentRef.destroy(); - } - if (this._viewContainerRef && ((_b = this._contentRef) === null || _b === void 0 ? void 0 : _b.viewRef)) { - this._viewContainerRef.remove(this._viewContainerRef.indexOf(this._contentRef.viewRef)); - } - if ((_c = this._contentRef) === null || _c === void 0 ? void 0 : _c.viewRef) { - this._contentRef.viewRef.destroy(); - } - this._contentRef = void 0; - this._componentRef = void 0; - this._removeGlobalListener(); - this.onHidden.emit(id ? { id } : null); - return this; - } - toggle() { - if (this.isShown) { - this.hide(); - return; - } - this.show(); - } - dispose() { - if (this.isShown) { - this.hide(); - } - this._unsubscribePositioning(); - if (this._unregisterListenersFn) { - this._unregisterListenersFn(); - } - } - listen(listenOpts) { - var _a; - this.triggers = listenOpts.triggers || this.triggers; - this._listenOpts.outsideClick = listenOpts.outsideClick; - this._listenOpts.outsideEsc = listenOpts.outsideEsc; - listenOpts.target = listenOpts.target || ((_a = this._elementRef) === null || _a === void 0 ? void 0 : _a.nativeElement); - const hide = (this._listenOpts.hide = () => listenOpts.hide ? listenOpts.hide() : void this.hide()); - const show = (this._listenOpts.show = (registerHide) => { - listenOpts.show ? listenOpts.show(registerHide) : this.show(registerHide); - registerHide(); - }); - // eslint-disable-next-line @typescript-eslint/no-explicit-any - const toggle = (registerHide) => { - this.isShown ? hide() : show(registerHide); - }; - if (this._renderer) { - this._unregisterListenersFn = Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_1__["listenToTriggersV2"])(this._renderer, { - target: listenOpts.target, - triggers: listenOpts.triggers, - show, - hide, - toggle - }); - } - return this; - } - _removeGlobalListener() { - if (this._globalListener) { - this._globalListener(); - this._globalListener = Function.prototype; - } - } - attachInline(vRef, - // eslint-disable-next-line @typescript-eslint/no-explicit-any - template) { - if (vRef && template) { - this._inlineViewRef = vRef.createEmbeddedView(template); - } - return this; - } - _registerOutsideClick() { - if (!this._componentRef || !this._componentRef.location) { - return; - } - // why: should run after first event bubble - if (this._listenOpts.outsideClick) { - const target = this._componentRef.location.nativeElement; - setTimeout(() => { - if (this._renderer && this._elementRef) { - this._globalListener = Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_1__["registerOutsideClick"])(this._renderer, { - targets: [target, this._elementRef.nativeElement], - outsideClick: this._listenOpts.outsideClick, - hide: () => this._listenOpts.hide && this._listenOpts.hide() - }); - } - }); - } - if (this._listenOpts.outsideEsc && this._renderer && this._elementRef) { - const target = this._componentRef.location.nativeElement; - this._globalListener = Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_1__["registerEscClick"])(this._renderer, { - targets: [target, this._elementRef.nativeElement], - outsideEsc: this._listenOpts.outsideEsc, - hide: () => this._listenOpts.hide && this._listenOpts.hide() - }); - } - } - getInnerComponent() { - return this._innerComponent; - } - _subscribePositioning() { - if (this._zoneSubscription || !this.attachment) { - return; - } - this.onShown.subscribe(() => { - var _a; - this._posService.position({ - element: (_a = this._componentRef) === null || _a === void 0 ? void 0 : _a.location, - target: this._elementRef, - attachment: this.attachment, - appendToBody: this.container === 'body' - }); - }); - this._zoneSubscription = this._ngZone.onStable.subscribe(() => { - if (!this._componentRef) { - return; - } - this._posService.calcPosition(); - }); - } - _unsubscribePositioning() { - if (!this._zoneSubscription) { - return; - } - this._zoneSubscription.unsubscribe(); - this._zoneSubscription = void 0; - } - _getContentRef( - // eslint-disable-next-line @typescript-eslint/no-explicit-any - content, - // eslint-disable-next-line @typescript-eslint/no-explicit-any - context, - // eslint-disable-next-line @typescript-eslint/no-explicit-any - initialState) { - if (!content) { - return new ContentRef([]); - } - if (content instanceof _angular_core__WEBPACK_IMPORTED_MODULE_0__["TemplateRef"]) { - if (this._viewContainerRef) { - const _viewRef = this._viewContainerRef - .createEmbeddedView(content, context); - _viewRef.markForCheck(); - return new ContentRef([_viewRef.rootNodes], _viewRef); - } - const viewRef = content.createEmbeddedView({}); - this._applicationRef.attachView(viewRef); - return new ContentRef([viewRef.rootNodes], viewRef); - } - if (typeof content === 'function') { - const contentCmptFactory = this._componentFactoryResolver.resolveComponentFactory(content); - const modalContentInjector = _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"].create({ - providers: this._providers, - parent: this._injector - }); - const componentRef = contentCmptFactory.create(modalContentInjector); - Object.assign(componentRef.instance, initialState); - this._applicationRef.attachView(componentRef.hostView); - return new ContentRef([[componentRef.location.nativeElement]], componentRef.hostView, componentRef); - } - const nodes = this._renderer - ? [this._renderer.createText(`${content}`)] - : []; - return new ContentRef([nodes]); - } -} -let ComponentLoaderFactory = /*@__PURE__*/ (() => { - class ComponentLoaderFactory { - constructor(_componentFactoryResolver, _ngZone, _injector, _posService, _applicationRef) { - this._componentFactoryResolver = _componentFactoryResolver; - this._ngZone = _ngZone; - this._injector = _injector; - this._posService = _posService; - this._applicationRef = _applicationRef; - } - /** - * - * @param _elementRef - * @param _viewContainerRef - * @param _renderer - */ - createLoader(_elementRef, _viewContainerRef, _renderer) { - return new ComponentLoader(_viewContainerRef, _renderer, _elementRef, this._injector, this._componentFactoryResolver, this._ngZone, this._applicationRef, this._posService); - } - } - ComponentLoaderFactory.ɵfac = function ComponentLoaderFactory_Factory(t) { return new (t || ComponentLoaderFactory)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](ngx_bootstrap_positioning__WEBPACK_IMPORTED_MODULE_2__["PositioningService"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ApplicationRef"])); }; - ComponentLoaderFactory.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({ factory: function ComponentLoaderFactory_Factory() { return new ComponentLoaderFactory(Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["INJECTOR"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(ngx_bootstrap_positioning__WEBPACK_IMPORTED_MODULE_2__["PositioningService"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ApplicationRef"])); }, token: ComponentLoaderFactory, providedIn: "root" }); - return ComponentLoaderFactory; -})(); -/** - * Generated bundle index. Do not edit. - */ - -//# sourceMappingURL=ngx-bootstrap-component-loader.js.map - - -/***/ }), - -/***/ "4A3s": -/*!*************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/ignoreElements.js ***! - \*************************************************************************/ -/*! exports provided: ignoreElements */ -/***/ (function(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 */ "7o/Q"); - -function ignoreElements() { - return function ignoreElementsOperatorFunction(source) { - return source.lift(new IgnoreElementsOperator()); - }; -} -class IgnoreElementsOperator { - call(subscriber, source) { - return source.subscribe(new IgnoreElementsSubscriber(subscriber)); - } -} -class IgnoreElementsSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - _next(unused) { - } -} -//# sourceMappingURL=ignoreElements.js.map - - -/***/ }), - -/***/ "4I5i": -/*!*****************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js ***! - \*****************************************************************************/ -/*! exports provided: ArgumentOutOfRangeError */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ArgumentOutOfRangeError", function() { return ArgumentOutOfRangeError; }); -const ArgumentOutOfRangeErrorImpl = /*@__PURE__*/ (() => { - function ArgumentOutOfRangeErrorImpl() { - Error.call(this); - this.message = 'argument out of range'; - this.name = 'ArgumentOutOfRangeError'; - return this; - } - ArgumentOutOfRangeErrorImpl.prototype = Object.create(Error.prototype); - return ArgumentOutOfRangeErrorImpl; -})(); -const ArgumentOutOfRangeError = ArgumentOutOfRangeErrorImpl; -//# sourceMappingURL=ArgumentOutOfRangeError.js.map - - -/***/ }), - -/***/ "4O5X": -/*!****************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/bindNodeCallback.js ***! - \****************************************************************************/ -/*! exports provided: bindNodeCallback */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../AsyncSubject */ "NHP+"); -/* harmony import */ var _operators_map__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../operators/map */ "lJxs"); -/* harmony import */ var _util_canReportError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/canReportError */ "8Qeq"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); -/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../util/isArray */ "DH7j"); - - - - - - -function bindNodeCallback(callbackFunc, resultSelector, scheduler) { - if (resultSelector) { - if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_4__["isScheduler"])(resultSelector)) { - scheduler = resultSelector; - } - else { - return (...args) => bindNodeCallback(callbackFunc, scheduler)(...args).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_2__["map"])(args => Object(_util_isArray__WEBPACK_IMPORTED_MODULE_5__["isArray"])(args) ? resultSelector(...args) : resultSelector(args))); - } - } - return function (...args) { - const params = { - subject: undefined, - args, - callbackFunc, - scheduler, - context: this, - }; - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - const { context } = params; - let { subject } = params; - if (!scheduler) { - if (!subject) { - subject = params.subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"](); - const handler = (...innerArgs) => { - const err = innerArgs.shift(); - if (err) { - subject.error(err); - return; - } - subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs); - subject.complete(); - }; - try { - callbackFunc.apply(context, [...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, subscriber, context }); - } - }); - }; -} -function dispatch(state) { - const { params, subscriber, context } = state; - const { callbackFunc, args, scheduler } = params; - let subject = params.subject; - if (!subject) { - subject = params.subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"](); - const handler = (...innerArgs) => { - const err = innerArgs.shift(); - if (err) { - this.add(scheduler.schedule(dispatchError, 0, { err, subject })); - } - else { - const value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs; - this.add(scheduler.schedule(dispatchNext, 0, { value, subject })); - } - }; - try { - callbackFunc.apply(context, [...args, handler]); - } - catch (err) { - this.add(scheduler.schedule(dispatchError, 0, { err, subject })); - } - } - this.add(subject.subscribe(subscriber)); -} -function dispatchNext(arg) { - const { value, subject } = arg; - subject.next(value); - subject.complete(); -} -function dispatchError(arg) { - const { err, subject } = arg; - subject.error(err); -} -//# sourceMappingURL=bindNodeCallback.js.map - - -/***/ }), - -/***/ "4f8F": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/race.js ***! - \***************************************************************/ -/*! exports provided: race */ -/***/ (function(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 */ "DH7j"); -/* harmony import */ var _observable_race__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../observable/race */ "Nv8m"); - - -function race(...observables) { - 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"])(source, ...observables)); - }; -} -//# sourceMappingURL=race.js.map - - -/***/ }), - -/***/ "4hIw": -/*!***********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/timeInterval.js ***! - \***********************************************************************/ -/*! exports provided: timeInterval, TimeInterval */ -/***/ (function(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 */ "D0XW"); -/* harmony import */ var _scan__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./scan */ "Kqap"); -/* harmony import */ var _observable_defer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../observable/defer */ "NXyV"); -/* harmony import */ var _map__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./map */ "lJxs"); - - - - -function timeInterval(scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_0__["async"]) { - return (source) => Object(_observable_defer__WEBPACK_IMPORTED_MODULE_2__["defer"])(() => { - return source.pipe(Object(_scan__WEBPACK_IMPORTED_MODULE_1__["scan"])(({ current }, value) => ({ value, current: scheduler.now(), last: current }), { current: scheduler.now(), value: undefined, last: undefined }), Object(_map__WEBPACK_IMPORTED_MODULE_3__["map"])(({ current, last, value }) => new TimeInterval(value, current - last))); - }); -} -class TimeInterval { - constructor(value, interval) { - this.value = value; - this.interval = interval; - } -} -//# sourceMappingURL=timeInterval.js.map - - -/***/ }), - -/***/ "4yVj": -/*!**************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduled/schedulePromise.js ***! - \**************************************************************************/ -/*! exports provided: schedulePromise */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Subscription */ "quSY"); - - -function schedulePromise(input, scheduler) { - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - const sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"](); - sub.add(scheduler.schedule(() => input.then(value => { - sub.add(scheduler.schedule(() => { - subscriber.next(value); - sub.add(scheduler.schedule(() => subscriber.complete())); - })); - }, err => { - sub.add(scheduler.schedule(() => subscriber.error(err))); - }))); - return sub; - }); -} -//# sourceMappingURL=schedulePromise.js.map - - -/***/ }), - -/***/ "5+tZ": -/*!*******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeMap.js ***! - \*******************************************************************/ -/*! exports provided: mergeMap, MergeMapOperator, MergeMapSubscriber, flatMap */ -/***/ (function(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 export (binding) */ __webpack_require__.d(__webpack_exports__, "flatMap", function() { return flatMap; }); -/* harmony import */ var _map__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./map */ "lJxs"); -/* harmony import */ var _observable_from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../observable/from */ "Cfvw"); -/* harmony import */ var _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - - - -function mergeMap(project, resultSelector, concurrent = Number.POSITIVE_INFINITY) { - if (typeof resultSelector === 'function') { - return (source) => source.pipe(mergeMap((a, i) => Object(_observable_from__WEBPACK_IMPORTED_MODULE_1__["from"])(project(a, i)).pipe(Object(_map__WEBPACK_IMPORTED_MODULE_0__["map"])((b, ii) => resultSelector(a, b, i, ii))), concurrent)); - } - else if (typeof resultSelector === 'number') { - concurrent = resultSelector; - } - return (source) => source.lift(new MergeMapOperator(project, concurrent)); -} -class MergeMapOperator { - constructor(project, concurrent = Number.POSITIVE_INFINITY) { - this.project = project; - this.concurrent = concurrent; - } - call(observer, source) { - return source.subscribe(new MergeMapSubscriber(observer, this.project, this.concurrent)); - } -} -class MergeMapSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["SimpleOuterSubscriber"] { - constructor(destination, project, concurrent = Number.POSITIVE_INFINITY) { - super(destination); - this.project = project; - this.concurrent = concurrent; - this.hasCompleted = false; - this.buffer = []; - this.active = 0; - this.index = 0; - } - _next(value) { - if (this.active < this.concurrent) { - this._tryNext(value); - } - else { - this.buffer.push(value); - } - } - _tryNext(value) { - let result; - const index = this.index++; - try { - result = this.project(value, index); - } - catch (err) { - this.destination.error(err); - return; - } - this.active++; - this._innerSub(result); - } - _innerSub(ish) { - const innerSubscriber = new _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["SimpleInnerSubscriber"](this); - const destination = this.destination; - destination.add(innerSubscriber); - const innerSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["innerSubscribe"])(ish, innerSubscriber); - if (innerSubscription !== innerSubscriber) { - destination.add(innerSubscription); - } - } - _complete() { - this.hasCompleted = true; - if (this.active === 0 && this.buffer.length === 0) { - this.destination.complete(); - } - this.unsubscribe(); - } - notifyNext(innerValue) { - this.destination.next(innerValue); - } - notifyComplete() { - const buffer = this.buffer; - this.active--; - if (buffer.length > 0) { - this._next(buffer.shift()); - } - else if (this.active === 0 && this.hasCompleted) { - this.destination.complete(); - } - } -} -const flatMap = mergeMap; -//# sourceMappingURL=mergeMap.js.map - - -/***/ }), - -/***/ "51Bx": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeScan.js ***! - \********************************************************************/ -/*! exports provided: mergeScan, MergeScanOperator, MergeScanSubscriber */ -/***/ (function(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 _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - -function mergeScan(accumulator, seed, concurrent = Number.POSITIVE_INFINITY) { - return (source) => source.lift(new MergeScanOperator(accumulator, seed, concurrent)); -} -class MergeScanOperator { - constructor(accumulator, seed, concurrent) { - this.accumulator = accumulator; - this.seed = seed; - this.concurrent = concurrent; - } - call(subscriber, source) { - return source.subscribe(new MergeScanSubscriber(subscriber, this.accumulator, this.seed, this.concurrent)); - } -} -class MergeScanSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleOuterSubscriber"] { - constructor(destination, accumulator, acc, concurrent) { - super(destination); - this.accumulator = accumulator; - this.acc = acc; - this.concurrent = concurrent; - this.hasValue = false; - this.hasCompleted = false; - this.buffer = []; - this.active = 0; - this.index = 0; - } - _next(value) { - if (this.active < this.concurrent) { - const index = this.index++; - const destination = this.destination; - let ish; - try { - const { accumulator } = this; - ish = accumulator(this.acc, value, index); - } - catch (e) { - return destination.error(e); - } - this.active++; - this._innerSub(ish); - } - else { - this.buffer.push(value); - } - } - _innerSub(ish) { - const innerSubscriber = new _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleInnerSubscriber"](this); - const destination = this.destination; - destination.add(innerSubscriber); - const innerSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["innerSubscribe"])(ish, innerSubscriber); - if (innerSubscription !== innerSubscriber) { - destination.add(innerSubscription); - } - } - _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(); - } - notifyNext(innerValue) { - const { destination } = this; - this.acc = innerValue; - this.hasValue = true; - destination.next(innerValue); - } - notifyComplete() { - const buffer = this.buffer; - 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(); - } - } -} -//# sourceMappingURL=mergeScan.js.map - - -/***/ }), - -/***/ "51Dv": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/InnerSubscriber.js ***! - \****************************************************************/ -/*! exports provided: InnerSubscriber */ -/***/ (function(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 */ "7o/Q"); - -class InnerSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(parent, outerValue, outerIndex) { - super(); - this.parent = parent; - this.outerValue = outerValue; - this.outerIndex = outerIndex; - this.index = 0; - } - _next(value) { - this.parent.notifyNext(this.outerValue, value, this.outerIndex, this.index++, this); - } - _error(error) { - this.parent.notifyError(error, this); - this.unsubscribe(); - } - _complete() { - this.parent.notifyComplete(this); - this.unsubscribe(); - } -} -//# sourceMappingURL=InnerSubscriber.js.map - - -/***/ }), - -/***/ "5B2Y": -/*!*****************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduled/scheduleObservable.js ***! - \*****************************************************************************/ -/*! exports provided: scheduleObservable */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Subscription */ "quSY"); -/* harmony import */ var _symbol_observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../symbol/observable */ "kJWO"); - - - -function scheduleObservable(input, scheduler) { - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - const sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"](); - sub.add(scheduler.schedule(() => { - const observable = input[_symbol_observable__WEBPACK_IMPORTED_MODULE_2__["observable"]](); - sub.add(observable.subscribe({ - next(value) { sub.add(scheduler.schedule(() => subscriber.next(value))); }, - error(err) { sub.add(scheduler.schedule(() => subscriber.error(err))); }, - complete() { sub.add(scheduler.schedule(() => subscriber.complete())); }, - })); - })); - return sub; - }); -} -//# sourceMappingURL=scheduleObservable.js.map - - -/***/ }), - -/***/ "5yfJ": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/never.js ***! - \*****************************************************************/ -/*! exports provided: NEVER, never */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _util_noop__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/noop */ "KqfI"); - - -const NEVER = /*@__PURE__*/ new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](_util_noop__WEBPACK_IMPORTED_MODULE_1__["noop"]); -function never() { - return NEVER; -} -//# sourceMappingURL=never.js.map - - -/***/ }), - -/***/ "6eBy": -/*!*******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/debounce.js ***! - \*******************************************************************/ -/*! exports provided: debounce */ -/***/ (function(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 _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - -function debounce(durationSelector) { - return (source) => source.lift(new DebounceOperator(durationSelector)); -} -class DebounceOperator { - constructor(durationSelector) { - this.durationSelector = durationSelector; - } - call(subscriber, source) { - return source.subscribe(new DebounceSubscriber(subscriber, this.durationSelector)); - } -} -class DebounceSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleOuterSubscriber"] { - constructor(destination, durationSelector) { - super(destination); - this.durationSelector = durationSelector; - this.hasValue = false; - } - _next(value) { - try { - const result = this.durationSelector.call(this, value); - if (result) { - this._tryNext(value, result); - } - } - catch (err) { - this.destination.error(err); - } - } - _complete() { - this.emitValue(); - this.destination.complete(); - } - _tryNext(value, duration) { - let subscription = this.durationSubscription; - this.value = value; - this.hasValue = true; - if (subscription) { - subscription.unsubscribe(); - this.remove(subscription); - } - subscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["innerSubscribe"])(duration, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleInnerSubscriber"](this)); - if (subscription && !subscription.closed) { - this.add(this.durationSubscription = subscription); - } - } - notifyNext() { - this.emitValue(); - } - notifyComplete() { - this.emitValue(); - } - emitValue() { - if (this.hasValue) { - const value = this.value; - const subscription = this.durationSubscription; - if (subscription) { - this.durationSubscription = undefined; - subscription.unsubscribe(); - this.remove(subscription); - } - this.value = undefined; - this.hasValue = false; - super._next(value); - } - } -} -//# sourceMappingURL=debounce.js.map - - -/***/ }), - -/***/ "7+OI": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isObservable.js ***! - \******************************************************************/ -/*! exports provided: isObservable */ -/***/ (function(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 */ "HDdC"); - -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 - - -/***/ }), - -/***/ "7HRe": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduled/scheduled.js ***! - \********************************************************************/ -/*! exports provided: scheduled */ -/***/ (function(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 */ "5B2Y"); -/* harmony import */ var _schedulePromise__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./schedulePromise */ "4yVj"); -/* harmony import */ var _scheduleArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./scheduleArray */ "jZKg"); -/* harmony import */ var _scheduleIterable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./scheduleIterable */ "MBAA"); -/* harmony import */ var _util_isInteropObservable__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../util/isInteropObservable */ "QIAL"); -/* harmony import */ var _util_isPromise__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../util/isPromise */ "c2HN"); -/* harmony import */ var _util_isArrayLike__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../util/isArrayLike */ "I55L"); -/* harmony import */ var _util_isIterable__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../util/isIterable */ "CMyj"); - - - - - - - - -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 - - -/***/ }), - -/***/ "7Hc7": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/asap.js ***! - \***************************************************************/ -/*! exports provided: asapScheduler, asap */ -/***/ (function(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 export (binding) */ __webpack_require__.d(__webpack_exports__, "asap", function() { return asap; }); -/* harmony import */ var _AsapAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./AsapAction */ "Pz8W"); -/* harmony import */ var _AsapScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AsapScheduler */ "RUbi"); - - -const asapScheduler = /*@__PURE__*/ new _AsapScheduler__WEBPACK_IMPORTED_MODULE_1__["AsapScheduler"](_AsapAction__WEBPACK_IMPORTED_MODULE_0__["AsapAction"]); -const asap = asapScheduler; -//# sourceMappingURL=asap.js.map - - -/***/ }), - -/***/ "7o/Q": -/*!***********************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/Subscriber.js ***! - \***********************************************************/ -/*! exports provided: Subscriber, SafeSubscriber */ -/***/ (function(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 */ "n6bG"); -/* harmony import */ var _Observer__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Observer */ "gRHU"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Subscription */ "quSY"); -/* harmony import */ var _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../internal/symbol/rxSubscriber */ "2QA8"); -/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./config */ "2fFW"); -/* harmony import */ var _util_hostReportError__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./util/hostReportError */ "NJ4a"); - - - - - - -class Subscriber extends _Subscription__WEBPACK_IMPORTED_MODULE_2__["Subscription"] { - constructor(destinationOrNext, error, complete) { - super(); - this.syncErrorValue = null; - this.syncErrorThrown = false; - this.syncErrorThrowable = false; - this.isStopped = false; - switch (arguments.length) { - case 0: - this.destination = _Observer__WEBPACK_IMPORTED_MODULE_1__["empty"]; - break; - case 1: - if (!destinationOrNext) { - this.destination = _Observer__WEBPACK_IMPORTED_MODULE_1__["empty"]; - break; - } - if (typeof destinationOrNext === 'object') { - if (destinationOrNext instanceof Subscriber) { - this.syncErrorThrowable = destinationOrNext.syncErrorThrowable; - this.destination = destinationOrNext; - destinationOrNext.add(this); - } - else { - this.syncErrorThrowable = true; - this.destination = new SafeSubscriber(this, destinationOrNext); - } - break; - } - default: - this.syncErrorThrowable = true; - this.destination = new SafeSubscriber(this, destinationOrNext, error, complete); - break; - } - } - [_internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_3__["rxSubscriber"]]() { return this; } - static create(next, error, complete) { - const subscriber = new Subscriber(next, error, complete); - subscriber.syncErrorThrowable = false; - return subscriber; - } - next(value) { - if (!this.isStopped) { - this._next(value); - } - } - error(err) { - if (!this.isStopped) { - this.isStopped = true; - this._error(err); - } - } - complete() { - if (!this.isStopped) { - this.isStopped = true; - this._complete(); - } - } - unsubscribe() { - if (this.closed) { - return; - } - this.isStopped = true; - super.unsubscribe(); - } - _next(value) { - this.destination.next(value); - } - _error(err) { - this.destination.error(err); - this.unsubscribe(); - } - _complete() { - this.destination.complete(); - this.unsubscribe(); - } - _unsubscribeAndRecycle() { - const { _parentOrParents } = this; - this._parentOrParents = null; - this.unsubscribe(); - this.closed = false; - this.isStopped = false; - this._parentOrParents = _parentOrParents; - return this; - } -} -class SafeSubscriber extends Subscriber { - constructor(_parentSubscriber, observerOrNext, error, complete) { - super(); - this._parentSubscriber = _parentSubscriber; - let next; - let context = this; - 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)) { - this.add(context.unsubscribe.bind(context)); - } - context.unsubscribe = this.unsubscribe.bind(this); - } - } - this._context = context; - this._next = next; - this._error = error; - this._complete = complete; - } - next(value) { - if (!this.isStopped && this._next) { - const { _parentSubscriber } = this; - 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(); - } - } - } - error(err) { - if (!this.isStopped) { - const { _parentSubscriber } = this; - const { useDeprecatedSynchronousErrorHandling } = _config__WEBPACK_IMPORTED_MODULE_4__["config"]; - 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(); - } - } - } - complete() { - if (!this.isStopped) { - const { _parentSubscriber } = this; - if (this._complete) { - const wrappedComplete = () => this._complete.call(this._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(); - } - } - } - __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); - } - } - } - __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; - } - _unsubscribe() { - const { _parentSubscriber } = this; - this._context = null; - this._parentSubscriber = null; - _parentSubscriber.unsubscribe(); - } -} -//# sourceMappingURL=Subscriber.js.map - - -/***/ }), - -/***/ "7ve7": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/Action.js ***! - \*****************************************************************/ -/*! exports provided: Action */ -/***/ (function(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 */ "quSY"); - -class Action extends _Subscription__WEBPACK_IMPORTED_MODULE_0__["Subscription"] { - constructor(scheduler, work) { - super(); - } - schedule(state, delay = 0) { - return this; - } -} -//# sourceMappingURL=Action.js.map - - -/***/ }), - -/***/ "7wxJ": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/combineAll.js ***! - \*********************************************************************/ -/*! exports provided: combineAll */ -/***/ (function(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 */ "itXk"); - -function combineAll(project) { - return (source) => source.lift(new _observable_combineLatest__WEBPACK_IMPORTED_MODULE_0__["CombineLatestOperator"](project)); -} -//# sourceMappingURL=combineAll.js.map - - -/***/ }), - -/***/ "8Qeq": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/canReportError.js ***! - \********************************************************************/ -/*! exports provided: canReportError */ -/***/ (function(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 */ "7o/Q"); - -function canReportError(observer) { - while (observer) { - const { closed, destination, isStopped } = observer; - 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 - - -/***/ }), - -/***/ "9M8c": -/*!**********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferCount.js ***! - \**********************************************************************/ -/*! exports provided: bufferCount */ -/***/ (function(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 */ "7o/Q"); - -function bufferCount(bufferSize, startBufferEvery = null) { - return function bufferCountOperatorFunction(source) { - return source.lift(new BufferCountOperator(bufferSize, startBufferEvery)); - }; -} -class BufferCountOperator { - constructor(bufferSize, startBufferEvery) { - this.bufferSize = bufferSize; - this.startBufferEvery = startBufferEvery; - if (!startBufferEvery || bufferSize === startBufferEvery) { - this.subscriberClass = BufferCountSubscriber; - } - else { - this.subscriberClass = BufferSkipCountSubscriber; - } - } - call(subscriber, source) { - return source.subscribe(new this.subscriberClass(subscriber, this.bufferSize, this.startBufferEvery)); - } -} -class BufferCountSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, bufferSize) { - super(destination); - this.bufferSize = bufferSize; - this.buffer = []; - } - _next(value) { - const buffer = this.buffer; - buffer.push(value); - if (buffer.length == this.bufferSize) { - this.destination.next(buffer); - this.buffer = []; - } - } - _complete() { - const buffer = this.buffer; - if (buffer.length > 0) { - this.destination.next(buffer); - } - super._complete(); - } -} -class BufferSkipCountSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, bufferSize, startBufferEvery) { - super(destination); - this.bufferSize = bufferSize; - this.startBufferEvery = startBufferEvery; - this.buffers = []; - this.count = 0; - } - _next(value) { - const { bufferSize, startBufferEvery, buffers, count } = this; - this.count++; - if (count % startBufferEvery === 0) { - buffers.push([]); - } - for (let i = buffers.length; i--;) { - const buffer = buffers[i]; - buffer.push(value); - if (buffer.length === bufferSize) { - buffers.splice(i, 1); - this.destination.next(buffer); - } - } - } - _complete() { - const { buffers, destination } = this; - while (buffers.length > 0) { - let buffer = buffers.shift(); - if (buffer.length > 0) { - destination.next(buffer); - } - } - super._complete(); - } -} -//# sourceMappingURL=bufferCount.js.map - - -/***/ }), - -/***/ "9ihq": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/elementAt.js ***! - \********************************************************************/ -/*! exports provided: elementAt */ -/***/ (function(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 */ "4I5i"); -/* harmony import */ var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./filter */ "pLZG"); -/* harmony import */ var _throwIfEmpty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./throwIfEmpty */ "XDbj"); -/* harmony import */ var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./defaultIfEmpty */ "xbPD"); -/* harmony import */ var _take__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./take */ "IzEk"); - - - - - -function elementAt(index, defaultValue) { - if (index < 0) { - throw new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_0__["ArgumentOutOfRangeError"](); - } - const hasDefaultValue = arguments.length >= 2; - return (source) => source.pipe(Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])((v, i) => 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"])(() => new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_0__["ArgumentOutOfRangeError"]())); -} -//# sourceMappingURL=elementAt.js.map - - -/***/ }), - -/***/ "9ppp": -/*!*****************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js ***! - \*****************************************************************************/ -/*! exports provided: ObjectUnsubscribedError */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ObjectUnsubscribedError", function() { return ObjectUnsubscribedError; }); -const ObjectUnsubscribedErrorImpl = /*@__PURE__*/ (() => { - function ObjectUnsubscribedErrorImpl() { - Error.call(this); - this.message = 'object unsubscribed'; - this.name = 'ObjectUnsubscribedError'; - return this; - } - ObjectUnsubscribedErrorImpl.prototype = Object.create(Error.prototype); - return ObjectUnsubscribedErrorImpl; -})(); -const ObjectUnsubscribedError = ObjectUnsubscribedErrorImpl; -//# sourceMappingURL=ObjectUnsubscribedError.js.map - - -/***/ }), - -/***/ "A3iJ": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/partition.js ***! - \********************************************************************/ -/*! exports provided: partition */ -/***/ (function(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 */ "F97/"); -/* harmony import */ var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./filter */ "pLZG"); - - -function partition(predicate, thisArg) { - return (source) => [ - 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 - - -/***/ }), - -/***/ "AytR": -/*!*****************************************!*\ - !*** ./src/environments/environment.ts ***! - \*****************************************/ -/*! exports provided: environment */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "environment", function() { return environment; }); -const environment = { - production: true -}; - - -/***/ }), - -/***/ "BFxc": -/*!*******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/takeLast.js ***! - \*******************************************************************/ -/*! exports provided: takeLast */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/ArgumentOutOfRangeError */ "4I5i"); -/* harmony import */ var _observable_empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../observable/empty */ "EY2u"); - - - -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)); - } - }; -} -class TakeLastOperator { - constructor(total) { - this.total = total; - if (this.total < 0) { - throw new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__["ArgumentOutOfRangeError"]; - } - } - call(subscriber, source) { - return source.subscribe(new TakeLastSubscriber(subscriber, this.total)); - } -} -class TakeLastSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, total) { - super(destination); - this.total = total; - this.ring = new Array(); - this.count = 0; - } - _next(value) { - const ring = this.ring; - const total = this.total; - const count = this.count++; - if (ring.length < total) { - ring.push(value); - } - else { - const index = count % total; - ring[index] = value; - } - } - _complete() { - const destination = this.destination; - let count = this.count; - if (count > 0) { - const total = this.count >= this.total ? this.total : this.count; - const ring = this.ring; - for (let i = 0; i < total; i++) { - const idx = (count++) % total; - destination.next(ring[idx]); - } - } - destination.complete(); - } -} -//# sourceMappingURL=takeLast.js.map - - -/***/ }), - -/***/ "CMyj": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isIterable.js ***! - \****************************************************************/ -/*! exports provided: isIterable */ -/***/ (function(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 */ "Lhse"); - -function isIterable(input) { - return input && typeof input[_symbol_iterator__WEBPACK_IMPORTED_MODULE_0__["iterator"]] === 'function'; -} -//# sourceMappingURL=isIterable.js.map - - -/***/ }), - -/***/ "CRDf": -/*!***************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToObservable.js ***! - \***************************************************************************/ -/*! exports provided: subscribeToObservable */ -/***/ (function(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 */ "kJWO"); - -const subscribeToObservable = (obj) => (subscriber) => { - const 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 - - -/***/ }), - -/***/ "Cfvw": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/from.js ***! - \****************************************************************/ -/*! exports provided: from */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _util_subscribeTo__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/subscribeTo */ "SeVD"); -/* harmony import */ var _scheduled_scheduled__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../scheduled/scheduled */ "7HRe"); - - - -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 - - -/***/ }), - -/***/ "CqXF": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/mapTo.js ***! - \****************************************************************/ -/*! exports provided: mapTo */ -/***/ (function(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 */ "7o/Q"); - -function mapTo(value) { - return (source) => source.lift(new MapToOperator(value)); -} -class MapToOperator { - constructor(value) { - this.value = value; - } - call(subscriber, source) { - return source.subscribe(new MapToSubscriber(subscriber, this.value)); - } -} -class MapToSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, value) { - super(destination); - this.value = value; - } - _next(x) { - this.destination.next(this.value); - } -} -//# sourceMappingURL=mapTo.js.map - - -/***/ }), - -/***/ "D0XW": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/async.js ***! - \****************************************************************/ -/*! exports provided: asyncScheduler, async */ -/***/ (function(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 export (binding) */ __webpack_require__.d(__webpack_exports__, "async", function() { return async; }); -/* harmony import */ var _AsyncAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./AsyncAction */ "3N8a"); -/* harmony import */ var _AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AsyncScheduler */ "IjjT"); - - -const asyncScheduler = /*@__PURE__*/ new _AsyncScheduler__WEBPACK_IMPORTED_MODULE_1__["AsyncScheduler"](_AsyncAction__WEBPACK_IMPORTED_MODULE_0__["AsyncAction"]); -const async = asyncScheduler; -//# sourceMappingURL=async.js.map - - -/***/ }), - -/***/ "DH7j": -/*!*************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isArray.js ***! - \*************************************************************/ -/*! exports provided: isArray */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isArray", function() { return isArray; }); -const isArray = /*@__PURE__*/ (() => Array.isArray || ((x) => x && typeof x.length === 'number'))(); -//# sourceMappingURL=isArray.js.map - - -/***/ }), - -/***/ "Dti6": -/*!**************************************************************************!*\ - !*** ./node_modules/@angular/elements/__ivy_ngcc__/fesm2015/elements.js ***! - \**************************************************************************/ -/*! exports provided: NgElement, VERSION, createCustomElement */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "NgElement", function() { return NgElement; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "VERSION", function() { return VERSION; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "createCustomElement", function() { return createCustomElement; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "fXoL"); -/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! rxjs */ "qCKp"); -/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! rxjs/operators */ "kU1M"); -/** - * @license Angular v11.2.14 - * (c) 2010-2021 Google LLC. https://angular.io/ - * License: MIT - */ - - - - - -/** - * @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 - */ -/** - * Provide methods for scheduling the execution of a callback. - */ -const scheduler = { - /** - * Schedule a callback to be called after some delay. - * - * Returns a function that when executed will cancel the scheduled function. - */ - schedule(taskFn, delay) { - const id = setTimeout(taskFn, delay); - return () => clearTimeout(id); - }, - /** - * Schedule a callback to be called before the next render. - * (If `window.requestAnimationFrame()` is not available, use `scheduler.schedule()` instead.) - * - * Returns a function that when executed will cancel the scheduled function. - */ - scheduleBeforeRender(taskFn) { - // TODO(gkalpak): Implement a better way of accessing `requestAnimationFrame()` - // (e.g. accounting for vendor prefix, SSR-compatibility, etc). - if (typeof window === 'undefined') { - // For SSR just schedule immediately. - return scheduler.schedule(taskFn, 0); - } - if (typeof window.requestAnimationFrame === 'undefined') { - const frameMs = 16; - return scheduler.schedule(taskFn, frameMs); - } - const id = window.requestAnimationFrame(taskFn); - return () => window.cancelAnimationFrame(id); - }, -}; -/** - * Convert a camelCased string to kebab-cased. - */ -function camelToDashCase(input) { - return input.replace(/[A-Z]/g, char => `-${char.toLowerCase()}`); -} -/** - * Create a `CustomEvent` (even on browsers where `CustomEvent` is not a constructor). - */ -function createCustomEvent(doc, name, detail) { - const bubbles = false; - const cancelable = false; - // On IE11, `CustomEvent` is not a constructor. - if (typeof CustomEvent !== 'function') { - const event = doc.createEvent('CustomEvent'); - event.initCustomEvent(name, bubbles, cancelable, detail); - return event; - } - return new CustomEvent(name, { bubbles, cancelable, detail }); -} -/** - * Check whether the input is an `Element`. - */ -function isElement(node) { - return !!node && node.nodeType === Node.ELEMENT_NODE; -} -/** - * Check whether the input is a function. - */ -function isFunction(value) { - return typeof value === 'function'; -} -/** - * Convert a kebab-cased string to camelCased. - */ -function kebabToCamelCase(input) { - return input.replace(/-([a-z\d])/g, (_, char) => char.toUpperCase()); -} -let _matches; -/** - * Check whether an `Element` matches a CSS selector. - * NOTE: this is duplicated from @angular/upgrade, and can - * be consolidated in the future - */ -function matchesSelector(el, selector) { - if (!_matches) { - const elProto = Element.prototype; - _matches = elProto.matches || elProto.matchesSelector || elProto.mozMatchesSelector || - elProto.msMatchesSelector || elProto.oMatchesSelector || elProto.webkitMatchesSelector; - } - return el.nodeType === Node.ELEMENT_NODE ? _matches.call(el, selector) : false; -} -/** - * Test two values for strict equality, accounting for the fact that `NaN !== NaN`. - */ -function strictEquals(value1, value2) { - return value1 === value2 || (value1 !== value1 && value2 !== value2); -} -/** Gets a map of default set of attributes to observe and the properties they affect. */ -function getDefaultAttributeToPropertyInputs(inputs) { - const attributeToPropertyInputs = {}; - inputs.forEach(({ propName, templateName }) => { - attributeToPropertyInputs[camelToDashCase(templateName)] = propName; - }); - return attributeToPropertyInputs; -} -/** - * Gets a component's set of inputs. Uses the injector to get the component factory where the inputs - * are defined. - */ -function getComponentInputs(component, injector) { - const componentFactoryResolver = injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]); - const componentFactory = componentFactoryResolver.resolveComponentFactory(component); - return componentFactory.inputs; -} - -/** - * @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 extractProjectableNodes(host, ngContentSelectors) { - const nodes = host.childNodes; - const projectableNodes = ngContentSelectors.map(() => []); - let wildcardIndex = -1; - ngContentSelectors.some((selector, i) => { - if (selector === '*') { - wildcardIndex = i; - return true; - } - return false; - }); - for (let i = 0, ii = nodes.length; i < ii; ++i) { - const node = nodes[i]; - const ngContentIndex = findMatchingIndex(node, ngContentSelectors, wildcardIndex); - if (ngContentIndex !== -1) { - projectableNodes[ngContentIndex].push(node); - } - } - return projectableNodes; -} -function findMatchingIndex(node, selectors, defaultIndex) { - let matchingIndex = defaultIndex; - if (isElement(node)) { - selectors.some((selector, i) => { - if ((selector !== '*') && matchesSelector(node, selector)) { - matchingIndex = i; - return true; - } - return false; - }); - } - return matchingIndex; -} - -/** - * @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 - */ -/** Time in milliseconds to wait before destroying the component ref when disconnected. */ -const DESTROY_DELAY = 10; -/** - * Factory that creates new ComponentNgElementStrategy instance. Gets the component factory with the - * constructor's injector's factory resolver and passes that factory to each strategy. - * - * @publicApi - */ -class ComponentNgElementStrategyFactory { - constructor(component, injector) { - this.componentFactory = - injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ComponentFactoryResolver"]).resolveComponentFactory(component); - } - create(injector) { - return new ComponentNgElementStrategy(this.componentFactory, injector); - } -} -/** - * Creates and destroys a component ref using a component factory and handles change detection - * in response to input changes. - * - * @publicApi - */ -class ComponentNgElementStrategy { - constructor(componentFactory, injector) { - this.componentFactory = componentFactory; - this.injector = injector; - // Subject of `NgElementStrategyEvent` observables corresponding to the component's outputs. - this.eventEmitters = new rxjs__WEBPACK_IMPORTED_MODULE_1__["ReplaySubject"](1); - /** Merged stream of the component's output events. */ - this.events = this.eventEmitters.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["switchMap"])(emitters => Object(rxjs__WEBPACK_IMPORTED_MODULE_1__["merge"])(...emitters))); - /** Reference to the component that was created on connect. */ - this.componentRef = null; - /** Reference to the component view's `ChangeDetectorRef`. */ - this.viewChangeDetectorRef = null; - /** - * Changes that have been made to component inputs since the last change detection run. - * (NOTE: These are only recorded if the component implements the `OnChanges` interface.) - */ - this.inputChanges = null; - /** Whether changes have been made to component inputs since the last change detection run. */ - this.hasInputChanges = false; - /** Whether the created component implements the `OnChanges` interface. */ - this.implementsOnChanges = false; - /** Whether a change detection has been scheduled to run on the component. */ - this.scheduledChangeDetectionFn = null; - /** Callback function that when called will cancel a scheduled destruction on the component. */ - this.scheduledDestroyFn = null; - /** Initial input values that were set before the component was created. */ - this.initialInputValues = new Map(); - /** - * Set of component inputs that have not yet changed, i.e. for which `recordInputChange()` has not - * fired. - * (This helps detect the first change of an input, even if it is explicitly set to `undefined`.) - */ - this.unchangedInputs = new Set(this.componentFactory.inputs.map(({ propName }) => propName)); - /** Service for setting zone context. */ - this.ngZone = this.injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["NgZone"]); - /** The zone the element was created in or `null` if Zone.js is not loaded. */ - this.elementZone = (typeof Zone === 'undefined') ? null : this.ngZone.run(() => Zone.current); - } - /** - * Initializes a new component if one has not yet been created and cancels any scheduled - * destruction. - */ - connect(element) { - this.runInZone(() => { - // If the element is marked to be destroyed, cancel the task since the component was - // reconnected - if (this.scheduledDestroyFn !== null) { - this.scheduledDestroyFn(); - this.scheduledDestroyFn = null; - return; - } - if (this.componentRef === null) { - this.initializeComponent(element); - } - }); - } - /** - * Schedules the component to be destroyed after some small delay in case the element is just - * being moved across the DOM. - */ - disconnect() { - this.runInZone(() => { - // Return if there is no componentRef or the component is already scheduled for destruction - if (this.componentRef === null || this.scheduledDestroyFn !== null) { - return; - } - // Schedule the component to be destroyed after a small timeout in case it is being - // moved elsewhere in the DOM - this.scheduledDestroyFn = scheduler.schedule(() => { - if (this.componentRef !== null) { - this.componentRef.destroy(); - this.componentRef = null; - this.viewChangeDetectorRef = null; - } - }, DESTROY_DELAY); - }); - } - /** - * Returns the component property value. If the component has not yet been created, the value is - * retrieved from the cached initialization values. - */ - getInputValue(property) { - return this.runInZone(() => { - if (this.componentRef === null) { - return this.initialInputValues.get(property); - } - return this.componentRef.instance[property]; - }); - } - /** - * Sets the input value for the property. If the component has not yet been created, the value is - * cached and set when the component is created. - */ - setInputValue(property, value) { - this.runInZone(() => { - if (this.componentRef === null) { - this.initialInputValues.set(property, value); - return; - } - // Ignore the value if it is strictly equal to the current value, except if it is `undefined` - // and this is the first change to the value (because an explicit `undefined` _is_ strictly - // equal to not having a value set at all, but we still need to record this as a change). - if (strictEquals(value, this.getInputValue(property)) && - !((value === undefined) && this.unchangedInputs.has(property))) { - return; - } - // Record the changed value and update internal state to reflect the fact that this input has - // changed. - this.recordInputChange(property, value); - this.unchangedInputs.delete(property); - this.hasInputChanges = true; - // Update the component instance and schedule change detection. - this.componentRef.instance[property] = value; - this.scheduleDetectChanges(); - }); - } - /** - * Creates a new component through the component factory with the provided element host and - * sets up its initial inputs, listens for outputs changes, and runs an initial change detection. - */ - initializeComponent(element) { - const childInjector = _angular_core__WEBPACK_IMPORTED_MODULE_0__["Injector"].create({ providers: [], parent: this.injector }); - const projectableNodes = extractProjectableNodes(element, this.componentFactory.ngContentSelectors); - this.componentRef = this.componentFactory.create(childInjector, projectableNodes, element); - this.viewChangeDetectorRef = this.componentRef.injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]); - this.implementsOnChanges = isFunction(this.componentRef.instance.ngOnChanges); - this.initializeInputs(); - this.initializeOutputs(this.componentRef); - this.detectChanges(); - const applicationRef = this.injector.get(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ApplicationRef"]); - applicationRef.attachView(this.componentRef.hostView); - } - /** Set any stored initial inputs on the component's properties. */ - initializeInputs() { - this.componentFactory.inputs.forEach(({ propName }) => { - if (this.initialInputValues.has(propName)) { - // Call `setInputValue()` now that the component has been instantiated to update its - // properties and fire `ngOnChanges()`. - this.setInputValue(propName, this.initialInputValues.get(propName)); - } - }); - this.initialInputValues.clear(); - } - /** Sets up listeners for the component's outputs so that the events stream emits the events. */ - initializeOutputs(componentRef) { - const eventEmitters = this.componentFactory.outputs.map(({ propName, templateName }) => { - const emitter = componentRef.instance[propName]; - return emitter.pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_2__["map"])(value => ({ name: templateName, value }))); - }); - this.eventEmitters.next(eventEmitters); - } - /** Calls ngOnChanges with all the inputs that have changed since the last call. */ - callNgOnChanges(componentRef) { - if (!this.implementsOnChanges || this.inputChanges === null) { - return; - } - // Cache the changes and set inputChanges to null to capture any changes that might occur - // during ngOnChanges. - const inputChanges = this.inputChanges; - this.inputChanges = null; - componentRef.instance.ngOnChanges(inputChanges); - } - /** - * Marks the component view for check, if necessary. - * (NOTE: This is required when the `ChangeDetectionStrategy` is set to `OnPush`.) - */ - markViewForCheck(viewChangeDetectorRef) { - if (this.hasInputChanges) { - this.hasInputChanges = false; - viewChangeDetectorRef.markForCheck(); - } - } - /** - * Schedules change detection to run on the component. - * Ignores subsequent calls if already scheduled. - */ - scheduleDetectChanges() { - if (this.scheduledChangeDetectionFn) { - return; - } - this.scheduledChangeDetectionFn = scheduler.scheduleBeforeRender(() => { - this.scheduledChangeDetectionFn = null; - this.detectChanges(); - }); - } - /** - * Records input changes so that the component receives SimpleChanges in its onChanges function. - */ - recordInputChange(property, currentValue) { - // Do not record the change if the component does not implement `OnChanges`. - if (!this.implementsOnChanges) { - return; - } - if (this.inputChanges === null) { - this.inputChanges = {}; - } - // If there already is a change, modify the current value to match but leave the values for - // `previousValue` and `isFirstChange`. - const pendingChange = this.inputChanges[property]; - if (pendingChange) { - pendingChange.currentValue = currentValue; - return; - } - const isFirstChange = this.unchangedInputs.has(property); - const previousValue = isFirstChange ? undefined : this.getInputValue(property); - this.inputChanges[property] = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["SimpleChange"](previousValue, currentValue, isFirstChange); - } - /** Runs change detection on the component. */ - detectChanges() { - if (this.componentRef === null) { - return; - } - this.callNgOnChanges(this.componentRef); - this.markViewForCheck(this.viewChangeDetectorRef); - this.componentRef.changeDetectorRef.detectChanges(); - } - /** Runs in the angular zone, if present. */ - runInZone(fn) { - return (this.elementZone && Zone.current !== this.elementZone) ? this.ngZone.run(fn) : fn(); - } -} - -/** - * @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 - */ -/** - * Implements the functionality needed for a custom element. - * - * @publicApi - */ -class NgElement extends HTMLElement { - constructor() { - super(...arguments); - /** - * A subscription to change, connect, and disconnect events in the custom element. - */ - this.ngElementEventsSubscription = null; - } -} -/** - * @description Creates a custom element class based on an Angular component. - * - * Builds a class that encapsulates the functionality of the provided component and - * uses the configuration information to provide more context to the class. - * Takes the component factory's inputs and outputs to convert them to the proper - * custom element API and add hooks to input changes. - * - * The configuration's injector is the initial injector set on the class, - * and used by default for each created instance.This behavior can be overridden with the - * static property to affect all newly created instances, or as a constructor argument for - * one-off creations. - * - * @see [Angular Elements Overview](guide/elements "Turning Angular components into custom elements") - * - * @param component The component to transform. - * @param config A configuration that provides initialization information to the created class. - * @returns The custom-element construction class, which can be registered with - * a browser's `CustomElementRegistry`. - * - * @publicApi - */ -function createCustomElement(component, config) { - const inputs = getComponentInputs(component, config.injector); - const strategyFactory = config.strategyFactory || new ComponentNgElementStrategyFactory(component, config.injector); - const attributeToPropertyInputs = getDefaultAttributeToPropertyInputs(inputs); - class NgElementImpl extends NgElement { - constructor(injector) { - super(); - this.injector = injector; - } - get ngElementStrategy() { - // NOTE: - // Some polyfills (e.g. `document-register-element`) do not call the constructor, therefore - // it is not safe to set `ngElementStrategy` in the constructor and assume it will be - // available inside the methods. - // - // TODO(andrewseguin): Add e2e tests that cover cases where the constructor isn't called. For - // now this is tested using a Google internal test suite. - if (!this._ngElementStrategy) { - const strategy = this._ngElementStrategy = - strategyFactory.create(this.injector || config.injector); - // Re-apply pre-existing input values (set as properties on the element) through the - // strategy. - inputs.forEach(({ propName }) => { - if (!this.hasOwnProperty(propName)) { - // No pre-existing value for `propName`. - return; - } - // Delete the property from the instance and re-apply it through the strategy. - const value = this[propName]; - delete this[propName]; - strategy.setInputValue(propName, value); - }); - } - return this._ngElementStrategy; - } - attributeChangedCallback(attrName, oldValue, newValue, namespace) { - const propName = attributeToPropertyInputs[attrName]; - this.ngElementStrategy.setInputValue(propName, newValue); - } - connectedCallback() { - // For historical reasons, some strategies may not have initialized the `events` property - // until after `connect()` is run. Subscribe to `events` if it is available before running - // `connect()` (in order to capture events emitted suring inittialization), otherwise - // subscribe afterwards. - // - // TODO: Consider deprecating/removing the post-connect subscription in a future major version - // (e.g. v11). - let subscribedToEvents = false; - if (this.ngElementStrategy.events) { - // `events` are already available: Subscribe to it asap. - this.subscribeToEvents(); - subscribedToEvents = true; - } - this.ngElementStrategy.connect(this); - if (!subscribedToEvents) { - // `events` were not initialized before running `connect()`: Subscribe to them now. - // The events emitted during the component initialization have been missed, but at least - // future events will be captured. - this.subscribeToEvents(); - } - } - disconnectedCallback() { - // Not using `this.ngElementStrategy` to avoid unnecessarily creating the `NgElementStrategy`. - if (this._ngElementStrategy) { - this._ngElementStrategy.disconnect(); - } - if (this.ngElementEventsSubscription) { - this.ngElementEventsSubscription.unsubscribe(); - this.ngElementEventsSubscription = null; - } - } - subscribeToEvents() { - // Listen for events from the strategy and dispatch them as custom events. - this.ngElementEventsSubscription = this.ngElementStrategy.events.subscribe(e => { - const customEvent = createCustomEvent(this.ownerDocument, e.name, e.value); - this.dispatchEvent(customEvent); - }); - } - } - // Work around a bug in closure typed optimizations(b/79557487) where it is not honoring static - // field externs. So using quoted access to explicitly prevent renaming. - NgElementImpl['observedAttributes'] = Object.keys(attributeToPropertyInputs); - // Add getters and setters to the prototype for each property input. - inputs.forEach(({ propName }) => { - Object.defineProperty(NgElementImpl.prototype, propName, { - get() { - return this.ngElementStrategy.getInputValue(propName); - }, - set(newValue) { - this.ngElementStrategy.setInputValue(propName, newValue); - }, - configurable: true, - enumerable: true, - }); - }); - return NgElementImpl; -} - -/** - * @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 - */ -/** - * @publicApi - */ -const VERSION = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["Version"]('11.2.14'); - -/** - * @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 - */ -// This file only reexports content of the `src` folder. Keep it that way. - -/** - * @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 - */ - -/** - * Generated bundle index. Do not edit. - */ - - - -//# sourceMappingURL=elements.js.map - -/***/ }), - -/***/ "Dwot": -/*!********************************************!*\ - !*** ./src/app/svgcss/svgcss.component.ts ***! - \********************************************/ -/*! exports provided: SvgcssComponent */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SvgcssComponent", function() { return SvgcssComponent; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "fXoL"); -/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/common */ "ofXK"); - - -function SvgcssComponent_ng_container_0_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerStart"](0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "span", 1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](2, "background-image:\u00A0"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](3, "span", 2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](4, "url("); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](5, "span", 3); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](6); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](7, "span", 2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](8, ");"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerEnd"](); - } - if (rf & 2) { - const ctx_r0 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](6); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtextInterpolate"](ctx_r0.getSvgCss()); - } -} -function SvgcssComponent_ng_container_1_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerStart"](0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerEnd"](); - } - if (rf & 2) { - const ctx_r1 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtextInterpolate1"]("background-image: url(", ctx_r1.getSvgCss(), ");"); - } -} -let SvgcssComponent = /*@__PURE__*/ (() => { - class SvgcssComponent { - constructor() { - this.raw = false; - this.symbols = /[\r\n%#()<>?[\\\]^`{|}]/g; - this.quotes = { - level1: `"`, - level2: `'`, - }; - } - ngOnInit() { - // trim leading and trailing double quotes - this.svg = this.svg.replace(/^"(.*)"$/, `$1`); - } - getSvgCss() { - const namespaced = this.addNameSpace(this.svg); - const escaped = this.encodeSVG(namespaced); - const resultCss = `${this.quotes.level1}data:image/svg+xml,${escaped}${this.quotes.level1}`; - return resultCss; - } - addNameSpace(data) { - if (data.indexOf(`http://www.w3.org/2000/svg`) < 0) { - data = data.replace(/\s{1,}<`); - data = data.replace(/\s{2,}/g, ` `); - // Using encodeURIComponent() as replacement function - // allows to keep result code readable - return data.replace(this.symbols, encodeURIComponent); - } - } - SvgcssComponent.ɵfac = function SvgcssComponent_Factory(t) { return new (t || SvgcssComponent)(); }; - SvgcssComponent.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({ type: SvgcssComponent, selectors: [["app-svgcss"]], inputs: { svg: "svg", raw: "raw" }, decls: 2, vars: 2, consts: [[4, "ngIf"], [1, "nt"], [1, "na"], [1, "s"]], template: function SvgcssComponent_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](0, SvgcssComponent_ng_container_0_Template, 9, 1, "ng-container", 0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](1, SvgcssComponent_ng_container_1_Template, 2, 1, "ng-container", 0); - } - if (rf & 2) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngIf", !ctx.raw); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngIf", ctx.raw); - } - }, directives: [_angular_common__WEBPACK_IMPORTED_MODULE_1__["NgIf"]], encapsulation: 2 }); - return SvgcssComponent; -})(); - - -/***/ }), - -/***/ "EQ5u": -/*!*********************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/ConnectableObservable.js ***! - \*********************************************************************************/ -/*! exports provided: ConnectableObservable, connectableObservableDescriptor */ -/***/ (function(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 */ "XNiG"); -/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Observable */ "HDdC"); -/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Subscriber */ "7o/Q"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../Subscription */ "quSY"); -/* harmony import */ var _operators_refCount__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../operators/refCount */ "x+ZX"); - - - - - -class ConnectableObservable extends _Observable__WEBPACK_IMPORTED_MODULE_1__["Observable"] { - constructor(source, subjectFactory) { - super(); - this.source = source; - this.subjectFactory = subjectFactory; - this._refCount = 0; - this._isComplete = false; - } - _subscribe(subscriber) { - return this.getSubject().subscribe(subscriber); - } - getSubject() { - const subject = this._subject; - if (!subject || subject.isStopped) { - this._subject = this.subjectFactory(); - } - return this._subject; - } - connect() { - let 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; - } - refCount() { - return Object(_operators_refCount__WEBPACK_IMPORTED_MODULE_4__["refCount"])()(this); - } -} -const connectableObservableDescriptor = /*@__PURE__*/ (() => { - const 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 } - }; -})(); -class ConnectableSubscriber extends _Subject__WEBPACK_IMPORTED_MODULE_0__["SubjectSubscriber"] { - constructor(destination, connectable) { - super(destination); - this.connectable = connectable; - } - _error(err) { - this._unsubscribe(); - super._error(err); - } - _complete() { - this.connectable._isComplete = true; - this._unsubscribe(); - super._complete(); - } - _unsubscribe() { - const connectable = this.connectable; - if (connectable) { - this.connectable = null; - const connection = connectable._connection; - connectable._refCount = 0; - connectable._subject = null; - connectable._connection = null; - if (connection) { - connection.unsubscribe(); - } - } - } -} -class RefCountOperator { - constructor(connectable) { - this.connectable = connectable; - } - call(subscriber, source) { - const { connectable } = this; - connectable._refCount++; - const refCounter = new RefCountSubscriber(subscriber, connectable); - const subscription = source.subscribe(refCounter); - if (!refCounter.closed) { - refCounter.connection = connectable.connect(); - } - return subscription; - } -} -class RefCountSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"] { - constructor(destination, connectable) { - super(destination); - this.connectable = connectable; - } - _unsubscribe() { - const { connectable } = this; - if (!connectable) { - this.connection = null; - return; - } - this.connectable = null; - const refCount = connectable._refCount; - if (refCount <= 0) { - this.connection = null; - return; - } - connectable._refCount = refCount - 1; - if (refCount > 1) { - this.connection = null; - return; - } - const { connection } = this; - const sharedConnection = connectable._connection; - this.connection = null; - if (sharedConnection && (!connection || sharedConnection === connection)) { - sharedConnection.unsubscribe(); - } - } -} -//# sourceMappingURL=ConnectableObservable.js.map - - -/***/ }), - -/***/ "EY2u": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/empty.js ***! - \*****************************************************************/ -/*! exports provided: EMPTY, empty */ -/***/ (function(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 */ "HDdC"); - -const EMPTY = /*@__PURE__*/ new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => subscriber.complete()); -function empty(scheduler) { - return scheduler ? emptyScheduled(scheduler) : EMPTY; -} -function emptyScheduled(scheduler) { - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => scheduler.schedule(() => subscriber.complete())); -} -//# sourceMappingURL=empty.js.map - - -/***/ }), - -/***/ "F97/": -/*!*********************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/not.js ***! - \*********************************************************/ -/*! exports provided: not */ -/***/ (function(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 - - -/***/ }), - -/***/ "FD9M": -/*!***********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferToggle.js ***! - \***********************************************************************/ -/*! exports provided: bufferToggle */ -/***/ (function(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 */ "quSY"); -/* harmony import */ var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/subscribeToResult */ "ZUHj"); -/* harmony import */ var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../OuterSubscriber */ "l7GE"); - - - -function bufferToggle(openings, closingSelector) { - return function bufferToggleOperatorFunction(source) { - return source.lift(new BufferToggleOperator(openings, closingSelector)); - }; -} -class BufferToggleOperator { - constructor(openings, closingSelector) { - this.openings = openings; - this.closingSelector = closingSelector; - } - call(subscriber, source) { - return source.subscribe(new BufferToggleSubscriber(subscriber, this.openings, this.closingSelector)); - } -} -class BufferToggleSubscriber extends _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"] { - constructor(destination, openings, closingSelector) { - super(destination); - this.closingSelector = closingSelector; - this.contexts = []; - this.add(Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_1__["subscribeToResult"])(this, openings)); - } - _next(value) { - const contexts = this.contexts; - const len = contexts.length; - for (let i = 0; i < len; i++) { - contexts[i].buffer.push(value); - } - } - _error(err) { - const contexts = this.contexts; - while (contexts.length > 0) { - const context = contexts.shift(); - context.subscription.unsubscribe(); - context.buffer = null; - context.subscription = null; - } - this.contexts = null; - super._error(err); - } - _complete() { - const contexts = this.contexts; - while (contexts.length > 0) { - const context = contexts.shift(); - this.destination.next(context.buffer); - context.subscription.unsubscribe(); - context.buffer = null; - context.subscription = null; - } - this.contexts = null; - super._complete(); - } - notifyNext(outerValue, innerValue) { - outerValue ? this.closeBuffer(outerValue) : this.openBuffer(innerValue); - } - notifyComplete(innerSub) { - this.closeBuffer(innerSub.context); - } - openBuffer(value) { - try { - const closingSelector = this.closingSelector; - const closingNotifier = closingSelector.call(this, value); - if (closingNotifier) { - this.trySubscribe(closingNotifier); - } - } - catch (err) { - this._error(err); - } - } - closeBuffer(context) { - const contexts = this.contexts; - if (contexts && context) { - const { buffer, subscription } = context; - this.destination.next(buffer); - contexts.splice(contexts.indexOf(context), 1); - this.remove(subscription); - subscription.unsubscribe(); - } - } - trySubscribe(closingNotifier) { - const contexts = this.contexts; - const buffer = []; - const subscription = new _Subscription__WEBPACK_IMPORTED_MODULE_0__["Subscription"](); - const context = { buffer, subscription }; - contexts.push(context); - const 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); - } - } -} -//# sourceMappingURL=bufferToggle.js.map - - -/***/ }), - -/***/ "FQpF": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/expand.js ***! - \*****************************************************************/ -/*! exports provided: expand, ExpandOperator, ExpandSubscriber */ -/***/ (function(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 _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - -function expand(project, concurrent = Number.POSITIVE_INFINITY, scheduler) { - concurrent = (concurrent || 0) < 1 ? Number.POSITIVE_INFINITY : concurrent; - return (source) => source.lift(new ExpandOperator(project, concurrent, scheduler)); -} -class ExpandOperator { - constructor(project, concurrent, scheduler) { - this.project = project; - this.concurrent = concurrent; - this.scheduler = scheduler; - } - call(subscriber, source) { - return source.subscribe(new ExpandSubscriber(subscriber, this.project, this.concurrent, this.scheduler)); - } -} -class ExpandSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleOuterSubscriber"] { - constructor(destination, project, concurrent, scheduler) { - super(destination); - this.project = project; - this.concurrent = concurrent; - this.scheduler = scheduler; - this.index = 0; - this.active = 0; - this.hasCompleted = false; - if (concurrent < Number.POSITIVE_INFINITY) { - this.buffer = []; - } - } - static dispatch(arg) { - const { subscriber, result, value, index } = arg; - subscriber.subscribeToProjection(result, value, index); - } - _next(value) { - const destination = this.destination; - if (destination.closed) { - this._complete(); - return; - } - const index = this.index++; - if (this.active < this.concurrent) { - destination.next(value); - try { - const { project } = this; - const result = project(value, index); - if (!this.scheduler) { - this.subscribeToProjection(result, value, index); - } - else { - const state = { subscriber: this, result, value, index }; - const destination = this.destination; - destination.add(this.scheduler.schedule(ExpandSubscriber.dispatch, 0, state)); - } - } - catch (e) { - destination.error(e); - } - } - else { - this.buffer.push(value); - } - } - subscribeToProjection(result, value, index) { - this.active++; - const destination = this.destination; - destination.add(Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["innerSubscribe"])(result, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleInnerSubscriber"](this))); - } - _complete() { - this.hasCompleted = true; - if (this.hasCompleted && this.active === 0) { - this.destination.complete(); - } - this.unsubscribe(); - } - notifyNext(innerValue) { - this._next(innerValue); - } - notifyComplete() { - const buffer = this.buffer; - this.active--; - if (buffer && buffer.length > 0) { - this._next(buffer.shift()); - } - if (this.hasCompleted && this.active === 0) { - this.destination.complete(); - } - } -} -//# sourceMappingURL=expand.js.map - - -/***/ }), - -/***/ "FZB8": -/*!**************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/min.js ***! - \**************************************************************/ -/*! exports provided: min */ -/***/ (function(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 */ "128B"); - -function min(comparer) { - const min = (typeof comparer === 'function') - ? (x, y) => comparer(x, y) < 0 ? x : y - : (x, y) => x < y ? x : y; - return Object(_reduce__WEBPACK_IMPORTED_MODULE_0__["reduce"])(min); -} -//# sourceMappingURL=min.js.map - - -/***/ }), - -/***/ "GJmQ": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/takeWhile.js ***! - \********************************************************************/ -/*! exports provided: takeWhile */ -/***/ (function(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 */ "7o/Q"); - -function takeWhile(predicate, inclusive = false) { - return (source) => source.lift(new TakeWhileOperator(predicate, inclusive)); -} -class TakeWhileOperator { - constructor(predicate, inclusive) { - this.predicate = predicate; - this.inclusive = inclusive; - } - call(subscriber, source) { - return source.subscribe(new TakeWhileSubscriber(subscriber, this.predicate, this.inclusive)); - } -} -class TakeWhileSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, predicate, inclusive) { - super(destination); - this.predicate = predicate; - this.inclusive = inclusive; - this.index = 0; - } - _next(value) { - const destination = this.destination; - let result; - try { - result = this.predicate(value, this.index++); - } - catch (err) { - destination.error(err); - return; - } - this.nextOrComplete(value, result); - } - nextOrComplete(value, predicateResult) { - const destination = this.destination; - if (Boolean(predicateResult)) { - destination.next(value); - } - else { - if (this.inclusive) { - destination.next(value); - } - destination.complete(); - } - } -} -//# sourceMappingURL=takeWhile.js.map - - -/***/ }), - -/***/ "Gi4w": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/every.js ***! - \****************************************************************/ -/*! exports provided: every */ -/***/ (function(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 */ "7o/Q"); - -function every(predicate, thisArg) { - return (source) => source.lift(new EveryOperator(predicate, thisArg, source)); -} -class EveryOperator { - constructor(predicate, thisArg, source) { - this.predicate = predicate; - this.thisArg = thisArg; - this.source = source; - } - call(observer, source) { - return source.subscribe(new EverySubscriber(observer, this.predicate, this.thisArg, this.source)); - } -} -class EverySubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, predicate, thisArg, source) { - super(destination); - this.predicate = predicate; - this.thisArg = thisArg; - this.source = source; - this.index = 0; - this.thisArg = thisArg || this; - } - notifyComplete(everyValueMatch) { - this.destination.next(everyValueMatch); - this.destination.complete(); - } - _next(value) { - let 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); - } - } - _complete() { - this.notifyComplete(true); - } -} -//# sourceMappingURL=every.js.map - - -/***/ }), - -/***/ "GjHo": -/*!**************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/zip.js ***! - \**************************************************************/ -/*! exports provided: zip */ -/***/ (function(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 */ "1uah"); - -function zip(...observables) { - return function zipOperatorFunction(source) { - return source.lift.call(Object(_observable_zip__WEBPACK_IMPORTED_MODULE_0__["zip"])(source, ...observables)); - }; -} -//# sourceMappingURL=zip.js.map - - -/***/ }), - -/***/ "Gqsl": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/repeatWhen.js ***! - \*********************************************************************/ -/*! exports provided: repeatWhen */ -/***/ (function(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 */ "XNiG"); -/* harmony import */ var _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - - -function repeatWhen(notifier) { - return (source) => source.lift(new RepeatWhenOperator(notifier)); -} -class RepeatWhenOperator { - constructor(notifier) { - this.notifier = notifier; - } - call(subscriber, source) { - return source.subscribe(new RepeatWhenSubscriber(subscriber, this.notifier, source)); - } -} -class RepeatWhenSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["SimpleOuterSubscriber"] { - constructor(destination, notifier, source) { - super(destination); - this.notifier = notifier; - this.source = source; - this.sourceIsBeingSubscribedTo = true; - } - notifyNext() { - this.sourceIsBeingSubscribedTo = true; - this.source.subscribe(this); - } - notifyComplete() { - if (this.sourceIsBeingSubscribedTo === false) { - return super.complete(); - } - } - complete() { - this.sourceIsBeingSubscribedTo = false; - if (!this.isStopped) { - if (!this.retries) { - this.subscribeToRetries(); - } - if (!this.retriesSubscription || this.retriesSubscription.closed) { - return super.complete(); - } - this._unsubscribeAndRecycle(); - this.notifications.next(undefined); - } - } - _unsubscribe() { - const { notifications, retriesSubscription } = this; - if (notifications) { - notifications.unsubscribe(); - this.notifications = undefined; - } - if (retriesSubscription) { - retriesSubscription.unsubscribe(); - this.retriesSubscription = undefined; - } - this.retries = undefined; - } - _unsubscribeAndRecycle() { - const { _unsubscribe } = this; - this._unsubscribe = null; - super._unsubscribeAndRecycle(); - this._unsubscribe = _unsubscribe; - return this; - } - subscribeToRetries() { - this.notifications = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"](); - let retries; - try { - const { notifier } = this; - retries = notifier(this.notifications); - } - catch (e) { - return super.complete(); - } - this.retries = retries; - this.retriesSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["innerSubscribe"])(retries, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["SimpleInnerSubscriber"](this)); - } -} -//# sourceMappingURL=repeatWhen.js.map - - -/***/ }), - -/***/ "GwmF": -/*!**************************************!*\ - !*** ./src/app/set/set.component.ts ***! - \**************************************/ -/*! exports provided: SetComponent */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "SetComponent", function() { return SetComponent; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "fXoL"); -/* harmony import */ var _icon_service__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../icon.service */ "MICr"); -/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/platform-browser */ "jhN1"); -/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/forms */ "3Pt+"); -/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/common */ "ofXK"); -/* harmony import */ var ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ngx-bootstrap/dropdown */ "dZIy"); -/* harmony import */ var _pipes_filter_pipe__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../_pipes/filter.pipe */ "YEEh"); - - - - - - - -const _c0 = function (a0) { return { active: a0 }; }; -function SetComponent_div_5_ul_9_li_1_Template(rf, ctx) { - if (rf & 1) { - const _r7 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetCurrentView"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "li", 17); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "a", 18); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("click", function SetComponent_div_5_ul_9_li_1_Template_a_click_1_listener() { _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵrestoreView"](_r7); const cat_r5 = ctx.$implicit; const ctx_r6 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](3); return ctx_r6.selectCategory(cat_r5); }); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - } - if (rf & 2) { - const cat_r5 = ctx.$implicit; - const ctx_r4 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](3); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngClass", _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵpureFunction1"](2, _c0, ctx_r4.selectedCategory === cat_r5)); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtextInterpolate"](cat_r5); - } -} -function SetComponent_div_5_ul_9_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "ul", 15); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](1, SetComponent_div_5_ul_9_li_1_Template, 3, 4, "li", 16); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - } - if (rf & 2) { - const ctx_r3 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngForOf", ctx_r3.categoryList); - } -} -function SetComponent_div_5_Template(rf, ctx) { - if (rf & 1) { - const _r9 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵgetCurrentView"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "div", 7); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "div", 8); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](2, "input", 9); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("change", function SetComponent_div_5_Template_input_change_2_listener() { _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵrestoreView"](_r9); const ctx_r8 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](); return ctx_r8.showCategories = !ctx_r8.showCategories; }); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](3, "label", 10); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](4, "Show categories"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](5, "div", 11); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](6, "div", 12); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](7, "button", 13); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](8, " Categories "); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](9, SetComponent_div_5_ul_9_Template, 2, 1, "ul", 14); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - } - if (rf & 2) { - const ctx_r0 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("checked", ctx_r0.showCategories)("disabled", ctx_r0.filterTerm !== ""); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](5); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("disabled", ctx_r0.filterTerm !== ""); - } -} -function SetComponent_ng_container_6_ng_container_1_div_1_ng_container_4_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerStart"](0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "li", 24); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](2, "a", 25); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](3, "div", 26); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnamespaceSVG"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](4, "svg", 27); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](5, "use"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnamespaceHTML"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](6, "div", 28); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](7); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerEnd"](); - } - if (rf & 2) { - const icon_r14 = ctx.$implicit; - const ctx_r13 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](4); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("data-tags", icon_r14.tags.join[","])("data-categories", icon_r14.categories.join[","]); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("href", "/" + ctx_r13.setname + "/" + icon_r14.name + "/", _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsanitizeUrl"]); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](3); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("href", ctx_r13.assetpath + ctx_r13.setname + "/sprites/modus-icons.svg#" + icon_r14.name, null, "xlink"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtextInterpolate1"](" ", icon_r14.displayName, " "); - } -} -function SetComponent_ng_container_6_ng_container_1_div_1_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "div", 21); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "h2", 22); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](3, "ul", 23); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](4, SetComponent_ng_container_6_ng_container_1_div_1_ng_container_4_Template, 8, 5, "ng-container", 19); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵpipe"](5, "filter"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - } - if (rf & 2) { - const cat_r11 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"]().$implicit; - const ctx_r12 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtextInterpolate1"](" ", cat_r11.name === "" ? "No Category" : cat_r11.name, " "); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngForOf", _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵpipeBind2"](5, 2, cat_r11.icons, ctx_r12.filterTerm)); - } -} -function SetComponent_ng_container_6_ng_container_1_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerStart"](0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](1, SetComponent_ng_container_6_ng_container_1_div_1_Template, 6, 5, "div", 20); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerEnd"](); - } - if (rf & 2) { - const cat_r11 = ctx.$implicit; - const ctx_r10 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngIf", cat_r11.name === ctx_r10.selectedCategory || ctx_r10.selectedCategory === "All"); - } -} -function SetComponent_ng_container_6_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerStart"](0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](1, SetComponent_ng_container_6_ng_container_1_Template, 2, 1, "ng-container", 19); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerEnd"](); - } - if (rf & 2) { - const ctx_r1 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngForOf", ctx_r1.iconSetCats); - } -} -function SetComponent_ng_container_7_ng_container_2_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerStart"](0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "li", 24); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](2, "a", 25); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](3, "div", 26); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnamespaceSVG"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](4, "svg", 27); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](5, "use"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnamespaceHTML"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](6, "div", 28); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtext"](7); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerEnd"](); - } - if (rf & 2) { - const icon_r17 = ctx.$implicit; - const ctx_r16 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("data-tags", icon_r17.tags.join[","])("data-categories", icon_r17.categories.join[","]); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("href", "/" + ctx_r16.setname + "/" + icon_r17.name + "/", _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsanitizeUrl"]); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](3); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("href", ctx_r16.assetpath + ctx_r16.setname + "/sprites/modus-icons.svg#" + icon_r17.name, null, "xlink"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtextInterpolate1"](" ", icon_r17.displayName, " "); - } -} -function SetComponent_ng_container_7_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerStart"](0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "ul", 23); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](2, SetComponent_ng_container_7_ng_container_2_Template, 8, 5, "ng-container", 19); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵpipe"](3, "filter"); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementContainerEnd"](); - } - if (rf & 2) { - const ctx_r2 = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵnextContext"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngForOf", _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵpipeBind2"](3, 1, ctx_r2.iconSet.icons, ctx_r2.filterTerm)); - } -} -let SetComponent = /*@__PURE__*/ (() => { - class SetComponent { - constructor(iconService, sanitizer) { - this.iconService = iconService; - this.sanitizer = sanitizer; - this.assetpath = '/'; - this.categories = 'true'; - this.categoryList = []; - this.selectedCategory = 'All'; - this.showCategories = true; - this.filterTerm = ''; - } - ngOnInit() { - if (window.location.search) { - const params = new URLSearchParams(window.location.search); - if (params.get('filter')) - this.filterTerm = decodeURIComponent(params.get('filter')) || ''; - if (params.get('category')) - this.selectedCategory = - decodeURIComponent(params.get('category')) || 'All'; - } - this.hasCategories = this.categories === 'true'; - this.iconService.getSet(this.setname).subscribe((data) => { - this.iconSet = data; - this.iconSet.icons.forEach((icon) => { - let iconCategories = icon.categories.join(', '); - if (!this.categoryList.includes(iconCategories)) { - this.categoryList.push(iconCategories); - } - }); - this.categoryList.sort(); - this.iconSetCats = this.categoryList.map((cat) => { - return { - name: cat, - icons: this.iconSet.icons.filter((icon) => { - return icon.categories.join(', ') === cat; - }), - }; - }); - this.categoryList.unshift('All'); - if (!this.categoryList.includes(this.selectedCategory)) { - this.selectedCategory = 'All'; - } - this.fontCssUrl = this.sanitizer.bypassSecurityTrustResourceUrl(`${this.assetpath + (this.assetpath !== '') ? '/' : ''}/${this.iconSet.setName}/fonts/modus-icons.css`); - }); - } - filterIcons(term) { - this.filterTerm = term; - if (term === '') { - window.history.replaceState(null, null, window.location.pathname); - } - else { - window.history.replaceState(null, null, `?filter=${encodeURIComponent(term)}`); - } - } - selectCategory(cat) { - this.selectedCategory = cat; - this.showCategories = true; - if (cat === 'All') { - window.history.replaceState(null, null, window.location.pathname); - } - else { - window.history.replaceState(null, null, `?category=${encodeURIComponent(cat)}`); - } - } - } - SetComponent.ɵfac = function SetComponent_Factory(t) { return new (t || SetComponent)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_icon_service__WEBPACK_IMPORTED_MODULE_1__["IconService"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_platform_browser__WEBPACK_IMPORTED_MODULE_2__["DomSanitizer"])); }; - SetComponent.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({ type: SetComponent, selectors: [["app-set"]], inputs: { setname: "setname", assetpath: "assetpath", categories: "categories" }, decls: 8, vars: 6, consts: [[1, "d-flex", "align-items-center", "mb-4"], ["role", "search", 1, "form-control-with-icon", 2, "width", "30%", "min-width", "250px"], ["type", "search", 1, "form-control", "form-control-filter", 3, "placeholder", "ngModel", "ngModelChange", "input"], [1, "form-control-icon"], ["alt", "", "height", "22", "width", "22", 1, "opacity-75", 3, "src"], ["class", "d-flex ms-auto", 4, "ngIf"], [4, "ngIf"], [1, "d-flex", "ms-auto"], [1, "form-check", "form-switch", "me-2", "mb-0", "mt-1"], ["type", "checkbox", "id", "Switch1", 1, "form-check-input", 3, "checked", "disabled", "change"], ["for", "Switch1", 1, "form-check-label", "me-2"], [1, "d-flex", "flex-column"], ["dropdown", "", 1, "btn-group"], ["id", "button-basic", "dropdownToggle", "", "type", "button", "aria-controls", "dropdown-basic", 1, "btn", "btn-outline-secondary", "dropdown-toggle", 3, "disabled"], ["id", "dropdown-basic", "class", "dropdown-menu", "role", "menu", "aria-labelledby", "button-basic", 4, "dropdownMenu"], ["id", "dropdown-basic", "role", "menu", "aria-labelledby", "button-basic", 1, "dropdown-menu"], ["role", "menuitem", 4, "ngFor", "ngForOf"], ["role", "menuitem"], ["href", "javascript: void(0);", 1, "dropdown-item", 3, "ngClass", "click"], [4, "ngFor", "ngForOf"], ["class", "mb-5", 4, "ngIf"], [1, "mb-5"], [1, "fw-bold", "mb-3"], [1, "row", "row-cols-2", "row-cols-sm-4", "row-cols-md-5", "row-cols-lg-6", "row-cols-xl-8", "list-unstyled", "list"], [1, "col", "mb-4"], [1, "d-block", "text-dark", "text-decoration-none", 3, "href"], [1, "p-3", "py-4", "mb-2", "bg-light", "text-center", "rounded"], ["fill", "currentColor", "width", "32", "height", "32", 1, "modus-icons"], [1, "name", "text-muted", "text-decoration-none", "text-center", "pt-1"]], template: function SetComponent_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "div", 0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](1, "div", 1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](2, "input", 2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("ngModelChange", function SetComponent_Template_input_ngModelChange_2_listener($event) { return ctx.filterTerm = $event; })("input", function SetComponent_Template_input_input_2_listener($event) { return ctx.filterIcons($event.target.value); }); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](3, "div", 3); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelement"](4, "img", 4); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](5, SetComponent_div_5_Template, 10, 3, "div", 5); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](6, SetComponent_ng_container_6_Template, 2, 1, "ng-container", 6); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵtemplate"](7, SetComponent_ng_container_7_Template, 4, 4, "ng-container", 6); - } - if (rf & 2) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("placeholder", "Filter " + ctx.iconSet.displayName + " icons")("ngModel", ctx.filterTerm); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](2); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("src", ctx.assetpath + "modus-solid/svg/filter.svg", _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsanitizeUrl"]); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngIf", ctx.hasCategories); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngIf", ctx.hasCategories && ctx.showCategories && ctx.filterTerm === ""); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵadvance"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngIf", !ctx.hasCategories || !ctx.showCategories || ctx.filterTerm !== ""); - } - }, directives: [_angular_forms__WEBPACK_IMPORTED_MODULE_3__["DefaultValueAccessor"], _angular_forms__WEBPACK_IMPORTED_MODULE_3__["NgControlStatus"], _angular_forms__WEBPACK_IMPORTED_MODULE_3__["NgModel"], _angular_common__WEBPACK_IMPORTED_MODULE_4__["NgIf"], ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_5__["BsDropdownDirective"], ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_5__["BsDropdownToggleDirective"], ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_5__["BsDropdownMenuDirective"], _angular_common__WEBPACK_IMPORTED_MODULE_4__["NgForOf"], _angular_common__WEBPACK_IMPORTED_MODULE_4__["NgClass"]], pipes: [_pipes_filter_pipe__WEBPACK_IMPORTED_MODULE_6__["FilterPipe"]], styles: [""] }); - return SetComponent; -})(); - - -/***/ }), - -/***/ "GyhO": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/concat.js ***! - \******************************************************************/ -/*! exports provided: concat */ -/***/ (function(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 */ "LRne"); -/* harmony import */ var _operators_concatAll__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../operators/concatAll */ "0EUg"); - - -function concat(...observables) { - return Object(_operators_concatAll__WEBPACK_IMPORTED_MODULE_1__["concatAll"])()(Object(_of__WEBPACK_IMPORTED_MODULE_0__["of"])(...observables)); -} -//# sourceMappingURL=concat.js.map - - -/***/ }), - -/***/ "HDdC": -/*!***********************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/Observable.js ***! - \***********************************************************/ -/*! exports provided: Observable */ -/***/ (function(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 */ "8Qeq"); -/* harmony import */ var _util_toSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./util/toSubscriber */ "WyKG"); -/* harmony import */ var _symbol_observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./symbol/observable */ "kJWO"); -/* harmony import */ var _util_pipe__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./util/pipe */ "mCNh"); -/* harmony import */ var _config__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./config */ "2fFW"); - - - - - -let Observable = /*@__PURE__*/ (() => { - class Observable { - constructor(subscribe) { - this._isScalar = false; - if (subscribe) { - this._subscribe = subscribe; - } - } - lift(operator) { - const observable = new Observable(); - observable.source = this; - observable.operator = operator; - return observable; - } - subscribe(observerOrNext, error, complete) { - const { operator } = this; - const 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; - } - _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); - } - } - } - forEach(next, promiseCtor) { - promiseCtor = getPromiseCtor(promiseCtor); - return new promiseCtor((resolve, reject) => { - let subscription; - subscription = this.subscribe((value) => { - try { - next(value); - } - catch (err) { - reject(err); - if (subscription) { - subscription.unsubscribe(); - } - } - }, reject, resolve); - }); - } - _subscribe(subscriber) { - const { source } = this; - return source && source.subscribe(subscriber); - } - [_symbol_observable__WEBPACK_IMPORTED_MODULE_2__["observable"]]() { - return this; - } - pipe(...operations) { - if (operations.length === 0) { - return this; - } - return Object(_util_pipe__WEBPACK_IMPORTED_MODULE_3__["pipeFromArray"])(operations)(this); - } - toPromise(promiseCtor) { - promiseCtor = getPromiseCtor(promiseCtor); - return new promiseCtor((resolve, reject) => { - let value; - this.subscribe((x) => value = x, (err) => reject(err), () => resolve(value)); - }); - } - } - Observable.create = (subscribe) => { - return new Observable(subscribe); - }; - return Observable; -})(); -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 - - -/***/ }), - -/***/ "Hh5Z": -/*!*************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/QueueScheduler.js ***! - \*************************************************************************/ -/*! exports provided: QueueScheduler */ -/***/ (function(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 */ "IjjT"); - -class QueueScheduler extends _AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__["AsyncScheduler"] { -} -//# sourceMappingURL=QueueScheduler.js.map - - -/***/ }), - -/***/ "Hkhx": -/*!*****************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/onErrorResumeNext.js ***! - \*****************************************************************************/ -/*! exports provided: onErrorResumeNext */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./from */ "Cfvw"); -/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../util/isArray */ "DH7j"); -/* harmony import */ var _empty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./empty */ "EY2u"); - - - - -function onErrorResumeNext(...sources) { - if (sources.length === 0) { - return _empty__WEBPACK_IMPORTED_MODULE_3__["EMPTY"]; - } - const [first, ...remainder] = sources; - if (sources.length === 1 && Object(_util_isArray__WEBPACK_IMPORTED_MODULE_2__["isArray"])(first)) { - return onErrorResumeNext(...first); - } - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - const subNext = () => subscriber.add(onErrorResumeNext(...remainder).subscribe(subscriber)); - return Object(_from__WEBPACK_IMPORTED_MODULE_1__["from"])(first).subscribe({ - next(value) { subscriber.next(value); }, - error: subNext, - complete: subNext, - }); - }); -} -//# sourceMappingURL=onErrorResumeNext.js.map - - -/***/ }), - -/***/ "HrJb": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/count.js ***! - \****************************************************************/ -/*! exports provided: count */ -/***/ (function(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 */ "7o/Q"); - -function count(predicate) { - return (source) => source.lift(new CountOperator(predicate, source)); -} -class CountOperator { - constructor(predicate, source) { - this.predicate = predicate; - this.source = source; - } - call(subscriber, source) { - return source.subscribe(new CountSubscriber(subscriber, this.predicate, this.source)); - } -} -class CountSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, predicate, source) { - super(destination); - this.predicate = predicate; - this.source = source; - this.count = 0; - this.index = 0; - } - _next(value) { - if (this.predicate) { - this._tryPredicate(value); - } - else { - this.count++; - } - } - _tryPredicate(value) { - let result; - try { - result = this.predicate(value, this.index++, this.source); - } - catch (err) { - this.destination.error(err); - return; - } - if (result) { - this.count++; - } - } - _complete() { - this.destination.next(this.count); - this.destination.complete(); - } -} -//# sourceMappingURL=count.js.map - - -/***/ }), - -/***/ "I55L": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isArrayLike.js ***! - \*****************************************************************/ -/*! exports provided: isArrayLike */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "isArrayLike", function() { return isArrayLike; }); -const isArrayLike = ((x) => x && typeof x.length === 'number' && typeof x !== 'function'); -//# sourceMappingURL=isArrayLike.js.map - - -/***/ }), - -/***/ "IAdc": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/toArray.js ***! - \******************************************************************/ -/*! exports provided: toArray */ -/***/ (function(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 */ "128B"); - -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 - - -/***/ }), - -/***/ "IjjT": -/*!*************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js ***! - \*************************************************************************/ -/*! exports provided: AsyncScheduler */ -/***/ (function(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 */ "Y/cZ"); - -class AsyncScheduler extends _Scheduler__WEBPACK_IMPORTED_MODULE_0__["Scheduler"] { - constructor(SchedulerAction, now = _Scheduler__WEBPACK_IMPORTED_MODULE_0__["Scheduler"].now) { - super(SchedulerAction, () => { - if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) { - return AsyncScheduler.delegate.now(); - } - else { - return now(); - } - }); - this.actions = []; - this.active = false; - this.scheduled = undefined; - } - schedule(work, delay = 0, state) { - if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) { - return AsyncScheduler.delegate.schedule(work, delay, state); - } - else { - return super.schedule(work, delay, state); - } - } - flush(action) { - const { actions } = this; - if (this.active) { - actions.push(action); - return; - } - let 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; - } - } -} -//# sourceMappingURL=AsyncScheduler.js.map - - -/***/ }), - -/***/ "IzEk": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/take.js ***! - \***************************************************************/ -/*! exports provided: take */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/ArgumentOutOfRangeError */ "4I5i"); -/* harmony import */ var _observable_empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../observable/empty */ "EY2u"); - - - -function take(count) { - return (source) => { - if (count === 0) { - return Object(_observable_empty__WEBPACK_IMPORTED_MODULE_2__["empty"])(); - } - else { - return source.lift(new TakeOperator(count)); - } - }; -} -class TakeOperator { - constructor(total) { - this.total = total; - if (this.total < 0) { - throw new _util_ArgumentOutOfRangeError__WEBPACK_IMPORTED_MODULE_1__["ArgumentOutOfRangeError"]; - } - } - call(subscriber, source) { - return source.subscribe(new TakeSubscriber(subscriber, this.total)); - } -} -class TakeSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, total) { - super(destination); - this.total = total; - this.count = 0; - } - _next(value) { - const total = this.total; - const count = ++this.count; - if (count <= total) { - this.destination.next(value); - if (count === total) { - this.destination.complete(); - this.unsubscribe(); - } - } - } -} -//# sourceMappingURL=take.js.map - - -/***/ }), - -/***/ "JIr8": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/catchError.js ***! - \*********************************************************************/ -/*! exports provided: catchError */ -/***/ (function(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 _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - -function catchError(selector) { - return function catchErrorOperatorFunction(source) { - const operator = new CatchOperator(selector); - const caught = source.lift(operator); - return (operator.caught = caught); - }; -} -class CatchOperator { - constructor(selector) { - this.selector = selector; - } - call(subscriber, source) { - return source.subscribe(new CatchSubscriber(subscriber, this.selector, this.caught)); - } -} -class CatchSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleOuterSubscriber"] { - constructor(destination, selector, caught) { - super(destination); - this.selector = selector; - this.caught = caught; - } - error(err) { - if (!this.isStopped) { - let result; - try { - result = this.selector(err, this.caught); - } - catch (err2) { - super.error(err2); - return; - } - this._unsubscribeAndRecycle(); - const innerSubscriber = new _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleInnerSubscriber"](this); - this.add(innerSubscriber); - const innerSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["innerSubscribe"])(result, innerSubscriber); - if (innerSubscription !== innerSubscriber) { - this.add(innerSubscription); - } - } - } -} -//# sourceMappingURL=catchError.js.map - - -/***/ }), - -/***/ "JX91": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/startWith.js ***! - \********************************************************************/ -/*! exports provided: startWith */ -/***/ (function(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 */ "GyhO"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); - - -function startWith(...array) { - const scheduler = array[array.length - 1]; - if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_1__["isScheduler"])(scheduler)) { - array.pop(); - return (source) => Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"])(array, source, scheduler); - } - else { - return (source) => Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"])(array, source); - } -} -//# sourceMappingURL=startWith.js.map - - -/***/ }), - -/***/ "JmF6": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/zipAll.js ***! - \*****************************************************************/ -/*! exports provided: zipAll */ -/***/ (function(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 */ "1uah"); - -function zipAll(project) { - return (source) => source.lift(new _observable_zip__WEBPACK_IMPORTED_MODULE_0__["ZipOperator"](project)); -} -//# sourceMappingURL=zipAll.js.map - - -/***/ }), - -/***/ "K7De": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/findIndex.js ***! - \********************************************************************/ -/*! exports provided: findIndex */ -/***/ (function(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 */ "cBqT"); - -function findIndex(predicate, thisArg) { - return (source) => source.lift(new _operators_find__WEBPACK_IMPORTED_MODULE_0__["FindValueOperator"](predicate, source, true, thisArg)); -} -//# sourceMappingURL=findIndex.js.map - - -/***/ }), - -/***/ "Kj3r": -/*!***********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/debounceTime.js ***! - \***********************************************************************/ -/*! exports provided: debounceTime */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../scheduler/async */ "D0XW"); - - -function debounceTime(dueTime, scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"]) { - return (source) => source.lift(new DebounceTimeOperator(dueTime, scheduler)); -} -class DebounceTimeOperator { - constructor(dueTime, scheduler) { - this.dueTime = dueTime; - this.scheduler = scheduler; - } - call(subscriber, source) { - return source.subscribe(new DebounceTimeSubscriber(subscriber, this.dueTime, this.scheduler)); - } -} -class DebounceTimeSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, dueTime, scheduler) { - super(destination); - this.dueTime = dueTime; - this.scheduler = scheduler; - this.debouncedSubscription = null; - this.lastValue = null; - this.hasValue = false; - } - _next(value) { - this.clearDebounce(); - this.lastValue = value; - this.hasValue = true; - this.add(this.debouncedSubscription = this.scheduler.schedule(dispatchNext, this.dueTime, this)); - } - _complete() { - this.debouncedNext(); - this.destination.complete(); - } - debouncedNext() { - this.clearDebounce(); - if (this.hasValue) { - const { lastValue } = this; - this.lastValue = null; - this.hasValue = false; - this.destination.next(lastValue); - } - } - clearDebounce() { - const debouncedSubscription = this.debouncedSubscription; - if (debouncedSubscription !== null) { - this.remove(debouncedSubscription); - debouncedSubscription.unsubscribe(); - this.debouncedSubscription = null; - } - } -} -function dispatchNext(subscriber) { - subscriber.debouncedNext(); -} -//# sourceMappingURL=debounceTime.js.map - - -/***/ }), - -/***/ "Kqap": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/scan.js ***! - \***************************************************************/ -/*! exports provided: scan */ -/***/ (function(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 */ "7o/Q"); - -function scan(accumulator, seed) { - let hasSeed = false; - if (arguments.length >= 2) { - hasSeed = true; - } - return function scanOperatorFunction(source) { - return source.lift(new ScanOperator(accumulator, seed, hasSeed)); - }; -} -class ScanOperator { - constructor(accumulator, seed, hasSeed = false) { - this.accumulator = accumulator; - this.seed = seed; - this.hasSeed = hasSeed; - } - call(subscriber, source) { - return source.subscribe(new ScanSubscriber(subscriber, this.accumulator, this.seed, this.hasSeed)); - } -} -class ScanSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, accumulator, _seed, hasSeed) { - super(destination); - this.accumulator = accumulator; - this._seed = _seed; - this.hasSeed = hasSeed; - this.index = 0; - } - get seed() { - return this._seed; - } - set seed(value) { - this.hasSeed = true; - this._seed = value; - } - _next(value) { - if (!this.hasSeed) { - this.seed = value; - this.destination.next(value); - } - else { - return this._tryNext(value); - } - } - _tryNext(value) { - const index = this.index++; - let result; - try { - result = this.accumulator(this.seed, value, index); - } - catch (err) { - this.destination.error(err); - } - this.seed = result; - this.destination.next(result); - } -} -//# sourceMappingURL=scan.js.map - - -/***/ }), - -/***/ "KqfI": -/*!**********************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/noop.js ***! - \**********************************************************/ -/*! exports provided: noop */ -/***/ (function(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 - - -/***/ }), - -/***/ "LRne": -/*!**************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/of.js ***! - \**************************************************************/ -/*! exports provided: of */ -/***/ (function(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 */ "z+Ro"); -/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./fromArray */ "yCtX"); -/* harmony import */ var _scheduled_scheduleArray__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../scheduled/scheduleArray */ "jZKg"); - - - -function of(...args) { - let 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 - - -/***/ }), - -/***/ "Lhse": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/symbol/iterator.js ***! - \****************************************************************/ -/*! exports provided: getSymbolIterator, iterator, $$iterator */ -/***/ (function(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; -} -const iterator = /*@__PURE__*/ getSymbolIterator(); -const $$iterator = iterator; -//# sourceMappingURL=iterator.js.map - - -/***/ }), - -/***/ "MBAA": -/*!***************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduled/scheduleIterable.js ***! - \***************************************************************************/ -/*! exports provided: scheduleIterable */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Subscription */ "quSY"); -/* harmony import */ var _symbol_iterator__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../symbol/iterator */ "Lhse"); - - - -function scheduleIterable(input, scheduler) { - if (!input) { - throw new Error('Iterable cannot be null'); - } - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - const sub = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"](); - let iterator; - sub.add(() => { - if (iterator && typeof iterator.return === 'function') { - iterator.return(); - } - }); - sub.add(scheduler.schedule(() => { - iterator = input[_symbol_iterator__WEBPACK_IMPORTED_MODULE_2__["iterator"]](); - sub.add(scheduler.schedule(function () { - if (subscriber.closed) { - return; - } - let value; - let done; - try { - const 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 - - -/***/ }), - -/***/ "MICr": -/*!*********************************!*\ - !*** ./src/app/icon.service.ts ***! - \*********************************/ -/*! exports provided: IconService */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "IconService", function() { return IconService; }); -/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! rxjs */ "qCKp"); -/* harmony import */ var src_app_data_site_data__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! src/app/_data/site-data */ "jmYl"); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/core */ "fXoL"); - - - -let IconService = /*@__PURE__*/ (() => { - class IconService { - constructor() { } - getSetList() { - return src_app_data_site_data__WEBPACK_IMPORTED_MODULE_1__["siteData"].map((set) => { - return { - setName: set.setName, - displayName: set.displayName, - type: set.type, - iconCount: set.icons.length, - }; - }); - } - getSetDisplayName(setName) { - var _a; - return ((_a = src_app_data_site_data__WEBPACK_IMPORTED_MODULE_1__["siteData"].find((set) => set.setName === setName)) === null || _a === void 0 ? void 0 : _a.displayName) || ''; - } - getSet(setName) { - return new rxjs__WEBPACK_IMPORTED_MODULE_0__["Observable"]((observer) => { - observer.next(src_app_data_site_data__WEBPACK_IMPORTED_MODULE_1__["siteData"].find((set) => set.setName === setName)); - observer.complete(); - }); - } - getIconList(setName) { - return new rxjs__WEBPACK_IMPORTED_MODULE_0__["Observable"]((observer) => { - var _a; - observer.next((_a = src_app_data_site_data__WEBPACK_IMPORTED_MODULE_1__["siteData"].find((set) => set.setName === setName)) === null || _a === void 0 ? void 0 : _a.icons); - observer.complete(); - }); - } - getIcon(setName, iconName) { - return new rxjs__WEBPACK_IMPORTED_MODULE_0__["Observable"]((observer) => { - var _a; - observer.next((_a = src_app_data_site_data__WEBPACK_IMPORTED_MODULE_1__["siteData"] - .find((set) => set.setName === setName)) === null || _a === void 0 ? void 0 : _a.icons.find((icon) => icon.name === iconName)); - observer.complete(); - }); - } - searchIcons(searchTerm) { - const results = []; - if (searchTerm.length < 2) { - return new rxjs__WEBPACK_IMPORTED_MODULE_0__["Observable"]((observer) => { - observer.next(results); - observer.complete(); - }); - } - src_app_data_site_data__WEBPACK_IMPORTED_MODULE_1__["siteData"].forEach((set) => { - set.icons.forEach((icon) => { - if (icon.name.toLowerCase().includes(searchTerm.toLowerCase())) { - const result = Object.assign({}, icon); - result.setName = set.setName; - result.setDisplayName = set.displayName; - results.push(result); - } - icon.tags.forEach((tag) => { - if (tag.toLowerCase().includes(searchTerm.toLowerCase())) { - const result = Object.assign({}, icon); - result.setName = set.setName; - result.setDisplayName = set.displayName; - results.push(result); - } - }); - }); - }); - return new rxjs__WEBPACK_IMPORTED_MODULE_0__["Observable"]((observer) => { - observer.next(results); - observer.complete(); - }); - } - } - IconService.ɵfac = function IconService_Factory(t) { return new (t || IconService)(); }; - IconService.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_2__["ɵɵdefineInjectable"]({ token: IconService, factory: IconService.ɵfac, providedIn: 'root' }); - return IconService; -})(); - - -/***/ }), - -/***/ "MtjB": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/retryWhen.js ***! - \********************************************************************/ -/*! exports provided: retryWhen */ -/***/ (function(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 */ "XNiG"); -/* harmony import */ var _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - - -function retryWhen(notifier) { - return (source) => source.lift(new RetryWhenOperator(notifier, source)); -} -class RetryWhenOperator { - constructor(notifier, source) { - this.notifier = notifier; - this.source = source; - } - call(subscriber, source) { - return source.subscribe(new RetryWhenSubscriber(subscriber, this.notifier, this.source)); - } -} -class RetryWhenSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["SimpleOuterSubscriber"] { - constructor(destination, notifier, source) { - super(destination); - this.notifier = notifier; - this.source = source; - } - error(err) { - if (!this.isStopped) { - let errors = this.errors; - let retries = this.retries; - let retriesSubscription = this.retriesSubscription; - if (!retries) { - errors = new _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"](); - try { - const { notifier } = this; - retries = notifier(errors); - } - catch (e) { - return super.error(e); - } - retriesSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["innerSubscribe"])(retries, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["SimpleInnerSubscriber"](this)); - } - else { - this.errors = undefined; - this.retriesSubscription = undefined; - } - this._unsubscribeAndRecycle(); - this.errors = errors; - this.retries = retries; - this.retriesSubscription = retriesSubscription; - errors.next(err); - } - } - _unsubscribe() { - const { errors, retriesSubscription } = this; - if (errors) { - errors.unsubscribe(); - this.errors = undefined; - } - if (retriesSubscription) { - retriesSubscription.unsubscribe(); - this.retriesSubscription = undefined; - } - this.retries = undefined; - } - notifyNext() { - const { _unsubscribe } = this; - this._unsubscribe = null; - this._unsubscribeAndRecycle(); - this._unsubscribe = _unsubscribe; - this.source.subscribe(this); - } -} -//# sourceMappingURL=retryWhen.js.map - - -/***/ }), - -/***/ "NHP+": -/*!*************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/AsyncSubject.js ***! - \*************************************************************/ -/*! exports provided: AsyncSubject */ -/***/ (function(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 */ "XNiG"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Subscription */ "quSY"); - - -class AsyncSubject extends _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"] { - constructor() { - super(...arguments); - this.value = null; - this.hasNext = false; - this.hasCompleted = false; - } - _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 super._subscribe(subscriber); - } - next(value) { - if (!this.hasCompleted) { - this.value = value; - this.hasNext = true; - } - } - error(error) { - if (!this.hasCompleted) { - super.error(error); - } - } - complete() { - this.hasCompleted = true; - if (this.hasNext) { - super.next(this.value); - } - super.complete(); - } -} -//# sourceMappingURL=AsyncSubject.js.map - - -/***/ }), - -/***/ "NJ4a": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/hostReportError.js ***! - \*********************************************************************/ -/*! exports provided: hostReportError */ -/***/ (function(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(() => { throw err; }, 0); -} -//# sourceMappingURL=hostReportError.js.map - - -/***/ }), - -/***/ "NJ9Y": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/last.js ***! - \***************************************************************/ -/*! exports provided: last */ -/***/ (function(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 */ "sVev"); -/* harmony import */ var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./filter */ "pLZG"); -/* harmony import */ var _takeLast__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./takeLast */ "BFxc"); -/* harmony import */ var _throwIfEmpty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./throwIfEmpty */ "XDbj"); -/* harmony import */ var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./defaultIfEmpty */ "xbPD"); -/* harmony import */ var _util_identity__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../util/identity */ "SpAZ"); - - - - - - -function last(predicate, defaultValue) { - const hasDefaultValue = arguments.length >= 2; - return (source) => source.pipe(predicate ? Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])((v, i) => 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"])(() => new _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__["EmptyError"]())); -} -//# sourceMappingURL=last.js.map - - -/***/ }), - -/***/ "NNCq": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/range.js ***! - \*****************************************************************/ -/*! exports provided: range, dispatch */ -/***/ (function(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 */ "HDdC"); - -function range(start = 0, count, scheduler) { - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - if (count === undefined) { - count = start; - start = 0; - } - let index = 0; - let current = start; - if (scheduler) { - return scheduler.schedule(dispatch, 0, { - index, count, start, subscriber - }); - } - else { - do { - if (index++ >= count) { - subscriber.complete(); - break; - } - subscriber.next(current++); - if (subscriber.closed) { - break; - } - } while (true); - } - return undefined; - }); -} -function dispatch(state) { - const { start, index, count, subscriber } = state; - 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 - - -/***/ }), - -/***/ "NXyV": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/defer.js ***! - \*****************************************************************/ -/*! exports provided: defer */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./from */ "Cfvw"); -/* harmony import */ var _empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./empty */ "EY2u"); - - - -function defer(observableFactory) { - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - let input; - try { - input = observableFactory(); - } - catch (err) { - subscriber.error(err); - return undefined; - } - const 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 - - -/***/ }), - -/***/ "NfdI": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/publish.js ***! - \******************************************************************/ -/*! exports provided: publish */ -/***/ (function(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 */ "XNiG"); -/* harmony import */ var _multicast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./multicast */ "oB13"); - - -function publish(selector) { - return selector ? - Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(() => 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 - - -/***/ }), - -/***/ "Nv8m": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/race.js ***! - \****************************************************************/ -/*! exports provided: race, RaceOperator, RaceSubscriber */ -/***/ (function(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 */ "DH7j"); -/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./fromArray */ "yCtX"); -/* harmony import */ var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../OuterSubscriber */ "l7GE"); -/* harmony import */ var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/subscribeToResult */ "ZUHj"); - - - - -function race(...observables) { - 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()); -} -class RaceOperator { - call(subscriber, source) { - return source.subscribe(new RaceSubscriber(subscriber)); - } -} -class RaceSubscriber extends _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"] { - constructor(destination) { - super(destination); - this.hasFirst = false; - this.observables = []; - this.subscriptions = []; - } - _next(observable) { - this.observables.push(observable); - } - _complete() { - const observables = this.observables; - const len = observables.length; - if (len === 0) { - this.destination.complete(); - } - else { - for (let i = 0; i < len && !this.hasFirst; i++) { - const observable = observables[i]; - const subscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(this, observable, undefined, i); - if (this.subscriptions) { - this.subscriptions.push(subscription); - } - this.add(subscription); - } - this.observables = null; - } - } - notifyNext(_outerValue, innerValue, outerIndex) { - if (!this.hasFirst) { - this.hasFirst = true; - for (let i = 0; i < this.subscriptions.length; i++) { - if (i !== outerIndex) { - let subscription = this.subscriptions[i]; - subscription.unsubscribe(); - this.remove(subscription); - } - } - this.subscriptions = null; - } - this.destination.next(innerValue); - } -} -//# sourceMappingURL=race.js.map - - -/***/ }), - -/***/ "O4y0": -/*!*********************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/SubscribeOnObservable.js ***! - \*********************************************************************************/ -/*! exports provided: SubscribeOnObservable */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../scheduler/asap */ "7Hc7"); -/* harmony import */ var _util_isNumeric__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../util/isNumeric */ "Y7HM"); - - - -class SubscribeOnObservable extends _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"] { - constructor(source, delayTime = 0, scheduler = _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__["asap"]) { - super(); - this.source = source; - this.delayTime = delayTime; - this.scheduler = scheduler; - if (!Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__["isNumeric"])(delayTime) || delayTime < 0) { - this.delayTime = 0; - } - if (!scheduler || typeof scheduler.schedule !== 'function') { - this.scheduler = _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__["asap"]; - } - } - static create(source, delay = 0, scheduler = _scheduler_asap__WEBPACK_IMPORTED_MODULE_1__["asap"]) { - return new SubscribeOnObservable(source, delay, scheduler); - } - static dispatch(arg) { - const { source, subscriber } = arg; - return this.add(source.subscribe(subscriber)); - } - _subscribe(subscriber) { - const delay = this.delayTime; - const source = this.source; - const scheduler = this.scheduler; - return scheduler.schedule(SubscribeOnObservable.dispatch, delay, { - source, subscriber - }); - } -} -//# sourceMappingURL=SubscribeOnObservable.js.map - - -/***/ }), - -/***/ "OQgR": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/groupBy.js ***! - \******************************************************************/ -/*! exports provided: groupBy, GroupedObservable */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Subscription */ "quSY"); -/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Observable */ "HDdC"); -/* harmony import */ var _Subject__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../Subject */ "XNiG"); - - - - -function groupBy(keySelector, elementSelector, durationSelector, subjectSelector) { - return (source) => source.lift(new GroupByOperator(keySelector, elementSelector, durationSelector, subjectSelector)); -} -class GroupByOperator { - constructor(keySelector, elementSelector, durationSelector, subjectSelector) { - this.keySelector = keySelector; - this.elementSelector = elementSelector; - this.durationSelector = durationSelector; - this.subjectSelector = subjectSelector; - } - call(subscriber, source) { - return source.subscribe(new GroupBySubscriber(subscriber, this.keySelector, this.elementSelector, this.durationSelector, this.subjectSelector)); - } -} -class GroupBySubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, keySelector, elementSelector, durationSelector, subjectSelector) { - super(destination); - this.keySelector = keySelector; - this.elementSelector = elementSelector; - this.durationSelector = durationSelector; - this.subjectSelector = subjectSelector; - this.groups = null; - this.attemptedToUnsubscribe = false; - this.count = 0; - } - _next(value) { - let key; - try { - key = this.keySelector(value); - } - catch (err) { - this.error(err); - return; - } - this._group(value, key); - } - _group(value, key) { - let groups = this.groups; - if (!groups) { - groups = this.groups = new Map(); - } - let group = groups.get(key); - let 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); - const groupedObservable = new GroupedObservable(key, group, this); - this.destination.next(groupedObservable); - if (this.durationSelector) { - let 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); - } - } - _error(err) { - const groups = this.groups; - if (groups) { - groups.forEach((group, key) => { - group.error(err); - }); - groups.clear(); - } - this.destination.error(err); - } - _complete() { - const groups = this.groups; - if (groups) { - groups.forEach((group, key) => { - group.complete(); - }); - groups.clear(); - } - this.destination.complete(); - } - removeGroup(key) { - this.groups.delete(key); - } - unsubscribe() { - if (!this.closed) { - this.attemptedToUnsubscribe = true; - if (this.count === 0) { - super.unsubscribe(); - } - } - } -} -class GroupDurationSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(key, group, parent) { - super(group); - this.key = key; - this.group = group; - this.parent = parent; - } - _next(value) { - this.complete(); - } - _unsubscribe() { - const { parent, key } = this; - this.key = this.parent = null; - if (parent) { - parent.removeGroup(key); - } - } -} -class GroupedObservable extends _Observable__WEBPACK_IMPORTED_MODULE_2__["Observable"] { - constructor(key, groupSubject, refCountSubscription) { - super(); - this.key = key; - this.groupSubject = groupSubject; - this.refCountSubscription = refCountSubscription; - } - _subscribe(subscriber) { - const subscription = new _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"](); - const { refCountSubscription, groupSubject } = this; - if (refCountSubscription && !refCountSubscription.closed) { - subscription.add(new InnerRefCountSubscription(refCountSubscription)); - } - subscription.add(groupSubject.subscribe(subscriber)); - return subscription; - } -} -class InnerRefCountSubscription extends _Subscription__WEBPACK_IMPORTED_MODULE_1__["Subscription"] { - constructor(parent) { - super(); - this.parent = parent; - parent.count++; - } - unsubscribe() { - const parent = this.parent; - if (!parent.closed && !this.closed) { - super.unsubscribe(); - parent.count -= 1; - if (parent.count === 0 && parent.attemptedToUnsubscribe) { - parent.unsubscribe(); - } - } - } -} -//# sourceMappingURL=groupBy.js.map - - -/***/ }), - -/***/ "OsX3": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferTime.js ***! - \*********************************************************************/ -/*! exports provided: bufferTime */ -/***/ (function(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 */ "D0XW"); -/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Subscriber */ "7o/Q"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); - - - -function bufferTime(bufferTimeSpan) { - let length = arguments.length; - let 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--; - } - let bufferCreationInterval = null; - if (length >= 2) { - bufferCreationInterval = arguments[1]; - } - let maxBufferSize = Number.POSITIVE_INFINITY; - if (length >= 3) { - maxBufferSize = arguments[2]; - } - return function bufferTimeOperatorFunction(source) { - return source.lift(new BufferTimeOperator(bufferTimeSpan, bufferCreationInterval, maxBufferSize, scheduler)); - }; -} -class BufferTimeOperator { - constructor(bufferTimeSpan, bufferCreationInterval, maxBufferSize, scheduler) { - this.bufferTimeSpan = bufferTimeSpan; - this.bufferCreationInterval = bufferCreationInterval; - this.maxBufferSize = maxBufferSize; - this.scheduler = scheduler; - } - call(subscriber, source) { - return source.subscribe(new BufferTimeSubscriber(subscriber, this.bufferTimeSpan, this.bufferCreationInterval, this.maxBufferSize, this.scheduler)); - } -} -class Context { - constructor() { - this.buffer = []; - } -} -class BufferTimeSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_1__["Subscriber"] { - constructor(destination, bufferTimeSpan, bufferCreationInterval, maxBufferSize, scheduler) { - super(destination); - this.bufferTimeSpan = bufferTimeSpan; - this.bufferCreationInterval = bufferCreationInterval; - this.maxBufferSize = maxBufferSize; - this.scheduler = scheduler; - this.contexts = []; - const context = this.openContext(); - this.timespanOnly = bufferCreationInterval == null || bufferCreationInterval < 0; - if (this.timespanOnly) { - const timeSpanOnlyState = { subscriber: this, context, bufferTimeSpan }; - this.add(context.closeAction = scheduler.schedule(dispatchBufferTimeSpanOnly, bufferTimeSpan, timeSpanOnlyState)); - } - else { - const closeState = { subscriber: this, context }; - const creationState = { bufferTimeSpan, bufferCreationInterval, subscriber: this, scheduler }; - this.add(context.closeAction = scheduler.schedule(dispatchBufferClose, bufferTimeSpan, closeState)); - this.add(scheduler.schedule(dispatchBufferCreation, bufferCreationInterval, creationState)); - } - } - _next(value) { - const contexts = this.contexts; - const len = contexts.length; - let filledBufferContext; - for (let i = 0; i < len; i++) { - const context = contexts[i]; - const buffer = context.buffer; - buffer.push(value); - if (buffer.length == this.maxBufferSize) { - filledBufferContext = context; - } - } - if (filledBufferContext) { - this.onBufferFull(filledBufferContext); - } - } - _error(err) { - this.contexts.length = 0; - super._error(err); - } - _complete() { - const { contexts, destination } = this; - while (contexts.length > 0) { - const context = contexts.shift(); - destination.next(context.buffer); - } - super._complete(); - } - _unsubscribe() { - this.contexts = null; - } - onBufferFull(context) { - this.closeContext(context); - const closeAction = context.closeAction; - closeAction.unsubscribe(); - this.remove(closeAction); - if (!this.closed && this.timespanOnly) { - context = this.openContext(); - const bufferTimeSpan = this.bufferTimeSpan; - const timeSpanOnlyState = { subscriber: this, context, bufferTimeSpan }; - this.add(context.closeAction = this.scheduler.schedule(dispatchBufferTimeSpanOnly, bufferTimeSpan, timeSpanOnlyState)); - } - } - openContext() { - const context = new Context(); - this.contexts.push(context); - return context; - } - closeContext(context) { - this.destination.next(context.buffer); - const contexts = this.contexts; - const spliceIndex = contexts ? contexts.indexOf(context) : -1; - if (spliceIndex >= 0) { - contexts.splice(contexts.indexOf(context), 1); - } - } -} -function dispatchBufferTimeSpanOnly(state) { - const subscriber = state.subscriber; - const 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) { - const { bufferCreationInterval, bufferTimeSpan, subscriber, scheduler } = state; - const context = subscriber.openContext(); - const action = this; - if (!subscriber.closed) { - subscriber.add(context.closeAction = scheduler.schedule(dispatchBufferClose, bufferTimeSpan, { subscriber, context })); - action.schedule(state, bufferCreationInterval); - } -} -function dispatchBufferClose(arg) { - const { subscriber, context } = arg; - subscriber.closeContext(context); -} -//# sourceMappingURL=bufferTime.js.map - - -/***/ }), - -/***/ "PZkE": -/*!**********************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/distinctUntilKeyChanged.js ***! - \**********************************************************************************/ -/*! exports provided: distinctUntilKeyChanged */ -/***/ (function(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 */ "/uUt"); - -function distinctUntilKeyChanged(key, compare) { - return Object(_distinctUntilChanged__WEBPACK_IMPORTED_MODULE_0__["distinctUntilChanged"])((x, y) => compare ? compare(x[key], y[key]) : x[key] === y[key]); -} -//# sourceMappingURL=distinctUntilKeyChanged.js.map - - -/***/ }), - -/***/ "PfrF": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/bufferWhen.js ***! - \*********************************************************************/ -/*! exports provided: bufferWhen */ -/***/ (function(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 */ "quSY"); -/* harmony import */ var _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - - -function bufferWhen(closingSelector) { - return function (source) { - return source.lift(new BufferWhenOperator(closingSelector)); - }; -} -class BufferWhenOperator { - constructor(closingSelector) { - this.closingSelector = closingSelector; - } - call(subscriber, source) { - return source.subscribe(new BufferWhenSubscriber(subscriber, this.closingSelector)); - } -} -class BufferWhenSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["SimpleOuterSubscriber"] { - constructor(destination, closingSelector) { - super(destination); - this.closingSelector = closingSelector; - this.subscribing = false; - this.openBuffer(); - } - _next(value) { - this.buffer.push(value); - } - _complete() { - const buffer = this.buffer; - if (buffer) { - this.destination.next(buffer); - } - super._complete(); - } - _unsubscribe() { - this.buffer = undefined; - this.subscribing = false; - } - notifyNext() { - this.openBuffer(); - } - notifyComplete() { - if (this.subscribing) { - this.complete(); - } - else { - this.openBuffer(); - } - } - openBuffer() { - let { closingSubscription } = this; - if (closingSubscription) { - this.remove(closingSubscription); - closingSubscription.unsubscribe(); - } - const buffer = this.buffer; - if (this.buffer) { - this.destination.next(buffer); - } - this.buffer = []; - let closingNotifier; - try { - const { closingSelector } = this; - 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(_innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["innerSubscribe"])(closingNotifier, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_1__["SimpleInnerSubscriber"](this))); - this.subscribing = false; - } -} -//# sourceMappingURL=bufferWhen.js.map - - -/***/ }), - -/***/ "PqYM": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/timer.js ***! - \*****************************************************************/ -/*! exports provided: timer */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../scheduler/async */ "D0XW"); -/* harmony import */ var _util_isNumeric__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../util/isNumeric */ "Y7HM"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); - - - - -function timer(dueTime = 0, periodOrScheduler, scheduler) { - let 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"](subscriber => { - const due = Object(_util_isNumeric__WEBPACK_IMPORTED_MODULE_2__["isNumeric"])(dueTime) - ? dueTime - : (+dueTime - scheduler.now()); - return scheduler.schedule(dispatch, due, { - index: 0, period, subscriber - }); - }); -} -function dispatch(state) { - const { index, period, subscriber } = state; - 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 - - -/***/ }), - -/***/ "Pz8W": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsapAction.js ***! - \*********************************************************************/ -/*! exports provided: AsapAction */ -/***/ (function(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 */ "c7jc"); -/* harmony import */ var _AsyncAction__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AsyncAction */ "3N8a"); - - -class AsapAction extends _AsyncAction__WEBPACK_IMPORTED_MODULE_1__["AsyncAction"] { - constructor(scheduler, work) { - super(scheduler, work); - this.scheduler = scheduler; - this.work = work; - } - requestAsyncId(scheduler, id, delay = 0) { - if (delay !== null && delay > 0) { - return super.requestAsyncId(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))); - } - recycleAsyncId(scheduler, id, delay = 0) { - if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { - return super.recycleAsyncId(scheduler, id, delay); - } - if (scheduler.actions.length === 0) { - _util_Immediate__WEBPACK_IMPORTED_MODULE_0__["Immediate"].clearImmediate(id); - scheduler.scheduled = undefined; - } - return undefined; - } -} -//# sourceMappingURL=AsapAction.js.map - - -/***/ }), - -/***/ "QIAL": -/*!*************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isInteropObservable.js ***! - \*************************************************************************/ -/*! exports provided: isInteropObservable */ -/***/ (function(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 */ "kJWO"); - -function isInteropObservable(input) { - return input && typeof input[_symbol_observable__WEBPACK_IMPORTED_MODULE_0__["observable"]] === 'function'; -} -//# sourceMappingURL=isInteropObservable.js.map - - -/***/ }), - -/***/ "Qn8I": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/using.js ***! - \*****************************************************************/ -/*! exports provided: using */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./from */ "Cfvw"); -/* harmony import */ var _empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./empty */ "EY2u"); - - - -function using(resourceFactory, observableFactory) { - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - let resource; - try { - resource = resourceFactory(); - } - catch (err) { - subscriber.error(err); - return undefined; - } - let result; - try { - result = observableFactory(resource); - } - catch (err) { - subscriber.error(err); - return undefined; - } - const source = result ? Object(_from__WEBPACK_IMPORTED_MODULE_1__["from"])(result) : _empty__WEBPACK_IMPORTED_MODULE_2__["EMPTY"]; - const subscription = source.subscribe(subscriber); - return () => { - subscription.unsubscribe(); - if (resource) { - resource.unsubscribe(); - } - }; - }); -} -//# sourceMappingURL=using.js.map - - -/***/ }), - -/***/ "QqCr": -/*!************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/bindCallback.js ***! - \************************************************************************/ -/*! exports provided: bindCallback */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../AsyncSubject */ "NHP+"); -/* harmony import */ var _operators_map__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../operators/map */ "lJxs"); -/* harmony import */ var _util_canReportError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/canReportError */ "8Qeq"); -/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../util/isArray */ "DH7j"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); - - - - - - -function bindCallback(callbackFunc, resultSelector, scheduler) { - if (resultSelector) { - if (Object(_util_isScheduler__WEBPACK_IMPORTED_MODULE_5__["isScheduler"])(resultSelector)) { - scheduler = resultSelector; - } - else { - return (...args) => bindCallback(callbackFunc, scheduler)(...args).pipe(Object(_operators_map__WEBPACK_IMPORTED_MODULE_2__["map"])((args) => Object(_util_isArray__WEBPACK_IMPORTED_MODULE_4__["isArray"])(args) ? resultSelector(...args) : resultSelector(args))); - } - } - return function (...args) { - const context = this; - let subject; - const params = { - context, - subject, - callbackFunc, - scheduler, - }; - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - if (!scheduler) { - if (!subject) { - subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"](); - const handler = (...innerArgs) => { - subject.next(innerArgs.length <= 1 ? innerArgs[0] : innerArgs); - subject.complete(); - }; - try { - callbackFunc.apply(context, [...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 { - const state = { - args, subscriber, params, - }; - return scheduler.schedule(dispatch, 0, state); - } - }); - }; -} -function dispatch(state) { - const self = this; - const { args, subscriber, params } = state; - const { callbackFunc, context, scheduler } = params; - let { subject } = params; - if (!subject) { - subject = params.subject = new _AsyncSubject__WEBPACK_IMPORTED_MODULE_1__["AsyncSubject"](); - const handler = (...innerArgs) => { - const value = innerArgs.length <= 1 ? innerArgs[0] : innerArgs; - this.add(scheduler.schedule(dispatchNext, 0, { value, subject })); - }; - try { - callbackFunc.apply(context, [...args, handler]); - } - catch (err) { - subject.error(err); - } - } - this.add(subject.subscribe(subscriber)); -} -function dispatchNext(state) { - const { value, subject } = state; - subject.next(value); - subject.complete(); -} -function dispatchError(state) { - const { err, subject } = state; - subject.error(err); -} -//# sourceMappingURL=bindCallback.js.map - - -/***/ }), - -/***/ "R0Ic": -/*!******************************************************************************!*\ - !*** ./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(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 v11.2.14 - * (c) 2010-2021 Google LLC. https://angular.io/ - * License: MIT - */ -/** - * 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 - */ -class AnimationBuilder { -} -/** - * A factory object returned from the `AnimationBuilder`.`build()` method. - * - * @publicApi - */ -class AnimationFactory { -} -/** - * @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 - */ -/** - * Specifies automatic styling. - * - * @publicApi - */ -const AUTO_STYLE = '*'; -/** - * Creates a named animation trigger, containing a list of `state()` - * and `transition()` entries to be evaluated when the expression - * bound to the trigger changes. - * - * @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. - * - * @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 - * - *
...
- * ``` - * - * ### 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'; - * } - * - * @Component({ - * 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 - * @Component({ - * selector: 'my-component', - * template: ` - *
- *
- *
- * `, - * 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'; - * - * @Component({ - * 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 - */ -function trigger(name, definitions) { - return { type: 7 /* Trigger */, name, definitions, options: {} }; -} -/** - * Defines an animation step that combines styling information with timing information. - * - * @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()`. - * @returns An object that encapsulates the animation step. - * - * @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 - */ -function animate(timings, styles = null) { - return { type: 4 /* Animate */, styles, timings }; -} -/** - * @description Defines a list of animation steps to be run in parallel. - * - * @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. - * - * @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 - */ -function group(steps, options = null) { - return { type: 3 /* Group */, steps, options }; -} -/** - * Defines a list of animation steps to be run sequentially, one by one. - * - * @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. - * - * @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 - **/ -function sequence(steps, options = null) { - return { type: 2 /* Sequence */, steps, 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()`. - * - * @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. - * - * @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 - **/ -function style(tokens) { - return { type: 6 /* Style */, styles: tokens, offset: null }; -} -/** - * Declares an animation state within a trigger attached to an element. - * - * @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. - * - * @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 - **/ -function state(name, styles, options) { - return { type: 0 /* State */, name, styles, options }; -} -/** - * Defines a set of animation styles, associating each style with an optional `offset` value. - * - * @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. - * @returns An object that encapsulates the keyframes data. - * - * @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 - */ -function keyframes(steps) { - return { type: 5 /* Keyframes */, 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. - * - * @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. - * @returns An object that encapsulates the transition data. - * - * @usageNotes - * The template associated with a component binds an animation trigger to an element. - * - * ```HTML - * - *
...
- * ``` - * - * 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 - *
...
- * // in the component metadata - * trigger('openClose', [ - * state('true', style({ height: '*' })), - * state('false', style({ height: '0px' })), - * transition('false <=> true', animate(500)) - * ]) - * ``` - * - * @publicApi - **/ -function transition(stateChangeExpr, steps, options = null) { - return { type: 1 /* Transition */, expr: stateChangeExpr, animation: steps, options }; -} -/** - * Produces a reusable animation that can be invoked in another animation or sequence, - * by calling the `useAnimation()` function. - * - * @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. - * @returns An object that encapsulates the animation data. - * - * @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 - */ -function animation(steps, options = null) { - return { type: 8 /* Reference */, animation: steps, options }; -} -/** - * Executes a queried inner animation element within an animation sequence. - * - * @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. - * - * @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 - */ -function animateChild(options = null) { - return { type: 9 /* AnimateChild */, options }; -} -/** - * Starts a reusable animation that is created using the `animation()` function. - * - * @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. - * - * @publicApi - */ -function useAnimation(animation, options = null) { - return { type: 10 /* AnimateRef */, animation, options }; -} -/** - * Finds one or more inner elements within the current element that is - * being animated within a sequence. Use with `animate()`. - * - * @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. - * - * @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: ` - *
- *

Title

- *
- * Blah blah blah - *
- *
- * `, - * 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 - */ -function query(selector, animation, options = null) { - return { type: 11 /* Query */, selector, animation, options }; -} -/** - * Use within an animation `query()` call to issue a timing gap after - * each queried item is animated. - * - * @param timings A delay value. - * @param animation One ore more animation steps. - * @returns An object that encapsulates the stagger data. - * - * @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 - * - * - *
- *
- *
- * {{ item }} - *
- *
- * ``` - * - * 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 - */ -function stagger(timings, animation) { - return { type: 12 /* Stagger */, timings, animation }; -} -/** - * @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 scheduleMicroTask(cb) { - Promise.resolve(null).then(cb); -} -/** - * @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 - */ -/** - * 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 - */ -class NoopAnimationPlayer { - constructor(duration = 0, delay = 0) { - this._onDoneFns = []; - this._onStartFns = []; - this._onDestroyFns = []; - this._started = false; - this._destroyed = false; - this._finished = false; - this._position = 0; - this.parentPlayer = null; - this.totalTime = duration + delay; - } - _onFinish() { - if (!this._finished) { - this._finished = true; - this._onDoneFns.forEach(fn => fn()); - this._onDoneFns = []; - } - } - onStart(fn) { - this._onStartFns.push(fn); - } - onDone(fn) { - this._onDoneFns.push(fn); - } - onDestroy(fn) { - this._onDestroyFns.push(fn); - } - hasStarted() { - return this._started; - } - init() { } - play() { - if (!this.hasStarted()) { - this._onStart(); - this.triggerMicrotask(); - } - this._started = true; - } - /** @internal */ - triggerMicrotask() { - scheduleMicroTask(() => this._onFinish()); - } - _onStart() { - this._onStartFns.forEach(fn => fn()); - this._onStartFns = []; - } - pause() { } - restart() { } - finish() { - this._onFinish(); - } - destroy() { - if (!this._destroyed) { - this._destroyed = true; - if (!this.hasStarted()) { - this._onStart(); - } - this.finish(); - this._onDestroyFns.forEach(fn => fn()); - this._onDestroyFns = []; - } - } - reset() { } - setPosition(position) { - this._position = this.totalTime ? position * this.totalTime : 1; - } - getPosition() { - return this.totalTime ? this._position / this.totalTime : 1; - } - /** @internal */ - triggerCallback(phaseName) { - const methods = phaseName == 'start' ? this._onStartFns : this._onDoneFns; - methods.forEach(fn => fn()); - methods.length = 0; - } -} -/** - * @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 - */ -/** - * A programmatic controller for a group of reusable animations. - * Used internally to control animations. - * - * @see `AnimationPlayer` - * @see `{@link animations/group group()}` - * - */ -class AnimationGroupPlayer { - constructor(_players) { - this._onDoneFns = []; - this._onStartFns = []; - this._finished = false; - this._started = false; - this._destroyed = false; - this._onDestroyFns = []; - this.parentPlayer = null; - this.totalTime = 0; - this.players = _players; - let doneCount = 0; - let destroyCount = 0; - let startCount = 0; - const total = this.players.length; - if (total == 0) { - scheduleMicroTask(() => this._onFinish()); - } - else { - this.players.forEach(player => { - player.onDone(() => { - if (++doneCount == total) { - this._onFinish(); - } - }); - player.onDestroy(() => { - if (++destroyCount == total) { - this._onDestroy(); - } - }); - player.onStart(() => { - if (++startCount == total) { - this._onStart(); - } - }); - }); - } - this.totalTime = this.players.reduce((time, player) => Math.max(time, player.totalTime), 0); - } - _onFinish() { - if (!this._finished) { - this._finished = true; - this._onDoneFns.forEach(fn => fn()); - this._onDoneFns = []; - } - } - init() { - this.players.forEach(player => player.init()); - } - onStart(fn) { - this._onStartFns.push(fn); - } - _onStart() { - if (!this.hasStarted()) { - this._started = true; - this._onStartFns.forEach(fn => fn()); - this._onStartFns = []; - } - } - onDone(fn) { - this._onDoneFns.push(fn); - } - onDestroy(fn) { - this._onDestroyFns.push(fn); - } - hasStarted() { - return this._started; - } - play() { - if (!this.parentPlayer) { - this.init(); - } - this._onStart(); - this.players.forEach(player => player.play()); - } - pause() { - this.players.forEach(player => player.pause()); - } - restart() { - this.players.forEach(player => player.restart()); - } - finish() { - this._onFinish(); - this.players.forEach(player => player.finish()); - } - destroy() { - this._onDestroy(); - } - _onDestroy() { - if (!this._destroyed) { - this._destroyed = true; - this._onFinish(); - this.players.forEach(player => player.destroy()); - this._onDestroyFns.forEach(fn => fn()); - this._onDestroyFns = []; - } - } - reset() { - this.players.forEach(player => player.reset()); - this._destroyed = false; - this._finished = false; - this._started = false; - } - setPosition(p) { - const timeAtPosition = p * this.totalTime; - this.players.forEach(player => { - const position = player.totalTime ? Math.min(1, timeAtPosition / player.totalTime) : 1; - player.setPosition(position); - }); - } - getPosition() { - const longestPlayer = this.players.reduce((longestSoFar, player) => { - const newPlayerIsLongest = longestSoFar === null || player.totalTime > longestSoFar.totalTime; - return newPlayerIsLongest ? player : longestSoFar; - }, null); - return longestPlayer != null ? longestPlayer.getPosition() : 0; - } - beforeDestroy() { - this.players.forEach(player => { - if (player.beforeDestroy) { - player.beforeDestroy(); - } - }); - } - /** @internal */ - triggerCallback(phaseName) { - const methods = phaseName == 'start' ? this._onStartFns : this._onDoneFns; - methods.forEach(fn => fn()); - methods.length = 0; - } -} -/** - * @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 - */ -const ɵPRE_STYLE = '!'; -/** - * @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 - */ -/** - * @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 - */ -/** - * Generated bundle index. Do not edit. - */ - -//# sourceMappingURL=animations.js.map - - -/***/ }), - -/***/ "R1ws": -/*!************************************************************************************!*\ - !*** ./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(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 */ "fXoL"); -/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/platform-browser */ "jhN1"); -/* harmony import */ var _angular_animations__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/animations */ "R0Ic"); -/* harmony import */ var _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! @angular/animations/browser */ "t9l1"); -/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/common */ "ofXK"); -/** - * @license Angular v11.2.14 - * (c) 2010-2021 Google LLC. https://angular.io/ - * License: MIT - */ - - - - - -/** - * @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 - */ - - -let BrowserAnimationBuilder = /*@__PURE__*/ (() => { - class BrowserAnimationBuilder extends _angular_animations__WEBPACK_IMPORTED_MODULE_2__["AnimationBuilder"] { - constructor(rootRenderer, doc) { - super(); - this._nextAnimationId = 0; - const typeData = { id: '0', encapsulation: _angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewEncapsulation"].None, styles: [], data: { animation: [] } }; - this._renderer = rootRenderer.createRenderer(doc.body, typeData); - } - build(animation) { - const id = this._nextAnimationId.toString(); - this._nextAnimationId++; - const 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); - } - } - 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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({ token: BrowserAnimationBuilder, factory: BrowserAnimationBuilder.ɵfac }); - return BrowserAnimationBuilder; -})(); -class BrowserAnimationFactory extends _angular_animations__WEBPACK_IMPORTED_MODULE_2__["AnimationFactory"] { - constructor(_id, _renderer) { - super(); - this._id = _id; - this._renderer = _renderer; - } - create(element, options) { - return new RendererAnimationPlayer(this._id, element, options || {}, this._renderer); - } -} -class RendererAnimationPlayer { - constructor(id, element, options, _renderer) { - this.id = id; - this.element = element; - this._renderer = _renderer; - this.parentPlayer = null; - this._started = false; - this.totalTime = 0; - this._command('create', options); - } - _listen(eventName, callback) { - return this._renderer.listen(this.element, `@@${this.id}:${eventName}`, callback); - } - _command(command, ...args) { - return issueAnimationCommand(this._renderer, this.element, this.id, command, args); - } - onDone(fn) { - this._listen('done', fn); - } - onStart(fn) { - this._listen('start', fn); - } - onDestroy(fn) { - this._listen('destroy', fn); - } - init() { - this._command('init'); - } - hasStarted() { - return this._started; - } - play() { - this._command('play'); - this._started = true; - } - pause() { - this._command('pause'); - } - restart() { - this._command('restart'); - } - finish() { - this._command('finish'); - } - destroy() { - this._command('destroy'); - } - reset() { - this._command('reset'); - } - setPosition(p) { - this._command('setPosition', p); - } - getPosition() { - var _a, _b; - return (_b = (_a = this._renderer.engine.players[+this.id]) === null || _a === void 0 ? void 0 : _a.getPosition()) !== null && _b !== void 0 ? _b : 0; - } -} -function issueAnimationCommand(renderer, element, id, command, args) { - return renderer.setProperty(element, `@@${id}:${command}`, args); -} -const ANIMATION_PREFIX = '@'; -const DISABLE_ANIMATIONS_FLAG = '@.disabled'; -let AnimationRendererFactory = /*@__PURE__*/ (() => { - class AnimationRendererFactory { - constructor(delegate, engine, _zone) { - 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 = (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); - } - }; - } - createRenderer(hostElement, type) { - const EMPTY_NAMESPACE_ID = ''; - // cache the delegates to find out which cached delegate can - // be used by which cached renderer - const delegate = this.delegate.createRenderer(hostElement, type); - if (!hostElement || !type || !type.data || !type.data['animation']) { - let 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; - } - const componentId = type.id; - const namespaceId = type.id + '-' + this._currentId; - this._currentId++; - this.engine.register(namespaceId, hostElement); - const registerTrigger = (trigger) => { - if (Array.isArray(trigger)) { - trigger.forEach(registerTrigger); - } - else { - this.engine.registerTrigger(componentId, namespaceId, hostElement, trigger.name, trigger); - } - }; - const animationTriggers = type.data['animation']; - animationTriggers.forEach(registerTrigger); - return new AnimationRenderer(this, namespaceId, delegate, this.engine); - } - begin() { - this._cdRecurDepth++; - if (this.delegate.begin) { - this.delegate.begin(); - } - } - _scheduleCountTask() { - // always use promise to schedule microtask instead of use Zone - this.promise.then(() => { - this._microtaskId++; - }); - } - /** @internal */ - scheduleListenerCallback(count, fn, data) { - if (count >= 0 && count < this._microtaskId) { - this._zone.run(() => fn(data)); - return; - } - if (this._animationCallbacksBuffer.length == 0) { - Promise.resolve(null).then(() => { - this._zone.run(() => { - this._animationCallbacksBuffer.forEach(tuple => { - const [fn, data] = tuple; - fn(data); - }); - this._animationCallbacksBuffer = []; - }); - }); - } - this._animationCallbacksBuffer.push([fn, data]); - } - end() { - 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(() => { - this._scheduleCountTask(); - this.engine.flush(this._microtaskId); - }); - } - if (this.delegate.end) { - this.delegate.end(); - } - } - whenRenderingDone() { - return this.engine.whenRenderingDone(); - } - } - 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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({ token: AnimationRendererFactory, factory: AnimationRendererFactory.ɵfac }); - return AnimationRendererFactory; -})(); -class BaseAnimationRenderer { - constructor(namespaceId, delegate, engine) { - this.namespaceId = namespaceId; - this.delegate = delegate; - this.engine = engine; - this.destroyNode = this.delegate.destroyNode ? (n) => delegate.destroyNode(n) : null; - } - get data() { - return this.delegate.data; - } - destroy() { - this.engine.destroy(this.namespaceId, this.delegate); - this.delegate.destroy(); - } - createElement(name, namespace) { - return this.delegate.createElement(name, namespace); - } - createComment(value) { - return this.delegate.createComment(value); - } - createText(value) { - return this.delegate.createText(value); - } - appendChild(parent, newChild) { - this.delegate.appendChild(parent, newChild); - this.engine.onInsert(this.namespaceId, newChild, parent, false); - } - insertBefore(parent, newChild, refChild, isMove = true) { - this.delegate.insertBefore(parent, newChild, refChild); - // If `isMove` true than we should animate this insert. - this.engine.onInsert(this.namespaceId, newChild, parent, isMove); - } - removeChild(parent, oldChild, isHostElement) { - this.engine.onRemove(this.namespaceId, oldChild, this.delegate, isHostElement); - } - selectRootElement(selectorOrNode, preserveContent) { - return this.delegate.selectRootElement(selectorOrNode, preserveContent); - } - parentNode(node) { - return this.delegate.parentNode(node); - } - nextSibling(node) { - return this.delegate.nextSibling(node); - } - setAttribute(el, name, value, namespace) { - this.delegate.setAttribute(el, name, value, namespace); - } - removeAttribute(el, name, namespace) { - this.delegate.removeAttribute(el, name, namespace); - } - addClass(el, name) { - this.delegate.addClass(el, name); - } - removeClass(el, name) { - this.delegate.removeClass(el, name); - } - setStyle(el, style, value, flags) { - this.delegate.setStyle(el, style, value, flags); - } - removeStyle(el, style, flags) { - this.delegate.removeStyle(el, style, flags); - } - 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); - } - } - setValue(node, value) { - this.delegate.setValue(node, value); - } - listen(target, eventName, callback) { - return this.delegate.listen(target, eventName, callback); - } - disableAnimations(element, value) { - this.engine.disableAnimations(element, value); - } -} -class AnimationRenderer extends BaseAnimationRenderer { - constructor(factory, namespaceId, delegate, engine) { - super(namespaceId, delegate, engine); - this.factory = factory; - this.namespaceId = namespaceId; - } - 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, value); - } - else { - this.engine.process(this.namespaceId, el, name.substr(1), value); - } - } - else { - this.delegate.setProperty(el, name, value); - } - } - listen(target, eventName, callback) { - if (eventName.charAt(0) == ANIMATION_PREFIX) { - const element = resolveElementFromTarget(target); - let name = eventName.substr(1); - let phase = ''; - // @listener.phase is for trigger animation callbacks - // @@listener is for animation builder callbacks - if (name.charAt(0) != ANIMATION_PREFIX) { - [name, phase] = parseTriggerCallbackName(name); - } - return this.engine.listen(this.namespaceId, element, name, phase, event => { - const countId = event['_data'] || -1; - this.factory.scheduleListenerCallback(countId, callback, event); - }); - } - return this.delegate.listen(target, eventName, callback); - } -} -function resolveElementFromTarget(target) { - switch (target) { - case 'body': - return document.body; - case 'document': - return document; - case 'window': - return window; - default: - return target; - } -} -function parseTriggerCallbackName(triggerName) { - const dotIndex = triggerName.indexOf('.'); - const trigger = triggerName.substring(0, dotIndex); - const phase = triggerName.substr(dotIndex + 1); - return [trigger, phase]; -} -let InjectableAnimationEngine = /*@__PURE__*/ (() => { - class InjectableAnimationEngine extends _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵAnimationEngine"] { - constructor(doc, driver, normalizer) { - super(doc.body, driver, normalizer); - } - } - 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 = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({ token: InjectableAnimationEngine, factory: InjectableAnimationEngine.ɵfac }); - return InjectableAnimationEngine; -})(); -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"](); -} -function instantiateDefaultStyleNormalizer() { - return new _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["ɵWebAnimationsStyleNormalizer"](); -} -function instantiateRendererFactory(renderer, engine, zone) { - return new AnimationRendererFactory(renderer, engine, zone); -} -/** - * @publicApi - */ -const ANIMATION_MODULE_TYPE = /*@__PURE__*/ new _angular_core__WEBPACK_IMPORTED_MODULE_0__["InjectionToken"]('AnimationModuleType'); -const 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. - */ -const BROWSER_ANIMATIONS_PROVIDERS = [ - { provide: _angular_animations_browser__WEBPACK_IMPORTED_MODULE_3__["AnimationDriver"], useFactory: instantiateSupportedAnimationDriver }, - { provide: ANIMATION_MODULE_TYPE, useValue: 'BrowserAnimations' }, ...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. - */ -const 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' }, ...SHARED_ANIMATION_PROVIDERS -]; -let BrowserAnimationsModule = /*@__PURE__*/ (() => { - class BrowserAnimationsModule { - } - BrowserAnimationsModule.ɵfac = function BrowserAnimationsModule_Factory(t) { return new (t || BrowserAnimationsModule)(); }; - BrowserAnimationsModule.ɵmod = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({ type: BrowserAnimationsModule }); - BrowserAnimationsModule.ɵinj = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({ providers: BROWSER_ANIMATIONS_PROVIDERS, imports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]] }); - return BrowserAnimationsModule; -})(); -/*@__PURE__*/ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](BrowserAnimationsModule, { exports: function () { return [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]]; } }); })(); -let NoopAnimationsModule = /*@__PURE__*/ (() => { - class NoopAnimationsModule { - } - NoopAnimationsModule.ɵfac = function NoopAnimationsModule_Factory(t) { return new (t || NoopAnimationsModule)(); }; - NoopAnimationsModule.ɵmod = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({ type: NoopAnimationsModule }); - NoopAnimationsModule.ɵinj = /*@__PURE__*/ _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({ providers: BROWSER_NOOP_ANIMATIONS_PROVIDERS, imports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]] }); - return NoopAnimationsModule; -})(); -/*@__PURE__*/ (function () { (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](NoopAnimationsModule, { exports: function () { return [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_1__["BrowserModule"]]; } }); })(); -/** - * @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 - */ -/** - * @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 - */ -/** - * Generated bundle index. Do not edit. - */ - -//# sourceMappingURL=animations.js.map - - -/***/ }), - -/***/ "RUbi": -/*!************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AsapScheduler.js ***! - \************************************************************************/ -/*! exports provided: AsapScheduler */ -/***/ (function(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 */ "IjjT"); - -class AsapScheduler extends _AsyncScheduler__WEBPACK_IMPORTED_MODULE_0__["AsyncScheduler"] { - flush(action) { - this.active = true; - this.scheduled = undefined; - const { actions } = this; - let error; - let index = -1; - let 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; - } - } -} -//# sourceMappingURL=AsapScheduler.js.map - - -/***/ }), - -/***/ "SeVD": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeTo.js ***! - \*****************************************************************/ -/*! exports provided: subscribeTo */ -/***/ (function(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 */ "ngJS"); -/* harmony import */ var _subscribeToPromise__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./subscribeToPromise */ "a7t3"); -/* harmony import */ var _subscribeToIterable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./subscribeToIterable */ "pLzU"); -/* harmony import */ var _subscribeToObservable__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./subscribeToObservable */ "CRDf"); -/* harmony import */ var _isArrayLike__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./isArrayLike */ "I55L"); -/* harmony import */ var _isPromise__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./isPromise */ "c2HN"); -/* harmony import */ var _isObject__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./isObject */ "XoHu"); -/* harmony import */ var _symbol_iterator__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../symbol/iterator */ "Lhse"); -/* harmony import */ var _symbol_observable__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../symbol/observable */ "kJWO"); - - - - - - - - - -const 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 { - const value = Object(_isObject__WEBPACK_IMPORTED_MODULE_6__["isObject"])(result) ? 'an invalid object' : `'${result}'`; - const msg = `You provided ${value} where a stream was expected.` - + ' You can provide an Observable, Promise, Array, or Iterable.'; - throw new TypeError(msg); - } -}; -//# sourceMappingURL=subscribeTo.js.map - - -/***/ }), - -/***/ "SpAZ": -/*!**************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/identity.js ***! - \**************************************************************/ -/*! exports provided: identity */ -/***/ (function(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 - - -/***/ }), - -/***/ "SxV6": -/*!****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/first.js ***! - \****************************************************************/ -/*! exports provided: first */ -/***/ (function(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 */ "sVev"); -/* harmony import */ var _filter__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./filter */ "pLZG"); -/* harmony import */ var _take__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./take */ "IzEk"); -/* harmony import */ var _defaultIfEmpty__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./defaultIfEmpty */ "xbPD"); -/* harmony import */ var _throwIfEmpty__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./throwIfEmpty */ "XDbj"); -/* harmony import */ var _util_identity__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../util/identity */ "SpAZ"); - - - - - - -function first(predicate, defaultValue) { - const hasDefaultValue = arguments.length >= 2; - return (source) => source.pipe(predicate ? Object(_filter__WEBPACK_IMPORTED_MODULE_1__["filter"])((v, i) => 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"])(() => new _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__["EmptyError"]())); -} -//# sourceMappingURL=first.js.map - - -/***/ }), - -/***/ "UGaM": -/*!**************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/publishBehavior.js ***! - \**************************************************************************/ -/*! exports provided: publishBehavior */ -/***/ (function(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 */ "2Vo4"); -/* harmony import */ var _multicast__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./multicast */ "oB13"); - - -function publishBehavior(value) { - return (source) => Object(_multicast__WEBPACK_IMPORTED_MODULE_1__["multicast"])(new _BehaviorSubject__WEBPACK_IMPORTED_MODULE_0__["BehaviorSubject"](value))(source); -} -//# sourceMappingURL=publishBehavior.js.map - - -/***/ }), - -/***/ "UHp3": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/windowTime.js ***! - \*********************************************************************/ -/*! exports provided: windowTime */ -/***/ (function(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 */ "XNiG"); -/* harmony import */ var _scheduler_async__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../scheduler/async */ "D0XW"); -/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Subscriber */ "7o/Q"); -/* harmony import */ var _util_isNumeric__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/isNumeric */ "Y7HM"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); - - - - - -function windowTime(windowTimeSpan) { - let scheduler = _scheduler_async__WEBPACK_IMPORTED_MODULE_1__["async"]; - let windowCreationInterval = null; - let 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 = Number(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 = Number(arguments[1]); - } - return function windowTimeOperatorFunction(source) { - return source.lift(new WindowTimeOperator(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler)); - }; -} -class WindowTimeOperator { - constructor(windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) { - this.windowTimeSpan = windowTimeSpan; - this.windowCreationInterval = windowCreationInterval; - this.maxWindowSize = maxWindowSize; - this.scheduler = scheduler; - } - call(subscriber, source) { - return source.subscribe(new WindowTimeSubscriber(subscriber, this.windowTimeSpan, this.windowCreationInterval, this.maxWindowSize, this.scheduler)); - } -} -class CountedSubject extends _Subject__WEBPACK_IMPORTED_MODULE_0__["Subject"] { - constructor() { - super(...arguments); - this._numberOfNextedValues = 0; - } - next(value) { - this._numberOfNextedValues++; - super.next(value); - } - get numberOfNextedValues() { - return this._numberOfNextedValues; - } -} -class WindowTimeSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_2__["Subscriber"] { - constructor(destination, windowTimeSpan, windowCreationInterval, maxWindowSize, scheduler) { - super(destination); - this.destination = destination; - this.windowTimeSpan = windowTimeSpan; - this.windowCreationInterval = windowCreationInterval; - this.maxWindowSize = maxWindowSize; - this.scheduler = scheduler; - this.windows = []; - const window = this.openWindow(); - if (windowCreationInterval !== null && windowCreationInterval >= 0) { - const closeState = { subscriber: this, window, context: null }; - const creationState = { windowTimeSpan, windowCreationInterval, subscriber: this, scheduler }; - this.add(scheduler.schedule(dispatchWindowClose, windowTimeSpan, closeState)); - this.add(scheduler.schedule(dispatchWindowCreation, windowCreationInterval, creationState)); - } - else { - const timeSpanOnlyState = { subscriber: this, window, windowTimeSpan }; - this.add(scheduler.schedule(dispatchWindowTimeSpanOnly, windowTimeSpan, timeSpanOnlyState)); - } - } - _next(value) { - const windows = this.windows; - const len = windows.length; - for (let i = 0; i < len; i++) { - const window = windows[i]; - if (!window.closed) { - window.next(value); - if (window.numberOfNextedValues >= this.maxWindowSize) { - this.closeWindow(window); - } - } - } - } - _error(err) { - const windows = this.windows; - while (windows.length > 0) { - windows.shift().error(err); - } - this.destination.error(err); - } - _complete() { - const windows = this.windows; - while (windows.length > 0) { - const window = windows.shift(); - if (!window.closed) { - window.complete(); - } - } - this.destination.complete(); - } - openWindow() { - const window = new CountedSubject(); - this.windows.push(window); - const destination = this.destination; - destination.next(window); - return window; - } - closeWindow(window) { - window.complete(); - const windows = this.windows; - windows.splice(windows.indexOf(window), 1); - } -} -function dispatchWindowTimeSpanOnly(state) { - const { subscriber, windowTimeSpan, window } = state; - if (window) { - subscriber.closeWindow(window); - } - state.window = subscriber.openWindow(); - this.schedule(state, windowTimeSpan); -} -function dispatchWindowCreation(state) { - const { windowTimeSpan, subscriber, scheduler, windowCreationInterval } = state; - const window = subscriber.openWindow(); - const action = this; - let context = { action, subscription: null }; - const timeSpanState = { subscriber, window, context }; - context.subscription = scheduler.schedule(dispatchWindowClose, windowTimeSpan, timeSpanState); - action.add(context.subscription); - action.schedule(state, windowCreationInterval); -} -function dispatchWindowClose(state) { - const { subscriber, window, context } = state; - if (context && context.action && context.subscription) { - context.action.remove(context.subscription); - } - subscriber.closeWindow(window); -} -//# sourceMappingURL=windowTime.js.map - - -/***/ }), - -/***/ "UXbc": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeMapTo.js ***! - \*********************************************************************/ -/*! exports provided: mergeMapTo */ -/***/ (function(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 */ "5+tZ"); - -function mergeMapTo(innerObservable, resultSelector, concurrent = Number.POSITIVE_INFINITY) { - if (typeof resultSelector === 'function') { - return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(() => innerObservable, resultSelector, concurrent); - } - if (typeof resultSelector === 'number') { - concurrent = resultSelector; - } - return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(() => innerObservable, concurrent); -} -//# sourceMappingURL=mergeMapTo.js.map - - -/***/ }), - -/***/ "UXun": -/*!**********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/shareReplay.js ***! - \**********************************************************************/ -/*! exports provided: shareReplay */ -/***/ (function(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 */ "jtHE"); - -function shareReplay(configOrBufferSize, windowTime, scheduler) { - let config; - if (configOrBufferSize && typeof configOrBufferSize === 'object') { - config = configOrBufferSize; - } - else { - config = { - bufferSize: configOrBufferSize, - windowTime, - refCount: false, - scheduler, - }; - } - return (source) => source.lift(shareReplayOperator(config)); -} -function shareReplayOperator({ bufferSize = Number.POSITIVE_INFINITY, windowTime = Number.POSITIVE_INFINITY, refCount: useRefCount, scheduler, }) { - let subject; - let refCount = 0; - let subscription; - let hasError = false; - let isComplete = false; - return function shareReplayOperation(source) { - refCount++; - let innerSub; - if (!subject || hasError) { - hasError = false; - subject = new _ReplaySubject__WEBPACK_IMPORTED_MODULE_0__["ReplaySubject"](bufferSize, windowTime, scheduler); - innerSub = subject.subscribe(this); - subscription = source.subscribe({ - next(value) { - subject.next(value); - }, - error(err) { - hasError = true; - subject.error(err); - }, - complete() { - isComplete = true; - subscription = undefined; - subject.complete(); - }, - }); - if (isComplete) { - subscription = undefined; - } - } - else { - innerSub = subject.subscribe(this); - } - this.add(() => { - refCount--; - innerSub.unsubscribe(); - innerSub = undefined; - if (subscription && !isComplete && useRefCount && refCount === 0) { - subscription.unsubscribe(); - subscription = undefined; - subject = undefined; - } - }); - }; -} -//# sourceMappingURL=shareReplay.js.map - - -/***/ }), - -/***/ "VRyK": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/merge.js ***! - \*****************************************************************/ -/*! exports provided: merge */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); -/* harmony import */ var _operators_mergeAll__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../operators/mergeAll */ "bHdf"); -/* harmony import */ var _fromArray__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./fromArray */ "yCtX"); - - - - -function merge(...observables) { - let concurrent = Number.POSITIVE_INFINITY; - let scheduler = null; - let 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 - - -/***/ }), - -/***/ "Vpsf": -/*!*******************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/AnimationFrameAction.js ***! - \*******************************************************************************/ -/*! exports provided: AnimationFrameAction */ -/***/ (function(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 */ "3N8a"); - -class AnimationFrameAction extends _AsyncAction__WEBPACK_IMPORTED_MODULE_0__["AsyncAction"] { - constructor(scheduler, work) { - super(scheduler, work); - this.scheduler = scheduler; - this.work = work; - } - requestAsyncId(scheduler, id, delay = 0) { - if (delay !== null && delay > 0) { - return super.requestAsyncId(scheduler, id, delay); - } - scheduler.actions.push(this); - return scheduler.scheduled || (scheduler.scheduled = requestAnimationFrame(() => scheduler.flush(null))); - } - recycleAsyncId(scheduler, id, delay = 0) { - if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { - return super.recycleAsyncId(scheduler, id, delay); - } - if (scheduler.actions.length === 0) { - cancelAnimationFrame(id); - scheduler.scheduled = undefined; - } - return undefined; - } -} -//# sourceMappingURL=AnimationFrameAction.js.map - - -/***/ }), - -/***/ "WMd4": -/*!*************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/Notification.js ***! - \*************************************************************/ -/*! exports provided: NotificationKind, Notification */ -/***/ (function(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 */ "EY2u"); -/* harmony import */ var _observable_of__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./observable/of */ "LRne"); -/* harmony import */ var _observable_throwError__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./observable/throwError */ "z6cu"); - - - -var NotificationKind = /*@__PURE__*/ (function (NotificationKind) { - NotificationKind["NEXT"] = "N"; - NotificationKind["ERROR"] = "E"; - NotificationKind["COMPLETE"] = "C"; - return NotificationKind; -})({}); -let Notification = /*@__PURE__*/ (() => { - class Notification { - constructor(kind, value, error) { - this.kind = kind; - this.value = value; - this.error = error; - this.hasValue = kind === 'N'; - } - 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(); - } - } - do(next, error, complete) { - const kind = this.kind; - switch (kind) { - case 'N': - return next && next(this.value); - case 'E': - return error && error(this.error); - case 'C': - return complete && complete(); - } - } - accept(nextOrObserver, error, complete) { - if (nextOrObserver && typeof nextOrObserver.next === 'function') { - return this.observe(nextOrObserver); - } - else { - return this.do(nextOrObserver, error, complete); - } - } - toObservable() { - const 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'); - } - static createNext(value) { - if (typeof value !== 'undefined') { - return new Notification('N', value); - } - return Notification.undefinedValueNotification; - } - static createError(err) { - return new Notification('E', undefined, err); - } - static createComplete() { - return Notification.completeNotification; - } - } - Notification.completeNotification = /*@__PURE__*/ new Notification('C'); - Notification.undefinedValueNotification = /*@__PURE__*/ new Notification('N', undefined); - return Notification; -})(); -//# sourceMappingURL=Notification.js.map - - -/***/ }), - -/***/ "WPMC": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/generate.js ***! - \********************************************************************/ -/*! exports provided: generate */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _util_identity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/identity */ "SpAZ"); -/* harmony import */ var _util_isScheduler__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../util/isScheduler */ "z+Ro"); - - - -function generate(initialStateOrOptions, condition, iterate, resultSelectorOrObservable, scheduler) { - let resultSelector; - let initialState; - if (arguments.length == 1) { - const 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"](subscriber => { - let state = initialState; - if (scheduler) { - return scheduler.schedule(dispatch, 0, { - subscriber, - iterate, - condition, - resultSelector, - state - }); - } - do { - if (condition) { - let conditionResult; - try { - conditionResult = condition(state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - if (!conditionResult) { - subscriber.complete(); - break; - } - } - let value; - 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) { - const { subscriber, condition } = state; - 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) { - let conditionResult; - try { - conditionResult = condition(state.state); - } - catch (err) { - subscriber.error(err); - return undefined; - } - if (!conditionResult) { - subscriber.complete(); - return undefined; - } - if (subscriber.closed) { - return undefined; - } - } - let 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 - - -/***/ }), - -/***/ "WyKG": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/toSubscriber.js ***! - \******************************************************************/ -/*! exports provided: toSubscriber */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../symbol/rxSubscriber */ "2QA8"); -/* harmony import */ var _Observer__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Observer */ "gRHU"); - - - -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 - - -/***/ }), - -/***/ "WyaX": -/*!***************************************************************************************************!*\ - !*** ./node_modules/ngx-bootstrap/__ivy_ngcc__/positioning/fesm2015/ngx-bootstrap-positioning.js ***! - \***************************************************************************************************/ -/*! exports provided: PlacementForBs5, Positioning, PositioningService, checkMargins, positionElements */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PlacementForBs5", function() { return PlacementForBs5; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Positioning", function() { return Positioning; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "PositioningService", function() { return PositioningService; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "checkMargins", function() { return checkMargins; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "positionElements", function() { return positionElements; }); -/* harmony import */ var ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ngx-bootstrap/utils */ "lUod"); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/core */ "fXoL"); -/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/common */ "ofXK"); -/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! rxjs */ "qCKp"); - - - - - -var MapPlacementInToRL = /*@__PURE__*/ (function (MapPlacementInToRL) { - MapPlacementInToRL["top"] = "top"; - MapPlacementInToRL["bottom"] = "bottom"; - MapPlacementInToRL["left"] = "left"; - MapPlacementInToRL["right"] = "right"; - MapPlacementInToRL["auto"] = "auto"; - MapPlacementInToRL["end"] = "right"; - MapPlacementInToRL["start"] = "left"; - MapPlacementInToRL["top left"] = "top left"; - MapPlacementInToRL["top right"] = "top right"; - MapPlacementInToRL["right top"] = "right top"; - MapPlacementInToRL["right bottom"] = "right bottom"; - MapPlacementInToRL["bottom right"] = "bottom right"; - MapPlacementInToRL["bottom left"] = "bottom left"; - MapPlacementInToRL["left bottom"] = "left bottom"; - MapPlacementInToRL["left top"] = "left top"; - MapPlacementInToRL["top start"] = "top left"; - MapPlacementInToRL["top end"] = "top right"; - MapPlacementInToRL["end top"] = "right top"; - MapPlacementInToRL["end bottom"] = "right bottom"; - MapPlacementInToRL["bottom end"] = "bottom right"; - MapPlacementInToRL["bottom start"] = "bottom left"; - MapPlacementInToRL["start bottom"] = "start bottom"; - MapPlacementInToRL["start top"] = "left top"; - return MapPlacementInToRL; -})({}); -var PlacementForBs5 = /*@__PURE__*/ (function (PlacementForBs5) { - PlacementForBs5["top"] = "top"; - PlacementForBs5["bottom"] = "bottom"; - PlacementForBs5["left"] = "start"; - PlacementForBs5["right"] = "end"; - PlacementForBs5["auto"] = "auto"; - PlacementForBs5["end"] = "end"; - PlacementForBs5["start"] = "start"; - PlacementForBs5["top left"] = "top start"; - PlacementForBs5["top right"] = "top end"; - PlacementForBs5["right top"] = "end top"; - PlacementForBs5["right bottom"] = "end bottom"; - PlacementForBs5["bottom right"] = "bottom end"; - PlacementForBs5["bottom left"] = "bottom start"; - PlacementForBs5["left bottom"] = "start bottom"; - PlacementForBs5["left top"] = "start top"; - PlacementForBs5["top start"] = "top start"; - PlacementForBs5["top end"] = "top end"; - PlacementForBs5["end top"] = "end top"; - PlacementForBs5["end bottom"] = "end bottom"; - PlacementForBs5["bottom end"] = "bottom end"; - PlacementForBs5["bottom start"] = "bottom start"; - PlacementForBs5["start bottom"] = "start bottom"; - PlacementForBs5["start top"] = "start top"; - return PlacementForBs5; -})({}); -function getStyleComputedProperty(element, property) { - if (element.nodeType !== 1) { - return []; - } - // NOTE: 1 DOM access here - const window = element.ownerDocument.defaultView; - const css = window === null || window === void 0 ? void 0 : window.getComputedStyle(element, null); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore - return property ? css && css[property] : css; -} -const isBrowser = typeof window !== 'undefined' && typeof document !== 'undefined'; -/** - * Determines if the browser is Internet Explorer - */ -// todo: valorkin fix and drop IE support :evil: -// eslint-disable-next-line @typescript-eslint/no-explicit-any -const isIE11 = isBrowser && !!(window.MSInputMethodContext && document.documentMode); -const isIE10 = isBrowser && !!(window.MSInputMethodContext && /MSIE 10/.test(navigator.userAgent)); -function isIE(version) { - if (version === 11) { - return isIE11; - } - if (version === 10) { - return isIE10; - } - return isIE11 || isIE10; -} -/** - * Returns the offset parent of the given element - */ -function getOffsetParent(element) { - if (!element) { - return document.documentElement; - } - const noOffsetParent = isIE(10) ? document.body : null; - // NOTE: 1 DOM access here - let offsetParent = element === null || element === void 0 ? void 0 : element.offsetParent; - // Skip hidden elements which don't have an offsetParent - let sibling = void 0; - while (offsetParent === noOffsetParent - && element.nextElementSibling - && sibling !== element.nextElementSibling) { - // todo: valorkin fix - sibling = element.nextElementSibling; - offsetParent = sibling.offsetParent; - } - const nodeName = offsetParent && offsetParent.nodeName; - if (!nodeName || nodeName === 'BODY' || nodeName === 'HTML') { - return sibling ? sibling.ownerDocument.documentElement : document.documentElement; - } - // .offsetParent will return the closest TH, TD or TABLE in case - if (offsetParent && - ['TH', 'TD', 'TABLE'].indexOf(offsetParent.nodeName) !== -1 && - getStyleComputedProperty(offsetParent, 'position') === 'static') { - return getOffsetParent(offsetParent); - } - return offsetParent; -} -// todo: valorkin fix -// eslint-disable-next-line @typescript-eslint/no-explicit-any -function isOffsetContainer(element) { - const { nodeName } = element; - if (nodeName === 'BODY') { - return false; - } - return (nodeName === 'HTML' || getOffsetParent(element.firstElementChild) === element); -} -/** - * Finds the root node (document, shadowDOM root) of the given element - */ -function getRoot(node) { - if (node.parentNode !== null) { - return getRoot(node.parentNode); - } - return node; -} -/** - * Finds the offset parent common to the two provided nodes - */ -function findCommonOffsetParent(element1, element2) { - // This check is needed to avoid errors in case one of the elements isn't defined for any reason - if (!element1 || !element1.nodeType || !element2 || !element2.nodeType) { - return document.documentElement; - } - // Here we make sure to give as "start" the element that comes first in the DOM - const order = element1.compareDocumentPosition(element2) & Node.DOCUMENT_POSITION_FOLLOWING; - const start = order ? element1 : element2; - const end = order ? element2 : element1; - // Get common ancestor container - const range = document.createRange(); - range.setStart(start, 0); - range.setEnd(end, 0); - // todo: valorkin fix - const commonAncestorContainer = range.commonAncestorContainer; - // Both nodes are inside #document - if ((element1 !== commonAncestorContainer && - element2 !== commonAncestorContainer) || - start.contains(end)) { - if (isOffsetContainer(commonAncestorContainer)) { - return commonAncestorContainer; - } - return getOffsetParent(commonAncestorContainer); - } - // one of the nodes is inside shadowDOM, find which one - const element1root = getRoot(element1); - if (element1root.host) { - return findCommonOffsetParent(element1root.host, element2); - } - else { - return findCommonOffsetParent(element1, getRoot(element2).host); - } -} -/** - * Finds the first parent of an element that has a transformed property defined - */ -function getFixedPositionOffsetParent(element) { - // This check is needed to avoid errors in case one of the elements isn't defined for any reason - if (!element || !element.parentElement || isIE()) { - return document.documentElement; - } - let el = element.parentElement; - while ((el === null || el === void 0 ? void 0 : el.parentElement) && getStyleComputedProperty(el, 'transform') === 'none') { - el = el.parentElement; - } - return el || document.documentElement; -} -/** - * Helper to detect borders of a given element - */ -function getBordersSize(styles, axis) { - const sideA = axis === 'x' ? 'Left' : 'Top'; - const sideB = sideA === 'Left' ? 'Right' : 'Bottom'; - return (parseFloat(styles[`border${sideA}Width`]) + - parseFloat(styles[`border${sideB}Width`])); -} -function getSize(axis, body, html, computedStyle) { - const _body = body; - const _html = html; - const _computedStyle = computedStyle; - return Math.max(_body[`offset${axis}`], _body[`scroll${axis}`], _html[`client${axis}`], _html[`offset${axis}`], _html[`scroll${axis}`], isIE(10) - ? (parseInt(_html[`offset${axis}`], 10) + - parseInt(_computedStyle[`margin${axis === 'Height' ? 'Top' : 'Left'}`], 10) + - parseInt(_computedStyle[`margin${axis === 'Height' ? 'Bottom' : 'Right'}`], 10)) - : 0); -} -function getWindowSizes(document) { - const body = document.body; - const html = document.documentElement; - const computedStyle = isIE(10) ? getComputedStyle(html) : void 0; - return { - height: getSize('Height', body, html, computedStyle), - width: getSize('Width', body, html, computedStyle) - }; -} -/** - * Gets the scroll value of the given element in the given side (top and left) - */ -function getScroll(element, side = 'top') { - const upperSide = side === 'top' ? 'scrollTop' : 'scrollLeft'; - const nodeName = element.nodeName; - if (nodeName === 'BODY' || nodeName === 'HTML') { - const html = element.ownerDocument.documentElement; - const scrollingElement = element.ownerDocument.scrollingElement || html; - return scrollingElement[upperSide]; - } - return element[upperSide]; -} -function getClientRect(offsets) { - return Object.assign(Object.assign({}, offsets), { right: (offsets.left || 0) + offsets.width, bottom: (offsets.top || 0) + offsets.height }); -} -/** - * Tells if a given input is a number - */ -function isNumeric(n) { - return n !== '' && !isNaN(parseFloat(n)) && isFinite(Number(n)); -} -// eslint-disable-next-line @typescript-eslint/no-explicit-any -function isNumber(value) { - return typeof value === 'number' || Object.prototype.toString.call(value) === '[object Number]'; -} -/** - * Get bounding client rect of given element - */ -function getBoundingClientRect(element) { - const rect = element.getBoundingClientRect(); - // IE10 10 FIX: Please, don't ask, the element isn't - // considered in DOM in some circumstances... - // This isn't reproducible in IE10 compatibility mode of IE11 - try { - if (isIE(10)) { - const scrollTop = getScroll(element, 'top'); - const scrollLeft = getScroll(element, 'left'); - if (rect && isNumber(rect.top) && isNumber(rect.left) && isNumber(rect.bottom) && isNumber(rect.right)) { - rect.top += scrollTop; - rect.left += scrollLeft; - rect.bottom += scrollTop; - rect.right += scrollLeft; - } - } - } - catch (e) { - return rect; - } - if (!(rect && isNumber(rect.top) && isNumber(rect.left) && isNumber(rect.bottom) && isNumber(rect.right))) { - return rect; - } - const result = { - left: rect.left, - top: rect.top, - width: rect.right - rect.left, - height: rect.bottom - rect.top - }; - // subtract scrollbar size from sizes - const sizes = element.nodeName === 'HTML' ? getWindowSizes(element.ownerDocument) : undefined; - const width = (sizes === null || sizes === void 0 ? void 0 : sizes.width) || element.clientWidth - || isNumber(rect.right) && isNumber(result.left) && rect.right - result.left || 0; - const height = (sizes === null || sizes === void 0 ? void 0 : sizes.height) || element.clientHeight - || isNumber(rect.bottom) && isNumber(result.top) && rect.bottom - result.top || 0; - let horizScrollbar = element.offsetWidth - width; - let vertScrollbar = element.offsetHeight - height; - // if an hypothetical scrollbar is detected, we must be sure it's not a `border` - // we make this check conditional for performance reasons - if (horizScrollbar || vertScrollbar) { - const styles = getStyleComputedProperty(element); - horizScrollbar -= getBordersSize(styles, 'x'); - vertScrollbar -= getBordersSize(styles, 'y'); - result.width -= horizScrollbar; - result.height -= vertScrollbar; - } - return getClientRect(result); -} -/** - * Returns the parentNode or the host of the element - */ -// todo: valorkin fix -// eslint-disable-next-line @typescript-eslint/no-explicit-any -function getParentNode(element) { - if (element.nodeName === 'HTML') { - return element; - } - return element.parentNode || element.host; -} -/** - * Returns the scrolling parent of the given element - */ -// todo: valorkin fix -// eslint-disable-next-line @typescript-eslint/no-explicit-any -function getScrollParent(element) { - // Return body, `getScroll` will take care to get the correct `scrollTop` from it - if (!element) { - return document.body; - } - switch (element.nodeName) { - case 'HTML': - case 'BODY': - return element.ownerDocument.body; - case '#document': - return element.body; - default: - } - // Firefox want us to check `-x` and `-y` variations as well - const { overflow, overflowX, overflowY } = getStyleComputedProperty(element); - if (/(auto|scroll|overlay)/.test(String(overflow) + String(overflowY) + String(overflowX))) { - return element; - } - return getScrollParent(getParentNode(element)); -} -/** - * Sum or subtract the element scroll values (left and top) from a given rect object - */ -function includeScroll(rect, element, subtract = false) { - const scrollTop = getScroll(element, 'top'); - const scrollLeft = getScroll(element, 'left'); - const modifier = subtract ? -1 : 1; - if (isNumber(rect.top)) { - rect.top += scrollTop * modifier; - } - if (isNumber(rect.bottom)) { - rect.bottom += scrollTop * modifier; - } - if (isNumber(rect.left)) { - rect.left += scrollLeft * modifier; - } - if (isNumber(rect.right)) { - rect.right += scrollLeft * modifier; - } - return rect; -} -function getOffsetRectRelativeToArbitraryNode(children, parent, fixedPosition = false) { - var _a, _b, _c, _d, _e, _f; - const isIE10 = isIE(10); - const isHTML = parent.nodeName === 'HTML'; - const childrenRect = getBoundingClientRect(children); - const parentRect = getBoundingClientRect(parent); - const scrollParent = getScrollParent(children); - const styles = getStyleComputedProperty(parent); - const borderTopWidth = parseFloat(styles.borderTopWidth); - const borderLeftWidth = parseFloat(styles.borderLeftWidth); - // In cases where the parent is fixed, we must ignore negative scroll in offset calc - if (fixedPosition && isHTML) { - parentRect.top = Math.max((_a = parentRect.top) !== null && _a !== void 0 ? _a : 0, 0); - parentRect.left = Math.max((_b = parentRect.left) !== null && _b !== void 0 ? _b : 0, 0); - } - let offsets = getClientRect({ - top: ((_c = childrenRect.top) !== null && _c !== void 0 ? _c : 0) - ((_d = parentRect.top) !== null && _d !== void 0 ? _d : 0) - borderTopWidth, - left: ((_e = childrenRect.left) !== null && _e !== void 0 ? _e : 0) - ((_f = parentRect.left) !== null && _f !== void 0 ? _f : 0) - borderLeftWidth, - width: childrenRect.width, - height: childrenRect.height - }); - offsets.marginTop = 0; - offsets.marginLeft = 0; - // Subtract margins of documentElement in case it's being used as parent - // we do this only on HTML because it's the only element that behaves - // differently when margins are applied to it. The margins are included in - // the box of the documentElement, in the other cases not. - if (!isIE10 && isHTML) { - const marginTop = parseFloat(styles.marginTop); - const marginLeft = parseFloat(styles.marginLeft); - if (isNumber(offsets.top)) { - offsets.top -= borderTopWidth - marginTop; - } - if (isNumber(offsets.bottom)) { - offsets.bottom -= borderTopWidth - marginTop; - } - if (isNumber(offsets.left)) { - offsets.left -= borderLeftWidth - marginLeft; - } - if (isNumber(offsets.right)) { - offsets.right -= borderLeftWidth - marginLeft; - } - // Attach marginTop and marginLeft because in some circumstances we may need them - offsets.marginTop = marginTop; - offsets.marginLeft = marginLeft; - } - if (isIE10 && !fixedPosition - ? parent.contains(scrollParent) - : parent === scrollParent && scrollParent.nodeName !== 'BODY') { - offsets = includeScroll(offsets, parent); - } - return offsets; -} -function getViewportOffsetRectRelativeToArtbitraryNode(element, excludeScroll = false) { - const html = element.ownerDocument.documentElement; - const relativeOffset = getOffsetRectRelativeToArbitraryNode(element, html); - const width = Math.max(html.clientWidth, window.innerWidth || 0); - const height = Math.max(html.clientHeight, window.innerHeight || 0); - const scrollTop = !excludeScroll ? getScroll(html) : 0; - const scrollLeft = !excludeScroll ? getScroll(html, 'left') : 0; - const offset = { - top: scrollTop - Number(relativeOffset === null || relativeOffset === void 0 ? void 0 : relativeOffset.top) + Number(relativeOffset === null || relativeOffset === void 0 ? void 0 : relativeOffset.marginTop), - left: scrollLeft - Number(relativeOffset === null || relativeOffset === void 0 ? void 0 : relativeOffset.left) + Number(relativeOffset === null || relativeOffset === void 0 ? void 0 : relativeOffset.marginLeft), - width, - height - }; - return getClientRect(offset); -} -/** - * Check if the given element is fixed or is inside a fixed parent - */ -function isFixed(element) { - const nodeName = element.nodeName; - if (nodeName === 'BODY' || nodeName === 'HTML') { - return false; - } - if (getStyleComputedProperty(element, 'position') === 'fixed') { - return true; - } - return isFixed(getParentNode(element)); -} -function getBoundaries(target, host, padding = 0, boundariesElement, fixedPosition = false) { - // NOTE: 1 DOM access here - let boundaries = { top: 0, left: 0 }; - const offsetParent = fixedPosition ? getFixedPositionOffsetParent(target) : findCommonOffsetParent(target, host); - // Handle viewport case - if (boundariesElement === 'viewport') { - boundaries = getViewportOffsetRectRelativeToArtbitraryNode(offsetParent, fixedPosition); - } - else { - // Handle other cases based on DOM element used as boundaries - let boundariesNode; - if (boundariesElement === 'scrollParent') { - boundariesNode = getScrollParent(getParentNode(host)); - if (boundariesNode.nodeName === 'BODY') { - boundariesNode = target.ownerDocument.documentElement; - } - } - else if (boundariesElement === 'window') { - boundariesNode = target.ownerDocument.documentElement; - } - else { - boundariesNode = boundariesElement; - } - const offsets = getOffsetRectRelativeToArbitraryNode(boundariesNode, offsetParent, fixedPosition); - // In case of HTML, we need a different computation - if (offsets && boundariesNode.nodeName === 'HTML' && !isFixed(offsetParent)) { - const { height, width } = getWindowSizes(target.ownerDocument); - if (isNumber(boundaries.top) && isNumber(offsets.top) && isNumber(offsets.marginTop)) { - boundaries.top += offsets.top - offsets.marginTop; - } - if (isNumber(boundaries.top)) { - boundaries.bottom = Number(height) + Number(offsets.top); - } - if (isNumber(boundaries.left) && isNumber(offsets.left) && isNumber(offsets.marginLeft)) { - boundaries.left += offsets.left - offsets.marginLeft; - } - if (isNumber(boundaries.top)) { - boundaries.right = Number(width) + Number(offsets.left); - } - } - else if (offsets) { - // for all the other DOM elements, this one is good - boundaries = offsets; - } - } - // Add paddings - if (isNumber(boundaries.left)) { - boundaries.left += padding; - } - if (isNumber(boundaries.top)) { - boundaries.top += padding; - } - if (isNumber(boundaries.right)) { - boundaries.right -= padding; - } - if (isNumber(boundaries.bottom)) { - boundaries.bottom -= padding; - } - return boundaries; -} -/** - * Utility used to transform the `auto` placement to the placement with more - * available space. - */ -function getArea({ width, height }) { - return width * height; -} -function computeAutoPlacement(placement, refRect, target, host, allowedPositions = ['top', 'bottom', 'right', 'left'], boundariesElement = 'viewport', padding = 0) { - var _a, _b, _c, _d; - if (placement.indexOf('auto') === -1) { - return placement; - } - const boundaries = getBoundaries(target, host, padding, boundariesElement); - const rects = { - top: { - width: (_a = boundaries.width) !== null && _a !== void 0 ? _a : 0, - height: refRect.top && boundaries.top ? refRect.top - boundaries.top : 0 - }, - right: { - width: boundaries.right && refRect.right ? boundaries.right - refRect.right : 0, - height: (_b = boundaries.height) !== null && _b !== void 0 ? _b : 0 - }, - bottom: { - width: (_c = boundaries.width) !== null && _c !== void 0 ? _c : 0, - height: boundaries.bottom && refRect.bottom ? boundaries.bottom - refRect.bottom : 0 - }, - left: { - width: refRect.left && boundaries.left ? refRect.left - boundaries.left : 0, - height: (_d = boundaries.height) !== null && _d !== void 0 ? _d : 0 - } - }; - const sortedAreas = Object.keys(rects) - .map((key) => (Object.assign(Object.assign({ key }, rects[key]), { area: getArea(rects[key]) }))) - .sort((a, b) => b.area - a.area); - let filteredAreas = sortedAreas.filter(({ width, height }) => { - return width >= target.clientWidth - && height >= target.clientHeight; - }); - filteredAreas = filteredAreas.filter((position) => { - return allowedPositions - .some((allowedPosition) => { - return allowedPosition === position.key; - }); - }); - const computedPlacement = filteredAreas.length > 0 - ? filteredAreas[0].key - : sortedAreas[0].key; - const variation = placement.split(' ')[1]; - // for tooltip on auto position - target.className = target.className.replace(/bs-tooltip-auto/g, `bs-tooltip-${Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_0__["getBsVer"])().isBs5 ? PlacementForBs5[computedPlacement] : computedPlacement}`); - return computedPlacement + (variation ? `-${variation}` : ''); -} -function getOffsets(data) { - var _a, _b, _c, _d; - return { - width: data.offsets.target.width, - height: data.offsets.target.height, - left: Math.floor((_a = data.offsets.target.left) !== null && _a !== void 0 ? _a : 0), - top: Math.round((_b = data.offsets.target.top) !== null && _b !== void 0 ? _b : 0), - bottom: Math.round((_c = data.offsets.target.bottom) !== null && _c !== void 0 ? _c : 0), - right: Math.floor((_d = data.offsets.target.right) !== null && _d !== void 0 ? _d : 0) - }; -} -/** - * Get the opposite placement of the given one - */ -function getOppositePlacement(placement) { - const hash = { left: 'right', right: 'left', bottom: 'top', top: 'bottom' }; - return placement.replace(/left|right|bottom|top/g, matched => hash[matched]); -} -/** - * Get the opposite placement variation of the given one - */ -function getOppositeVariation(variation) { - if (variation === 'right') { - return 'left'; - } - else if (variation === 'left') { - return 'right'; - } - return variation; -} -const parse = (value, def = 0) => value ? parseFloat(value) : def; -const ɵ0 = parse; -function getOuterSizes(element) { - const window = element.ownerDocument.defaultView; - const styles = window === null || window === void 0 ? void 0 : window.getComputedStyle(element); - const x = parse(styles === null || styles === void 0 ? void 0 : styles.marginTop) + parse(styles === null || styles === void 0 ? void 0 : styles.marginBottom); - const y = parse(styles === null || styles === void 0 ? void 0 : styles.marginLeft) + parse(styles === null || styles === void 0 ? void 0 : styles.marginRight); - return { - width: Number(element.offsetWidth) + y, - height: Number(element.offsetHeight) + x - }; -} -/** - * Get offsets to the reference element - */ -function getReferenceOffsets(target, host, fixedPosition) { - const commonOffsetParent = fixedPosition - ? getFixedPositionOffsetParent(target) - : findCommonOffsetParent(target, host); - return getOffsetRectRelativeToArbitraryNode(host, commonOffsetParent, fixedPosition); -} -/** - * Get offsets to the target - */ -function getTargetOffsets(target, hostOffsets, position) { - var _a, _b, _c; - const placement = position.split(' ')[0]; - // Get target node sizes - const targetRect = getOuterSizes(target); - // Add position, width and height to our offsets object - const targetOffsets = { - width: targetRect.width, - height: targetRect.height - }; - // depending by the target placement we have to compute its offsets slightly differently - const isHoriz = ['right', 'left'].indexOf(placement) !== -1; - const mainSide = isHoriz ? 'top' : 'left'; - const secondarySide = isHoriz ? 'left' : 'top'; - const measurement = isHoriz ? 'height' : 'width'; - const secondaryMeasurement = !isHoriz ? 'height' : 'width'; - targetOffsets[mainSide] = - ((_a = hostOffsets[mainSide]) !== null && _a !== void 0 ? _a : 0) + - hostOffsets[measurement] / 2 - - targetRect[measurement] / 2; - targetOffsets[secondarySide] = placement === secondarySide - ? ((_b = hostOffsets[secondarySide]) !== null && _b !== void 0 ? _b : 0) - targetRect[secondaryMeasurement] - : (_c = hostOffsets[getOppositePlacement(secondarySide)]) !== null && _c !== void 0 ? _c : 0; - return targetOffsets; -} -function isModifierEnabled(options, modifierName) { - var _a; - return !!((_a = options.modifiers[modifierName]) === null || _a === void 0 ? void 0 : _a.enabled); -} -const availablePositions = { - top: ['top', 'top start', 'top end'], - bottom: ['bottom', 'bottom start', 'bottom end'], - start: ['start', 'start top', 'start bottom'], - end: ['end', 'end top', 'end bottom'] -}; -function checkPopoverMargin(placement, checkPosition) { - if (!Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_0__["getBsVer"])().isBs5) { - return false; - } - return availablePositions[checkPosition].includes(placement); -} -function checkMargins(placement) { - if (!Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_0__["getBsVer"])().isBs5) { - return ''; - } - if (checkPopoverMargin(placement, 'end')) { - return 'ms-2'; - } - if (checkPopoverMargin(placement, 'start')) { - return 'me-2'; - } - if (checkPopoverMargin(placement, 'top')) { - return 'mb-2'; - } - if (checkPopoverMargin(placement, 'bottom')) { - return 'mt-2'; - } - return ''; -} -function updateContainerClass(data, renderer) { - const target = data.instance.target; - let containerClass = target.className; - const dataPlacement = Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_0__["getBsVer"])().isBs5 ? PlacementForBs5[data.placement] : data.placement; - if (data.placementAuto) { - containerClass = containerClass.replace(/bs-popover-auto/g, `bs-popover-${dataPlacement}`); - containerClass = containerClass.replace(/ms-2|me-2|mb-2|mt-2/g, ''); - containerClass = containerClass.replace(/bs-tooltip-auto/g, `bs-tooltip-${dataPlacement}`); - containerClass = containerClass.replace(/\sauto/g, ` ${dataPlacement}`); - if (containerClass.indexOf('popover') !== -1) { - containerClass = containerClass + ' ' + checkMargins(dataPlacement); - } - if (containerClass.indexOf('popover') !== -1 && containerClass.indexOf('popover-auto') === -1) { - containerClass += ' popover-auto'; - } - if (containerClass.indexOf('tooltip') !== -1 && containerClass.indexOf('tooltip-auto') === -1) { - containerClass += ' tooltip-auto'; - } - } - containerClass = containerClass.replace(/left|right|top|bottom|end|start/g, `${dataPlacement.split(' ')[0]}`); - if (renderer) { - renderer.setAttribute(target, 'class', containerClass); - return; - } - target.className = containerClass; -} -function setStyles(element, styles, renderer) { - if (!element || !styles) { - return; - } - Object.keys(styles).forEach((prop) => { - let unit = ''; - // add unit if the value is numeric and is one of the following - if (['width', 'height', 'top', 'right', 'bottom', 'left'].indexOf(prop) !== -1 && - isNumeric(styles[prop])) { - unit = 'px'; - } - if (renderer) { - renderer.setStyle(element, prop, `${String(styles[prop])}${unit}`); - return; - } - // eslint-disable-next-line @typescript-eslint/no-explicit-any - element.style[prop] = String(styles[prop]) + unit; - }); -} -function arrow(data) { - var _a, _b, _c, _d, _e, _f; - let targetOffsets = data.offsets.target; - // if arrowElement is a string, suppose it's a CSS selector - const arrowElement = data.instance.target.querySelector('.arrow'); - // if arrowElement is not found, don't run the modifier - if (!arrowElement) { - return data; - } - const isVertical = ['left', 'right'].indexOf(data.placement.split(' ')[0]) !== -1; - const len = isVertical ? 'height' : 'width'; - const sideCapitalized = isVertical ? 'Top' : 'Left'; - const side = sideCapitalized.toLowerCase(); - const altSide = isVertical ? 'left' : 'top'; - const opSide = isVertical ? 'bottom' : 'right'; - const arrowElementSize = getOuterSizes(arrowElement)[len]; - const placementVariation = data.placement.split(' ')[1]; - // top/left side - if (((_a = data.offsets.host[opSide]) !== null && _a !== void 0 ? _a : 0) - arrowElementSize < ((_b = targetOffsets[side]) !== null && _b !== void 0 ? _b : 0)) { - (targetOffsets)[side] -= - ((_c = targetOffsets[side]) !== null && _c !== void 0 ? _c : 0) - (((_d = data.offsets.host[opSide]) !== null && _d !== void 0 ? _d : 0) - arrowElementSize); - } - // bottom/right side - if (Number((data).offsets.host[side]) + Number(arrowElementSize) > ((_e = targetOffsets[opSide]) !== null && _e !== void 0 ? _e : 0)) { - (targetOffsets)[side] += - Number((data).offsets.host[side]) + Number(arrowElementSize) - Number((targetOffsets)[opSide]); - } - targetOffsets = getClientRect(targetOffsets); - // Compute the sideValue using the updated target offsets - // take target margin in account because we don't have this info available - const css = getStyleComputedProperty(data.instance.target); - const targetMarginSide = parseFloat(css[`margin${sideCapitalized}`]) || 0; - const targetBorderSide = parseFloat(css[`border${sideCapitalized}Width`]) || 0; - // compute center of the target - let center; - if (!placementVariation) { - center = Number((data).offsets.host[side]) + Number(data.offsets.host[len] / 2 - arrowElementSize / 2); - } - else { - const targetBorderRadius = parseFloat(css.borderRadius) || 0; - const targetSideArrowOffset = Number(targetMarginSide + targetBorderSide + targetBorderRadius); - center = side === placementVariation ? - Number((data).offsets.host[side]) + targetSideArrowOffset : - Number((data).offsets.host[side]) + Number(data.offsets.host[len] - targetSideArrowOffset); - } - let sideValue = center - ((_f = targetOffsets[side]) !== null && _f !== void 0 ? _f : 0) - targetMarginSide - targetBorderSide; - // prevent arrowElement from being placed not contiguously to its target - sideValue = Math.max(Math.min(targetOffsets[len] - (arrowElementSize + 5), sideValue), 0); - data.offsets.arrow = { - [side]: Math.round(sideValue), - [altSide]: '' // make sure to unset any eventual altSide value from the DOM node - }; - data.instance.arrow = arrowElement; - return data; -} -function flip(data) { - data.offsets.target = getClientRect(data.offsets.target); - if (!isModifierEnabled(data.options, 'flip')) { - data.offsets.target = Object.assign(Object.assign({}, data.offsets.target), getTargetOffsets(data.instance.target, data.offsets.host, data.placement)); - return data; - } - const boundaries = getBoundaries(data.instance.target, data.instance.host, 0, // padding - 'viewport', false // positionFixed - ); - let placement = data.placement.split(' ')[0]; - let variation = data.placement.split(' ')[1] || ''; - const offsetsHost = data.offsets.host; - const target = data.instance.target; - const host = data.instance.host; - const adaptivePosition = computeAutoPlacement('auto', offsetsHost, target, host, data.options.allowedPositions); - const flipOrder = [placement, adaptivePosition]; - flipOrder.forEach((step, index) => { - var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r; - if (placement !== step || flipOrder.length === index + 1) { - return; - } - placement = data.placement.split(' ')[0]; - // using floor because the host offsets may contain decimals we are not going to consider here - const overlapsRef = (placement === 'left' && - Math.floor((_a = data.offsets.target.right) !== null && _a !== void 0 ? _a : 0) > Math.floor((_b = data.offsets.host.left) !== null && _b !== void 0 ? _b : 0)) || - (placement === 'right' && - Math.floor((_c = data.offsets.target.left) !== null && _c !== void 0 ? _c : 0) < Math.floor((_d = data.offsets.host.right) !== null && _d !== void 0 ? _d : 0)) || - (placement === 'top' && - Math.floor((_e = data.offsets.target.bottom) !== null && _e !== void 0 ? _e : 0) > Math.floor((_f = data.offsets.host.top) !== null && _f !== void 0 ? _f : 0)) || - (placement === 'bottom' && - Math.floor((_g = data.offsets.target.top) !== null && _g !== void 0 ? _g : 0) < Math.floor((_h = data.offsets.host.bottom) !== null && _h !== void 0 ? _h : 0)); - const overflowsLeft = Math.floor((_j = data.offsets.target.left) !== null && _j !== void 0 ? _j : 0) < Math.floor((_k = boundaries.left) !== null && _k !== void 0 ? _k : 0); - const overflowsRight = Math.floor((_l = data.offsets.target.right) !== null && _l !== void 0 ? _l : 0) > Math.floor((_m = boundaries.right) !== null && _m !== void 0 ? _m : 0); - const overflowsTop = Math.floor((_o = data.offsets.target.top) !== null && _o !== void 0 ? _o : 0) < Math.floor((_p = boundaries.top) !== null && _p !== void 0 ? _p : 0); - const overflowsBottom = Math.floor((_q = data.offsets.target.bottom) !== null && _q !== void 0 ? _q : 0) > Math.floor((_r = boundaries.bottom) !== null && _r !== void 0 ? _r : 0); - const overflowsBoundaries = (placement === 'left' && overflowsLeft) || - (placement === 'right' && overflowsRight) || - (placement === 'top' && overflowsTop) || - (placement === 'bottom' && overflowsBottom); - // flip the variation if required - const isVertical = ['top', 'bottom'].indexOf(placement) !== -1; - const flippedVariation = ((isVertical && variation === 'left' && overflowsLeft) || - (isVertical && variation === 'right' && overflowsRight) || - (!isVertical && variation === 'left' && overflowsTop) || - (!isVertical && variation === 'right' && overflowsBottom)); - if (overlapsRef || overflowsBoundaries || flippedVariation) { - if (overlapsRef || overflowsBoundaries) { - placement = flipOrder[index + 1]; - } - if (flippedVariation) { - variation = getOppositeVariation(variation); - } - data.placement = placement + (variation ? ` ${variation}` : ''); - data.offsets.target = Object.assign(Object.assign({}, data.offsets.target), getTargetOffsets(data.instance.target, data.offsets.host, data.placement)); - } - }); - return data; -} -function initData(targetElement, hostElement, position, options) { - if (!targetElement || !hostElement) { - return; - } - const hostElPosition = getReferenceOffsets(targetElement, hostElement); - if (!position.match(/^(auto)*\s*(left|right|top|bottom|start|end)*$/) - && !position.match(/^(left|right|top|bottom|start|end)*(?: (left|right|top|bottom|start|end))*$/)) { - position = 'auto'; - } - const placementAuto = !!position.match(/auto/g); - // support old placements 'auto left|right|top|bottom' - let placement = position.match(/auto\s(left|right|top|bottom|start|end)/) - ? position.split(' ')[1] || 'auto' - : position; - // Normalize placements that have identical main placement and variation ("right right" => "right"). - const matches = placement.match(/^(left|right|top|bottom|start|end)* ?(?!\1)(left|right|top|bottom|start|end)?/); - if (matches) { - placement = matches[1] + (matches[2] ? ` ${matches[2]}` : ''); - } - // "left right", "top bottom" etc. placements also considered incorrect. - if (['left right', 'right left', 'top bottom', 'bottom top'].indexOf(placement) !== -1) { - placement = 'auto'; - } - placement = computeAutoPlacement(placement, hostElPosition, targetElement, hostElement, options ? options.allowedPositions : undefined); - const targetOffset = getTargetOffsets(targetElement, hostElPosition, placement); - return { - options: options || { modifiers: {} }, - instance: { - target: targetElement, - host: hostElement, - arrow: void 0 - }, - offsets: { - target: targetOffset, - host: hostElPosition, - arrow: void 0 - }, - positionFixed: false, - placement, - placementAuto - }; -} -function preventOverflow(data) { - var _a; - if (!isModifierEnabled(data.options, 'preventOverflow')) { - return data; - } - // NOTE: DOM access here - // resets the target Offsets's position so that the document size can be calculated excluding - // the size of the targetOffsets element itself - const transformProp = 'transform'; - const targetStyles = data.instance.target.style; // assignment to help minification - const { top, left, [transformProp]: transform } = targetStyles; - targetStyles.top = ''; - targetStyles.left = ''; - targetStyles[transformProp] = ''; - const boundaries = getBoundaries(data.instance.target, data.instance.host, 0, // padding - ((_a = data.options.modifiers.preventOverflow) === null || _a === void 0 ? void 0 : _a.boundariesElement) || 'scrollParent', false // positionFixed - ); - // NOTE: DOM access here - // restores the original style properties after the offsets have been computed - targetStyles.top = top; - targetStyles.left = left; - targetStyles[transformProp] = transform; - const order = ['left', 'right', 'top', 'bottom']; - const check = { - primary(placement) { - var _a, _b, _c, _d; - let value = data.offsets.target[placement]; - // options.escapeWithReference - if (((_a = data.offsets.target[placement]) !== null && _a !== void 0 ? _a : 0) < ((_b = boundaries[placement]) !== null && _b !== void 0 ? _b : 0)) { - value = Math.max((_c = data.offsets.target[placement]) !== null && _c !== void 0 ? _c : 0, (_d = boundaries[placement]) !== null && _d !== void 0 ? _d : 0); - } - return { [placement]: value }; - }, - secondary(placement) { - var _a, _b, _c, _d, _e, _f, _g, _h; - const mainSide = placement === 'right' ? 'left' : 'top'; - let value = data.offsets.target[mainSide]; - // escapeWithReference - if (((_a = data.offsets.target[placement]) !== null && _a !== void 0 ? _a : 0) < ((_b = boundaries[placement]) !== null && _b !== void 0 ? _b : 0) && placement !== 'right') { - value = Math.min((_c = data.offsets.target[mainSide]) !== null && _c !== void 0 ? _c : 0, ((_d = boundaries[placement]) !== null && _d !== void 0 ? _d : 0) - data.offsets.target.height); - } - if (((_e = data.offsets.target[placement]) !== null && _e !== void 0 ? _e : 0) > ((_f = boundaries[placement]) !== null && _f !== void 0 ? _f : 0) && placement === 'right') { - value = Math.min((_g = data.offsets.target[mainSide]) !== null && _g !== void 0 ? _g : 0, ((_h = boundaries[placement]) !== null && _h !== void 0 ? _h : 0) - data.offsets.target.width); - } - return { [mainSide]: value }; - } - }; - order.forEach((placement) => { - const side = ['left', 'top', 'start'].indexOf(placement) !== -1 ? check['primary'] : check['secondary']; - data.offsets.target = Object.assign(Object.assign({}, data.offsets.target), side(placement)); - }); - return data; -} -function shift(data) { - var _a; - const placement = data.placement; - const basePlacement = placement.split(' ')[0]; - const shiftVariation = placement.split(' ')[1]; - if (shiftVariation) { - const { host, target } = data.offsets; - const isVertical = ['bottom', 'top'].indexOf(basePlacement) !== -1; - const side = isVertical ? 'left' : 'top'; - const measurement = isVertical ? 'width' : 'height'; - const shiftOffsets = { - start: { [side]: host[side] }, - end: { - [side]: ((_a = host[side]) !== null && _a !== void 0 ? _a : 0) + host[measurement] - target[measurement] - } - }; - data.offsets.target = Object.assign(Object.assign({}, target), { - [side]: (side === shiftVariation ? shiftOffsets.start[side] : shiftOffsets.end[side]) - }); - } - return data; -} -class Positioning { - position(hostElement, targetElement /*, round = true*/) { - return this.offset(hostElement, targetElement /*, false*/); - } - offset(hostElement, targetElement /*, round = true*/) { - return getReferenceOffsets(targetElement, hostElement); - } - positionElements(hostElement, targetElement, position, appendToBody, options) { - const chainOfModifiers = [flip, shift, preventOverflow, arrow]; - const _position = MapPlacementInToRL[position]; - const data = initData(targetElement, hostElement, _position, options); - if (!data) { - return; - } - return chainOfModifiers.reduce((modifiedData, modifier) => modifier(modifiedData), data); - } -} -const positionService = new Positioning(); -function positionElements(hostElement, targetElement, placement, appendToBody, options, renderer) { - const data = positionService.positionElements(hostElement, targetElement, placement, appendToBody, options); - if (!data) { - return; - } - const offsets = getOffsets(data); - setStyles(targetElement, { - 'will-change': 'transform', - top: '0px', - left: '0px', - transform: `translate3d(${offsets.left}px, ${offsets.top}px, 0px)` - }, renderer); - if (data.instance.arrow) { - setStyles(data.instance.arrow, data.offsets.arrow, renderer); - } - updateContainerClass(data, renderer); -} -let PositioningService = /*@__PURE__*/ (() => { - class PositioningService { - constructor(ngZone, rendererFactory, platformId) { - this.update$$ = new rxjs__WEBPACK_IMPORTED_MODULE_3__["Subject"](); - this.positionElements = new Map(); - this.isDisabled = false; - if (Object(_angular_common__WEBPACK_IMPORTED_MODULE_2__["isPlatformBrowser"])(platformId)) { - ngZone.runOutsideAngular(() => { - this.triggerEvent$ = Object(rxjs__WEBPACK_IMPORTED_MODULE_3__["merge"])(Object(rxjs__WEBPACK_IMPORTED_MODULE_3__["fromEvent"])(window, 'scroll', { passive: true }), Object(rxjs__WEBPACK_IMPORTED_MODULE_3__["fromEvent"])(window, 'resize', { passive: true }), Object(rxjs__WEBPACK_IMPORTED_MODULE_3__["of"])(0, rxjs__WEBPACK_IMPORTED_MODULE_3__["animationFrameScheduler"]), this.update$$); - this.triggerEvent$.subscribe(() => { - if (this.isDisabled) { - return; - } - this.positionElements - // eslint-disable-next-line @typescript-eslint/no-explicit-any - .forEach((positionElement) => { - positionElements(_getHtmlElement(positionElement.target), _getHtmlElement(positionElement.element), positionElement.attachment, positionElement.appendToBody, this.options, rendererFactory.createRenderer(null, null)); - }); - }); - }); - } - } - position(options) { - this.addPositionElement(options); - } - get event$() { - return this.triggerEvent$; - } - disable() { - this.isDisabled = true; - } - enable() { - this.isDisabled = false; - } - addPositionElement(options) { - this.positionElements.set(_getHtmlElement(options.element), options); - } - calcPosition() { - this.update$$.next(); - } - deletePositionElement(elRef) { - this.positionElements.delete(_getHtmlElement(elRef)); - } - setOptions(options) { - this.options = options; - } - } - PositioningService.ɵfac = function PositioningService_Factory(t) { return new (t || PositioningService)(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["RendererFactory2"]), _angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_1__["PLATFORM_ID"])); }; - PositioningService.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵdefineInjectable"])({ factory: function PositioningService_Factory() { return new PositioningService(Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["NgZone"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["RendererFactory2"]), Object(_angular_core__WEBPACK_IMPORTED_MODULE_1__["ɵɵinject"])(_angular_core__WEBPACK_IMPORTED_MODULE_1__["PLATFORM_ID"])); }, token: PositioningService, providedIn: "root" }); - return PositioningService; -})(); -function _getHtmlElement(element) { - // it means that we got a selector - if (typeof element === 'string') { - return document.querySelector(element); - } - if (element instanceof _angular_core__WEBPACK_IMPORTED_MODULE_1__["ElementRef"]) { - return element.nativeElement; - } - return element !== null && element !== void 0 ? element : null; -} -/** - * Generated bundle index. Do not edit. - */ - -//# sourceMappingURL=ngx-bootstrap-positioning.js.map - - -/***/ }), - -/***/ "XDbj": -/*!***********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js ***! - \***********************************************************************/ -/*! exports provided: throwIfEmpty */ -/***/ (function(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 */ "sVev"); -/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Subscriber */ "7o/Q"); - - -function throwIfEmpty(errorFactory = defaultErrorFactory) { - return (source) => { - return source.lift(new ThrowIfEmptyOperator(errorFactory)); - }; -} -class ThrowIfEmptyOperator { - constructor(errorFactory) { - this.errorFactory = errorFactory; - } - call(subscriber, source) { - return source.subscribe(new ThrowIfEmptySubscriber(subscriber, this.errorFactory)); - } -} -class ThrowIfEmptySubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_1__["Subscriber"] { - constructor(destination, errorFactory) { - super(destination); - this.errorFactory = errorFactory; - this.hasValue = false; - } - _next(value) { - this.hasValue = true; - this.destination.next(value); - } - _complete() { - if (!this.hasValue) { - let err; - try { - err = this.errorFactory(); - } - catch (e) { - err = e; - } - this.destination.error(err); - } - else { - return this.destination.complete(); - } - } -} -function defaultErrorFactory() { - return new _util_EmptyError__WEBPACK_IMPORTED_MODULE_0__["EmptyError"](); -} -//# sourceMappingURL=throwIfEmpty.js.map - - -/***/ }), - -/***/ "XNiG": -/*!********************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/Subject.js ***! - \********************************************************/ -/*! exports provided: SubjectSubscriber, Subject, AnonymousSubject */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _Subscriber__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Subscriber */ "7o/Q"); -/* harmony import */ var _Subscription__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Subscription */ "quSY"); -/* harmony import */ var _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./util/ObjectUnsubscribedError */ "9ppp"); -/* harmony import */ var _SubjectSubscription__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./SubjectSubscription */ "Ylt2"); -/* harmony import */ var _internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../internal/symbol/rxSubscriber */ "2QA8"); - - - - - - -class SubjectSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_1__["Subscriber"] { - constructor(destination) { - super(destination); - this.destination = destination; - } -} -let Subject = /*@__PURE__*/ (() => { - class Subject extends _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"] { - constructor() { - super(); - this.observers = []; - this.closed = false; - this.isStopped = false; - this.hasError = false; - this.thrownError = null; - } - [_internal_symbol_rxSubscriber__WEBPACK_IMPORTED_MODULE_5__["rxSubscriber"]]() { - return new SubjectSubscriber(this); - } - lift(operator) { - const subject = new AnonymousSubject(this, this); - subject.operator = operator; - return subject; - } - next(value) { - if (this.closed) { - throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"](); - } - if (!this.isStopped) { - const { observers } = this; - const len = observers.length; - const copy = observers.slice(); - for (let i = 0; i < len; i++) { - copy[i].next(value); - } - } - } - error(err) { - if (this.closed) { - throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"](); - } - this.hasError = true; - this.thrownError = err; - this.isStopped = true; - const { observers } = this; - const len = observers.length; - const copy = observers.slice(); - for (let i = 0; i < len; i++) { - copy[i].error(err); - } - this.observers.length = 0; - } - complete() { - if (this.closed) { - throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"](); - } - this.isStopped = true; - const { observers } = this; - const len = observers.length; - const copy = observers.slice(); - for (let i = 0; i < len; i++) { - copy[i].complete(); - } - this.observers.length = 0; - } - unsubscribe() { - this.isStopped = true; - this.closed = true; - this.observers = null; - } - _trySubscribe(subscriber) { - if (this.closed) { - throw new _util_ObjectUnsubscribedError__WEBPACK_IMPORTED_MODULE_3__["ObjectUnsubscribedError"](); - } - else { - return super._trySubscribe(subscriber); - } - } - _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); - } - } - asObservable() { - const observable = new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](); - observable.source = this; - return observable; - } - } - Subject.create = (destination, source) => { - return new AnonymousSubject(destination, source); - }; - return Subject; -})(); -class AnonymousSubject extends Subject { - constructor(destination, source) { - super(); - this.destination = destination; - this.source = source; - } - next(value) { - const { destination } = this; - if (destination && destination.next) { - destination.next(value); - } - } - error(err) { - const { destination } = this; - if (destination && destination.error) { - this.destination.error(err); - } - } - complete() { - const { destination } = this; - if (destination && destination.complete) { - this.destination.complete(); - } - } - _subscribe(subscriber) { - const { source } = this; - if (source) { - return this.source.subscribe(subscriber); - } - else { - return _Subscription__WEBPACK_IMPORTED_MODULE_2__["Subscription"].EMPTY; - } - } -} -//# sourceMappingURL=Subject.js.map - - -/***/ }), - -/***/ "XoHu": -/*!**************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isObject.js ***! - \**************************************************************/ -/*! exports provided: isObject */ -/***/ (function(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 - - -/***/ }), - -/***/ "XqQ8": -/*!*********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/exhaustMap.js ***! - \*********************************************************************/ -/*! exports provided: exhaustMap */ -/***/ (function(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 _map__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./map */ "lJxs"); -/* harmony import */ var _observable_from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../observable/from */ "Cfvw"); -/* harmony import */ var _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - - - -function exhaustMap(project, resultSelector) { - if (resultSelector) { - return (source) => source.pipe(exhaustMap((a, i) => Object(_observable_from__WEBPACK_IMPORTED_MODULE_1__["from"])(project(a, i)).pipe(Object(_map__WEBPACK_IMPORTED_MODULE_0__["map"])((b, ii) => resultSelector(a, b, i, ii))))); - } - return (source) => source.lift(new ExhaustMapOperator(project)); -} -class ExhaustMapOperator { - constructor(project) { - this.project = project; - } - call(subscriber, source) { - return source.subscribe(new ExhaustMapSubscriber(subscriber, this.project)); - } -} -class ExhaustMapSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["SimpleOuterSubscriber"] { - constructor(destination, project) { - super(destination); - this.project = project; - this.hasSubscription = false; - this.hasCompleted = false; - this.index = 0; - } - _next(value) { - if (!this.hasSubscription) { - this.tryNext(value); - } - } - tryNext(value) { - let result; - const index = this.index++; - try { - result = this.project(value, index); - } - catch (err) { - this.destination.error(err); - return; - } - this.hasSubscription = true; - this._innerSub(result); - } - _innerSub(result) { - const innerSubscriber = new _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["SimpleInnerSubscriber"](this); - const destination = this.destination; - destination.add(innerSubscriber); - const innerSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["innerSubscribe"])(result, innerSubscriber); - if (innerSubscription !== innerSubscriber) { - destination.add(innerSubscription); - } - } - _complete() { - this.hasCompleted = true; - if (!this.hasSubscription) { - this.destination.complete(); - } - this.unsubscribe(); - } - notifyNext(innerValue) { - this.destination.next(innerValue); - } - notifyError(err) { - this.destination.error(err); - } - notifyComplete() { - this.hasSubscription = false; - if (this.hasCompleted) { - this.destination.complete(); - } - } -} -//# sourceMappingURL=exhaustMap.js.map - - -/***/ }), - -/***/ "Y/cZ": -/*!**********************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/Scheduler.js ***! - \**********************************************************/ -/*! exports provided: Scheduler */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "Scheduler", function() { return Scheduler; }); -let Scheduler = /*@__PURE__*/ (() => { - class Scheduler { - constructor(SchedulerAction, now = Scheduler.now) { - this.SchedulerAction = SchedulerAction; - this.now = now; - } - schedule(work, delay = 0, state) { - return new this.SchedulerAction(this, work).schedule(state, delay); - } - } - Scheduler.now = () => Date.now(); - return Scheduler; -})(); -//# sourceMappingURL=Scheduler.js.map - - -/***/ }), - -/***/ "Y6u4": -/*!******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/TimeoutError.js ***! - \******************************************************************/ -/*! exports provided: TimeoutError */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "TimeoutError", function() { return TimeoutError; }); -const TimeoutErrorImpl = /*@__PURE__*/ (() => { - function TimeoutErrorImpl() { - Error.call(this); - this.message = 'Timeout has occurred'; - this.name = 'TimeoutError'; - return this; - } - TimeoutErrorImpl.prototype = Object.create(Error.prototype); - return TimeoutErrorImpl; -})(); -const TimeoutError = TimeoutErrorImpl; -//# sourceMappingURL=TimeoutError.js.map - - -/***/ }), - -/***/ "Y6wi": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/switchAll.js ***! - \********************************************************************/ -/*! exports provided: switchAll */ -/***/ (function(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 */ "eIep"); -/* harmony import */ var _util_identity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/identity */ "SpAZ"); - - -function switchAll() { - return Object(_switchMap__WEBPACK_IMPORTED_MODULE_0__["switchMap"])(_util_identity__WEBPACK_IMPORTED_MODULE_1__["identity"]); -} -//# sourceMappingURL=switchAll.js.map - - -/***/ }), - -/***/ "Y7HM": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isNumeric.js ***! - \***************************************************************/ -/*! exports provided: isNumeric */ -/***/ (function(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 */ "DH7j"); - -function isNumeric(val) { - return !Object(_isArray__WEBPACK_IMPORTED_MODULE_0__["isArray"])(val) && (val - parseFloat(val) + 1) >= 0; -} -//# sourceMappingURL=isNumeric.js.map - - -/***/ }), - -/***/ "YEEh": -/*!***************************************!*\ - !*** ./src/app/_pipes/filter.pipe.ts ***! - \***************************************/ -/*! exports provided: FilterPipe */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "FilterPipe", function() { return FilterPipe; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "fXoL"); - -let FilterPipe = /*@__PURE__*/ (() => { - class FilterPipe { - transform(items, term) { - return items.filter((item) => { - return (item.name - .toLowerCase() - .replace(/ /g, '') - .includes(term.toLowerCase().replace(/ /g, '')) || - item.tags.join(', ').toLowerCase().includes(term.toLowerCase())); - }); - } - } - FilterPipe.ɵfac = function FilterPipe_Factory(t) { return new (t || FilterPipe)(); }; - FilterPipe.ɵpipe = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefinePipe"]({ name: "filter", type: FilterPipe, pure: true }); - return FilterPipe; -})(); - - -/***/ }), - -/***/ "Ylt2": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/SubjectSubscription.js ***! - \********************************************************************/ -/*! exports provided: SubjectSubscription */ -/***/ (function(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 */ "quSY"); - -class SubjectSubscription extends _Subscription__WEBPACK_IMPORTED_MODULE_0__["Subscription"] { - constructor(subject, subscriber) { - super(); - this.subject = subject; - this.subscriber = subscriber; - this.closed = false; - } - unsubscribe() { - if (this.closed) { - return; - } - this.closed = true; - const subject = this.subject; - const observers = subject.observers; - this.subject = null; - if (!observers || observers.length === 0 || subject.isStopped || subject.closed) { - return; - } - const subscriberIndex = observers.indexOf(this.subscriber); - if (subscriberIndex !== -1) { - observers.splice(subscriberIndex, 1); - } - } -} -//# sourceMappingURL=SubjectSubscription.js.map - - -/***/ }), - -/***/ "YuR2": -/*!**********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/QueueAction.js ***! - \**********************************************************************/ -/*! exports provided: QueueAction */ -/***/ (function(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 */ "3N8a"); - -class QueueAction extends _AsyncAction__WEBPACK_IMPORTED_MODULE_0__["AsyncAction"] { - constructor(scheduler, work) { - super(scheduler, work); - this.scheduler = scheduler; - this.work = work; - } - schedule(state, delay = 0) { - if (delay > 0) { - return super.schedule(state, delay); - } - this.delay = delay; - this.state = state; - this.scheduler.flush(this); - return this; - } - execute(state, delay) { - return (delay > 0 || this.closed) ? - super.execute(state, delay) : - this._execute(state, delay); - } - requestAsyncId(scheduler, id, delay = 0) { - if ((delay !== null && delay > 0) || (delay === null && this.delay > 0)) { - return super.requestAsyncId(scheduler, id, delay); - } - return scheduler.flush(this); - } -} -//# sourceMappingURL=QueueAction.js.map - - -/***/ }), - -/***/ "ZAI4": -/*!*******************************!*\ - !*** ./src/app/app.module.ts ***! - \*******************************/ -/*! exports provided: AppModule */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AppModule", function() { return AppModule; }); -/* harmony import */ var _angular_elements__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/elements */ "Dti6"); -/* harmony import */ var _angular_forms__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @angular/forms */ "3Pt+"); -/* harmony import */ var _angular_platform_browser__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @angular/platform-browser */ "jhN1"); -/* harmony import */ var _search_search_component__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./search/search.component */ "tq2C"); -/* harmony import */ var _set_set_component__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./set/set.component */ "GwmF"); -/* harmony import */ var _svgcss_svgcss_component__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./svgcss/svgcss.component */ "Dwot"); -/* harmony import */ var _pipes_filter_pipe__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./_pipes/filter.pipe */ "YEEh"); -/* harmony import */ var ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ngx-bootstrap/dropdown */ "dZIy"); -/* harmony import */ var _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! @angular/platform-browser/animations */ "R1ws"); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! @angular/core */ "fXoL"); - - - - - - - - - - - -let AppModule = /*@__PURE__*/ (() => { - class AppModule { - constructor(injector) { - this.injector = injector; - const searchElement = Object(_angular_elements__WEBPACK_IMPORTED_MODULE_0__["createCustomElement"])(_search_search_component__WEBPACK_IMPORTED_MODULE_3__["SearchComponent"], { - injector: this.injector, - }); - customElements.define('site-search', searchElement); - const setElement = Object(_angular_elements__WEBPACK_IMPORTED_MODULE_0__["createCustomElement"])(_set_set_component__WEBPACK_IMPORTED_MODULE_4__["SetComponent"], { - injector: this.injector, - }); - customElements.define('icon-set-list', setElement); - const svgcssElement = Object(_angular_elements__WEBPACK_IMPORTED_MODULE_0__["createCustomElement"])(_svgcss_svgcss_component__WEBPACK_IMPORTED_MODULE_5__["SvgcssComponent"], { - injector: this.injector, - }); - customElements.define('svg-css', svgcssElement); - } - ngDoBootstrap() { } - } - AppModule.ɵfac = function AppModule_Factory(t) { return new (t || AppModule)(_angular_core__WEBPACK_IMPORTED_MODULE_9__["ɵɵinject"](_angular_core__WEBPACK_IMPORTED_MODULE_9__["Injector"])); }; - AppModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_9__["ɵɵdefineNgModule"]({ type: AppModule }); - AppModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_9__["ɵɵdefineInjector"]({ providers: [ - // { provide: OverlayContainer, useClass: CdkOverlayContainer } - ], imports: [[ - _angular_platform_browser__WEBPACK_IMPORTED_MODULE_2__["BrowserModule"], - _angular_forms__WEBPACK_IMPORTED_MODULE_1__["FormsModule"], - ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_7__["BsDropdownModule"].forRoot(), - _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_8__["BrowserAnimationsModule"], - ]] }); - return AppModule; -})(); -(function () { - (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_9__["ɵɵsetNgModuleScope"](AppModule, { declarations: [_search_search_component__WEBPACK_IMPORTED_MODULE_3__["SearchComponent"], _set_set_component__WEBPACK_IMPORTED_MODULE_4__["SetComponent"], _pipes_filter_pipe__WEBPACK_IMPORTED_MODULE_6__["FilterPipe"], _svgcss_svgcss_component__WEBPACK_IMPORTED_MODULE_5__["SvgcssComponent"]], imports: [_angular_platform_browser__WEBPACK_IMPORTED_MODULE_2__["BrowserModule"], - _angular_forms__WEBPACK_IMPORTED_MODULE_1__["FormsModule"], ngx_bootstrap_dropdown__WEBPACK_IMPORTED_MODULE_7__["BsDropdownModule"], _angular_platform_browser_animations__WEBPACK_IMPORTED_MODULE_8__["BrowserAnimationsModule"]] }); -})(); - - -/***/ }), - -/***/ "ZUHj": -/*!***********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js ***! - \***********************************************************************/ -/*! exports provided: subscribeToResult */ -/***/ (function(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 */ "51Dv"); -/* harmony import */ var _subscribeTo__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./subscribeTo */ "SeVD"); -/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Observable */ "HDdC"); - - - -function subscribeToResult(outerSubscriber, result, outerValue, outerIndex, innerSubscriber = 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 - - -/***/ }), - -/***/ "Zy1z": -/*!*******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/pairwise.js ***! - \*******************************************************************/ -/*! exports provided: pairwise */ -/***/ (function(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 */ "7o/Q"); - -function pairwise() { - return (source) => source.lift(new PairwiseOperator()); -} -class PairwiseOperator { - call(subscriber, source) { - return source.subscribe(new PairwiseSubscriber(subscriber)); - } -} -class PairwiseSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination) { - super(destination); - this.hasPrev = false; - } - _next(value) { - let pair; - if (this.hasPrev) { - pair = [this.prev, value]; - } - else { - this.hasPrev = true; - } - this.prev = value; - if (pair) { - this.destination.next(pair); - } - } -} -//# sourceMappingURL=pairwise.js.map - - -/***/ }), - -/***/ "Zyez": -/*!************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/sequenceEqual.js ***! - \************************************************************************/ -/*! exports provided: sequenceEqual, SequenceEqualOperator, SequenceEqualSubscriber */ -/***/ (function(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 */ "7o/Q"); - -function sequenceEqual(compareTo, comparator) { - return (source) => source.lift(new SequenceEqualOperator(compareTo, comparator)); -} -class SequenceEqualOperator { - constructor(compareTo, comparator) { - this.compareTo = compareTo; - this.comparator = comparator; - } - call(subscriber, source) { - return source.subscribe(new SequenceEqualSubscriber(subscriber, this.compareTo, this.comparator)); - } -} -class SequenceEqualSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, compareTo, comparator) { - super(destination); - this.compareTo = compareTo; - this.comparator = comparator; - this._a = []; - this._b = []; - this._oneComplete = false; - this.destination.add(compareTo.subscribe(new SequenceEqualCompareToSubscriber(destination, this))); - } - _next(value) { - if (this._oneComplete && this._b.length === 0) { - this.emit(false); - } - else { - this._a.push(value); - this.checkValues(); - } - } - _complete() { - if (this._oneComplete) { - this.emit(this._a.length === 0 && this._b.length === 0); - } - else { - this._oneComplete = true; - } - this.unsubscribe(); - } - checkValues() { - const { _a, _b, comparator } = this; - while (_a.length > 0 && _b.length > 0) { - let a = _a.shift(); - let b = _b.shift(); - let areEqual = false; - try { - areEqual = comparator ? comparator(a, b) : a === b; - } - catch (e) { - this.destination.error(e); - } - if (!areEqual) { - this.emit(false); - } - } - } - emit(value) { - const { destination } = this; - destination.next(value); - destination.complete(); - } - nextB(value) { - if (this._oneComplete && this._a.length === 0) { - this.emit(false); - } - else { - this._b.push(value); - this.checkValues(); - } - } - completeB() { - if (this._oneComplete) { - this.emit(this._a.length === 0 && this._b.length === 0); - } - else { - this._oneComplete = true; - } - } -} -class SequenceEqualCompareToSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, parent) { - super(destination); - this.parent = parent; - } - _next(value) { - this.parent.nextB(value); - } - _error(err) { - this.parent.error(err); - this.unsubscribe(); - } - _complete() { - this.parent.completeB(); - this.unsubscribe(); - } -} -//# sourceMappingURL=sequenceEqual.js.map - - -/***/ }), - -/***/ "a7t3": -/*!************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/subscribeToPromise.js ***! - \************************************************************************/ -/*! exports provided: subscribeToPromise */ -/***/ (function(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 */ "NJ4a"); - -const subscribeToPromise = (promise) => (subscriber) => { - promise.then((value) => { - if (!subscriber.closed) { - subscriber.next(value); - subscriber.complete(); - } - }, (err) => subscriber.error(err)) - .then(null, _hostReportError__WEBPACK_IMPORTED_MODULE_0__["hostReportError"]); - return subscriber; -}; -//# sourceMappingURL=subscribeToPromise.js.map - - -/***/ }), - -/***/ "aGrj": -/*!**********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/switchMapTo.js ***! - \**********************************************************************/ -/*! exports provided: switchMapTo */ -/***/ (function(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 */ "eIep"); - -function switchMapTo(innerObservable, resultSelector) { - return resultSelector ? Object(_switchMap__WEBPACK_IMPORTED_MODULE_0__["switchMap"])(() => innerObservable, resultSelector) : Object(_switchMap__WEBPACK_IMPORTED_MODULE_0__["switchMap"])(() => innerObservable); -} -//# sourceMappingURL=switchMapTo.js.map - - -/***/ }), - -/***/ "bHdf": -/*!*******************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/mergeAll.js ***! - \*******************************************************************/ -/*! exports provided: mergeAll */ -/***/ (function(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 */ "5+tZ"); -/* harmony import */ var _util_identity__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/identity */ "SpAZ"); - - -function mergeAll(concurrent = Number.POSITIVE_INFINITY) { - return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(_util_identity__WEBPACK_IMPORTED_MODULE_1__["identity"], concurrent); -} -//# sourceMappingURL=mergeAll.js.map - - -/***/ }), - -/***/ "bOdf": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/concatMap.js ***! - \********************************************************************/ -/*! exports provided: concatMap */ -/***/ (function(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 */ "5+tZ"); - -function concatMap(project, resultSelector) { - return Object(_mergeMap__WEBPACK_IMPORTED_MODULE_0__["mergeMap"])(project, resultSelector, 1); -} -//# sourceMappingURL=concatMap.js.map - - -/***/ }), - -/***/ "c2HN": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/isPromise.js ***! - \***************************************************************/ -/*! exports provided: isPromise */ -/***/ (function(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 - - -/***/ }), - -/***/ "c6ID": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/sample.js ***! - \*****************************************************************/ -/*! exports provided: sample */ -/***/ (function(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 _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - -function sample(notifier) { - return (source) => source.lift(new SampleOperator(notifier)); -} -class SampleOperator { - constructor(notifier) { - this.notifier = notifier; - } - call(subscriber, source) { - const sampleSubscriber = new SampleSubscriber(subscriber); - const subscription = source.subscribe(sampleSubscriber); - subscription.add(Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["innerSubscribe"])(this.notifier, new _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleInnerSubscriber"](sampleSubscriber))); - return subscription; - } -} -class SampleSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_0__["SimpleOuterSubscriber"] { - constructor() { - super(...arguments); - this.hasValue = false; - } - _next(value) { - this.value = value; - this.hasValue = true; - } - notifyNext() { - this.emitValue(); - } - notifyComplete() { - this.emitValue(); - } - emitValue() { - if (this.hasValue) { - this.hasValue = false; - this.destination.next(this.value); - } - } -} -//# sourceMappingURL=sample.js.map - - -/***/ }), - -/***/ "c7jc": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/util/Immediate.js ***! - \***************************************************************/ -/*! exports provided: Immediate, TestTools */ -/***/ (function(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; }); -let nextHandle = 1; -const RESOLVED = /*@__PURE__*/ (() => Promise.resolve())(); -const activeHandles = {}; -function findAndClearHandle(handle) { - if (handle in activeHandles) { - delete activeHandles[handle]; - return true; - } - return false; -} -const Immediate = { - setImmediate(cb) { - const handle = nextHandle++; - activeHandles[handle] = true; - RESOLVED.then(() => findAndClearHandle(handle) && cb()); - return handle; - }, - clearImmediate(handle) { - findAndClearHandle(handle); - }, -}; -const TestTools = { - pending() { - return Object.keys(activeHandles).length; - } -}; -//# sourceMappingURL=Immediate.js.map - - -/***/ }), - -/***/ "cBqT": -/*!***************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/find.js ***! - \***************************************************************/ -/*! exports provided: find, FindValueOperator, FindValueSubscriber */ -/***/ (function(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 */ "7o/Q"); - -function find(predicate, thisArg) { - if (typeof predicate !== 'function') { - throw new TypeError('predicate is not a function'); - } - return (source) => source.lift(new FindValueOperator(predicate, source, false, thisArg)); -} -class FindValueOperator { - constructor(predicate, source, yieldIndex, thisArg) { - this.predicate = predicate; - this.source = source; - this.yieldIndex = yieldIndex; - this.thisArg = thisArg; - } - call(observer, source) { - return source.subscribe(new FindValueSubscriber(observer, this.predicate, this.source, this.yieldIndex, this.thisArg)); - } -} -class FindValueSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, predicate, source, yieldIndex, thisArg) { - super(destination); - this.predicate = predicate; - this.source = source; - this.yieldIndex = yieldIndex; - this.thisArg = thisArg; - this.index = 0; - } - notifyComplete(value) { - const destination = this.destination; - destination.next(value); - destination.complete(); - this.unsubscribe(); - } - _next(value) { - const { predicate, thisArg } = this; - const index = this.index++; - try { - const result = predicate.call(thisArg || this, value, index, this.source); - if (result) { - this.notifyComplete(this.yieldIndex ? index : value); - } - } - catch (err) { - this.destination.error(err); - } - } - _complete() { - this.notifyComplete(this.yieldIndex ? -1 : undefined); - } -} -//# sourceMappingURL=find.js.map - - -/***/ }), - -/***/ "coGc": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/delayWhen.js ***! - \********************************************************************/ -/*! exports provided: delayWhen */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _Observable__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Observable */ "HDdC"); -/* harmony import */ var _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../OuterSubscriber */ "l7GE"); -/* harmony import */ var _util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/subscribeToResult */ "ZUHj"); - - - - -function delayWhen(delayDurationSelector, subscriptionDelay) { - if (subscriptionDelay) { - return (source) => new SubscriptionDelayObservable(source, subscriptionDelay) - .lift(new DelayWhenOperator(delayDurationSelector)); - } - return (source) => source.lift(new DelayWhenOperator(delayDurationSelector)); -} -class DelayWhenOperator { - constructor(delayDurationSelector) { - this.delayDurationSelector = delayDurationSelector; - } - call(subscriber, source) { - return source.subscribe(new DelayWhenSubscriber(subscriber, this.delayDurationSelector)); - } -} -class DelayWhenSubscriber extends _OuterSubscriber__WEBPACK_IMPORTED_MODULE_2__["OuterSubscriber"] { - constructor(destination, delayDurationSelector) { - super(destination); - this.delayDurationSelector = delayDurationSelector; - this.completed = false; - this.delayNotifierSubscriptions = []; - this.index = 0; - } - notifyNext(outerValue, _innerValue, _outerIndex, _innerIndex, innerSub) { - this.destination.next(outerValue); - this.removeSubscription(innerSub); - this.tryComplete(); - } - notifyError(error, innerSub) { - this._error(error); - } - notifyComplete(innerSub) { - const value = this.removeSubscription(innerSub); - if (value) { - this.destination.next(value); - } - this.tryComplete(); - } - _next(value) { - const index = this.index++; - try { - const delayNotifier = this.delayDurationSelector(value, index); - if (delayNotifier) { - this.tryDelay(delayNotifier, value); - } - } - catch (err) { - this.destination.error(err); - } - } - _complete() { - this.completed = true; - this.tryComplete(); - this.unsubscribe(); - } - removeSubscription(subscription) { - subscription.unsubscribe(); - const subscriptionIdx = this.delayNotifierSubscriptions.indexOf(subscription); - if (subscriptionIdx !== -1) { - this.delayNotifierSubscriptions.splice(subscriptionIdx, 1); - } - return subscription.outerValue; - } - tryDelay(delayNotifier, value) { - const notifierSubscription = Object(_util_subscribeToResult__WEBPACK_IMPORTED_MODULE_3__["subscribeToResult"])(this, delayNotifier, value); - if (notifierSubscription && !notifierSubscription.closed) { - const destination = this.destination; - destination.add(notifierSubscription); - this.delayNotifierSubscriptions.push(notifierSubscription); - } - } - tryComplete() { - if (this.completed && this.delayNotifierSubscriptions.length === 0) { - this.destination.complete(); - } - } -} -class SubscriptionDelayObservable extends _Observable__WEBPACK_IMPORTED_MODULE_1__["Observable"] { - constructor(source, subscriptionDelay) { - super(); - this.source = source; - this.subscriptionDelay = subscriptionDelay; - } - _subscribe(subscriber) { - this.subscriptionDelay.subscribe(new SubscriptionDelaySubscriber(subscriber, this.source)); - } -} -class SubscriptionDelaySubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(parent, source) { - super(); - this.parent = parent; - this.source = source; - this.sourceSubscribed = false; - } - _next(unused) { - this.subscribeToSource(); - } - _error(err) { - this.unsubscribe(); - this.parent.error(err); - } - _complete() { - this.unsubscribe(); - this.subscribeToSource(); - } - subscribeToSource() { - if (!this.sourceSubscribed) { - this.sourceSubscribed = true; - this.unsubscribe(); - this.source.subscribe(this.parent); - } - } -} -//# sourceMappingURL=delayWhen.js.map - - -/***/ }), - -/***/ "cp0P": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/observable/forkJoin.js ***! - \********************************************************************/ -/*! exports provided: forkJoin */ -/***/ (function(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 */ "HDdC"); -/* harmony import */ var _util_isArray__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/isArray */ "DH7j"); -/* harmony import */ var _operators_map__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../operators/map */ "lJxs"); -/* harmony import */ var _util_isObject__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../util/isObject */ "XoHu"); -/* harmony import */ var _from__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./from */ "Cfvw"); - - - - - -function forkJoin(...sources) { - if (sources.length === 1) { - const 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) { - const keys = Object.keys(first); - return forkJoinInternal(keys.map(key => first[key]), keys); - } - } - if (typeof sources[sources.length - 1] === 'function') { - const 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"])((args) => resultSelector(...args))); - } - return forkJoinInternal(sources, null); -} -function forkJoinInternal(sources, keys) { - return new _Observable__WEBPACK_IMPORTED_MODULE_0__["Observable"](subscriber => { - const len = sources.length; - if (len === 0) { - subscriber.complete(); - return; - } - const values = new Array(len); - let completed = 0; - let emitted = 0; - for (let i = 0; i < len; i++) { - const source = Object(_from__WEBPACK_IMPORTED_MODULE_4__["from"])(sources[i]); - let hasValue = false; - subscriber.add(source.subscribe({ - next: value => { - if (!hasValue) { - hasValue = true; - emitted++; - } - values[i] = value; - }, - error: err => subscriber.error(err), - complete: () => { - completed++; - if (completed === len || !hasValue) { - if (emitted === len) { - subscriber.next(keys ? - keys.reduce((result, key, i) => (result[key] = values[i], result), {}) : - values); - } - subscriber.complete(); - } - } - })); - } - }); -} -//# sourceMappingURL=forkJoin.js.map - - -/***/ }), - -/***/ "cx9U": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/single.js ***! - \*****************************************************************/ -/*! exports provided: single */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _util_EmptyError__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../util/EmptyError */ "sVev"); - - -function single(predicate) { - return (source) => source.lift(new SingleOperator(predicate, source)); -} -class SingleOperator { - constructor(predicate, source) { - this.predicate = predicate; - this.source = source; - } - call(subscriber, source) { - return source.subscribe(new SingleSubscriber(subscriber, this.predicate, this.source)); - } -} -class SingleSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination, predicate, source) { - super(destination); - this.predicate = predicate; - this.source = source; - this.seenValue = false; - this.index = 0; - } - applySingleValue(value) { - if (this.seenValue) { - this.destination.error('Sequence contains more than one element'); - } - else { - this.seenValue = true; - this.singleValue = value; - } - } - _next(value) { - const index = this.index++; - if (this.predicate) { - this.tryNext(value, index); - } - else { - this.applySingleValue(value); - } - } - tryNext(value, index) { - try { - if (this.predicate(value, index, this.source)) { - this.applySingleValue(value); - } - } - catch (err) { - this.destination.error(err); - } - } - _complete() { - const 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"]); - } - } -} -//# sourceMappingURL=single.js.map - - -/***/ }), - -/***/ "dZIy": -/*!*********************************************************************************************!*\ - !*** ./node_modules/ngx-bootstrap/__ivy_ngcc__/dropdown/fesm2015/ngx-bootstrap-dropdown.js ***! - \*********************************************************************************************/ -/*! exports provided: BsDropdownConfig, BsDropdownContainerComponent, BsDropdownDirective, BsDropdownMenuDirective, BsDropdownModule, BsDropdownState, BsDropdownToggleDirective */ -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -__webpack_require__.r(__webpack_exports__); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsDropdownConfig", function() { return BsDropdownConfig; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsDropdownContainerComponent", function() { return BsDropdownContainerComponent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsDropdownDirective", function() { return BsDropdownDirective; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsDropdownMenuDirective", function() { return BsDropdownMenuDirective; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsDropdownModule", function() { return BsDropdownModule; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsDropdownState", function() { return BsDropdownState; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "BsDropdownToggleDirective", function() { return BsDropdownToggleDirective; }); -/* harmony import */ var _angular_core__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @angular/core */ "fXoL"); -/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! rxjs/operators */ "kU1M"); -/* harmony import */ var ngx_bootstrap_component_loader__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ngx-bootstrap/component-loader */ "3XJ7"); -/* harmony import */ var ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ngx-bootstrap/utils */ "lUod"); -/* harmony import */ var _angular_animations__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @angular/animations */ "R0Ic"); -/* harmony import */ var _angular_common__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @angular/common */ "ofXK"); -/* harmony import */ var ngx_bootstrap_positioning__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ngx-bootstrap/positioning */ "WyaX"); - - - - - - - -/** Default dropdown configuration */ - - - - -const _c0 = function (a0) { return { dropdown: a0 }; }; -const _c1 = ["*"]; -let BsDropdownConfig = /*@__PURE__*/ (() => { - class BsDropdownConfig { - constructor() { - /** default dropdown auto closing behavior */ - this.autoClose = true; - /** default dropdown auto closing behavior */ - this.insideClick = false; - /** turn on/off animation */ - this.isAnimated = false; - /** value true of stopOnClickPropagation allows event stopPropagation*/ - this.stopOnClickPropagation = false; - } - } - BsDropdownConfig.ɵfac = function BsDropdownConfig_Factory(t) { return new (t || BsDropdownConfig)(); }; - BsDropdownConfig.ɵprov = Object(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"])({ factory: function BsDropdownConfig_Factory() { return new BsDropdownConfig(); }, token: BsDropdownConfig, providedIn: "root" }); - return BsDropdownConfig; -})(); -let BsDropdownState = /*@__PURE__*/ (() => { - class BsDropdownState { - constructor() { - this.direction = 'down'; - this.autoClose = true; - this.insideClick = false; - this.isAnimated = false; - this.stopOnClickPropagation = false; - this.isOpenChange = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.isDisabledChange = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.toggleClick = new _angular_core__WEBPACK_IMPORTED_MODULE_0__["EventEmitter"](); - this.counts = 0; - this.dropdownMenu = new Promise(resolve => { - this.resolveDropdownMenu = resolve; - }); - } - } - BsDropdownState.ɵfac = function BsDropdownState_Factory(t) { return new (t || BsDropdownState)(); }; - BsDropdownState.ɵprov = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjectable"]({ token: BsDropdownState, factory: BsDropdownState.ɵfac }); - return BsDropdownState; -})(); -const DROPDOWN_ANIMATION_TIMING = '220ms cubic-bezier(0, 0, 0.2, 1)'; -const dropdownAnimation = [ - Object(_angular_animations__WEBPACK_IMPORTED_MODULE_4__["style"])({ height: 0, overflow: 'hidden' }), - Object(_angular_animations__WEBPACK_IMPORTED_MODULE_4__["animate"])(DROPDOWN_ANIMATION_TIMING, Object(_angular_animations__WEBPACK_IMPORTED_MODULE_4__["style"])({ height: '*', overflow: 'hidden' })) -]; -let BsDropdownContainerComponent = /*@__PURE__*/ (() => { - class BsDropdownContainerComponent { - constructor(_state, cd, _renderer, _element, _builder) { - this._state = _state; - this.cd = cd; - this._renderer = _renderer; - this._element = _element; - this.isOpen = false; - this._factoryDropDownAnimation = _builder.build(dropdownAnimation); - this._subscription = _state.isOpenChange.subscribe((value) => { - this.isOpen = value; - const dropdown = this._element.nativeElement.querySelector('.dropdown-menu'); - this._renderer.addClass(this._element.nativeElement.querySelector('div'), 'open'); - if (dropdown && !Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_3__["isBs3"])()) { - this._renderer.addClass(dropdown, 'show'); - if (dropdown.classList.contains('dropdown-menu-right') || dropdown.classList.contains('dropdown-menu-end')) { - this._renderer.setStyle(dropdown, 'left', 'auto'); - this._renderer.setStyle(dropdown, 'right', '0'); - } - if (this.direction === 'up') { - this._renderer.setStyle(dropdown, 'top', 'auto'); - this._renderer.setStyle(dropdown, 'transform', 'translateY(-101%)'); - } - } - if (dropdown && this._state.isAnimated) { - this._factoryDropDownAnimation.create(dropdown) - .play(); - } - this.cd.markForCheck(); - this.cd.detectChanges(); - }); - } - get direction() { - return this._state.direction; - } - /** @internal */ - _contains(el) { - return this._element.nativeElement.contains(el); - } - ngOnDestroy() { - this._subscription.unsubscribe(); - } - } - BsDropdownContainerComponent.ɵfac = function BsDropdownContainerComponent_Factory(t) { return new (t || BsDropdownContainerComponent)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](BsDropdownState), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]), _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"](_angular_animations__WEBPACK_IMPORTED_MODULE_4__["AnimationBuilder"])); }; - BsDropdownContainerComponent.ɵcmp = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineComponent"]({ type: BsDropdownContainerComponent, selectors: [["bs-dropdown-container"]], hostAttrs: [2, "display", "block", "position", "absolute", "z-index", "1040"], ngContentSelectors: _c1, decls: 2, vars: 9, consts: [[3, "ngClass"]], template: function BsDropdownContainerComponent_Template(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojectionDef"](); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementStart"](0, "div", 0); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵprojection"](1); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵelementEnd"](); - } - if (rf & 2) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("dropup", ctx.direction === "up")("show", ctx.isOpen)("open", ctx.isOpen); - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵproperty"]("ngClass", _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵpureFunction1"](7, _c0, ctx.direction === "down")); - } - }, directives: [_angular_common__WEBPACK_IMPORTED_MODULE_5__["NgClass"]], encapsulation: 2, changeDetection: 0 }); - return BsDropdownContainerComponent; -})(); -let BsDropdownDirective = /*@__PURE__*/ (() => { - class BsDropdownDirective { - constructor(_elementRef, _renderer, _viewContainerRef, _cis, _state, _config, _builder) { - this._elementRef = _elementRef; - this._renderer = _renderer; - this._viewContainerRef = _viewContainerRef; - this._cis = _cis; - this._state = _state; - this._config = _config; - /** - * This attribute indicates that the dropdown should be opened upwards - */ - this.dropup = false; - // todo: move to component loader - this._isInlineOpen = false; - this._isDisabled = false; - this._subscriptions = []; - this._isInited = false; - // set initial dropdown state from config - this._state.autoClose = this._config.autoClose; - this._state.insideClick = this._config.insideClick; - this._state.isAnimated = this._config.isAnimated; - this._state.stopOnClickPropagation = this._config.stopOnClickPropagation; - this._factoryDropDownAnimation = _builder.build(dropdownAnimation); - // create dropdown component loader - this._dropdown = this._cis - .createLoader(this._elementRef, this._viewContainerRef, this._renderer) - .provide({ provide: BsDropdownState, useValue: this._state }); - this.onShown = this._dropdown.onShown; - this.onHidden = this._dropdown.onHidden; - this.isOpenChange = this._state.isOpenChange; - } - /** - * Indicates that dropdown will be closed on item or document click, - * and after pressing ESC - */ - set autoClose(value) { - this._state.autoClose = value; - } - get autoClose() { - return this._state.autoClose; - } - /** - * Indicates that dropdown will be animated - */ - set isAnimated(value) { - this._state.isAnimated = value; - } - get isAnimated() { - return this._state.isAnimated; - } - /** - * This attribute indicates that the dropdown shouldn't close on inside click when autoClose is set to true - */ - set insideClick(value) { - this._state.insideClick = value; - } - get insideClick() { - return this._state.insideClick; - } - /** - * Disables dropdown toggle and hides dropdown menu if opened - */ - set isDisabled(value) { - this._isDisabled = value; - this._state.isDisabledChange.emit(value); - if (value) { - this.hide(); - } - } - get isDisabled() { - return this._isDisabled; - } - /** - * Returns whether or not the popover is currently being shown - */ - get isOpen() { - if (this._showInline) { - return this._isInlineOpen; - } - return this._dropdown.isShown; - } - set isOpen(value) { - if (value) { - this.show(); - } - else { - this.hide(); - } - } - get isBs4() { - return !Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_3__["isBs3"])(); - } - get _showInline() { - return !this.container; - } - ngOnInit() { - // fix: seems there are an issue with `routerLinkActive` - // which result in duplicated call ngOnInit without call to ngOnDestroy - // read more: https://github.com/valor-software/ngx-bootstrap/issues/1885 - if (this._isInited) { - return; - } - this._isInited = true; - // attach DOM listeners - this._dropdown.listen({ - // because of dropdown inline mode - outsideClick: false, - triggers: this.triggers, - show: () => this.show() - }); - // toggle visibility on toggle element click - this._subscriptions.push(this._state.toggleClick.subscribe((value) => this.toggle(value))); - // hide dropdown if set disabled while opened - this._subscriptions.push(this._state.isDisabledChange - .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_1__["filter"])((value) => value)) - .subscribe(( /*value: boolean*/) => this.hide())); - } - /** - * Opens an element’s popover. This is considered a “manual” triggering of - * the popover. - */ - show() { - if (this.isOpen || this.isDisabled) { - return; - } - if (this._showInline) { - if (!this._inlinedMenu) { - this._state.dropdownMenu.then((dropdownMenu) => { - this._dropdown.attachInline(dropdownMenu.viewContainer, dropdownMenu.templateRef); - this._inlinedMenu = this._dropdown._inlineViewRef; - this.addBs4Polyfills(); - if (this._inlinedMenu) { - this._renderer.addClass(this._inlinedMenu.rootNodes[0].parentNode, 'open'); - } - this.playAnimation(); - }) - // swallow errors - .catch(); - } - this.addBs4Polyfills(); - this._isInlineOpen = true; - this.onShown.emit(true); - this._state.isOpenChange.emit(true); - this.playAnimation(); - return; - } - this._state.dropdownMenu.then(dropdownMenu => { - // check direction in which dropdown should be opened - const _dropup = this.dropup || - (typeof this.dropup !== 'undefined' && this.dropup); - this._state.direction = _dropup ? 'up' : 'down'; - const _placement = this.placement || (_dropup ? 'top start' : 'bottom start'); - // show dropdown - this._dropdown - .attach(BsDropdownContainerComponent) - .to(this.container) - .position({ attachment: _placement }) - .show({ - content: dropdownMenu.templateRef, - placement: _placement - }); - this._state.isOpenChange.emit(true); - }) - // swallow error - .catch(); - } - /** - * Closes an element’s popover. This is considered a “manual” triggering of - * the popover. - */ - hide() { - if (!this.isOpen) { - return; - } - if (this._showInline) { - this.removeShowClass(); - this.removeDropupStyles(); - this._isInlineOpen = false; - this.onHidden.emit(true); - } - else { - this._dropdown.hide(); - } - this._state.isOpenChange.emit(false); - } - /** - * Toggles an element’s popover. This is considered a “manual” triggering of - * the popover. With parameter true allows toggling, with parameter false - * only hides opened dropdown. Parameter usage will be removed in ngx-bootstrap v3 - */ - toggle(value) { - if (this.isOpen || !value) { - return this.hide(); - } - return this.show(); - } - /** @internal */ - _contains(event) { - // todo: valorkin fix typings - return this._elementRef.nativeElement.contains(event.target) || - (this._dropdown.instance && this._dropdown.instance._contains(event.target)); - } - navigationClick(event) { - const ref = this._elementRef.nativeElement.querySelector('.dropdown-menu'); - if (!ref) { - return; - } - const firstActive = this._elementRef.nativeElement.ownerDocument.activeElement; - const allRef = ref.querySelectorAll('.dropdown-item'); - switch (event.keyCode) { - case 38: - if (this._state.counts > 0) { - allRef[--this._state.counts].focus(); - } - break; - case 40: - if (this._state.counts + 1 < allRef.length) { - if (firstActive.classList !== allRef[this._state.counts].classList) { - allRef[this._state.counts].focus(); - } - else { - allRef[++this._state.counts].focus(); - } - } - break; - default: - } - event.preventDefault(); - } - ngOnDestroy() { - // clean up subscriptions and destroy dropdown - for (const sub of this._subscriptions) { - sub.unsubscribe(); - } - this._dropdown.dispose(); - } - addBs4Polyfills() { - if (!Object(ngx_bootstrap_utils__WEBPACK_IMPORTED_MODULE_3__["isBs3"])()) { - this.addShowClass(); - this.checkRightAlignment(); - this.addDropupStyles(); - } - } - playAnimation() { - if (this._state.isAnimated && this._inlinedMenu) { - setTimeout(() => { - if (this._inlinedMenu) { - this._factoryDropDownAnimation.create(this._inlinedMenu.rootNodes[0]).play(); - } - }); - } - } - addShowClass() { - if (this._inlinedMenu && this._inlinedMenu.rootNodes[0]) { - this._renderer.addClass(this._inlinedMenu.rootNodes[0], 'show'); - } - } - removeShowClass() { - if (this._inlinedMenu && this._inlinedMenu.rootNodes[0]) { - this._renderer.removeClass(this._inlinedMenu.rootNodes[0], 'show'); - } - } - checkRightAlignment() { - if (this._inlinedMenu && this._inlinedMenu.rootNodes[0]) { - const isRightAligned = this._inlinedMenu.rootNodes[0].classList.contains('dropdown-menu-right') || this._inlinedMenu.rootNodes[0].classList.contains('dropdown-menu-end'); - this._renderer.setStyle(this._inlinedMenu.rootNodes[0], 'left', isRightAligned ? 'auto' : '0'); - this._renderer.setStyle(this._inlinedMenu.rootNodes[0], 'right', isRightAligned ? '0' : 'auto'); - } - } - addDropupStyles() { - if (this._inlinedMenu && this._inlinedMenu.rootNodes[0]) { - // a little hack to not break support of bootstrap 4 beta - this._renderer.setStyle(this._inlinedMenu.rootNodes[0], 'top', this.dropup ? 'auto' : '100%'); - this._renderer.setStyle(this._inlinedMenu.rootNodes[0], 'transform', this.dropup ? 'translateY(-101%)' : 'translateY(0)'); - this._renderer.setStyle(this._inlinedMenu.rootNodes[0], 'bottom', 'auto'); - } - } - removeDropupStyles() { - if (this._inlinedMenu && this._inlinedMenu.rootNodes[0]) { - this._renderer.removeStyle(this._inlinedMenu.rootNodes[0], 'top'); - this._renderer.removeStyle(this._inlinedMenu.rootNodes[0], 'transform'); - this._renderer.removeStyle(this._inlinedMenu.rootNodes[0], 'bottom'); - } - } - } - BsDropdownDirective.ɵfac = function BsDropdownDirective_Factory(t) { return new (t || BsDropdownDirective)(_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"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ViewContainerRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](ngx_bootstrap_component_loader__WEBPACK_IMPORTED_MODULE_2__["ComponentLoaderFactory"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](BsDropdownState), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](BsDropdownConfig), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_animations__WEBPACK_IMPORTED_MODULE_4__["AnimationBuilder"])); }; - BsDropdownDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: BsDropdownDirective, selectors: [["", "bsDropdown", ""], ["", "dropdown", ""]], hostVars: 6, hostBindings: function BsDropdownDirective_HostBindings(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("keydown.arrowDown", function BsDropdownDirective_keydown_arrowDown_HostBindingHandler($event) { return ctx.navigationClick($event); })("keydown.arrowUp", function BsDropdownDirective_keydown_arrowUp_HostBindingHandler($event) { return ctx.navigationClick($event); }); - } - if (rf & 2) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵclassProp"]("dropup", ctx.dropup)("open", ctx.isOpen)("show", ctx.isOpen && ctx.isBs4); - } - }, inputs: { dropup: "dropup", autoClose: "autoClose", isAnimated: "isAnimated", insideClick: "insideClick", isDisabled: "isDisabled", isOpen: "isOpen", placement: "placement", triggers: "triggers", container: "container" }, outputs: { onShown: "onShown", onHidden: "onHidden", isOpenChange: "isOpenChange" }, exportAs: ["bs-dropdown"], features: [_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵProvidersFeature"]([BsDropdownState])] }); - return BsDropdownDirective; -})(); -let BsDropdownMenuDirective = /*@__PURE__*/ (() => { - class BsDropdownMenuDirective { - constructor(_state, _viewContainer, _templateRef) { - _state.resolveDropdownMenu({ - templateRef: _templateRef, - viewContainer: _viewContainer - }); - } - } - BsDropdownMenuDirective.ɵfac = function BsDropdownMenuDirective_Factory(t) { return new (t || BsDropdownMenuDirective)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](BsDropdownState), _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"])); }; - BsDropdownMenuDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: BsDropdownMenuDirective, selectors: [["", "bsDropdownMenu", ""], ["", "dropdownMenu", ""]], exportAs: ["bs-dropdown-menu"] }); - return BsDropdownMenuDirective; -})(); -let BsDropdownToggleDirective = /*@__PURE__*/ (() => { - class BsDropdownToggleDirective { - constructor(_changeDetectorRef, _dropdown, _element, _renderer, _state) { - this._changeDetectorRef = _changeDetectorRef; - this._dropdown = _dropdown; - this._element = _element; - this._renderer = _renderer; - this._state = _state; - this.isOpen = false; - this._subscriptions = []; - // sync is open value with state - this._subscriptions.push(this._state.isOpenChange.subscribe((value) => { - this.isOpen = value; - if (value) { - this._documentClickListener = this._renderer.listen('document', 'click', (event) => { - if (this._state.autoClose && event.button !== 2 && - !this._element.nativeElement.contains(event.target) && - !(this._state.insideClick && this._dropdown._contains(event))) { - this._state.toggleClick.emit(false); - this._changeDetectorRef.detectChanges(); - } - }); - this._escKeyUpListener = this._renderer.listen(this._element.nativeElement, 'keyup.esc', () => { - if (this._state.autoClose) { - this._state.toggleClick.emit(false); - this._changeDetectorRef.detectChanges(); - } - }); - } - else { - this._documentClickListener && this._documentClickListener(); - this._escKeyUpListener && this._escKeyUpListener(); - } - })); - // populate disabled state - this._subscriptions.push(this._state.isDisabledChange - .subscribe((value) => this.isDisabled = value || void 0)); - } - onClick(event) { - if (this._state.stopOnClickPropagation) { - event.stopPropagation(); - } - if (this.isDisabled) { - return; - } - this._state.toggleClick.emit(true); - } - ngOnDestroy() { - if (this._documentClickListener) { - this._documentClickListener(); - } - if (this._escKeyUpListener) { - this._escKeyUpListener(); - } - for (const sub of this._subscriptions) { - sub.unsubscribe(); - } - } - } - BsDropdownToggleDirective.ɵfac = function BsDropdownToggleDirective_Factory(t) { return new (t || BsDropdownToggleDirective)(_angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](_angular_core__WEBPACK_IMPORTED_MODULE_0__["ChangeDetectorRef"]), _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdirectiveInject"](BsDropdownDirective), _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"](BsDropdownState)); }; - BsDropdownToggleDirective.ɵdir = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineDirective"]({ type: BsDropdownToggleDirective, selectors: [["", "bsDropdownToggle", ""], ["", "dropdownToggle", ""]], hostVars: 3, hostBindings: function BsDropdownToggleDirective_HostBindings(rf, ctx) { - if (rf & 1) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵlistener"]("click", function BsDropdownToggleDirective_click_HostBindingHandler($event) { return ctx.onClick($event); }); - } - if (rf & 2) { - _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵattribute"]("aria-haspopup", true)("aria-expanded", ctx.isOpen)("disabled", ctx.isDisabled); - } - }, exportAs: ["bs-dropdown-toggle"] }); - return BsDropdownToggleDirective; -})(); -let BsDropdownModule = /*@__PURE__*/ (() => { - class BsDropdownModule { - static forRoot() { - return { - ngModule: BsDropdownModule, - providers: [ - ngx_bootstrap_component_loader__WEBPACK_IMPORTED_MODULE_2__["ComponentLoaderFactory"], - ngx_bootstrap_positioning__WEBPACK_IMPORTED_MODULE_6__["PositioningService"], - BsDropdownState - ] - }; - } - } - BsDropdownModule.ɵfac = function BsDropdownModule_Factory(t) { return new (t || BsDropdownModule)(); }; - BsDropdownModule.ɵmod = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineNgModule"]({ type: BsDropdownModule }); - BsDropdownModule.ɵinj = _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵdefineInjector"]({ imports: [[_angular_common__WEBPACK_IMPORTED_MODULE_5__["CommonModule"]]] }); - return BsDropdownModule; -})(); -(function () { (typeof ngJitMode === "undefined" || ngJitMode) && _angular_core__WEBPACK_IMPORTED_MODULE_0__["ɵɵsetNgModuleScope"](BsDropdownModule, { declarations: function () { return [BsDropdownMenuDirective, BsDropdownToggleDirective, BsDropdownContainerComponent, BsDropdownDirective]; }, imports: function () { return [_angular_common__WEBPACK_IMPORTED_MODULE_5__["CommonModule"]]; }, exports: function () { return [BsDropdownMenuDirective, BsDropdownToggleDirective, BsDropdownDirective]; } }); })(); -/** - * Generated bundle index. Do not edit. - */ - -//# sourceMappingURL=ngx-bootstrap-dropdown.js.map - - -/***/ }), - -/***/ "dkDA": -/*!**********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/materialize.js ***! - \**********************************************************************/ -/*! exports provided: materialize */ -/***/ (function(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 */ "7o/Q"); -/* harmony import */ var _Notification__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Notification */ "WMd4"); - - -function materialize() { - return function materializeOperatorFunction(source) { - return source.lift(new MaterializeOperator()); - }; -} -class MaterializeOperator { - call(subscriber, source) { - return source.subscribe(new MaterializeSubscriber(subscriber)); - } -} -class MaterializeSubscriber extends _Subscriber__WEBPACK_IMPORTED_MODULE_0__["Subscriber"] { - constructor(destination) { - super(destination); - } - _next(value) { - this.destination.next(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createNext(value)); - } - _error(err) { - const destination = this.destination; - destination.next(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createError(err)); - destination.complete(); - } - _complete() { - const destination = this.destination; - destination.next(_Notification__WEBPACK_IMPORTED_MODULE_1__["Notification"].createComplete()); - destination.complete(); - } -} -//# sourceMappingURL=materialize.js.map - - -/***/ }), - -/***/ "eIep": -/*!********************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/switchMap.js ***! - \********************************************************************/ -/*! exports provided: switchMap */ -/***/ (function(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 _map__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./map */ "lJxs"); -/* harmony import */ var _observable_from__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../observable/from */ "Cfvw"); -/* harmony import */ var _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../innerSubscribe */ "zx2A"); - - - -function switchMap(project, resultSelector) { - if (typeof resultSelector === 'function') { - return (source) => source.pipe(switchMap((a, i) => Object(_observable_from__WEBPACK_IMPORTED_MODULE_1__["from"])(project(a, i)).pipe(Object(_map__WEBPACK_IMPORTED_MODULE_0__["map"])((b, ii) => resultSelector(a, b, i, ii))))); - } - return (source) => source.lift(new SwitchMapOperator(project)); -} -class SwitchMapOperator { - constructor(project) { - this.project = project; - } - call(subscriber, source) { - return source.subscribe(new SwitchMapSubscriber(subscriber, this.project)); - } -} -class SwitchMapSubscriber extends _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["SimpleOuterSubscriber"] { - constructor(destination, project) { - super(destination); - this.project = project; - this.index = 0; - } - _next(value) { - let result; - const index = this.index++; - try { - result = this.project(value, index); - } - catch (error) { - this.destination.error(error); - return; - } - this._innerSub(result); - } - _innerSub(result) { - const innerSubscription = this.innerSubscription; - if (innerSubscription) { - innerSubscription.unsubscribe(); - } - const innerSubscriber = new _innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["SimpleInnerSubscriber"](this); - const destination = this.destination; - destination.add(innerSubscriber); - this.innerSubscription = Object(_innerSubscribe__WEBPACK_IMPORTED_MODULE_2__["innerSubscribe"])(result, innerSubscriber); - if (this.innerSubscription !== innerSubscriber) { - destination.add(this.innerSubscription); - } - } - _complete() { - const { innerSubscription } = this; - if (!innerSubscription || innerSubscription.closed) { - super._complete(); - } - this.unsubscribe(); - } - _unsubscribe() { - this.innerSubscription = undefined; - } - notifyComplete() { - this.innerSubscription = undefined; - if (this.isStopped) { - super._complete(); - } - } - notifyNext(innerValue) { - this.destination.next(innerValue); - } -} -//# sourceMappingURL=switchMap.js.map - - -/***/ }), - -/***/ "eNwd": -/*!*************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/scheduler/animationFrame.js ***! - \*************************************************************************/ -/*! exports provided: animationFrameScheduler, animationFrame */ -/***/ (function(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 export (binding) */ __webpack_require__.d(__webpack_exports__, "animationFrame", function() { return animationFrame; }); -/* harmony import */ var _AnimationFrameAction__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./AnimationFrameAction */ "Vpsf"); -/* harmony import */ var _AnimationFrameScheduler__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./AnimationFrameScheduler */ "znLP"); - - -const animationFrameScheduler = /*@__PURE__*/ new _AnimationFrameScheduler__WEBPACK_IMPORTED_MODULE_1__["AnimationFrameScheduler"](_AnimationFrameAction__WEBPACK_IMPORTED_MODULE_0__["AnimationFrameAction"]); -const animationFrame = animationFrameScheduler; -//# sourceMappingURL=animationFrame.js.map - - -/***/ }), - -/***/ "f29J": -/*!*****************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/concat.js ***! - \*****************************************************************/ -/*! exports provided: concat */ -/***/ (function(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 */ "GyhO"); - -function concat(...observables) { - return (source) => source.lift.call(Object(_observable_concat__WEBPACK_IMPORTED_MODULE_0__["concat"])(source, ...observables)); -} -//# sourceMappingURL=concat.js.map - - -/***/ }), - -/***/ "fFD9": -/*!************************************************************************!*\ - !*** ./node_modules/rxjs/_esm2015/internal/operators/combineLatest.js ***! - \************************************************************************/ -/*! exports provided: combineLatest */ -/***/ (function(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 */ "DH7j"); -/* harmony import */ var _observable_combineLatest__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../observable/combineLatest */ "itXk"); -/* harmony import */ var _observable_from__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../observable/from */ "Cfvw"); - - - -const none = {}; -function combineLatest(...observables) { - let 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 (source) => source.lift.call(Object(_observable_from__WEBPACK_IMPORTED_MODULE_2__["from"])([source, ...observables]), new _observable_combineLatest__WEBPACK_IMPORTED_MODULE_1__["CombineLatestOperator"](project)); -} -//# sourceMappingURL=combineLatest.js.map - - -/***/ }), - -/***/ "fXoL": -/*!******************************************************************!*\ - !*** ./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, ɵ0, ɵALLOW_MULTIPLE_PLATFORMS, ɵAPP_ID_RANDOM_PROVIDER, ɵCREATE_ATTRIBUTE_DECORATOR__POST_R3__, ɵ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, ɵRuntimeError, ɵ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, ɵ_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_be, ɵ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_bl, ɵangular_packages_core_core_bm, ɵangular_packages_core_core_bn, ɵangular_packages_core_core_bo, ɵangular_packages_core_core_bp, ɵangular_packages_core_core_bq, ɵangular_packages_core_core_br, ɵangular_packages_core_core_bs, ɵangular_packages_core_core_bv, ɵangular_packages_core_core_bw, ɵangular_packages_core_core_bx, ɵangular_packages_core_core_bz, ɵangular_packages_core_core_c, ɵangular_packages_core_core_cb, ɵangular_packages_core_core_cc, ɵ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, ɵisSubscribable, ɵivyEnabled, ɵmakeDecorator, ɵmarkDirty, ɵmod, ɵmpd, ɵncd, ɵnoSideEffects, ɵ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, ɵɵcontentQuery, ɵɵdefineComponent, ɵɵdefineDirective, ɵɵdefineInjectable, ɵɵdefineInjector, ɵɵdefineNgModule, ɵɵdefinePipe, ɵɵdirectiveInject, ɵɵdisableBindings, ɵɵelement, ɵɵelementContainer, ɵɵelementContainerEnd, ɵɵelementContainerStart, ɵɵelementEnd, ɵɵelementStart, ɵɵenableBindings, ɵɵgetCurrentView, ɵɵgetInheritedFactory, ɵɵhostProperty, ɵɵi18n, ɵɵi18nApply, ɵɵi18nAttributes, ɵɵi18nEnd, ɵɵi18nExp, ɵɵi18nPostprocess, ɵɵi18nStart, ɵɵinject, ɵɵinjectAttribute, ɵɵinjectPipeChangeDetectorRef, ɵɵinvalidFactory, ɵɵinvalidFactoryDep, ɵɵlistener, ɵɵloadQuery, ɵɵnamespaceHTML, ɵɵnamespaceMathML, ɵɵnamespaceSVG, ɵɵnextContext, ɵɵngDeclareComponent, ɵɵngDeclareDirective, ɵɵngDeclarePipe, ɵɵ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, ɵɵsetComponentScope, ɵɵsetNgModuleScope, ɵɵstyleMap, ɵɵstyleMapInterpolate1, ɵɵstyleMapInterpolate2, ɵɵstyleMapInterpolate3, ɵɵstyleMapInterpolate4, ɵɵstyleMapInterpolate5, ɵɵstyleMapInterpolate6, ɵɵstyleMapInterpolate7, ɵɵstyleMapInterpolate8, ɵɵstyleMapInterpolateV, ɵɵstyleProp, ɵɵstylePropInterpolate1, ɵɵstylePropInterpolate2, ɵɵstylePropInterpolate3, ɵɵstylePropInterpolate4, ɵɵstylePropInterpolate5, ɵɵstylePropInterpolate6, ɵɵstylePropInterpolate7, ɵɵstylePropInterpolate8, ɵɵstylePropInterpolateV, ɵɵsyntheticHostListener, ɵɵsyntheticHostProperty, ɵɵtemplate, ɵɵtemplateRefExtractor, ɵɵtext, ɵɵtextInterpolate, ɵɵtextInterpolate1, ɵɵtextInterpolate2, ɵɵtextInterpolate3, ɵɵtextInterpolate4, ɵɵtextInterpolate5, ɵɵtextInterpolate6, ɵɵtextInterpolate7, ɵɵtextInterpolate8, ɵɵtextInterpolateV, ɵɵtrustConstantHtml, ɵɵtrustConstantResourceUrl, ɵɵviewQuery */ -/***/ (function(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; }); -/* 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$1; }); -/* 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; }); -/* 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__, "ɵ0", function() { return ɵ0$3; }); -/* 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__, "ɵCREATE_ATTRIBUTE_DECORATOR__POST_R3__", function() { return CREATE_ATTRIBUTE_DECORATOR__POST_R3__; }); -/* 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__, "ɵRuntimeError", function() { return RuntimeError; }); -/* 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__, "ɵ_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 zoneSchedulerFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bb", function() { return USD_CURRENCY_CODE; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bc", function() { return _def; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bd", function() { return DebugContext; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_be", function() { return NgOnChangesFeatureImpl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bf", function() { return SCHEDULER; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bg", function() { return injectAttributeImpl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bh", function() { return getLView; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bi", function() { return getBindingRoot; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bj", function() { return nextContextImpl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bl", function() { return pureFunction1Internal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bm", function() { return pureFunction2Internal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bn", function() { return pureFunction3Internal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bo", function() { return pureFunction4Internal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bp", function() { return pureFunctionVInternal; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bq", function() { return getUrlSanitizer; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_br", function() { return makePropDecorator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bs", function() { return makeParamDecorator; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bv", function() { return getClosureSafeProperty; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bw", function() { return NullInjector; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bx", function() { return getInjectImplementation; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_bz", function() { return getNativeByTNode; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_c", function() { return attachInjectFlag; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_cb", function() { return getRootContext; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_cc", function() { return i18nPostprocess; }); -/* 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 injectRenderer2; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_i", function() { return injectElementRef; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_j", function() { return createElementRef; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_k", function() { return getModuleFactory__PRE_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_l", function() { return injectTemplateRef; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_m", function() { return createTemplateRef; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_n", function() { return injectViewContainerRef; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_o", function() { return DebugNode__PRE_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_p", function() { return DebugElement__PRE_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_q", function() { return getDebugNodeR2__PRE_R3__; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_r", function() { return injectChangeDetectorRef; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_s", function() { return DefaultIterableDifferFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_t", function() { return DefaultKeyValueDifferFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_u", function() { return defaultIterableDiffersFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_v", function() { return defaultKeyValueDiffersFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_w", function() { return _iterableDiffersFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_x", function() { return _keyValueDiffersFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_y", function() { return _localeFactory; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵangular_packages_core_core_z", function() { return APPLICATION_MODULE_PROVIDERS; }); -/* 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; }); -/* 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; }); -/* 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__, "ɵisSubscribable", function() { return isSubscribable; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵivyEnabled", function() { return ivyEnabled; }); -/* 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__, "ɵnoSideEffects", function() { return noSideEffects; }); -/* 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__, "ɵɵcontentQuery", function() { return ɵɵcontentQuery; }); -/* 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__, "ɵɵenableBindings", function() { return ɵɵenableBindings; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵɵgetCurrentView", function() { return ɵɵgetCurrentView; }); -/* 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__, "ɵɵngDeclareComponent", function() { return ɵɵngDeclareComponent; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵɵngDeclareDirective", function() { return ɵɵngDeclareDirective; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵɵngDeclarePipe", function() { return ɵɵngDeclarePipe; }); -/* 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__, "ɵɵsetComponentScope", function() { return ɵɵsetComponentScope; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵɵsetNgModuleScope", function() { return ɵɵsetNgModuleScope; }); -/* 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__, "ɵɵsyntheticHostListener", function() { return ɵɵsyntheticHostListener; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵɵsyntheticHostProperty", function() { return ɵɵsyntheticHostProperty; }); -/* 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__, "ɵɵtrustConstantHtml", function() { return ɵɵtrustConstantHtml; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵɵtrustConstantResourceUrl", function() { return ɵɵtrustConstantResourceUrl; }); -/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "ɵɵviewQuery", function() { return ɵɵviewQuery; }); -/* harmony import */ var rxjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! rxjs */ "qCKp"); -/* harmony import */ var rxjs_operators__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! rxjs/operators */ "kU1M"); -/** - * @license Angular v11.2.14 - * (c) 2010-2021 Google LLC. https://angular.io/ - * License: MIT - */ - - -/** - * @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 getClosureSafeProperty(objWithPropertyToExtract) { - for (let 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 (const key in source) { - if (source.hasOwnProperty(key) && !target.hasOwnProperty(key)) { - target[key] = source[key]; - } - } -} -/** - * @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 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 `${token.overriddenName}`; - } - if (token.name) { - return `${token.name}`; - } - const res = token.toString(); - if (res == null) { - return '' + res; - } - const 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); -} -/** - * @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 - */ -const __forward_ref__ = /*@__PURE__*/ 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 - */ -function forwardRef(forwardRefFn) { - forwardRefFn.__forward_ref__ = forwardRef; - forwardRefFn.toString = function () { - return stringify(this()); - }; - return 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 - */ -function resolveForwardRef(type) { - return isForwardRef(type) ? type() : type; -} -/** Checks whether a function is wrapped by a `forwardRef`. */ -function isForwardRef(fn) { - return typeof fn === 'function' && fn.hasOwnProperty(__forward_ref__) && - fn.__forward_ref__ === forwardRef; -} -/** - * @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 - */ -// Base URL for the error details page. -// Keep this value in sync with a similar const in -// `packages/compiler-cli/src/ngtsc/diagnostics/src/error_code.ts`. -const ERROR_DETAILS_PAGE_BASE_URL = 'https://angular.io/errors'; -class RuntimeError extends Error { - constructor(code, message) { - super(formatRuntimeError(code, message)); - this.code = code; - } -} -// Contains a set of error messages that have details guides at angular.io. -// Full list of available error guides can be found at https://angular.io/errors -/* tslint:disable:no-toplevel-property-access */ -const RUNTIME_ERRORS_WITH_GUIDES = /*@__PURE__*/ new Set([ - "100" /* EXPRESSION_CHANGED_AFTER_CHECKED */, - "200" /* CYCLIC_DI_DEPENDENCY */, - "201" /* PROVIDER_NOT_FOUND */, - "300" /* MULTIPLE_COMPONENTS_MATCH */, - "301" /* EXPORT_NOT_FOUND */, - "302" /* PIPE_NOT_FOUND */, -]); -/* tslint:enable:no-toplevel-property-access */ -/** Called to format a runtime error */ -function formatRuntimeError(code, message) { - const fullCode = code ? `NG0${code}: ` : ''; - let errorMessage = `${fullCode}${message}`; - // Some runtime errors are still thrown without `ngDevMode` (for example - // `throwProviderNotFoundError`), so we add `ngDevMode` check here to avoid pulling - // `RUNTIME_ERRORS_WITH_GUIDES` symbol into prod bundles. - // TODO: revisit all instances where `RuntimeError` is thrown and see if `ngDevMode` can be added - // there instead to tree-shake more devmode-only code (and eventually remove `ngDevMode` check - // from this code). - if (ngDevMode && RUNTIME_ERRORS_WITH_GUIDES.has(code)) { - errorMessage = `${errorMessage}. Find more at ${ERROR_DETAILS_PAGE_BASE_URL}/NG0${code}`; - } - return errorMessage; -} -/** - * @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 - */ -/** - * 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. - * Check `core/test/render3/perf/render_stringify` for benchmarks and alternate implementations. - */ -function renderStringify(value) { - if (typeof value === 'string') - return value; - if (value == null) - return ''; - // Use `String` so that it invokes the `toString` method of the value. Note that this - // appears to be faster than calling `value.toString` (see `render_stringify` benchmark). - return String(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. - */ -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); -} -/** Called when directives inject each other (creating a circular dependency) */ -function throwCyclicDependencyError(token, path) { - const depPath = path ? `. Dependency path: ${path.join(' > ')} > ${token}` : ''; - throw new RuntimeError("200" /* CYCLIC_DI_DEPENDENCY */, `Circular dependency in DI detected for ${token}${depPath}`); -} -function throwMixedMultiProviderError() { - throw new Error(`Cannot mix multi providers and regular providers`); -} -function throwInvalidProviderError(ngModuleType, providers, provider) { - let ngModuleDetail = ''; - if (ngModuleType && providers) { - const providerDetail = providers.map(v => v == provider ? '?' + provider + '?' : '...'); - ngModuleDetail = - ` - only instances of Provider and Type are allowed, got: [${providerDetail.join(', ')}]`; - } - throw new Error(`Invalid provider for the NgModule '${stringify(ngModuleType)}'` + ngModuleDetail); -} -/** Throws an error when a token is not found in DI. */ -function throwProviderNotFoundError(token, injectorName) { - const injectorDetails = injectorName ? ` in ${injectorName}` : ''; - throw new RuntimeError("201" /* PROVIDER_NOT_FOUND */, `No provider for ${stringifyForError(token)} found${injectorDetails}`); -} -/** - * @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 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 assertFunction(actual, msg) { - if (!(typeof actual === 'function')) { - throwError(msg, actual === null ? 'null' : typeof actual, 'function', '==='); - } -} -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: ${msg}` + - (comparison == null ? '' : ` [Expected=> ${expected} ${comparison} ${actual} <=Actual]`)); -} -function assertDomNode(node) { - // If we're in a worker, `Node` will not be defined. - if (!(typeof Node !== 'undefined' && node instanceof Node) && - !(typeof node === 'object' && node != null && - node.constructor.name === 'WebWorkerRenderNode')) { - throwError(`The provided value must be an instance of a DOM Node but got ${stringify(node)}`); - } -} -function assertIndexInRange(arr, index) { - assertDefined(arr, 'Array must be defined.'); - const maxLen = arr.length; - if (index < 0 || index >= maxLen) { - throwError(`Index expected to be less than ${maxLen} but got ${index}`); - } -} -function assertOneOf(value, ...validValues) { - if (validValues.indexOf(value) !== -1) - return true; - throwError(`Expected value to be one of ${JSON.stringify(validValues)} but was ${JSON.stringify(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 - */ -/** - * 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 - * @publicApi This instruction has been emitted by ViewEngine for some time and is deployed to npm. - */ -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 by generated code, and that - * code should now use ɵɵdefineInjectable instead. - * @publicApi - */ -const 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: - * - * * `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. - * - * @codeGenApi - */ -function ɵɵdefineInjector(options) { - return { 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, NG_PROV_DEF) || getOwnDefinition(type, NG_INJECTABLE_DEF); -} -/** - * Return definition only if it is defined directly on `type` and is not inherited from a base - * class of `type`. - */ -function getOwnDefinition(type, field) { - return type.hasOwnProperty(field) ? type[field] : 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 a future version of Angular, where an error will occur in the - * scenario if we find the `ɵprov` on an ancestor only. - */ -function getInheritedInjectableDef(type) { - const def = type && (type[NG_PROV_DEF] || type[NG_INJECTABLE_DEF]); - if (def) { - const typeName = getTypeName(type); - // TODO(FW-1307): Re-add ngDevMode when closure can handle it - // ngDevMode && - console.warn(`DEPRECATED: DI is instantiating a token "${typeName}" that inherits its @Injectable decorator but does not provide one itself.\n` + - `This will become an error in a future version of Angular. Please add @Injectable() to the "${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; - } - const 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; -} -const NG_PROV_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵprov: getClosureSafeProperty }); -const NG_INJ_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵinj: getClosureSafeProperty }); -// We need to keep these around so we can read off old defs if new defs are unavailable -const NG_INJECTABLE_DEF = /*@__PURE__*/ getClosureSafeProperty({ ngInjectableDef: getClosureSafeProperty }); -const NG_INJECTOR_DEF = /*@__PURE__*/ getClosureSafeProperty({ ngInjectorDef: getClosureSafeProperty }); -/** - * @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 - */ -/** - * Injection flags for DI. - * - * @publicApi - */ -var InjectFlags = /*@__PURE__*/ (function (InjectFlags) { - // TODO(alxhub): make this 'const' (and remove `InternalInjectFlags` enum) 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"; - return InjectFlags; -})({}); -/** - * @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 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. - */ -let _injectImplementation; -function getInjectImplementation() { - return _injectImplementation; -} -/** - * Sets the current inject implementation. - */ -function setInjectImplementation(impl) { - const previous = _injectImplementation; - _injectImplementation = impl; - return previous; -} -/** - * 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`. - */ -function injectRootLimpMode(token, notFoundValue, flags) { - const 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; - throwProviderNotFoundError(stringify(token), 'Injector'); -} -/** - * Assert that `_injectImplementation` is not `fn`. - * - * This is useful, to prevent infinite recursion. - * - * @param fn Function which it should not equal to - */ -function assertInjectImplementationNotEqual(fn) { - ngDevMode && - assertNotEqual(_injectImplementation, fn, 'Calling ɵɵinject would cause infinite recursion'); -} -/** - * @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 - */ -/** - * 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 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 - */ -/** - * The strategy that the default change detector uses to detect changes. - * When set, takes effect the next time change detection is triggered. - * - * @see {@link ChangeDetectorRef#usage-notes Change detection usage} - * - * @publicApi - */ -var ChangeDetectionStrategy = /*@__PURE__*/ (function (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. - */ - ChangeDetectionStrategy[ChangeDetectionStrategy["OnPush"] = 0] = "OnPush"; - /** - * Use the default `CheckAlways` strategy, in which change detection is automatic until - * explicitly deactivated. - */ - ChangeDetectionStrategy[ChangeDetectionStrategy["Default"] = 1] = "Default"; - return ChangeDetectionStrategy; -})({}); -/** - * Defines the possible states of the default change detector. - * @see `ChangeDetectorRef` - */ -var ChangeDetectorStatus = /*@__PURE__*/ (function (ChangeDetectorStatus) { - /** - * A state in which, after calling `detectChanges()`, the change detector - * state becomes `Checked`, and must be explicitly invoked or reactivated. - */ - ChangeDetectorStatus[ChangeDetectorStatus["CheckOnce"] = 0] = "CheckOnce"; - /** - * A state in which change detection is skipped until the change detector mode - * becomes `CheckOnce`. - */ - ChangeDetectorStatus[ChangeDetectorStatus["Checked"] = 1] = "Checked"; - /** - * A state in which change detection continues automatically until explicitly - * deactivated. - */ - ChangeDetectorStatus[ChangeDetectorStatus["CheckAlways"] = 2] = "CheckAlways"; - /** - * A state in which a change detector sub tree is not a part of the main tree and - * should be skipped. - */ - ChangeDetectorStatus[ChangeDetectorStatus["Detached"] = 3] = "Detached"; - /** - * 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. - */ - ChangeDetectorStatus[ChangeDetectorStatus["Errored"] = 4] = "Errored"; - /** - * Indicates that the change detector has been destroyed. - */ - ChangeDetectorStatus[ChangeDetectorStatus["Destroyed"] = 5] = "Destroyed"; - return ChangeDetectorStatus; -})({}); -/** - * Reports whether a given strategy is currently the default for change detection. - * @param changeDetectionStrategy The strategy to check. - * @returns True if the given strategy is the current default, false otherwise. - * @see `ChangeDetectorStatus` - * @see `ChangeDetectorRef` - */ -function isDefaultChangeDetectionStrategy(changeDetectionStrategy) { - return changeDetectionStrategy == null || - changeDetectionStrategy === ChangeDetectionStrategy.Default; -} -/** - * @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 - */ -/** - * Defines template and style encapsulation options available for Component's {@link Component}. - * - * See {@link Component#encapsulation encapsulation}. - * - * @usageNotes - * ### Example - * - * {@example core/ts/metadata/encapsulation.ts region='longform'} - * - * @publicApi - */ -var ViewEncapsulation = /*@__PURE__*/ (function (ViewEncapsulation) { - /** - * 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. - */ - ViewEncapsulation[ViewEncapsulation["Emulated"] = 0] = "Emulated"; - // Historically the 1 value was for `Native` encapsulation which has been removed as of v11. - /** - * Don't provide any template or style encapsulation. - */ - ViewEncapsulation[ViewEncapsulation["None"] = 2] = "None"; - /** - * Use Shadow DOM to encapsulate styles. - * - * For the DOM this means using modern [Shadow - * DOM](https://developer.mozilla.org/en-US/docs/Web/Web_Components/Using_shadow_DOM) and - * creating a ShadowRoot for Component's Host Element. - */ - ViewEncapsulation[ViewEncapsulation["ShadowDom"] = 3] = "ShadowDom"; - return ViewEncapsulation; -})({}); -/** - * @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 - */ -const __globalThis = typeof globalThis !== 'undefined' && globalThis; -const __window = typeof window !== 'undefined' && window; -const __self = typeof self !== 'undefined' && typeof WorkerGlobalScope !== 'undefined' && - self instanceof WorkerGlobalScope && self; -const __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. -const _global = __globalThis || __global || __window || __self; -/** - * @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 ngDevModeResetPerfCounters() { - const locationString = typeof location !== 'undefined' ? location.toString() : ''; - const 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. - const 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 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 typeof ngDevMode !== 'undefined' && !!ngDevMode; - } - return 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 - */ -/** - * 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. - */ -const EMPTY_OBJ = {}; -const EMPTY_ARRAY = []; -// freezing the values prevents any code from accidentally inserting new values in -if ((typeof ngDevMode === 'undefined' || ngDevMode) && /*@__PURE__*/ 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 - /*@__PURE__*/ Object.freeze(EMPTY_OBJ); - // tslint:disable-next-line:no-toplevel-property-access - /*@__PURE__*/ Object.freeze(EMPTY_ARRAY); -} -/** - * @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 - */ -/** - * 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. - */ -const EMPTY_ARRAY$1 = []; -// freezing the values prevents any code from accidentally inserting new values in -if ((typeof ngDevMode === 'undefined' || ngDevMode) && /*@__PURE__*/ 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 - /*@__PURE__*/ Object.freeze(EMPTY_ARRAY$1); -} -/** - * @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 - */ -const NG_COMP_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵcmp: getClosureSafeProperty }); -const NG_DIR_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵdir: getClosureSafeProperty }); -const NG_PIPE_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵpipe: getClosureSafeProperty }); -const NG_MOD_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵmod: getClosureSafeProperty }); -const NG_LOC_ID_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵloc: getClosureSafeProperty }); -const NG_FACTORY_DEF = /*@__PURE__*/ getClosureSafeProperty({ ɵfac: getClosureSafeProperty }); -/** - * 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. - */ -// TODO(misko): This is wrong. The NG_ELEMENT_ID should never be minified. -const NG_ELEMENT_ID = /*@__PURE__*/ getClosureSafeProperty({ __NG_ELEMENT_ID__: getClosureSafeProperty }); -/** - * @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 - */ -let _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 - */ -function ɵɵdefineComponent(componentDefinition) { - return noSideEffects(() => { - // Initialize ngDevMode. This must be the first statement in ɵɵdefineComponent. - // See the `initNgDevMode` docstring for more information. - (typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode(); - const type = componentDefinition.type; - const declaredInputs = {}; - const def = { - type: type, - providersResolver: null, - decls: componentDefinition.decls, - vars: componentDefinition.vars, - factory: null, - template: componentDefinition.template || 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: null, - outputs: null, - exportAs: componentDefinition.exportAs || null, - onPush: componentDefinition.changeDetection === ChangeDetectionStrategy.OnPush, - directiveDefs: null, - pipeDefs: null, - selectors: componentDefinition.selectors || EMPTY_ARRAY$1, - viewQuery: componentDefinition.viewQuery || null, - features: 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.Emulated, - id: 'c', - styles: componentDefinition.styles || EMPTY_ARRAY$1, - _: null, - setInput: null, - schemas: componentDefinition.schemas || null, - tView: null, - }; - const directiveTypes = componentDefinition.directives; - const feature = componentDefinition.features; - const pipeTypes = componentDefinition.pipes; - def.id += _renderCompCount++; - def.inputs = invertObject(componentDefinition.inputs, declaredInputs), - def.outputs = invertObject(componentDefinition.outputs), - feature && feature.forEach((fn) => fn(def)); - def.directiveDefs = directiveTypes ? - () => (typeof directiveTypes === 'function' ? directiveTypes() : directiveTypes) - .map(extractDirectiveDef) : - null; - def.pipeDefs = pipeTypes ? - () => (typeof pipeTypes === 'function' ? pipeTypes() : pipeTypes).map(extractPipeDef) : - null; - return def; - }); -} -/** - * Generated next to NgModules to monkey-patch directive and pipe references onto a component's - * definition, when generating a direct reference in the component file would otherwise create an - * import cycle. - * - * See [this explanation](https://hackmd.io/Odw80D0pR6yfsOjg_7XCJg?view) for more details. - * - * @codeGenApi - */ -function ɵɵsetComponentScope(type, directives, pipes) { - const def = type.ɵcmp; - def.directiveDefs = () => directives.map(extractDirectiveDef); - def.pipeDefs = () => pipes.map(extractPipeDef); -} -function extractDirectiveDef(type) { - const def = getComponentDef(type) || getDirectiveDef(type); - if (ngDevMode && !def) { - throw new Error(`'${type.name}' is neither 'ComponentType' or 'DirectiveType'.`); - } - return def; -} -function extractPipeDef(type) { - const def = getPipeDef(type); - if (ngDevMode && !def) { - throw new Error(`'${type.name}' is not a 'PipeType'.`); - } - return def; -} -const autoRegisterModuleById = {}; -/** - * @codeGenApi - */ -function ɵɵdefineNgModule(def) { - const res = { - type: def.type, - bootstrap: def.bootstrap || EMPTY_ARRAY$1, - declarations: def.declarations || EMPTY_ARRAY$1, - imports: def.imports || EMPTY_ARRAY$1, - exports: def.exports || EMPTY_ARRAY$1, - transitiveCompileScopes: null, - schemas: def.schemas || null, - id: def.id || null, - }; - if (def.id != null) { - noSideEffects(() => { - autoRegisterModuleById[def.id] = def.type; - }); - } - return 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 - */ -function ɵɵsetNgModuleScope(type, scope) { - return noSideEffects(() => { - const ngModuleDef = getNgModuleDef(type, true); - ngModuleDef.declarations = scope.declarations || EMPTY_ARRAY$1; - ngModuleDef.imports = scope.imports || EMPTY_ARRAY$1; - ngModuleDef.exports = scope.exports || EMPTY_ARRAY$1; - }); -} -/** - * 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', - * } - * ``` - * - - */ -function invertObject(obj, secondary) { - if (obj == null) - return EMPTY_OBJ; - const newLookup = {}; - for (const minifiedKey in obj) { - if (obj.hasOwnProperty(minifiedKey)) { - let publicName = obj[minifiedKey]; - let declaredName = publicName; - if (Array.isArray(publicName)) { - declaredName = publicName[1]; - publicName = publicName[0]; - } - newLookup[publicName] = minifiedKey; - if (secondary) { - (secondary[publicName] = 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 - */ -const ɵɵdefineDirective = ɵɵdefineComponent; -/** - * Create a pipe definition object. - * - * # Example - * ``` - * class MyPipe implements PipeTransform { - * // Generated by Angular Template Compiler - * static ɵpipe = definePipe({ - * ... - * }); - * } - * ``` - * @param pipeDef Pipe definition generated by the compiler - * - * @codeGenApi - */ -function ɵɵdefinePipe(pipeDef) { - return { - 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 from 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. - */ -function getComponentDef(type) { - return type[NG_COMP_DEF] || null; -} -function getDirectiveDef(type) { - return type[NG_DIR_DEF] || null; -} -function getPipeDef(type) { - return type[NG_PIPE_DEF] || null; -} -function getNgModuleDef(type, throwNotFound) { - const ngModuleDef = type[NG_MOD_DEF] || null; - if (!ngModuleDef && throwNotFound === true) { - throw new Error(`Type ${stringify(type)} does not have 'ɵmod' property.`); - } - return ngModuleDef; -} -function getNgLocaleIdDef(type) { - return type[NG_LOC_ID_DEF] || null; -} -/** - * @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 - */ -// 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. -const HOST = 0; -const TVIEW = 1; -const FLAGS = 2; -const PARENT = 3; -const NEXT = 4; -const TRANSPLANTED_VIEWS_TO_REFRESH = 5; -const T_HOST = 6; -const CLEANUP = 7; -const CONTEXT = 8; -const INJECTOR = 9; -const RENDERER_FACTORY = 10; -const RENDERER = 11; -const SANITIZER = 12; -const CHILD_HEAD = 13; -const CHILD_TAIL = 14; -// FIXME(misko): Investigate if the three declarations aren't all same thing. -const DECLARATION_VIEW = 15; -const DECLARATION_COMPONENT_VIEW = 16; -const DECLARATION_LCONTAINER = 17; -const PREORDER_HOOK_FLAGS = 18; -const QUERIES = 19; -/** - * Size of LView's header. Necessary to adjust for it when setting slots. - * - * IMPORTANT: `HEADER_OFFSET` should only be referred to the in the `ɵɵ*` instructions to translate - * instruction index into `LView` index. All other indexes should be in the `LView` index space and - * there should be no need to refer to `HEADER_OFFSET` anywhere else. - */ -const HEADER_OFFSET = 20; -/** - * Converts `TViewType` into human readable text. - * Make sure this matches with `TViewType` - */ -const TViewTypeAsString = [ - 'Root', - 'Component', - 'Embedded', -]; -// Note: This hack is necessary so we don't erroneously get a circular dependency -// failure based on types. -const unusedValueExportToPlacateAjd = 1; -/** - * @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 - */ -/** - * 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`. - */ -const 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. - */ -/** - * 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 `refreshEmbeddedViews`. But when set we still need to verify - * that the `MOVED_VIEWS` are transplanted and on-push. - */ -const HAS_TRANSPLANTED_VIEWS = 2; -// PARENT, NEXT, TRANSPLANTED_VIEWS_TO_REFRESH are indices 3, 4, and 5 -// As we already have these constants in LView, we don't need to re-create them. -// T_HOST is index 6 -// We already have this constants in LView, we don't need to re-create it. -const NATIVE = 7; -const VIEW_REFS = 8; -const MOVED_VIEWS = 9; -/** - * 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. - */ -const CONTAINER_HEADER_OFFSET = 10; -// Note: This hack is necessary so we don't erroneously get a circular dependency -// failure based on types. -const unusedValueExportToPlacateAjd$1 = 1; -/** - * @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 - */ -/** - * True if `value` is `LView`. - * @param value wrapped value of `RNode`, `LView`, `LContainer` - */ -function isLView(value) { - return Array.isArray(value) && typeof value[TYPE] === 'object'; -} -/** - * True if `value` is `LContainer`. - * @param value wrapped value of `RNode`, `LView`, `LContainer` - */ -function isLContainer(value) { - return Array.isArray(value) && value[TYPE] === true; -} -function isContentQueryHost(tNode) { - return (tNode.flags & 8 /* hasContentQuery */) !== 0; -} -function isComponentHost(tNode) { - return (tNode.flags & 2 /* isComponentHost */) === 2 /* isComponentHost */; -} -function isDirectiveHost(tNode) { - return (tNode.flags & 1 /* isDirectiveHost */) === 1 /* isDirectiveHost */; -} -function isComponentDef(def) { - return def.template !== null; -} -function isRootView(target) { - return (target[FLAGS] & 512 /* IsRoot */) !== 0; -} -/** - * @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 - */ -// [Assert functions do not constraint type when they are guarded by a truthy -// expression.](https://github.com/microsoft/TypeScript/issues/37295) -function assertTNodeForLView(tNode, lView) { - assertTNodeForTView(tNode, lView[TVIEW]); -} -function assertTNodeForTView(tNode, tView) { - assertTNode(tNode); - tNode.hasOwnProperty('tView_') && - assertEqual(tNode.tView_, tView, 'This TNode does not belong to this TView.'); -} -function assertTNode(tNode) { - assertDefined(tNode, 'TNode must be defined'); - if (!(tNode && typeof tNode === 'object' && tNode.hasOwnProperty('directiveStylingLast'))) { - throwError('Not of type TNode, got: ' + tNode); - } -} -function assertTIcu(tIcu) { - assertDefined(tIcu, 'Expected TIcu to be defined'); - if (!(typeof tIcu.currentCaseLViewIndex === 'number')) { - throwError('Object is not of TIcu type.'); - } -} -function assertComponentType(actual, msg = 'Type passed in is not ComponentType, it does not have \'ɵcmp\' property.') { - if (!getComponentDef(actual)) { - throwError(msg); - } -} -function assertNgModuleType(actual, msg = 'Type passed in is not NgModuleType, it does not have \'ɵmod\' property.') { - if (!getNgModuleDef(actual)) { - throwError(msg); - } -} -function assertCurrentTNodeIsParent(isParent) { - assertEqual(isParent, true, 'currentTNode should be a parent'); -} -function assertHasParent(tNode) { - assertDefined(tNode, 'currentTNode should exist!'); - assertDefined(tNode.parent, 'currentTNode should have a parent'); -} -function assertDataNext(lView, index, arr) { - if (arr == null) - arr = lView; - assertEqual(arr.length, index, `index ${index} expected to be at the end of arr (length ${arr.length})`); -} -function assertLContainer(value) { - assertDefined(value, 'LContainer must be defined'); - assertEqual(isLContainer(value), true, 'Expecting LContainer'); -} -function assertLViewOrUndefined(value) { - value && assertEqual(isLView(value), true, 'Expecting LView or undefined or null'); -} -function assertLView(value) { - assertDefined(value, 'LView must be defined'); - assertEqual(isLView(value), true, 'Expecting LView'); -} -function assertFirstCreatePass(tView, errMessage) { - assertEqual(tView.firstCreatePass, true, errMessage || 'Should only be called in first create pass.'); -} -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. - */ -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.`); - } -} -function assertIndexInDeclRange(lView, index) { - const tView = lView[1]; - assertBetween(HEADER_OFFSET, tView.bindingStartIndex, index); -} -function assertIndexInVarsRange(lView, index) { - const tView = lView[1]; - assertBetween(tView.bindingStartIndex, tView.expandoStartIndex, index); -} -function assertIndexInExpandoRange(lView, index) { - const tView = lView[1]; - assertBetween(tView.expandoStartIndex, lView.length, index); -} -function assertBetween(lower, upper, index) { - if (!(lower <= index && index < upper)) { - throwError(`Index out of range (expecting ${lower} <= ${index} < ${upper})`); - } -} -function assertProjectionSlots(lView, errMessage) { - assertDefined(lView[DECLARATION_COMPONENT_VIEW], 'Component views should exist.'); - assertDefined(lView[DECLARATION_COMPONENT_VIEW][T_HOST].projection, errMessage || - 'Components with projection nodes () must have projection slots defined.'); -} -function assertParentView(lView, errMessage) { - assertDefined(lView, errMessage || 'Component views should always have a parent view (component\'s host view)'); -} -/** - * This is a basic sanity check that the `injectorIndex` seems to point to what looks like a - * NodeInjector data structure. - * - * @param lView `LView` which should be checked. - * @param injectorIndex index into the `LView` where the `NodeInjector` is expected. - */ -function assertNodeInjector(lView, injectorIndex) { - assertIndexInExpandoRange(lView, injectorIndex); - assertIndexInExpandoRange(lView, injectorIndex + 8 /* PARENT */); - assertNumber(lView[injectorIndex + 0], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 1], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 2], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 3], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 4], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 5], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 6], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 7], 'injectorIndex should point to a bloom filter'); - assertNumber(lView[injectorIndex + 8 /* PARENT */], 'injectorIndex should point to parent injector'); -} -/** - * @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 getFactoryDef(type, throwNotFound) { - const hasFactoryDef = type.hasOwnProperty(NG_FACTORY_DEF); - if (!hasFactoryDef && throwNotFound === true && ngDevMode) { - throw new Error(`Type ${stringify(type)} does not have 'ɵfac' property.`); - } - return hasFactoryDef ? type[NG_FACTORY_DEF] : null; -} -/** - * @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 - */ -/** - * 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 - */ -class SimpleChange { - constructor(previousValue, currentValue, firstChange) { - this.previousValue = previousValue; - this.currentValue = currentValue; - this.firstChange = firstChange; - } - /** - * Check whether the new value is the first value assigned. - */ - isFirstChange() { - return this.firstChange; - } -} -/** - * @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 - */ -/** - * 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 - */ -function ɵɵNgOnChangesFeature() { - return NgOnChangesFeatureImpl; -} -function NgOnChangesFeatureImpl(definition) { - if (definition.type.prototype.ngOnChanges) { - definition.setInput = ngOnChangesSetInput; - } - return rememberChangeHistoryAndInvokeOnChangesHook; -} -// This option ensures that the ngOnChanges lifecycle hook will be inherited -// from superclasses (in InheritDefinitionFeature). -/** @nocollapse */ -// tslint:disable-next-line:no-toplevel-property-access -ɵɵNgOnChangesFeature.ngInherit = true; -/** - * This is a synthetic lifecycle hook which gets inserted into `TView.preOrderHooks` to simulate - * `ngOnChanges`. - * - * The hook reads the `NgSimpleChangesStore` data from the component instance and if changes are - * found it invokes `ngOnChanges` on the component instance. - * - * @param this Component instance. Because this function gets inserted into `TView.preOrderHooks`, - * it is guaranteed to be called with component instance. - */ -function rememberChangeHistoryAndInvokeOnChangesHook() { - const simpleChangesStore = getSimpleChangesStore(this); - const current = simpleChangesStore === null || simpleChangesStore === void 0 ? void 0 : simpleChangesStore.current; - if (current) { - const previous = simpleChangesStore.previous; - if (previous === EMPTY_OBJ) { - 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 (let key in current) { - previous[key] = current[key]; - } - } - simpleChangesStore.current = null; - this.ngOnChanges(current); - } -} -function ngOnChangesSetInput(instance, value, publicName, privateName) { - const simpleChangesStore = getSimpleChangesStore(instance) || - setSimpleChangesStore(instance, { previous: EMPTY_OBJ, current: null }); - const current = simpleChangesStore.current || (simpleChangesStore.current = {}); - const previous = simpleChangesStore.previous; - const declaredName = this.declaredInputs[publicName]; - const previousChange = previous[declaredName]; - current[declaredName] = new SimpleChange(previousChange && previousChange.currentValue, value, previous === EMPTY_OBJ); - instance[privateName] = value; -} -const SIMPLE_CHANGES_STORE = '__ngSimpleChanges__'; -function getSimpleChangesStore(instance) { - return instance[SIMPLE_CHANGES_STORE] || null; -} -function setSimpleChangesStore(instance, store) { - return instance[SIMPLE_CHANGES_STORE] = store; -} -/** - * @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 - */ -let profilerCallback = null; -/** - * Sets the callback function which will be invoked before and after performing certain actions at - * runtime (for example, before and after running change detection). - * - * Warning: this function is *INTERNAL* and should not be relied upon in application's code. - * The contract of the function might be changed in any release and/or the function can be removed - * completely. - * - * @param profiler function provided by the caller or null value to disable profiling. - */ -const setProfiler = (profiler) => { - profilerCallback = profiler; -}; -/** - * Profiler function which wraps user code executed by the runtime. - * - * @param event ProfilerEvent corresponding to the execution context - * @param instance component instance - * @param hookOrListener lifecycle hook function or output listener. The value depends on the - * execution context - * @returns - */ -const profiler = function (event, instance, hookOrListener) { - if (profilerCallback != null /* both `null` and `undefined` */) { - profilerCallback(event, instance, hookOrListener); - } -}; -/** - * @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 - */ -const SVG_NAMESPACE = 'http://www.w3.org/2000/svg'; -const MATH_ML_NAMESPACE = 'http://www.w3.org/1998/MathML/'; -/** - * @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 - */ -/** - * This property will be monkey-patched on elements, components and directives - */ -const MONKEY_PATCH_KEY_NAME = '__ngContext__'; -/** - * @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 - */ -/** - * 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. - */ -let 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. - */ -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. - */ -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 undefined; -} -/** - * @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: cleanup once the code is merged in angular/angular -var RendererStyleFlags3 = /*@__PURE__*/ (function (RendererStyleFlags3) { - RendererStyleFlags3[RendererStyleFlags3["Important"] = 1] = "Important"; - RendererStyleFlags3[RendererStyleFlags3["DashCase"] = 2] = "DashCase"; - return RendererStyleFlags3; -})({}); -/** Returns whether the `renderer` is a `ProceduralRenderer3` */ -function isProceduralRenderer(renderer) { - return !!(renderer.listen); -} -const ɵ0 = (hostElement, rendererType) => { - return getDocument(); -}; -const domRendererFactory3 = { - createRenderer: ɵ0 -}; -// Note: This hack is necessary so we don't erroneously get a circular dependency -// failure based on types. -const unusedValueExportToPlacateAjd$2 = 1; -/** - * @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 - */ -/** - * 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` - */ -function unwrapRNode(value) { - while (Array.isArray(value)) { - value = value[HOST]; - } - return value; -} -/** - * Returns `LView` or `null` if not found. - * @param value wrapped value of `RNode`, `LView`, `LContainer` - */ -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 value; - value = value[HOST]; - } - return null; -} -/** - * Returns `LContainer` or `null` if not found. - * @param value wrapped value of `RNode`, `LView`, `LContainer` - */ -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 value; - value = value[HOST]; - } - return null; -} -/** - * Retrieves an element value from the provided `viewData`, by unwrapping - * from any containers, component views, or style contexts. - */ -function getNativeByIndex(index, lView) { - ngDevMode && assertIndexInRange(lView, index); - ngDevMode && assertGreaterThanOrEqual(index, HEADER_OFFSET, 'Expected to be past HEADER_OFFSET'); - return unwrapRNode(lView[index]); -} -/** - * 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 - */ -function getNativeByTNode(tNode, lView) { - ngDevMode && assertTNodeForLView(tNode, lView); - ngDevMode && assertIndexInRange(lView, tNode.index); - const 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 - */ -function getNativeByTNodeOrNull(tNode, lView) { - const index = tNode === null ? -1 : tNode.index; - if (index !== -1) { - ngDevMode && assertTNodeForLView(tNode, lView); - const node = unwrapRNode(lView[index]); - ngDevMode && node !== null && !isProceduralRenderer(lView[RENDERER]) && assertDomNode(node); - return node; - } - return null; -} -// fixme(misko): The return Type should be `TNode|null` -function getTNode(tView, index) { - ngDevMode && assertGreaterThan(index, -1, 'wrong index for TNode'); - ngDevMode && assertLessThan(index, tView.data.length, 'wrong index for TNode'); - const tNode = tView.data[index]; - ngDevMode && tNode !== null && assertTNode(tNode); - return tNode; -} -/** Retrieves a value from any `LView` or `TData`. */ -function load(view, index) { - ngDevMode && assertIndexInRange(view, index); - return view[index]; -} -function getComponentLViewByIndex(nodeIndex, hostView) { - // Could be an LView or an LContainer. If LContainer, unwrap to find LView. - ngDevMode && assertIndexInRange(hostView, nodeIndex); - const slotValue = hostView[nodeIndex]; - const 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). - */ -function readPatchedData(target) { - ngDevMode && assertDefined(target, 'Target expected'); - return target[MONKEY_PATCH_KEY_NAME] || null; -} -function readPatchedLView(target) { - const value = readPatchedData(target); - if (value) { - return Array.isArray(value) ? value : value.lView; - } - return null; -} -/** Checks whether a given view is in creation mode */ -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. - */ -function viewAttachedToChangeDetector(view) { - return (view[FLAGS] & 128 /* Attached */) === 128 /* Attached */; -} -/** Returns a boolean for whether the view is attached to a container. */ -function viewAttachedToContainer(view) { - return isLContainer(view[PARENT]); -} -function getConstant(consts, index) { - if (index === null || index === undefined) - return null; - ngDevMode && assertIndexInRange(consts, index); - return consts[index]; -} -/** - * Resets the pre-order hook flags of the view. - * @param lView the LView on which the flags are reset - */ -function resetPreOrderHookFlags(lView) { - lView[PREORDER_HOOK_FLAGS] = 0; -} -/** - * Updates the `TRANSPLANTED_VIEWS_TO_REFRESH` counter on the `LContainer` as well as the parents - * whose - * 1. counter goes from 0 to 1, indicating that there is a new child that has a view to refresh - * or - * 2. counter goes from 1 to 0, indicating there are no more descendant views to refresh - */ -function updateTransplantedViewCount(lContainer, amount) { - lContainer[TRANSPLANTED_VIEWS_TO_REFRESH] += amount; - let viewOrContainer = lContainer; - let parent = lContainer[PARENT]; - while (parent !== null && - ((amount === 1 && viewOrContainer[TRANSPLANTED_VIEWS_TO_REFRESH] === 1) || - (amount === -1 && viewOrContainer[TRANSPLANTED_VIEWS_TO_REFRESH] === 0))) { - parent[TRANSPLANTED_VIEWS_TO_REFRESH] += amount; - viewOrContainer = parent; - parent = parent[PARENT]; - } -} -/** - * @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 - */ -const instructionState = { - lFrame: /*@__PURE__*/ createLFrame(null), - bindingsEnabled: true, - isInCheckNoChangesMode: false, -}; -/** - * Returns true if the instruction state stack is empty. - * - * Intended to be called from tests only (tree shaken otherwise). - */ -function specOnlyIsInstructionStateEmpty() { - return instructionState.lFrame.parent === null; -} -function getElementDepthCount() { - return instructionState.lFrame.elementDepthCount; -} -function increaseElementDepthCount() { - instructionState.lFrame.elementDepthCount++; -} -function decreaseElementDepthCount() { - instructionState.lFrame.elementDepthCount--; -} -function getBindingsEnabled() { - return instructionState.bindingsEnabled; -} -/** - * Enables directive matching on elements. - * - * * Example: - * ``` - * - * Should match component / directive. - * - *
- * - * - * Should not match component / directive because we are in ngNonBindable. - * - * - *
- * ``` - * - * @codeGenApi - */ -function ɵɵenableBindings() { - instructionState.bindingsEnabled = true; -} -/** - * Disables directive matching on element. - * - * * Example: - * ``` - * - * Should match component / directive. - * - *
- * - * - * Should not match component / directive because we are in ngNonBindable. - * - * - *
- * ``` - * - * @codeGenApi - */ -function ɵɵdisableBindings() { - instructionState.bindingsEnabled = false; -} -/** - * Return the current `LView`. - */ -function getLView() { - return instructionState.lFrame.lView; -} -/** - * Return the current `TView`. - */ -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. - * - * @param viewToRestore The OpaqueViewState instance to restore. - * - * @codeGenApi - */ -function ɵɵrestoreView(viewToRestore) { - instructionState.lFrame.contextLView = viewToRestore; -} -function getCurrentTNode() { - let currentTNode = getCurrentTNodePlaceholderOk(); - while (currentTNode !== null && currentTNode.type === 64 /* Placeholder */) { - currentTNode = currentTNode.parent; - } - return currentTNode; -} -function getCurrentTNodePlaceholderOk() { - return instructionState.lFrame.currentTNode; -} -function getCurrentParentTNode() { - const lFrame = instructionState.lFrame; - const currentTNode = lFrame.currentTNode; - return lFrame.isParent ? currentTNode : currentTNode.parent; -} -function setCurrentTNode(tNode, isParent) { - ngDevMode && tNode && assertTNodeForTView(tNode, instructionState.lFrame.tView); - const lFrame = instructionState.lFrame; - lFrame.currentTNode = tNode; - lFrame.isParent = isParent; -} -function isCurrentTNodeParent() { - return instructionState.lFrame.isParent; -} -function setCurrentTNodeAsNotParent() { - instructionState.lFrame.isParent = false; -} -function setCurrentTNodeAsParent() { - instructionState.lFrame.isParent = true; -} -function getContextLView() { - return instructionState.lFrame.contextLView; -} -function isInCheckNoChangesMode() { - // TODO(misko): remove this from the LView since it is ngDevMode=true mode only. - return instructionState.isInCheckNoChangesMode; -} -function setIsInCheckNoChangesMode(mode) { - instructionState.isInCheckNoChangesMode = mode; -} -// top level variables should not be exported for performance reasons (PERF_NOTES.md) -function getBindingRoot() { - const lFrame = instructionState.lFrame; - let index = lFrame.bindingRootIndex; - if (index === -1) { - index = lFrame.bindingRootIndex = lFrame.tView.bindingStartIndex; - } - return index; -} -function getBindingIndex() { - return instructionState.lFrame.bindingIndex; -} -function setBindingIndex(value) { - return instructionState.lFrame.bindingIndex = value; -} -function nextBindingIndex() { - return instructionState.lFrame.bindingIndex++; -} -function incrementBindingIndex(count) { - const lFrame = instructionState.lFrame; - const index = lFrame.bindingIndex; - lFrame.bindingIndex = lFrame.bindingIndex + count; - return index; -} -function isInI18nBlock() { - return instructionState.lFrame.inI18n; -} -function setInI18nBlock(isInI18nBlock) { - instructionState.lFrame.inI18n = isInI18nBlock; -} -/** - * 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. - */ -function setBindingRootForHostBindings(bindingRootIndex, currentDirectiveIndex) { - const 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. - */ -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. - */ -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. - */ -function getCurrentDirectiveDef(tData) { - const currentDirectiveIndex = instructionState.lFrame.currentDirectiveIndex; - return currentDirectiveIndex === -1 ? null : tData[currentDirectiveIndex]; -} -function getCurrentQueryIndex() { - return instructionState.lFrame.currentQueryIndex; -} -function setCurrentQueryIndex(value) { - instructionState.lFrame.currentQueryIndex = value; -} -/** - * Returns a `TNode` of the location where the current `LView` is declared at. - * - * @param lView an `LView` that we want to find parent `TNode` for. - */ -function getDeclarationTNode(lView) { - const tView = lView[TVIEW]; - // Return the declaration parent for embedded views - if (tView.type === 2 /* Embedded */) { - ngDevMode && assertDefined(tView.declTNode, 'Embedded TNodes should have declaration parents.'); - return tView.declTNode; - } - // Components don't have `TView.declTNode` because each instance of component could be - // inserted in different location, hence `TView.declTNode` is meaningless. - // Falling back to `T_HOST` in case we cross component boundary. - if (tView.type === 1 /* Component */) { - return lView[T_HOST]; - } - // Remaining TNode type is `TViewType.Root` which doesn't have a parent TNode. - return null; -} -/** - * This is a light weight version of the `enterView` which is needed by the DI system. - * - * @param lView `LView` location of the DI context. - * @param tNode `TNode` for DI context - * @param flags DI context flags. if `SkipSelf` flag is set than we walk up the declaration - * tree from `tNode` until we find parent declared `TElementNode`. - * @returns `true` if we have successfully entered DI associated with `tNode` (or with declared - * `TNode` if `flags` has `SkipSelf`). Failing to enter DI implies that no associated - * `NodeInjector` can be found and we should instead use `ModuleInjector`. - * - If `true` than this call must be fallowed by `leaveDI` - * - If `false` than this call failed and we should NOT call `leaveDI` - */ -function enterDI(lView, tNode, flags) { - ngDevMode && assertLViewOrUndefined(lView); - if (flags & InjectFlags.SkipSelf) { - ngDevMode && assertTNodeForTView(tNode, lView[TVIEW]); - let parentTNode = tNode; - let parentLView = lView; - while (true) { - ngDevMode && assertDefined(parentTNode, 'Parent TNode should be defined'); - parentTNode = parentTNode.parent; - if (parentTNode === null && !(flags & InjectFlags.Host)) { - parentTNode = getDeclarationTNode(parentLView); - if (parentTNode === null) - break; - // In this case, a parent exists and is definitely an element. So it will definitely - // have an existing lView as the declaration view, which is why we can assume it's defined. - ngDevMode && assertDefined(parentLView, 'Parent LView should be defined'); - parentLView = parentLView[DECLARATION_VIEW]; - // In Ivy there are Comment nodes that correspond to ngIf and NgFor embedded directives - // We want to skip those and look only at Elements and ElementContainers to ensure - // we're looking at true parent nodes, and not content or other types. - if (parentTNode.type & (2 /* Element */ | 8 /* ElementContainer */)) { - break; - } - } - else { - break; - } - } - if (parentTNode === null) { - // If we failed to find a parent TNode this means that we should use module injector. - return false; - } - else { - tNode = parentTNode; - lView = parentLView; - } - } - ngDevMode && assertTNodeForLView(tNode, lView); - const lFrame = instructionState.lFrame = allocLFrame(); - lFrame.currentTNode = tNode; - lFrame.lView = lView; - return true; -} -/** - * 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 - * @returns the previously active lView; - */ -function enterView(newView) { - ngDevMode && assertNotEqual(newView[0], newView[1], '????'); - ngDevMode && assertLViewOrUndefined(newView); - const 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, -1, '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.bindingRootIndex, -1, 'Expected clean LFrame'); - assertEqual(newLFrame.currentQueryIndex, 0, 'Expected clean LFrame'); - } - const tView = newView[TVIEW]; - instructionState.lFrame = newLFrame; - ngDevMode && tView.firstChild && assertTNodeForTView(tView.firstChild, tView); - newLFrame.currentTNode = tView.firstChild; - newLFrame.lView = newView; - newLFrame.tView = tView; - newLFrame.contextLView = newView; - newLFrame.bindingIndex = tView.bindingStartIndex; - newLFrame.inI18n = false; -} -/** - * Allocates next free LFrame. This function tries to reuse the `LFrame`s to lower memory pressure. - */ -function allocLFrame() { - const currentLFrame = instructionState.lFrame; - const childLFrame = currentLFrame === null ? null : currentLFrame.child; - const newLFrame = childLFrame === null ? createLFrame(currentLFrame) : childLFrame; - return newLFrame; -} -function createLFrame(parent) { - const lFrame = { - currentTNode: null, - isParent: true, - lView: null, - tView: null, - selectedIndex: -1, - contextLView: null, - elementDepthCount: 0, - currentNamespace: null, - currentDirectiveIndex: -1, - bindingRootIndex: -1, - bindingIndex: -1, - currentQueryIndex: 0, - parent: parent, - child: null, - inI18n: false, - }; - 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 `currentTNode` 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`. - */ -function leaveViewLight() { - const oldLFrame = instructionState.lFrame; - instructionState.lFrame = oldLFrame.parent; - oldLFrame.currentTNode = null; - oldLFrame.lView = 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. - */ -const 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. - */ -function leaveView() { - const oldLFrame = leaveViewLight(); - oldLFrame.isParent = true; - oldLFrame.tView = null; - oldLFrame.selectedIndex = -1; - oldLFrame.contextLView = null; - oldLFrame.elementDepthCount = 0; - oldLFrame.currentDirectiveIndex = -1; - oldLFrame.currentNamespace = null; - oldLFrame.bindingRootIndex = -1; - oldLFrame.bindingIndex = -1; - oldLFrame.currentQueryIndex = 0; -} -function nextContextImpl(level) { - const contextLView = instructionState.lFrame.contextLView = - walkUpViews(level, instructionState.lFrame.contextLView); - return contextLView[CONTEXT]; -} -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 = 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. - */ -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.) - */ -function setSelectedIndex(index) { - ngDevMode && index !== -1 && - assertGreaterThanOrEqual(index, HEADER_OFFSET, 'Index must be past HEADER_OFFSET (or -1).'); - ngDevMode && - assertLessThan(index, instructionState.lFrame.lView.length, 'Can\'t set index passed end of LView'); - instructionState.lFrame.selectedIndex = index; -} -/** - * Gets the `tNode` that represents currently selected element. - */ -function getSelectedTNode() { - const 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 - */ -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 - */ -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 - */ -function ɵɵnamespaceHTML() { - namespaceHTMLInternal(); -} -/** - * Sets the namespace used to create elements to `null`, which forces element creation to use - * `createElement` rather than `createElementNS`. - */ -function namespaceHTMLInternal() { - instructionState.lFrame.currentNamespace = null; -} -function getNamespace() { - return instructionState.lFrame.currentNamespace; -} -/** - * @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 - */ -/** - * 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 - */ -function registerPreOrderHooks(directiveIndex, directiveDef, tView) { - ngDevMode && assertFirstCreatePass(tView); - const { ngOnChanges, ngOnInit, ngDoCheck } = directiveDef.type.prototype; - if (ngOnChanges) { - const wrappedOnChanges = NgOnChangesFeatureImpl(directiveDef); - (tView.preOrderHooks || (tView.preOrderHooks = [])).push(directiveIndex, wrappedOnChanges); - (tView.preOrderCheckHooks || (tView.preOrderCheckHooks = [])) - .push(directiveIndex, wrappedOnChanges); - } - if (ngOnInit) { - (tView.preOrderHooks || (tView.preOrderHooks = [])).push(0 - directiveIndex, ngOnInit); - } - if (ngDoCheck) { - (tView.preOrderHooks || (tView.preOrderHooks = [])).push(directiveIndex, ngDoCheck); - (tView.preOrderCheckHooks || (tView.preOrderCheckHooks = [])).push(directiveIndex, ngDoCheck); - } -} -/** - * - * 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 - */ -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 (let i = tNode.directiveStart, end = tNode.directiveEnd; i < end; i++) { - const directiveDef = tView.data[i]; - ngDevMode && assertDefined(directiveDef, 'Expecting DirectiveDef'); - const lifecycleHooks = directiveDef.type.prototype; - const { ngAfterContentInit, ngAfterContentChecked, ngAfterViewInit, ngAfterViewChecked, ngOnDestroy } = lifecycleHooks; - if (ngAfterContentInit) { - (tView.contentHooks || (tView.contentHooks = [])).push(-i, ngAfterContentInit); - } - if (ngAfterContentChecked) { - (tView.contentHooks || (tView.contentHooks = [])).push(i, ngAfterContentChecked); - (tView.contentCheckHooks || (tView.contentCheckHooks = [])).push(i, ngAfterContentChecked); - } - if (ngAfterViewInit) { - (tView.viewHooks || (tView.viewHooks = [])).push(-i, ngAfterViewInit); - } - if (ngAfterViewChecked) { - (tView.viewHooks || (tView.viewHooks = [])).push(i, ngAfterViewChecked); - (tView.viewCheckHooks || (tView.viewCheckHooks = [])).push(i, ngAfterViewChecked); - } - if (ngOnDestroy != null) { - (tView.destroyHooks || (tView.destroyHooks = [])).push(i, ngOnDestroy); - } - } -} -/** - * 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)) - */ -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)) - */ -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); - } -} -function incrementInitPhaseFlags(lView, initPhase) { - ngDevMode && - assertNotEqual(initPhase, 3 /* InitPhaseCompleted */, 'Init hooks phase should not be incremented after all init hooks have been run.'); - let flags = lView[FLAGS]; - if ((flags & 3 /* InitPhaseStateMask */) === initPhase) { - flags &= 2047 /* 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 initPhaseState the current state of the init phase - * @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)) - */ -function callHooks(currentView, arr, initPhase, currentNodeIndex) { - ngDevMode && - assertEqual(isInCheckNoChangesMode(), false, 'Hooks should never be run when in check no changes mode.'); - const startIndex = currentNodeIndex !== undefined ? - (currentView[PREORDER_HOOK_FLAGS] & 65535 /* IndexOfTheNextPreOrderHookMaskMask */) : - 0; - const nodeIndexLimit = currentNodeIndex != null ? currentNodeIndex : -1; - const max = arr.length - 1; // Stop the loop at length - 1, because we look for the hook at i + 1 - let lastNodeIndexFound = 0; - for (let i = startIndex; i < max; i++) { - const hook = arr[i + 1]; - if (typeof hook === 'number') { - lastNodeIndexFound = arr[i]; - if (currentNodeIndex != null && lastNodeIndexFound >= currentNodeIndex) { - break; - } - } - else { - const 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 initPhaseState the current state of the init phase - * @param arr The array in which the hooks are found - * @param i The current index within the hook data array - */ -function callHook(currentView, initPhase, arr, i) { - const isInitHook = arr[i] < 0; - const hook = arr[i + 1]; - const directiveIndex = isInitHook ? -arr[i] : arr[i]; - const directive = currentView[directiveIndex]; - if (isInitHook) { - const indexWithintInitPhase = currentView[FLAGS] >> 11 /* 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] += 2048 /* IndexWithinInitPhaseIncrementer */; - profiler(4 /* LifecycleHookStart */, directive, hook); - try { - hook.call(directive); - } - finally { - profiler(5 /* LifecycleHookEnd */, directive, hook); - } - } - } - else { - profiler(4 /* LifecycleHookStart */, directive, hook); - try { - hook.call(directive); - } - finally { - profiler(5 /* LifecycleHookEnd */, directive, hook); - } - } -} -/** - * @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 - */ -const NO_PARENT_INJECTOR = -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 { - * - * // 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 { - * - * // 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`. - */ -class NodeInjectorFactory { - constructor( - /** - * Factory to invoke in order to create a new instance. - */ - factory, - /** - * Set to `true` if the token is declared in `viewProviders` (or if it is component). - */ - isViewProvider, injectImplementation) { - 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; - ngDevMode && assertDefined(factory, 'Factory not specified'); - ngDevMode && assertEqual(typeof factory, 'function', 'Expected factory function.'); - this.canSeeViewProviders = isViewProvider; - this.injectImpl = injectImplementation; - } -} -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. -const unusedValueExportToPlacateAjd$3 = 1; -/** - * Converts `TNodeType` into human readable text. - * Make sure this matches with `TNodeType` - */ -function toTNodeTypeAsString(tNodeType) { - let text = ''; - (tNodeType & 1 /* Text */) && (text += '|Text'); - (tNodeType & 2 /* Element */) && (text += '|Element'); - (tNodeType & 4 /* Container */) && (text += '|Container'); - (tNodeType & 8 /* ElementContainer */) && (text += '|ElementContainer'); - (tNodeType & 16 /* Projection */) && (text += '|Projection'); - (tNodeType & 32 /* Icu */) && (text += '|IcuContainer'); - (tNodeType & 64 /* Placeholder */) && (text += '|Placeholder'); - return text.length > 0 ? text.substring(1) : text; -} -// Note: This hack is necessary so we don't erroneously get a circular dependency -// failure based on types. -const unusedValueExportToPlacateAjd$4 = 1; -/** - * Returns `true` if the `TNode` has a directive which has `@Input()` for `class` binding. - * - * ``` - *
- * ``` - * 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 - */ -function hasClassInput(tNode) { - return (tNode.flags & 16 /* hasClassInput */) !== 0; -} -/** - * Returns `true` if the `TNode` has a directive which has `@Input()` for `style` binding. - * - * ``` - *
- * ``` - * 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 - */ -function hasStyleInput(tNode) { - return (tNode.flags & 32 /* hasStyleInput */) !== 0; -} -/** - * @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 assertTNodeType(tNode, expectedTypes, message) { - assertDefined(tNode, 'should be called with a TNode'); - if ((tNode.type & expectedTypes) === 0) { - throwError(message || - `Expected [${toTNodeTypeAsString(expectedTypes)}] but got ${toTNodeTypeAsString(tNode.type)}.`); - } -} -function assertPureTNodeType(type) { - if (!(type === 2 /* Element */ || // - type === 1 /* Text */ || // - type === 4 /* Container */ || // - type === 8 /* ElementContainer */ || // - type === 32 /* Icu */ || // - type === 16 /* Projection */ || // - type === 64 /* Placeholder */)) { - throwError(`Expected TNodeType to have only a single type selected, but got ${toTNodeTypeAsString(type)}.`); - } -} -/** - * 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 - * @returns the index value that was last accessed in the attributes array - */ -function setUpAttributes(renderer, native, attrs) { - const isProc = isProceduralRenderer(renderer); - let i = 0; - while (i < attrs.length) { - const 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++; - const namespaceURI = attrs[i++]; - const attrName = attrs[i++]; - const attrVal = attrs[i++]; - ngDevMode && ngDevMode.rendererSetAttribute++; - isProc ? - renderer.setAttribute(native, attrName, attrVal, namespaceURI) : - native.setAttributeNS(namespaceURI, attrName, attrVal); - } - else { - // attrName is string; - const attrName = value; - const attrVal = attrs[++i]; - // Standard attributes - ngDevMode && ngDevMode.rendererSetAttribute++; - if (isAnimationProp(attrName)) { - if (isProc) { - renderer.setProperty(native, attrName, attrVal); - } - } - else { - isProc ? - renderer.setAttribute(native, attrName, attrVal) : - native.setAttribute(attrName, 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. - * @returns 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 */; -} -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` - */ -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 { - let srcMarker = -1 /* ImplicitAttributes */; - for (let i = 0; i < src.length; i++) { - const 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, item, null, src[++i]); - } - else { - // Case where we have to consume `key1` only. - mergeHostAttribute(dst, srcMarker, 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. - */ -function mergeHostAttribute(dst, marker, key1, key2, value) { - let i = 0; - // Assume that new markers will be inserted at the end. - let markerInsertPosition = dst.length; - // scan until correct type. - if (marker === -1 /* ImplicitAttributes */) { - markerInsertPosition = -1; - } - else { - while (i < dst.length) { - const 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) { - const 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] = 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); - } -} -/** - * @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 - */ -/// Parent Injector Utils /////////////////////////////////////////////////////////////// -function hasParentInjector(parentLocation) { - return parentLocation !== NO_PARENT_INJECTOR; -} -function getParentInjectorIndex(parentLocation) { - ngDevMode && assertNumber(parentLocation, 'Number expected'); - ngDevMode && assertNotEqual(parentLocation, -1, 'Not a valid state.'); - const parentInjectorIndex = parentLocation & 32767 /* InjectorIndexMask */; - ngDevMode && - assertGreaterThan(parentInjectorIndex, HEADER_OFFSET, 'Parent injector must be pointing past HEADER_OFFSET.'); - return parentLocation & 32767 /* InjectorIndexMask */; -} -function getParentInjectorViewOffset(parentLocation) { - return 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 - * @returns The LView instance that contains the parent injector - */ -function getParentInjectorView(location, startView) { - let viewOffset = getParentInjectorViewOffset(location); - let 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 - // tags or inline views, where the parent injector might live many views - // above the child injector. - while (viewOffset > 0) { - parentView = parentView[DECLARATION_VIEW]; - viewOffset--; - } - return parentView; -} -/** - * @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 - */ -/** - * 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'); - * } - * } - * - * ``` - */ -let includeViewProviders = true; -function setIncludeViewProviders(v) { - const 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. - */ -const BLOOM_SIZE = 256; -const BLOOM_MASK = BLOOM_SIZE - 1; -/** - * The number of bits that is represented by a single bloom bucket. JS bit operations are 32 bits, - * so each bucket represents 32 distinct tokens which accounts for log2(32) = 5 bits of a bloom hash - * number. - */ -const BLOOM_BUCKET_BITS = 5; -/** Counter used to generate unique IDs for directives. */ -let 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 - */ -function bloomAdd(injectorIndex, tView, type) { - ngDevMode && assertEqual(tView.firstCreatePass, true, 'expected firstCreatePass to be true'); - let id; - if (typeof type === 'string') { - id = type.charCodeAt(0) || 0; - } - else if (type.hasOwnProperty(NG_ELEMENT_ID)) { - id = type[NG_ELEMENT_ID]; - } - // 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[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. - const bloomHash = 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. - const mask = 1 << bloomHash; - // Each bloom bucket in `tData` represents `BLOOM_BUCKET_BITS` number of bits of `bloomHash`. - // Any bits in `bloomHash` beyond `BLOOM_BUCKET_BITS` indicate the bucket offset that the mask - // should be written to. - tView.data[injectorIndex + (bloomHash >> BLOOM_BUCKET_BITS)] |= mask; -} -/** - * Creates (or gets an existing) injector for a given element or container. - * - * @param tNode for which an injector should be retrieved / created. - * @param lView View where the node is stored - * @returns Node injector - */ -function getOrCreateNodeInjectorForNode(tNode, lView) { - const existingInjectorIndex = getInjectorIndex(tNode, lView); - if (existingInjectorIndex !== -1) { - return existingInjectorIndex; - } - const tView = lView[TVIEW]; - if (tView.firstCreatePass) { - tNode.injectorIndex = lView.length; - insertBloom(tView.data, tNode); // foundation for node bloom - insertBloom(lView, null); // foundation for cumulative bloom - insertBloom(tView.blueprint, null); - } - const parentLoc = getParentInjectorLocation(tNode, lView); - const 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)) { - const parentIndex = getParentInjectorIndex(parentLoc); - const parentLView = getParentInjectorView(parentLoc, lView); - const parentData = 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 (let i = 0; i < 8 /* BLOOM_SIZE */; i++) { - lView[injectorIndex + i] = parentLView[parentIndex + i] | parentData[parentIndex + i]; - } - } - lView[injectorIndex + 8 /* PARENT */] = parentLoc; - return injectorIndex; -} -function insertBloom(arr, footer) { - arr.push(0, 0, 0, 0, 0, 0, 0, 0, footer); -} -function getInjectorIndex(tNode, lView) { - 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 - lView[tNode.injectorIndex + 8 /* PARENT */] === null) { - return -1; - } - else { - ngDevMode && assertIndexInRange(lView, tNode.injectorIndex); - return tNode.injectorIndex; - } -} -/** - * Finds the index of the parent injector, with a view offset if applicable. Used to set the - * parent injector initially. - * - * @returns Returns a number that is the combination of the number of LViews that we have to go up - * to find the LView containing the parent inject AND the index of the injector within that LView. - */ -function getParentInjectorLocation(tNode, lView) { - if (tNode.parent && tNode.parent.injectorIndex !== -1) { - // If we have a parent `TNode` and there is an injector associated with it we are done, because - // the parent injector is within the current `LView`. - return tNode.parent.injectorIndex; // ViewOffset is 0 - } - // When parent injector location is computed it may be outside of the current view. (ie it could - // be pointing to a declared parent location). This variable stores number of declaration parents - // we need to walk up in order to find the parent injector location. - let declarationViewOffset = 0; - let parentTNode = null; - let lViewCursor = lView; - // The parent injector is not in the current `LView`. We will have to walk the declared parent - // `LView` hierarchy and look for it. If we walk of the top, that means that there is no parent - // `NodeInjector`. - while (lViewCursor !== null) { - // First determine the `parentTNode` location. The parent pointer differs based on `TView.type`. - const tView = lViewCursor[TVIEW]; - const tViewType = tView.type; - if (tViewType === 2 /* Embedded */) { - ngDevMode && - assertDefined(tView.declTNode, 'Embedded TNodes should have declaration parents.'); - parentTNode = tView.declTNode; - } - else if (tViewType === 1 /* Component */) { - // Components don't have `TView.declTNode` because each instance of component could be - // inserted in different location, hence `TView.declTNode` is meaningless. - parentTNode = lViewCursor[T_HOST]; - } - else { - ngDevMode && assertEqual(tView.type, 0 /* Root */, 'Root type expected'); - parentTNode = null; - } - if (parentTNode === null) { - // If we have no parent, than we are done. - return NO_PARENT_INJECTOR; - } - ngDevMode && parentTNode && assertTNodeForLView(parentTNode, lViewCursor[DECLARATION_VIEW]); - // Every iteration of the loop requires that we go to the declared parent. - declarationViewOffset++; - lViewCursor = lViewCursor[DECLARATION_VIEW]; - if (parentTNode.injectorIndex !== -1) { - // We found a NodeInjector which points to something. - return (parentTNode.injectorIndex | - (declarationViewOffset << 16 /* ViewOffsetShift */)); - } - } - return NO_PARENT_INJECTOR; -} -/** - * Makes a type or an injection token public to the DI system by adding it to an - * injector's bloom filter. - * - * @param di The node injector in which a directive will be added - * @param token The type or the injection token to be made public - */ -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 - * ``` - * - * ``` - * - * Then factory method generated is: - * ``` - * MyComponent.ɵcmp = defineComponent({ - * factory: () => new MyComponent(injectAttribute('title')) - * ... - * }) - * ``` - * - * @publicApi - */ -function injectAttributeImpl(tNode, attrNameToInject) { - ngDevMode && assertTNodeType(tNode, 12 /* AnyContainer */ | 3 /* AnyRNode */); - ngDevMode && assertDefined(tNode, 'expecting tNode'); - if (attrNameToInject === 'class') { - return tNode.classes; - } - if (attrNameToInject === 'style') { - return tNode.styles; - } - const attrs = tNode.attrs; - if (attrs) { - const attrsLength = attrs.length; - let i = 0; - while (i < attrsLength) { - const 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 attrs[i + 1]; - } - else { - i = i + 2; - } - } - } - return null; -} -function notFoundValueOrThrow(notFoundValue, token, flags) { - if (flags & InjectFlags.Optional) { - return notFoundValue; - } - else { - throwProviderNotFoundError(token, 'NodeInjector'); - } -} -/** - * Returns the value associated to the given token from the ModuleInjector or throws exception - * - * @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` - * @returns the value from the injector or throws an exception - */ -function lookupTokenUsingModuleInjector(lView, token, flags, notFoundValue) { - 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) { - const moduleInjector = lView[INJECTOR]; - // 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) - const 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); - } - } - return notFoundValueOrThrow(notFoundValue, token, flags); -} -/** - * 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. `-1` is reserved for injecting `Injector` (implemented by `NodeInjector`) - * - * @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` - * @returns the value from the injector, `null` when not found, or `notFoundValue` if provided - */ -function getOrCreateInjectable(tNode, lView, token, flags = InjectFlags.Default, notFoundValue) { - if (tNode !== null) { - const 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') { - if (!enterDI(lView, tNode, flags)) { - // Failed to enter DI, try module injector instead. If a token is injected with the @Host - // flag, the module injector is not searched for that token in Ivy. - return (flags & InjectFlags.Host) ? - notFoundValueOrThrow(notFoundValue, token, flags) : - lookupTokenUsingModuleInjector(lView, token, flags, notFoundValue); - } - try { - const value = bloomHash(); - if (value == null && !(flags & InjectFlags.Optional)) { - throwProviderNotFoundError(token); - } - else { - return value; - } - } - finally { - leaveDI(); - } - } - else if (typeof bloomHash === 'number') { - // 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. - let previousTView = null; - let injectorIndex = getInjectorIndex(tNode, lView); - let parentLocation = NO_PARENT_INJECTOR; - let 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 + 8 /* PARENT */]; - if (parentLocation === NO_PARENT_INJECTOR || !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) { - ngDevMode && assertNodeInjector(lView, injectorIndex); - // Check the current injector. If it matches, see if it contains token. - const tView = lView[TVIEW]; - ngDevMode && - assertTNodeForLView(tView.data[injectorIndex + 8 /* TNODE */], lView); - 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. - const instance = searchTokensOnInjector(injectorIndex, lView, token, previousTView, flags, hostTElementNode); - if (instance !== NOT_FOUND) { - return instance; - } - } - parentLocation = lView[injectorIndex + 8 /* PARENT */]; - if (parentLocation !== NO_PARENT_INJECTOR && - shouldSearchParent(flags, lView[TVIEW].data[injectorIndex + 8 /* 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; - } - } - } - } - return lookupTokenUsingModuleInjector(lView, token, flags, notFoundValue); -} -const NOT_FOUND = {}; -function createNodeInjector() { - return new NodeInjector(getCurrentTNode(), getLView()); -} -function searchTokensOnInjector(injectorIndex, lView, token, previousTView, flags, hostTElementNode) { - const currentTView = lView[TVIEW]; - const tNode = currentTView.data[injectorIndex + 8 /* TNODE */]; - // First, we need to determine if view providers can be accessed by the starting element. - // There are two possibilities - const 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 /* AnyRNode */) !== 0)); - // This special case happens when there is a @host on the inject and when we are searching - // on the host element node. - const isHostSpecialCase = (flags & InjectFlags.Host) && hostTElementNode === tNode; - const injectableIdx = locateDirectiveOrProvider(tNode, currentTView, token, canAccessViewProviders, isHostSpecialCase); - if (injectableIdx !== null) { - return getNodeInjectable(lView, currentTView, injectableIdx, tNode); - } - else { - return NOT_FOUND; - } -} -/** - * Searches for the given token among the node's directives and providers. - * - * @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. - * @returns Index of a found directive or provider, or null when none found. - */ -function locateDirectiveOrProvider(tNode, tView, token, canAccessViewProviders, isHostSpecialCase) { - const nodeProviderIndexes = tNode.providerIndexes; - const tInjectables = tView.data; - const injectablesStart = nodeProviderIndexes & 1048575 /* ProvidersStartIndexMask */; - const directivesStart = tNode.directiveStart; - const directiveEnd = tNode.directiveEnd; - const cptViewProvidersCount = nodeProviderIndexes >> 20 /* CptViewProvidersCountShift */; - const startingIndex = canAccessViewProviders ? injectablesStart : injectablesStart + cptViewProvidersCount; - // When the host special case applies, only the viewProviders and the component are visible - const endIndex = isHostSpecialCase ? injectablesStart + cptViewProvidersCount : directiveEnd; - for (let i = startingIndex; i < endIndex; i++) { - const providerTokenOrDef = tInjectables[i]; - if (i < directivesStart && token === providerTokenOrDef || - i >= directivesStart && providerTokenOrDef.type === token) { - return i; - } - } - if (isHostSpecialCase) { - const dirDef = 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. - */ -function getNodeInjectable(lView, tView, index, tNode) { - let value = lView[index]; - const tData = tView.data; - if (isFactory(value)) { - const factory = value; - if (factory.resolving) { - throwCyclicDependencyError(stringifyForError(tData[index])); - } - const previousIncludeViewProviders = setIncludeViewProviders(factory.canSeeViewProviders); - factory.resolving = true; - const previousInjectImplementation = factory.injectImpl ? setInjectImplementation(factory.injectImpl) : null; - const success = enterDI(lView, tNode, InjectFlags.Default); - ngDevMode && - assertEqual(success, true, 'Because flags do not contain \`SkipSelf\' we expect this to always succeed.'); - 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, tData[index], tView); - } - } - finally { - previousInjectImplementation !== null && - 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 - * @returns 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; - } - const tokenId = - // First check with `hasOwnProperty` so we don't get an inherited ID. - token.hasOwnProperty(NG_ELEMENT_ID) ? token[NG_ELEMENT_ID] : undefined; - // Negative token IDs are used for special objects such as `Injector` - if (typeof tokenId === 'number') { - if (tokenId >= 0) { - return tokenId & BLOOM_MASK; - } - else { - ngDevMode && - assertEqual(tokenId, -1 /* Injector */, 'Expecting to get Special Injector Id'); - return createNodeInjector; - } - } - else { - return tokenId; - } -} -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. - const mask = 1 << bloomHash; - // Each bloom bucket in `injectorView` represents `BLOOM_BUCKET_BITS` number of bits of - // `bloomHash`. Any bits in `bloomHash` beyond `BLOOM_BUCKET_BITS` indicate the bucket offset - // that should be used. - const value = injectorView[injectorIndex + (bloomHash >> BLOOM_BUCKET_BITS)]; - // 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 */ -function shouldSearchParent(flags, isFirstHostTNode) { - return !(flags & InjectFlags.Self) && !(flags & InjectFlags.Host && isFirstHostTNode); -} -class NodeInjector { - constructor(_tNode, _lView) { - this._tNode = _tNode; - this._lView = _lView; - } - get(token, notFoundValue) { - return getOrCreateInjectable(this._tNode, this._lView, token, undefined, notFoundValue); - } -} -/** - * @codeGenApi - */ -function ɵɵgetInheritedFactory(type) { - return noSideEffects(() => { - const ownConstructor = type.prototype.constructor; - const ownFactory = ownConstructor[NG_FACTORY_DEF] || getFactoryOf(ownConstructor); - const objectPrototype = Object.prototype; - let parent = Object.getPrototypeOf(type.prototype).constructor; - // Go up the prototype until we hit `Object`. - while (parent && parent !== objectPrototype) { - const factory = parent[NG_FACTORY_DEF] || getFactoryOf(parent); - // If we hit something that has a factory and the factory isn't the same as the type, - // we've found the inherited factory. Note the check that the factory isn't the type's - // own factory is redundant in most cases, but if the user has custom decorators on the - // class, this lookup will start one level down in the prototype chain, causing us to - // find the own factory first and potentially triggering an infinite loop downstream. - if (factory && factory !== ownFactory) { - return factory; - } - parent = Object.getPrototypeOf(parent); - } - // 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 t => new t(); - }); -} -function getFactoryOf(type) { - if (isForwardRef(type)) { - return () => { - const factory = getFactoryOf(resolveForwardRef(type)); - return factory && factory(); - }; - } - return getFactoryDef(type); -} -/** - * @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 - */ -/** - * Facade for the attribute injection from DI. - * - * @codeGenApi - */ -function ɵɵinjectAttribute(attrNameToInject) { - return injectAttributeImpl(getCurrentTNode(), attrNameToInject); -} -/** - * @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 - */ -const ANNOTATIONS = '__annotations__'; -const PARAMETERS = '__parameters__'; -const PROP_METADATA = '__prop__metadata__'; -/** - * @suppress {globalThis} - */ -function makeDecorator(name, props, parentClass, additionalProcessing, typeFn) { - return noSideEffects(() => { - const metaCtor = makeMetadataCtor(props); - function DecoratorFactory(...args) { - if (this instanceof DecoratorFactory) { - metaCtor.call(this, ...args); - return this; - } - const annotationInstance = new DecoratorFactory(...args); - return function TypeDecorator(cls) { - if (typeFn) - typeFn(cls, ...args); - // Use of Object.defineProperty is important since it creates non-enumerable property which - // prevents the property is copied during subclassing. - const 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(...args) { - if (props) { - const values = props(...args); - for (const propName in values) { - this[propName] = values[propName]; - } - } - }; -} -function makeParamDecorator(name, props, parentClass) { - return noSideEffects(() => { - const metaCtor = makeMetadataCtor(props); - function ParamDecoratorFactory(...args) { - if (this instanceof ParamDecoratorFactory) { - metaCtor.apply(this, args); - return this; - } - const annotationInstance = new 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. - const 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(() => { - const metaCtor = makeMetadataCtor(props); - function PropDecoratorFactory(...args) { - if (this instanceof PropDecoratorFactory) { - metaCtor.apply(this, args); - return this; - } - const decoratorInstance = new PropDecoratorFactory(...args); - function PropDecorator(target, name) { - const constructor = target.constructor; - // Use of Object.defineProperty is important because it creates a non-enumerable property - // which prevents the property from being copied during subclassing. - const 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(target, name, ...args); - } - return PropDecorator; - } - if (parentClass) { - PropDecoratorFactory.prototype = Object.create(parentClass.prototype); - } - PropDecoratorFactory.prototype.ngMetadataName = name; - PropDecoratorFactory.annotationCls = PropDecoratorFactory; - return PropDecoratorFactory; - }); -} -/** - * @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 CREATE_ATTRIBUTE_DECORATOR__PRE_R3__() { - return makeParamDecorator('Attribute', (attributeName) => ({ attributeName })); -} -function CREATE_ATTRIBUTE_DECORATOR__POST_R3__() { - return makeParamDecorator('Attribute', (attributeName) => ({ attributeName, __NG_ELEMENT_ID__: () => ɵɵinjectAttribute(attributeName) })); -} -const CREATE_ATTRIBUTE_DECORATOR_IMPL = CREATE_ATTRIBUTE_DECORATOR__POST_R3__; -/** - * Attribute decorator and metadata. - * - * @Annotation - * @publicApi - */ -const Attribute = /*@__PURE__*/ CREATE_ATTRIBUTE_DECORATOR_IMPL(); -/** - * @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 - */ -/** - * 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('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 - */ -class InjectionToken { - constructor(_desc, options) { - this._desc = _desc; - /** @internal */ - this.ngMetadataName = 'InjectionToken'; - this.ɵprov = undefined; - if (typeof options == 'number') { - (typeof ngDevMode === 'undefined' || ngDevMode) && - assertLessThan(options, 0, 'Only negative numbers are supported here'); - // This is a special hack to assign __NG_ELEMENT_ID__ to this instance. - // See `InjectorMarkers` - this.__NG_ELEMENT_ID__ = options; - } - else if (options !== undefined) { - this.ɵprov = ɵɵdefineInjectable({ - token: this, - providedIn: options.providedIn || 'root', - factory: options.factory, - }); - } - } - toString() { - return `InjectionToken ${this._desc}`; - } -} -/** - * @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 - */ -/** - * 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. - */ -const ANALYZE_FOR_ENTRY_COMPONENTS = /*@__PURE__*/ new InjectionToken('AnalyzeForEntryComponents'); -// Stores the default value of `emitDistinctChangesOnly` when the `emitDistinctChangesOnly` is not -// explicitly set. This value will be changed to `true` in v12. -// TODO(misko): switch the default in v12 to `true`. See: packages/compiler/src/core.ts -const emitDistinctChangesOnlyDefaultValue = false; -/** - * Base class for query metadata. - * - * @see `ContentChildren`. - * @see `ContentChild`. - * @see `ViewChildren`. - * @see `ViewChild`. - * - * @publicApi - */ -class Query { -} -const ɵ0$1 = (selector, data = {}) => (Object.assign({ selector, first: false, isViewQuery: false, descendants: false, emitDistinctChangesOnly: emitDistinctChangesOnlyDefaultValue }, data)); -/** - * ContentChildren decorator and metadata. - * - * - * @Annotation - * @publicApi - */ -const ContentChildren = /*@__PURE__*/ makePropDecorator('ContentChildren', ɵ0$1, Query); -const ɵ1 = (selector, data = {}) => (Object.assign({ selector, first: true, isViewQuery: false, descendants: true }, data)); -/** - * ContentChild decorator and metadata. - * - * - * @Annotation - * - * @publicApi - */ -const ContentChild = /*@__PURE__*/ makePropDecorator('ContentChild', ɵ1, Query); -const ɵ2 = (selector, data = {}) => (Object.assign({ selector, first: false, isViewQuery: true, descendants: true, emitDistinctChangesOnly: emitDistinctChangesOnlyDefaultValue }, data)); -/** - * ViewChildren decorator and metadata. - * - * @Annotation - * @publicApi - */ -const ViewChildren = /*@__PURE__*/ makePropDecorator('ViewChildren', ɵ2, Query); -const ɵ3 = (selector, data) => (Object.assign({ selector, first: true, isViewQuery: true, descendants: true }, data)); -/** - * ViewChild decorator and metadata. - * - * @Annotation - * @publicApi - */ -const ViewChild = /*@__PURE__*/ makePropDecorator('ViewChild', ɵ3, Query); -/** - * @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 - */ -var R3ResolvedDependencyType = /*@__PURE__*/ (function (R3ResolvedDependencyType) { - R3ResolvedDependencyType[R3ResolvedDependencyType["Token"] = 0] = "Token"; - R3ResolvedDependencyType[R3ResolvedDependencyType["Attribute"] = 1] = "Attribute"; - R3ResolvedDependencyType[R3ResolvedDependencyType["ChangeDetectorRef"] = 2] = "ChangeDetectorRef"; - R3ResolvedDependencyType[R3ResolvedDependencyType["Invalid"] = 3] = "Invalid"; - return R3ResolvedDependencyType; -})({}); -var R3FactoryTarget = /*@__PURE__*/ (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"; - return R3FactoryTarget; -})({}); -var ViewEncapsulation$1 = /*@__PURE__*/ (function (ViewEncapsulation) { - ViewEncapsulation[ViewEncapsulation["Emulated"] = 0] = "Emulated"; - // Historically the 1 value was for `Native` encapsulation which has been removed as of v11. - ViewEncapsulation[ViewEncapsulation["None"] = 2] = "None"; - ViewEncapsulation[ViewEncapsulation["ShadowDom"] = 3] = "ShadowDom"; - return ViewEncapsulation; -})({}); -/** - * @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 getCompilerFacade() { - const 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; -} -/** - * @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 - */ -/** - * @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 represented by - * the `MyCustomComponent` constructor function. - * - * @publicApi - */ -const Type = Function; -function isType(v) { - return typeof v === 'function'; -} -/** - * @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 - */ -/** - * 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 (let i = 0; i < items.length; i++) { - arr.push(items[i]); - } -} -/** - * Determines if the contents of two arrays is identical - * - * @param a first array - * @param b second array - * @param identityAccessor Optional function for extracting stable object identity from a value in - * the array. - */ -function arrayEquals(a, b, identityAccessor) { - if (a.length !== b.length) - return false; - for (let i = 0; i < a.length; i++) { - let valueA = a[i]; - let valueB = b[i]; - if (identityAccessor) { - valueA = identityAccessor(valueA); - valueB = identityAccessor(valueB); - } - if (valueB !== valueA) { - return false; - } - } - return true; -} -/** - * Flattens an array. - */ -function flatten(list, dst) { - if (dst === undefined) - dst = list; - for (let i = 0; i < list.length; i++) { - let 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(value => 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) { - const list = []; - for (let 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) { - const 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.'); - let end = array.length; - while (end > index) { - const 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.'); - let 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) { - const 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) { - let 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) { - const 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) { - let 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) { - const 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) { - const 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'); - let start = 0; - let end = array.length >> shift; - while (end !== start) { - const middle = start + ((end - start) >> 1); // find the middle. - const 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); -} -/** - * @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 - */ -/* - * ######################### - * Attention: These Regular expressions have to hold even if the code is minified! - * ########################## - */ -/** - * Regular expression that detects pass-through constructors for ES5 output. This Regex - * intends to capture the common delegation pattern emitted by TypeScript and Babel. Also - * it intends to capture the pattern where existing constructors have been downleveled from - * ES2015 to ES5 using TypeScript w/ downlevel iteration. e.g. - * - * ``` - * function MyClass() { - * var _this = _super.apply(this, arguments) || this; - * ``` - * - * ``` - * function MyClass() { - * var _this = _super.apply(this, __spread(arguments)) || this; - * ``` - * - * More details can be found in: https://github.com/angular/angular/issues/38453. - */ -const ES5_DELEGATE_CTOR = /^function\s+\S+\(\)\s*{[\s\S]+\.apply\(this,\s*(arguments|[^()]+\(arguments\))\)/; -/** Regular expression that detects ES2015 classes which extend from other classes. */ -const ES2015_INHERITED_CLASS = /^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{/; -/** - * Regular expression that detects ES2015 classes which extend from other classes and - * have an explicit constructor defined. - */ -const ES2015_INHERITED_CLASS_WITH_CTOR = /^class\s+[A-Za-z\d$_]*\s*extends\s+[^{]+{[\s\S]*constructor\s*\(/; -/** - * Regular expression that detects ES2015 classes which extend from other classes - * and inherit a constructor. - */ -const ES2015_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 ES5_DELEGATE_CTOR.test(typeStr) || - ES2015_INHERITED_CLASS_WITH_DELEGATE_CTOR.test(typeStr) || - (ES2015_INHERITED_CLASS.test(typeStr) && !ES2015_INHERITED_CLASS_WITH_CTOR.test(typeStr)); -} -class ReflectionCapabilities { - constructor(reflect) { - this._reflect = reflect || _global['Reflect']; - } - isReflectionEnabled() { - return true; - } - factory(t) { - return (...args) => new t(...args); - } - /** @internal */ - _zipTypesAndAnnotations(paramTypes, paramAnnotations) { - let result; - if (typeof paramTypes === 'undefined') { - result = newArray(paramAnnotations.length); - } - else { - result = newArray(paramTypes.length); - } - for (let 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; - } - _ownParameters(type, parentCtor) { - const 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. - const tsickleCtorParams = type.ctorParameters; - if (tsickleCtorParams && tsickleCtorParams !== parentCtor.ctorParameters) { - // Newer tsickle uses a function closure - // Retain the non-function case for compatibility with older tsickle - const ctorParameters = typeof tsickleCtorParams === 'function' ? tsickleCtorParams() : tsickleCtorParams; - const paramTypes = ctorParameters.map((ctorParam) => ctorParam && ctorParam.type); - const paramAnnotations = ctorParameters.map((ctorParam) => ctorParam && convertTsickleDecoratorIntoMetadata(ctorParam.decorators)); - return this._zipTypesAndAnnotations(paramTypes, paramAnnotations); - } - // API for metadata created by invoking the decorators. - const paramAnnotations = type.hasOwnProperty(PARAMETERS) && type[PARAMETERS]; - const 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); - } - 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 []; - } - const parentCtor = getParentCtor(type); - let parameters = this._ownParameters(type, parentCtor); - if (!parameters && parentCtor !== Object) { - parameters = this.parameters(parentCtor); - } - return parameters || []; - } - _ownAnnotations(typeOrFunc, parentCtor) { - // Prefer the direct API. - if (typeOrFunc.annotations && typeOrFunc.annotations !== parentCtor.annotations) { - let 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; - } - annotations(typeOrFunc) { - if (!isType(typeOrFunc)) { - return []; - } - const parentCtor = getParentCtor(typeOrFunc); - const ownAnnotations = this._ownAnnotations(typeOrFunc, parentCtor) || []; - const parentAnnotations = parentCtor !== Object ? this.annotations(parentCtor) : []; - return parentAnnotations.concat(ownAnnotations); - } - _ownPropMetadata(typeOrFunc, parentCtor) { - // Prefer the direct API. - if (typeOrFunc.propMetadata && - typeOrFunc.propMetadata !== parentCtor.propMetadata) { - let 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) { - const propDecorators = typeOrFunc.propDecorators; - const propMetadata = {}; - Object.keys(propDecorators).forEach(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; - } - propMetadata(typeOrFunc) { - if (!isType(typeOrFunc)) { - return {}; - } - const parentCtor = getParentCtor(typeOrFunc); - const propMetadata = {}; - if (parentCtor !== Object) { - const parentPropMetadata = this.propMetadata(parentCtor); - Object.keys(parentPropMetadata).forEach((propName) => { - propMetadata[propName] = parentPropMetadata[propName]; - }); - } - const ownPropMetadata = this._ownPropMetadata(typeOrFunc, parentCtor); - if (ownPropMetadata) { - Object.keys(ownPropMetadata).forEach((propName) => { - const decorators = []; - if (propMetadata.hasOwnProperty(propName)) { - decorators.push(...propMetadata[propName]); - } - decorators.push(...ownPropMetadata[propName]); - propMetadata[propName] = decorators; - }); - } - return propMetadata; - } - ownPropMetadata(typeOrFunc) { - if (!isType(typeOrFunc)) { - return {}; - } - return this._ownPropMetadata(typeOrFunc, getParentCtor(typeOrFunc)) || {}; - } - hasLifecycleHook(type, lcProperty) { - return type instanceof Type && lcProperty in type.prototype; - } - guards(type) { - return {}; - } - getter(name) { - return new Function('o', 'return o.' + name + ';'); - } - setter(name) { - return new Function('o', 'v', 'return o.' + name + ' = v;'); - } - method(name) { - const functionBody = `if (!o.${name}) throw new Error('"${name}" is undefined'); - return o.${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. - importUri(type) { - // StaticSymbol - if (typeof type === 'object' && type['filePath']) { - return type['filePath']; - } - // Runtime type - return `./${stringify(type)}`; - } - resourceUri(type) { - return `./${stringify(type)}`; - } - resolveIdentifier(name, moduleUrl, members, runtime) { - return runtime; - } - resolveEnum(enumIdentifier, name) { - return enumIdentifier[name]; - } -} -function convertTsickleDecoratorIntoMetadata(decoratorInvocations) { - if (!decoratorInvocations) { - return []; - } - return decoratorInvocations.map(decoratorInvocation => { - const decoratorType = decoratorInvocation.type; - const annotationCls = decoratorType.annotationCls; - const annotationArgs = decoratorInvocation.args ? decoratorInvocation.args : []; - return new annotationCls(...annotationArgs); - }); -} -function getParentCtor(ctor) { - const parentProto = ctor.prototype ? Object.getPrototypeOf(ctor.prototype) : null; - const parentCtor = parentProto ? parentProto.constructor : null; - // Note: We always use `Object` as the null value - // to simplify checking later on. - return parentCtor || Object; -} -/** - * @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 - */ -const _THROW_IF_NOT_FOUND = {}; -const THROW_IF_NOT_FOUND = _THROW_IF_NOT_FOUND; -/* - * Name of a property (that we patch onto DI decorator), which is used as an annotation of which - * InjectFlag this decorator represents. This allows to avoid direct references to the DI decorators - * in the code, thus making them tree-shakable. - */ -const DI_DECORATOR_FLAG = '__NG_DI_FLAG__'; -const NG_TEMP_TOKEN_PATH = 'ngTempTokenPath'; -const NG_TOKEN_PATH = 'ngTokenPath'; -const NEW_LINE = /\n/gm; -const NO_NEW_LINE = 'ɵ'; -const SOURCE = '__source'; -const ɵ0$2 = getClosureSafeProperty; -const USE_VALUE = /*@__PURE__*/ getClosureSafeProperty({ provide: String, useValue: ɵ0$2 }); -/** - * 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. - */ -let _currentInjector = undefined; -function setCurrentInjector(injector) { - const former = _currentInjector; - _currentInjector = injector; - return former; -} -function injectInjectorOnly(token, flags = 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); - } -} -function ɵɵinject(token, flags = InjectFlags.Default) { - return (getInjectImplementation() || 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 - */ -function ɵɵinvalidFactoryDep(index) { - const msg = ngDevMode ? - `This constructor is not compatible with Angular Dependency Injection because its dependency at index ${index} of the parameter list is invalid. -This can happen if the dependency type is a primitive like a string or if an ancestor of this class is missing an Angular decorator. - -Please check that 1) the type for the parameter at index ${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`. - * @returns the injected value if injection is successful, `null` otherwise. - * - * @usageNotes - * - * ### Example - * - * {@example core/di/ts/injector_spec.ts region='ShakableInjectionToken'} - * - * @publicApi - */ -const inject = ɵɵinject; -function injectArgs(types) { - const args = []; - for (let i = 0; i < types.length; i++) { - const arg = resolveForwardRef(types[i]); - if (Array.isArray(arg)) { - if (arg.length === 0) { - throw new Error('Arguments array must have arguments.'); - } - let type = undefined; - let flags = InjectFlags.Default; - for (let j = 0; j < arg.length; j++) { - const meta = arg[j]; - const flag = getInjectFlag(meta); - if (typeof flag === 'number') { - // Special case when we handle @Inject decorator. - if (flag === -1 /* Inject */) { - type = meta.token; - } - else { - flags |= flag; - } - } - else { - type = meta; - } - } - args.push(ɵɵinject(type, flags)); - } - else { - args.push(ɵɵinject(arg)); - } - } - return args; -} -/** - * Attaches a given InjectFlag to a given decorator using monkey-patching. - * Since DI decorators can be used in providers `deps` array (when provider is configured using - * `useFactory`) without initialization (e.g. `Host`) and as an instance (e.g. `new Host()`), we - * attach the flag to make it available both as a static property and as a field on decorator - * instance. - * - * @param decorator Provided DI decorator. - * @param flag InjectFlag that should be applied. - */ -function attachInjectFlag(decorator, flag) { - decorator[DI_DECORATOR_FLAG] = flag; - decorator.prototype[DI_DECORATOR_FLAG] = flag; - return decorator; -} -/** - * Reads monkey-patched property that contains InjectFlag attached to a decorator. - * - * @param token Token that may contain monkey-patched DI flags property. - */ -function getInjectFlag(token) { - return token[DI_DECORATOR_FLAG]; -} -function catchInjectorError(e, token, injectorErrorName, source) { - const 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; -} -function formatError(text, obj, injectorErrorName, source = null) { - text = text && text.charAt(0) === '\n' && text.charAt(1) == NO_NEW_LINE ? text.substr(2) : text; - let context = stringify(obj); - if (Array.isArray(obj)) { - context = obj.map(stringify).join(' -> '); - } - else if (typeof obj === 'object') { - let parts = []; - for (let key in obj) { - if (obj.hasOwnProperty(key)) { - let value = obj[key]; - parts.push(key + ':' + (typeof value === 'string' ? JSON.stringify(value) : stringify(value))); - } - } - context = `{${parts.join(', ')}}`; - } - return `${injectorErrorName}${source ? '(' + source + ')' : ''}[${context}]: ${text.replace(NEW_LINE, '\n ')}`; -} -/** - * @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 - */ -const ɵ0$3 = (token) => ({ token }); -/** - * Inject decorator and metadata. - * - * @Annotation - * @publicApi - */ -const Inject = /*@__PURE__*/ attachInjectFlag( -// Disable tslint because `DecoratorFlags` is a const enum which gets inlined. -// tslint:disable-next-line: no-toplevel-property-access -/*@__PURE__*/ makeParamDecorator('Inject', ɵ0$3), -1 /* Inject */); -/** - * Optional decorator and metadata. - * - * @Annotation - * @publicApi - */ -const Optional = -// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined. -// tslint:disable-next-line: no-toplevel-property-access -/*@__PURE__*/ attachInjectFlag(/*@__PURE__*/ makeParamDecorator('Optional'), 8 /* Optional */); -/** - * Self decorator and metadata. - * - * @Annotation - * @publicApi - */ -const Self = -// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined. -// tslint:disable-next-line: no-toplevel-property-access -/*@__PURE__*/ attachInjectFlag(/*@__PURE__*/ makeParamDecorator('Self'), 2 /* Self */); -/** - * `SkipSelf` decorator and metadata. - * - * @Annotation - * @publicApi - */ -const SkipSelf = -// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined. -// tslint:disable-next-line: no-toplevel-property-access -/*@__PURE__*/ attachInjectFlag(/*@__PURE__*/ makeParamDecorator('SkipSelf'), 4 /* SkipSelf */); -/** - * Host decorator and metadata. - * - * @Annotation - * @publicApi - */ -const Host = -// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined. -// tslint:disable-next-line: no-toplevel-property-access -/*@__PURE__*/ attachInjectFlag(/*@__PURE__*/ makeParamDecorator('Host'), 1 /* Host */); -/** - * @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 - */ -let _reflect = null; -function getReflect() { - return (_reflect = _reflect || new ReflectionCapabilities()); -} -function reflectDependencies(type) { - return convertDependencies(getReflect().parameters(type)); -} -function convertDependencies(deps) { - const compiler = getCompilerFacade(); - return deps.map(dep => reflectDependency(compiler, dep)); -} -function reflectDependency(compiler, dep) { - const meta = { - token: null, - host: false, - optional: false, - resolved: compiler.R3ResolvedDependencyType.Token, - self: false, - skipSelf: false, - }; - function setTokenAndResolvedType(token) { - meta.resolved = compiler.R3ResolvedDependencyType.Token; - meta.token = token; - } - if (Array.isArray(dep) && dep.length > 0) { - for (let j = 0; j < dep.length; j++) { - const param = dep[j]; - if (param === undefined) { - // param may be undefined if type of dep is not set by ngtsc - continue; - } - const 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__ === true) { - 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; -} -/** - * @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 - */ -/** - * 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. - */ -function resolveComponentResources(resourceResolver) { - // Store all promises which are fetching the resources. - const componentResolved = []; - // Cache so that we don't fetch the same resource more than once. - const urlMap = new Map(); - function cachedResourceResolve(url) { - let promise = urlMap.get(url); - if (!promise) { - const resp = resourceResolver(url); - urlMap.set(url, promise = resp.then(unwrapResponse)); - } - return promise; - } - componentResourceResolutionQueue.forEach((component, type) => { - const promises = []; - if (component.templateUrl) { - promises.push(cachedResourceResolve(component.templateUrl).then((template) => { - component.template = template; - })); - } - const styleUrls = component.styleUrls; - const styles = component.styles || (component.styles = []); - const styleOffset = component.styles.length; - styleUrls && styleUrls.forEach((styleUrl, index) => { - styles.push(''); // pre-allocate array. - promises.push(cachedResourceResolve(styleUrl).then((style) => { - styles[styleOffset + index] = style; - styleUrls.splice(styleUrls.indexOf(styleUrl), 1); - if (styleUrls.length == 0) { - component.styleUrls = undefined; - } - })); - }); - const fullyResolved = Promise.all(promises).then(() => componentDefResolved(type)); - componentResolved.push(fullyResolved); - }); - clearResolutionOfComponentResourcesQueue(); - return Promise.all(componentResolved).then(() => undefined); -} -let componentResourceResolutionQueue = /*@__PURE__*/ new Map(); -// Track when existing ɵcmp for a Type is waiting on resources. -const componentDefPendingResolution = /*@__PURE__*/ new Set(); -function maybeQueueResolutionOfComponentResources(type, metadata) { - if (componentNeedsResolution(metadata)) { - componentResourceResolutionQueue.set(type, metadata); - componentDefPendingResolution.add(type); - } -} -function isComponentDefPendingResolution(type) { - return componentDefPendingResolution.has(type); -} -function componentNeedsResolution(component) { - return !!((component.templateUrl && !component.hasOwnProperty('template')) || - component.styleUrls && component.styleUrls.length); -} -function clearResolutionOfComponentResourcesQueue() { - const old = componentResourceResolutionQueue; - componentResourceResolutionQueue = new Map(); - return old; -} -function restoreComponentResolutionQueue(queue) { - componentDefPendingResolution.clear(); - queue.forEach((_, type) => componentDefPendingResolution.add(type)); - componentResourceResolutionQueue = queue; -} -function isComponentResourceResolutionQueueEmpty() { - return componentResourceResolutionQueue.size === 0; -} -function unwrapResponse(response) { - return typeof response == 'string' ? response : response.text(); -} -function componentDefResolved(type) { - componentDefPendingResolution.delete(type); -} -/** - * @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 - */ -/** - * The Trusted Types policy, or null if Trusted Types are not - * enabled/supported, or undefined if the policy has not been created yet. - */ -let policy; -/** - * Returns the Trusted Types policy, or null if Trusted Types are not - * enabled/supported. The first call to this function will create the policy. - */ -function getPolicy() { - if (policy === undefined) { - policy = null; - if (_global.trustedTypes) { - try { - policy = _global.trustedTypes.createPolicy('angular', { - createHTML: (s) => s, - createScript: (s) => s, - createScriptURL: (s) => s, - }); - } - catch (_a) { - // trustedTypes.createPolicy throws if called with a name that is - // already registered, even in report-only mode. Until the API changes, - // catch the error not to break the applications functionally. In such - // cases, the code will fall back to using strings. - } - } - } - return policy; -} -/** - * Unsafely promote a string to a TrustedHTML, falling back to strings when - * Trusted Types are not available. - * @security This is a security-sensitive function; any use of this function - * must go through security review. In particular, it must be assured that the - * provided string will never cause an XSS vulnerability if used in a context - * that will be interpreted as HTML by a browser, e.g. when assigning to - * element.innerHTML. - */ -function trustedHTMLFromString(html) { - var _a; - return ((_a = getPolicy()) === null || _a === void 0 ? void 0 : _a.createHTML(html)) || html; -} -/** - * Unsafely promote a string to a TrustedScript, falling back to strings when - * Trusted Types are not available. - * @security In particular, it must be assured that the provided string will - * never cause an XSS vulnerability if used in a context that will be - * interpreted and executed as a script by a browser, e.g. when calling eval. - */ -function trustedScriptFromString(script) { - var _a; - return ((_a = getPolicy()) === null || _a === void 0 ? void 0 : _a.createScript(script)) || script; -} -/** - * Unsafely promote a string to a TrustedScriptURL, falling back to strings - * when Trusted Types are not available. - * @security This is a security-sensitive function; any use of this function - * must go through security review. In particular, it must be assured that the - * provided string will never cause an XSS vulnerability if used in a context - * that will cause a browser to load and execute a resource, e.g. when - * assigning to script.src. - */ -function trustedScriptURLFromString(url) { - var _a; - return ((_a = getPolicy()) === null || _a === void 0 ? void 0 : _a.createScriptURL(url)) || url; -} -/** - * Unsafely call the Function constructor with the given string arguments. It - * is only available in development mode, and should be stripped out of - * production code. - * @security This is a security-sensitive function; any use of this function - * must go through security review. In particular, it must be assured that it - * is only called from development code, as use in production code can lead to - * XSS vulnerabilities. - */ -function newTrustedFunctionForDev(...args) { - if (typeof ngDevMode === 'undefined') { - throw new Error('newTrustedFunctionForDev should never be called in production'); - } - if (!_global.trustedTypes) { - // In environments that don't support Trusted Types, fall back to the most - // straightforward implementation: - return new Function(...args); - } - // Chrome currently does not support passing TrustedScript to the Function - // constructor. The following implements the workaround proposed on the page - // below, where the Chromium bug is also referenced: - // https://github.com/w3c/webappsec-trusted-types/wiki/Trusted-Types-for-function-constructor - const fnArgs = args.slice(0, -1).join(','); - const fnBody = args[args.length - 1]; - const body = `(function anonymous(${fnArgs} -) { ${fnBody} -})`; - // Using eval directly confuses the compiler and prevents this module from - // being stripped out of JS binaries even if not used. The global['eval'] - // indirection fixes that. - const fn = _global['eval'](trustedScriptFromString(body)); - if (fn.bind === undefined) { - // Workaround for a browser bug that only exists in Chrome 83, where passing - // a TrustedScript to eval just returns the TrustedScript back without - // evaluating it. In that case, fall back to the most straightforward - // implementation: - return new Function(...args); - } - // To completely mimic the behavior of calling "new Function", two more - // things need to happen: - // 1. Stringifying the resulting function should return its source code - fn.toString = () => body; - // 2. When calling the resulting function, `this` should refer to `global` - return fn.bind(_global); - // When Trusted Types support in Function constructors is widely available, - // the implementation of this function can be simplified to: - // return new Function(...args.map(a => trustedScriptFromString(a))); -} -/** - * @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 - */ -/** - * The Trusted Types policy, or null if Trusted Types are not - * enabled/supported, or undefined if the policy has not been created yet. - */ -let policy$1; -/** - * Returns the Trusted Types policy, or null if Trusted Types are not - * enabled/supported. The first call to this function will create the policy. - */ -function getPolicy$1() { - if (policy$1 === undefined) { - policy$1 = null; - if (_global.trustedTypes) { - try { - policy$1 = _global.trustedTypes - .createPolicy('angular#unsafe-bypass', { - createHTML: (s) => s, - createScript: (s) => s, - createScriptURL: (s) => s, - }); - } - catch (_a) { - // trustedTypes.createPolicy throws if called with a name that is - // already registered, even in report-only mode. Until the API changes, - // catch the error not to break the applications functionally. In such - // cases, the code will fall back to using strings. - } - } - } - return policy$1; -} -/** - * Unsafely promote a string to a TrustedHTML, falling back to strings when - * Trusted Types are not available. - * @security This is a security-sensitive function; any use of this function - * must go through security review. In particular, it must be assured that it - * is only passed strings that come directly from custom sanitizers or the - * bypassSecurityTrust* functions. - */ -function trustedHTMLFromStringBypass(html) { - var _a; - return ((_a = getPolicy$1()) === null || _a === void 0 ? void 0 : _a.createHTML(html)) || html; -} -/** - * Unsafely promote a string to a TrustedScript, falling back to strings when - * Trusted Types are not available. - * @security This is a security-sensitive function; any use of this function - * must go through security review. In particular, it must be assured that it - * is only passed strings that come directly from custom sanitizers or the - * bypassSecurityTrust* functions. - */ -function trustedScriptFromStringBypass(script) { - var _a; - return ((_a = getPolicy$1()) === null || _a === void 0 ? void 0 : _a.createScript(script)) || script; -} -/** - * Unsafely promote a string to a TrustedScriptURL, falling back to strings - * when Trusted Types are not available. - * @security This is a security-sensitive function; any use of this function - * must go through security review. In particular, it must be assured that it - * is only passed strings that come directly from custom sanitizers or the - * bypassSecurityTrust* functions. - */ -function trustedScriptURLFromStringBypass(url) { - var _a; - return ((_a = getPolicy$1()) === null || _a === void 0 ? void 0 : _a.createScriptURL(url)) || url; -} -/** - * @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 SafeValueImpl { - constructor(changingThisBreaksApplicationSecurity) { - this.changingThisBreaksApplicationSecurity = changingThisBreaksApplicationSecurity; - } - toString() { - return `SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity}` + - ` (see https://g.co/ng/security#xss)`; - } -} -class SafeHtmlImpl extends SafeValueImpl { - getTypeName() { - return "HTML" /* Html */; - } -} -class SafeStyleImpl extends SafeValueImpl { - getTypeName() { - return "Style" /* Style */; - } -} -class SafeScriptImpl extends SafeValueImpl { - getTypeName() { - return "Script" /* Script */; - } -} -class SafeUrlImpl extends SafeValueImpl { - getTypeName() { - return "URL" /* Url */; - } -} -class SafeResourceUrlImpl extends SafeValueImpl { - getTypeName() { - return "ResourceURL" /* ResourceUrl */; - } -} -function unwrapSafeValue(value) { - return value instanceof SafeValueImpl ? value.changingThisBreaksApplicationSecurity : - value; -} -function allowSanitizationBypassAndThrow(value, type) { - const 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 ${type}, got a ${actualType} (see https://g.co/ng/security#xss)`); - } - return actualType === type; -} -function getSanitizationBypassType(value) { - return value instanceof SafeValueImpl && 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. - * @returns 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. - * @returns 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. - * @returns 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. - * @returns 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. - * @returns a `url` which has been branded to be implicitly trusted. - */ -function bypassSanitizationTrustResourceUrl(trustedResourceUrl) { - return new SafeResourceUrlImpl(trustedResourceUrl); -} -/** - * @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 - */ -/** - * This helper is used to get hold of an inert tree of DOM elements containing dirty HTML - * that needs sanitizing. - * Depending upon browser support we use one of two strategies for doing this. - * Default: DOMParser strategy - * Fallback: InertDocument strategy - */ -function getInertBodyHelper(defaultDoc) { - const inertDocumentHelper = new InertDocumentHelper(defaultDoc); - return isDOMParserAvailable() ? new DOMParserHelper(inertDocumentHelper) : inertDocumentHelper; -} -/** - * Uses DOMParser to create and fill an inert body element. - * This is the default strategy used in browsers that support it. - */ -class DOMParserHelper { - constructor(inertDocumentHelper) { - this.inertDocumentHelper = inertDocumentHelper; - } - getInertBodyElement(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 `` do not get hoisted to the - // `` tag. Note that the `` tag is closed implicitly to prevent unclosed tags - // in `html` from consuming the otherwise explicit `` tag. - html = '' + html; - try { - const body = new window.DOMParser() - .parseFromString(trustedHTMLFromString(html), 'text/html') - .body; - if (body === null) { - // In some browsers (e.g. Mozilla/5.0 iPad AppleWebKit Mobile) the `body` property only - // becomes available in the following tick of the JS engine. In that case we fall back to - // the `inertDocumentHelper` instead. - return this.inertDocumentHelper.getInertBodyElement(html); - } - body.removeChild(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 fallback strategy if the browser does not support DOMParser. - */ -class InertDocumentHelper { - constructor(defaultDoc) { - this.defaultDoc = defaultDoc; - this.inertDocument = this.defaultDoc.implementation.createHTMLDocument('sanitization-inert'); - if (this.inertDocument.body == null) { - // usually there should be only one body element in the document, but IE doesn't have any, so - // we need to create one. - const inertHtml = this.inertDocument.createElement('html'); - this.inertDocument.appendChild(inertHtml); - const inertBodyElement = this.inertDocument.createElement('body'); - inertHtml.appendChild(inertBodyElement); - } - } - getInertBodyElement(html) { - // Prefer using