{"version":3,"sources":["node_modules/moment/moment.js","node_modules/chart.js/dist/Chart.js","node_modules/@angular/core/fesm2022/primitives/signals.mjs","node_modules/@angular/core/fesm2022/primitives/di.mjs","node_modules/rxjs/_esm2015/internal/util/isFunction.js","node_modules/rxjs/_esm2015/internal/config.js","node_modules/rxjs/_esm2015/internal/util/hostReportError.js","node_modules/rxjs/_esm2015/internal/Observer.js","node_modules/rxjs/_esm2015/internal/util/isArray.js","node_modules/rxjs/_esm2015/internal/util/isObject.js","node_modules/rxjs/_esm2015/internal/util/UnsubscriptionError.js","node_modules/rxjs/_esm2015/internal/Subscription.js","node_modules/rxjs/_esm2015/internal/symbol/rxSubscriber.js","node_modules/rxjs/_esm2015/internal/Subscriber.js","node_modules/rxjs/_esm2015/internal/util/canReportError.js","node_modules/rxjs/_esm2015/internal/util/toSubscriber.js","node_modules/rxjs/_esm2015/internal/symbol/observable.js","node_modules/rxjs/_esm2015/internal/util/identity.js","node_modules/rxjs/_esm2015/internal/util/pipe.js","node_modules/rxjs/_esm2015/internal/Observable.js","node_modules/rxjs/_esm2015/internal/util/ObjectUnsubscribedError.js","node_modules/rxjs/_esm2015/internal/SubjectSubscription.js","node_modules/rxjs/_esm2015/internal/Subject.js","node_modules/rxjs/_esm2015/internal/operators/refCount.js","node_modules/rxjs/_esm2015/internal/observable/ConnectableObservable.js","node_modules/rxjs/_esm2015/internal/BehaviorSubject.js","node_modules/rxjs/_esm2015/internal/scheduler/Action.js","node_modules/rxjs/_esm2015/internal/scheduler/AsyncAction.js","node_modules/rxjs/_esm2015/internal/scheduler/QueueAction.js","node_modules/rxjs/_esm2015/internal/Scheduler.js","node_modules/rxjs/_esm2015/internal/scheduler/AsyncScheduler.js","node_modules/rxjs/_esm2015/internal/scheduler/QueueScheduler.js","node_modules/rxjs/_esm2015/internal/scheduler/queue.js","node_modules/rxjs/_esm2015/internal/observable/empty.js","node_modules/rxjs/_esm2015/internal/util/isScheduler.js","node_modules/rxjs/_esm2015/internal/util/subscribeToArray.js","node_modules/rxjs/_esm2015/internal/scheduled/scheduleArray.js","node_modules/rxjs/_esm2015/internal/observable/fromArray.js","node_modules/rxjs/_esm2015/internal/observable/of.js","node_modules/rxjs/_esm2015/internal/observable/throwError.js","node_modules/rxjs/_esm2015/internal/Notification.js","node_modules/rxjs/_esm2015/internal/operators/observeOn.js","node_modules/rxjs/_esm2015/internal/ReplaySubject.js","node_modules/rxjs/_esm2015/internal/scheduler/async.js","node_modules/rxjs/_esm2015/internal/util/noop.js","node_modules/rxjs/_esm2015/internal/util/isObservable.js","node_modules/rxjs/_esm2015/internal/util/ArgumentOutOfRangeError.js","node_modules/rxjs/_esm2015/internal/util/EmptyError.js","node_modules/rxjs/_esm2015/internal/operators/map.js","node_modules/rxjs/_esm2015/internal/OuterSubscriber.js","node_modules/rxjs/_esm2015/internal/InnerSubscriber.js","node_modules/rxjs/_esm2015/internal/util/subscribeToPromise.js","node_modules/rxjs/_esm2015/internal/symbol/iterator.js","node_modules/rxjs/_esm2015/internal/util/subscribeToIterable.js","node_modules/rxjs/_esm2015/internal/util/subscribeToObservable.js","node_modules/rxjs/_esm2015/internal/util/isArrayLike.js","node_modules/rxjs/_esm2015/internal/util/isPromise.js","node_modules/rxjs/_esm2015/internal/util/subscribeTo.js","node_modules/rxjs/_esm2015/internal/util/subscribeToResult.js","node_modules/rxjs/_esm2015/internal/observable/combineLatest.js","node_modules/rxjs/_esm2015/internal/scheduled/scheduleObservable.js","node_modules/rxjs/_esm2015/internal/scheduled/schedulePromise.js","node_modules/rxjs/_esm2015/internal/scheduled/scheduleIterable.js","node_modules/rxjs/_esm2015/internal/util/isInteropObservable.js","node_modules/rxjs/_esm2015/internal/util/isIterable.js","node_modules/rxjs/_esm2015/internal/scheduled/scheduled.js","node_modules/rxjs/_esm2015/internal/observable/from.js","node_modules/rxjs/_esm2015/internal/innerSubscribe.js","node_modules/rxjs/_esm2015/internal/operators/mergeMap.js","node_modules/rxjs/_esm2015/internal/operators/mergeAll.js","node_modules/rxjs/_esm2015/internal/operators/concatAll.js","node_modules/rxjs/_esm2015/internal/observable/concat.js","node_modules/rxjs/_esm2015/internal/observable/defer.js","node_modules/rxjs/_esm2015/internal/observable/forkJoin.js","node_modules/rxjs/_esm2015/internal/operators/filter.js","node_modules/rxjs/_esm2015/internal/operators/catchError.js","node_modules/rxjs/_esm2015/internal/operators/concatMap.js","node_modules/rxjs/_esm2015/internal/operators/defaultIfEmpty.js","node_modules/rxjs/_esm2015/internal/util/isDate.js","node_modules/rxjs/_esm2015/internal/operators/delay.js","node_modules/rxjs/_esm2015/internal/operators/throwIfEmpty.js","node_modules/rxjs/_esm2015/internal/operators/take.js","node_modules/rxjs/_esm2015/internal/operators/finalize.js","node_modules/rxjs/_esm2015/internal/operators/first.js","node_modules/rxjs/_esm2015/internal/operators/takeLast.js","node_modules/rxjs/_esm2015/internal/operators/last.js","node_modules/rxjs/_esm2015/internal/operators/scan.js","node_modules/rxjs/_esm2015/internal/operators/shareReplay.js","node_modules/rxjs/_esm2015/internal/operators/startWith.js","node_modules/rxjs/_esm2015/internal/operators/switchMap.js","node_modules/rxjs/_esm2015/internal/operators/takeUntil.js","node_modules/rxjs/_esm2015/internal/operators/tap.js","node_modules/@angular/core/fesm2022/core.mjs","node_modules/@angular/common/fesm2022/common.mjs","node_modules/@angular/common/fesm2022/http.mjs","node_modules/@angular/platform-browser/fesm2022/platform-browser.mjs","node_modules/@angular/router/fesm2022/router.mjs","node_modules/@ngx-translate/core/dist/fesm2022/ngx-translate-core.mjs","src/app/containers/tabs/default-tab.service.ts","src/app/containers/default-tabbar/default-tabbar.component.ts","src/app/containers/default-tabbar/default-tabbar.component.html","src/app/containers/default-layout/default-layout.component.ts","src/app/containers/default-layout/default-layout.component.html","src/app/views/error/error404/error404.component.ts","src/app/views/error/error404/error404.component.html","src/app/views/error/error500/error500.component.ts","src/app/views/error/error500/error500.component.html","src/app/views/emf-lit/emf-lit.component.ts","src/app/views/emf-lit/emf-lit.component.html","src/app/views/emf-lit/emf-lit.component.EU1999.ts","src/app/views/emf-lit/emf-lit.component.FB451.ts","src/app/views/emf-lit/emf-lit.component.EMFV.ts","src/app/views/emf-lit/emf-lit.component.BImSchV.ts","src/app/views/emf-lit/emf-lit.component.DGUVV15.ts","src/app/views/emf-lit/emf-lit.component.EU2013.ts","node_modules/@angular/forms/fesm2022/forms.mjs","src/app/containers/tabs/tab-body/tab-body.component.ts","src/app/containers/tabs/tab-body/tab-body.component.html","src/app/containers/tabs/tab-item/tab-item.component.ts","src/app/containers/tabs/tab-item/tab-item.component.html","src/app/containers/tabs/tabs.component.ts","src/app/containers/tabs/tabs.component.html","src/app/views/emf-lit/tooltip.directive.ts","src/app/app-routing.module.ts","src/app/app.component.ts","src/app/views/default/default.component.ts","src/app/views/default/default.component.html","src/app/_nav.ts","src/app/containers/default-navbar/default-navbar.component.ts","src/app/containers/default-navbar/default-navbar.component.html","src/app/containers/tabs/tabs.module.ts","node_modules/@ngx-translate/http-loader/dist/fesm2022/ngx-translate-http-loader.mjs","src/app/app.module.ts","src/environments/environment.ts","src/main.ts"],"sourcesContent":["//! moment.js\n//! version : 2.30.1\n//! authors : Tim Wood, Iskren Chernev, Moment.js contributors\n//! license : MIT\n//! momentjs.com\n\n;\n(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : typeof define === 'function' && define.amd ? define(factory) : global.moment = factory();\n})(this, function () {\n 'use strict';\n\n var hookCallback;\n function hooks() {\n return hookCallback.apply(null, arguments);\n }\n\n // This is done to register the method called with moment()\n // without creating circular dependencies.\n function setHookCallback(callback) {\n hookCallback = callback;\n }\n function isArray(input) {\n return input instanceof Array || Object.prototype.toString.call(input) === '[object Array]';\n }\n function isObject(input) {\n // IE8 will treat undefined and null as object if it wasn't for\n // input != null\n return input != null && Object.prototype.toString.call(input) === '[object Object]';\n }\n function hasOwnProp(a, b) {\n return Object.prototype.hasOwnProperty.call(a, b);\n }\n function isObjectEmpty(obj) {\n if (Object.getOwnPropertyNames) {\n return Object.getOwnPropertyNames(obj).length === 0;\n } else {\n var k;\n for (k in obj) {\n if (hasOwnProp(obj, k)) {\n return false;\n }\n }\n return true;\n }\n }\n function isUndefined(input) {\n return input === void 0;\n }\n function isNumber(input) {\n return typeof input === 'number' || Object.prototype.toString.call(input) === '[object Number]';\n }\n function isDate(input) {\n return input instanceof Date || Object.prototype.toString.call(input) === '[object Date]';\n }\n function map(arr, fn) {\n var res = [],\n i,\n arrLen = arr.length;\n for (i = 0; i < arrLen; ++i) {\n res.push(fn(arr[i], i));\n }\n return res;\n }\n function extend(a, b) {\n for (var i in b) {\n if (hasOwnProp(b, i)) {\n a[i] = b[i];\n }\n }\n if (hasOwnProp(b, 'toString')) {\n a.toString = b.toString;\n }\n if (hasOwnProp(b, 'valueOf')) {\n a.valueOf = b.valueOf;\n }\n return a;\n }\n function createUTC(input, format, locale, strict) {\n return createLocalOrUTC(input, format, locale, strict, true).utc();\n }\n function defaultParsingFlags() {\n // We need to deep clone this object.\n return {\n empty: false,\n unusedTokens: [],\n unusedInput: [],\n overflow: -2,\n charsLeftOver: 0,\n nullInput: false,\n invalidEra: null,\n invalidMonth: null,\n invalidFormat: false,\n userInvalidated: false,\n iso: false,\n parsedDateParts: [],\n era: null,\n meridiem: null,\n rfc2822: false,\n weekdayMismatch: false\n };\n }\n function getParsingFlags(m) {\n if (m._pf == null) {\n m._pf = defaultParsingFlags();\n }\n return m._pf;\n }\n var some;\n if (Array.prototype.some) {\n some = Array.prototype.some;\n } else {\n some = function (fun) {\n var t = Object(this),\n len = t.length >>> 0,\n i;\n for (i = 0; i < len; i++) {\n if (i in t && fun.call(this, t[i], i, t)) {\n return true;\n }\n }\n return false;\n };\n }\n function isValid(m) {\n var flags = null,\n parsedParts = false,\n isNowValid = m._d && !isNaN(m._d.getTime());\n if (isNowValid) {\n flags = getParsingFlags(m);\n parsedParts = some.call(flags.parsedDateParts, function (i) {\n return i != null;\n });\n isNowValid = flags.overflow < 0 && !flags.empty && !flags.invalidEra && !flags.invalidMonth && !flags.invalidWeekday && !flags.weekdayMismatch && !flags.nullInput && !flags.invalidFormat && !flags.userInvalidated && (!flags.meridiem || flags.meridiem && parsedParts);\n if (m._strict) {\n isNowValid = isNowValid && flags.charsLeftOver === 0 && flags.unusedTokens.length === 0 && flags.bigHour === undefined;\n }\n }\n if (Object.isFrozen == null || !Object.isFrozen(m)) {\n m._isValid = isNowValid;\n } else {\n return isNowValid;\n }\n return m._isValid;\n }\n function createInvalid(flags) {\n var m = createUTC(NaN);\n if (flags != null) {\n extend(getParsingFlags(m), flags);\n } else {\n getParsingFlags(m).userInvalidated = true;\n }\n return m;\n }\n\n // Plugins that add properties should also add the key here (null value),\n // so we can properly clone ourselves.\n var momentProperties = hooks.momentProperties = [],\n updateInProgress = false;\n function copyConfig(to, from) {\n var i,\n prop,\n val,\n momentPropertiesLen = momentProperties.length;\n if (!isUndefined(from._isAMomentObject)) {\n to._isAMomentObject = from._isAMomentObject;\n }\n if (!isUndefined(from._i)) {\n to._i = from._i;\n }\n if (!isUndefined(from._f)) {\n to._f = from._f;\n }\n if (!isUndefined(from._l)) {\n to._l = from._l;\n }\n if (!isUndefined(from._strict)) {\n to._strict = from._strict;\n }\n if (!isUndefined(from._tzm)) {\n to._tzm = from._tzm;\n }\n if (!isUndefined(from._isUTC)) {\n to._isUTC = from._isUTC;\n }\n if (!isUndefined(from._offset)) {\n to._offset = from._offset;\n }\n if (!isUndefined(from._pf)) {\n to._pf = getParsingFlags(from);\n }\n if (!isUndefined(from._locale)) {\n to._locale = from._locale;\n }\n if (momentPropertiesLen > 0) {\n for (i = 0; i < momentPropertiesLen; i++) {\n prop = momentProperties[i];\n val = from[prop];\n if (!isUndefined(val)) {\n to[prop] = val;\n }\n }\n }\n return to;\n }\n\n // Moment prototype object\n function Moment(config) {\n copyConfig(this, config);\n this._d = new Date(config._d != null ? config._d.getTime() : NaN);\n if (!this.isValid()) {\n this._d = new Date(NaN);\n }\n // Prevent infinite loop in case updateOffset creates new moment\n // objects.\n if (updateInProgress === false) {\n updateInProgress = true;\n hooks.updateOffset(this);\n updateInProgress = false;\n }\n }\n function isMoment(obj) {\n return obj instanceof Moment || obj != null && obj._isAMomentObject != null;\n }\n function warn(msg) {\n if (hooks.suppressDeprecationWarnings === false && typeof console !== 'undefined' && console.warn) {\n console.warn('Deprecation warning: ' + msg);\n }\n }\n function deprecate(msg, fn) {\n var firstTime = true;\n return extend(function () {\n if (hooks.deprecationHandler != null) {\n hooks.deprecationHandler(null, msg);\n }\n if (firstTime) {\n var args = [],\n arg,\n i,\n key,\n argLen = arguments.length;\n for (i = 0; i < argLen; i++) {\n arg = '';\n if (typeof arguments[i] === 'object') {\n arg += '\\n[' + i + '] ';\n for (key in arguments[0]) {\n if (hasOwnProp(arguments[0], key)) {\n arg += key + ': ' + arguments[0][key] + ', ';\n }\n }\n arg = arg.slice(0, -2); // Remove trailing comma and space\n } else {\n arg = arguments[i];\n }\n args.push(arg);\n }\n warn(msg + '\\nArguments: ' + Array.prototype.slice.call(args).join('') + '\\n' + new Error().stack);\n firstTime = false;\n }\n return fn.apply(this, arguments);\n }, fn);\n }\n var deprecations = {};\n function deprecateSimple(name, msg) {\n if (hooks.deprecationHandler != null) {\n hooks.deprecationHandler(name, msg);\n }\n if (!deprecations[name]) {\n warn(msg);\n deprecations[name] = true;\n }\n }\n hooks.suppressDeprecationWarnings = false;\n hooks.deprecationHandler = null;\n function isFunction(input) {\n return typeof Function !== 'undefined' && input instanceof Function || Object.prototype.toString.call(input) === '[object Function]';\n }\n function set(config) {\n var prop, i;\n for (i in config) {\n if (hasOwnProp(config, i)) {\n prop = config[i];\n if (isFunction(prop)) {\n this[i] = prop;\n } else {\n this['_' + i] = prop;\n }\n }\n }\n this._config = config;\n // Lenient ordinal parsing accepts just a number in addition to\n // number + (possibly) stuff coming from _dayOfMonthOrdinalParse.\n // TODO: Remove \"ordinalParse\" fallback in next major release.\n this._dayOfMonthOrdinalParseLenient = new RegExp((this._dayOfMonthOrdinalParse.source || this._ordinalParse.source) + '|' + /\\d{1,2}/.source);\n }\n function mergeConfigs(parentConfig, childConfig) {\n var res = extend({}, parentConfig),\n prop;\n for (prop in childConfig) {\n if (hasOwnProp(childConfig, prop)) {\n if (isObject(parentConfig[prop]) && isObject(childConfig[prop])) {\n res[prop] = {};\n extend(res[prop], parentConfig[prop]);\n extend(res[prop], childConfig[prop]);\n } else if (childConfig[prop] != null) {\n res[prop] = childConfig[prop];\n } else {\n delete res[prop];\n }\n }\n }\n for (prop in parentConfig) {\n if (hasOwnProp(parentConfig, prop) && !hasOwnProp(childConfig, prop) && isObject(parentConfig[prop])) {\n // make sure changes to properties don't modify parent config\n res[prop] = extend({}, res[prop]);\n }\n }\n return res;\n }\n function Locale(config) {\n if (config != null) {\n this.set(config);\n }\n }\n var keys;\n if (Object.keys) {\n keys = Object.keys;\n } else {\n keys = function (obj) {\n var i,\n res = [];\n for (i in obj) {\n if (hasOwnProp(obj, i)) {\n res.push(i);\n }\n }\n return res;\n };\n }\n var defaultCalendar = {\n sameDay: '[Today at] LT',\n nextDay: '[Tomorrow at] LT',\n nextWeek: 'dddd [at] LT',\n lastDay: '[Yesterday at] LT',\n lastWeek: '[Last] dddd [at] LT',\n sameElse: 'L'\n };\n function calendar(key, mom, now) {\n var output = this._calendar[key] || this._calendar['sameElse'];\n return isFunction(output) ? output.call(mom, now) : output;\n }\n function zeroFill(number, targetLength, forceSign) {\n var absNumber = '' + Math.abs(number),\n zerosToFill = targetLength - absNumber.length,\n sign = number >= 0;\n return (sign ? forceSign ? '+' : '' : '-') + Math.pow(10, Math.max(0, zerosToFill)).toString().substr(1) + absNumber;\n }\n var formattingTokens = /(\\[[^\\[]*\\])|(\\\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,\n localFormattingTokens = /(\\[[^\\[]*\\])|(\\\\)?(LTS|LT|LL?L?L?|l{1,4})/g,\n formatFunctions = {},\n formatTokenFunctions = {};\n\n // token: 'M'\n // padded: ['MM', 2]\n // ordinal: 'Mo'\n // callback: function () { this.month() + 1 }\n function addFormatToken(token, padded, ordinal, callback) {\n var func = callback;\n if (typeof callback === 'string') {\n func = function () {\n return this[callback]();\n };\n }\n if (token) {\n formatTokenFunctions[token] = func;\n }\n if (padded) {\n formatTokenFunctions[padded[0]] = function () {\n return zeroFill(func.apply(this, arguments), padded[1], padded[2]);\n };\n }\n if (ordinal) {\n formatTokenFunctions[ordinal] = function () {\n return this.localeData().ordinal(func.apply(this, arguments), token);\n };\n }\n }\n function removeFormattingTokens(input) {\n if (input.match(/\\[[\\s\\S]/)) {\n return input.replace(/^\\[|\\]$/g, '');\n }\n return input.replace(/\\\\/g, '');\n }\n function makeFormatFunction(format) {\n var array = format.match(formattingTokens),\n i,\n length;\n for (i = 0, length = array.length; i < length; i++) {\n if (formatTokenFunctions[array[i]]) {\n array[i] = formatTokenFunctions[array[i]];\n } else {\n array[i] = removeFormattingTokens(array[i]);\n }\n }\n return function (mom) {\n var output = '',\n i;\n for (i = 0; i < length; i++) {\n output += isFunction(array[i]) ? array[i].call(mom, format) : array[i];\n }\n return output;\n };\n }\n\n // format date using native date object\n function formatMoment(m, format) {\n if (!m.isValid()) {\n return m.localeData().invalidDate();\n }\n format = expandFormat(format, m.localeData());\n formatFunctions[format] = formatFunctions[format] || makeFormatFunction(format);\n return formatFunctions[format](m);\n }\n function expandFormat(format, locale) {\n var i = 5;\n function replaceLongDateFormatTokens(input) {\n return locale.longDateFormat(input) || input;\n }\n localFormattingTokens.lastIndex = 0;\n while (i >= 0 && localFormattingTokens.test(format)) {\n format = format.replace(localFormattingTokens, replaceLongDateFormatTokens);\n localFormattingTokens.lastIndex = 0;\n i -= 1;\n }\n return format;\n }\n var defaultLongDateFormat = {\n LTS: 'h:mm:ss A',\n LT: 'h:mm A',\n L: 'MM/DD/YYYY',\n LL: 'MMMM D, YYYY',\n LLL: 'MMMM D, YYYY h:mm A',\n LLLL: 'dddd, MMMM D, YYYY h:mm A'\n };\n function longDateFormat(key) {\n var format = this._longDateFormat[key],\n formatUpper = this._longDateFormat[key.toUpperCase()];\n if (format || !formatUpper) {\n return format;\n }\n this._longDateFormat[key] = formatUpper.match(formattingTokens).map(function (tok) {\n if (tok === 'MMMM' || tok === 'MM' || tok === 'DD' || tok === 'dddd') {\n return tok.slice(1);\n }\n return tok;\n }).join('');\n return this._longDateFormat[key];\n }\n var defaultInvalidDate = 'Invalid date';\n function invalidDate() {\n return this._invalidDate;\n }\n var defaultOrdinal = '%d',\n defaultDayOfMonthOrdinalParse = /\\d{1,2}/;\n function ordinal(number) {\n return this._ordinal.replace('%d', number);\n }\n var defaultRelativeTime = {\n future: 'in %s',\n past: '%s ago',\n s: 'a few seconds',\n ss: '%d seconds',\n m: 'a minute',\n mm: '%d minutes',\n h: 'an hour',\n hh: '%d hours',\n d: 'a day',\n dd: '%d days',\n w: 'a week',\n ww: '%d weeks',\n M: 'a month',\n MM: '%d months',\n y: 'a year',\n yy: '%d years'\n };\n function relativeTime(number, withoutSuffix, string, isFuture) {\n var output = this._relativeTime[string];\n return isFunction(output) ? output(number, withoutSuffix, string, isFuture) : output.replace(/%d/i, number);\n }\n function pastFuture(diff, output) {\n var format = this._relativeTime[diff > 0 ? 'future' : 'past'];\n return isFunction(format) ? format(output) : format.replace(/%s/i, output);\n }\n var aliases = {\n D: 'date',\n dates: 'date',\n date: 'date',\n d: 'day',\n days: 'day',\n day: 'day',\n e: 'weekday',\n weekdays: 'weekday',\n weekday: 'weekday',\n E: 'isoWeekday',\n isoweekdays: 'isoWeekday',\n isoweekday: 'isoWeekday',\n DDD: 'dayOfYear',\n dayofyears: 'dayOfYear',\n dayofyear: 'dayOfYear',\n h: 'hour',\n hours: 'hour',\n hour: 'hour',\n ms: 'millisecond',\n milliseconds: 'millisecond',\n millisecond: 'millisecond',\n m: 'minute',\n minutes: 'minute',\n minute: 'minute',\n M: 'month',\n months: 'month',\n month: 'month',\n Q: 'quarter',\n quarters: 'quarter',\n quarter: 'quarter',\n s: 'second',\n seconds: 'second',\n second: 'second',\n gg: 'weekYear',\n weekyears: 'weekYear',\n weekyear: 'weekYear',\n GG: 'isoWeekYear',\n isoweekyears: 'isoWeekYear',\n isoweekyear: 'isoWeekYear',\n w: 'week',\n weeks: 'week',\n week: 'week',\n W: 'isoWeek',\n isoweeks: 'isoWeek',\n isoweek: 'isoWeek',\n y: 'year',\n years: 'year',\n year: 'year'\n };\n function normalizeUnits(units) {\n return typeof units === 'string' ? aliases[units] || aliases[units.toLowerCase()] : undefined;\n }\n function normalizeObjectUnits(inputObject) {\n var normalizedInput = {},\n normalizedProp,\n prop;\n for (prop in inputObject) {\n if (hasOwnProp(inputObject, prop)) {\n normalizedProp = normalizeUnits(prop);\n if (normalizedProp) {\n normalizedInput[normalizedProp] = inputObject[prop];\n }\n }\n }\n return normalizedInput;\n }\n var priorities = {\n date: 9,\n day: 11,\n weekday: 11,\n isoWeekday: 11,\n dayOfYear: 4,\n hour: 13,\n millisecond: 16,\n minute: 14,\n month: 8,\n quarter: 7,\n second: 15,\n weekYear: 1,\n isoWeekYear: 1,\n week: 5,\n isoWeek: 5,\n year: 1\n };\n function getPrioritizedUnits(unitsObj) {\n var units = [],\n u;\n for (u in unitsObj) {\n if (hasOwnProp(unitsObj, u)) {\n units.push({\n unit: u,\n priority: priorities[u]\n });\n }\n }\n units.sort(function (a, b) {\n return a.priority - b.priority;\n });\n return units;\n }\n var match1 = /\\d/,\n // 0 - 9\n match2 = /\\d\\d/,\n // 00 - 99\n match3 = /\\d{3}/,\n // 000 - 999\n match4 = /\\d{4}/,\n // 0000 - 9999\n match6 = /[+-]?\\d{6}/,\n // -999999 - 999999\n match1to2 = /\\d\\d?/,\n // 0 - 99\n match3to4 = /\\d\\d\\d\\d?/,\n // 999 - 9999\n match5to6 = /\\d\\d\\d\\d\\d\\d?/,\n // 99999 - 999999\n match1to3 = /\\d{1,3}/,\n // 0 - 999\n match1to4 = /\\d{1,4}/,\n // 0 - 9999\n match1to6 = /[+-]?\\d{1,6}/,\n // -999999 - 999999\n matchUnsigned = /\\d+/,\n // 0 - inf\n matchSigned = /[+-]?\\d+/,\n // -inf - inf\n matchOffset = /Z|[+-]\\d\\d:?\\d\\d/gi,\n // +00:00 -00:00 +0000 -0000 or Z\n matchShortOffset = /Z|[+-]\\d\\d(?::?\\d\\d)?/gi,\n // +00 -00 +00:00 -00:00 +0000 -0000 or Z\n matchTimestamp = /[+-]?\\d+(\\.\\d{1,3})?/,\n // 123456789 123456789.123\n // any word (or two) characters or numbers including two/three word month in arabic.\n // includes scottish gaelic two word and hyphenated months\n matchWord = /[0-9]{0,256}['a-z\\u00A0-\\u05FF\\u0700-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFF07\\uFF10-\\uFFEF]{1,256}|[\\u0600-\\u06FF\\/]{1,256}(\\s*?[\\u0600-\\u06FF]{1,256}){1,2}/i,\n match1to2NoLeadingZero = /^[1-9]\\d?/,\n // 1-99\n match1to2HasZero = /^([1-9]\\d|\\d)/,\n // 0-99\n regexes;\n regexes = {};\n function addRegexToken(token, regex, strictRegex) {\n regexes[token] = isFunction(regex) ? regex : function (isStrict, localeData) {\n return isStrict && strictRegex ? strictRegex : regex;\n };\n }\n function getParseRegexForToken(token, config) {\n if (!hasOwnProp(regexes, token)) {\n return new RegExp(unescapeFormat(token));\n }\n return regexes[token](config._strict, config._locale);\n }\n\n // Code from http://stackoverflow.com/questions/3561493/is-there-a-regexp-escape-function-in-javascript\n function unescapeFormat(s) {\n return regexEscape(s.replace('\\\\', '').replace(/\\\\(\\[)|\\\\(\\])|\\[([^\\]\\[]*)\\]|\\\\(.)/g, function (matched, p1, p2, p3, p4) {\n return p1 || p2 || p3 || p4;\n }));\n }\n function regexEscape(s) {\n return s.replace(/[-\\/\\\\^$*+?.()|[\\]{}]/g, '\\\\$&');\n }\n function absFloor(number) {\n if (number < 0) {\n // -0 -> 0\n return Math.ceil(number) || 0;\n } else {\n return Math.floor(number);\n }\n }\n function toInt(argumentForCoercion) {\n var coercedNumber = +argumentForCoercion,\n value = 0;\n if (coercedNumber !== 0 && isFinite(coercedNumber)) {\n value = absFloor(coercedNumber);\n }\n return value;\n }\n var tokens = {};\n function addParseToken(token, callback) {\n var i,\n func = callback,\n tokenLen;\n if (typeof token === 'string') {\n token = [token];\n }\n if (isNumber(callback)) {\n func = function (input, array) {\n array[callback] = toInt(input);\n };\n }\n tokenLen = token.length;\n for (i = 0; i < tokenLen; i++) {\n tokens[token[i]] = func;\n }\n }\n function addWeekParseToken(token, callback) {\n addParseToken(token, function (input, array, config, token) {\n config._w = config._w || {};\n callback(input, config._w, config, token);\n });\n }\n function addTimeToArrayFromToken(token, input, config) {\n if (input != null && hasOwnProp(tokens, token)) {\n tokens[token](input, config._a, config, token);\n }\n }\n function isLeapYear(year) {\n return year % 4 === 0 && year % 100 !== 0 || year % 400 === 0;\n }\n var YEAR = 0,\n MONTH = 1,\n DATE = 2,\n HOUR = 3,\n MINUTE = 4,\n SECOND = 5,\n MILLISECOND = 6,\n WEEK = 7,\n WEEKDAY = 8;\n\n // FORMATTING\n\n addFormatToken('Y', 0, 0, function () {\n var y = this.year();\n return y <= 9999 ? zeroFill(y, 4) : '+' + y;\n });\n addFormatToken(0, ['YY', 2], 0, function () {\n return this.year() % 100;\n });\n addFormatToken(0, ['YYYY', 4], 0, 'year');\n addFormatToken(0, ['YYYYY', 5], 0, 'year');\n addFormatToken(0, ['YYYYYY', 6, true], 0, 'year');\n\n // PARSING\n\n addRegexToken('Y', matchSigned);\n addRegexToken('YY', match1to2, match2);\n addRegexToken('YYYY', match1to4, match4);\n addRegexToken('YYYYY', match1to6, match6);\n addRegexToken('YYYYYY', match1to6, match6);\n addParseToken(['YYYYY', 'YYYYYY'], YEAR);\n addParseToken('YYYY', function (input, array) {\n array[YEAR] = input.length === 2 ? hooks.parseTwoDigitYear(input) : toInt(input);\n });\n addParseToken('YY', function (input, array) {\n array[YEAR] = hooks.parseTwoDigitYear(input);\n });\n addParseToken('Y', function (input, array) {\n array[YEAR] = parseInt(input, 10);\n });\n\n // HELPERS\n\n function daysInYear(year) {\n return isLeapYear(year) ? 366 : 365;\n }\n\n // HOOKS\n\n hooks.parseTwoDigitYear = function (input) {\n return toInt(input) + (toInt(input) > 68 ? 1900 : 2000);\n };\n\n // MOMENTS\n\n var getSetYear = makeGetSet('FullYear', true);\n function getIsLeapYear() {\n return isLeapYear(this.year());\n }\n function makeGetSet(unit, keepTime) {\n return function (value) {\n if (value != null) {\n set$1(this, unit, value);\n hooks.updateOffset(this, keepTime);\n return this;\n } else {\n return get(this, unit);\n }\n };\n }\n function get(mom, unit) {\n if (!mom.isValid()) {\n return NaN;\n }\n var d = mom._d,\n isUTC = mom._isUTC;\n switch (unit) {\n case 'Milliseconds':\n return isUTC ? d.getUTCMilliseconds() : d.getMilliseconds();\n case 'Seconds':\n return isUTC ? d.getUTCSeconds() : d.getSeconds();\n case 'Minutes':\n return isUTC ? d.getUTCMinutes() : d.getMinutes();\n case 'Hours':\n return isUTC ? d.getUTCHours() : d.getHours();\n case 'Date':\n return isUTC ? d.getUTCDate() : d.getDate();\n case 'Day':\n return isUTC ? d.getUTCDay() : d.getDay();\n case 'Month':\n return isUTC ? d.getUTCMonth() : d.getMonth();\n case 'FullYear':\n return isUTC ? d.getUTCFullYear() : d.getFullYear();\n default:\n return NaN;\n // Just in case\n }\n }\n function set$1(mom, unit, value) {\n var d, isUTC, year, month, date;\n if (!mom.isValid() || isNaN(value)) {\n return;\n }\n d = mom._d;\n isUTC = mom._isUTC;\n switch (unit) {\n case 'Milliseconds':\n return void (isUTC ? d.setUTCMilliseconds(value) : d.setMilliseconds(value));\n case 'Seconds':\n return void (isUTC ? d.setUTCSeconds(value) : d.setSeconds(value));\n case 'Minutes':\n return void (isUTC ? d.setUTCMinutes(value) : d.setMinutes(value));\n case 'Hours':\n return void (isUTC ? d.setUTCHours(value) : d.setHours(value));\n case 'Date':\n return void (isUTC ? d.setUTCDate(value) : d.setDate(value));\n // case 'Day': // Not real\n // return void (isUTC ? d.setUTCDay(value) : d.setDay(value));\n // case 'Month': // Not used because we need to pass two variables\n // return void (isUTC ? d.setUTCMonth(value) : d.setMonth(value));\n case 'FullYear':\n break;\n // See below ...\n default:\n return;\n // Just in case\n }\n year = value;\n month = mom.month();\n date = mom.date();\n date = date === 29 && month === 1 && !isLeapYear(year) ? 28 : date;\n void (isUTC ? d.setUTCFullYear(year, month, date) : d.setFullYear(year, month, date));\n }\n\n // MOMENTS\n\n function stringGet(units) {\n units = normalizeUnits(units);\n if (isFunction(this[units])) {\n return this[units]();\n }\n return this;\n }\n function stringSet(units, value) {\n if (typeof units === 'object') {\n units = normalizeObjectUnits(units);\n var prioritized = getPrioritizedUnits(units),\n i,\n prioritizedLen = prioritized.length;\n for (i = 0; i < prioritizedLen; i++) {\n this[prioritized[i].unit](units[prioritized[i].unit]);\n }\n } else {\n units = normalizeUnits(units);\n if (isFunction(this[units])) {\n return this[units](value);\n }\n }\n return this;\n }\n function mod(n, x) {\n return (n % x + x) % x;\n }\n var indexOf;\n if (Array.prototype.indexOf) {\n indexOf = Array.prototype.indexOf;\n } else {\n indexOf = function (o) {\n // I know\n var i;\n for (i = 0; i < this.length; ++i) {\n if (this[i] === o) {\n return i;\n }\n }\n return -1;\n };\n }\n function daysInMonth(year, month) {\n if (isNaN(year) || isNaN(month)) {\n return NaN;\n }\n var modMonth = mod(month, 12);\n year += (month - modMonth) / 12;\n return modMonth === 1 ? isLeapYear(year) ? 29 : 28 : 31 - modMonth % 7 % 2;\n }\n\n // FORMATTING\n\n addFormatToken('M', ['MM', 2], 'Mo', function () {\n return this.month() + 1;\n });\n addFormatToken('MMM', 0, 0, function (format) {\n return this.localeData().monthsShort(this, format);\n });\n addFormatToken('MMMM', 0, 0, function (format) {\n return this.localeData().months(this, format);\n });\n\n // PARSING\n\n addRegexToken('M', match1to2, match1to2NoLeadingZero);\n addRegexToken('MM', match1to2, match2);\n addRegexToken('MMM', function (isStrict, locale) {\n return locale.monthsShortRegex(isStrict);\n });\n addRegexToken('MMMM', function (isStrict, locale) {\n return locale.monthsRegex(isStrict);\n });\n addParseToken(['M', 'MM'], function (input, array) {\n array[MONTH] = toInt(input) - 1;\n });\n addParseToken(['MMM', 'MMMM'], function (input, array, config, token) {\n var month = config._locale.monthsParse(input, token, config._strict);\n // if we didn't find a month name, mark the date as invalid.\n if (month != null) {\n array[MONTH] = month;\n } else {\n getParsingFlags(config).invalidMonth = input;\n }\n });\n\n // LOCALES\n\n var defaultLocaleMonths = 'January_February_March_April_May_June_July_August_September_October_November_December'.split('_'),\n defaultLocaleMonthsShort = 'Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec'.split('_'),\n MONTHS_IN_FORMAT = /D[oD]?(\\[[^\\[\\]]*\\]|\\s)+MMMM?/,\n defaultMonthsShortRegex = matchWord,\n defaultMonthsRegex = matchWord;\n function localeMonths(m, format) {\n if (!m) {\n return isArray(this._months) ? this._months : this._months['standalone'];\n }\n return isArray(this._months) ? this._months[m.month()] : this._months[(this._months.isFormat || MONTHS_IN_FORMAT).test(format) ? 'format' : 'standalone'][m.month()];\n }\n function localeMonthsShort(m, format) {\n if (!m) {\n return isArray(this._monthsShort) ? this._monthsShort : this._monthsShort['standalone'];\n }\n return isArray(this._monthsShort) ? this._monthsShort[m.month()] : this._monthsShort[MONTHS_IN_FORMAT.test(format) ? 'format' : 'standalone'][m.month()];\n }\n function handleStrictParse(monthName, format, strict) {\n var i,\n ii,\n mom,\n llc = monthName.toLocaleLowerCase();\n if (!this._monthsParse) {\n // this is not used\n this._monthsParse = [];\n this._longMonthsParse = [];\n this._shortMonthsParse = [];\n for (i = 0; i < 12; ++i) {\n mom = createUTC([2000, i]);\n this._shortMonthsParse[i] = this.monthsShort(mom, '').toLocaleLowerCase();\n this._longMonthsParse[i] = this.months(mom, '').toLocaleLowerCase();\n }\n }\n if (strict) {\n if (format === 'MMM') {\n ii = indexOf.call(this._shortMonthsParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._longMonthsParse, llc);\n return ii !== -1 ? ii : null;\n }\n } else {\n if (format === 'MMM') {\n ii = indexOf.call(this._shortMonthsParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._longMonthsParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._longMonthsParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortMonthsParse, llc);\n return ii !== -1 ? ii : null;\n }\n }\n }\n function localeMonthsParse(monthName, format, strict) {\n var i, mom, regex;\n if (this._monthsParseExact) {\n return handleStrictParse.call(this, monthName, format, strict);\n }\n if (!this._monthsParse) {\n this._monthsParse = [];\n this._longMonthsParse = [];\n this._shortMonthsParse = [];\n }\n\n // TODO: add sorting\n // Sorting makes sure if one month (or abbr) is a prefix of another\n // see sorting in computeMonthsParse\n for (i = 0; i < 12; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, i]);\n if (strict && !this._longMonthsParse[i]) {\n this._longMonthsParse[i] = new RegExp('^' + this.months(mom, '').replace('.', '') + '$', 'i');\n this._shortMonthsParse[i] = new RegExp('^' + this.monthsShort(mom, '').replace('.', '') + '$', 'i');\n }\n if (!strict && !this._monthsParse[i]) {\n regex = '^' + this.months(mom, '') + '|^' + this.monthsShort(mom, '');\n this._monthsParse[i] = new RegExp(regex.replace('.', ''), 'i');\n }\n // test the regex\n if (strict && format === 'MMMM' && this._longMonthsParse[i].test(monthName)) {\n return i;\n } else if (strict && format === 'MMM' && this._shortMonthsParse[i].test(monthName)) {\n return i;\n } else if (!strict && this._monthsParse[i].test(monthName)) {\n return i;\n }\n }\n }\n\n // MOMENTS\n\n function setMonth(mom, value) {\n if (!mom.isValid()) {\n // No op\n return mom;\n }\n if (typeof value === 'string') {\n if (/^\\d+$/.test(value)) {\n value = toInt(value);\n } else {\n value = mom.localeData().monthsParse(value);\n // TODO: Another silent failure?\n if (!isNumber(value)) {\n return mom;\n }\n }\n }\n var month = value,\n date = mom.date();\n date = date < 29 ? date : Math.min(date, daysInMonth(mom.year(), month));\n void (mom._isUTC ? mom._d.setUTCMonth(month, date) : mom._d.setMonth(month, date));\n return mom;\n }\n function getSetMonth(value) {\n if (value != null) {\n setMonth(this, value);\n hooks.updateOffset(this, true);\n return this;\n } else {\n return get(this, 'Month');\n }\n }\n function getDaysInMonth() {\n return daysInMonth(this.year(), this.month());\n }\n function monthsShortRegex(isStrict) {\n if (this._monthsParseExact) {\n if (!hasOwnProp(this, '_monthsRegex')) {\n computeMonthsParse.call(this);\n }\n if (isStrict) {\n return this._monthsShortStrictRegex;\n } else {\n return this._monthsShortRegex;\n }\n } else {\n if (!hasOwnProp(this, '_monthsShortRegex')) {\n this._monthsShortRegex = defaultMonthsShortRegex;\n }\n return this._monthsShortStrictRegex && isStrict ? this._monthsShortStrictRegex : this._monthsShortRegex;\n }\n }\n function monthsRegex(isStrict) {\n if (this._monthsParseExact) {\n if (!hasOwnProp(this, '_monthsRegex')) {\n computeMonthsParse.call(this);\n }\n if (isStrict) {\n return this._monthsStrictRegex;\n } else {\n return this._monthsRegex;\n }\n } else {\n if (!hasOwnProp(this, '_monthsRegex')) {\n this._monthsRegex = defaultMonthsRegex;\n }\n return this._monthsStrictRegex && isStrict ? this._monthsStrictRegex : this._monthsRegex;\n }\n }\n function computeMonthsParse() {\n function cmpLenRev(a, b) {\n return b.length - a.length;\n }\n var shortPieces = [],\n longPieces = [],\n mixedPieces = [],\n i,\n mom,\n shortP,\n longP;\n for (i = 0; i < 12; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, i]);\n shortP = regexEscape(this.monthsShort(mom, ''));\n longP = regexEscape(this.months(mom, ''));\n shortPieces.push(shortP);\n longPieces.push(longP);\n mixedPieces.push(longP);\n mixedPieces.push(shortP);\n }\n // Sorting makes sure if one month (or abbr) is a prefix of another it\n // will match the longer piece.\n shortPieces.sort(cmpLenRev);\n longPieces.sort(cmpLenRev);\n mixedPieces.sort(cmpLenRev);\n this._monthsRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._monthsShortRegex = this._monthsRegex;\n this._monthsStrictRegex = new RegExp('^(' + longPieces.join('|') + ')', 'i');\n this._monthsShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');\n }\n function createDate(y, m, d, h, M, s, ms) {\n // can't just apply() to create a date:\n // https://stackoverflow.com/q/181348\n var date;\n // the date constructor remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n date = new Date(y + 400, m, d, h, M, s, ms);\n if (isFinite(date.getFullYear())) {\n date.setFullYear(y);\n }\n } else {\n date = new Date(y, m, d, h, M, s, ms);\n }\n return date;\n }\n function createUTCDate(y) {\n var date, args;\n // the Date.UTC function remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n args = Array.prototype.slice.call(arguments);\n // preserve leap years using a full 400 year cycle, then reset\n args[0] = y + 400;\n date = new Date(Date.UTC.apply(null, args));\n if (isFinite(date.getUTCFullYear())) {\n date.setUTCFullYear(y);\n }\n } else {\n date = new Date(Date.UTC.apply(null, arguments));\n }\n return date;\n }\n\n // start-of-first-week - start-of-year\n function firstWeekOffset(year, dow, doy) {\n var\n // first-week day -- which january is always in the first week (4 for iso, 1 for other)\n fwd = 7 + dow - doy,\n // first-week day local weekday -- which local weekday is fwd\n fwdlw = (7 + createUTCDate(year, 0, fwd).getUTCDay() - dow) % 7;\n return -fwdlw + fwd - 1;\n }\n\n // https://en.wikipedia.org/wiki/ISO_week_date#Calculating_a_date_given_the_year.2C_week_number_and_weekday\n function dayOfYearFromWeeks(year, week, weekday, dow, doy) {\n var localWeekday = (7 + weekday - dow) % 7,\n weekOffset = firstWeekOffset(year, dow, doy),\n dayOfYear = 1 + 7 * (week - 1) + localWeekday + weekOffset,\n resYear,\n resDayOfYear;\n if (dayOfYear <= 0) {\n resYear = year - 1;\n resDayOfYear = daysInYear(resYear) + dayOfYear;\n } else if (dayOfYear > daysInYear(year)) {\n resYear = year + 1;\n resDayOfYear = dayOfYear - daysInYear(year);\n } else {\n resYear = year;\n resDayOfYear = dayOfYear;\n }\n return {\n year: resYear,\n dayOfYear: resDayOfYear\n };\n }\n function weekOfYear(mom, dow, doy) {\n var weekOffset = firstWeekOffset(mom.year(), dow, doy),\n week = Math.floor((mom.dayOfYear() - weekOffset - 1) / 7) + 1,\n resWeek,\n resYear;\n if (week < 1) {\n resYear = mom.year() - 1;\n resWeek = week + weeksInYear(resYear, dow, doy);\n } else if (week > weeksInYear(mom.year(), dow, doy)) {\n resWeek = week - weeksInYear(mom.year(), dow, doy);\n resYear = mom.year() + 1;\n } else {\n resYear = mom.year();\n resWeek = week;\n }\n return {\n week: resWeek,\n year: resYear\n };\n }\n function weeksInYear(year, dow, doy) {\n var weekOffset = firstWeekOffset(year, dow, doy),\n weekOffsetNext = firstWeekOffset(year + 1, dow, doy);\n return (daysInYear(year) - weekOffset + weekOffsetNext) / 7;\n }\n\n // FORMATTING\n\n addFormatToken('w', ['ww', 2], 'wo', 'week');\n addFormatToken('W', ['WW', 2], 'Wo', 'isoWeek');\n\n // PARSING\n\n addRegexToken('w', match1to2, match1to2NoLeadingZero);\n addRegexToken('ww', match1to2, match2);\n addRegexToken('W', match1to2, match1to2NoLeadingZero);\n addRegexToken('WW', match1to2, match2);\n addWeekParseToken(['w', 'ww', 'W', 'WW'], function (input, week, config, token) {\n week[token.substr(0, 1)] = toInt(input);\n });\n\n // HELPERS\n\n // LOCALES\n\n function localeWeek(mom) {\n return weekOfYear(mom, this._week.dow, this._week.doy).week;\n }\n var defaultLocaleWeek = {\n dow: 0,\n // Sunday is the first day of the week.\n doy: 6 // The week that contains Jan 6th is the first week of the year.\n };\n function localeFirstDayOfWeek() {\n return this._week.dow;\n }\n function localeFirstDayOfYear() {\n return this._week.doy;\n }\n\n // MOMENTS\n\n function getSetWeek(input) {\n var week = this.localeData().week(this);\n return input == null ? week : this.add((input - week) * 7, 'd');\n }\n function getSetISOWeek(input) {\n var week = weekOfYear(this, 1, 4).week;\n return input == null ? week : this.add((input - week) * 7, 'd');\n }\n\n // FORMATTING\n\n addFormatToken('d', 0, 'do', 'day');\n addFormatToken('dd', 0, 0, function (format) {\n return this.localeData().weekdaysMin(this, format);\n });\n addFormatToken('ddd', 0, 0, function (format) {\n return this.localeData().weekdaysShort(this, format);\n });\n addFormatToken('dddd', 0, 0, function (format) {\n return this.localeData().weekdays(this, format);\n });\n addFormatToken('e', 0, 0, 'weekday');\n addFormatToken('E', 0, 0, 'isoWeekday');\n\n // PARSING\n\n addRegexToken('d', match1to2);\n addRegexToken('e', match1to2);\n addRegexToken('E', match1to2);\n addRegexToken('dd', function (isStrict, locale) {\n return locale.weekdaysMinRegex(isStrict);\n });\n addRegexToken('ddd', function (isStrict, locale) {\n return locale.weekdaysShortRegex(isStrict);\n });\n addRegexToken('dddd', function (isStrict, locale) {\n return locale.weekdaysRegex(isStrict);\n });\n addWeekParseToken(['dd', 'ddd', 'dddd'], function (input, week, config, token) {\n var weekday = config._locale.weekdaysParse(input, token, config._strict);\n // if we didn't get a weekday name, mark the date as invalid\n if (weekday != null) {\n week.d = weekday;\n } else {\n getParsingFlags(config).invalidWeekday = input;\n }\n });\n addWeekParseToken(['d', 'e', 'E'], function (input, week, config, token) {\n week[token] = toInt(input);\n });\n\n // HELPERS\n\n function parseWeekday(input, locale) {\n if (typeof input !== 'string') {\n return input;\n }\n if (!isNaN(input)) {\n return parseInt(input, 10);\n }\n input = locale.weekdaysParse(input);\n if (typeof input === 'number') {\n return input;\n }\n return null;\n }\n function parseIsoWeekday(input, locale) {\n if (typeof input === 'string') {\n return locale.weekdaysParse(input) % 7 || 7;\n }\n return isNaN(input) ? null : input;\n }\n\n // LOCALES\n function shiftWeekdays(ws, n) {\n return ws.slice(n, 7).concat(ws.slice(0, n));\n }\n var defaultLocaleWeekdays = 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_'),\n defaultLocaleWeekdaysShort = 'Sun_Mon_Tue_Wed_Thu_Fri_Sat'.split('_'),\n defaultLocaleWeekdaysMin = 'Su_Mo_Tu_We_Th_Fr_Sa'.split('_'),\n defaultWeekdaysRegex = matchWord,\n defaultWeekdaysShortRegex = matchWord,\n defaultWeekdaysMinRegex = matchWord;\n function localeWeekdays(m, format) {\n var weekdays = isArray(this._weekdays) ? this._weekdays : this._weekdays[m && m !== true && this._weekdays.isFormat.test(format) ? 'format' : 'standalone'];\n return m === true ? shiftWeekdays(weekdays, this._week.dow) : m ? weekdays[m.day()] : weekdays;\n }\n function localeWeekdaysShort(m) {\n return m === true ? shiftWeekdays(this._weekdaysShort, this._week.dow) : m ? this._weekdaysShort[m.day()] : this._weekdaysShort;\n }\n function localeWeekdaysMin(m) {\n return m === true ? shiftWeekdays(this._weekdaysMin, this._week.dow) : m ? this._weekdaysMin[m.day()] : this._weekdaysMin;\n }\n function handleStrictParse$1(weekdayName, format, strict) {\n var i,\n ii,\n mom,\n llc = weekdayName.toLocaleLowerCase();\n if (!this._weekdaysParse) {\n this._weekdaysParse = [];\n this._shortWeekdaysParse = [];\n this._minWeekdaysParse = [];\n for (i = 0; i < 7; ++i) {\n mom = createUTC([2000, 1]).day(i);\n this._minWeekdaysParse[i] = this.weekdaysMin(mom, '').toLocaleLowerCase();\n this._shortWeekdaysParse[i] = this.weekdaysShort(mom, '').toLocaleLowerCase();\n this._weekdaysParse[i] = this.weekdays(mom, '').toLocaleLowerCase();\n }\n }\n if (strict) {\n if (format === 'dddd') {\n ii = indexOf.call(this._weekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else if (format === 'ddd') {\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n }\n } else {\n if (format === 'dddd') {\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else if (format === 'ddd') {\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._minWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n } else {\n ii = indexOf.call(this._minWeekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._weekdaysParse, llc);\n if (ii !== -1) {\n return ii;\n }\n ii = indexOf.call(this._shortWeekdaysParse, llc);\n return ii !== -1 ? ii : null;\n }\n }\n }\n function localeWeekdaysParse(weekdayName, format, strict) {\n var i, mom, regex;\n if (this._weekdaysParseExact) {\n return handleStrictParse$1.call(this, weekdayName, format, strict);\n }\n if (!this._weekdaysParse) {\n this._weekdaysParse = [];\n this._minWeekdaysParse = [];\n this._shortWeekdaysParse = [];\n this._fullWeekdaysParse = [];\n }\n for (i = 0; i < 7; i++) {\n // make the regex if we don't have it already\n\n mom = createUTC([2000, 1]).day(i);\n if (strict && !this._fullWeekdaysParse[i]) {\n this._fullWeekdaysParse[i] = new RegExp('^' + this.weekdays(mom, '').replace('.', '\\\\.?') + '$', 'i');\n this._shortWeekdaysParse[i] = new RegExp('^' + this.weekdaysShort(mom, '').replace('.', '\\\\.?') + '$', 'i');\n this._minWeekdaysParse[i] = new RegExp('^' + this.weekdaysMin(mom, '').replace('.', '\\\\.?') + '$', 'i');\n }\n if (!this._weekdaysParse[i]) {\n regex = '^' + this.weekdays(mom, '') + '|^' + this.weekdaysShort(mom, '') + '|^' + this.weekdaysMin(mom, '');\n this._weekdaysParse[i] = new RegExp(regex.replace('.', ''), 'i');\n }\n // test the regex\n if (strict && format === 'dddd' && this._fullWeekdaysParse[i].test(weekdayName)) {\n return i;\n } else if (strict && format === 'ddd' && this._shortWeekdaysParse[i].test(weekdayName)) {\n return i;\n } else if (strict && format === 'dd' && this._minWeekdaysParse[i].test(weekdayName)) {\n return i;\n } else if (!strict && this._weekdaysParse[i].test(weekdayName)) {\n return i;\n }\n }\n }\n\n // MOMENTS\n\n function getSetDayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n var day = get(this, 'Day');\n if (input != null) {\n input = parseWeekday(input, this.localeData());\n return this.add(input - day, 'd');\n } else {\n return day;\n }\n }\n function getSetLocaleDayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n var weekday = (this.day() + 7 - this.localeData()._week.dow) % 7;\n return input == null ? weekday : this.add(input - weekday, 'd');\n }\n function getSetISODayOfWeek(input) {\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n\n // behaves the same as moment#day except\n // as a getter, returns 7 instead of 0 (1-7 range instead of 0-6)\n // as a setter, sunday should belong to the previous week.\n\n if (input != null) {\n var weekday = parseIsoWeekday(input, this.localeData());\n return this.day(this.day() % 7 ? weekday : weekday - 7);\n } else {\n return this.day() || 7;\n }\n }\n function weekdaysRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysStrictRegex;\n } else {\n return this._weekdaysRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n this._weekdaysRegex = defaultWeekdaysRegex;\n }\n return this._weekdaysStrictRegex && isStrict ? this._weekdaysStrictRegex : this._weekdaysRegex;\n }\n }\n function weekdaysShortRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysShortStrictRegex;\n } else {\n return this._weekdaysShortRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysShortRegex')) {\n this._weekdaysShortRegex = defaultWeekdaysShortRegex;\n }\n return this._weekdaysShortStrictRegex && isStrict ? this._weekdaysShortStrictRegex : this._weekdaysShortRegex;\n }\n }\n function weekdaysMinRegex(isStrict) {\n if (this._weekdaysParseExact) {\n if (!hasOwnProp(this, '_weekdaysRegex')) {\n computeWeekdaysParse.call(this);\n }\n if (isStrict) {\n return this._weekdaysMinStrictRegex;\n } else {\n return this._weekdaysMinRegex;\n }\n } else {\n if (!hasOwnProp(this, '_weekdaysMinRegex')) {\n this._weekdaysMinRegex = defaultWeekdaysMinRegex;\n }\n return this._weekdaysMinStrictRegex && isStrict ? this._weekdaysMinStrictRegex : this._weekdaysMinRegex;\n }\n }\n function computeWeekdaysParse() {\n function cmpLenRev(a, b) {\n return b.length - a.length;\n }\n var minPieces = [],\n shortPieces = [],\n longPieces = [],\n mixedPieces = [],\n i,\n mom,\n minp,\n shortp,\n longp;\n for (i = 0; i < 7; i++) {\n // make the regex if we don't have it already\n mom = createUTC([2000, 1]).day(i);\n minp = regexEscape(this.weekdaysMin(mom, ''));\n shortp = regexEscape(this.weekdaysShort(mom, ''));\n longp = regexEscape(this.weekdays(mom, ''));\n minPieces.push(minp);\n shortPieces.push(shortp);\n longPieces.push(longp);\n mixedPieces.push(minp);\n mixedPieces.push(shortp);\n mixedPieces.push(longp);\n }\n // Sorting makes sure if one weekday (or abbr) is a prefix of another it\n // will match the longer piece.\n minPieces.sort(cmpLenRev);\n shortPieces.sort(cmpLenRev);\n longPieces.sort(cmpLenRev);\n mixedPieces.sort(cmpLenRev);\n this._weekdaysRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._weekdaysShortRegex = this._weekdaysRegex;\n this._weekdaysMinRegex = this._weekdaysRegex;\n this._weekdaysStrictRegex = new RegExp('^(' + longPieces.join('|') + ')', 'i');\n this._weekdaysShortStrictRegex = new RegExp('^(' + shortPieces.join('|') + ')', 'i');\n this._weekdaysMinStrictRegex = new RegExp('^(' + minPieces.join('|') + ')', 'i');\n }\n\n // FORMATTING\n\n function hFormat() {\n return this.hours() % 12 || 12;\n }\n function kFormat() {\n return this.hours() || 24;\n }\n addFormatToken('H', ['HH', 2], 0, 'hour');\n addFormatToken('h', ['hh', 2], 0, hFormat);\n addFormatToken('k', ['kk', 2], 0, kFormat);\n addFormatToken('hmm', 0, 0, function () {\n return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2);\n });\n addFormatToken('hmmss', 0, 0, function () {\n return '' + hFormat.apply(this) + zeroFill(this.minutes(), 2) + zeroFill(this.seconds(), 2);\n });\n addFormatToken('Hmm', 0, 0, function () {\n return '' + this.hours() + zeroFill(this.minutes(), 2);\n });\n addFormatToken('Hmmss', 0, 0, function () {\n return '' + this.hours() + zeroFill(this.minutes(), 2) + zeroFill(this.seconds(), 2);\n });\n function meridiem(token, lowercase) {\n addFormatToken(token, 0, 0, function () {\n return this.localeData().meridiem(this.hours(), this.minutes(), lowercase);\n });\n }\n meridiem('a', true);\n meridiem('A', false);\n\n // PARSING\n\n function matchMeridiem(isStrict, locale) {\n return locale._meridiemParse;\n }\n addRegexToken('a', matchMeridiem);\n addRegexToken('A', matchMeridiem);\n addRegexToken('H', match1to2, match1to2HasZero);\n addRegexToken('h', match1to2, match1to2NoLeadingZero);\n addRegexToken('k', match1to2, match1to2NoLeadingZero);\n addRegexToken('HH', match1to2, match2);\n addRegexToken('hh', match1to2, match2);\n addRegexToken('kk', match1to2, match2);\n addRegexToken('hmm', match3to4);\n addRegexToken('hmmss', match5to6);\n addRegexToken('Hmm', match3to4);\n addRegexToken('Hmmss', match5to6);\n addParseToken(['H', 'HH'], HOUR);\n addParseToken(['k', 'kk'], function (input, array, config) {\n var kInput = toInt(input);\n array[HOUR] = kInput === 24 ? 0 : kInput;\n });\n addParseToken(['a', 'A'], function (input, array, config) {\n config._isPm = config._locale.isPM(input);\n config._meridiem = input;\n });\n addParseToken(['h', 'hh'], function (input, array, config) {\n array[HOUR] = toInt(input);\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('hmm', function (input, array, config) {\n var pos = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos));\n array[MINUTE] = toInt(input.substr(pos));\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('hmmss', function (input, array, config) {\n var pos1 = input.length - 4,\n pos2 = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos1));\n array[MINUTE] = toInt(input.substr(pos1, 2));\n array[SECOND] = toInt(input.substr(pos2));\n getParsingFlags(config).bigHour = true;\n });\n addParseToken('Hmm', function (input, array, config) {\n var pos = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos));\n array[MINUTE] = toInt(input.substr(pos));\n });\n addParseToken('Hmmss', function (input, array, config) {\n var pos1 = input.length - 4,\n pos2 = input.length - 2;\n array[HOUR] = toInt(input.substr(0, pos1));\n array[MINUTE] = toInt(input.substr(pos1, 2));\n array[SECOND] = toInt(input.substr(pos2));\n });\n\n // LOCALES\n\n function localeIsPM(input) {\n // IE8 Quirks Mode & IE7 Standards Mode do not allow accessing strings like arrays\n // Using charAt should be more compatible.\n return (input + '').toLowerCase().charAt(0) === 'p';\n }\n var defaultLocaleMeridiemParse = /[ap]\\.?m?\\.?/i,\n // Setting the hour should keep the time, because the user explicitly\n // specified which hour they want. So trying to maintain the same hour (in\n // a new timezone) makes sense. Adding/subtracting hours does not follow\n // this rule.\n getSetHour = makeGetSet('Hours', true);\n function localeMeridiem(hours, minutes, isLower) {\n if (hours > 11) {\n return isLower ? 'pm' : 'PM';\n } else {\n return isLower ? 'am' : 'AM';\n }\n }\n var baseConfig = {\n calendar: defaultCalendar,\n longDateFormat: defaultLongDateFormat,\n invalidDate: defaultInvalidDate,\n ordinal: defaultOrdinal,\n dayOfMonthOrdinalParse: defaultDayOfMonthOrdinalParse,\n relativeTime: defaultRelativeTime,\n months: defaultLocaleMonths,\n monthsShort: defaultLocaleMonthsShort,\n week: defaultLocaleWeek,\n weekdays: defaultLocaleWeekdays,\n weekdaysMin: defaultLocaleWeekdaysMin,\n weekdaysShort: defaultLocaleWeekdaysShort,\n meridiemParse: defaultLocaleMeridiemParse\n };\n\n // internal storage for locale config files\n var locales = {},\n localeFamilies = {},\n globalLocale;\n function commonPrefix(arr1, arr2) {\n var i,\n minl = Math.min(arr1.length, arr2.length);\n for (i = 0; i < minl; i += 1) {\n if (arr1[i] !== arr2[i]) {\n return i;\n }\n }\n return minl;\n }\n function normalizeLocale(key) {\n return key ? key.toLowerCase().replace('_', '-') : key;\n }\n\n // pick the locale from the array\n // try ['en-au', 'en-gb'] as 'en-au', 'en-gb', 'en', as in move through the list trying each\n // substring from most specific to least, but move to the next array item if it's a more specific variant than the current root\n function chooseLocale(names) {\n var i = 0,\n j,\n next,\n locale,\n split;\n while (i < names.length) {\n split = normalizeLocale(names[i]).split('-');\n j = split.length;\n next = normalizeLocale(names[i + 1]);\n next = next ? next.split('-') : null;\n while (j > 0) {\n locale = loadLocale(split.slice(0, j).join('-'));\n if (locale) {\n return locale;\n }\n if (next && next.length >= j && commonPrefix(split, next) >= j - 1) {\n //the next array item is better than a shallower substring of this one\n break;\n }\n j--;\n }\n i++;\n }\n return globalLocale;\n }\n function isLocaleNameSane(name) {\n // Prevent names that look like filesystem paths, i.e contain '/' or '\\'\n // Ensure name is available and function returns boolean\n return !!(name && name.match('^[^/\\\\\\\\]*$'));\n }\n function loadLocale(name) {\n var oldLocale = null,\n aliasedRequire;\n // TODO: Find a better way to register and load all the locales in Node\n if (locales[name] === undefined && typeof module !== 'undefined' && module && module.exports && isLocaleNameSane(name)) {\n try {\n oldLocale = globalLocale._abbr;\n aliasedRequire = require;\n aliasedRequire('./locale/' + name);\n getSetGlobalLocale(oldLocale);\n } catch (e) {\n // mark as not found to avoid repeating expensive file require call causing high CPU\n // when trying to find en-US, en_US, en-us for every format call\n locales[name] = null; // null means not found\n }\n }\n return locales[name];\n }\n\n // This function will load locale and then set the global locale. If\n // no arguments are passed in, it will simply return the current global\n // locale key.\n function getSetGlobalLocale(key, values) {\n var data;\n if (key) {\n if (isUndefined(values)) {\n data = getLocale(key);\n } else {\n data = defineLocale(key, values);\n }\n if (data) {\n // moment.duration._locale = moment._locale = data;\n globalLocale = data;\n } else {\n if (typeof console !== 'undefined' && console.warn) {\n //warn user if arguments are passed but the locale could not be set\n console.warn('Locale ' + key + ' not found. Did you forget to load it?');\n }\n }\n }\n return globalLocale._abbr;\n }\n function defineLocale(name, config) {\n if (config !== null) {\n var locale,\n parentConfig = baseConfig;\n config.abbr = name;\n if (locales[name] != null) {\n deprecateSimple('defineLocaleOverride', 'use moment.updateLocale(localeName, config) to change ' + 'an existing locale. moment.defineLocale(localeName, ' + 'config) should only be used for creating a new locale ' + 'See http://momentjs.com/guides/#/warnings/define-locale/ for more info.');\n parentConfig = locales[name]._config;\n } else if (config.parentLocale != null) {\n if (locales[config.parentLocale] != null) {\n parentConfig = locales[config.parentLocale]._config;\n } else {\n locale = loadLocale(config.parentLocale);\n if (locale != null) {\n parentConfig = locale._config;\n } else {\n if (!localeFamilies[config.parentLocale]) {\n localeFamilies[config.parentLocale] = [];\n }\n localeFamilies[config.parentLocale].push({\n name: name,\n config: config\n });\n return null;\n }\n }\n }\n locales[name] = new Locale(mergeConfigs(parentConfig, config));\n if (localeFamilies[name]) {\n localeFamilies[name].forEach(function (x) {\n defineLocale(x.name, x.config);\n });\n }\n\n // backwards compat for now: also set the locale\n // make sure we set the locale AFTER all child locales have been\n // created, so we won't end up with the child locale set.\n getSetGlobalLocale(name);\n return locales[name];\n } else {\n // useful for testing\n delete locales[name];\n return null;\n }\n }\n function updateLocale(name, config) {\n if (config != null) {\n var locale,\n tmpLocale,\n parentConfig = baseConfig;\n if (locales[name] != null && locales[name].parentLocale != null) {\n // Update existing child locale in-place to avoid memory-leaks\n locales[name].set(mergeConfigs(locales[name]._config, config));\n } else {\n // MERGE\n tmpLocale = loadLocale(name);\n if (tmpLocale != null) {\n parentConfig = tmpLocale._config;\n }\n config = mergeConfigs(parentConfig, config);\n if (tmpLocale == null) {\n // updateLocale is called for creating a new locale\n // Set abbr so it will have a name (getters return\n // undefined otherwise).\n config.abbr = name;\n }\n locale = new Locale(config);\n locale.parentLocale = locales[name];\n locales[name] = locale;\n }\n\n // backwards compat for now: also set the locale\n getSetGlobalLocale(name);\n } else {\n // pass null for config to unupdate, useful for tests\n if (locales[name] != null) {\n if (locales[name].parentLocale != null) {\n locales[name] = locales[name].parentLocale;\n if (name === getSetGlobalLocale()) {\n getSetGlobalLocale(name);\n }\n } else if (locales[name] != null) {\n delete locales[name];\n }\n }\n }\n return locales[name];\n }\n\n // returns locale data\n function getLocale(key) {\n var locale;\n if (key && key._locale && key._locale._abbr) {\n key = key._locale._abbr;\n }\n if (!key) {\n return globalLocale;\n }\n if (!isArray(key)) {\n //short-circuit everything else\n locale = loadLocale(key);\n if (locale) {\n return locale;\n }\n key = [key];\n }\n return chooseLocale(key);\n }\n function listLocales() {\n return keys(locales);\n }\n function checkOverflow(m) {\n var overflow,\n a = m._a;\n if (a && getParsingFlags(m).overflow === -2) {\n overflow = a[MONTH] < 0 || a[MONTH] > 11 ? MONTH : a[DATE] < 1 || a[DATE] > daysInMonth(a[YEAR], a[MONTH]) ? DATE : a[HOUR] < 0 || a[HOUR] > 24 || a[HOUR] === 24 && (a[MINUTE] !== 0 || a[SECOND] !== 0 || a[MILLISECOND] !== 0) ? HOUR : a[MINUTE] < 0 || a[MINUTE] > 59 ? MINUTE : a[SECOND] < 0 || a[SECOND] > 59 ? SECOND : a[MILLISECOND] < 0 || a[MILLISECOND] > 999 ? MILLISECOND : -1;\n if (getParsingFlags(m)._overflowDayOfYear && (overflow < YEAR || overflow > DATE)) {\n overflow = DATE;\n }\n if (getParsingFlags(m)._overflowWeeks && overflow === -1) {\n overflow = WEEK;\n }\n if (getParsingFlags(m)._overflowWeekday && overflow === -1) {\n overflow = WEEKDAY;\n }\n getParsingFlags(m).overflow = overflow;\n }\n return m;\n }\n\n // iso 8601 regex\n // 0000-00-00 0000-W00 or 0000-W00-0 + T + 00 or 00:00 or 00:00:00 or 00:00:00.000 + +00:00 or +0000 or +00)\n var extendedIsoRegex = /^\\s*((?:[+-]\\d{6}|\\d{4})-(?:\\d\\d-\\d\\d|W\\d\\d-\\d|W\\d\\d|\\d\\d\\d|\\d\\d))(?:(T| )(\\d\\d(?::\\d\\d(?::\\d\\d(?:[.,]\\d+)?)?)?)([+-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?$/,\n basicIsoRegex = /^\\s*((?:[+-]\\d{6}|\\d{4})(?:\\d\\d\\d\\d|W\\d\\d\\d|W\\d\\d|\\d\\d\\d|\\d\\d|))(?:(T| )(\\d\\d(?:\\d\\d(?:\\d\\d(?:[.,]\\d+)?)?)?)([+-]\\d\\d(?::?\\d\\d)?|\\s*Z)?)?$/,\n tzRegex = /Z|[+-]\\d\\d(?::?\\d\\d)?/,\n isoDates = [['YYYYYY-MM-DD', /[+-]\\d{6}-\\d\\d-\\d\\d/], ['YYYY-MM-DD', /\\d{4}-\\d\\d-\\d\\d/], ['GGGG-[W]WW-E', /\\d{4}-W\\d\\d-\\d/], ['GGGG-[W]WW', /\\d{4}-W\\d\\d/, false], ['YYYY-DDD', /\\d{4}-\\d{3}/], ['YYYY-MM', /\\d{4}-\\d\\d/, false], ['YYYYYYMMDD', /[+-]\\d{10}/], ['YYYYMMDD', /\\d{8}/], ['GGGG[W]WWE', /\\d{4}W\\d{3}/], ['GGGG[W]WW', /\\d{4}W\\d{2}/, false], ['YYYYDDD', /\\d{7}/], ['YYYYMM', /\\d{6}/, false], ['YYYY', /\\d{4}/, false]],\n // iso time formats and regexes\n isoTimes = [['HH:mm:ss.SSSS', /\\d\\d:\\d\\d:\\d\\d\\.\\d+/], ['HH:mm:ss,SSSS', /\\d\\d:\\d\\d:\\d\\d,\\d+/], ['HH:mm:ss', /\\d\\d:\\d\\d:\\d\\d/], ['HH:mm', /\\d\\d:\\d\\d/], ['HHmmss.SSSS', /\\d\\d\\d\\d\\d\\d\\.\\d+/], ['HHmmss,SSSS', /\\d\\d\\d\\d\\d\\d,\\d+/], ['HHmmss', /\\d\\d\\d\\d\\d\\d/], ['HHmm', /\\d\\d\\d\\d/], ['HH', /\\d\\d/]],\n aspNetJsonRegex = /^\\/?Date\\((-?\\d+)/i,\n // RFC 2822 regex: For details see https://tools.ietf.org/html/rfc2822#section-3.3\n rfc2822 = /^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\\s)?(\\d{1,2})\\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\\s(\\d{2,4})\\s(\\d\\d):(\\d\\d)(?::(\\d\\d))?\\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\\d{4}))$/,\n obsOffsets = {\n UT: 0,\n GMT: 0,\n EDT: -4 * 60,\n EST: -5 * 60,\n CDT: -5 * 60,\n CST: -6 * 60,\n MDT: -6 * 60,\n MST: -7 * 60,\n PDT: -7 * 60,\n PST: -8 * 60\n };\n\n // date from iso format\n function configFromISO(config) {\n var i,\n l,\n string = config._i,\n match = extendedIsoRegex.exec(string) || basicIsoRegex.exec(string),\n allowTime,\n dateFormat,\n timeFormat,\n tzFormat,\n isoDatesLen = isoDates.length,\n isoTimesLen = isoTimes.length;\n if (match) {\n getParsingFlags(config).iso = true;\n for (i = 0, l = isoDatesLen; i < l; i++) {\n if (isoDates[i][1].exec(match[1])) {\n dateFormat = isoDates[i][0];\n allowTime = isoDates[i][2] !== false;\n break;\n }\n }\n if (dateFormat == null) {\n config._isValid = false;\n return;\n }\n if (match[3]) {\n for (i = 0, l = isoTimesLen; i < l; i++) {\n if (isoTimes[i][1].exec(match[3])) {\n // match[2] should be 'T' or space\n timeFormat = (match[2] || ' ') + isoTimes[i][0];\n break;\n }\n }\n if (timeFormat == null) {\n config._isValid = false;\n return;\n }\n }\n if (!allowTime && timeFormat != null) {\n config._isValid = false;\n return;\n }\n if (match[4]) {\n if (tzRegex.exec(match[4])) {\n tzFormat = 'Z';\n } else {\n config._isValid = false;\n return;\n }\n }\n config._f = dateFormat + (timeFormat || '') + (tzFormat || '');\n configFromStringAndFormat(config);\n } else {\n config._isValid = false;\n }\n }\n function extractFromRFC2822Strings(yearStr, monthStr, dayStr, hourStr, minuteStr, secondStr) {\n var result = [untruncateYear(yearStr), defaultLocaleMonthsShort.indexOf(monthStr), parseInt(dayStr, 10), parseInt(hourStr, 10), parseInt(minuteStr, 10)];\n if (secondStr) {\n result.push(parseInt(secondStr, 10));\n }\n return result;\n }\n function untruncateYear(yearStr) {\n var year = parseInt(yearStr, 10);\n if (year <= 49) {\n return 2000 + year;\n } else if (year <= 999) {\n return 1900 + year;\n }\n return year;\n }\n function preprocessRFC2822(s) {\n // Remove comments and folding whitespace and replace multiple-spaces with a single space\n return s.replace(/\\([^()]*\\)|[\\n\\t]/g, ' ').replace(/(\\s\\s+)/g, ' ').replace(/^\\s\\s*/, '').replace(/\\s\\s*$/, '');\n }\n function checkWeekday(weekdayStr, parsedInput, config) {\n if (weekdayStr) {\n // TODO: Replace the vanilla JS Date object with an independent day-of-week check.\n var weekdayProvided = defaultLocaleWeekdaysShort.indexOf(weekdayStr),\n weekdayActual = new Date(parsedInput[0], parsedInput[1], parsedInput[2]).getDay();\n if (weekdayProvided !== weekdayActual) {\n getParsingFlags(config).weekdayMismatch = true;\n config._isValid = false;\n return false;\n }\n }\n return true;\n }\n function calculateOffset(obsOffset, militaryOffset, numOffset) {\n if (obsOffset) {\n return obsOffsets[obsOffset];\n } else if (militaryOffset) {\n // the only allowed military tz is Z\n return 0;\n } else {\n var hm = parseInt(numOffset, 10),\n m = hm % 100,\n h = (hm - m) / 100;\n return h * 60 + m;\n }\n }\n\n // date and time from ref 2822 format\n function configFromRFC2822(config) {\n var match = rfc2822.exec(preprocessRFC2822(config._i)),\n parsedArray;\n if (match) {\n parsedArray = extractFromRFC2822Strings(match[4], match[3], match[2], match[5], match[6], match[7]);\n if (!checkWeekday(match[1], parsedArray, config)) {\n return;\n }\n config._a = parsedArray;\n config._tzm = calculateOffset(match[8], match[9], match[10]);\n config._d = createUTCDate.apply(null, config._a);\n config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);\n getParsingFlags(config).rfc2822 = true;\n } else {\n config._isValid = false;\n }\n }\n\n // date from 1) ASP.NET, 2) ISO, 3) RFC 2822 formats, or 4) optional fallback if parsing isn't strict\n function configFromString(config) {\n var matched = aspNetJsonRegex.exec(config._i);\n if (matched !== null) {\n config._d = new Date(+matched[1]);\n return;\n }\n configFromISO(config);\n if (config._isValid === false) {\n delete config._isValid;\n } else {\n return;\n }\n configFromRFC2822(config);\n if (config._isValid === false) {\n delete config._isValid;\n } else {\n return;\n }\n if (config._strict) {\n config._isValid = false;\n } else {\n // Final attempt, use Input Fallback\n hooks.createFromInputFallback(config);\n }\n }\n hooks.createFromInputFallback = deprecate('value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), ' + 'which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are ' + 'discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.', function (config) {\n config._d = new Date(config._i + (config._useUTC ? ' UTC' : ''));\n });\n\n // Pick the first defined of two or three arguments.\n function defaults(a, b, c) {\n if (a != null) {\n return a;\n }\n if (b != null) {\n return b;\n }\n return c;\n }\n function currentDateArray(config) {\n // hooks is actually the exported moment object\n var nowValue = new Date(hooks.now());\n if (config._useUTC) {\n return [nowValue.getUTCFullYear(), nowValue.getUTCMonth(), nowValue.getUTCDate()];\n }\n return [nowValue.getFullYear(), nowValue.getMonth(), nowValue.getDate()];\n }\n\n // convert an array to a date.\n // the array should mirror the parameters below\n // note: all values past the year are optional and will default to the lowest possible value.\n // [year, month, day , hour, minute, second, millisecond]\n function configFromArray(config) {\n var i,\n date,\n input = [],\n currentDate,\n expectedWeekday,\n yearToUse;\n if (config._d) {\n return;\n }\n currentDate = currentDateArray(config);\n\n //compute day of the year from weeks and weekdays\n if (config._w && config._a[DATE] == null && config._a[MONTH] == null) {\n dayOfYearFromWeekInfo(config);\n }\n\n //if the day of the year is set, figure out what it is\n if (config._dayOfYear != null) {\n yearToUse = defaults(config._a[YEAR], currentDate[YEAR]);\n if (config._dayOfYear > daysInYear(yearToUse) || config._dayOfYear === 0) {\n getParsingFlags(config)._overflowDayOfYear = true;\n }\n date = createUTCDate(yearToUse, 0, config._dayOfYear);\n config._a[MONTH] = date.getUTCMonth();\n config._a[DATE] = date.getUTCDate();\n }\n\n // Default to current date.\n // * if no year, month, day of month are given, default to today\n // * if day of month is given, default month and year\n // * if month is given, default only year\n // * if year is given, don't default anything\n for (i = 0; i < 3 && config._a[i] == null; ++i) {\n config._a[i] = input[i] = currentDate[i];\n }\n\n // Zero out whatever was not defaulted, including time\n for (; i < 7; i++) {\n config._a[i] = input[i] = config._a[i] == null ? i === 2 ? 1 : 0 : config._a[i];\n }\n\n // Check for 24:00:00.000\n if (config._a[HOUR] === 24 && config._a[MINUTE] === 0 && config._a[SECOND] === 0 && config._a[MILLISECOND] === 0) {\n config._nextDay = true;\n config._a[HOUR] = 0;\n }\n config._d = (config._useUTC ? createUTCDate : createDate).apply(null, input);\n expectedWeekday = config._useUTC ? config._d.getUTCDay() : config._d.getDay();\n\n // Apply timezone offset from input. The actual utcOffset can be changed\n // with parseZone.\n if (config._tzm != null) {\n config._d.setUTCMinutes(config._d.getUTCMinutes() - config._tzm);\n }\n if (config._nextDay) {\n config._a[HOUR] = 24;\n }\n\n // check for mismatching day of week\n if (config._w && typeof config._w.d !== 'undefined' && config._w.d !== expectedWeekday) {\n getParsingFlags(config).weekdayMismatch = true;\n }\n }\n function dayOfYearFromWeekInfo(config) {\n var w, weekYear, week, weekday, dow, doy, temp, weekdayOverflow, curWeek;\n w = config._w;\n if (w.GG != null || w.W != null || w.E != null) {\n dow = 1;\n doy = 4;\n\n // TODO: We need to take the current isoWeekYear, but that depends on\n // how we interpret now (local, utc, fixed offset). So create\n // a now version of current config (take local/utc/offset flags, and\n // create now).\n weekYear = defaults(w.GG, config._a[YEAR], weekOfYear(createLocal(), 1, 4).year);\n week = defaults(w.W, 1);\n weekday = defaults(w.E, 1);\n if (weekday < 1 || weekday > 7) {\n weekdayOverflow = true;\n }\n } else {\n dow = config._locale._week.dow;\n doy = config._locale._week.doy;\n curWeek = weekOfYear(createLocal(), dow, doy);\n weekYear = defaults(w.gg, config._a[YEAR], curWeek.year);\n\n // Default to current week.\n week = defaults(w.w, curWeek.week);\n if (w.d != null) {\n // weekday -- low day numbers are considered next week\n weekday = w.d;\n if (weekday < 0 || weekday > 6) {\n weekdayOverflow = true;\n }\n } else if (w.e != null) {\n // local weekday -- counting starts from beginning of week\n weekday = w.e + dow;\n if (w.e < 0 || w.e > 6) {\n weekdayOverflow = true;\n }\n } else {\n // default to beginning of week\n weekday = dow;\n }\n }\n if (week < 1 || week > weeksInYear(weekYear, dow, doy)) {\n getParsingFlags(config)._overflowWeeks = true;\n } else if (weekdayOverflow != null) {\n getParsingFlags(config)._overflowWeekday = true;\n } else {\n temp = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy);\n config._a[YEAR] = temp.year;\n config._dayOfYear = temp.dayOfYear;\n }\n }\n\n // constant that refers to the ISO standard\n hooks.ISO_8601 = function () {};\n\n // constant that refers to the RFC 2822 form\n hooks.RFC_2822 = function () {};\n\n // date from string and format string\n function configFromStringAndFormat(config) {\n // TODO: Move this to another part of the creation flow to prevent circular deps\n if (config._f === hooks.ISO_8601) {\n configFromISO(config);\n return;\n }\n if (config._f === hooks.RFC_2822) {\n configFromRFC2822(config);\n return;\n }\n config._a = [];\n getParsingFlags(config).empty = true;\n\n // This array is used to make a Date, either with `new Date` or `Date.UTC`\n var string = '' + config._i,\n i,\n parsedInput,\n tokens,\n token,\n skipped,\n stringLength = string.length,\n totalParsedInputLength = 0,\n era,\n tokenLen;\n tokens = expandFormat(config._f, config._locale).match(formattingTokens) || [];\n tokenLen = tokens.length;\n for (i = 0; i < tokenLen; i++) {\n token = tokens[i];\n parsedInput = (string.match(getParseRegexForToken(token, config)) || [])[0];\n if (parsedInput) {\n skipped = string.substr(0, string.indexOf(parsedInput));\n if (skipped.length > 0) {\n getParsingFlags(config).unusedInput.push(skipped);\n }\n string = string.slice(string.indexOf(parsedInput) + parsedInput.length);\n totalParsedInputLength += parsedInput.length;\n }\n // don't parse if it's not a known token\n if (formatTokenFunctions[token]) {\n if (parsedInput) {\n getParsingFlags(config).empty = false;\n } else {\n getParsingFlags(config).unusedTokens.push(token);\n }\n addTimeToArrayFromToken(token, parsedInput, config);\n } else if (config._strict && !parsedInput) {\n getParsingFlags(config).unusedTokens.push(token);\n }\n }\n\n // add remaining unparsed input length to the string\n getParsingFlags(config).charsLeftOver = stringLength - totalParsedInputLength;\n if (string.length > 0) {\n getParsingFlags(config).unusedInput.push(string);\n }\n\n // clear _12h flag if hour is <= 12\n if (config._a[HOUR] <= 12 && getParsingFlags(config).bigHour === true && config._a[HOUR] > 0) {\n getParsingFlags(config).bigHour = undefined;\n }\n getParsingFlags(config).parsedDateParts = config._a.slice(0);\n getParsingFlags(config).meridiem = config._meridiem;\n // handle meridiem\n config._a[HOUR] = meridiemFixWrap(config._locale, config._a[HOUR], config._meridiem);\n\n // handle era\n era = getParsingFlags(config).era;\n if (era !== null) {\n config._a[YEAR] = config._locale.erasConvertYear(era, config._a[YEAR]);\n }\n configFromArray(config);\n checkOverflow(config);\n }\n function meridiemFixWrap(locale, hour, meridiem) {\n var isPm;\n if (meridiem == null) {\n // nothing to do\n return hour;\n }\n if (locale.meridiemHour != null) {\n return locale.meridiemHour(hour, meridiem);\n } else if (locale.isPM != null) {\n // Fallback\n isPm = locale.isPM(meridiem);\n if (isPm && hour < 12) {\n hour += 12;\n }\n if (!isPm && hour === 12) {\n hour = 0;\n }\n return hour;\n } else {\n // this is not supposed to happen\n return hour;\n }\n }\n\n // date from string and array of format strings\n function configFromStringAndArray(config) {\n var tempConfig,\n bestMoment,\n scoreToBeat,\n i,\n currentScore,\n validFormatFound,\n bestFormatIsValid = false,\n configfLen = config._f.length;\n if (configfLen === 0) {\n getParsingFlags(config).invalidFormat = true;\n config._d = new Date(NaN);\n return;\n }\n for (i = 0; i < configfLen; i++) {\n currentScore = 0;\n validFormatFound = false;\n tempConfig = copyConfig({}, config);\n if (config._useUTC != null) {\n tempConfig._useUTC = config._useUTC;\n }\n tempConfig._f = config._f[i];\n configFromStringAndFormat(tempConfig);\n if (isValid(tempConfig)) {\n validFormatFound = true;\n }\n\n // if there is any input that was not parsed add a penalty for that format\n currentScore += getParsingFlags(tempConfig).charsLeftOver;\n\n //or tokens\n currentScore += getParsingFlags(tempConfig).unusedTokens.length * 10;\n getParsingFlags(tempConfig).score = currentScore;\n if (!bestFormatIsValid) {\n if (scoreToBeat == null || currentScore < scoreToBeat || validFormatFound) {\n scoreToBeat = currentScore;\n bestMoment = tempConfig;\n if (validFormatFound) {\n bestFormatIsValid = true;\n }\n }\n } else {\n if (currentScore < scoreToBeat) {\n scoreToBeat = currentScore;\n bestMoment = tempConfig;\n }\n }\n }\n extend(config, bestMoment || tempConfig);\n }\n function configFromObject(config) {\n if (config._d) {\n return;\n }\n var i = normalizeObjectUnits(config._i),\n dayOrDate = i.day === undefined ? i.date : i.day;\n config._a = map([i.year, i.month, dayOrDate, i.hour, i.minute, i.second, i.millisecond], function (obj) {\n return obj && parseInt(obj, 10);\n });\n configFromArray(config);\n }\n function createFromConfig(config) {\n var res = new Moment(checkOverflow(prepareConfig(config)));\n if (res._nextDay) {\n // Adding is smart enough around DST\n res.add(1, 'd');\n res._nextDay = undefined;\n }\n return res;\n }\n function prepareConfig(config) {\n var input = config._i,\n format = config._f;\n config._locale = config._locale || getLocale(config._l);\n if (input === null || format === undefined && input === '') {\n return createInvalid({\n nullInput: true\n });\n }\n if (typeof input === 'string') {\n config._i = input = config._locale.preparse(input);\n }\n if (isMoment(input)) {\n return new Moment(checkOverflow(input));\n } else if (isDate(input)) {\n config._d = input;\n } else if (isArray(format)) {\n configFromStringAndArray(config);\n } else if (format) {\n configFromStringAndFormat(config);\n } else {\n configFromInput(config);\n }\n if (!isValid(config)) {\n config._d = null;\n }\n return config;\n }\n function configFromInput(config) {\n var input = config._i;\n if (isUndefined(input)) {\n config._d = new Date(hooks.now());\n } else if (isDate(input)) {\n config._d = new Date(input.valueOf());\n } else if (typeof input === 'string') {\n configFromString(config);\n } else if (isArray(input)) {\n config._a = map(input.slice(0), function (obj) {\n return parseInt(obj, 10);\n });\n configFromArray(config);\n } else if (isObject(input)) {\n configFromObject(config);\n } else if (isNumber(input)) {\n // from milliseconds\n config._d = new Date(input);\n } else {\n hooks.createFromInputFallback(config);\n }\n }\n function createLocalOrUTC(input, format, locale, strict, isUTC) {\n var c = {};\n if (format === true || format === false) {\n strict = format;\n format = undefined;\n }\n if (locale === true || locale === false) {\n strict = locale;\n locale = undefined;\n }\n if (isObject(input) && isObjectEmpty(input) || isArray(input) && input.length === 0) {\n input = undefined;\n }\n // object construction must be done this way.\n // https://github.com/moment/moment/issues/1423\n c._isAMomentObject = true;\n c._useUTC = c._isUTC = isUTC;\n c._l = locale;\n c._i = input;\n c._f = format;\n c._strict = strict;\n return createFromConfig(c);\n }\n function createLocal(input, format, locale, strict) {\n return createLocalOrUTC(input, format, locale, strict, false);\n }\n var prototypeMin = deprecate('moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/', function () {\n var other = createLocal.apply(null, arguments);\n if (this.isValid() && other.isValid()) {\n return other < this ? this : other;\n } else {\n return createInvalid();\n }\n }),\n prototypeMax = deprecate('moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/', function () {\n var other = createLocal.apply(null, arguments);\n if (this.isValid() && other.isValid()) {\n return other > this ? this : other;\n } else {\n return createInvalid();\n }\n });\n\n // Pick a moment m from moments so that m[fn](other) is true for all\n // other. This relies on the function fn to be transitive.\n //\n // moments should either be an array of moment objects or an array, whose\n // first element is an array of moment objects.\n function pickBy(fn, moments) {\n var res, i;\n if (moments.length === 1 && isArray(moments[0])) {\n moments = moments[0];\n }\n if (!moments.length) {\n return createLocal();\n }\n res = moments[0];\n for (i = 1; i < moments.length; ++i) {\n if (!moments[i].isValid() || moments[i][fn](res)) {\n res = moments[i];\n }\n }\n return res;\n }\n\n // TODO: Use [].sort instead?\n function min() {\n var args = [].slice.call(arguments, 0);\n return pickBy('isBefore', args);\n }\n function max() {\n var args = [].slice.call(arguments, 0);\n return pickBy('isAfter', args);\n }\n var now = function () {\n return Date.now ? Date.now() : +new Date();\n };\n var ordering = ['year', 'quarter', 'month', 'week', 'day', 'hour', 'minute', 'second', 'millisecond'];\n function isDurationValid(m) {\n var key,\n unitHasDecimal = false,\n i,\n orderLen = ordering.length;\n for (key in m) {\n if (hasOwnProp(m, key) && !(indexOf.call(ordering, key) !== -1 && (m[key] == null || !isNaN(m[key])))) {\n return false;\n }\n }\n for (i = 0; i < orderLen; ++i) {\n if (m[ordering[i]]) {\n if (unitHasDecimal) {\n return false; // only allow non-integers for smallest unit\n }\n if (parseFloat(m[ordering[i]]) !== toInt(m[ordering[i]])) {\n unitHasDecimal = true;\n }\n }\n }\n return true;\n }\n function isValid$1() {\n return this._isValid;\n }\n function createInvalid$1() {\n return createDuration(NaN);\n }\n function Duration(duration) {\n var normalizedInput = normalizeObjectUnits(duration),\n years = normalizedInput.year || 0,\n quarters = normalizedInput.quarter || 0,\n months = normalizedInput.month || 0,\n weeks = normalizedInput.week || normalizedInput.isoWeek || 0,\n days = normalizedInput.day || 0,\n hours = normalizedInput.hour || 0,\n minutes = normalizedInput.minute || 0,\n seconds = normalizedInput.second || 0,\n milliseconds = normalizedInput.millisecond || 0;\n this._isValid = isDurationValid(normalizedInput);\n\n // representation for dateAddRemove\n this._milliseconds = +milliseconds + seconds * 1e3 +\n // 1000\n minutes * 6e4 +\n // 1000 * 60\n hours * 1000 * 60 * 60; //using 1000 * 60 * 60 instead of 36e5 to avoid floating point rounding errors https://github.com/moment/moment/issues/2978\n // Because of dateAddRemove treats 24 hours as different from a\n // day when working around DST, we need to store them separately\n this._days = +days + weeks * 7;\n // It is impossible to translate months into days without knowing\n // which months you are are talking about, so we have to store\n // it separately.\n this._months = +months + quarters * 3 + years * 12;\n this._data = {};\n this._locale = getLocale();\n this._bubble();\n }\n function isDuration(obj) {\n return obj instanceof Duration;\n }\n function absRound(number) {\n if (number < 0) {\n return Math.round(-1 * number) * -1;\n } else {\n return Math.round(number);\n }\n }\n\n // compare two arrays, return the number of differences\n function compareArrays(array1, array2, dontConvert) {\n var len = Math.min(array1.length, array2.length),\n lengthDiff = Math.abs(array1.length - array2.length),\n diffs = 0,\n i;\n for (i = 0; i < len; i++) {\n if (dontConvert && array1[i] !== array2[i] || !dontConvert && toInt(array1[i]) !== toInt(array2[i])) {\n diffs++;\n }\n }\n return diffs + lengthDiff;\n }\n\n // FORMATTING\n\n function offset(token, separator) {\n addFormatToken(token, 0, 0, function () {\n var offset = this.utcOffset(),\n sign = '+';\n if (offset < 0) {\n offset = -offset;\n sign = '-';\n }\n return sign + zeroFill(~~(offset / 60), 2) + separator + zeroFill(~~offset % 60, 2);\n });\n }\n offset('Z', ':');\n offset('ZZ', '');\n\n // PARSING\n\n addRegexToken('Z', matchShortOffset);\n addRegexToken('ZZ', matchShortOffset);\n addParseToken(['Z', 'ZZ'], function (input, array, config) {\n config._useUTC = true;\n config._tzm = offsetFromString(matchShortOffset, input);\n });\n\n // HELPERS\n\n // timezone chunker\n // '+10:00' > ['10', '00']\n // '-1530' > ['-15', '30']\n var chunkOffset = /([\\+\\-]|\\d\\d)/gi;\n function offsetFromString(matcher, string) {\n var matches = (string || '').match(matcher),\n chunk,\n parts,\n minutes;\n if (matches === null) {\n return null;\n }\n chunk = matches[matches.length - 1] || [];\n parts = (chunk + '').match(chunkOffset) || ['-', 0, 0];\n minutes = +(parts[1] * 60) + toInt(parts[2]);\n return minutes === 0 ? 0 : parts[0] === '+' ? minutes : -minutes;\n }\n\n // Return a moment from input, that is local/utc/zone equivalent to model.\n function cloneWithOffset(input, model) {\n var res, diff;\n if (model._isUTC) {\n res = model.clone();\n diff = (isMoment(input) || isDate(input) ? input.valueOf() : createLocal(input).valueOf()) - res.valueOf();\n // Use low-level api, because this fn is low-level api.\n res._d.setTime(res._d.valueOf() + diff);\n hooks.updateOffset(res, false);\n return res;\n } else {\n return createLocal(input).local();\n }\n }\n function getDateOffset(m) {\n // On Firefox.24 Date#getTimezoneOffset returns a floating point.\n // https://github.com/moment/moment/pull/1871\n return -Math.round(m._d.getTimezoneOffset());\n }\n\n // HOOKS\n\n // This function will be called whenever a moment is mutated.\n // It is intended to keep the offset in sync with the timezone.\n hooks.updateOffset = function () {};\n\n // MOMENTS\n\n // keepLocalTime = true means only change the timezone, without\n // affecting the local hour. So 5:31:26 +0300 --[utcOffset(2, true)]-->\n // 5:31:26 +0200 It is possible that 5:31:26 doesn't exist with offset\n // +0200, so we adjust the time as needed, to be valid.\n //\n // Keeping the time actually adds/subtracts (one hour)\n // from the actual represented time. That is why we call updateOffset\n // a second time. In case it wants us to change the offset again\n // _changeInProgress == true case, then we have to adjust, because\n // there is no such time in the given timezone.\n function getSetOffset(input, keepLocalTime, keepMinutes) {\n var offset = this._offset || 0,\n localAdjust;\n if (!this.isValid()) {\n return input != null ? this : NaN;\n }\n if (input != null) {\n if (typeof input === 'string') {\n input = offsetFromString(matchShortOffset, input);\n if (input === null) {\n return this;\n }\n } else if (Math.abs(input) < 16 && !keepMinutes) {\n input = input * 60;\n }\n if (!this._isUTC && keepLocalTime) {\n localAdjust = getDateOffset(this);\n }\n this._offset = input;\n this._isUTC = true;\n if (localAdjust != null) {\n this.add(localAdjust, 'm');\n }\n if (offset !== input) {\n if (!keepLocalTime || this._changeInProgress) {\n addSubtract(this, createDuration(input - offset, 'm'), 1, false);\n } else if (!this._changeInProgress) {\n this._changeInProgress = true;\n hooks.updateOffset(this, true);\n this._changeInProgress = null;\n }\n }\n return this;\n } else {\n return this._isUTC ? offset : getDateOffset(this);\n }\n }\n function getSetZone(input, keepLocalTime) {\n if (input != null) {\n if (typeof input !== 'string') {\n input = -input;\n }\n this.utcOffset(input, keepLocalTime);\n return this;\n } else {\n return -this.utcOffset();\n }\n }\n function setOffsetToUTC(keepLocalTime) {\n return this.utcOffset(0, keepLocalTime);\n }\n function setOffsetToLocal(keepLocalTime) {\n if (this._isUTC) {\n this.utcOffset(0, keepLocalTime);\n this._isUTC = false;\n if (keepLocalTime) {\n this.subtract(getDateOffset(this), 'm');\n }\n }\n return this;\n }\n function setOffsetToParsedOffset() {\n if (this._tzm != null) {\n this.utcOffset(this._tzm, false, true);\n } else if (typeof this._i === 'string') {\n var tZone = offsetFromString(matchOffset, this._i);\n if (tZone != null) {\n this.utcOffset(tZone);\n } else {\n this.utcOffset(0, true);\n }\n }\n return this;\n }\n function hasAlignedHourOffset(input) {\n if (!this.isValid()) {\n return false;\n }\n input = input ? createLocal(input).utcOffset() : 0;\n return (this.utcOffset() - input) % 60 === 0;\n }\n function isDaylightSavingTime() {\n return this.utcOffset() > this.clone().month(0).utcOffset() || this.utcOffset() > this.clone().month(5).utcOffset();\n }\n function isDaylightSavingTimeShifted() {\n if (!isUndefined(this._isDSTShifted)) {\n return this._isDSTShifted;\n }\n var c = {},\n other;\n copyConfig(c, this);\n c = prepareConfig(c);\n if (c._a) {\n other = c._isUTC ? createUTC(c._a) : createLocal(c._a);\n this._isDSTShifted = this.isValid() && compareArrays(c._a, other.toArray()) > 0;\n } else {\n this._isDSTShifted = false;\n }\n return this._isDSTShifted;\n }\n function isLocal() {\n return this.isValid() ? !this._isUTC : false;\n }\n function isUtcOffset() {\n return this.isValid() ? this._isUTC : false;\n }\n function isUtc() {\n return this.isValid() ? this._isUTC && this._offset === 0 : false;\n }\n\n // ASP.NET json date format regex\n var aspNetRegex = /^(-|\\+)?(?:(\\d*)[. ])?(\\d+):(\\d+)(?::(\\d+)(\\.\\d*)?)?$/,\n // from http://docs.closure-library.googlecode.com/git/closure_goog_date_date.js.source.html\n // somewhat more in line with 4.4.3.2 2004 spec, but allows decimal anywhere\n // and further modified to allow for strings containing both week and day\n isoRegex = /^(-|\\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;\n function createDuration(input, key) {\n var duration = input,\n // matching against regexp is expensive, do it on demand\n match = null,\n sign,\n ret,\n diffRes;\n if (isDuration(input)) {\n duration = {\n ms: input._milliseconds,\n d: input._days,\n M: input._months\n };\n } else if (isNumber(input) || !isNaN(+input)) {\n duration = {};\n if (key) {\n duration[key] = +input;\n } else {\n duration.milliseconds = +input;\n }\n } else if (match = aspNetRegex.exec(input)) {\n sign = match[1] === '-' ? -1 : 1;\n duration = {\n y: 0,\n d: toInt(match[DATE]) * sign,\n h: toInt(match[HOUR]) * sign,\n m: toInt(match[MINUTE]) * sign,\n s: toInt(match[SECOND]) * sign,\n ms: toInt(absRound(match[MILLISECOND] * 1000)) * sign // the millisecond decimal point is included in the match\n };\n } else if (match = isoRegex.exec(input)) {\n sign = match[1] === '-' ? -1 : 1;\n duration = {\n y: parseIso(match[2], sign),\n M: parseIso(match[3], sign),\n w: parseIso(match[4], sign),\n d: parseIso(match[5], sign),\n h: parseIso(match[6], sign),\n m: parseIso(match[7], sign),\n s: parseIso(match[8], sign)\n };\n } else if (duration == null) {\n // checks for null or undefined\n duration = {};\n } else if (typeof duration === 'object' && ('from' in duration || 'to' in duration)) {\n diffRes = momentsDifference(createLocal(duration.from), createLocal(duration.to));\n duration = {};\n duration.ms = diffRes.milliseconds;\n duration.M = diffRes.months;\n }\n ret = new Duration(duration);\n if (isDuration(input) && hasOwnProp(input, '_locale')) {\n ret._locale = input._locale;\n }\n if (isDuration(input) && hasOwnProp(input, '_isValid')) {\n ret._isValid = input._isValid;\n }\n return ret;\n }\n createDuration.fn = Duration.prototype;\n createDuration.invalid = createInvalid$1;\n function parseIso(inp, sign) {\n // We'd normally use ~~inp for this, but unfortunately it also\n // converts floats to ints.\n // inp may be undefined, so careful calling replace on it.\n var res = inp && parseFloat(inp.replace(',', '.'));\n // apply sign while we're at it\n return (isNaN(res) ? 0 : res) * sign;\n }\n function positiveMomentsDifference(base, other) {\n var res = {};\n res.months = other.month() - base.month() + (other.year() - base.year()) * 12;\n if (base.clone().add(res.months, 'M').isAfter(other)) {\n --res.months;\n }\n res.milliseconds = +other - +base.clone().add(res.months, 'M');\n return res;\n }\n function momentsDifference(base, other) {\n var res;\n if (!(base.isValid() && other.isValid())) {\n return {\n milliseconds: 0,\n months: 0\n };\n }\n other = cloneWithOffset(other, base);\n if (base.isBefore(other)) {\n res = positiveMomentsDifference(base, other);\n } else {\n res = positiveMomentsDifference(other, base);\n res.milliseconds = -res.milliseconds;\n res.months = -res.months;\n }\n return res;\n }\n\n // TODO: remove 'name' arg after deprecation is removed\n function createAdder(direction, name) {\n return function (val, period) {\n var dur, tmp;\n //invert the arguments, but complain about it\n if (period !== null && !isNaN(+period)) {\n deprecateSimple(name, 'moment().' + name + '(period, number) is deprecated. Please use moment().' + name + '(number, period). ' + 'See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info.');\n tmp = val;\n val = period;\n period = tmp;\n }\n dur = createDuration(val, period);\n addSubtract(this, dur, direction);\n return this;\n };\n }\n function addSubtract(mom, duration, isAdding, updateOffset) {\n var milliseconds = duration._milliseconds,\n days = absRound(duration._days),\n months = absRound(duration._months);\n if (!mom.isValid()) {\n // No op\n return;\n }\n updateOffset = updateOffset == null ? true : updateOffset;\n if (months) {\n setMonth(mom, get(mom, 'Month') + months * isAdding);\n }\n if (days) {\n set$1(mom, 'Date', get(mom, 'Date') + days * isAdding);\n }\n if (milliseconds) {\n mom._d.setTime(mom._d.valueOf() + milliseconds * isAdding);\n }\n if (updateOffset) {\n hooks.updateOffset(mom, days || months);\n }\n }\n var add = createAdder(1, 'add'),\n subtract = createAdder(-1, 'subtract');\n function isString(input) {\n return typeof input === 'string' || input instanceof String;\n }\n\n // type MomentInput = Moment | Date | string | number | (number | string)[] | MomentInputObject | void; // null | undefined\n function isMomentInput(input) {\n return isMoment(input) || isDate(input) || isString(input) || isNumber(input) || isNumberOrStringArray(input) || isMomentInputObject(input) || input === null || input === undefined;\n }\n function isMomentInputObject(input) {\n var objectTest = isObject(input) && !isObjectEmpty(input),\n propertyTest = false,\n properties = ['years', 'year', 'y', 'months', 'month', 'M', 'days', 'day', 'd', 'dates', 'date', 'D', 'hours', 'hour', 'h', 'minutes', 'minute', 'm', 'seconds', 'second', 's', 'milliseconds', 'millisecond', 'ms'],\n i,\n property,\n propertyLen = properties.length;\n for (i = 0; i < propertyLen; i += 1) {\n property = properties[i];\n propertyTest = propertyTest || hasOwnProp(input, property);\n }\n return objectTest && propertyTest;\n }\n function isNumberOrStringArray(input) {\n var arrayTest = isArray(input),\n dataTypeTest = false;\n if (arrayTest) {\n dataTypeTest = input.filter(function (item) {\n return !isNumber(item) && isString(input);\n }).length === 0;\n }\n return arrayTest && dataTypeTest;\n }\n function isCalendarSpec(input) {\n var objectTest = isObject(input) && !isObjectEmpty(input),\n propertyTest = false,\n properties = ['sameDay', 'nextDay', 'lastDay', 'nextWeek', 'lastWeek', 'sameElse'],\n i,\n property;\n for (i = 0; i < properties.length; i += 1) {\n property = properties[i];\n propertyTest = propertyTest || hasOwnProp(input, property);\n }\n return objectTest && propertyTest;\n }\n function getCalendarFormat(myMoment, now) {\n var diff = myMoment.diff(now, 'days', true);\n return diff < -6 ? 'sameElse' : diff < -1 ? 'lastWeek' : diff < 0 ? 'lastDay' : diff < 1 ? 'sameDay' : diff < 2 ? 'nextDay' : diff < 7 ? 'nextWeek' : 'sameElse';\n }\n function calendar$1(time, formats) {\n // Support for single parameter, formats only overload to the calendar function\n if (arguments.length === 1) {\n if (!arguments[0]) {\n time = undefined;\n formats = undefined;\n } else if (isMomentInput(arguments[0])) {\n time = arguments[0];\n formats = undefined;\n } else if (isCalendarSpec(arguments[0])) {\n formats = arguments[0];\n time = undefined;\n }\n }\n // We want to compare the start of today, vs this.\n // Getting start-of-today depends on whether we're local/utc/offset or not.\n var now = time || createLocal(),\n sod = cloneWithOffset(now, this).startOf('day'),\n format = hooks.calendarFormat(this, sod) || 'sameElse',\n output = formats && (isFunction(formats[format]) ? formats[format].call(this, now) : formats[format]);\n return this.format(output || this.localeData().calendar(format, this, createLocal(now)));\n }\n function clone() {\n return new Moment(this);\n }\n function isAfter(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input);\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() > localInput.valueOf();\n } else {\n return localInput.valueOf() < this.clone().startOf(units).valueOf();\n }\n }\n function isBefore(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input);\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() < localInput.valueOf();\n } else {\n return this.clone().endOf(units).valueOf() < localInput.valueOf();\n }\n }\n function isBetween(from, to, units, inclusivity) {\n var localFrom = isMoment(from) ? from : createLocal(from),\n localTo = isMoment(to) ? to : createLocal(to);\n if (!(this.isValid() && localFrom.isValid() && localTo.isValid())) {\n return false;\n }\n inclusivity = inclusivity || '()';\n return (inclusivity[0] === '(' ? this.isAfter(localFrom, units) : !this.isBefore(localFrom, units)) && (inclusivity[1] === ')' ? this.isBefore(localTo, units) : !this.isAfter(localTo, units));\n }\n function isSame(input, units) {\n var localInput = isMoment(input) ? input : createLocal(input),\n inputMs;\n if (!(this.isValid() && localInput.isValid())) {\n return false;\n }\n units = normalizeUnits(units) || 'millisecond';\n if (units === 'millisecond') {\n return this.valueOf() === localInput.valueOf();\n } else {\n inputMs = localInput.valueOf();\n return this.clone().startOf(units).valueOf() <= inputMs && inputMs <= this.clone().endOf(units).valueOf();\n }\n }\n function isSameOrAfter(input, units) {\n return this.isSame(input, units) || this.isAfter(input, units);\n }\n function isSameOrBefore(input, units) {\n return this.isSame(input, units) || this.isBefore(input, units);\n }\n function diff(input, units, asFloat) {\n var that, zoneDelta, output;\n if (!this.isValid()) {\n return NaN;\n }\n that = cloneWithOffset(input, this);\n if (!that.isValid()) {\n return NaN;\n }\n zoneDelta = (that.utcOffset() - this.utcOffset()) * 6e4;\n units = normalizeUnits(units);\n switch (units) {\n case 'year':\n output = monthDiff(this, that) / 12;\n break;\n case 'month':\n output = monthDiff(this, that);\n break;\n case 'quarter':\n output = monthDiff(this, that) / 3;\n break;\n case 'second':\n output = (this - that) / 1e3;\n break;\n // 1000\n case 'minute':\n output = (this - that) / 6e4;\n break;\n // 1000 * 60\n case 'hour':\n output = (this - that) / 36e5;\n break;\n // 1000 * 60 * 60\n case 'day':\n output = (this - that - zoneDelta) / 864e5;\n break;\n // 1000 * 60 * 60 * 24, negate dst\n case 'week':\n output = (this - that - zoneDelta) / 6048e5;\n break;\n // 1000 * 60 * 60 * 24 * 7, negate dst\n default:\n output = this - that;\n }\n return asFloat ? output : absFloor(output);\n }\n function monthDiff(a, b) {\n if (a.date() < b.date()) {\n // end-of-month calculations work correct when the start month has more\n // days than the end month.\n return -monthDiff(b, a);\n }\n // difference in months\n var wholeMonthDiff = (b.year() - a.year()) * 12 + (b.month() - a.month()),\n // b is in (anchor - 1 month, anchor + 1 month)\n anchor = a.clone().add(wholeMonthDiff, 'months'),\n anchor2,\n adjust;\n if (b - anchor < 0) {\n anchor2 = a.clone().add(wholeMonthDiff - 1, 'months');\n // linear across the month\n adjust = (b - anchor) / (anchor - anchor2);\n } else {\n anchor2 = a.clone().add(wholeMonthDiff + 1, 'months');\n // linear across the month\n adjust = (b - anchor) / (anchor2 - anchor);\n }\n\n //check for negative zero, return zero if negative zero\n return -(wholeMonthDiff + adjust) || 0;\n }\n hooks.defaultFormat = 'YYYY-MM-DDTHH:mm:ssZ';\n hooks.defaultFormatUtc = 'YYYY-MM-DDTHH:mm:ss[Z]';\n function toString() {\n return this.clone().locale('en').format('ddd MMM DD YYYY HH:mm:ss [GMT]ZZ');\n }\n function toISOString(keepOffset) {\n if (!this.isValid()) {\n return null;\n }\n var utc = keepOffset !== true,\n m = utc ? this.clone().utc() : this;\n if (m.year() < 0 || m.year() > 9999) {\n return formatMoment(m, utc ? 'YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYYYY-MM-DD[T]HH:mm:ss.SSSZ');\n }\n if (isFunction(Date.prototype.toISOString)) {\n // native implementation is ~50x faster, use it when we can\n if (utc) {\n return this.toDate().toISOString();\n } else {\n return new Date(this.valueOf() + this.utcOffset() * 60 * 1000).toISOString().replace('Z', formatMoment(m, 'Z'));\n }\n }\n return formatMoment(m, utc ? 'YYYY-MM-DD[T]HH:mm:ss.SSS[Z]' : 'YYYY-MM-DD[T]HH:mm:ss.SSSZ');\n }\n\n /**\n * Return a human readable representation of a moment that can\n * also be evaluated to get a new moment which is the same\n *\n * @link https://nodejs.org/dist/latest/docs/api/util.html#util_custom_inspect_function_on_objects\n */\n function inspect() {\n if (!this.isValid()) {\n return 'moment.invalid(/* ' + this._i + ' */)';\n }\n var func = 'moment',\n zone = '',\n prefix,\n year,\n datetime,\n suffix;\n if (!this.isLocal()) {\n func = this.utcOffset() === 0 ? 'moment.utc' : 'moment.parseZone';\n zone = 'Z';\n }\n prefix = '[' + func + '(\"]';\n year = 0 <= this.year() && this.year() <= 9999 ? 'YYYY' : 'YYYYYY';\n datetime = '-MM-DD[T]HH:mm:ss.SSS';\n suffix = zone + '[\")]';\n return this.format(prefix + year + datetime + suffix);\n }\n function format(inputString) {\n if (!inputString) {\n inputString = this.isUtc() ? hooks.defaultFormatUtc : hooks.defaultFormat;\n }\n var output = formatMoment(this, inputString);\n return this.localeData().postformat(output);\n }\n function from(time, withoutSuffix) {\n if (this.isValid() && (isMoment(time) && time.isValid() || createLocal(time).isValid())) {\n return createDuration({\n to: this,\n from: time\n }).locale(this.locale()).humanize(!withoutSuffix);\n } else {\n return this.localeData().invalidDate();\n }\n }\n function fromNow(withoutSuffix) {\n return this.from(createLocal(), withoutSuffix);\n }\n function to(time, withoutSuffix) {\n if (this.isValid() && (isMoment(time) && time.isValid() || createLocal(time).isValid())) {\n return createDuration({\n from: this,\n to: time\n }).locale(this.locale()).humanize(!withoutSuffix);\n } else {\n return this.localeData().invalidDate();\n }\n }\n function toNow(withoutSuffix) {\n return this.to(createLocal(), withoutSuffix);\n }\n\n // If passed a locale key, it will set the locale for this\n // instance. Otherwise, it will return the locale configuration\n // variables for this instance.\n function locale(key) {\n var newLocaleData;\n if (key === undefined) {\n return this._locale._abbr;\n } else {\n newLocaleData = getLocale(key);\n if (newLocaleData != null) {\n this._locale = newLocaleData;\n }\n return this;\n }\n }\n var lang = deprecate('moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.', function (key) {\n if (key === undefined) {\n return this.localeData();\n } else {\n return this.locale(key);\n }\n });\n function localeData() {\n return this._locale;\n }\n var MS_PER_SECOND = 1000,\n MS_PER_MINUTE = 60 * MS_PER_SECOND,\n MS_PER_HOUR = 60 * MS_PER_MINUTE,\n MS_PER_400_YEARS = (365 * 400 + 97) * 24 * MS_PER_HOUR;\n\n // actual modulo - handles negative numbers (for dates before 1970):\n function mod$1(dividend, divisor) {\n return (dividend % divisor + divisor) % divisor;\n }\n function localStartOfDate(y, m, d) {\n // the date constructor remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n return new Date(y + 400, m, d) - MS_PER_400_YEARS;\n } else {\n return new Date(y, m, d).valueOf();\n }\n }\n function utcStartOfDate(y, m, d) {\n // Date.UTC remaps years 0-99 to 1900-1999\n if (y < 100 && y >= 0) {\n // preserve leap years using a full 400 year cycle, then reset\n return Date.UTC(y + 400, m, d) - MS_PER_400_YEARS;\n } else {\n return Date.UTC(y, m, d);\n }\n }\n function startOf(units) {\n var time, startOfDate;\n units = normalizeUnits(units);\n if (units === undefined || units === 'millisecond' || !this.isValid()) {\n return this;\n }\n startOfDate = this._isUTC ? utcStartOfDate : localStartOfDate;\n switch (units) {\n case 'year':\n time = startOfDate(this.year(), 0, 1);\n break;\n case 'quarter':\n time = startOfDate(this.year(), this.month() - this.month() % 3, 1);\n break;\n case 'month':\n time = startOfDate(this.year(), this.month(), 1);\n break;\n case 'week':\n time = startOfDate(this.year(), this.month(), this.date() - this.weekday());\n break;\n case 'isoWeek':\n time = startOfDate(this.year(), this.month(), this.date() - (this.isoWeekday() - 1));\n break;\n case 'day':\n case 'date':\n time = startOfDate(this.year(), this.month(), this.date());\n break;\n case 'hour':\n time = this._d.valueOf();\n time -= mod$1(time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE), MS_PER_HOUR);\n break;\n case 'minute':\n time = this._d.valueOf();\n time -= mod$1(time, MS_PER_MINUTE);\n break;\n case 'second':\n time = this._d.valueOf();\n time -= mod$1(time, MS_PER_SECOND);\n break;\n }\n this._d.setTime(time);\n hooks.updateOffset(this, true);\n return this;\n }\n function endOf(units) {\n var time, startOfDate;\n units = normalizeUnits(units);\n if (units === undefined || units === 'millisecond' || !this.isValid()) {\n return this;\n }\n startOfDate = this._isUTC ? utcStartOfDate : localStartOfDate;\n switch (units) {\n case 'year':\n time = startOfDate(this.year() + 1, 0, 1) - 1;\n break;\n case 'quarter':\n time = startOfDate(this.year(), this.month() - this.month() % 3 + 3, 1) - 1;\n break;\n case 'month':\n time = startOfDate(this.year(), this.month() + 1, 1) - 1;\n break;\n case 'week':\n time = startOfDate(this.year(), this.month(), this.date() - this.weekday() + 7) - 1;\n break;\n case 'isoWeek':\n time = startOfDate(this.year(), this.month(), this.date() - (this.isoWeekday() - 1) + 7) - 1;\n break;\n case 'day':\n case 'date':\n time = startOfDate(this.year(), this.month(), this.date() + 1) - 1;\n break;\n case 'hour':\n time = this._d.valueOf();\n time += MS_PER_HOUR - mod$1(time + (this._isUTC ? 0 : this.utcOffset() * MS_PER_MINUTE), MS_PER_HOUR) - 1;\n break;\n case 'minute':\n time = this._d.valueOf();\n time += MS_PER_MINUTE - mod$1(time, MS_PER_MINUTE) - 1;\n break;\n case 'second':\n time = this._d.valueOf();\n time += MS_PER_SECOND - mod$1(time, MS_PER_SECOND) - 1;\n break;\n }\n this._d.setTime(time);\n hooks.updateOffset(this, true);\n return this;\n }\n function valueOf() {\n return this._d.valueOf() - (this._offset || 0) * 60000;\n }\n function unix() {\n return Math.floor(this.valueOf() / 1000);\n }\n function toDate() {\n return new Date(this.valueOf());\n }\n function toArray() {\n var m = this;\n return [m.year(), m.month(), m.date(), m.hour(), m.minute(), m.second(), m.millisecond()];\n }\n function toObject() {\n var m = this;\n return {\n years: m.year(),\n months: m.month(),\n date: m.date(),\n hours: m.hours(),\n minutes: m.minutes(),\n seconds: m.seconds(),\n milliseconds: m.milliseconds()\n };\n }\n function toJSON() {\n // new Date(NaN).toJSON() === null\n return this.isValid() ? this.toISOString() : null;\n }\n function isValid$2() {\n return isValid(this);\n }\n function parsingFlags() {\n return extend({}, getParsingFlags(this));\n }\n function invalidAt() {\n return getParsingFlags(this).overflow;\n }\n function creationData() {\n return {\n input: this._i,\n format: this._f,\n locale: this._locale,\n isUTC: this._isUTC,\n strict: this._strict\n };\n }\n addFormatToken('N', 0, 0, 'eraAbbr');\n addFormatToken('NN', 0, 0, 'eraAbbr');\n addFormatToken('NNN', 0, 0, 'eraAbbr');\n addFormatToken('NNNN', 0, 0, 'eraName');\n addFormatToken('NNNNN', 0, 0, 'eraNarrow');\n addFormatToken('y', ['y', 1], 'yo', 'eraYear');\n addFormatToken('y', ['yy', 2], 0, 'eraYear');\n addFormatToken('y', ['yyy', 3], 0, 'eraYear');\n addFormatToken('y', ['yyyy', 4], 0, 'eraYear');\n addRegexToken('N', matchEraAbbr);\n addRegexToken('NN', matchEraAbbr);\n addRegexToken('NNN', matchEraAbbr);\n addRegexToken('NNNN', matchEraName);\n addRegexToken('NNNNN', matchEraNarrow);\n addParseToken(['N', 'NN', 'NNN', 'NNNN', 'NNNNN'], function (input, array, config, token) {\n var era = config._locale.erasParse(input, token, config._strict);\n if (era) {\n getParsingFlags(config).era = era;\n } else {\n getParsingFlags(config).invalidEra = input;\n }\n });\n addRegexToken('y', matchUnsigned);\n addRegexToken('yy', matchUnsigned);\n addRegexToken('yyy', matchUnsigned);\n addRegexToken('yyyy', matchUnsigned);\n addRegexToken('yo', matchEraYearOrdinal);\n addParseToken(['y', 'yy', 'yyy', 'yyyy'], YEAR);\n addParseToken(['yo'], function (input, array, config, token) {\n var match;\n if (config._locale._eraYearOrdinalRegex) {\n match = input.match(config._locale._eraYearOrdinalRegex);\n }\n if (config._locale.eraYearOrdinalParse) {\n array[YEAR] = config._locale.eraYearOrdinalParse(input, match);\n } else {\n array[YEAR] = parseInt(input, 10);\n }\n });\n function localeEras(m, format) {\n var i,\n l,\n date,\n eras = this._eras || getLocale('en')._eras;\n for (i = 0, l = eras.length; i < l; ++i) {\n switch (typeof eras[i].since) {\n case 'string':\n // truncate time\n date = hooks(eras[i].since).startOf('day');\n eras[i].since = date.valueOf();\n break;\n }\n switch (typeof eras[i].until) {\n case 'undefined':\n eras[i].until = +Infinity;\n break;\n case 'string':\n // truncate time\n date = hooks(eras[i].until).startOf('day').valueOf();\n eras[i].until = date.valueOf();\n break;\n }\n }\n return eras;\n }\n function localeErasParse(eraName, format, strict) {\n var i,\n l,\n eras = this.eras(),\n name,\n abbr,\n narrow;\n eraName = eraName.toUpperCase();\n for (i = 0, l = eras.length; i < l; ++i) {\n name = eras[i].name.toUpperCase();\n abbr = eras[i].abbr.toUpperCase();\n narrow = eras[i].narrow.toUpperCase();\n if (strict) {\n switch (format) {\n case 'N':\n case 'NN':\n case 'NNN':\n if (abbr === eraName) {\n return eras[i];\n }\n break;\n case 'NNNN':\n if (name === eraName) {\n return eras[i];\n }\n break;\n case 'NNNNN':\n if (narrow === eraName) {\n return eras[i];\n }\n break;\n }\n } else if ([name, abbr, narrow].indexOf(eraName) >= 0) {\n return eras[i];\n }\n }\n }\n function localeErasConvertYear(era, year) {\n var dir = era.since <= era.until ? +1 : -1;\n if (year === undefined) {\n return hooks(era.since).year();\n } else {\n return hooks(era.since).year() + (year - era.offset) * dir;\n }\n }\n function getEraName() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].name;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].name;\n }\n }\n return '';\n }\n function getEraNarrow() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].narrow;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].narrow;\n }\n }\n return '';\n }\n function getEraAbbr() {\n var i,\n l,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until) {\n return eras[i].abbr;\n }\n if (eras[i].until <= val && val <= eras[i].since) {\n return eras[i].abbr;\n }\n }\n return '';\n }\n function getEraYear() {\n var i,\n l,\n dir,\n val,\n eras = this.localeData().eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n dir = eras[i].since <= eras[i].until ? +1 : -1;\n\n // truncate time\n val = this.clone().startOf('day').valueOf();\n if (eras[i].since <= val && val <= eras[i].until || eras[i].until <= val && val <= eras[i].since) {\n return (this.year() - hooks(eras[i].since).year()) * dir + eras[i].offset;\n }\n }\n return this.year();\n }\n function erasNameRegex(isStrict) {\n if (!hasOwnProp(this, '_erasNameRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasNameRegex : this._erasRegex;\n }\n function erasAbbrRegex(isStrict) {\n if (!hasOwnProp(this, '_erasAbbrRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasAbbrRegex : this._erasRegex;\n }\n function erasNarrowRegex(isStrict) {\n if (!hasOwnProp(this, '_erasNarrowRegex')) {\n computeErasParse.call(this);\n }\n return isStrict ? this._erasNarrowRegex : this._erasRegex;\n }\n function matchEraAbbr(isStrict, locale) {\n return locale.erasAbbrRegex(isStrict);\n }\n function matchEraName(isStrict, locale) {\n return locale.erasNameRegex(isStrict);\n }\n function matchEraNarrow(isStrict, locale) {\n return locale.erasNarrowRegex(isStrict);\n }\n function matchEraYearOrdinal(isStrict, locale) {\n return locale._eraYearOrdinalRegex || matchUnsigned;\n }\n function computeErasParse() {\n var abbrPieces = [],\n namePieces = [],\n narrowPieces = [],\n mixedPieces = [],\n i,\n l,\n erasName,\n erasAbbr,\n erasNarrow,\n eras = this.eras();\n for (i = 0, l = eras.length; i < l; ++i) {\n erasName = regexEscape(eras[i].name);\n erasAbbr = regexEscape(eras[i].abbr);\n erasNarrow = regexEscape(eras[i].narrow);\n namePieces.push(erasName);\n abbrPieces.push(erasAbbr);\n narrowPieces.push(erasNarrow);\n mixedPieces.push(erasName);\n mixedPieces.push(erasAbbr);\n mixedPieces.push(erasNarrow);\n }\n this._erasRegex = new RegExp('^(' + mixedPieces.join('|') + ')', 'i');\n this._erasNameRegex = new RegExp('^(' + namePieces.join('|') + ')', 'i');\n this._erasAbbrRegex = new RegExp('^(' + abbrPieces.join('|') + ')', 'i');\n this._erasNarrowRegex = new RegExp('^(' + narrowPieces.join('|') + ')', 'i');\n }\n\n // FORMATTING\n\n addFormatToken(0, ['gg', 2], 0, function () {\n return this.weekYear() % 100;\n });\n addFormatToken(0, ['GG', 2], 0, function () {\n return this.isoWeekYear() % 100;\n });\n function addWeekYearFormatToken(token, getter) {\n addFormatToken(0, [token, token.length], 0, getter);\n }\n addWeekYearFormatToken('gggg', 'weekYear');\n addWeekYearFormatToken('ggggg', 'weekYear');\n addWeekYearFormatToken('GGGG', 'isoWeekYear');\n addWeekYearFormatToken('GGGGG', 'isoWeekYear');\n\n // ALIASES\n\n // PARSING\n\n addRegexToken('G', matchSigned);\n addRegexToken('g', matchSigned);\n addRegexToken('GG', match1to2, match2);\n addRegexToken('gg', match1to2, match2);\n addRegexToken('GGGG', match1to4, match4);\n addRegexToken('gggg', match1to4, match4);\n addRegexToken('GGGGG', match1to6, match6);\n addRegexToken('ggggg', match1to6, match6);\n addWeekParseToken(['gggg', 'ggggg', 'GGGG', 'GGGGG'], function (input, week, config, token) {\n week[token.substr(0, 2)] = toInt(input);\n });\n addWeekParseToken(['gg', 'GG'], function (input, week, config, token) {\n week[token] = hooks.parseTwoDigitYear(input);\n });\n\n // MOMENTS\n\n function getSetWeekYear(input) {\n return getSetWeekYearHelper.call(this, input, this.week(), this.weekday() + this.localeData()._week.dow, this.localeData()._week.dow, this.localeData()._week.doy);\n }\n function getSetISOWeekYear(input) {\n return getSetWeekYearHelper.call(this, input, this.isoWeek(), this.isoWeekday(), 1, 4);\n }\n function getISOWeeksInYear() {\n return weeksInYear(this.year(), 1, 4);\n }\n function getISOWeeksInISOWeekYear() {\n return weeksInYear(this.isoWeekYear(), 1, 4);\n }\n function getWeeksInYear() {\n var weekInfo = this.localeData()._week;\n return weeksInYear(this.year(), weekInfo.dow, weekInfo.doy);\n }\n function getWeeksInWeekYear() {\n var weekInfo = this.localeData()._week;\n return weeksInYear(this.weekYear(), weekInfo.dow, weekInfo.doy);\n }\n function getSetWeekYearHelper(input, week, weekday, dow, doy) {\n var weeksTarget;\n if (input == null) {\n return weekOfYear(this, dow, doy).year;\n } else {\n weeksTarget = weeksInYear(input, dow, doy);\n if (week > weeksTarget) {\n week = weeksTarget;\n }\n return setWeekAll.call(this, input, week, weekday, dow, doy);\n }\n }\n function setWeekAll(weekYear, week, weekday, dow, doy) {\n var dayOfYearData = dayOfYearFromWeeks(weekYear, week, weekday, dow, doy),\n date = createUTCDate(dayOfYearData.year, 0, dayOfYearData.dayOfYear);\n this.year(date.getUTCFullYear());\n this.month(date.getUTCMonth());\n this.date(date.getUTCDate());\n return this;\n }\n\n // FORMATTING\n\n addFormatToken('Q', 0, 'Qo', 'quarter');\n\n // PARSING\n\n addRegexToken('Q', match1);\n addParseToken('Q', function (input, array) {\n array[MONTH] = (toInt(input) - 1) * 3;\n });\n\n // MOMENTS\n\n function getSetQuarter(input) {\n return input == null ? Math.ceil((this.month() + 1) / 3) : this.month((input - 1) * 3 + this.month() % 3);\n }\n\n // FORMATTING\n\n addFormatToken('D', ['DD', 2], 'Do', 'date');\n\n // PARSING\n\n addRegexToken('D', match1to2, match1to2NoLeadingZero);\n addRegexToken('DD', match1to2, match2);\n addRegexToken('Do', function (isStrict, locale) {\n // TODO: Remove \"ordinalParse\" fallback in next major release.\n return isStrict ? locale._dayOfMonthOrdinalParse || locale._ordinalParse : locale._dayOfMonthOrdinalParseLenient;\n });\n addParseToken(['D', 'DD'], DATE);\n addParseToken('Do', function (input, array) {\n array[DATE] = toInt(input.match(match1to2)[0]);\n });\n\n // MOMENTS\n\n var getSetDayOfMonth = makeGetSet('Date', true);\n\n // FORMATTING\n\n addFormatToken('DDD', ['DDDD', 3], 'DDDo', 'dayOfYear');\n\n // PARSING\n\n addRegexToken('DDD', match1to3);\n addRegexToken('DDDD', match3);\n addParseToken(['DDD', 'DDDD'], function (input, array, config) {\n config._dayOfYear = toInt(input);\n });\n\n // HELPERS\n\n // MOMENTS\n\n function getSetDayOfYear(input) {\n var dayOfYear = Math.round((this.clone().startOf('day') - this.clone().startOf('year')) / 864e5) + 1;\n return input == null ? dayOfYear : this.add(input - dayOfYear, 'd');\n }\n\n // FORMATTING\n\n addFormatToken('m', ['mm', 2], 0, 'minute');\n\n // PARSING\n\n addRegexToken('m', match1to2, match1to2HasZero);\n addRegexToken('mm', match1to2, match2);\n addParseToken(['m', 'mm'], MINUTE);\n\n // MOMENTS\n\n var getSetMinute = makeGetSet('Minutes', false);\n\n // FORMATTING\n\n addFormatToken('s', ['ss', 2], 0, 'second');\n\n // PARSING\n\n addRegexToken('s', match1to2, match1to2HasZero);\n addRegexToken('ss', match1to2, match2);\n addParseToken(['s', 'ss'], SECOND);\n\n // MOMENTS\n\n var getSetSecond = makeGetSet('Seconds', false);\n\n // FORMATTING\n\n addFormatToken('S', 0, 0, function () {\n return ~~(this.millisecond() / 100);\n });\n addFormatToken(0, ['SS', 2], 0, function () {\n return ~~(this.millisecond() / 10);\n });\n addFormatToken(0, ['SSS', 3], 0, 'millisecond');\n addFormatToken(0, ['SSSS', 4], 0, function () {\n return this.millisecond() * 10;\n });\n addFormatToken(0, ['SSSSS', 5], 0, function () {\n return this.millisecond() * 100;\n });\n addFormatToken(0, ['SSSSSS', 6], 0, function () {\n return this.millisecond() * 1000;\n });\n addFormatToken(0, ['SSSSSSS', 7], 0, function () {\n return this.millisecond() * 10000;\n });\n addFormatToken(0, ['SSSSSSSS', 8], 0, function () {\n return this.millisecond() * 100000;\n });\n addFormatToken(0, ['SSSSSSSSS', 9], 0, function () {\n return this.millisecond() * 1000000;\n });\n\n // PARSING\n\n addRegexToken('S', match1to3, match1);\n addRegexToken('SS', match1to3, match2);\n addRegexToken('SSS', match1to3, match3);\n var token, getSetMillisecond;\n for (token = 'SSSS'; token.length <= 9; token += 'S') {\n addRegexToken(token, matchUnsigned);\n }\n function parseMs(input, array) {\n array[MILLISECOND] = toInt(('0.' + input) * 1000);\n }\n for (token = 'S'; token.length <= 9; token += 'S') {\n addParseToken(token, parseMs);\n }\n getSetMillisecond = makeGetSet('Milliseconds', false);\n\n // FORMATTING\n\n addFormatToken('z', 0, 0, 'zoneAbbr');\n addFormatToken('zz', 0, 0, 'zoneName');\n\n // MOMENTS\n\n function getZoneAbbr() {\n return this._isUTC ? 'UTC' : '';\n }\n function getZoneName() {\n return this._isUTC ? 'Coordinated Universal Time' : '';\n }\n var proto = Moment.prototype;\n proto.add = add;\n proto.calendar = calendar$1;\n proto.clone = clone;\n proto.diff = diff;\n proto.endOf = endOf;\n proto.format = format;\n proto.from = from;\n proto.fromNow = fromNow;\n proto.to = to;\n proto.toNow = toNow;\n proto.get = stringGet;\n proto.invalidAt = invalidAt;\n proto.isAfter = isAfter;\n proto.isBefore = isBefore;\n proto.isBetween = isBetween;\n proto.isSame = isSame;\n proto.isSameOrAfter = isSameOrAfter;\n proto.isSameOrBefore = isSameOrBefore;\n proto.isValid = isValid$2;\n proto.lang = lang;\n proto.locale = locale;\n proto.localeData = localeData;\n proto.max = prototypeMax;\n proto.min = prototypeMin;\n proto.parsingFlags = parsingFlags;\n proto.set = stringSet;\n proto.startOf = startOf;\n proto.subtract = subtract;\n proto.toArray = toArray;\n proto.toObject = toObject;\n proto.toDate = toDate;\n proto.toISOString = toISOString;\n proto.inspect = inspect;\n if (typeof Symbol !== 'undefined' && Symbol.for != null) {\n proto[Symbol.for('nodejs.util.inspect.custom')] = function () {\n return 'Moment<' + this.format() + '>';\n };\n }\n proto.toJSON = toJSON;\n proto.toString = toString;\n proto.unix = unix;\n proto.valueOf = valueOf;\n proto.creationData = creationData;\n proto.eraName = getEraName;\n proto.eraNarrow = getEraNarrow;\n proto.eraAbbr = getEraAbbr;\n proto.eraYear = getEraYear;\n proto.year = getSetYear;\n proto.isLeapYear = getIsLeapYear;\n proto.weekYear = getSetWeekYear;\n proto.isoWeekYear = getSetISOWeekYear;\n proto.quarter = proto.quarters = getSetQuarter;\n proto.month = getSetMonth;\n proto.daysInMonth = getDaysInMonth;\n proto.week = proto.weeks = getSetWeek;\n proto.isoWeek = proto.isoWeeks = getSetISOWeek;\n proto.weeksInYear = getWeeksInYear;\n proto.weeksInWeekYear = getWeeksInWeekYear;\n proto.isoWeeksInYear = getISOWeeksInYear;\n proto.isoWeeksInISOWeekYear = getISOWeeksInISOWeekYear;\n proto.date = getSetDayOfMonth;\n proto.day = proto.days = getSetDayOfWeek;\n proto.weekday = getSetLocaleDayOfWeek;\n proto.isoWeekday = getSetISODayOfWeek;\n proto.dayOfYear = getSetDayOfYear;\n proto.hour = proto.hours = getSetHour;\n proto.minute = proto.minutes = getSetMinute;\n proto.second = proto.seconds = getSetSecond;\n proto.millisecond = proto.milliseconds = getSetMillisecond;\n proto.utcOffset = getSetOffset;\n proto.utc = setOffsetToUTC;\n proto.local = setOffsetToLocal;\n proto.parseZone = setOffsetToParsedOffset;\n proto.hasAlignedHourOffset = hasAlignedHourOffset;\n proto.isDST = isDaylightSavingTime;\n proto.isLocal = isLocal;\n proto.isUtcOffset = isUtcOffset;\n proto.isUtc = isUtc;\n proto.isUTC = isUtc;\n proto.zoneAbbr = getZoneAbbr;\n proto.zoneName = getZoneName;\n proto.dates = deprecate('dates accessor is deprecated. Use date instead.', getSetDayOfMonth);\n proto.months = deprecate('months accessor is deprecated. Use month instead', getSetMonth);\n proto.years = deprecate('years accessor is deprecated. Use year instead', getSetYear);\n proto.zone = deprecate('moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/', getSetZone);\n proto.isDSTShifted = deprecate('isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information', isDaylightSavingTimeShifted);\n function createUnix(input) {\n return createLocal(input * 1000);\n }\n function createInZone() {\n return createLocal.apply(null, arguments).parseZone();\n }\n function preParsePostFormat(string) {\n return string;\n }\n var proto$1 = Locale.prototype;\n proto$1.calendar = calendar;\n proto$1.longDateFormat = longDateFormat;\n proto$1.invalidDate = invalidDate;\n proto$1.ordinal = ordinal;\n proto$1.preparse = preParsePostFormat;\n proto$1.postformat = preParsePostFormat;\n proto$1.relativeTime = relativeTime;\n proto$1.pastFuture = pastFuture;\n proto$1.set = set;\n proto$1.eras = localeEras;\n proto$1.erasParse = localeErasParse;\n proto$1.erasConvertYear = localeErasConvertYear;\n proto$1.erasAbbrRegex = erasAbbrRegex;\n proto$1.erasNameRegex = erasNameRegex;\n proto$1.erasNarrowRegex = erasNarrowRegex;\n proto$1.months = localeMonths;\n proto$1.monthsShort = localeMonthsShort;\n proto$1.monthsParse = localeMonthsParse;\n proto$1.monthsRegex = monthsRegex;\n proto$1.monthsShortRegex = monthsShortRegex;\n proto$1.week = localeWeek;\n proto$1.firstDayOfYear = localeFirstDayOfYear;\n proto$1.firstDayOfWeek = localeFirstDayOfWeek;\n proto$1.weekdays = localeWeekdays;\n proto$1.weekdaysMin = localeWeekdaysMin;\n proto$1.weekdaysShort = localeWeekdaysShort;\n proto$1.weekdaysParse = localeWeekdaysParse;\n proto$1.weekdaysRegex = weekdaysRegex;\n proto$1.weekdaysShortRegex = weekdaysShortRegex;\n proto$1.weekdaysMinRegex = weekdaysMinRegex;\n proto$1.isPM = localeIsPM;\n proto$1.meridiem = localeMeridiem;\n function get$1(format, index, field, setter) {\n var locale = getLocale(),\n utc = createUTC().set(setter, index);\n return locale[field](utc, format);\n }\n function listMonthsImpl(format, index, field) {\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n format = format || '';\n if (index != null) {\n return get$1(format, index, field, 'month');\n }\n var i,\n out = [];\n for (i = 0; i < 12; i++) {\n out[i] = get$1(format, i, field, 'month');\n }\n return out;\n }\n\n // ()\n // (5)\n // (fmt, 5)\n // (fmt)\n // (true)\n // (true, 5)\n // (true, fmt, 5)\n // (true, fmt)\n function listWeekdaysImpl(localeSorted, format, index, field) {\n if (typeof localeSorted === 'boolean') {\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n format = format || '';\n } else {\n format = localeSorted;\n index = format;\n localeSorted = false;\n if (isNumber(format)) {\n index = format;\n format = undefined;\n }\n format = format || '';\n }\n var locale = getLocale(),\n shift = localeSorted ? locale._week.dow : 0,\n i,\n out = [];\n if (index != null) {\n return get$1(format, (index + shift) % 7, field, 'day');\n }\n for (i = 0; i < 7; i++) {\n out[i] = get$1(format, (i + shift) % 7, field, 'day');\n }\n return out;\n }\n function listMonths(format, index) {\n return listMonthsImpl(format, index, 'months');\n }\n function listMonthsShort(format, index) {\n return listMonthsImpl(format, index, 'monthsShort');\n }\n function listWeekdays(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdays');\n }\n function listWeekdaysShort(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdaysShort');\n }\n function listWeekdaysMin(localeSorted, format, index) {\n return listWeekdaysImpl(localeSorted, format, index, 'weekdaysMin');\n }\n getSetGlobalLocale('en', {\n eras: [{\n since: '0001-01-01',\n until: +Infinity,\n offset: 1,\n name: 'Anno Domini',\n narrow: 'AD',\n abbr: 'AD'\n }, {\n since: '0000-12-31',\n until: -Infinity,\n offset: 1,\n name: 'Before Christ',\n narrow: 'BC',\n abbr: 'BC'\n }],\n dayOfMonthOrdinalParse: /\\d{1,2}(th|st|nd|rd)/,\n ordinal: function (number) {\n var b = number % 10,\n output = toInt(number % 100 / 10) === 1 ? 'th' : b === 1 ? 'st' : b === 2 ? 'nd' : b === 3 ? 'rd' : 'th';\n return number + output;\n }\n });\n\n // Side effect imports\n\n hooks.lang = deprecate('moment.lang is deprecated. Use moment.locale instead.', getSetGlobalLocale);\n hooks.langData = deprecate('moment.langData is deprecated. Use moment.localeData instead.', getLocale);\n var mathAbs = Math.abs;\n function abs() {\n var data = this._data;\n this._milliseconds = mathAbs(this._milliseconds);\n this._days = mathAbs(this._days);\n this._months = mathAbs(this._months);\n data.milliseconds = mathAbs(data.milliseconds);\n data.seconds = mathAbs(data.seconds);\n data.minutes = mathAbs(data.minutes);\n data.hours = mathAbs(data.hours);\n data.months = mathAbs(data.months);\n data.years = mathAbs(data.years);\n return this;\n }\n function addSubtract$1(duration, input, value, direction) {\n var other = createDuration(input, value);\n duration._milliseconds += direction * other._milliseconds;\n duration._days += direction * other._days;\n duration._months += direction * other._months;\n return duration._bubble();\n }\n\n // supports only 2.0-style add(1, 's') or add(duration)\n function add$1(input, value) {\n return addSubtract$1(this, input, value, 1);\n }\n\n // supports only 2.0-style subtract(1, 's') or subtract(duration)\n function subtract$1(input, value) {\n return addSubtract$1(this, input, value, -1);\n }\n function absCeil(number) {\n if (number < 0) {\n return Math.floor(number);\n } else {\n return Math.ceil(number);\n }\n }\n function bubble() {\n var milliseconds = this._milliseconds,\n days = this._days,\n months = this._months,\n data = this._data,\n seconds,\n minutes,\n hours,\n years,\n monthsFromDays;\n\n // if we have a mix of positive and negative values, bubble down first\n // check: https://github.com/moment/moment/issues/2166\n if (!(milliseconds >= 0 && days >= 0 && months >= 0 || milliseconds <= 0 && days <= 0 && months <= 0)) {\n milliseconds += absCeil(monthsToDays(months) + days) * 864e5;\n days = 0;\n months = 0;\n }\n\n // The following code bubbles up values, see the tests for\n // examples of what that means.\n data.milliseconds = milliseconds % 1000;\n seconds = absFloor(milliseconds / 1000);\n data.seconds = seconds % 60;\n minutes = absFloor(seconds / 60);\n data.minutes = minutes % 60;\n hours = absFloor(minutes / 60);\n data.hours = hours % 24;\n days += absFloor(hours / 24);\n\n // convert days to months\n monthsFromDays = absFloor(daysToMonths(days));\n months += monthsFromDays;\n days -= absCeil(monthsToDays(monthsFromDays));\n\n // 12 months -> 1 year\n years = absFloor(months / 12);\n months %= 12;\n data.days = days;\n data.months = months;\n data.years = years;\n return this;\n }\n function daysToMonths(days) {\n // 400 years have 146097 days (taking into account leap year rules)\n // 400 years have 12 months === 4800\n return days * 4800 / 146097;\n }\n function monthsToDays(months) {\n // the reverse of daysToMonths\n return months * 146097 / 4800;\n }\n function as(units) {\n if (!this.isValid()) {\n return NaN;\n }\n var days,\n months,\n milliseconds = this._milliseconds;\n units = normalizeUnits(units);\n if (units === 'month' || units === 'quarter' || units === 'year') {\n days = this._days + milliseconds / 864e5;\n months = this._months + daysToMonths(days);\n switch (units) {\n case 'month':\n return months;\n case 'quarter':\n return months / 3;\n case 'year':\n return months / 12;\n }\n } else {\n // handle milliseconds separately because of floating point math errors (issue #1867)\n days = this._days + Math.round(monthsToDays(this._months));\n switch (units) {\n case 'week':\n return days / 7 + milliseconds / 6048e5;\n case 'day':\n return days + milliseconds / 864e5;\n case 'hour':\n return days * 24 + milliseconds / 36e5;\n case 'minute':\n return days * 1440 + milliseconds / 6e4;\n case 'second':\n return days * 86400 + milliseconds / 1000;\n // Math.floor prevents floating point math errors here\n case 'millisecond':\n return Math.floor(days * 864e5) + milliseconds;\n default:\n throw new Error('Unknown unit ' + units);\n }\n }\n }\n function makeAs(alias) {\n return function () {\n return this.as(alias);\n };\n }\n var asMilliseconds = makeAs('ms'),\n asSeconds = makeAs('s'),\n asMinutes = makeAs('m'),\n asHours = makeAs('h'),\n asDays = makeAs('d'),\n asWeeks = makeAs('w'),\n asMonths = makeAs('M'),\n asQuarters = makeAs('Q'),\n asYears = makeAs('y'),\n valueOf$1 = asMilliseconds;\n function clone$1() {\n return createDuration(this);\n }\n function get$2(units) {\n units = normalizeUnits(units);\n return this.isValid() ? this[units + 's']() : NaN;\n }\n function makeGetter(name) {\n return function () {\n return this.isValid() ? this._data[name] : NaN;\n };\n }\n var milliseconds = makeGetter('milliseconds'),\n seconds = makeGetter('seconds'),\n minutes = makeGetter('minutes'),\n hours = makeGetter('hours'),\n days = makeGetter('days'),\n months = makeGetter('months'),\n years = makeGetter('years');\n function weeks() {\n return absFloor(this.days() / 7);\n }\n var round = Math.round,\n thresholds = {\n ss: 44,\n // a few seconds to seconds\n s: 45,\n // seconds to minute\n m: 45,\n // minutes to hour\n h: 22,\n // hours to day\n d: 26,\n // days to month/week\n w: null,\n // weeks to month\n M: 11 // months to year\n };\n\n // helper function for moment.fn.from, moment.fn.fromNow, and moment.duration.fn.humanize\n function substituteTimeAgo(string, number, withoutSuffix, isFuture, locale) {\n return locale.relativeTime(number || 1, !!withoutSuffix, string, isFuture);\n }\n function relativeTime$1(posNegDuration, withoutSuffix, thresholds, locale) {\n var duration = createDuration(posNegDuration).abs(),\n seconds = round(duration.as('s')),\n minutes = round(duration.as('m')),\n hours = round(duration.as('h')),\n days = round(duration.as('d')),\n months = round(duration.as('M')),\n weeks = round(duration.as('w')),\n years = round(duration.as('y')),\n a = seconds <= thresholds.ss && ['s', seconds] || seconds < thresholds.s && ['ss', seconds] || minutes <= 1 && ['m'] || minutes < thresholds.m && ['mm', minutes] || hours <= 1 && ['h'] || hours < thresholds.h && ['hh', hours] || days <= 1 && ['d'] || days < thresholds.d && ['dd', days];\n if (thresholds.w != null) {\n a = a || weeks <= 1 && ['w'] || weeks < thresholds.w && ['ww', weeks];\n }\n a = a || months <= 1 && ['M'] || months < thresholds.M && ['MM', months] || years <= 1 && ['y'] || ['yy', years];\n a[2] = withoutSuffix;\n a[3] = +posNegDuration > 0;\n a[4] = locale;\n return substituteTimeAgo.apply(null, a);\n }\n\n // This function allows you to set the rounding function for relative time strings\n function getSetRelativeTimeRounding(roundingFunction) {\n if (roundingFunction === undefined) {\n return round;\n }\n if (typeof roundingFunction === 'function') {\n round = roundingFunction;\n return true;\n }\n return false;\n }\n\n // This function allows you to set a threshold for relative time strings\n function getSetRelativeTimeThreshold(threshold, limit) {\n if (thresholds[threshold] === undefined) {\n return false;\n }\n if (limit === undefined) {\n return thresholds[threshold];\n }\n thresholds[threshold] = limit;\n if (threshold === 's') {\n thresholds.ss = limit - 1;\n }\n return true;\n }\n function humanize(argWithSuffix, argThresholds) {\n if (!this.isValid()) {\n return this.localeData().invalidDate();\n }\n var withSuffix = false,\n th = thresholds,\n locale,\n output;\n if (typeof argWithSuffix === 'object') {\n argThresholds = argWithSuffix;\n argWithSuffix = false;\n }\n if (typeof argWithSuffix === 'boolean') {\n withSuffix = argWithSuffix;\n }\n if (typeof argThresholds === 'object') {\n th = Object.assign({}, thresholds, argThresholds);\n if (argThresholds.s != null && argThresholds.ss == null) {\n th.ss = argThresholds.s - 1;\n }\n }\n locale = this.localeData();\n output = relativeTime$1(this, !withSuffix, th, locale);\n if (withSuffix) {\n output = locale.pastFuture(+this, output);\n }\n return locale.postformat(output);\n }\n var abs$1 = Math.abs;\n function sign(x) {\n return (x > 0) - (x < 0) || +x;\n }\n function toISOString$1() {\n // for ISO strings we do not use the normal bubbling rules:\n // * milliseconds bubble up until they become hours\n // * days do not bubble at all\n // * months bubble up until they become years\n // This is because there is no context-free conversion between hours and days\n // (think of clock changes)\n // and also not between days and months (28-31 days per month)\n if (!this.isValid()) {\n return this.localeData().invalidDate();\n }\n var seconds = abs$1(this._milliseconds) / 1000,\n days = abs$1(this._days),\n months = abs$1(this._months),\n minutes,\n hours,\n years,\n s,\n total = this.asSeconds(),\n totalSign,\n ymSign,\n daysSign,\n hmsSign;\n if (!total) {\n // this is the same as C#'s (Noda) and python (isodate)...\n // but not other JS (goog.date)\n return 'P0D';\n }\n\n // 3600 seconds -> 60 minutes -> 1 hour\n minutes = absFloor(seconds / 60);\n hours = absFloor(minutes / 60);\n seconds %= 60;\n minutes %= 60;\n\n // 12 months -> 1 year\n years = absFloor(months / 12);\n months %= 12;\n\n // inspired by https://github.com/dordille/moment-isoduration/blob/master/moment.isoduration.js\n s = seconds ? seconds.toFixed(3).replace(/\\.?0+$/, '') : '';\n totalSign = total < 0 ? '-' : '';\n ymSign = sign(this._months) !== sign(total) ? '-' : '';\n daysSign = sign(this._days) !== sign(total) ? '-' : '';\n hmsSign = sign(this._milliseconds) !== sign(total) ? '-' : '';\n return totalSign + 'P' + (years ? ymSign + years + 'Y' : '') + (months ? ymSign + months + 'M' : '') + (days ? daysSign + days + 'D' : '') + (hours || minutes || seconds ? 'T' : '') + (hours ? hmsSign + hours + 'H' : '') + (minutes ? hmsSign + minutes + 'M' : '') + (seconds ? hmsSign + s + 'S' : '');\n }\n var proto$2 = Duration.prototype;\n proto$2.isValid = isValid$1;\n proto$2.abs = abs;\n proto$2.add = add$1;\n proto$2.subtract = subtract$1;\n proto$2.as = as;\n proto$2.asMilliseconds = asMilliseconds;\n proto$2.asSeconds = asSeconds;\n proto$2.asMinutes = asMinutes;\n proto$2.asHours = asHours;\n proto$2.asDays = asDays;\n proto$2.asWeeks = asWeeks;\n proto$2.asMonths = asMonths;\n proto$2.asQuarters = asQuarters;\n proto$2.asYears = asYears;\n proto$2.valueOf = valueOf$1;\n proto$2._bubble = bubble;\n proto$2.clone = clone$1;\n proto$2.get = get$2;\n proto$2.milliseconds = milliseconds;\n proto$2.seconds = seconds;\n proto$2.minutes = minutes;\n proto$2.hours = hours;\n proto$2.days = days;\n proto$2.weeks = weeks;\n proto$2.months = months;\n proto$2.years = years;\n proto$2.humanize = humanize;\n proto$2.toISOString = toISOString$1;\n proto$2.toString = toISOString$1;\n proto$2.toJSON = toISOString$1;\n proto$2.locale = locale;\n proto$2.localeData = localeData;\n proto$2.toIsoString = deprecate('toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)', toISOString$1);\n proto$2.lang = lang;\n\n // FORMATTING\n\n addFormatToken('X', 0, 0, 'unix');\n addFormatToken('x', 0, 0, 'valueOf');\n\n // PARSING\n\n addRegexToken('x', matchSigned);\n addRegexToken('X', matchTimestamp);\n addParseToken('X', function (input, array, config) {\n config._d = new Date(parseFloat(input) * 1000);\n });\n addParseToken('x', function (input, array, config) {\n config._d = new Date(toInt(input));\n });\n\n //! moment.js\n\n hooks.version = '2.30.1';\n setHookCallback(createLocal);\n hooks.fn = proto;\n hooks.min = min;\n hooks.max = max;\n hooks.now = now;\n hooks.utc = createUTC;\n hooks.unix = createUnix;\n hooks.months = listMonths;\n hooks.isDate = isDate;\n hooks.locale = getSetGlobalLocale;\n hooks.invalid = createInvalid;\n hooks.duration = createDuration;\n hooks.isMoment = isMoment;\n hooks.weekdays = listWeekdays;\n hooks.parseZone = createInZone;\n hooks.localeData = getLocale;\n hooks.isDuration = isDuration;\n hooks.monthsShort = listMonthsShort;\n hooks.weekdaysMin = listWeekdaysMin;\n hooks.defineLocale = defineLocale;\n hooks.updateLocale = updateLocale;\n hooks.locales = listLocales;\n hooks.weekdaysShort = listWeekdaysShort;\n hooks.normalizeUnits = normalizeUnits;\n hooks.relativeTimeRounding = getSetRelativeTimeRounding;\n hooks.relativeTimeThreshold = getSetRelativeTimeThreshold;\n hooks.calendarFormat = getCalendarFormat;\n hooks.prototype = proto;\n\n // currently HTML5 input type only supports 24-hour formats\n hooks.HTML5_FMT = {\n DATETIME_LOCAL: 'YYYY-MM-DDTHH:mm',\n // <input type=\"datetime-local\" />\n DATETIME_LOCAL_SECONDS: 'YYYY-MM-DDTHH:mm:ss',\n // <input type=\"datetime-local\" step=\"1\" />\n DATETIME_LOCAL_MS: 'YYYY-MM-DDTHH:mm:ss.SSS',\n // <input type=\"datetime-local\" step=\"0.001\" />\n DATE: 'YYYY-MM-DD',\n // <input type=\"date\" />\n TIME: 'HH:mm',\n // <input type=\"time\" />\n TIME_SECONDS: 'HH:mm:ss',\n // <input type=\"time\" step=\"1\" />\n TIME_MS: 'HH:mm:ss.SSS',\n // <input type=\"time\" step=\"0.001\" />\n WEEK: 'GGGG-[W]WW',\n // <input type=\"week\" />\n MONTH: 'YYYY-MM' // <input type=\"month\" />\n };\n return hooks;\n});","/*!\n * Chart.js v2.9.4\n * https://www.chartjs.org\n * (c) 2020 Chart.js Contributors\n * Released under the MIT License\n */\n(function (global, factory) {\n typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(function () {\n try {\n return require('moment');\n } catch (e) {}\n }()) : typeof define === 'function' && define.amd ? define(['require'], function (require) {\n return factory(function () {\n try {\n return require('moment');\n } catch (e) {}\n }());\n }) : (global = global || self, global.Chart = factory(global.moment));\n})(this, function (moment) {\n 'use strict';\n\n moment = moment && moment.hasOwnProperty('default') ? moment['default'] : moment;\n function createCommonjsModule(fn, module) {\n return module = {\n exports: {}\n }, fn(module, module.exports), module.exports;\n }\n function getCjsExportFromNamespace(n) {\n return n && n['default'] || n;\n }\n var colorName = {\n \"aliceblue\": [240, 248, 255],\n \"antiquewhite\": [250, 235, 215],\n \"aqua\": [0, 255, 255],\n \"aquamarine\": [127, 255, 212],\n \"azure\": [240, 255, 255],\n \"beige\": [245, 245, 220],\n \"bisque\": [255, 228, 196],\n \"black\": [0, 0, 0],\n \"blanchedalmond\": [255, 235, 205],\n \"blue\": [0, 0, 255],\n \"blueviolet\": [138, 43, 226],\n \"brown\": [165, 42, 42],\n \"burlywood\": [222, 184, 135],\n \"cadetblue\": [95, 158, 160],\n \"chartreuse\": [127, 255, 0],\n \"chocolate\": [210, 105, 30],\n \"coral\": [255, 127, 80],\n \"cornflowerblue\": [100, 149, 237],\n \"cornsilk\": [255, 248, 220],\n \"crimson\": [220, 20, 60],\n \"cyan\": [0, 255, 255],\n \"darkblue\": [0, 0, 139],\n \"darkcyan\": [0, 139, 139],\n \"darkgoldenrod\": [184, 134, 11],\n \"darkgray\": [169, 169, 169],\n \"darkgreen\": [0, 100, 0],\n \"darkgrey\": [169, 169, 169],\n \"darkkhaki\": [189, 183, 107],\n \"darkmagenta\": [139, 0, 139],\n \"darkolivegreen\": [85, 107, 47],\n \"darkorange\": [255, 140, 0],\n \"darkorchid\": [153, 50, 204],\n \"darkred\": [139, 0, 0],\n \"darksalmon\": [233, 150, 122],\n \"darkseagreen\": [143, 188, 143],\n \"darkslateblue\": [72, 61, 139],\n \"darkslategray\": [47, 79, 79],\n \"darkslategrey\": [47, 79, 79],\n \"darkturquoise\": [0, 206, 209],\n \"darkviolet\": [148, 0, 211],\n \"deeppink\": [255, 20, 147],\n \"deepskyblue\": [0, 191, 255],\n \"dimgray\": [105, 105, 105],\n \"dimgrey\": [105, 105, 105],\n \"dodgerblue\": [30, 144, 255],\n \"firebrick\": [178, 34, 34],\n \"floralwhite\": [255, 250, 240],\n \"forestgreen\": [34, 139, 34],\n \"fuchsia\": [255, 0, 255],\n \"gainsboro\": [220, 220, 220],\n \"ghostwhite\": [248, 248, 255],\n \"gold\": [255, 215, 0],\n \"goldenrod\": [218, 165, 32],\n \"gray\": [128, 128, 128],\n \"green\": [0, 128, 0],\n \"greenyellow\": [173, 255, 47],\n \"grey\": [128, 128, 128],\n \"honeydew\": [240, 255, 240],\n \"hotpink\": [255, 105, 180],\n \"indianred\": [205, 92, 92],\n \"indigo\": [75, 0, 130],\n \"ivory\": [255, 255, 240],\n \"khaki\": [240, 230, 140],\n \"lavender\": [230, 230, 250],\n \"lavenderblush\": [255, 240, 245],\n \"lawngreen\": [124, 252, 0],\n \"lemonchiffon\": [255, 250, 205],\n \"lightblue\": [173, 216, 230],\n \"lightcoral\": [240, 128, 128],\n \"lightcyan\": [224, 255, 255],\n \"lightgoldenrodyellow\": [250, 250, 210],\n \"lightgray\": [211, 211, 211],\n \"lightgreen\": [144, 238, 144],\n \"lightgrey\": [211, 211, 211],\n \"lightpink\": [255, 182, 193],\n \"lightsalmon\": [255, 160, 122],\n \"lightseagreen\": [32, 178, 170],\n \"lightskyblue\": [135, 206, 250],\n \"lightslategray\": [119, 136, 153],\n \"lightslategrey\": [119, 136, 153],\n \"lightsteelblue\": [176, 196, 222],\n \"lightyellow\": [255, 255, 224],\n \"lime\": [0, 255, 0],\n \"limegreen\": [50, 205, 50],\n \"linen\": [250, 240, 230],\n \"magenta\": [255, 0, 255],\n \"maroon\": [128, 0, 0],\n \"mediumaquamarine\": [102, 205, 170],\n \"mediumblue\": [0, 0, 205],\n \"mediumorchid\": [186, 85, 211],\n \"mediumpurple\": [147, 112, 219],\n \"mediumseagreen\": [60, 179, 113],\n \"mediumslateblue\": [123, 104, 238],\n \"mediumspringgreen\": [0, 250, 154],\n \"mediumturquoise\": [72, 209, 204],\n \"mediumvioletred\": [199, 21, 133],\n \"midnightblue\": [25, 25, 112],\n \"mintcream\": [245, 255, 250],\n \"mistyrose\": [255, 228, 225],\n \"moccasin\": [255, 228, 181],\n \"navajowhite\": [255, 222, 173],\n \"navy\": [0, 0, 128],\n \"oldlace\": [253, 245, 230],\n \"olive\": [128, 128, 0],\n \"olivedrab\": [107, 142, 35],\n \"orange\": [255, 165, 0],\n \"orangered\": [255, 69, 0],\n \"orchid\": [218, 112, 214],\n \"palegoldenrod\": [238, 232, 170],\n \"palegreen\": [152, 251, 152],\n \"paleturquoise\": [175, 238, 238],\n \"palevioletred\": [219, 112, 147],\n \"papayawhip\": [255, 239, 213],\n \"peachpuff\": [255, 218, 185],\n \"peru\": [205, 133, 63],\n \"pink\": [255, 192, 203],\n \"plum\": [221, 160, 221],\n \"powderblue\": [176, 224, 230],\n \"purple\": [128, 0, 128],\n \"rebeccapurple\": [102, 51, 153],\n \"red\": [255, 0, 0],\n \"rosybrown\": [188, 143, 143],\n \"royalblue\": [65, 105, 225],\n \"saddlebrown\": [139, 69, 19],\n \"salmon\": [250, 128, 114],\n \"sandybrown\": [244, 164, 96],\n \"seagreen\": [46, 139, 87],\n \"seashell\": [255, 245, 238],\n \"sienna\": [160, 82, 45],\n \"silver\": [192, 192, 192],\n \"skyblue\": [135, 206, 235],\n \"slateblue\": [106, 90, 205],\n \"slategray\": [112, 128, 144],\n \"slategrey\": [112, 128, 144],\n \"snow\": [255, 250, 250],\n \"springgreen\": [0, 255, 127],\n \"steelblue\": [70, 130, 180],\n \"tan\": [210, 180, 140],\n \"teal\": [0, 128, 128],\n \"thistle\": [216, 191, 216],\n \"tomato\": [255, 99, 71],\n \"turquoise\": [64, 224, 208],\n \"violet\": [238, 130, 238],\n \"wheat\": [245, 222, 179],\n \"white\": [255, 255, 255],\n \"whitesmoke\": [245, 245, 245],\n \"yellow\": [255, 255, 0],\n \"yellowgreen\": [154, 205, 50]\n };\n var conversions = createCommonjsModule(function (module) {\n /* MIT license */\n\n // NOTE: conversions should only return primitive values (i.e. arrays, or\n // values that give correct `typeof` results).\n // do not use box values types (i.e. Number(), String(), etc.)\n\n var reverseKeywords = {};\n for (var key in colorName) {\n if (colorName.hasOwnProperty(key)) {\n reverseKeywords[colorName[key]] = key;\n }\n }\n var convert = module.exports = {\n rgb: {\n channels: 3,\n labels: 'rgb'\n },\n hsl: {\n channels: 3,\n labels: 'hsl'\n },\n hsv: {\n channels: 3,\n labels: 'hsv'\n },\n hwb: {\n channels: 3,\n labels: 'hwb'\n },\n cmyk: {\n channels: 4,\n labels: 'cmyk'\n },\n xyz: {\n channels: 3,\n labels: 'xyz'\n },\n lab: {\n channels: 3,\n labels: 'lab'\n },\n lch: {\n channels: 3,\n labels: 'lch'\n },\n hex: {\n channels: 1,\n labels: ['hex']\n },\n keyword: {\n channels: 1,\n labels: ['keyword']\n },\n ansi16: {\n channels: 1,\n labels: ['ansi16']\n },\n ansi256: {\n channels: 1,\n labels: ['ansi256']\n },\n hcg: {\n channels: 3,\n labels: ['h', 'c', 'g']\n },\n apple: {\n channels: 3,\n labels: ['r16', 'g16', 'b16']\n },\n gray: {\n channels: 1,\n labels: ['gray']\n }\n };\n\n // hide .channels and .labels properties\n for (var model in convert) {\n if (convert.hasOwnProperty(model)) {\n if (!('channels' in convert[model])) {\n throw new Error('missing channels property: ' + model);\n }\n if (!('labels' in convert[model])) {\n throw new Error('missing channel labels property: ' + model);\n }\n if (convert[model].labels.length !== convert[model].channels) {\n throw new Error('channel and label counts mismatch: ' + model);\n }\n var channels = convert[model].channels;\n var labels = convert[model].labels;\n delete convert[model].channels;\n delete convert[model].labels;\n Object.defineProperty(convert[model], 'channels', {\n value: channels\n });\n Object.defineProperty(convert[model], 'labels', {\n value: labels\n });\n }\n }\n convert.rgb.hsl = function (rgb) {\n var r = rgb[0] / 255;\n var g = rgb[1] / 255;\n var b = rgb[2] / 255;\n var min = Math.min(r, g, b);\n var max = Math.max(r, g, b);\n var delta = max - min;\n var h;\n var s;\n var l;\n if (max === min) {\n h = 0;\n } else if (r === max) {\n h = (g - b) / delta;\n } else if (g === max) {\n h = 2 + (b - r) / delta;\n } else if (b === max) {\n h = 4 + (r - g) / delta;\n }\n h = Math.min(h * 60, 360);\n if (h < 0) {\n h += 360;\n }\n l = (min + max) / 2;\n if (max === min) {\n s = 0;\n } else if (l <= 0.5) {\n s = delta / (max + min);\n } else {\n s = delta / (2 - max - min);\n }\n return [h, s * 100, l * 100];\n };\n convert.rgb.hsv = function (rgb) {\n var rdif;\n var gdif;\n var bdif;\n var h;\n var s;\n var r = rgb[0] / 255;\n var g = rgb[1] / 255;\n var b = rgb[2] / 255;\n var v = Math.max(r, g, b);\n var diff = v - Math.min(r, g, b);\n var diffc = function (c) {\n return (v - c) / 6 / diff + 1 / 2;\n };\n if (diff === 0) {\n h = s = 0;\n } else {\n s = diff / v;\n rdif = diffc(r);\n gdif = diffc(g);\n bdif = diffc(b);\n if (r === v) {\n h = bdif - gdif;\n } else if (g === v) {\n h = 1 / 3 + rdif - bdif;\n } else if (b === v) {\n h = 2 / 3 + gdif - rdif;\n }\n if (h < 0) {\n h += 1;\n } else if (h > 1) {\n h -= 1;\n }\n }\n return [h * 360, s * 100, v * 100];\n };\n convert.rgb.hwb = function (rgb) {\n var r = rgb[0];\n var g = rgb[1];\n var b = rgb[2];\n var h = convert.rgb.hsl(rgb)[0];\n var w = 1 / 255 * Math.min(r, Math.min(g, b));\n b = 1 - 1 / 255 * Math.max(r, Math.max(g, b));\n return [h, w * 100, b * 100];\n };\n convert.rgb.cmyk = function (rgb) {\n var r = rgb[0] / 255;\n var g = rgb[1] / 255;\n var b = rgb[2] / 255;\n var c;\n var m;\n var y;\n var k;\n k = Math.min(1 - r, 1 - g, 1 - b);\n c = (1 - r - k) / (1 - k) || 0;\n m = (1 - g - k) / (1 - k) || 0;\n y = (1 - b - k) / (1 - k) || 0;\n return [c * 100, m * 100, y * 100, k * 100];\n };\n\n /**\n * See https://en.m.wikipedia.org/wiki/Euclidean_distance#Squared_Euclidean_distance\n * */\n function comparativeDistance(x, y) {\n return Math.pow(x[0] - y[0], 2) + Math.pow(x[1] - y[1], 2) + Math.pow(x[2] - y[2], 2);\n }\n convert.rgb.keyword = function (rgb) {\n var reversed = reverseKeywords[rgb];\n if (reversed) {\n return reversed;\n }\n var currentClosestDistance = Infinity;\n var currentClosestKeyword;\n for (var keyword in colorName) {\n if (colorName.hasOwnProperty(keyword)) {\n var value = colorName[keyword];\n\n // Compute comparative distance\n var distance = comparativeDistance(rgb, value);\n\n // Check if its less, if so set as closest\n if (distance < currentClosestDistance) {\n currentClosestDistance = distance;\n currentClosestKeyword = keyword;\n }\n }\n }\n return currentClosestKeyword;\n };\n convert.keyword.rgb = function (keyword) {\n return colorName[keyword];\n };\n convert.rgb.xyz = function (rgb) {\n var r = rgb[0] / 255;\n var g = rgb[1] / 255;\n var b = rgb[2] / 255;\n\n // assume sRGB\n r = r > 0.04045 ? Math.pow((r + 0.055) / 1.055, 2.4) : r / 12.92;\n g = g > 0.04045 ? Math.pow((g + 0.055) / 1.055, 2.4) : g / 12.92;\n b = b > 0.04045 ? Math.pow((b + 0.055) / 1.055, 2.4) : b / 12.92;\n var x = r * 0.4124 + g * 0.3576 + b * 0.1805;\n var y = r * 0.2126 + g * 0.7152 + b * 0.0722;\n var z = r * 0.0193 + g * 0.1192 + b * 0.9505;\n return [x * 100, y * 100, z * 100];\n };\n convert.rgb.lab = function (rgb) {\n var xyz = convert.rgb.xyz(rgb);\n var x = xyz[0];\n var y = xyz[1];\n var z = xyz[2];\n var l;\n var a;\n var b;\n x /= 95.047;\n y /= 100;\n z /= 108.883;\n x = x > 0.008856 ? Math.pow(x, 1 / 3) : 7.787 * x + 16 / 116;\n y = y > 0.008856 ? Math.pow(y, 1 / 3) : 7.787 * y + 16 / 116;\n z = z > 0.008856 ? Math.pow(z, 1 / 3) : 7.787 * z + 16 / 116;\n l = 116 * y - 16;\n a = 500 * (x - y);\n b = 200 * (y - z);\n return [l, a, b];\n };\n convert.hsl.rgb = function (hsl) {\n var h = hsl[0] / 360;\n var s = hsl[1] / 100;\n var l = hsl[2] / 100;\n var t1;\n var t2;\n var t3;\n var rgb;\n var val;\n if (s === 0) {\n val = l * 255;\n return [val, val, val];\n }\n if (l < 0.5) {\n t2 = l * (1 + s);\n } else {\n t2 = l + s - l * s;\n }\n t1 = 2 * l - t2;\n rgb = [0, 0, 0];\n for (var i = 0; i < 3; i++) {\n t3 = h + 1 / 3 * -(i - 1);\n if (t3 < 0) {\n t3++;\n }\n if (t3 > 1) {\n t3--;\n }\n if (6 * t3 < 1) {\n val = t1 + (t2 - t1) * 6 * t3;\n } else if (2 * t3 < 1) {\n val = t2;\n } else if (3 * t3 < 2) {\n val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;\n } else {\n val = t1;\n }\n rgb[i] = val * 255;\n }\n return rgb;\n };\n convert.hsl.hsv = function (hsl) {\n var h = hsl[0];\n var s = hsl[1] / 100;\n var l = hsl[2] / 100;\n var smin = s;\n var lmin = Math.max(l, 0.01);\n var sv;\n var v;\n l *= 2;\n s *= l <= 1 ? l : 2 - l;\n smin *= lmin <= 1 ? lmin : 2 - lmin;\n v = (l + s) / 2;\n sv = l === 0 ? 2 * smin / (lmin + smin) : 2 * s / (l + s);\n return [h, sv * 100, v * 100];\n };\n convert.hsv.rgb = function (hsv) {\n var h = hsv[0] / 60;\n var s = hsv[1] / 100;\n var v = hsv[2] / 100;\n var hi = Math.floor(h) % 6;\n var f = h - Math.floor(h);\n var p = 255 * v * (1 - s);\n var q = 255 * v * (1 - s * f);\n var t = 255 * v * (1 - s * (1 - f));\n v *= 255;\n switch (hi) {\n case 0:\n return [v, t, p];\n case 1:\n return [q, v, p];\n case 2:\n return [p, v, t];\n case 3:\n return [p, q, v];\n case 4:\n return [t, p, v];\n case 5:\n return [v, p, q];\n }\n };\n convert.hsv.hsl = function (hsv) {\n var h = hsv[0];\n var s = hsv[1] / 100;\n var v = hsv[2] / 100;\n var vmin = Math.max(v, 0.01);\n var lmin;\n var sl;\n var l;\n l = (2 - s) * v;\n lmin = (2 - s) * vmin;\n sl = s * vmin;\n sl /= lmin <= 1 ? lmin : 2 - lmin;\n sl = sl || 0;\n l /= 2;\n return [h, sl * 100, l * 100];\n };\n\n // http://dev.w3.org/csswg/css-color/#hwb-to-rgb\n convert.hwb.rgb = function (hwb) {\n var h = hwb[0] / 360;\n var wh = hwb[1] / 100;\n var bl = hwb[2] / 100;\n var ratio = wh + bl;\n var i;\n var v;\n var f;\n var n;\n\n // wh + bl cant be > 1\n if (ratio > 1) {\n wh /= ratio;\n bl /= ratio;\n }\n i = Math.floor(6 * h);\n v = 1 - bl;\n f = 6 * h - i;\n if ((i & 0x01) !== 0) {\n f = 1 - f;\n }\n n = wh + f * (v - wh); // linear interpolation\n\n var r;\n var g;\n var b;\n switch (i) {\n default:\n case 6:\n case 0:\n r = v;\n g = n;\n b = wh;\n break;\n case 1:\n r = n;\n g = v;\n b = wh;\n break;\n case 2:\n r = wh;\n g = v;\n b = n;\n break;\n case 3:\n r = wh;\n g = n;\n b = v;\n break;\n case 4:\n r = n;\n g = wh;\n b = v;\n break;\n case 5:\n r = v;\n g = wh;\n b = n;\n break;\n }\n return [r * 255, g * 255, b * 255];\n };\n convert.cmyk.rgb = function (cmyk) {\n var c = cmyk[0] / 100;\n var m = cmyk[1] / 100;\n var y = cmyk[2] / 100;\n var k = cmyk[3] / 100;\n var r;\n var g;\n var b;\n r = 1 - Math.min(1, c * (1 - k) + k);\n g = 1 - Math.min(1, m * (1 - k) + k);\n b = 1 - Math.min(1, y * (1 - k) + k);\n return [r * 255, g * 255, b * 255];\n };\n convert.xyz.rgb = function (xyz) {\n var x = xyz[0] / 100;\n var y = xyz[1] / 100;\n var z = xyz[2] / 100;\n var r;\n var g;\n var b;\n r = x * 3.2406 + y * -1.5372 + z * -0.4986;\n g = x * -0.9689 + y * 1.8758 + z * 0.0415;\n b = x * 0.0557 + y * -0.2040 + z * 1.0570;\n\n // assume sRGB\n r = r > 0.0031308 ? 1.055 * Math.pow(r, 1.0 / 2.4) - 0.055 : r * 12.92;\n g = g > 0.0031308 ? 1.055 * Math.pow(g, 1.0 / 2.4) - 0.055 : g * 12.92;\n b = b > 0.0031308 ? 1.055 * Math.pow(b, 1.0 / 2.4) - 0.055 : b * 12.92;\n r = Math.min(Math.max(0, r), 1);\n g = Math.min(Math.max(0, g), 1);\n b = Math.min(Math.max(0, b), 1);\n return [r * 255, g * 255, b * 255];\n };\n convert.xyz.lab = function (xyz) {\n var x = xyz[0];\n var y = xyz[1];\n var z = xyz[2];\n var l;\n var a;\n var b;\n x /= 95.047;\n y /= 100;\n z /= 108.883;\n x = x > 0.008856 ? Math.pow(x, 1 / 3) : 7.787 * x + 16 / 116;\n y = y > 0.008856 ? Math.pow(y, 1 / 3) : 7.787 * y + 16 / 116;\n z = z > 0.008856 ? Math.pow(z, 1 / 3) : 7.787 * z + 16 / 116;\n l = 116 * y - 16;\n a = 500 * (x - y);\n b = 200 * (y - z);\n return [l, a, b];\n };\n convert.lab.xyz = function (lab) {\n var l = lab[0];\n var a = lab[1];\n var b = lab[2];\n var x;\n var y;\n var z;\n y = (l + 16) / 116;\n x = a / 500 + y;\n z = y - b / 200;\n var y2 = Math.pow(y, 3);\n var x2 = Math.pow(x, 3);\n var z2 = Math.pow(z, 3);\n y = y2 > 0.008856 ? y2 : (y - 16 / 116) / 7.787;\n x = x2 > 0.008856 ? x2 : (x - 16 / 116) / 7.787;\n z = z2 > 0.008856 ? z2 : (z - 16 / 116) / 7.787;\n x *= 95.047;\n y *= 100;\n z *= 108.883;\n return [x, y, z];\n };\n convert.lab.lch = function (lab) {\n var l = lab[0];\n var a = lab[1];\n var b = lab[2];\n var hr;\n var h;\n var c;\n hr = Math.atan2(b, a);\n h = hr * 360 / 2 / Math.PI;\n if (h < 0) {\n h += 360;\n }\n c = Math.sqrt(a * a + b * b);\n return [l, c, h];\n };\n convert.lch.lab = function (lch) {\n var l = lch[0];\n var c = lch[1];\n var h = lch[2];\n var a;\n var b;\n var hr;\n hr = h / 360 * 2 * Math.PI;\n a = c * Math.cos(hr);\n b = c * Math.sin(hr);\n return [l, a, b];\n };\n convert.rgb.ansi16 = function (args) {\n var r = args[0];\n var g = args[1];\n var b = args[2];\n var value = 1 in arguments ? arguments[1] : convert.rgb.hsv(args)[2]; // hsv -> ansi16 optimization\n\n value = Math.round(value / 50);\n if (value === 0) {\n return 30;\n }\n var ansi = 30 + (Math.round(b / 255) << 2 | Math.round(g / 255) << 1 | Math.round(r / 255));\n if (value === 2) {\n ansi += 60;\n }\n return ansi;\n };\n convert.hsv.ansi16 = function (args) {\n // optimization here; we already know the value and don't need to get\n // it converted for us.\n return convert.rgb.ansi16(convert.hsv.rgb(args), args[2]);\n };\n convert.rgb.ansi256 = function (args) {\n var r = args[0];\n var g = args[1];\n var b = args[2];\n\n // we use the extended greyscale palette here, with the exception of\n // black and white. normal palette only has 4 greyscale shades.\n if (r === g && g === b) {\n if (r < 8) {\n return 16;\n }\n if (r > 248) {\n return 231;\n }\n return Math.round((r - 8) / 247 * 24) + 232;\n }\n var ansi = 16 + 36 * Math.round(r / 255 * 5) + 6 * Math.round(g / 255 * 5) + Math.round(b / 255 * 5);\n return ansi;\n };\n convert.ansi16.rgb = function (args) {\n var color = args % 10;\n\n // handle greyscale\n if (color === 0 || color === 7) {\n if (args > 50) {\n color += 3.5;\n }\n color = color / 10.5 * 255;\n return [color, color, color];\n }\n var mult = (~~(args > 50) + 1) * 0.5;\n var r = (color & 1) * mult * 255;\n var g = (color >> 1 & 1) * mult * 255;\n var b = (color >> 2 & 1) * mult * 255;\n return [r, g, b];\n };\n convert.ansi256.rgb = function (args) {\n // handle greyscale\n if (args >= 232) {\n var c = (args - 232) * 10 + 8;\n return [c, c, c];\n }\n args -= 16;\n var rem;\n var r = Math.floor(args / 36) / 5 * 255;\n var g = Math.floor((rem = args % 36) / 6) / 5 * 255;\n var b = rem % 6 / 5 * 255;\n return [r, g, b];\n };\n convert.rgb.hex = function (args) {\n var integer = ((Math.round(args[0]) & 0xFF) << 16) + ((Math.round(args[1]) & 0xFF) << 8) + (Math.round(args[2]) & 0xFF);\n var string = integer.toString(16).toUpperCase();\n return '000000'.substring(string.length) + string;\n };\n convert.hex.rgb = function (args) {\n var match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);\n if (!match) {\n return [0, 0, 0];\n }\n var colorString = match[0];\n if (match[0].length === 3) {\n colorString = colorString.split('').map(function (char) {\n return char + char;\n }).join('');\n }\n var integer = parseInt(colorString, 16);\n var r = integer >> 16 & 0xFF;\n var g = integer >> 8 & 0xFF;\n var b = integer & 0xFF;\n return [r, g, b];\n };\n convert.rgb.hcg = function (rgb) {\n var r = rgb[0] / 255;\n var g = rgb[1] / 255;\n var b = rgb[2] / 255;\n var max = Math.max(Math.max(r, g), b);\n var min = Math.min(Math.min(r, g), b);\n var chroma = max - min;\n var grayscale;\n var hue;\n if (chroma < 1) {\n grayscale = min / (1 - chroma);\n } else {\n grayscale = 0;\n }\n if (chroma <= 0) {\n hue = 0;\n } else if (max === r) {\n hue = (g - b) / chroma % 6;\n } else if (max === g) {\n hue = 2 + (b - r) / chroma;\n } else {\n hue = 4 + (r - g) / chroma + 4;\n }\n hue /= 6;\n hue %= 1;\n return [hue * 360, chroma * 100, grayscale * 100];\n };\n convert.hsl.hcg = function (hsl) {\n var s = hsl[1] / 100;\n var l = hsl[2] / 100;\n var c = 1;\n var f = 0;\n if (l < 0.5) {\n c = 2.0 * s * l;\n } else {\n c = 2.0 * s * (1.0 - l);\n }\n if (c < 1.0) {\n f = (l - 0.5 * c) / (1.0 - c);\n }\n return [hsl[0], c * 100, f * 100];\n };\n convert.hsv.hcg = function (hsv) {\n var s = hsv[1] / 100;\n var v = hsv[2] / 100;\n var c = s * v;\n var f = 0;\n if (c < 1.0) {\n f = (v - c) / (1 - c);\n }\n return [hsv[0], c * 100, f * 100];\n };\n convert.hcg.rgb = function (hcg) {\n var h = hcg[0] / 360;\n var c = hcg[1] / 100;\n var g = hcg[2] / 100;\n if (c === 0.0) {\n return [g * 255, g * 255, g * 255];\n }\n var pure = [0, 0, 0];\n var hi = h % 1 * 6;\n var v = hi % 1;\n var w = 1 - v;\n var mg = 0;\n switch (Math.floor(hi)) {\n case 0:\n pure[0] = 1;\n pure[1] = v;\n pure[2] = 0;\n break;\n case 1:\n pure[0] = w;\n pure[1] = 1;\n pure[2] = 0;\n break;\n case 2:\n pure[0] = 0;\n pure[1] = 1;\n pure[2] = v;\n break;\n case 3:\n pure[0] = 0;\n pure[1] = w;\n pure[2] = 1;\n break;\n case 4:\n pure[0] = v;\n pure[1] = 0;\n pure[2] = 1;\n break;\n default:\n pure[0] = 1;\n pure[1] = 0;\n pure[2] = w;\n }\n mg = (1.0 - c) * g;\n return [(c * pure[0] + mg) * 255, (c * pure[1] + mg) * 255, (c * pure[2] + mg) * 255];\n };\n convert.hcg.hsv = function (hcg) {\n var c = hcg[1] / 100;\n var g = hcg[2] / 100;\n var v = c + g * (1.0 - c);\n var f = 0;\n if (v > 0.0) {\n f = c / v;\n }\n return [hcg[0], f * 100, v * 100];\n };\n convert.hcg.hsl = function (hcg) {\n var c = hcg[1] / 100;\n var g = hcg[2] / 100;\n var l = g * (1.0 - c) + 0.5 * c;\n var s = 0;\n if (l > 0.0 && l < 0.5) {\n s = c / (2 * l);\n } else if (l >= 0.5 && l < 1.0) {\n s = c / (2 * (1 - l));\n }\n return [hcg[0], s * 100, l * 100];\n };\n convert.hcg.hwb = function (hcg) {\n var c = hcg[1] / 100;\n var g = hcg[2] / 100;\n var v = c + g * (1.0 - c);\n return [hcg[0], (v - c) * 100, (1 - v) * 100];\n };\n convert.hwb.hcg = function (hwb) {\n var w = hwb[1] / 100;\n var b = hwb[2] / 100;\n var v = 1 - b;\n var c = v - w;\n var g = 0;\n if (c < 1) {\n g = (v - c) / (1 - c);\n }\n return [hwb[0], c * 100, g * 100];\n };\n convert.apple.rgb = function (apple) {\n return [apple[0] / 65535 * 255, apple[1] / 65535 * 255, apple[2] / 65535 * 255];\n };\n convert.rgb.apple = function (rgb) {\n return [rgb[0] / 255 * 65535, rgb[1] / 255 * 65535, rgb[2] / 255 * 65535];\n };\n convert.gray.rgb = function (args) {\n return [args[0] / 100 * 255, args[0] / 100 * 255, args[0] / 100 * 255];\n };\n convert.gray.hsl = convert.gray.hsv = function (args) {\n return [0, 0, args[0]];\n };\n convert.gray.hwb = function (gray) {\n return [0, 100, gray[0]];\n };\n convert.gray.cmyk = function (gray) {\n return [0, 0, 0, gray[0]];\n };\n convert.gray.lab = function (gray) {\n return [gray[0], 0, 0];\n };\n convert.gray.hex = function (gray) {\n var val = Math.round(gray[0] / 100 * 255) & 0xFF;\n var integer = (val << 16) + (val << 8) + val;\n var string = integer.toString(16).toUpperCase();\n return '000000'.substring(string.length) + string;\n };\n convert.rgb.gray = function (rgb) {\n var val = (rgb[0] + rgb[1] + rgb[2]) / 3;\n return [val / 255 * 100];\n };\n });\n var conversions_1 = conversions.rgb;\n var conversions_2 = conversions.hsl;\n var conversions_3 = conversions.hsv;\n var conversions_4 = conversions.hwb;\n var conversions_5 = conversions.cmyk;\n var conversions_6 = conversions.xyz;\n var conversions_7 = conversions.lab;\n var conversions_8 = conversions.lch;\n var conversions_9 = conversions.hex;\n var conversions_10 = conversions.keyword;\n var conversions_11 = conversions.ansi16;\n var conversions_12 = conversions.ansi256;\n var conversions_13 = conversions.hcg;\n var conversions_14 = conversions.apple;\n var conversions_15 = conversions.gray;\n\n /*\n \tthis function routes a model to all other models.\n \n \tall functions that are routed have a property `.conversion` attached\n \tto the returned synthetic function. This property is an array\n \tof strings, each with the steps in between the 'from' and 'to'\n \tcolor models (inclusive).\n \n \tconversions that are not possible simply are not included.\n */\n\n function buildGraph() {\n var graph = {};\n // https://jsperf.com/object-keys-vs-for-in-with-closure/3\n var models = Object.keys(conversions);\n for (var len = models.length, i = 0; i < len; i++) {\n graph[models[i]] = {\n // http://jsperf.com/1-vs-infinity\n // micro-opt, but this is simple.\n distance: -1,\n parent: null\n };\n }\n return graph;\n }\n\n // https://en.wikipedia.org/wiki/Breadth-first_search\n function deriveBFS(fromModel) {\n var graph = buildGraph();\n var queue = [fromModel]; // unshift -> queue -> pop\n\n graph[fromModel].distance = 0;\n while (queue.length) {\n var current = queue.pop();\n var adjacents = Object.keys(conversions[current]);\n for (var len = adjacents.length, i = 0; i < len; i++) {\n var adjacent = adjacents[i];\n var node = graph[adjacent];\n if (node.distance === -1) {\n node.distance = graph[current].distance + 1;\n node.parent = current;\n queue.unshift(adjacent);\n }\n }\n }\n return graph;\n }\n function link(from, to) {\n return function (args) {\n return to(from(args));\n };\n }\n function wrapConversion(toModel, graph) {\n var path = [graph[toModel].parent, toModel];\n var fn = conversions[graph[toModel].parent][toModel];\n var cur = graph[toModel].parent;\n while (graph[cur].parent) {\n path.unshift(graph[cur].parent);\n fn = link(conversions[graph[cur].parent][cur], fn);\n cur = graph[cur].parent;\n }\n fn.conversion = path;\n return fn;\n }\n var route = function (fromModel) {\n var graph = deriveBFS(fromModel);\n var conversion = {};\n var models = Object.keys(graph);\n for (var len = models.length, i = 0; i < len; i++) {\n var toModel = models[i];\n var node = graph[toModel];\n if (node.parent === null) {\n // no possible conversion, or this node is the source model.\n continue;\n }\n conversion[toModel] = wrapConversion(toModel, graph);\n }\n return conversion;\n };\n var convert = {};\n var models = Object.keys(conversions);\n function wrapRaw(fn) {\n var wrappedFn = function (args) {\n if (args === undefined || args === null) {\n return args;\n }\n if (arguments.length > 1) {\n args = Array.prototype.slice.call(arguments);\n }\n return fn(args);\n };\n\n // preserve .conversion property if there is one\n if ('conversion' in fn) {\n wrappedFn.conversion = fn.conversion;\n }\n return wrappedFn;\n }\n function wrapRounded(fn) {\n var wrappedFn = function (args) {\n if (args === undefined || args === null) {\n return args;\n }\n if (arguments.length > 1) {\n args = Array.prototype.slice.call(arguments);\n }\n var result = fn(args);\n\n // we're assuming the result is an array here.\n // see notice in conversions.js; don't use box types\n // in conversion functions.\n if (typeof result === 'object') {\n for (var len = result.length, i = 0; i < len; i++) {\n result[i] = Math.round(result[i]);\n }\n }\n return result;\n };\n\n // preserve .conversion property if there is one\n if ('conversion' in fn) {\n wrappedFn.conversion = fn.conversion;\n }\n return wrappedFn;\n }\n models.forEach(function (fromModel) {\n convert[fromModel] = {};\n Object.defineProperty(convert[fromModel], 'channels', {\n value: conversions[fromModel].channels\n });\n Object.defineProperty(convert[fromModel], 'labels', {\n value: conversions[fromModel].labels\n });\n var routes = route(fromModel);\n var routeModels = Object.keys(routes);\n routeModels.forEach(function (toModel) {\n var fn = routes[toModel];\n convert[fromModel][toModel] = wrapRounded(fn);\n convert[fromModel][toModel].raw = wrapRaw(fn);\n });\n });\n var colorConvert = convert;\n var colorName$1 = {\n \"aliceblue\": [240, 248, 255],\n \"antiquewhite\": [250, 235, 215],\n \"aqua\": [0, 255, 255],\n \"aquamarine\": [127, 255, 212],\n \"azure\": [240, 255, 255],\n \"beige\": [245, 245, 220],\n \"bisque\": [255, 228, 196],\n \"black\": [0, 0, 0],\n \"blanchedalmond\": [255, 235, 205],\n \"blue\": [0, 0, 255],\n \"blueviolet\": [138, 43, 226],\n \"brown\": [165, 42, 42],\n \"burlywood\": [222, 184, 135],\n \"cadetblue\": [95, 158, 160],\n \"chartreuse\": [127, 255, 0],\n \"chocolate\": [210, 105, 30],\n \"coral\": [255, 127, 80],\n \"cornflowerblue\": [100, 149, 237],\n \"cornsilk\": [255, 248, 220],\n \"crimson\": [220, 20, 60],\n \"cyan\": [0, 255, 255],\n \"darkblue\": [0, 0, 139],\n \"darkcyan\": [0, 139, 139],\n \"darkgoldenrod\": [184, 134, 11],\n \"darkgray\": [169, 169, 169],\n \"darkgreen\": [0, 100, 0],\n \"darkgrey\": [169, 169, 169],\n \"darkkhaki\": [189, 183, 107],\n \"darkmagenta\": [139, 0, 139],\n \"darkolivegreen\": [85, 107, 47],\n \"darkorange\": [255, 140, 0],\n \"darkorchid\": [153, 50, 204],\n \"darkred\": [139, 0, 0],\n \"darksalmon\": [233, 150, 122],\n \"darkseagreen\": [143, 188, 143],\n \"darkslateblue\": [72, 61, 139],\n \"darkslategray\": [47, 79, 79],\n \"darkslategrey\": [47, 79, 79],\n \"darkturquoise\": [0, 206, 209],\n \"darkviolet\": [148, 0, 211],\n \"deeppink\": [255, 20, 147],\n \"deepskyblue\": [0, 191, 255],\n \"dimgray\": [105, 105, 105],\n \"dimgrey\": [105, 105, 105],\n \"dodgerblue\": [30, 144, 255],\n \"firebrick\": [178, 34, 34],\n \"floralwhite\": [255, 250, 240],\n \"forestgreen\": [34, 139, 34],\n \"fuchsia\": [255, 0, 255],\n \"gainsboro\": [220, 220, 220],\n \"ghostwhite\": [248, 248, 255],\n \"gold\": [255, 215, 0],\n \"goldenrod\": [218, 165, 32],\n \"gray\": [128, 128, 128],\n \"green\": [0, 128, 0],\n \"greenyellow\": [173, 255, 47],\n \"grey\": [128, 128, 128],\n \"honeydew\": [240, 255, 240],\n \"hotpink\": [255, 105, 180],\n \"indianred\": [205, 92, 92],\n \"indigo\": [75, 0, 130],\n \"ivory\": [255, 255, 240],\n \"khaki\": [240, 230, 140],\n \"lavender\": [230, 230, 250],\n \"lavenderblush\": [255, 240, 245],\n \"lawngreen\": [124, 252, 0],\n \"lemonchiffon\": [255, 250, 205],\n \"lightblue\": [173, 216, 230],\n \"lightcoral\": [240, 128, 128],\n \"lightcyan\": [224, 255, 255],\n \"lightgoldenrodyellow\": [250, 250, 210],\n \"lightgray\": [211, 211, 211],\n \"lightgreen\": [144, 238, 144],\n \"lightgrey\": [211, 211, 211],\n \"lightpink\": [255, 182, 193],\n \"lightsalmon\": [255, 160, 122],\n \"lightseagreen\": [32, 178, 170],\n \"lightskyblue\": [135, 206, 250],\n \"lightslategray\": [119, 136, 153],\n \"lightslategrey\": [119, 136, 153],\n \"lightsteelblue\": [176, 196, 222],\n \"lightyellow\": [255, 255, 224],\n \"lime\": [0, 255, 0],\n \"limegreen\": [50, 205, 50],\n \"linen\": [250, 240, 230],\n \"magenta\": [255, 0, 255],\n \"maroon\": [128, 0, 0],\n \"mediumaquamarine\": [102, 205, 170],\n \"mediumblue\": [0, 0, 205],\n \"mediumorchid\": [186, 85, 211],\n \"mediumpurple\": [147, 112, 219],\n \"mediumseagreen\": [60, 179, 113],\n \"mediumslateblue\": [123, 104, 238],\n \"mediumspringgreen\": [0, 250, 154],\n \"mediumturquoise\": [72, 209, 204],\n \"mediumvioletred\": [199, 21, 133],\n \"midnightblue\": [25, 25, 112],\n \"mintcream\": [245, 255, 250],\n \"mistyrose\": [255, 228, 225],\n \"moccasin\": [255, 228, 181],\n \"navajowhite\": [255, 222, 173],\n \"navy\": [0, 0, 128],\n \"oldlace\": [253, 245, 230],\n \"olive\": [128, 128, 0],\n \"olivedrab\": [107, 142, 35],\n \"orange\": [255, 165, 0],\n \"orangered\": [255, 69, 0],\n \"orchid\": [218, 112, 214],\n \"palegoldenrod\": [238, 232, 170],\n \"palegreen\": [152, 251, 152],\n \"paleturquoise\": [175, 238, 238],\n \"palevioletred\": [219, 112, 147],\n \"papayawhip\": [255, 239, 213],\n \"peachpuff\": [255, 218, 185],\n \"peru\": [205, 133, 63],\n \"pink\": [255, 192, 203],\n \"plum\": [221, 160, 221],\n \"powderblue\": [176, 224, 230],\n \"purple\": [128, 0, 128],\n \"rebeccapurple\": [102, 51, 153],\n \"red\": [255, 0, 0],\n \"rosybrown\": [188, 143, 143],\n \"royalblue\": [65, 105, 225],\n \"saddlebrown\": [139, 69, 19],\n \"salmon\": [250, 128, 114],\n \"sandybrown\": [244, 164, 96],\n \"seagreen\": [46, 139, 87],\n \"seashell\": [255, 245, 238],\n \"sienna\": [160, 82, 45],\n \"silver\": [192, 192, 192],\n \"skyblue\": [135, 206, 235],\n \"slateblue\": [106, 90, 205],\n \"slategray\": [112, 128, 144],\n \"slategrey\": [112, 128, 144],\n \"snow\": [255, 250, 250],\n \"springgreen\": [0, 255, 127],\n \"steelblue\": [70, 130, 180],\n \"tan\": [210, 180, 140],\n \"teal\": [0, 128, 128],\n \"thistle\": [216, 191, 216],\n \"tomato\": [255, 99, 71],\n \"turquoise\": [64, 224, 208],\n \"violet\": [238, 130, 238],\n \"wheat\": [245, 222, 179],\n \"white\": [255, 255, 255],\n \"whitesmoke\": [245, 245, 245],\n \"yellow\": [255, 255, 0],\n \"yellowgreen\": [154, 205, 50]\n };\n\n /* MIT license */\n\n var colorString = {\n getRgba: getRgba,\n getHsla: getHsla,\n getRgb: getRgb,\n getHsl: getHsl,\n getHwb: getHwb,\n getAlpha: getAlpha,\n hexString: hexString,\n rgbString: rgbString,\n rgbaString: rgbaString,\n percentString: percentString,\n percentaString: percentaString,\n hslString: hslString,\n hslaString: hslaString,\n hwbString: hwbString,\n keyword: keyword\n };\n function getRgba(string) {\n if (!string) {\n return;\n }\n var abbr = /^#([a-fA-F0-9]{3,4})$/i,\n hex = /^#([a-fA-F0-9]{6}([a-fA-F0-9]{2})?)$/i,\n rgba = /^rgba?\\(\\s*([+-]?\\d+)\\s*,\\s*([+-]?\\d+)\\s*,\\s*([+-]?\\d+)\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)$/i,\n per = /^rgba?\\(\\s*([+-]?[\\d\\.]+)\\%\\s*,\\s*([+-]?[\\d\\.]+)\\%\\s*,\\s*([+-]?[\\d\\.]+)\\%\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)$/i,\n keyword = /(\\w+)/;\n var rgb = [0, 0, 0],\n a = 1,\n match = string.match(abbr),\n hexAlpha = \"\";\n if (match) {\n match = match[1];\n hexAlpha = match[3];\n for (var i = 0; i < rgb.length; i++) {\n rgb[i] = parseInt(match[i] + match[i], 16);\n }\n if (hexAlpha) {\n a = Math.round(parseInt(hexAlpha + hexAlpha, 16) / 255 * 100) / 100;\n }\n } else if (match = string.match(hex)) {\n hexAlpha = match[2];\n match = match[1];\n for (var i = 0; i < rgb.length; i++) {\n rgb[i] = parseInt(match.slice(i * 2, i * 2 + 2), 16);\n }\n if (hexAlpha) {\n a = Math.round(parseInt(hexAlpha, 16) / 255 * 100) / 100;\n }\n } else if (match = string.match(rgba)) {\n for (var i = 0; i < rgb.length; i++) {\n rgb[i] = parseInt(match[i + 1]);\n }\n a = parseFloat(match[4]);\n } else if (match = string.match(per)) {\n for (var i = 0; i < rgb.length; i++) {\n rgb[i] = Math.round(parseFloat(match[i + 1]) * 2.55);\n }\n a = parseFloat(match[4]);\n } else if (match = string.match(keyword)) {\n if (match[1] == \"transparent\") {\n return [0, 0, 0, 0];\n }\n rgb = colorName$1[match[1]];\n if (!rgb) {\n return;\n }\n }\n for (var i = 0; i < rgb.length; i++) {\n rgb[i] = scale(rgb[i], 0, 255);\n }\n if (!a && a != 0) {\n a = 1;\n } else {\n a = scale(a, 0, 1);\n }\n rgb[3] = a;\n return rgb;\n }\n function getHsla(string) {\n if (!string) {\n return;\n }\n var hsl = /^hsla?\\(\\s*([+-]?\\d+)(?:deg)?\\s*,\\s*([+-]?[\\d\\.]+)%\\s*,\\s*([+-]?[\\d\\.]+)%\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)/;\n var match = string.match(hsl);\n if (match) {\n var alpha = parseFloat(match[4]);\n var h = scale(parseInt(match[1]), 0, 360),\n s = scale(parseFloat(match[2]), 0, 100),\n l = scale(parseFloat(match[3]), 0, 100),\n a = scale(isNaN(alpha) ? 1 : alpha, 0, 1);\n return [h, s, l, a];\n }\n }\n function getHwb(string) {\n if (!string) {\n return;\n }\n var hwb = /^hwb\\(\\s*([+-]?\\d+)(?:deg)?\\s*,\\s*([+-]?[\\d\\.]+)%\\s*,\\s*([+-]?[\\d\\.]+)%\\s*(?:,\\s*([+-]?[\\d\\.]+)\\s*)?\\)/;\n var match = string.match(hwb);\n if (match) {\n var alpha = parseFloat(match[4]);\n var h = scale(parseInt(match[1]), 0, 360),\n w = scale(parseFloat(match[2]), 0, 100),\n b = scale(parseFloat(match[3]), 0, 100),\n a = scale(isNaN(alpha) ? 1 : alpha, 0, 1);\n return [h, w, b, a];\n }\n }\n function getRgb(string) {\n var rgba = getRgba(string);\n return rgba && rgba.slice(0, 3);\n }\n function getHsl(string) {\n var hsla = getHsla(string);\n return hsla && hsla.slice(0, 3);\n }\n function getAlpha(string) {\n var vals = getRgba(string);\n if (vals) {\n return vals[3];\n } else if (vals = getHsla(string)) {\n return vals[3];\n } else if (vals = getHwb(string)) {\n return vals[3];\n }\n }\n\n // generators\n function hexString(rgba, a) {\n var a = a !== undefined && rgba.length === 3 ? a : rgba[3];\n return \"#\" + hexDouble(rgba[0]) + hexDouble(rgba[1]) + hexDouble(rgba[2]) + (a >= 0 && a < 1 ? hexDouble(Math.round(a * 255)) : \"\");\n }\n function rgbString(rgba, alpha) {\n if (alpha < 1 || rgba[3] && rgba[3] < 1) {\n return rgbaString(rgba, alpha);\n }\n return \"rgb(\" + rgba[0] + \", \" + rgba[1] + \", \" + rgba[2] + \")\";\n }\n function rgbaString(rgba, alpha) {\n if (alpha === undefined) {\n alpha = rgba[3] !== undefined ? rgba[3] : 1;\n }\n return \"rgba(\" + rgba[0] + \", \" + rgba[1] + \", \" + rgba[2] + \", \" + alpha + \")\";\n }\n function percentString(rgba, alpha) {\n if (alpha < 1 || rgba[3] && rgba[3] < 1) {\n return percentaString(rgba, alpha);\n }\n var r = Math.round(rgba[0] / 255 * 100),\n g = Math.round(rgba[1] / 255 * 100),\n b = Math.round(rgba[2] / 255 * 100);\n return \"rgb(\" + r + \"%, \" + g + \"%, \" + b + \"%)\";\n }\n function percentaString(rgba, alpha) {\n var r = Math.round(rgba[0] / 255 * 100),\n g = Math.round(rgba[1] / 255 * 100),\n b = Math.round(rgba[2] / 255 * 100);\n return \"rgba(\" + r + \"%, \" + g + \"%, \" + b + \"%, \" + (alpha || rgba[3] || 1) + \")\";\n }\n function hslString(hsla, alpha) {\n if (alpha < 1 || hsla[3] && hsla[3] < 1) {\n return hslaString(hsla, alpha);\n }\n return \"hsl(\" + hsla[0] + \", \" + hsla[1] + \"%, \" + hsla[2] + \"%)\";\n }\n function hslaString(hsla, alpha) {\n if (alpha === undefined) {\n alpha = hsla[3] !== undefined ? hsla[3] : 1;\n }\n return \"hsla(\" + hsla[0] + \", \" + hsla[1] + \"%, \" + hsla[2] + \"%, \" + alpha + \")\";\n }\n\n // hwb is a bit different than rgb(a) & hsl(a) since there is no alpha specific syntax\n // (hwb have alpha optional & 1 is default value)\n function hwbString(hwb, alpha) {\n if (alpha === undefined) {\n alpha = hwb[3] !== undefined ? hwb[3] : 1;\n }\n return \"hwb(\" + hwb[0] + \", \" + hwb[1] + \"%, \" + hwb[2] + \"%\" + (alpha !== undefined && alpha !== 1 ? \", \" + alpha : \"\") + \")\";\n }\n function keyword(rgb) {\n return reverseNames[rgb.slice(0, 3)];\n }\n\n // helpers\n function scale(num, min, max) {\n return Math.min(Math.max(min, num), max);\n }\n function hexDouble(num) {\n var str = num.toString(16).toUpperCase();\n return str.length < 2 ? \"0\" + str : str;\n }\n\n //create a list of reverse color names\n var reverseNames = {};\n for (var name in colorName$1) {\n reverseNames[colorName$1[name]] = name;\n }\n\n /* MIT license */\n\n var Color = function (obj) {\n if (obj instanceof Color) {\n return obj;\n }\n if (!(this instanceof Color)) {\n return new Color(obj);\n }\n this.valid = false;\n this.values = {\n rgb: [0, 0, 0],\n hsl: [0, 0, 0],\n hsv: [0, 0, 0],\n hwb: [0, 0, 0],\n cmyk: [0, 0, 0, 0],\n alpha: 1\n };\n\n // parse Color() argument\n var vals;\n if (typeof obj === 'string') {\n vals = colorString.getRgba(obj);\n if (vals) {\n this.setValues('rgb', vals);\n } else if (vals = colorString.getHsla(obj)) {\n this.setValues('hsl', vals);\n } else if (vals = colorString.getHwb(obj)) {\n this.setValues('hwb', vals);\n }\n } else if (typeof obj === 'object') {\n vals = obj;\n if (vals.r !== undefined || vals.red !== undefined) {\n this.setValues('rgb', vals);\n } else if (vals.l !== undefined || vals.lightness !== undefined) {\n this.setValues('hsl', vals);\n } else if (vals.v !== undefined || vals.value !== undefined) {\n this.setValues('hsv', vals);\n } else if (vals.w !== undefined || vals.whiteness !== undefined) {\n this.setValues('hwb', vals);\n } else if (vals.c !== undefined || vals.cyan !== undefined) {\n this.setValues('cmyk', vals);\n }\n }\n };\n Color.prototype = {\n isValid: function () {\n return this.valid;\n },\n rgb: function () {\n return this.setSpace('rgb', arguments);\n },\n hsl: function () {\n return this.setSpace('hsl', arguments);\n },\n hsv: function () {\n return this.setSpace('hsv', arguments);\n },\n hwb: function () {\n return this.setSpace('hwb', arguments);\n },\n cmyk: function () {\n return this.setSpace('cmyk', arguments);\n },\n rgbArray: function () {\n return this.values.rgb;\n },\n hslArray: function () {\n return this.values.hsl;\n },\n hsvArray: function () {\n return this.values.hsv;\n },\n hwbArray: function () {\n var values = this.values;\n if (values.alpha !== 1) {\n return values.hwb.concat([values.alpha]);\n }\n return values.hwb;\n },\n cmykArray: function () {\n return this.values.cmyk;\n },\n rgbaArray: function () {\n var values = this.values;\n return values.rgb.concat([values.alpha]);\n },\n hslaArray: function () {\n var values = this.values;\n return values.hsl.concat([values.alpha]);\n },\n alpha: function (val) {\n if (val === undefined) {\n return this.values.alpha;\n }\n this.setValues('alpha', val);\n return this;\n },\n red: function (val) {\n return this.setChannel('rgb', 0, val);\n },\n green: function (val) {\n return this.setChannel('rgb', 1, val);\n },\n blue: function (val) {\n return this.setChannel('rgb', 2, val);\n },\n hue: function (val) {\n if (val) {\n val %= 360;\n val = val < 0 ? 360 + val : val;\n }\n return this.setChannel('hsl', 0, val);\n },\n saturation: function (val) {\n return this.setChannel('hsl', 1, val);\n },\n lightness: function (val) {\n return this.setChannel('hsl', 2, val);\n },\n saturationv: function (val) {\n return this.setChannel('hsv', 1, val);\n },\n whiteness: function (val) {\n return this.setChannel('hwb', 1, val);\n },\n blackness: function (val) {\n return this.setChannel('hwb', 2, val);\n },\n value: function (val) {\n return this.setChannel('hsv', 2, val);\n },\n cyan: function (val) {\n return this.setChannel('cmyk', 0, val);\n },\n magenta: function (val) {\n return this.setChannel('cmyk', 1, val);\n },\n yellow: function (val) {\n return this.setChannel('cmyk', 2, val);\n },\n black: function (val) {\n return this.setChannel('cmyk', 3, val);\n },\n hexString: function () {\n return colorString.hexString(this.values.rgb);\n },\n rgbString: function () {\n return colorString.rgbString(this.values.rgb, this.values.alpha);\n },\n rgbaString: function () {\n return colorString.rgbaString(this.values.rgb, this.values.alpha);\n },\n percentString: function () {\n return colorString.percentString(this.values.rgb, this.values.alpha);\n },\n hslString: function () {\n return colorString.hslString(this.values.hsl, this.values.alpha);\n },\n hslaString: function () {\n return colorString.hslaString(this.values.hsl, this.values.alpha);\n },\n hwbString: function () {\n return colorString.hwbString(this.values.hwb, this.values.alpha);\n },\n keyword: function () {\n return colorString.keyword(this.values.rgb, this.values.alpha);\n },\n rgbNumber: function () {\n var rgb = this.values.rgb;\n return rgb[0] << 16 | rgb[1] << 8 | rgb[2];\n },\n luminosity: function () {\n // http://www.w3.org/TR/WCAG20/#relativeluminancedef\n var rgb = this.values.rgb;\n var lum = [];\n for (var i = 0; i < rgb.length; i++) {\n var chan = rgb[i] / 255;\n lum[i] = chan <= 0.03928 ? chan / 12.92 : Math.pow((chan + 0.055) / 1.055, 2.4);\n }\n return 0.2126 * lum[0] + 0.7152 * lum[1] + 0.0722 * lum[2];\n },\n contrast: function (color2) {\n // http://www.w3.org/TR/WCAG20/#contrast-ratiodef\n var lum1 = this.luminosity();\n var lum2 = color2.luminosity();\n if (lum1 > lum2) {\n return (lum1 + 0.05) / (lum2 + 0.05);\n }\n return (lum2 + 0.05) / (lum1 + 0.05);\n },\n level: function (color2) {\n var contrastRatio = this.contrast(color2);\n if (contrastRatio >= 7.1) {\n return 'AAA';\n }\n return contrastRatio >= 4.5 ? 'AA' : '';\n },\n dark: function () {\n // YIQ equation from http://24ways.org/2010/calculating-color-contrast\n var rgb = this.values.rgb;\n var yiq = (rgb[0] * 299 + rgb[1] * 587 + rgb[2] * 114) / 1000;\n return yiq < 128;\n },\n light: function () {\n return !this.dark();\n },\n negate: function () {\n var rgb = [];\n for (var i = 0; i < 3; i++) {\n rgb[i] = 255 - this.values.rgb[i];\n }\n this.setValues('rgb', rgb);\n return this;\n },\n lighten: function (ratio) {\n var hsl = this.values.hsl;\n hsl[2] += hsl[2] * ratio;\n this.setValues('hsl', hsl);\n return this;\n },\n darken: function (ratio) {\n var hsl = this.values.hsl;\n hsl[2] -= hsl[2] * ratio;\n this.setValues('hsl', hsl);\n return this;\n },\n saturate: function (ratio) {\n var hsl = this.values.hsl;\n hsl[1] += hsl[1] * ratio;\n this.setValues('hsl', hsl);\n return this;\n },\n desaturate: function (ratio) {\n var hsl = this.values.hsl;\n hsl[1] -= hsl[1] * ratio;\n this.setValues('hsl', hsl);\n return this;\n },\n whiten: function (ratio) {\n var hwb = this.values.hwb;\n hwb[1] += hwb[1] * ratio;\n this.setValues('hwb', hwb);\n return this;\n },\n blacken: function (ratio) {\n var hwb = this.values.hwb;\n hwb[2] += hwb[2] * ratio;\n this.setValues('hwb', hwb);\n return this;\n },\n greyscale: function () {\n var rgb = this.values.rgb;\n // http://en.wikipedia.org/wiki/Grayscale#Converting_color_to_grayscale\n var val = rgb[0] * 0.3 + rgb[1] * 0.59 + rgb[2] * 0.11;\n this.setValues('rgb', [val, val, val]);\n return this;\n },\n clearer: function (ratio) {\n var alpha = this.values.alpha;\n this.setValues('alpha', alpha - alpha * ratio);\n return this;\n },\n opaquer: function (ratio) {\n var alpha = this.values.alpha;\n this.setValues('alpha', alpha + alpha * ratio);\n return this;\n },\n rotate: function (degrees) {\n var hsl = this.values.hsl;\n var hue = (hsl[0] + degrees) % 360;\n hsl[0] = hue < 0 ? 360 + hue : hue;\n this.setValues('hsl', hsl);\n return this;\n },\n /**\n * Ported from sass implementation in C\n * https://github.com/sass/libsass/blob/0e6b4a2850092356aa3ece07c6b249f0221caced/functions.cpp#L209\n */\n mix: function (mixinColor, weight) {\n var color1 = this;\n var color2 = mixinColor;\n var p = weight === undefined ? 0.5 : weight;\n var w = 2 * p - 1;\n var a = color1.alpha() - color2.alpha();\n var w1 = ((w * a === -1 ? w : (w + a) / (1 + w * a)) + 1) / 2.0;\n var w2 = 1 - w1;\n return this.rgb(w1 * color1.red() + w2 * color2.red(), w1 * color1.green() + w2 * color2.green(), w1 * color1.blue() + w2 * color2.blue()).alpha(color1.alpha() * p + color2.alpha() * (1 - p));\n },\n toJSON: function () {\n return this.rgb();\n },\n clone: function () {\n // NOTE(SB): using node-clone creates a dependency to Buffer when using browserify,\n // making the final build way to big to embed in Chart.js. So let's do it manually,\n // assuming that values to clone are 1 dimension arrays containing only numbers,\n // except 'alpha' which is a number.\n var result = new Color();\n var source = this.values;\n var target = result.values;\n var value, type;\n for (var prop in source) {\n if (source.hasOwnProperty(prop)) {\n value = source[prop];\n type = {}.toString.call(value);\n if (type === '[object Array]') {\n target[prop] = value.slice(0);\n } else if (type === '[object Number]') {\n target[prop] = value;\n } else {\n console.error('unexpected color value:', value);\n }\n }\n }\n return result;\n }\n };\n Color.prototype.spaces = {\n rgb: ['red', 'green', 'blue'],\n hsl: ['hue', 'saturation', 'lightness'],\n hsv: ['hue', 'saturation', 'value'],\n hwb: ['hue', 'whiteness', 'blackness'],\n cmyk: ['cyan', 'magenta', 'yellow', 'black']\n };\n Color.prototype.maxes = {\n rgb: [255, 255, 255],\n hsl: [360, 100, 100],\n hsv: [360, 100, 100],\n hwb: [360, 100, 100],\n cmyk: [100, 100, 100, 100]\n };\n Color.prototype.getValues = function (space) {\n var values = this.values;\n var vals = {};\n for (var i = 0; i < space.length; i++) {\n vals[space.charAt(i)] = values[space][i];\n }\n if (values.alpha !== 1) {\n vals.a = values.alpha;\n }\n\n // {r: 255, g: 255, b: 255, a: 0.4}\n return vals;\n };\n Color.prototype.setValues = function (space, vals) {\n var values = this.values;\n var spaces = this.spaces;\n var maxes = this.maxes;\n var alpha = 1;\n var i;\n this.valid = true;\n if (space === 'alpha') {\n alpha = vals;\n } else if (vals.length) {\n // [10, 10, 10]\n values[space] = vals.slice(0, space.length);\n alpha = vals[space.length];\n } else if (vals[space.charAt(0)] !== undefined) {\n // {r: 10, g: 10, b: 10}\n for (i = 0; i < space.length; i++) {\n values[space][i] = vals[space.charAt(i)];\n }\n alpha = vals.a;\n } else if (vals[spaces[space][0]] !== undefined) {\n // {red: 10, green: 10, blue: 10}\n var chans = spaces[space];\n for (i = 0; i < space.length; i++) {\n values[space][i] = vals[chans[i]];\n }\n alpha = vals.alpha;\n }\n values.alpha = Math.max(0, Math.min(1, alpha === undefined ? values.alpha : alpha));\n if (space === 'alpha') {\n return false;\n }\n var capped;\n\n // cap values of the space prior converting all values\n for (i = 0; i < space.length; i++) {\n capped = Math.max(0, Math.min(maxes[space][i], values[space][i]));\n values[space][i] = Math.round(capped);\n }\n\n // convert to all the other color spaces\n for (var sname in spaces) {\n if (sname !== space) {\n values[sname] = colorConvert[space][sname](values[space]);\n }\n }\n return true;\n };\n Color.prototype.setSpace = function (space, args) {\n var vals = args[0];\n if (vals === undefined) {\n // color.rgb()\n return this.getValues(space);\n }\n\n // color.rgb(10, 10, 10)\n if (typeof vals === 'number') {\n vals = Array.prototype.slice.call(args);\n }\n this.setValues(space, vals);\n return this;\n };\n Color.prototype.setChannel = function (space, index, val) {\n var svalues = this.values[space];\n if (val === undefined) {\n // color.red()\n return svalues[index];\n } else if (val === svalues[index]) {\n // color.red(color.red())\n return this;\n }\n\n // color.red(100)\n svalues[index] = val;\n this.setValues(space, svalues);\n return this;\n };\n if (typeof window !== 'undefined') {\n window.Color = Color;\n }\n var chartjsColor = Color;\n function isValidKey(key) {\n return ['__proto__', 'prototype', 'constructor'].indexOf(key) === -1;\n }\n\n /**\r\n * @namespace Chart.helpers\r\n */\n var helpers = {\n /**\r\n * An empty function that can be used, for example, for optional callback.\r\n */\n noop: function () {},\n /**\r\n * Returns a unique id, sequentially generated from a global variable.\r\n * @returns {number}\r\n * @function\r\n */\n uid: function () {\n var id = 0;\n return function () {\n return id++;\n };\n }(),\n /**\r\n * Returns true if `value` is neither null nor undefined, else returns false.\r\n * @param {*} value - The value to test.\r\n * @returns {boolean}\r\n * @since 2.7.0\r\n */\n isNullOrUndef: function (value) {\n return value === null || typeof value === 'undefined';\n },\n /**\r\n * Returns true if `value` is an array (including typed arrays), else returns false.\r\n * @param {*} value - The value to test.\r\n * @returns {boolean}\r\n * @function\r\n */\n isArray: function (value) {\n if (Array.isArray && Array.isArray(value)) {\n return true;\n }\n var type = Object.prototype.toString.call(value);\n if (type.substr(0, 7) === '[object' && type.substr(-6) === 'Array]') {\n return true;\n }\n return false;\n },\n /**\r\n * Returns true if `value` is an object (excluding null), else returns false.\r\n * @param {*} value - The value to test.\r\n * @returns {boolean}\r\n * @since 2.7.0\r\n */\n isObject: function (value) {\n return value !== null && Object.prototype.toString.call(value) === '[object Object]';\n },\n /**\r\n * Returns true if `value` is a finite number, else returns false\r\n * @param {*} value - The value to test.\r\n * @returns {boolean}\r\n */\n isFinite: function (value) {\n return (typeof value === 'number' || value instanceof Number) && isFinite(value);\n },\n /**\r\n * Returns `value` if defined, else returns `defaultValue`.\r\n * @param {*} value - The value to return if defined.\r\n * @param {*} defaultValue - The value to return if `value` is undefined.\r\n * @returns {*}\r\n */\n valueOrDefault: function (value, defaultValue) {\n return typeof value === 'undefined' ? defaultValue : value;\n },\n /**\r\n * Returns value at the given `index` in array if defined, else returns `defaultValue`.\r\n * @param {Array} value - The array to lookup for value at `index`.\r\n * @param {number} index - The index in `value` to lookup for value.\r\n * @param {*} defaultValue - The value to return if `value[index]` is undefined.\r\n * @returns {*}\r\n */\n valueAtIndexOrDefault: function (value, index, defaultValue) {\n return helpers.valueOrDefault(helpers.isArray(value) ? value[index] : value, defaultValue);\n },\n /**\r\n * Calls `fn` with the given `args` in the scope defined by `thisArg` and returns the\r\n * value returned by `fn`. If `fn` is not a function, this method returns undefined.\r\n * @param {function} fn - The function to call.\r\n * @param {Array|undefined|null} args - The arguments with which `fn` should be called.\r\n * @param {object} [thisArg] - The value of `this` provided for the call to `fn`.\r\n * @returns {*}\r\n */\n callback: function (fn, args, thisArg) {\n if (fn && typeof fn.call === 'function') {\n return fn.apply(thisArg, args);\n }\n },\n /**\r\n * Note(SB) for performance sake, this method should only be used when loopable type\r\n * is unknown or in none intensive code (not called often and small loopable). Else\r\n * it's preferable to use a regular for() loop and save extra function calls.\r\n * @param {object|Array} loopable - The object or array to be iterated.\r\n * @param {function} fn - The function to call for each item.\r\n * @param {object} [thisArg] - The value of `this` provided for the call to `fn`.\r\n * @param {boolean} [reverse] - If true, iterates backward on the loopable.\r\n */\n each: function (loopable, fn, thisArg, reverse) {\n var i, len, keys;\n if (helpers.isArray(loopable)) {\n len = loopable.length;\n if (reverse) {\n for (i = len - 1; i >= 0; i--) {\n fn.call(thisArg, loopable[i], i);\n }\n } else {\n for (i = 0; i < len; i++) {\n fn.call(thisArg, loopable[i], i);\n }\n }\n } else if (helpers.isObject(loopable)) {\n keys = Object.keys(loopable);\n len = keys.length;\n for (i = 0; i < len; i++) {\n fn.call(thisArg, loopable[keys[i]], keys[i]);\n }\n }\n },\n /**\r\n * Returns true if the `a0` and `a1` arrays have the same content, else returns false.\r\n * @see https://stackoverflow.com/a/14853974\r\n * @param {Array} a0 - The array to compare\r\n * @param {Array} a1 - The array to compare\r\n * @returns {boolean}\r\n */\n arrayEquals: function (a0, a1) {\n var i, ilen, v0, v1;\n if (!a0 || !a1 || a0.length !== a1.length) {\n return false;\n }\n for (i = 0, ilen = a0.length; i < ilen; ++i) {\n v0 = a0[i];\n v1 = a1[i];\n if (v0 instanceof Array && v1 instanceof Array) {\n if (!helpers.arrayEquals(v0, v1)) {\n return false;\n }\n } else if (v0 !== v1) {\n // NOTE: two different object instances will never be equal: {x:20} != {x:20}\n return false;\n }\n }\n return true;\n },\n /**\r\n * Returns a deep copy of `source` without keeping references on objects and arrays.\r\n * @param {*} source - The value to clone.\r\n * @returns {*}\r\n */\n clone: function (source) {\n if (helpers.isArray(source)) {\n return source.map(helpers.clone);\n }\n if (helpers.isObject(source)) {\n var target = Object.create(source);\n var keys = Object.keys(source);\n var klen = keys.length;\n var k = 0;\n for (; k < klen; ++k) {\n target[keys[k]] = helpers.clone(source[keys[k]]);\n }\n return target;\n }\n return source;\n },\n /**\r\n * The default merger when Chart.helpers.merge is called without merger option.\r\n * Note(SB): also used by mergeConfig and mergeScaleConfig as fallback.\r\n * @private\r\n */\n _merger: function (key, target, source, options) {\n if (!isValidKey(key)) {\n // We want to ensure we do not copy prototypes over\n // as this can pollute global namespaces\n return;\n }\n var tval = target[key];\n var sval = source[key];\n if (helpers.isObject(tval) && helpers.isObject(sval)) {\n helpers.merge(tval, sval, options);\n } else {\n target[key] = helpers.clone(sval);\n }\n },\n /**\r\n * Merges source[key] in target[key] only if target[key] is undefined.\r\n * @private\r\n */\n _mergerIf: function (key, target, source) {\n if (!isValidKey(key)) {\n // We want to ensure we do not copy prototypes over\n // as this can pollute global namespaces\n return;\n }\n var tval = target[key];\n var sval = source[key];\n if (helpers.isObject(tval) && helpers.isObject(sval)) {\n helpers.mergeIf(tval, sval);\n } else if (!target.hasOwnProperty(key)) {\n target[key] = helpers.clone(sval);\n }\n },\n /**\r\n * Recursively deep copies `source` properties into `target` with the given `options`.\r\n * IMPORTANT: `target` is not cloned and will be updated with `source` properties.\r\n * @param {object} target - The target object in which all sources are merged into.\r\n * @param {object|object[]} source - Object(s) to merge into `target`.\r\n * @param {object} [options] - Merging options:\r\n * @param {function} [options.merger] - The merge method (key, target, source, options)\r\n * @returns {object} The `target` object.\r\n */\n merge: function (target, source, options) {\n var sources = helpers.isArray(source) ? source : [source];\n var ilen = sources.length;\n var merge, i, keys, klen, k;\n if (!helpers.isObject(target)) {\n return target;\n }\n options = options || {};\n merge = options.merger || helpers._merger;\n for (i = 0; i < ilen; ++i) {\n source = sources[i];\n if (!helpers.isObject(source)) {\n continue;\n }\n keys = Object.keys(source);\n for (k = 0, klen = keys.length; k < klen; ++k) {\n merge(keys[k], target, source, options);\n }\n }\n return target;\n },\n /**\r\n * Recursively deep copies `source` properties into `target` *only* if not defined in target.\r\n * IMPORTANT: `target` is not cloned and will be updated with `source` properties.\r\n * @param {object} target - The target object in which all sources are merged into.\r\n * @param {object|object[]} source - Object(s) to merge into `target`.\r\n * @returns {object} The `target` object.\r\n */\n mergeIf: function (target, source) {\n return helpers.merge(target, source, {\n merger: helpers._mergerIf\n });\n },\n /**\r\n * Applies the contents of two or more objects together into the first object.\r\n * @param {object} target - The target object in which all objects are merged into.\r\n * @param {object} arg1 - Object containing additional properties to merge in target.\r\n * @param {object} argN - Additional objects containing properties to merge in target.\r\n * @returns {object} The `target` object.\r\n */\n extend: Object.assign || function (target) {\n return helpers.merge(target, [].slice.call(arguments, 1), {\n merger: function (key, dst, src) {\n dst[key] = src[key];\n }\n });\n },\n /**\r\n * Basic javascript inheritance based on the model created in Backbone.js\r\n */\n inherits: function (extensions) {\n var me = this;\n var ChartElement = extensions && extensions.hasOwnProperty('constructor') ? extensions.constructor : function () {\n return me.apply(this, arguments);\n };\n var Surrogate = function () {\n this.constructor = ChartElement;\n };\n Surrogate.prototype = me.prototype;\n ChartElement.prototype = new Surrogate();\n ChartElement.extend = helpers.inherits;\n if (extensions) {\n helpers.extend(ChartElement.prototype, extensions);\n }\n ChartElement.__super__ = me.prototype;\n return ChartElement;\n },\n _deprecated: function (scope, value, previous, current) {\n if (value !== undefined) {\n console.warn(scope + ': \"' + previous + '\" is deprecated. Please use \"' + current + '\" instead');\n }\n }\n };\n var helpers_core = helpers;\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.callback instead.\r\n * @function Chart.helpers.callCallback\r\n * @deprecated since version 2.6.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers.callCallback = helpers.callback;\n\n /**\r\n * Provided for backward compatibility, use Array.prototype.indexOf instead.\r\n * Array.prototype.indexOf compatibility: Chrome, Opera, Safari, FF1.5+, IE9+\r\n * @function Chart.helpers.indexOf\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers.indexOf = function (array, item, fromIndex) {\n return Array.prototype.indexOf.call(array, item, fromIndex);\n };\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.valueOrDefault instead.\r\n * @function Chart.helpers.getValueOrDefault\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers.getValueOrDefault = helpers.valueOrDefault;\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.valueAtIndexOrDefault instead.\r\n * @function Chart.helpers.getValueAtIndexOrDefault\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers.getValueAtIndexOrDefault = helpers.valueAtIndexOrDefault;\n\n /**\r\n * Easing functions adapted from Robert Penner's easing equations.\r\n * @namespace Chart.helpers.easingEffects\r\n * @see http://www.robertpenner.com/easing/\r\n */\n var effects = {\n linear: function (t) {\n return t;\n },\n easeInQuad: function (t) {\n return t * t;\n },\n easeOutQuad: function (t) {\n return -t * (t - 2);\n },\n easeInOutQuad: function (t) {\n if ((t /= 0.5) < 1) {\n return 0.5 * t * t;\n }\n return -0.5 * (--t * (t - 2) - 1);\n },\n easeInCubic: function (t) {\n return t * t * t;\n },\n easeOutCubic: function (t) {\n return (t = t - 1) * t * t + 1;\n },\n easeInOutCubic: function (t) {\n if ((t /= 0.5) < 1) {\n return 0.5 * t * t * t;\n }\n return 0.5 * ((t -= 2) * t * t + 2);\n },\n easeInQuart: function (t) {\n return t * t * t * t;\n },\n easeOutQuart: function (t) {\n return -((t = t - 1) * t * t * t - 1);\n },\n easeInOutQuart: function (t) {\n if ((t /= 0.5) < 1) {\n return 0.5 * t * t * t * t;\n }\n return -0.5 * ((t -= 2) * t * t * t - 2);\n },\n easeInQuint: function (t) {\n return t * t * t * t * t;\n },\n easeOutQuint: function (t) {\n return (t = t - 1) * t * t * t * t + 1;\n },\n easeInOutQuint: function (t) {\n if ((t /= 0.5) < 1) {\n return 0.5 * t * t * t * t * t;\n }\n return 0.5 * ((t -= 2) * t * t * t * t + 2);\n },\n easeInSine: function (t) {\n return -Math.cos(t * (Math.PI / 2)) + 1;\n },\n easeOutSine: function (t) {\n return Math.sin(t * (Math.PI / 2));\n },\n easeInOutSine: function (t) {\n return -0.5 * (Math.cos(Math.PI * t) - 1);\n },\n easeInExpo: function (t) {\n return t === 0 ? 0 : Math.pow(2, 10 * (t - 1));\n },\n easeOutExpo: function (t) {\n return t === 1 ? 1 : -Math.pow(2, -10 * t) + 1;\n },\n easeInOutExpo: function (t) {\n if (t === 0) {\n return 0;\n }\n if (t === 1) {\n return 1;\n }\n if ((t /= 0.5) < 1) {\n return 0.5 * Math.pow(2, 10 * (t - 1));\n }\n return 0.5 * (-Math.pow(2, -10 * --t) + 2);\n },\n easeInCirc: function (t) {\n if (t >= 1) {\n return t;\n }\n return -(Math.sqrt(1 - t * t) - 1);\n },\n easeOutCirc: function (t) {\n return Math.sqrt(1 - (t = t - 1) * t);\n },\n easeInOutCirc: function (t) {\n if ((t /= 0.5) < 1) {\n return -0.5 * (Math.sqrt(1 - t * t) - 1);\n }\n return 0.5 * (Math.sqrt(1 - (t -= 2) * t) + 1);\n },\n easeInElastic: function (t) {\n var s = 1.70158;\n var p = 0;\n var a = 1;\n if (t === 0) {\n return 0;\n }\n if (t === 1) {\n return 1;\n }\n if (!p) {\n p = 0.3;\n }\n if (a < 1) {\n a = 1;\n s = p / 4;\n } else {\n s = p / (2 * Math.PI) * Math.asin(1 / a);\n }\n return -(a * Math.pow(2, 10 * (t -= 1)) * Math.sin((t - s) * (2 * Math.PI) / p));\n },\n easeOutElastic: function (t) {\n var s = 1.70158;\n var p = 0;\n var a = 1;\n if (t === 0) {\n return 0;\n }\n if (t === 1) {\n return 1;\n }\n if (!p) {\n p = 0.3;\n }\n if (a < 1) {\n a = 1;\n s = p / 4;\n } else {\n s = p / (2 * Math.PI) * Math.asin(1 / a);\n }\n return a * Math.pow(2, -10 * t) * Math.sin((t - s) * (2 * Math.PI) / p) + 1;\n },\n easeInOutElastic: function (t) {\n var s = 1.70158;\n var p = 0;\n var a = 1;\n if (t === 0) {\n return 0;\n }\n if ((t /= 0.5) === 2) {\n return 1;\n }\n if (!p) {\n p = 0.45;\n }\n if (a < 1) {\n a = 1;\n s = p / 4;\n } else {\n s = p / (2 * Math.PI) * Math.asin(1 / a);\n }\n if (t < 1) {\n return -0.5 * (a * Math.pow(2, 10 * (t -= 1)) * Math.sin((t - s) * (2 * Math.PI) / p));\n }\n return a * Math.pow(2, -10 * (t -= 1)) * Math.sin((t - s) * (2 * Math.PI) / p) * 0.5 + 1;\n },\n easeInBack: function (t) {\n var s = 1.70158;\n return t * t * ((s + 1) * t - s);\n },\n easeOutBack: function (t) {\n var s = 1.70158;\n return (t = t - 1) * t * ((s + 1) * t + s) + 1;\n },\n easeInOutBack: function (t) {\n var s = 1.70158;\n if ((t /= 0.5) < 1) {\n return 0.5 * (t * t * (((s *= 1.525) + 1) * t - s));\n }\n return 0.5 * ((t -= 2) * t * (((s *= 1.525) + 1) * t + s) + 2);\n },\n easeInBounce: function (t) {\n return 1 - effects.easeOutBounce(1 - t);\n },\n easeOutBounce: function (t) {\n if (t < 1 / 2.75) {\n return 7.5625 * t * t;\n }\n if (t < 2 / 2.75) {\n return 7.5625 * (t -= 1.5 / 2.75) * t + 0.75;\n }\n if (t < 2.5 / 2.75) {\n return 7.5625 * (t -= 2.25 / 2.75) * t + 0.9375;\n }\n return 7.5625 * (t -= 2.625 / 2.75) * t + 0.984375;\n },\n easeInOutBounce: function (t) {\n if (t < 0.5) {\n return effects.easeInBounce(t * 2) * 0.5;\n }\n return effects.easeOutBounce(t * 2 - 1) * 0.5 + 0.5;\n }\n };\n var helpers_easing = {\n effects: effects\n };\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.easing.effects instead.\r\n * @function Chart.helpers.easingEffects\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers_core.easingEffects = effects;\n var PI = Math.PI;\n var RAD_PER_DEG = PI / 180;\n var DOUBLE_PI = PI * 2;\n var HALF_PI = PI / 2;\n var QUARTER_PI = PI / 4;\n var TWO_THIRDS_PI = PI * 2 / 3;\n\n /**\r\n * @namespace Chart.helpers.canvas\r\n */\n var exports$1 = {\n /**\r\n * Clears the entire canvas associated to the given `chart`.\r\n * @param {Chart} chart - The chart for which to clear the canvas.\r\n */\n clear: function (chart) {\n chart.ctx.clearRect(0, 0, chart.width, chart.height);\n },\n /**\r\n * Creates a \"path\" for a rectangle with rounded corners at position (x, y) with a\r\n * given size (width, height) and the same `radius` for all corners.\r\n * @param {CanvasRenderingContext2D} ctx - The canvas 2D Context.\r\n * @param {number} x - The x axis of the coordinate for the rectangle starting point.\r\n * @param {number} y - The y axis of the coordinate for the rectangle starting point.\r\n * @param {number} width - The rectangle's width.\r\n * @param {number} height - The rectangle's height.\r\n * @param {number} radius - The rounded amount (in pixels) for the four corners.\r\n * @todo handle `radius` as top-left, top-right, bottom-right, bottom-left array/object?\r\n */\n roundedRect: function (ctx, x, y, width, height, radius) {\n if (radius) {\n var r = Math.min(radius, height / 2, width / 2);\n var left = x + r;\n var top = y + r;\n var right = x + width - r;\n var bottom = y + height - r;\n ctx.moveTo(x, top);\n if (left < right && top < bottom) {\n ctx.arc(left, top, r, -PI, -HALF_PI);\n ctx.arc(right, top, r, -HALF_PI, 0);\n ctx.arc(right, bottom, r, 0, HALF_PI);\n ctx.arc(left, bottom, r, HALF_PI, PI);\n } else if (left < right) {\n ctx.moveTo(left, y);\n ctx.arc(right, top, r, -HALF_PI, HALF_PI);\n ctx.arc(left, top, r, HALF_PI, PI + HALF_PI);\n } else if (top < bottom) {\n ctx.arc(left, top, r, -PI, 0);\n ctx.arc(left, bottom, r, 0, PI);\n } else {\n ctx.arc(left, top, r, -PI, PI);\n }\n ctx.closePath();\n ctx.moveTo(x, y);\n } else {\n ctx.rect(x, y, width, height);\n }\n },\n drawPoint: function (ctx, style, radius, x, y, rotation) {\n var type, xOffset, yOffset, size, cornerRadius;\n var rad = (rotation || 0) * RAD_PER_DEG;\n if (style && typeof style === 'object') {\n type = style.toString();\n if (type === '[object HTMLImageElement]' || type === '[object HTMLCanvasElement]') {\n ctx.save();\n ctx.translate(x, y);\n ctx.rotate(rad);\n ctx.drawImage(style, -style.width / 2, -style.height / 2, style.width, style.height);\n ctx.restore();\n return;\n }\n }\n if (isNaN(radius) || radius <= 0) {\n return;\n }\n ctx.beginPath();\n switch (style) {\n // Default includes circle\n default:\n ctx.arc(x, y, radius, 0, DOUBLE_PI);\n ctx.closePath();\n break;\n case 'triangle':\n ctx.moveTo(x + Math.sin(rad) * radius, y - Math.cos(rad) * radius);\n rad += TWO_THIRDS_PI;\n ctx.lineTo(x + Math.sin(rad) * radius, y - Math.cos(rad) * radius);\n rad += TWO_THIRDS_PI;\n ctx.lineTo(x + Math.sin(rad) * radius, y - Math.cos(rad) * radius);\n ctx.closePath();\n break;\n case 'rectRounded':\n // NOTE: the rounded rect implementation changed to use `arc` instead of\n // `quadraticCurveTo` since it generates better results when rect is\n // almost a circle. 0.516 (instead of 0.5) produces results with visually\n // closer proportion to the previous impl and it is inscribed in the\n // circle with `radius`. For more details, see the following PRs:\n // https://github.com/chartjs/Chart.js/issues/5597\n // https://github.com/chartjs/Chart.js/issues/5858\n cornerRadius = radius * 0.516;\n size = radius - cornerRadius;\n xOffset = Math.cos(rad + QUARTER_PI) * size;\n yOffset = Math.sin(rad + QUARTER_PI) * size;\n ctx.arc(x - xOffset, y - yOffset, cornerRadius, rad - PI, rad - HALF_PI);\n ctx.arc(x + yOffset, y - xOffset, cornerRadius, rad - HALF_PI, rad);\n ctx.arc(x + xOffset, y + yOffset, cornerRadius, rad, rad + HALF_PI);\n ctx.arc(x - yOffset, y + xOffset, cornerRadius, rad + HALF_PI, rad + PI);\n ctx.closePath();\n break;\n case 'rect':\n if (!rotation) {\n size = Math.SQRT1_2 * radius;\n ctx.rect(x - size, y - size, 2 * size, 2 * size);\n break;\n }\n rad += QUARTER_PI;\n /* falls through */\n case 'rectRot':\n xOffset = Math.cos(rad) * radius;\n yOffset = Math.sin(rad) * radius;\n ctx.moveTo(x - xOffset, y - yOffset);\n ctx.lineTo(x + yOffset, y - xOffset);\n ctx.lineTo(x + xOffset, y + yOffset);\n ctx.lineTo(x - yOffset, y + xOffset);\n ctx.closePath();\n break;\n case 'crossRot':\n rad += QUARTER_PI;\n /* falls through */\n case 'cross':\n xOffset = Math.cos(rad) * radius;\n yOffset = Math.sin(rad) * radius;\n ctx.moveTo(x - xOffset, y - yOffset);\n ctx.lineTo(x + xOffset, y + yOffset);\n ctx.moveTo(x + yOffset, y - xOffset);\n ctx.lineTo(x - yOffset, y + xOffset);\n break;\n case 'star':\n xOffset = Math.cos(rad) * radius;\n yOffset = Math.sin(rad) * radius;\n ctx.moveTo(x - xOffset, y - yOffset);\n ctx.lineTo(x + xOffset, y + yOffset);\n ctx.moveTo(x + yOffset, y - xOffset);\n ctx.lineTo(x - yOffset, y + xOffset);\n rad += QUARTER_PI;\n xOffset = Math.cos(rad) * radius;\n yOffset = Math.sin(rad) * radius;\n ctx.moveTo(x - xOffset, y - yOffset);\n ctx.lineTo(x + xOffset, y + yOffset);\n ctx.moveTo(x + yOffset, y - xOffset);\n ctx.lineTo(x - yOffset, y + xOffset);\n break;\n case 'line':\n xOffset = Math.cos(rad) * radius;\n yOffset = Math.sin(rad) * radius;\n ctx.moveTo(x - xOffset, y - yOffset);\n ctx.lineTo(x + xOffset, y + yOffset);\n break;\n case 'dash':\n ctx.moveTo(x, y);\n ctx.lineTo(x + Math.cos(rad) * radius, y + Math.sin(rad) * radius);\n break;\n }\n ctx.fill();\n ctx.stroke();\n },\n /**\r\n * Returns true if the point is inside the rectangle\r\n * @param {object} point - The point to test\r\n * @param {object} area - The rectangle\r\n * @returns {boolean}\r\n * @private\r\n */\n _isPointInArea: function (point, area) {\n var epsilon = 1e-6; // 1e-6 is margin in pixels for accumulated error.\n\n return point.x > area.left - epsilon && point.x < area.right + epsilon && point.y > area.top - epsilon && point.y < area.bottom + epsilon;\n },\n clipArea: function (ctx, area) {\n ctx.save();\n ctx.beginPath();\n ctx.rect(area.left, area.top, area.right - area.left, area.bottom - area.top);\n ctx.clip();\n },\n unclipArea: function (ctx) {\n ctx.restore();\n },\n lineTo: function (ctx, previous, target, flip) {\n var stepped = target.steppedLine;\n if (stepped) {\n if (stepped === 'middle') {\n var midpoint = (previous.x + target.x) / 2.0;\n ctx.lineTo(midpoint, flip ? target.y : previous.y);\n ctx.lineTo(midpoint, flip ? previous.y : target.y);\n } else if (stepped === 'after' && !flip || stepped !== 'after' && flip) {\n ctx.lineTo(previous.x, target.y);\n } else {\n ctx.lineTo(target.x, previous.y);\n }\n ctx.lineTo(target.x, target.y);\n return;\n }\n if (!target.tension) {\n ctx.lineTo(target.x, target.y);\n return;\n }\n ctx.bezierCurveTo(flip ? previous.controlPointPreviousX : previous.controlPointNextX, flip ? previous.controlPointPreviousY : previous.controlPointNextY, flip ? target.controlPointNextX : target.controlPointPreviousX, flip ? target.controlPointNextY : target.controlPointPreviousY, target.x, target.y);\n }\n };\n var helpers_canvas = exports$1;\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.canvas.clear instead.\r\n * @namespace Chart.helpers.clear\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers_core.clear = exports$1.clear;\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.canvas.roundedRect instead.\r\n * @namespace Chart.helpers.drawRoundedRectangle\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers_core.drawRoundedRectangle = function (ctx) {\n ctx.beginPath();\n exports$1.roundedRect.apply(exports$1, arguments);\n };\n var defaults = {\n /**\r\n * @private\r\n */\n _set: function (scope, values) {\n return helpers_core.merge(this[scope] || (this[scope] = {}), values);\n }\n };\n\n // TODO(v3): remove 'global' from namespace. all default are global and\n // there's inconsistency around which options are under 'global'\n defaults._set('global', {\n defaultColor: 'rgba(0,0,0,0.1)',\n defaultFontColor: '#666',\n defaultFontFamily: \"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif\",\n defaultFontSize: 12,\n defaultFontStyle: 'normal',\n defaultLineHeight: 1.2,\n showLines: true\n });\n var core_defaults = defaults;\n var valueOrDefault = helpers_core.valueOrDefault;\n\n /**\r\n * Converts the given font object into a CSS font string.\r\n * @param {object} font - A font object.\r\n * @return {string} The CSS font string. See https://developer.mozilla.org/en-US/docs/Web/CSS/font\r\n * @private\r\n */\n function toFontString(font) {\n if (!font || helpers_core.isNullOrUndef(font.size) || helpers_core.isNullOrUndef(font.family)) {\n return null;\n }\n return (font.style ? font.style + ' ' : '') + (font.weight ? font.weight + ' ' : '') + font.size + 'px ' + font.family;\n }\n\n /**\r\n * @alias Chart.helpers.options\r\n * @namespace\r\n */\n var helpers_options = {\n /**\r\n * Converts the given line height `value` in pixels for a specific font `size`.\r\n * @param {number|string} value - The lineHeight to parse (eg. 1.6, '14px', '75%', '1.6em').\r\n * @param {number} size - The font size (in pixels) used to resolve relative `value`.\r\n * @returns {number} The effective line height in pixels (size * 1.2 if value is invalid).\r\n * @see https://developer.mozilla.org/en-US/docs/Web/CSS/line-height\r\n * @since 2.7.0\r\n */\n toLineHeight: function (value, size) {\n var matches = ('' + value).match(/^(normal|(\\d+(?:\\.\\d+)?)(px|em|%)?)$/);\n if (!matches || matches[1] === 'normal') {\n return size * 1.2;\n }\n value = +matches[2];\n switch (matches[3]) {\n case 'px':\n return value;\n case '%':\n value /= 100;\n break;\n }\n return size * value;\n },\n /**\r\n * Converts the given value into a padding object with pre-computed width/height.\r\n * @param {number|object} value - If a number, set the value to all TRBL component,\r\n * else, if and object, use defined properties and sets undefined ones to 0.\r\n * @returns {object} The padding values (top, right, bottom, left, width, height)\r\n * @since 2.7.0\r\n */\n toPadding: function (value) {\n var t, r, b, l;\n if (helpers_core.isObject(value)) {\n t = +value.top || 0;\n r = +value.right || 0;\n b = +value.bottom || 0;\n l = +value.left || 0;\n } else {\n t = r = b = l = +value || 0;\n }\n return {\n top: t,\n right: r,\n bottom: b,\n left: l,\n height: t + b,\n width: l + r\n };\n },\n /**\r\n * Parses font options and returns the font object.\r\n * @param {object} options - A object that contains font options to be parsed.\r\n * @return {object} The font object.\r\n * @todo Support font.* options and renamed to toFont().\r\n * @private\r\n */\n _parseFont: function (options) {\n var globalDefaults = core_defaults.global;\n var size = valueOrDefault(options.fontSize, globalDefaults.defaultFontSize);\n var font = {\n family: valueOrDefault(options.fontFamily, globalDefaults.defaultFontFamily),\n lineHeight: helpers_core.options.toLineHeight(valueOrDefault(options.lineHeight, globalDefaults.defaultLineHeight), size),\n size: size,\n style: valueOrDefault(options.fontStyle, globalDefaults.defaultFontStyle),\n weight: null,\n string: ''\n };\n font.string = toFontString(font);\n return font;\n },\n /**\r\n * Evaluates the given `inputs` sequentially and returns the first defined value.\r\n * @param {Array} inputs - An array of values, falling back to the last value.\r\n * @param {object} [context] - If defined and the current value is a function, the value\r\n * is called with `context` as first argument and the result becomes the new input.\r\n * @param {number} [index] - If defined and the current value is an array, the value\r\n * at `index` become the new input.\r\n * @param {object} [info] - object to return information about resolution in\r\n * @param {boolean} [info.cacheable] - Will be set to `false` if option is not cacheable.\r\n * @since 2.7.0\r\n */\n resolve: function (inputs, context, index, info) {\n var cacheable = true;\n var i, ilen, value;\n for (i = 0, ilen = inputs.length; i < ilen; ++i) {\n value = inputs[i];\n if (value === undefined) {\n continue;\n }\n if (context !== undefined && typeof value === 'function') {\n value = value(context);\n cacheable = false;\n }\n if (index !== undefined && helpers_core.isArray(value)) {\n value = value[index];\n cacheable = false;\n }\n if (value !== undefined) {\n if (info && !cacheable) {\n info.cacheable = false;\n }\n return value;\n }\n }\n }\n };\n\n /**\r\n * @alias Chart.helpers.math\r\n * @namespace\r\n */\n var exports$2 = {\n /**\r\n * Returns an array of factors sorted from 1 to sqrt(value)\r\n * @private\r\n */\n _factorize: function (value) {\n var result = [];\n var sqrt = Math.sqrt(value);\n var i;\n for (i = 1; i < sqrt; i++) {\n if (value % i === 0) {\n result.push(i);\n result.push(value / i);\n }\n }\n if (sqrt === (sqrt | 0)) {\n // if value is a square number\n result.push(sqrt);\n }\n result.sort(function (a, b) {\n return a - b;\n }).pop();\n return result;\n },\n log10: Math.log10 || function (x) {\n var exponent = Math.log(x) * Math.LOG10E; // Math.LOG10E = 1 / Math.LN10.\n // Check for whole powers of 10,\n // which due to floating point rounding error should be corrected.\n var powerOf10 = Math.round(exponent);\n var isPowerOf10 = x === Math.pow(10, powerOf10);\n return isPowerOf10 ? powerOf10 : exponent;\n }\n };\n var helpers_math = exports$2;\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.math.log10 instead.\r\n * @namespace Chart.helpers.log10\r\n * @deprecated since version 2.9.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers_core.log10 = exports$2.log10;\n var getRtlAdapter = function (rectX, width) {\n return {\n x: function (x) {\n return rectX + rectX + width - x;\n },\n setWidth: function (w) {\n width = w;\n },\n textAlign: function (align) {\n if (align === 'center') {\n return align;\n }\n return align === 'right' ? 'left' : 'right';\n },\n xPlus: function (x, value) {\n return x - value;\n },\n leftForLtr: function (x, itemWidth) {\n return x - itemWidth;\n }\n };\n };\n var getLtrAdapter = function () {\n return {\n x: function (x) {\n return x;\n },\n setWidth: function (w) {// eslint-disable-line no-unused-vars\n },\n textAlign: function (align) {\n return align;\n },\n xPlus: function (x, value) {\n return x + value;\n },\n leftForLtr: function (x, _itemWidth) {\n // eslint-disable-line no-unused-vars\n return x;\n }\n };\n };\n var getAdapter = function (rtl, rectX, width) {\n return rtl ? getRtlAdapter(rectX, width) : getLtrAdapter();\n };\n var overrideTextDirection = function (ctx, direction) {\n var style, original;\n if (direction === 'ltr' || direction === 'rtl') {\n style = ctx.canvas.style;\n original = [style.getPropertyValue('direction'), style.getPropertyPriority('direction')];\n style.setProperty('direction', direction, 'important');\n ctx.prevTextDirection = original;\n }\n };\n var restoreTextDirection = function (ctx) {\n var original = ctx.prevTextDirection;\n if (original !== undefined) {\n delete ctx.prevTextDirection;\n ctx.canvas.style.setProperty('direction', original[0], original[1]);\n }\n };\n var helpers_rtl = {\n getRtlAdapter: getAdapter,\n overrideTextDirection: overrideTextDirection,\n restoreTextDirection: restoreTextDirection\n };\n var helpers$1 = helpers_core;\n var easing = helpers_easing;\n var canvas = helpers_canvas;\n var options = helpers_options;\n var math = helpers_math;\n var rtl = helpers_rtl;\n helpers$1.easing = easing;\n helpers$1.canvas = canvas;\n helpers$1.options = options;\n helpers$1.math = math;\n helpers$1.rtl = rtl;\n function interpolate(start, view, model, ease) {\n var keys = Object.keys(model);\n var i, ilen, key, actual, origin, target, type, c0, c1;\n for (i = 0, ilen = keys.length; i < ilen; ++i) {\n key = keys[i];\n target = model[key];\n\n // if a value is added to the model after pivot() has been called, the view\n // doesn't contain it, so let's initialize the view to the target value.\n if (!view.hasOwnProperty(key)) {\n view[key] = target;\n }\n actual = view[key];\n if (actual === target || key[0] === '_') {\n continue;\n }\n if (!start.hasOwnProperty(key)) {\n start[key] = actual;\n }\n origin = start[key];\n type = typeof target;\n if (type === typeof origin) {\n if (type === 'string') {\n c0 = chartjsColor(origin);\n if (c0.valid) {\n c1 = chartjsColor(target);\n if (c1.valid) {\n view[key] = c1.mix(c0, ease).rgbString();\n continue;\n }\n }\n } else if (helpers$1.isFinite(origin) && helpers$1.isFinite(target)) {\n view[key] = origin + (target - origin) * ease;\n continue;\n }\n }\n view[key] = target;\n }\n }\n var Element = function (configuration) {\n helpers$1.extend(this, configuration);\n this.initialize.apply(this, arguments);\n };\n helpers$1.extend(Element.prototype, {\n _type: undefined,\n initialize: function () {\n this.hidden = false;\n },\n pivot: function () {\n var me = this;\n if (!me._view) {\n me._view = helpers$1.extend({}, me._model);\n }\n me._start = {};\n return me;\n },\n transition: function (ease) {\n var me = this;\n var model = me._model;\n var start = me._start;\n var view = me._view;\n\n // No animation -> No Transition\n if (!model || ease === 1) {\n me._view = helpers$1.extend({}, model);\n me._start = null;\n return me;\n }\n if (!view) {\n view = me._view = {};\n }\n if (!start) {\n start = me._start = {};\n }\n interpolate(start, view, model, ease);\n return me;\n },\n tooltipPosition: function () {\n return {\n x: this._model.x,\n y: this._model.y\n };\n },\n hasValue: function () {\n return helpers$1.isNumber(this._model.x) && helpers$1.isNumber(this._model.y);\n }\n });\n Element.extend = helpers$1.inherits;\n var core_element = Element;\n var exports$3 = core_element.extend({\n chart: null,\n // the animation associated chart instance\n currentStep: 0,\n // the current animation step\n numSteps: 60,\n // default number of steps\n easing: '',\n // the easing to use for this animation\n render: null,\n // render function used by the animation service\n\n onAnimationProgress: null,\n // user specified callback to fire on each step of the animation\n onAnimationComplete: null // user specified callback to fire when the animation finishes\n });\n var core_animation = exports$3;\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, use Chart.Animation instead\r\n * @prop Chart.Animation#animationObject\r\n * @deprecated since version 2.6.0\r\n * @todo remove at version 3\r\n */\n Object.defineProperty(exports$3.prototype, 'animationObject', {\n get: function () {\n return this;\n }\n });\n\n /**\r\n * Provided for backward compatibility, use Chart.Animation#chart instead\r\n * @prop Chart.Animation#chartInstance\r\n * @deprecated since version 2.6.0\r\n * @todo remove at version 3\r\n */\n Object.defineProperty(exports$3.prototype, 'chartInstance', {\n get: function () {\n return this.chart;\n },\n set: function (value) {\n this.chart = value;\n }\n });\n core_defaults._set('global', {\n animation: {\n duration: 1000,\n easing: 'easeOutQuart',\n onProgress: helpers$1.noop,\n onComplete: helpers$1.noop\n }\n });\n var core_animations = {\n animations: [],\n request: null,\n /**\r\n * @param {Chart} chart - The chart to animate.\r\n * @param {Chart.Animation} animation - The animation that we will animate.\r\n * @param {number} duration - The animation duration in ms.\r\n * @param {boolean} lazy - if true, the chart is not marked as animating to enable more responsive interactions\r\n */\n addAnimation: function (chart, animation, duration, lazy) {\n var animations = this.animations;\n var i, ilen;\n animation.chart = chart;\n animation.startTime = Date.now();\n animation.duration = duration;\n if (!lazy) {\n chart.animating = true;\n }\n for (i = 0, ilen = animations.length; i < ilen; ++i) {\n if (animations[i].chart === chart) {\n animations[i] = animation;\n return;\n }\n }\n animations.push(animation);\n\n // If there are no animations queued, manually kickstart a digest, for lack of a better word\n if (animations.length === 1) {\n this.requestAnimationFrame();\n }\n },\n cancelAnimation: function (chart) {\n var index = helpers$1.findIndex(this.animations, function (animation) {\n return animation.chart === chart;\n });\n if (index !== -1) {\n this.animations.splice(index, 1);\n chart.animating = false;\n }\n },\n requestAnimationFrame: function () {\n var me = this;\n if (me.request === null) {\n // Skip animation frame requests until the active one is executed.\n // This can happen when processing mouse events, e.g. 'mousemove'\n // and 'mouseout' events will trigger multiple renders.\n me.request = helpers$1.requestAnimFrame.call(window, function () {\n me.request = null;\n me.startDigest();\n });\n }\n },\n /**\r\n * @private\r\n */\n startDigest: function () {\n var me = this;\n me.advance();\n\n // Do we have more stuff to animate?\n if (me.animations.length > 0) {\n me.requestAnimationFrame();\n }\n },\n /**\r\n * @private\r\n */\n advance: function () {\n var animations = this.animations;\n var animation, chart, numSteps, nextStep;\n var i = 0;\n\n // 1 animation per chart, so we are looping charts here\n while (i < animations.length) {\n animation = animations[i];\n chart = animation.chart;\n numSteps = animation.numSteps;\n\n // Make sure that currentStep starts at 1\n // https://github.com/chartjs/Chart.js/issues/6104\n nextStep = Math.floor((Date.now() - animation.startTime) / animation.duration * numSteps) + 1;\n animation.currentStep = Math.min(nextStep, numSteps);\n helpers$1.callback(animation.render, [chart, animation], chart);\n helpers$1.callback(animation.onAnimationProgress, [animation], chart);\n if (animation.currentStep >= numSteps) {\n helpers$1.callback(animation.onAnimationComplete, [animation], chart);\n chart.animating = false;\n animations.splice(i, 1);\n } else {\n ++i;\n }\n }\n }\n };\n var resolve = helpers$1.options.resolve;\n var arrayEvents = ['push', 'pop', 'shift', 'splice', 'unshift'];\n\n /**\r\n * Hooks the array methods that add or remove values ('push', pop', 'shift', 'splice',\r\n * 'unshift') and notify the listener AFTER the array has been altered. Listeners are\r\n * called on the 'onData*' callbacks (e.g. onDataPush, etc.) with same arguments.\r\n */\n function listenArrayEvents(array, listener) {\n if (array._chartjs) {\n array._chartjs.listeners.push(listener);\n return;\n }\n Object.defineProperty(array, '_chartjs', {\n configurable: true,\n enumerable: false,\n value: {\n listeners: [listener]\n }\n });\n arrayEvents.forEach(function (key) {\n var method = 'onData' + key.charAt(0).toUpperCase() + key.slice(1);\n var base = array[key];\n Object.defineProperty(array, key, {\n configurable: true,\n enumerable: false,\n value: function () {\n var args = Array.prototype.slice.call(arguments);\n var res = base.apply(this, args);\n helpers$1.each(array._chartjs.listeners, function (object) {\n if (typeof object[method] === 'function') {\n object[method].apply(object, args);\n }\n });\n return res;\n }\n });\n });\n }\n\n /**\r\n * Removes the given array event listener and cleanup extra attached properties (such as\r\n * the _chartjs stub and overridden methods) if array doesn't have any more listeners.\r\n */\n function unlistenArrayEvents(array, listener) {\n var stub = array._chartjs;\n if (!stub) {\n return;\n }\n var listeners = stub.listeners;\n var index = listeners.indexOf(listener);\n if (index !== -1) {\n listeners.splice(index, 1);\n }\n if (listeners.length > 0) {\n return;\n }\n arrayEvents.forEach(function (key) {\n delete array[key];\n });\n delete array._chartjs;\n }\n\n // Base class for all dataset controllers (line, bar, etc)\n var DatasetController = function (chart, datasetIndex) {\n this.initialize(chart, datasetIndex);\n };\n helpers$1.extend(DatasetController.prototype, {\n /**\r\n * Element type used to generate a meta dataset (e.g. Chart.element.Line).\r\n * @type {Chart.core.element}\r\n */\n datasetElementType: null,\n /**\r\n * Element type used to generate a meta data (e.g. Chart.element.Point).\r\n * @type {Chart.core.element}\r\n */\n dataElementType: null,\n /**\r\n * Dataset element option keys to be resolved in _resolveDatasetElementOptions.\r\n * A derived controller may override this to resolve controller-specific options.\r\n * The keys defined here are for backward compatibility for legend styles.\r\n * @private\r\n */\n _datasetElementOptions: ['backgroundColor', 'borderCapStyle', 'borderColor', 'borderDash', 'borderDashOffset', 'borderJoinStyle', 'borderWidth'],\n /**\r\n * Data element option keys to be resolved in _resolveDataElementOptions.\r\n * A derived controller may override this to resolve controller-specific options.\r\n * The keys defined here are for backward compatibility for legend styles.\r\n * @private\r\n */\n _dataElementOptions: ['backgroundColor', 'borderColor', 'borderWidth', 'pointStyle'],\n initialize: function (chart, datasetIndex) {\n var me = this;\n me.chart = chart;\n me.index = datasetIndex;\n me.linkScales();\n me.addElements();\n me._type = me.getMeta().type;\n },\n updateIndex: function (datasetIndex) {\n this.index = datasetIndex;\n },\n linkScales: function () {\n var me = this;\n var meta = me.getMeta();\n var chart = me.chart;\n var scales = chart.scales;\n var dataset = me.getDataset();\n var scalesOpts = chart.options.scales;\n if (meta.xAxisID === null || !(meta.xAxisID in scales) || dataset.xAxisID) {\n meta.xAxisID = dataset.xAxisID || scalesOpts.xAxes[0].id;\n }\n if (meta.yAxisID === null || !(meta.yAxisID in scales) || dataset.yAxisID) {\n meta.yAxisID = dataset.yAxisID || scalesOpts.yAxes[0].id;\n }\n },\n getDataset: function () {\n return this.chart.data.datasets[this.index];\n },\n getMeta: function () {\n return this.chart.getDatasetMeta(this.index);\n },\n getScaleForId: function (scaleID) {\n return this.chart.scales[scaleID];\n },\n /**\r\n * @private\r\n */\n _getValueScaleId: function () {\n return this.getMeta().yAxisID;\n },\n /**\r\n * @private\r\n */\n _getIndexScaleId: function () {\n return this.getMeta().xAxisID;\n },\n /**\r\n * @private\r\n */\n _getValueScale: function () {\n return this.getScaleForId(this._getValueScaleId());\n },\n /**\r\n * @private\r\n */\n _getIndexScale: function () {\n return this.getScaleForId(this._getIndexScaleId());\n },\n reset: function () {\n this._update(true);\n },\n /**\r\n * @private\r\n */\n destroy: function () {\n if (this._data) {\n unlistenArrayEvents(this._data, this);\n }\n },\n createMetaDataset: function () {\n var me = this;\n var type = me.datasetElementType;\n return type && new type({\n _chart: me.chart,\n _datasetIndex: me.index\n });\n },\n createMetaData: function (index) {\n var me = this;\n var type = me.dataElementType;\n return type && new type({\n _chart: me.chart,\n _datasetIndex: me.index,\n _index: index\n });\n },\n addElements: function () {\n var me = this;\n var meta = me.getMeta();\n var data = me.getDataset().data || [];\n var metaData = meta.data;\n var i, ilen;\n for (i = 0, ilen = data.length; i < ilen; ++i) {\n metaData[i] = metaData[i] || me.createMetaData(i);\n }\n meta.dataset = meta.dataset || me.createMetaDataset();\n },\n addElementAndReset: function (index) {\n var element = this.createMetaData(index);\n this.getMeta().data.splice(index, 0, element);\n this.updateElement(element, index, true);\n },\n buildOrUpdateElements: function () {\n var me = this;\n var dataset = me.getDataset();\n var data = dataset.data || (dataset.data = []);\n\n // In order to correctly handle data addition/deletion animation (an thus simulate\n // real-time charts), we need to monitor these data modifications and synchronize\n // the internal meta data accordingly.\n if (me._data !== data) {\n if (me._data) {\n // This case happens when the user replaced the data array instance.\n unlistenArrayEvents(me._data, me);\n }\n if (data && Object.isExtensible(data)) {\n listenArrayEvents(data, me);\n }\n me._data = data;\n }\n\n // Re-sync meta data in case the user replaced the data array or if we missed\n // any updates and so make sure that we handle number of datapoints changing.\n me.resyncElements();\n },\n /**\r\n * Returns the merged user-supplied and default dataset-level options\r\n * @private\r\n */\n _configure: function () {\n var me = this;\n me._config = helpers$1.merge(Object.create(null), [me.chart.options.datasets[me._type], me.getDataset()], {\n merger: function (key, target, source) {\n if (key !== '_meta' && key !== 'data') {\n helpers$1._merger(key, target, source);\n }\n }\n });\n },\n _update: function (reset) {\n var me = this;\n me._configure();\n me._cachedDataOpts = null;\n me.update(reset);\n },\n update: helpers$1.noop,\n transition: function (easingValue) {\n var meta = this.getMeta();\n var elements = meta.data || [];\n var ilen = elements.length;\n var i = 0;\n for (; i < ilen; ++i) {\n elements[i].transition(easingValue);\n }\n if (meta.dataset) {\n meta.dataset.transition(easingValue);\n }\n },\n draw: function () {\n var meta = this.getMeta();\n var elements = meta.data || [];\n var ilen = elements.length;\n var i = 0;\n if (meta.dataset) {\n meta.dataset.draw();\n }\n for (; i < ilen; ++i) {\n elements[i].draw();\n }\n },\n /**\r\n * Returns a set of predefined style properties that should be used to represent the dataset\r\n * or the data if the index is specified\r\n * @param {number} index - data index\r\n * @return {IStyleInterface} style object\r\n */\n getStyle: function (index) {\n var me = this;\n var meta = me.getMeta();\n var dataset = meta.dataset;\n var style;\n me._configure();\n if (dataset && index === undefined) {\n style = me._resolveDatasetElementOptions(dataset || {});\n } else {\n index = index || 0;\n style = me._resolveDataElementOptions(meta.data[index] || {}, index);\n }\n if (style.fill === false || style.fill === null) {\n style.backgroundColor = style.borderColor;\n }\n return style;\n },\n /**\r\n * @private\r\n */\n _resolveDatasetElementOptions: function (element, hover) {\n var me = this;\n var chart = me.chart;\n var datasetOpts = me._config;\n var custom = element.custom || {};\n var options = chart.options.elements[me.datasetElementType.prototype._type] || {};\n var elementOptions = me._datasetElementOptions;\n var values = {};\n var i, ilen, key, readKey;\n\n // Scriptable options\n var context = {\n chart: chart,\n dataset: me.getDataset(),\n datasetIndex: me.index,\n hover: hover\n };\n for (i = 0, ilen = elementOptions.length; i < ilen; ++i) {\n key = elementOptions[i];\n readKey = hover ? 'hover' + key.charAt(0).toUpperCase() + key.slice(1) : key;\n values[key] = resolve([custom[readKey], datasetOpts[readKey], options[readKey]], context);\n }\n return values;\n },\n /**\r\n * @private\r\n */\n _resolveDataElementOptions: function (element, index) {\n var me = this;\n var custom = element && element.custom;\n var cached = me._cachedDataOpts;\n if (cached && !custom) {\n return cached;\n }\n var chart = me.chart;\n var datasetOpts = me._config;\n var options = chart.options.elements[me.dataElementType.prototype._type] || {};\n var elementOptions = me._dataElementOptions;\n var values = {};\n\n // Scriptable options\n var context = {\n chart: chart,\n dataIndex: index,\n dataset: me.getDataset(),\n datasetIndex: me.index\n };\n\n // `resolve` sets cacheable to `false` if any option is indexed or scripted\n var info = {\n cacheable: !custom\n };\n var keys, i, ilen, key;\n custom = custom || {};\n if (helpers$1.isArray(elementOptions)) {\n for (i = 0, ilen = elementOptions.length; i < ilen; ++i) {\n key = elementOptions[i];\n values[key] = resolve([custom[key], datasetOpts[key], options[key]], context, index, info);\n }\n } else {\n keys = Object.keys(elementOptions);\n for (i = 0, ilen = keys.length; i < ilen; ++i) {\n key = keys[i];\n values[key] = resolve([custom[key], datasetOpts[elementOptions[key]], datasetOpts[key], options[key]], context, index, info);\n }\n }\n if (info.cacheable) {\n me._cachedDataOpts = Object.freeze(values);\n }\n return values;\n },\n removeHoverStyle: function (element) {\n helpers$1.merge(element._model, element.$previousStyle || {});\n delete element.$previousStyle;\n },\n setHoverStyle: function (element) {\n var dataset = this.chart.data.datasets[element._datasetIndex];\n var index = element._index;\n var custom = element.custom || {};\n var model = element._model;\n var getHoverColor = helpers$1.getHoverColor;\n element.$previousStyle = {\n backgroundColor: model.backgroundColor,\n borderColor: model.borderColor,\n borderWidth: model.borderWidth\n };\n model.backgroundColor = resolve([custom.hoverBackgroundColor, dataset.hoverBackgroundColor, getHoverColor(model.backgroundColor)], undefined, index);\n model.borderColor = resolve([custom.hoverBorderColor, dataset.hoverBorderColor, getHoverColor(model.borderColor)], undefined, index);\n model.borderWidth = resolve([custom.hoverBorderWidth, dataset.hoverBorderWidth, model.borderWidth], undefined, index);\n },\n /**\r\n * @private\r\n */\n _removeDatasetHoverStyle: function () {\n var element = this.getMeta().dataset;\n if (element) {\n this.removeHoverStyle(element);\n }\n },\n /**\r\n * @private\r\n */\n _setDatasetHoverStyle: function () {\n var element = this.getMeta().dataset;\n var prev = {};\n var i, ilen, key, keys, hoverOptions, model;\n if (!element) {\n return;\n }\n model = element._model;\n hoverOptions = this._resolveDatasetElementOptions(element, true);\n keys = Object.keys(hoverOptions);\n for (i = 0, ilen = keys.length; i < ilen; ++i) {\n key = keys[i];\n prev[key] = model[key];\n model[key] = hoverOptions[key];\n }\n element.$previousStyle = prev;\n },\n /**\r\n * @private\r\n */\n resyncElements: function () {\n var me = this;\n var meta = me.getMeta();\n var data = me.getDataset().data;\n var numMeta = meta.data.length;\n var numData = data.length;\n if (numData < numMeta) {\n meta.data.splice(numData, numMeta - numData);\n } else if (numData > numMeta) {\n me.insertElements(numMeta, numData - numMeta);\n }\n },\n /**\r\n * @private\r\n */\n insertElements: function (start, count) {\n for (var i = 0; i < count; ++i) {\n this.addElementAndReset(start + i);\n }\n },\n /**\r\n * @private\r\n */\n onDataPush: function () {\n var count = arguments.length;\n this.insertElements(this.getDataset().data.length - count, count);\n },\n /**\r\n * @private\r\n */\n onDataPop: function () {\n this.getMeta().data.pop();\n },\n /**\r\n * @private\r\n */\n onDataShift: function () {\n this.getMeta().data.shift();\n },\n /**\r\n * @private\r\n */\n onDataSplice: function (start, count) {\n this.getMeta().data.splice(start, count);\n this.insertElements(start, arguments.length - 2);\n },\n /**\r\n * @private\r\n */\n onDataUnshift: function () {\n this.insertElements(0, arguments.length);\n }\n });\n DatasetController.extend = helpers$1.inherits;\n var core_datasetController = DatasetController;\n var TAU = Math.PI * 2;\n core_defaults._set('global', {\n elements: {\n arc: {\n backgroundColor: core_defaults.global.defaultColor,\n borderColor: '#fff',\n borderWidth: 2,\n borderAlign: 'center'\n }\n }\n });\n function clipArc(ctx, arc) {\n var startAngle = arc.startAngle;\n var endAngle = arc.endAngle;\n var pixelMargin = arc.pixelMargin;\n var angleMargin = pixelMargin / arc.outerRadius;\n var x = arc.x;\n var y = arc.y;\n\n // Draw an inner border by cliping the arc and drawing a double-width border\n // Enlarge the clipping arc by 0.33 pixels to eliminate glitches between borders\n ctx.beginPath();\n ctx.arc(x, y, arc.outerRadius, startAngle - angleMargin, endAngle + angleMargin);\n if (arc.innerRadius > pixelMargin) {\n angleMargin = pixelMargin / arc.innerRadius;\n ctx.arc(x, y, arc.innerRadius - pixelMargin, endAngle + angleMargin, startAngle - angleMargin, true);\n } else {\n ctx.arc(x, y, pixelMargin, endAngle + Math.PI / 2, startAngle - Math.PI / 2);\n }\n ctx.closePath();\n ctx.clip();\n }\n function drawFullCircleBorders(ctx, vm, arc, inner) {\n var endAngle = arc.endAngle;\n var i;\n if (inner) {\n arc.endAngle = arc.startAngle + TAU;\n clipArc(ctx, arc);\n arc.endAngle = endAngle;\n if (arc.endAngle === arc.startAngle && arc.fullCircles) {\n arc.endAngle += TAU;\n arc.fullCircles--;\n }\n }\n ctx.beginPath();\n ctx.arc(arc.x, arc.y, arc.innerRadius, arc.startAngle + TAU, arc.startAngle, true);\n for (i = 0; i < arc.fullCircles; ++i) {\n ctx.stroke();\n }\n ctx.beginPath();\n ctx.arc(arc.x, arc.y, vm.outerRadius, arc.startAngle, arc.startAngle + TAU);\n for (i = 0; i < arc.fullCircles; ++i) {\n ctx.stroke();\n }\n }\n function drawBorder(ctx, vm, arc) {\n var inner = vm.borderAlign === 'inner';\n if (inner) {\n ctx.lineWidth = vm.borderWidth * 2;\n ctx.lineJoin = 'round';\n } else {\n ctx.lineWidth = vm.borderWidth;\n ctx.lineJoin = 'bevel';\n }\n if (arc.fullCircles) {\n drawFullCircleBorders(ctx, vm, arc, inner);\n }\n if (inner) {\n clipArc(ctx, arc);\n }\n ctx.beginPath();\n ctx.arc(arc.x, arc.y, vm.outerRadius, arc.startAngle, arc.endAngle);\n ctx.arc(arc.x, arc.y, arc.innerRadius, arc.endAngle, arc.startAngle, true);\n ctx.closePath();\n ctx.stroke();\n }\n var element_arc = core_element.extend({\n _type: 'arc',\n inLabelRange: function (mouseX) {\n var vm = this._view;\n if (vm) {\n return Math.pow(mouseX - vm.x, 2) < Math.pow(vm.radius + vm.hoverRadius, 2);\n }\n return false;\n },\n inRange: function (chartX, chartY) {\n var vm = this._view;\n if (vm) {\n var pointRelativePosition = helpers$1.getAngleFromPoint(vm, {\n x: chartX,\n y: chartY\n });\n var angle = pointRelativePosition.angle;\n var distance = pointRelativePosition.distance;\n\n // Sanitise angle range\n var startAngle = vm.startAngle;\n var endAngle = vm.endAngle;\n while (endAngle < startAngle) {\n endAngle += TAU;\n }\n while (angle > endAngle) {\n angle -= TAU;\n }\n while (angle < startAngle) {\n angle += TAU;\n }\n\n // Check if within the range of the open/close angle\n var betweenAngles = angle >= startAngle && angle <= endAngle;\n var withinRadius = distance >= vm.innerRadius && distance <= vm.outerRadius;\n return betweenAngles && withinRadius;\n }\n return false;\n },\n getCenterPoint: function () {\n var vm = this._view;\n var halfAngle = (vm.startAngle + vm.endAngle) / 2;\n var halfRadius = (vm.innerRadius + vm.outerRadius) / 2;\n return {\n x: vm.x + Math.cos(halfAngle) * halfRadius,\n y: vm.y + Math.sin(halfAngle) * halfRadius\n };\n },\n getArea: function () {\n var vm = this._view;\n return Math.PI * ((vm.endAngle - vm.startAngle) / (2 * Math.PI)) * (Math.pow(vm.outerRadius, 2) - Math.pow(vm.innerRadius, 2));\n },\n tooltipPosition: function () {\n var vm = this._view;\n var centreAngle = vm.startAngle + (vm.endAngle - vm.startAngle) / 2;\n var rangeFromCentre = (vm.outerRadius - vm.innerRadius) / 2 + vm.innerRadius;\n return {\n x: vm.x + Math.cos(centreAngle) * rangeFromCentre,\n y: vm.y + Math.sin(centreAngle) * rangeFromCentre\n };\n },\n draw: function () {\n var ctx = this._chart.ctx;\n var vm = this._view;\n var pixelMargin = vm.borderAlign === 'inner' ? 0.33 : 0;\n var arc = {\n x: vm.x,\n y: vm.y,\n innerRadius: vm.innerRadius,\n outerRadius: Math.max(vm.outerRadius - pixelMargin, 0),\n pixelMargin: pixelMargin,\n startAngle: vm.startAngle,\n endAngle: vm.endAngle,\n fullCircles: Math.floor(vm.circumference / TAU)\n };\n var i;\n ctx.save();\n ctx.fillStyle = vm.backgroundColor;\n ctx.strokeStyle = vm.borderColor;\n if (arc.fullCircles) {\n arc.endAngle = arc.startAngle + TAU;\n ctx.beginPath();\n ctx.arc(arc.x, arc.y, arc.outerRadius, arc.startAngle, arc.endAngle);\n ctx.arc(arc.x, arc.y, arc.innerRadius, arc.endAngle, arc.startAngle, true);\n ctx.closePath();\n for (i = 0; i < arc.fullCircles; ++i) {\n ctx.fill();\n }\n arc.endAngle = arc.startAngle + vm.circumference % TAU;\n }\n ctx.beginPath();\n ctx.arc(arc.x, arc.y, arc.outerRadius, arc.startAngle, arc.endAngle);\n ctx.arc(arc.x, arc.y, arc.innerRadius, arc.endAngle, arc.startAngle, true);\n ctx.closePath();\n ctx.fill();\n if (vm.borderWidth) {\n drawBorder(ctx, vm, arc);\n }\n ctx.restore();\n }\n });\n var valueOrDefault$1 = helpers$1.valueOrDefault;\n var defaultColor = core_defaults.global.defaultColor;\n core_defaults._set('global', {\n elements: {\n line: {\n tension: 0.4,\n backgroundColor: defaultColor,\n borderWidth: 3,\n borderColor: defaultColor,\n borderCapStyle: 'butt',\n borderDash: [],\n borderDashOffset: 0.0,\n borderJoinStyle: 'miter',\n capBezierPoints: true,\n fill: true // do we fill in the area between the line and its base axis\n }\n }\n });\n var element_line = core_element.extend({\n _type: 'line',\n draw: function () {\n var me = this;\n var vm = me._view;\n var ctx = me._chart.ctx;\n var spanGaps = vm.spanGaps;\n var points = me._children.slice(); // clone array\n var globalDefaults = core_defaults.global;\n var globalOptionLineElements = globalDefaults.elements.line;\n var lastDrawnIndex = -1;\n var closePath = me._loop;\n var index, previous, currentVM;\n if (!points.length) {\n return;\n }\n if (me._loop) {\n for (index = 0; index < points.length; ++index) {\n previous = helpers$1.previousItem(points, index);\n // If the line has an open path, shift the point array\n if (!points[index]._view.skip && previous._view.skip) {\n points = points.slice(index).concat(points.slice(0, index));\n closePath = spanGaps;\n break;\n }\n }\n // If the line has a close path, add the first point again\n if (closePath) {\n points.push(points[0]);\n }\n }\n ctx.save();\n\n // Stroke Line Options\n ctx.lineCap = vm.borderCapStyle || globalOptionLineElements.borderCapStyle;\n\n // IE 9 and 10 do not support line dash\n if (ctx.setLineDash) {\n ctx.setLineDash(vm.borderDash || globalOptionLineElements.borderDash);\n }\n ctx.lineDashOffset = valueOrDefault$1(vm.borderDashOffset, globalOptionLineElements.borderDashOffset);\n ctx.lineJoin = vm.borderJoinStyle || globalOptionLineElements.borderJoinStyle;\n ctx.lineWidth = valueOrDefault$1(vm.borderWidth, globalOptionLineElements.borderWidth);\n ctx.strokeStyle = vm.borderColor || globalDefaults.defaultColor;\n\n // Stroke Line\n ctx.beginPath();\n\n // First point moves to it's starting position no matter what\n currentVM = points[0]._view;\n if (!currentVM.skip) {\n ctx.moveTo(currentVM.x, currentVM.y);\n lastDrawnIndex = 0;\n }\n for (index = 1; index < points.length; ++index) {\n currentVM = points[index]._view;\n previous = lastDrawnIndex === -1 ? helpers$1.previousItem(points, index) : points[lastDrawnIndex];\n if (!currentVM.skip) {\n if (lastDrawnIndex !== index - 1 && !spanGaps || lastDrawnIndex === -1) {\n // There was a gap and this is the first point after the gap\n ctx.moveTo(currentVM.x, currentVM.y);\n } else {\n // Line to next point\n helpers$1.canvas.lineTo(ctx, previous._view, currentVM);\n }\n lastDrawnIndex = index;\n }\n }\n if (closePath) {\n ctx.closePath();\n }\n ctx.stroke();\n ctx.restore();\n }\n });\n var valueOrDefault$2 = helpers$1.valueOrDefault;\n var defaultColor$1 = core_defaults.global.defaultColor;\n core_defaults._set('global', {\n elements: {\n point: {\n radius: 3,\n pointStyle: 'circle',\n backgroundColor: defaultColor$1,\n borderColor: defaultColor$1,\n borderWidth: 1,\n // Hover\n hitRadius: 1,\n hoverRadius: 4,\n hoverBorderWidth: 1\n }\n }\n });\n function xRange(mouseX) {\n var vm = this._view;\n return vm ? Math.abs(mouseX - vm.x) < vm.radius + vm.hitRadius : false;\n }\n function yRange(mouseY) {\n var vm = this._view;\n return vm ? Math.abs(mouseY - vm.y) < vm.radius + vm.hitRadius : false;\n }\n var element_point = core_element.extend({\n _type: 'point',\n inRange: function (mouseX, mouseY) {\n var vm = this._view;\n return vm ? Math.pow(mouseX - vm.x, 2) + Math.pow(mouseY - vm.y, 2) < Math.pow(vm.hitRadius + vm.radius, 2) : false;\n },\n inLabelRange: xRange,\n inXRange: xRange,\n inYRange: yRange,\n getCenterPoint: function () {\n var vm = this._view;\n return {\n x: vm.x,\n y: vm.y\n };\n },\n getArea: function () {\n return Math.PI * Math.pow(this._view.radius, 2);\n },\n tooltipPosition: function () {\n var vm = this._view;\n return {\n x: vm.x,\n y: vm.y,\n padding: vm.radius + vm.borderWidth\n };\n },\n draw: function (chartArea) {\n var vm = this._view;\n var ctx = this._chart.ctx;\n var pointStyle = vm.pointStyle;\n var rotation = vm.rotation;\n var radius = vm.radius;\n var x = vm.x;\n var y = vm.y;\n var globalDefaults = core_defaults.global;\n var defaultColor = globalDefaults.defaultColor; // eslint-disable-line no-shadow\n\n if (vm.skip) {\n return;\n }\n\n // Clipping for Points.\n if (chartArea === undefined || helpers$1.canvas._isPointInArea(vm, chartArea)) {\n ctx.strokeStyle = vm.borderColor || defaultColor;\n ctx.lineWidth = valueOrDefault$2(vm.borderWidth, globalDefaults.elements.point.borderWidth);\n ctx.fillStyle = vm.backgroundColor || defaultColor;\n helpers$1.canvas.drawPoint(ctx, pointStyle, radius, x, y, rotation);\n }\n }\n });\n var defaultColor$2 = core_defaults.global.defaultColor;\n core_defaults._set('global', {\n elements: {\n rectangle: {\n backgroundColor: defaultColor$2,\n borderColor: defaultColor$2,\n borderSkipped: 'bottom',\n borderWidth: 0\n }\n }\n });\n function isVertical(vm) {\n return vm && vm.width !== undefined;\n }\n\n /**\r\n * Helper function to get the bounds of the bar regardless of the orientation\r\n * @param bar {Chart.Element.Rectangle} the bar\r\n * @return {Bounds} bounds of the bar\r\n * @private\r\n */\n function getBarBounds(vm) {\n var x1, x2, y1, y2, half;\n if (isVertical(vm)) {\n half = vm.width / 2;\n x1 = vm.x - half;\n x2 = vm.x + half;\n y1 = Math.min(vm.y, vm.base);\n y2 = Math.max(vm.y, vm.base);\n } else {\n half = vm.height / 2;\n x1 = Math.min(vm.x, vm.base);\n x2 = Math.max(vm.x, vm.base);\n y1 = vm.y - half;\n y2 = vm.y + half;\n }\n return {\n left: x1,\n top: y1,\n right: x2,\n bottom: y2\n };\n }\n function swap(orig, v1, v2) {\n return orig === v1 ? v2 : orig === v2 ? v1 : orig;\n }\n function parseBorderSkipped(vm) {\n var edge = vm.borderSkipped;\n var res = {};\n if (!edge) {\n return res;\n }\n if (vm.horizontal) {\n if (vm.base > vm.x) {\n edge = swap(edge, 'left', 'right');\n }\n } else if (vm.base < vm.y) {\n edge = swap(edge, 'bottom', 'top');\n }\n res[edge] = true;\n return res;\n }\n function parseBorderWidth(vm, maxW, maxH) {\n var value = vm.borderWidth;\n var skip = parseBorderSkipped(vm);\n var t, r, b, l;\n if (helpers$1.isObject(value)) {\n t = +value.top || 0;\n r = +value.right || 0;\n b = +value.bottom || 0;\n l = +value.left || 0;\n } else {\n t = r = b = l = +value || 0;\n }\n return {\n t: skip.top || t < 0 ? 0 : t > maxH ? maxH : t,\n r: skip.right || r < 0 ? 0 : r > maxW ? maxW : r,\n b: skip.bottom || b < 0 ? 0 : b > maxH ? maxH : b,\n l: skip.left || l < 0 ? 0 : l > maxW ? maxW : l\n };\n }\n function boundingRects(vm) {\n var bounds = getBarBounds(vm);\n var width = bounds.right - bounds.left;\n var height = bounds.bottom - bounds.top;\n var border = parseBorderWidth(vm, width / 2, height / 2);\n return {\n outer: {\n x: bounds.left,\n y: bounds.top,\n w: width,\n h: height\n },\n inner: {\n x: bounds.left + border.l,\n y: bounds.top + border.t,\n w: width - border.l - border.r,\n h: height - border.t - border.b\n }\n };\n }\n function inRange(vm, x, y) {\n var skipX = x === null;\n var skipY = y === null;\n var bounds = !vm || skipX && skipY ? false : getBarBounds(vm);\n return bounds && (skipX || x >= bounds.left && x <= bounds.right) && (skipY || y >= bounds.top && y <= bounds.bottom);\n }\n var element_rectangle = core_element.extend({\n _type: 'rectangle',\n draw: function () {\n var ctx = this._chart.ctx;\n var vm = this._view;\n var rects = boundingRects(vm);\n var outer = rects.outer;\n var inner = rects.inner;\n ctx.fillStyle = vm.backgroundColor;\n ctx.fillRect(outer.x, outer.y, outer.w, outer.h);\n if (outer.w === inner.w && outer.h === inner.h) {\n return;\n }\n ctx.save();\n ctx.beginPath();\n ctx.rect(outer.x, outer.y, outer.w, outer.h);\n ctx.clip();\n ctx.fillStyle = vm.borderColor;\n ctx.rect(inner.x, inner.y, inner.w, inner.h);\n ctx.fill('evenodd');\n ctx.restore();\n },\n height: function () {\n var vm = this._view;\n return vm.base - vm.y;\n },\n inRange: function (mouseX, mouseY) {\n return inRange(this._view, mouseX, mouseY);\n },\n inLabelRange: function (mouseX, mouseY) {\n var vm = this._view;\n return isVertical(vm) ? inRange(vm, mouseX, null) : inRange(vm, null, mouseY);\n },\n inXRange: function (mouseX) {\n return inRange(this._view, mouseX, null);\n },\n inYRange: function (mouseY) {\n return inRange(this._view, null, mouseY);\n },\n getCenterPoint: function () {\n var vm = this._view;\n var x, y;\n if (isVertical(vm)) {\n x = vm.x;\n y = (vm.y + vm.base) / 2;\n } else {\n x = (vm.x + vm.base) / 2;\n y = vm.y;\n }\n return {\n x: x,\n y: y\n };\n },\n getArea: function () {\n var vm = this._view;\n return isVertical(vm) ? vm.width * Math.abs(vm.y - vm.base) : vm.height * Math.abs(vm.x - vm.base);\n },\n tooltipPosition: function () {\n var vm = this._view;\n return {\n x: vm.x,\n y: vm.y\n };\n }\n });\n var elements = {};\n var Arc = element_arc;\n var Line = element_line;\n var Point = element_point;\n var Rectangle = element_rectangle;\n elements.Arc = Arc;\n elements.Line = Line;\n elements.Point = Point;\n elements.Rectangle = Rectangle;\n var deprecated = helpers$1._deprecated;\n var valueOrDefault$3 = helpers$1.valueOrDefault;\n core_defaults._set('bar', {\n hover: {\n mode: 'label'\n },\n scales: {\n xAxes: [{\n type: 'category',\n offset: true,\n gridLines: {\n offsetGridLines: true\n }\n }],\n yAxes: [{\n type: 'linear'\n }]\n }\n });\n core_defaults._set('global', {\n datasets: {\n bar: {\n categoryPercentage: 0.8,\n barPercentage: 0.9\n }\n }\n });\n\n /**\r\n * Computes the \"optimal\" sample size to maintain bars equally sized while preventing overlap.\r\n * @private\r\n */\n function computeMinSampleSize(scale, pixels) {\n var min = scale._length;\n var prev, curr, i, ilen;\n for (i = 1, ilen = pixels.length; i < ilen; ++i) {\n min = Math.min(min, Math.abs(pixels[i] - pixels[i - 1]));\n }\n for (i = 0, ilen = scale.getTicks().length; i < ilen; ++i) {\n curr = scale.getPixelForTick(i);\n min = i > 0 ? Math.min(min, Math.abs(curr - prev)) : min;\n prev = curr;\n }\n return min;\n }\n\n /**\r\n * Computes an \"ideal\" category based on the absolute bar thickness or, if undefined or null,\r\n * uses the smallest interval (see computeMinSampleSize) that prevents bar overlapping. This\r\n * mode currently always generates bars equally sized (until we introduce scriptable options?).\r\n * @private\r\n */\n function computeFitCategoryTraits(index, ruler, options) {\n var thickness = options.barThickness;\n var count = ruler.stackCount;\n var curr = ruler.pixels[index];\n var min = helpers$1.isNullOrUndef(thickness) ? computeMinSampleSize(ruler.scale, ruler.pixels) : -1;\n var size, ratio;\n if (helpers$1.isNullOrUndef(thickness)) {\n size = min * options.categoryPercentage;\n ratio = options.barPercentage;\n } else {\n // When bar thickness is enforced, category and bar percentages are ignored.\n // Note(SB): we could add support for relative bar thickness (e.g. barThickness: '50%')\n // and deprecate barPercentage since this value is ignored when thickness is absolute.\n size = thickness * count;\n ratio = 1;\n }\n return {\n chunk: size / count,\n ratio: ratio,\n start: curr - size / 2\n };\n }\n\n /**\r\n * Computes an \"optimal\" category that globally arranges bars side by side (no gap when\r\n * percentage options are 1), based on the previous and following categories. This mode\r\n * generates bars with different widths when data are not evenly spaced.\r\n * @private\r\n */\n function computeFlexCategoryTraits(index, ruler, options) {\n var pixels = ruler.pixels;\n var curr = pixels[index];\n var prev = index > 0 ? pixels[index - 1] : null;\n var next = index < pixels.length - 1 ? pixels[index + 1] : null;\n var percent = options.categoryPercentage;\n var start, size;\n if (prev === null) {\n // first data: its size is double based on the next point or,\n // if it's also the last data, we use the scale size.\n prev = curr - (next === null ? ruler.end - ruler.start : next - curr);\n }\n if (next === null) {\n // last data: its size is also double based on the previous point.\n next = curr + curr - prev;\n }\n start = curr - (curr - Math.min(prev, next)) / 2 * percent;\n size = Math.abs(next - prev) / 2 * percent;\n return {\n chunk: size / ruler.stackCount,\n ratio: options.barPercentage,\n start: start\n };\n }\n var controller_bar = core_datasetController.extend({\n dataElementType: elements.Rectangle,\n /**\r\n * @private\r\n */\n _dataElementOptions: ['backgroundColor', 'borderColor', 'borderSkipped', 'borderWidth', 'barPercentage', 'barThickness', 'categoryPercentage', 'maxBarThickness', 'minBarLength'],\n initialize: function () {\n var me = this;\n var meta, scaleOpts;\n core_datasetController.prototype.initialize.apply(me, arguments);\n meta = me.getMeta();\n meta.stack = me.getDataset().stack;\n meta.bar = true;\n scaleOpts = me._getIndexScale().options;\n deprecated('bar chart', scaleOpts.barPercentage, 'scales.[x/y]Axes.barPercentage', 'dataset.barPercentage');\n deprecated('bar chart', scaleOpts.barThickness, 'scales.[x/y]Axes.barThickness', 'dataset.barThickness');\n deprecated('bar chart', scaleOpts.categoryPercentage, 'scales.[x/y]Axes.categoryPercentage', 'dataset.categoryPercentage');\n deprecated('bar chart', me._getValueScale().options.minBarLength, 'scales.[x/y]Axes.minBarLength', 'dataset.minBarLength');\n deprecated('bar chart', scaleOpts.maxBarThickness, 'scales.[x/y]Axes.maxBarThickness', 'dataset.maxBarThickness');\n },\n update: function (reset) {\n var me = this;\n var rects = me.getMeta().data;\n var i, ilen;\n me._ruler = me.getRuler();\n for (i = 0, ilen = rects.length; i < ilen; ++i) {\n me.updateElement(rects[i], i, reset);\n }\n },\n updateElement: function (rectangle, index, reset) {\n var me = this;\n var meta = me.getMeta();\n var dataset = me.getDataset();\n var options = me._resolveDataElementOptions(rectangle, index);\n rectangle._xScale = me.getScaleForId(meta.xAxisID);\n rectangle._yScale = me.getScaleForId(meta.yAxisID);\n rectangle._datasetIndex = me.index;\n rectangle._index = index;\n rectangle._model = {\n backgroundColor: options.backgroundColor,\n borderColor: options.borderColor,\n borderSkipped: options.borderSkipped,\n borderWidth: options.borderWidth,\n datasetLabel: dataset.label,\n label: me.chart.data.labels[index]\n };\n if (helpers$1.isArray(dataset.data[index])) {\n rectangle._model.borderSkipped = null;\n }\n me._updateElementGeometry(rectangle, index, reset, options);\n rectangle.pivot();\n },\n /**\r\n * @private\r\n */\n _updateElementGeometry: function (rectangle, index, reset, options) {\n var me = this;\n var model = rectangle._model;\n var vscale = me._getValueScale();\n var base = vscale.getBasePixel();\n var horizontal = vscale.isHorizontal();\n var ruler = me._ruler || me.getRuler();\n var vpixels = me.calculateBarValuePixels(me.index, index, options);\n var ipixels = me.calculateBarIndexPixels(me.index, index, ruler, options);\n model.horizontal = horizontal;\n model.base = reset ? base : vpixels.base;\n model.x = horizontal ? reset ? base : vpixels.head : ipixels.center;\n model.y = horizontal ? ipixels.center : reset ? base : vpixels.head;\n model.height = horizontal ? ipixels.size : undefined;\n model.width = horizontal ? undefined : ipixels.size;\n },\n /**\r\n * Returns the stacks based on groups and bar visibility.\r\n * @param {number} [last] - The dataset index\r\n * @returns {string[]} The list of stack IDs\r\n * @private\r\n */\n _getStacks: function (last) {\n var me = this;\n var scale = me._getIndexScale();\n var metasets = scale._getMatchingVisibleMetas(me._type);\n var stacked = scale.options.stacked;\n var ilen = metasets.length;\n var stacks = [];\n var i, meta;\n for (i = 0; i < ilen; ++i) {\n meta = metasets[i];\n // stacked | meta.stack\n // | found | not found | undefined\n // false | x | x | x\n // true | | x |\n // undefined | | x | x\n if (stacked === false || stacks.indexOf(meta.stack) === -1 || stacked === undefined && meta.stack === undefined) {\n stacks.push(meta.stack);\n }\n if (meta.index === last) {\n break;\n }\n }\n return stacks;\n },\n /**\r\n * Returns the effective number of stacks based on groups and bar visibility.\r\n * @private\r\n */\n getStackCount: function () {\n return this._getStacks().length;\n },\n /**\r\n * Returns the stack index for the given dataset based on groups and bar visibility.\r\n * @param {number} [datasetIndex] - The dataset index\r\n * @param {string} [name] - The stack name to find\r\n * @returns {number} The stack index\r\n * @private\r\n */\n getStackIndex: function (datasetIndex, name) {\n var stacks = this._getStacks(datasetIndex);\n var index = name !== undefined ? stacks.indexOf(name) : -1; // indexOf returns -1 if element is not present\n\n return index === -1 ? stacks.length - 1 : index;\n },\n /**\r\n * @private\r\n */\n getRuler: function () {\n var me = this;\n var scale = me._getIndexScale();\n var pixels = [];\n var i, ilen;\n for (i = 0, ilen = me.getMeta().data.length; i < ilen; ++i) {\n pixels.push(scale.getPixelForValue(null, i, me.index));\n }\n return {\n pixels: pixels,\n start: scale._startPixel,\n end: scale._endPixel,\n stackCount: me.getStackCount(),\n scale: scale\n };\n },\n /**\r\n * Note: pixel values are not clamped to the scale area.\r\n * @private\r\n */\n calculateBarValuePixels: function (datasetIndex, index, options) {\n var me = this;\n var chart = me.chart;\n var scale = me._getValueScale();\n var isHorizontal = scale.isHorizontal();\n var datasets = chart.data.datasets;\n var metasets = scale._getMatchingVisibleMetas(me._type);\n var value = scale._parseValue(datasets[datasetIndex].data[index]);\n var minBarLength = options.minBarLength;\n var stacked = scale.options.stacked;\n var stack = me.getMeta().stack;\n var start = value.start === undefined ? 0 : value.max >= 0 && value.min >= 0 ? value.min : value.max;\n var length = value.start === undefined ? value.end : value.max >= 0 && value.min >= 0 ? value.max - value.min : value.min - value.max;\n var ilen = metasets.length;\n var i, imeta, ivalue, base, head, size, stackLength;\n if (stacked || stacked === undefined && stack !== undefined) {\n for (i = 0; i < ilen; ++i) {\n imeta = metasets[i];\n if (imeta.index === datasetIndex) {\n break;\n }\n if (imeta.stack === stack) {\n stackLength = scale._parseValue(datasets[imeta.index].data[index]);\n ivalue = stackLength.start === undefined ? stackLength.end : stackLength.min >= 0 && stackLength.max >= 0 ? stackLength.max : stackLength.min;\n if (value.min < 0 && ivalue < 0 || value.max >= 0 && ivalue > 0) {\n start += ivalue;\n }\n }\n }\n }\n base = scale.getPixelForValue(start);\n head = scale.getPixelForValue(start + length);\n size = head - base;\n if (minBarLength !== undefined && Math.abs(size) < minBarLength) {\n size = minBarLength;\n if (length >= 0 && !isHorizontal || length < 0 && isHorizontal) {\n head = base - minBarLength;\n } else {\n head = base + minBarLength;\n }\n }\n return {\n size: size,\n base: base,\n head: head,\n center: head + size / 2\n };\n },\n /**\r\n * @private\r\n */\n calculateBarIndexPixels: function (datasetIndex, index, ruler, options) {\n var me = this;\n var range = options.barThickness === 'flex' ? computeFlexCategoryTraits(index, ruler, options) : computeFitCategoryTraits(index, ruler, options);\n var stackIndex = me.getStackIndex(datasetIndex, me.getMeta().stack);\n var center = range.start + range.chunk * stackIndex + range.chunk / 2;\n var size = Math.min(valueOrDefault$3(options.maxBarThickness, Infinity), range.chunk * range.ratio);\n return {\n base: center - size / 2,\n head: center + size / 2,\n center: center,\n size: size\n };\n },\n draw: function () {\n var me = this;\n var chart = me.chart;\n var scale = me._getValueScale();\n var rects = me.getMeta().data;\n var dataset = me.getDataset();\n var ilen = rects.length;\n var i = 0;\n helpers$1.canvas.clipArea(chart.ctx, chart.chartArea);\n for (; i < ilen; ++i) {\n var val = scale._parseValue(dataset.data[i]);\n if (!isNaN(val.min) && !isNaN(val.max)) {\n rects[i].draw();\n }\n }\n helpers$1.canvas.unclipArea(chart.ctx);\n },\n /**\r\n * @private\r\n */\n _resolveDataElementOptions: function () {\n var me = this;\n var values = helpers$1.extend({}, core_datasetController.prototype._resolveDataElementOptions.apply(me, arguments));\n var indexOpts = me._getIndexScale().options;\n var valueOpts = me._getValueScale().options;\n values.barPercentage = valueOrDefault$3(indexOpts.barPercentage, values.barPercentage);\n values.barThickness = valueOrDefault$3(indexOpts.barThickness, values.barThickness);\n values.categoryPercentage = valueOrDefault$3(indexOpts.categoryPercentage, values.categoryPercentage);\n values.maxBarThickness = valueOrDefault$3(indexOpts.maxBarThickness, values.maxBarThickness);\n values.minBarLength = valueOrDefault$3(valueOpts.minBarLength, values.minBarLength);\n return values;\n }\n });\n var valueOrDefault$4 = helpers$1.valueOrDefault;\n var resolve$1 = helpers$1.options.resolve;\n core_defaults._set('bubble', {\n hover: {\n mode: 'single'\n },\n scales: {\n xAxes: [{\n type: 'linear',\n // bubble should probably use a linear scale by default\n position: 'bottom',\n id: 'x-axis-0' // need an ID so datasets can reference the scale\n }],\n yAxes: [{\n type: 'linear',\n position: 'left',\n id: 'y-axis-0'\n }]\n },\n tooltips: {\n callbacks: {\n title: function () {\n // Title doesn't make sense for scatter since we format the data as a point\n return '';\n },\n label: function (item, data) {\n var datasetLabel = data.datasets[item.datasetIndex].label || '';\n var dataPoint = data.datasets[item.datasetIndex].data[item.index];\n return datasetLabel + ': (' + item.xLabel + ', ' + item.yLabel + ', ' + dataPoint.r + ')';\n }\n }\n }\n });\n var controller_bubble = core_datasetController.extend({\n /**\r\n * @protected\r\n */\n dataElementType: elements.Point,\n /**\r\n * @private\r\n */\n _dataElementOptions: ['backgroundColor', 'borderColor', 'borderWidth', 'hoverBackgroundColor', 'hoverBorderColor', 'hoverBorderWidth', 'hoverRadius', 'hitRadius', 'pointStyle', 'rotation'],\n /**\r\n * @protected\r\n */\n update: function (reset) {\n var me = this;\n var meta = me.getMeta();\n var points = meta.data;\n\n // Update Points\n helpers$1.each(points, function (point, index) {\n me.updateElement(point, index, reset);\n });\n },\n /**\r\n * @protected\r\n */\n updateElement: function (point, index, reset) {\n var me = this;\n var meta = me.getMeta();\n var custom = point.custom || {};\n var xScale = me.getScaleForId(meta.xAxisID);\n var yScale = me.getScaleForId(meta.yAxisID);\n var options = me._resolveDataElementOptions(point, index);\n var data = me.getDataset().data[index];\n var dsIndex = me.index;\n var x = reset ? xScale.getPixelForDecimal(0.5) : xScale.getPixelForValue(typeof data === 'object' ? data : NaN, index, dsIndex);\n var y = reset ? yScale.getBasePixel() : yScale.getPixelForValue(data, index, dsIndex);\n point._xScale = xScale;\n point._yScale = yScale;\n point._options = options;\n point._datasetIndex = dsIndex;\n point._index = index;\n point._model = {\n backgroundColor: options.backgroundColor,\n borderColor: options.borderColor,\n borderWidth: options.borderWidth,\n hitRadius: options.hitRadius,\n pointStyle: options.pointStyle,\n rotation: options.rotation,\n radius: reset ? 0 : options.radius,\n skip: custom.skip || isNaN(x) || isNaN(y),\n x: x,\n y: y\n };\n point.pivot();\n },\n /**\r\n * @protected\r\n */\n setHoverStyle: function (point) {\n var model = point._model;\n var options = point._options;\n var getHoverColor = helpers$1.getHoverColor;\n point.$previousStyle = {\n backgroundColor: model.backgroundColor,\n borderColor: model.borderColor,\n borderWidth: model.borderWidth,\n radius: model.radius\n };\n model.backgroundColor = valueOrDefault$4(options.hoverBackgroundColor, getHoverColor(options.backgroundColor));\n model.borderColor = valueOrDefault$4(options.hoverBorderColor, getHoverColor(options.borderColor));\n model.borderWidth = valueOrDefault$4(options.hoverBorderWidth, options.borderWidth);\n model.radius = options.radius + options.hoverRadius;\n },\n /**\r\n * @private\r\n */\n _resolveDataElementOptions: function (point, index) {\n var me = this;\n var chart = me.chart;\n var dataset = me.getDataset();\n var custom = point.custom || {};\n var data = dataset.data[index] || {};\n var values = core_datasetController.prototype._resolveDataElementOptions.apply(me, arguments);\n\n // Scriptable options\n var context = {\n chart: chart,\n dataIndex: index,\n dataset: dataset,\n datasetIndex: me.index\n };\n\n // In case values were cached (and thus frozen), we need to clone the values\n if (me._cachedDataOpts === values) {\n values = helpers$1.extend({}, values);\n }\n\n // Custom radius resolution\n values.radius = resolve$1([custom.radius, data.r, me._config.radius, chart.options.elements.point.radius], context, index);\n return values;\n }\n });\n var valueOrDefault$5 = helpers$1.valueOrDefault;\n var PI$1 = Math.PI;\n var DOUBLE_PI$1 = PI$1 * 2;\n var HALF_PI$1 = PI$1 / 2;\n core_defaults._set('doughnut', {\n animation: {\n // Boolean - Whether we animate the rotation of the Doughnut\n animateRotate: true,\n // Boolean - Whether we animate scaling the Doughnut from the centre\n animateScale: false\n },\n hover: {\n mode: 'single'\n },\n legendCallback: function (chart) {\n var list = document.createElement('ul');\n var data = chart.data;\n var datasets = data.datasets;\n var labels = data.labels;\n var i, ilen, listItem, listItemSpan;\n list.setAttribute('class', chart.id + '-legend');\n if (datasets.length) {\n for (i = 0, ilen = datasets[0].data.length; i < ilen; ++i) {\n listItem = list.appendChild(document.createElement('li'));\n listItemSpan = listItem.appendChild(document.createElement('span'));\n listItemSpan.style.backgroundColor = datasets[0].backgroundColor[i];\n if (labels[i]) {\n listItem.appendChild(document.createTextNode(labels[i]));\n }\n }\n }\n return list.outerHTML;\n },\n legend: {\n labels: {\n generateLabels: function (chart) {\n var data = chart.data;\n if (data.labels.length && data.datasets.length) {\n return data.labels.map(function (label, i) {\n var meta = chart.getDatasetMeta(0);\n var style = meta.controller.getStyle(i);\n return {\n text: label,\n fillStyle: style.backgroundColor,\n strokeStyle: style.borderColor,\n lineWidth: style.borderWidth,\n hidden: isNaN(data.datasets[0].data[i]) || meta.data[i].hidden,\n // Extra data used for toggling the correct item\n index: i\n };\n });\n }\n return [];\n }\n },\n onClick: function (e, legendItem) {\n var index = legendItem.index;\n var chart = this.chart;\n var i, ilen, meta;\n for (i = 0, ilen = (chart.data.datasets || []).length; i < ilen; ++i) {\n meta = chart.getDatasetMeta(i);\n // toggle visibility of index if exists\n if (meta.data[index]) {\n meta.data[index].hidden = !meta.data[index].hidden;\n }\n }\n chart.update();\n }\n },\n // The percentage of the chart that we cut out of the middle.\n cutoutPercentage: 50,\n // The rotation of the chart, where the first data arc begins.\n rotation: -HALF_PI$1,\n // The total circumference of the chart.\n circumference: DOUBLE_PI$1,\n // Need to override these to give a nice default\n tooltips: {\n callbacks: {\n title: function () {\n return '';\n },\n label: function (tooltipItem, data) {\n var dataLabel = data.labels[tooltipItem.index];\n var value = ': ' + data.datasets[tooltipItem.datasetIndex].data[tooltipItem.index];\n if (helpers$1.isArray(dataLabel)) {\n // show value on first line of multiline label\n // need to clone because we are changing the value\n dataLabel = dataLabel.slice();\n dataLabel[0] += value;\n } else {\n dataLabel += value;\n }\n return dataLabel;\n }\n }\n }\n });\n var controller_doughnut = core_datasetController.extend({\n dataElementType: elements.Arc,\n linkScales: helpers$1.noop,\n /**\r\n * @private\r\n */\n _dataElementOptions: ['backgroundColor', 'borderColor', 'borderWidth', 'borderAlign', 'hoverBackgroundColor', 'hoverBorderColor', 'hoverBorderWidth'],\n // Get index of the dataset in relation to the visible datasets. This allows determining the inner and outer radius correctly\n getRingIndex: function (datasetIndex) {\n var ringIndex = 0;\n for (var j = 0; j < datasetIndex; ++j) {\n if (this.chart.isDatasetVisible(j)) {\n ++ringIndex;\n }\n }\n return ringIndex;\n },\n update: function (reset) {\n var me = this;\n var chart = me.chart;\n var chartArea = chart.chartArea;\n var opts = chart.options;\n var ratioX = 1;\n var ratioY = 1;\n var offsetX = 0;\n var offsetY = 0;\n var meta = me.getMeta();\n var arcs = meta.data;\n var cutout = opts.cutoutPercentage / 100 || 0;\n var circumference = opts.circumference;\n var chartWeight = me._getRingWeight(me.index);\n var maxWidth, maxHeight, i, ilen;\n\n // If the chart's circumference isn't a full circle, calculate size as a ratio of the width/height of the arc\n if (circumference < DOUBLE_PI$1) {\n var startAngle = opts.rotation % DOUBLE_PI$1;\n startAngle += startAngle >= PI$1 ? -DOUBLE_PI$1 : startAngle < -PI$1 ? DOUBLE_PI$1 : 0;\n var endAngle = startAngle + circumference;\n var startX = Math.cos(startAngle);\n var startY = Math.sin(startAngle);\n var endX = Math.cos(endAngle);\n var endY = Math.sin(endAngle);\n var contains0 = startAngle <= 0 && endAngle >= 0 || endAngle >= DOUBLE_PI$1;\n var contains90 = startAngle <= HALF_PI$1 && endAngle >= HALF_PI$1 || endAngle >= DOUBLE_PI$1 + HALF_PI$1;\n var contains180 = startAngle === -PI$1 || endAngle >= PI$1;\n var contains270 = startAngle <= -HALF_PI$1 && endAngle >= -HALF_PI$1 || endAngle >= PI$1 + HALF_PI$1;\n var minX = contains180 ? -1 : Math.min(startX, startX * cutout, endX, endX * cutout);\n var minY = contains270 ? -1 : Math.min(startY, startY * cutout, endY, endY * cutout);\n var maxX = contains0 ? 1 : Math.max(startX, startX * cutout, endX, endX * cutout);\n var maxY = contains90 ? 1 : Math.max(startY, startY * cutout, endY, endY * cutout);\n ratioX = (maxX - minX) / 2;\n ratioY = (maxY - minY) / 2;\n offsetX = -(maxX + minX) / 2;\n offsetY = -(maxY + minY) / 2;\n }\n for (i = 0, ilen = arcs.length; i < ilen; ++i) {\n arcs[i]._options = me._resolveDataElementOptions(arcs[i], i);\n }\n chart.borderWidth = me.getMaxBorderWidth();\n maxWidth = (chartArea.right - chartArea.left - chart.borderWidth) / ratioX;\n maxHeight = (chartArea.bottom - chartArea.top - chart.borderWidth) / ratioY;\n chart.outerRadius = Math.max(Math.min(maxWidth, maxHeight) / 2, 0);\n chart.innerRadius = Math.max(chart.outerRadius * cutout, 0);\n chart.radiusLength = (chart.outerRadius - chart.innerRadius) / (me._getVisibleDatasetWeightTotal() || 1);\n chart.offsetX = offsetX * chart.outerRadius;\n chart.offsetY = offsetY * chart.outerRadius;\n meta.total = me.calculateTotal();\n me.outerRadius = chart.outerRadius - chart.radiusLength * me._getRingWeightOffset(me.index);\n me.innerRadius = Math.max(me.outerRadius - chart.radiusLength * chartWeight, 0);\n for (i = 0, ilen = arcs.length; i < ilen; ++i) {\n me.updateElement(arcs[i], i, reset);\n }\n },\n updateElement: function (arc, index, reset) {\n var me = this;\n var chart = me.chart;\n var chartArea = chart.chartArea;\n var opts = chart.options;\n var animationOpts = opts.animation;\n var centerX = (chartArea.left + chartArea.right) / 2;\n var centerY = (chartArea.top + chartArea.bottom) / 2;\n var startAngle = opts.rotation; // non reset case handled later\n var endAngle = opts.rotation; // non reset case handled later\n var dataset = me.getDataset();\n var circumference = reset && animationOpts.animateRotate ? 0 : arc.hidden ? 0 : me.calculateCircumference(dataset.data[index]) * (opts.circumference / DOUBLE_PI$1);\n var innerRadius = reset && animationOpts.animateScale ? 0 : me.innerRadius;\n var outerRadius = reset && animationOpts.animateScale ? 0 : me.outerRadius;\n var options = arc._options || {};\n helpers$1.extend(arc, {\n // Utility\n _datasetIndex: me.index,\n _index: index,\n // Desired view properties\n _model: {\n backgroundColor: options.backgroundColor,\n borderColor: options.borderColor,\n borderWidth: options.borderWidth,\n borderAlign: options.borderAlign,\n x: centerX + chart.offsetX,\n y: centerY + chart.offsetY,\n startAngle: startAngle,\n endAngle: endAngle,\n circumference: circumference,\n outerRadius: outerRadius,\n innerRadius: innerRadius,\n label: helpers$1.valueAtIndexOrDefault(dataset.label, index, chart.data.labels[index])\n }\n });\n var model = arc._model;\n\n // Set correct angles if not resetting\n if (!reset || !animationOpts.animateRotate) {\n if (index === 0) {\n model.startAngle = opts.rotation;\n } else {\n model.startAngle = me.getMeta().data[index - 1]._model.endAngle;\n }\n model.endAngle = model.startAngle + model.circumference;\n }\n arc.pivot();\n },\n calculateTotal: function () {\n var dataset = this.getDataset();\n var meta = this.getMeta();\n var total = 0;\n var value;\n helpers$1.each(meta.data, function (element, index) {\n value = dataset.data[index];\n if (!isNaN(value) && !element.hidden) {\n total += Math.abs(value);\n }\n });\n\n /* if (total === 0) {\r\n \ttotal = NaN;\r\n }*/\n\n return total;\n },\n calculateCircumference: function (value) {\n var total = this.getMeta().total;\n if (total > 0 && !isNaN(value)) {\n return DOUBLE_PI$1 * (Math.abs(value) / total);\n }\n return 0;\n },\n // gets the max border or hover width to properly scale pie charts\n getMaxBorderWidth: function (arcs) {\n var me = this;\n var max = 0;\n var chart = me.chart;\n var i, ilen, meta, arc, controller, options, borderWidth, hoverWidth;\n if (!arcs) {\n // Find the outmost visible dataset\n for (i = 0, ilen = chart.data.datasets.length; i < ilen; ++i) {\n if (chart.isDatasetVisible(i)) {\n meta = chart.getDatasetMeta(i);\n arcs = meta.data;\n if (i !== me.index) {\n controller = meta.controller;\n }\n break;\n }\n }\n }\n if (!arcs) {\n return 0;\n }\n for (i = 0, ilen = arcs.length; i < ilen; ++i) {\n arc = arcs[i];\n if (controller) {\n controller._configure();\n options = controller._resolveDataElementOptions(arc, i);\n } else {\n options = arc._options;\n }\n if (options.borderAlign !== 'inner') {\n borderWidth = options.borderWidth;\n hoverWidth = options.hoverBorderWidth;\n max = borderWidth > max ? borderWidth : max;\n max = hoverWidth > max ? hoverWidth : max;\n }\n }\n return max;\n },\n /**\r\n * @protected\r\n */\n setHoverStyle: function (arc) {\n var model = arc._model;\n var options = arc._options;\n var getHoverColor = helpers$1.getHoverColor;\n arc.$previousStyle = {\n backgroundColor: model.backgroundColor,\n borderColor: model.borderColor,\n borderWidth: model.borderWidth\n };\n model.backgroundColor = valueOrDefault$5(options.hoverBackgroundColor, getHoverColor(options.backgroundColor));\n model.borderColor = valueOrDefault$5(options.hoverBorderColor, getHoverColor(options.borderColor));\n model.borderWidth = valueOrDefault$5(options.hoverBorderWidth, options.borderWidth);\n },\n /**\r\n * Get radius length offset of the dataset in relation to the visible datasets weights. This allows determining the inner and outer radius correctly\r\n * @private\r\n */\n _getRingWeightOffset: function (datasetIndex) {\n var ringWeightOffset = 0;\n for (var i = 0; i < datasetIndex; ++i) {\n if (this.chart.isDatasetVisible(i)) {\n ringWeightOffset += this._getRingWeight(i);\n }\n }\n return ringWeightOffset;\n },\n /**\r\n * @private\r\n */\n _getRingWeight: function (dataSetIndex) {\n return Math.max(valueOrDefault$5(this.chart.data.datasets[dataSetIndex].weight, 1), 0);\n },\n /**\r\n * Returns the sum of all visibile data set weights. This value can be 0.\r\n * @private\r\n */\n _getVisibleDatasetWeightTotal: function () {\n return this._getRingWeightOffset(this.chart.data.datasets.length);\n }\n });\n core_defaults._set('horizontalBar', {\n hover: {\n mode: 'index',\n axis: 'y'\n },\n scales: {\n xAxes: [{\n type: 'linear',\n position: 'bottom'\n }],\n yAxes: [{\n type: 'category',\n position: 'left',\n offset: true,\n gridLines: {\n offsetGridLines: true\n }\n }]\n },\n elements: {\n rectangle: {\n borderSkipped: 'left'\n }\n },\n tooltips: {\n mode: 'index',\n axis: 'y'\n }\n });\n core_defaults._set('global', {\n datasets: {\n horizontalBar: {\n categoryPercentage: 0.8,\n barPercentage: 0.9\n }\n }\n });\n var controller_horizontalBar = controller_bar.extend({\n /**\r\n * @private\r\n */\n _getValueScaleId: function () {\n return this.getMeta().xAxisID;\n },\n /**\r\n * @private\r\n */\n _getIndexScaleId: function () {\n return this.getMeta().yAxisID;\n }\n });\n var valueOrDefault$6 = helpers$1.valueOrDefault;\n var resolve$2 = helpers$1.options.resolve;\n var isPointInArea = helpers$1.canvas._isPointInArea;\n core_defaults._set('line', {\n showLines: true,\n spanGaps: false,\n hover: {\n mode: 'label'\n },\n scales: {\n xAxes: [{\n type: 'category',\n id: 'x-axis-0'\n }],\n yAxes: [{\n type: 'linear',\n id: 'y-axis-0'\n }]\n }\n });\n function scaleClip(scale, halfBorderWidth) {\n var tickOpts = scale && scale.options.ticks || {};\n var reverse = tickOpts.reverse;\n var min = tickOpts.min === undefined ? halfBorderWidth : 0;\n var max = tickOpts.max === undefined ? halfBorderWidth : 0;\n return {\n start: reverse ? max : min,\n end: reverse ? min : max\n };\n }\n function defaultClip(xScale, yScale, borderWidth) {\n var halfBorderWidth = borderWidth / 2;\n var x = scaleClip(xScale, halfBorderWidth);\n var y = scaleClip(yScale, halfBorderWidth);\n return {\n top: y.end,\n right: x.end,\n bottom: y.start,\n left: x.start\n };\n }\n function toClip(value) {\n var t, r, b, l;\n if (helpers$1.isObject(value)) {\n t = value.top;\n r = value.right;\n b = value.bottom;\n l = value.left;\n } else {\n t = r = b = l = value;\n }\n return {\n top: t,\n right: r,\n bottom: b,\n left: l\n };\n }\n var controller_line = core_datasetController.extend({\n datasetElementType: elements.Line,\n dataElementType: elements.Point,\n /**\r\n * @private\r\n */\n _datasetElementOptions: ['backgroundColor', 'borderCapStyle', 'borderColor', 'borderDash', 'borderDashOffset', 'borderJoinStyle', 'borderWidth', 'cubicInterpolationMode', 'fill'],\n /**\r\n * @private\r\n */\n _dataElementOptions: {\n backgroundColor: 'pointBackgroundColor',\n borderColor: 'pointBorderColor',\n borderWidth: 'pointBorderWidth',\n hitRadius: 'pointHitRadius',\n hoverBackgroundColor: 'pointHoverBackgroundColor',\n hoverBorderColor: 'pointHoverBorderColor',\n hoverBorderWidth: 'pointHoverBorderWidth',\n hoverRadius: 'pointHoverRadius',\n pointStyle: 'pointStyle',\n radius: 'pointRadius',\n rotation: 'pointRotation'\n },\n update: function (reset) {\n var me = this;\n var meta = me.getMeta();\n var line = meta.dataset;\n var points = meta.data || [];\n var options = me.chart.options;\n var config = me._config;\n var showLine = me._showLine = valueOrDefault$6(config.showLine, options.showLines);\n var i, ilen;\n me._xScale = me.getScaleForId(meta.xAxisID);\n me._yScale = me.getScaleForId(meta.yAxisID);\n\n // Update Line\n if (showLine) {\n // Compatibility: If the properties are defined with only the old name, use those values\n if (config.tension !== undefined && config.lineTension === undefined) {\n config.lineTension = config.tension;\n }\n\n // Utility\n line._scale = me._yScale;\n line._datasetIndex = me.index;\n // Data\n line._children = points;\n // Model\n line._model = me._resolveDatasetElementOptions(line);\n line.pivot();\n }\n\n // Update Points\n for (i = 0, ilen = points.length; i < ilen; ++i) {\n me.updateElement(points[i], i, reset);\n }\n if (showLine && line._model.tension !== 0) {\n me.updateBezierControlPoints();\n }\n\n // Now pivot the point for animation\n for (i = 0, ilen = points.length; i < ilen; ++i) {\n points[i].pivot();\n }\n },\n updateElement: function (point, index, reset) {\n var me = this;\n var meta = me.getMeta();\n var custom = point.custom || {};\n var dataset = me.getDataset();\n var datasetIndex = me.index;\n var value = dataset.data[index];\n var xScale = me._xScale;\n var yScale = me._yScale;\n var lineModel = meta.dataset._model;\n var x, y;\n var options = me._resolveDataElementOptions(point, index);\n x = xScale.getPixelForValue(typeof value === 'object' ? value : NaN, index, datasetIndex);\n y = reset ? yScale.getBasePixel() : me.calculatePointY(value, index, datasetIndex);\n\n // Utility\n point._xScale = xScale;\n point._yScale = yScale;\n point._options = options;\n point._datasetIndex = datasetIndex;\n point._index = index;\n\n // Desired view properties\n point._model = {\n x: x,\n y: y,\n skip: custom.skip || isNaN(x) || isNaN(y),\n // Appearance\n radius: options.radius,\n pointStyle: options.pointStyle,\n rotation: options.rotation,\n backgroundColor: options.backgroundColor,\n borderColor: options.borderColor,\n borderWidth: options.borderWidth,\n tension: valueOrDefault$6(custom.tension, lineModel ? lineModel.tension : 0),\n steppedLine: lineModel ? lineModel.steppedLine : false,\n // Tooltip\n hitRadius: options.hitRadius\n };\n },\n /**\r\n * @private\r\n */\n _resolveDatasetElementOptions: function (element) {\n var me = this;\n var config = me._config;\n var custom = element.custom || {};\n var options = me.chart.options;\n var lineOptions = options.elements.line;\n var values = core_datasetController.prototype._resolveDatasetElementOptions.apply(me, arguments);\n\n // The default behavior of lines is to break at null values, according\n // to https://github.com/chartjs/Chart.js/issues/2435#issuecomment-216718158\n // This option gives lines the ability to span gaps\n values.spanGaps = valueOrDefault$6(config.spanGaps, options.spanGaps);\n values.tension = valueOrDefault$6(config.lineTension, lineOptions.tension);\n values.steppedLine = resolve$2([custom.steppedLine, config.steppedLine, lineOptions.stepped]);\n values.clip = toClip(valueOrDefault$6(config.clip, defaultClip(me._xScale, me._yScale, values.borderWidth)));\n return values;\n },\n calculatePointY: function (value, index, datasetIndex) {\n var me = this;\n var chart = me.chart;\n var yScale = me._yScale;\n var sumPos = 0;\n var sumNeg = 0;\n var i, ds, dsMeta, stackedRightValue, rightValue, metasets, ilen;\n if (yScale.options.stacked) {\n rightValue = +yScale.getRightValue(value);\n metasets = chart._getSortedVisibleDatasetMetas();\n ilen = metasets.length;\n for (i = 0; i < ilen; ++i) {\n dsMeta = metasets[i];\n if (dsMeta.index === datasetIndex) {\n break;\n }\n ds = chart.data.datasets[dsMeta.index];\n if (dsMeta.type === 'line' && dsMeta.yAxisID === yScale.id) {\n stackedRightValue = +yScale.getRightValue(ds.data[index]);\n if (stackedRightValue < 0) {\n sumNeg += stackedRightValue || 0;\n } else {\n sumPos += stackedRightValue || 0;\n }\n }\n }\n if (rightValue < 0) {\n return yScale.getPixelForValue(sumNeg + rightValue);\n }\n return yScale.getPixelForValue(sumPos + rightValue);\n }\n return yScale.getPixelForValue(value);\n },\n updateBezierControlPoints: function () {\n var me = this;\n var chart = me.chart;\n var meta = me.getMeta();\n var lineModel = meta.dataset._model;\n var area = chart.chartArea;\n var points = meta.data || [];\n var i, ilen, model, controlPoints;\n\n // Only consider points that are drawn in case the spanGaps option is used\n if (lineModel.spanGaps) {\n points = points.filter(function (pt) {\n return !pt._model.skip;\n });\n }\n function capControlPoint(pt, min, max) {\n return Math.max(Math.min(pt, max), min);\n }\n if (lineModel.cubicInterpolationMode === 'monotone') {\n helpers$1.splineCurveMonotone(points);\n } else {\n for (i = 0, ilen = points.length; i < ilen; ++i) {\n model = points[i]._model;\n controlPoints = helpers$1.splineCurve(helpers$1.previousItem(points, i)._model, model, helpers$1.nextItem(points, i)._model, lineModel.tension);\n model.controlPointPreviousX = controlPoints.previous.x;\n model.controlPointPreviousY = controlPoints.previous.y;\n model.controlPointNextX = controlPoints.next.x;\n model.controlPointNextY = controlPoints.next.y;\n }\n }\n if (chart.options.elements.line.capBezierPoints) {\n for (i = 0, ilen = points.length; i < ilen; ++i) {\n model = points[i]._model;\n if (isPointInArea(model, area)) {\n if (i > 0 && isPointInArea(points[i - 1]._model, area)) {\n model.controlPointPreviousX = capControlPoint(model.controlPointPreviousX, area.left, area.right);\n model.controlPointPreviousY = capControlPoint(model.controlPointPreviousY, area.top, area.bottom);\n }\n if (i < points.length - 1 && isPointInArea(points[i + 1]._model, area)) {\n model.controlPointNextX = capControlPoint(model.controlPointNextX, area.left, area.right);\n model.controlPointNextY = capControlPoint(model.controlPointNextY, area.top, area.bottom);\n }\n }\n }\n }\n },\n draw: function () {\n var me = this;\n var chart = me.chart;\n var meta = me.getMeta();\n var points = meta.data || [];\n var area = chart.chartArea;\n var canvas = chart.canvas;\n var i = 0;\n var ilen = points.length;\n var clip;\n if (me._showLine) {\n clip = meta.dataset._model.clip;\n helpers$1.canvas.clipArea(chart.ctx, {\n left: clip.left === false ? 0 : area.left - clip.left,\n right: clip.right === false ? canvas.width : area.right + clip.right,\n top: clip.top === false ? 0 : area.top - clip.top,\n bottom: clip.bottom === false ? canvas.height : area.bottom + clip.bottom\n });\n meta.dataset.draw();\n helpers$1.canvas.unclipArea(chart.ctx);\n }\n\n // Draw the points\n for (; i < ilen; ++i) {\n points[i].draw(area);\n }\n },\n /**\r\n * @protected\r\n */\n setHoverStyle: function (point) {\n var model = point._model;\n var options = point._options;\n var getHoverColor = helpers$1.getHoverColor;\n point.$previousStyle = {\n backgroundColor: model.backgroundColor,\n borderColor: model.borderColor,\n borderWidth: model.borderWidth,\n radius: model.radius\n };\n model.backgroundColor = valueOrDefault$6(options.hoverBackgroundColor, getHoverColor(options.backgroundColor));\n model.borderColor = valueOrDefault$6(options.hoverBorderColor, getHoverColor(options.borderColor));\n model.borderWidth = valueOrDefault$6(options.hoverBorderWidth, options.borderWidth);\n model.radius = valueOrDefault$6(options.hoverRadius, options.radius);\n }\n });\n var resolve$3 = helpers$1.options.resolve;\n core_defaults._set('polarArea', {\n scale: {\n type: 'radialLinear',\n angleLines: {\n display: false\n },\n gridLines: {\n circular: true\n },\n pointLabels: {\n display: false\n },\n ticks: {\n beginAtZero: true\n }\n },\n // Boolean - Whether to animate the rotation of the chart\n animation: {\n animateRotate: true,\n animateScale: true\n },\n startAngle: -0.5 * Math.PI,\n legendCallback: function (chart) {\n var list = document.createElement('ul');\n var data = chart.data;\n var datasets = data.datasets;\n var labels = data.labels;\n var i, ilen, listItem, listItemSpan;\n list.setAttribute('class', chart.id + '-legend');\n if (datasets.length) {\n for (i = 0, ilen = datasets[0].data.length; i < ilen; ++i) {\n listItem = list.appendChild(document.createElement('li'));\n listItemSpan = listItem.appendChild(document.createElement('span'));\n listItemSpan.style.backgroundColor = datasets[0].backgroundColor[i];\n if (labels[i]) {\n listItem.appendChild(document.createTextNode(labels[i]));\n }\n }\n }\n return list.outerHTML;\n },\n legend: {\n labels: {\n generateLabels: function (chart) {\n var data = chart.data;\n if (data.labels.length && data.datasets.length) {\n return data.labels.map(function (label, i) {\n var meta = chart.getDatasetMeta(0);\n var style = meta.controller.getStyle(i);\n return {\n text: label,\n fillStyle: style.backgroundColor,\n strokeStyle: style.borderColor,\n lineWidth: style.borderWidth,\n hidden: isNaN(data.datasets[0].data[i]) || meta.data[i].hidden,\n // Extra data used for toggling the correct item\n index: i\n };\n });\n }\n return [];\n }\n },\n onClick: function (e, legendItem) {\n var index = legendItem.index;\n var chart = this.chart;\n var i, ilen, meta;\n for (i = 0, ilen = (chart.data.datasets || []).length; i < ilen; ++i) {\n meta = chart.getDatasetMeta(i);\n meta.data[index].hidden = !meta.data[index].hidden;\n }\n chart.update();\n }\n },\n // Need to override these to give a nice default\n tooltips: {\n callbacks: {\n title: function () {\n return '';\n },\n label: function (item, data) {\n return data.labels[item.index] + ': ' + item.yLabel;\n }\n }\n }\n });\n var controller_polarArea = core_datasetController.extend({\n dataElementType: elements.Arc,\n linkScales: helpers$1.noop,\n /**\r\n * @private\r\n */\n _dataElementOptions: ['backgroundColor', 'borderColor', 'borderWidth', 'borderAlign', 'hoverBackgroundColor', 'hoverBorderColor', 'hoverBorderWidth'],\n /**\r\n * @private\r\n */\n _getIndexScaleId: function () {\n return this.chart.scale.id;\n },\n /**\r\n * @private\r\n */\n _getValueScaleId: function () {\n return this.chart.scale.id;\n },\n update: function (reset) {\n var me = this;\n var dataset = me.getDataset();\n var meta = me.getMeta();\n var start = me.chart.options.startAngle || 0;\n var starts = me._starts = [];\n var angles = me._angles = [];\n var arcs = meta.data;\n var i, ilen, angle;\n me._updateRadius();\n meta.count = me.countVisibleElements();\n for (i = 0, ilen = dataset.data.length; i < ilen; i++) {\n starts[i] = start;\n angle = me._computeAngle(i);\n angles[i] = angle;\n start += angle;\n }\n for (i = 0, ilen = arcs.length; i < ilen; ++i) {\n arcs[i]._options = me._resolveDataElementOptions(arcs[i], i);\n me.updateElement(arcs[i], i, reset);\n }\n },\n /**\r\n * @private\r\n */\n _updateRadius: function () {\n var me = this;\n var chart = me.chart;\n var chartArea = chart.chartArea;\n var opts = chart.options;\n var minSize = Math.min(chartArea.right - chartArea.left, chartArea.bottom - chartArea.top);\n chart.outerRadius = Math.max(minSize / 2, 0);\n chart.innerRadius = Math.max(opts.cutoutPercentage ? chart.outerRadius / 100 * opts.cutoutPercentage : 1, 0);\n chart.radiusLength = (chart.outerRadius - chart.innerRadius) / chart.getVisibleDatasetCount();\n me.outerRadius = chart.outerRadius - chart.radiusLength * me.index;\n me.innerRadius = me.outerRadius - chart.radiusLength;\n },\n updateElement: function (arc, index, reset) {\n var me = this;\n var chart = me.chart;\n var dataset = me.getDataset();\n var opts = chart.options;\n var animationOpts = opts.animation;\n var scale = chart.scale;\n var labels = chart.data.labels;\n var centerX = scale.xCenter;\n var centerY = scale.yCenter;\n\n // var negHalfPI = -0.5 * Math.PI;\n var datasetStartAngle = opts.startAngle;\n var distance = arc.hidden ? 0 : scale.getDistanceFromCenterForValue(dataset.data[index]);\n var startAngle = me._starts[index];\n var endAngle = startAngle + (arc.hidden ? 0 : me._angles[index]);\n var resetRadius = animationOpts.animateScale ? 0 : scale.getDistanceFromCenterForValue(dataset.data[index]);\n var options = arc._options || {};\n helpers$1.extend(arc, {\n // Utility\n _datasetIndex: me.index,\n _index: index,\n _scale: scale,\n // Desired view properties\n _model: {\n backgroundColor: options.backgroundColor,\n borderColor: options.borderColor,\n borderWidth: options.borderWidth,\n borderAlign: options.borderAlign,\n x: centerX,\n y: centerY,\n innerRadius: 0,\n outerRadius: reset ? resetRadius : distance,\n startAngle: reset && animationOpts.animateRotate ? datasetStartAngle : startAngle,\n endAngle: reset && animationOpts.animateRotate ? datasetStartAngle : endAngle,\n label: helpers$1.valueAtIndexOrDefault(labels, index, labels[index])\n }\n });\n arc.pivot();\n },\n countVisibleElements: function () {\n var dataset = this.getDataset();\n var meta = this.getMeta();\n var count = 0;\n helpers$1.each(meta.data, function (element, index) {\n if (!isNaN(dataset.data[index]) && !element.hidden) {\n count++;\n }\n });\n return count;\n },\n /**\r\n * @protected\r\n */\n setHoverStyle: function (arc) {\n var model = arc._model;\n var options = arc._options;\n var getHoverColor = helpers$1.getHoverColor;\n var valueOrDefault = helpers$1.valueOrDefault;\n arc.$previousStyle = {\n backgroundColor: model.backgroundColor,\n borderColor: model.borderColor,\n borderWidth: model.borderWidth\n };\n model.backgroundColor = valueOrDefault(options.hoverBackgroundColor, getHoverColor(options.backgroundColor));\n model.borderColor = valueOrDefault(options.hoverBorderColor, getHoverColor(options.borderColor));\n model.borderWidth = valueOrDefault(options.hoverBorderWidth, options.borderWidth);\n },\n /**\r\n * @private\r\n */\n _computeAngle: function (index) {\n var me = this;\n var count = this.getMeta().count;\n var dataset = me.getDataset();\n var meta = me.getMeta();\n if (isNaN(dataset.data[index]) || meta.data[index].hidden) {\n return 0;\n }\n\n // Scriptable options\n var context = {\n chart: me.chart,\n dataIndex: index,\n dataset: dataset,\n datasetIndex: me.index\n };\n return resolve$3([me.chart.options.elements.arc.angle, 2 * Math.PI / count], context, index);\n }\n });\n core_defaults._set('pie', helpers$1.clone(core_defaults.doughnut));\n core_defaults._set('pie', {\n cutoutPercentage: 0\n });\n\n // Pie charts are Doughnut chart with different defaults\n var controller_pie = controller_doughnut;\n var valueOrDefault$7 = helpers$1.valueOrDefault;\n core_defaults._set('radar', {\n spanGaps: false,\n scale: {\n type: 'radialLinear'\n },\n elements: {\n line: {\n fill: 'start',\n tension: 0 // no bezier in radar\n }\n }\n });\n var controller_radar = core_datasetController.extend({\n datasetElementType: elements.Line,\n dataElementType: elements.Point,\n linkScales: helpers$1.noop,\n /**\r\n * @private\r\n */\n _datasetElementOptions: ['backgroundColor', 'borderWidth', 'borderColor', 'borderCapStyle', 'borderDash', 'borderDashOffset', 'borderJoinStyle', 'fill'],\n /**\r\n * @private\r\n */\n _dataElementOptions: {\n backgroundColor: 'pointBackgroundColor',\n borderColor: 'pointBorderColor',\n borderWidth: 'pointBorderWidth',\n hitRadius: 'pointHitRadius',\n hoverBackgroundColor: 'pointHoverBackgroundColor',\n hoverBorderColor: 'pointHoverBorderColor',\n hoverBorderWidth: 'pointHoverBorderWidth',\n hoverRadius: 'pointHoverRadius',\n pointStyle: 'pointStyle',\n radius: 'pointRadius',\n rotation: 'pointRotation'\n },\n /**\r\n * @private\r\n */\n _getIndexScaleId: function () {\n return this.chart.scale.id;\n },\n /**\r\n * @private\r\n */\n _getValueScaleId: function () {\n return this.chart.scale.id;\n },\n update: function (reset) {\n var me = this;\n var meta = me.getMeta();\n var line = meta.dataset;\n var points = meta.data || [];\n var scale = me.chart.scale;\n var config = me._config;\n var i, ilen;\n\n // Compatibility: If the properties are defined with only the old name, use those values\n if (config.tension !== undefined && config.lineTension === undefined) {\n config.lineTension = config.tension;\n }\n\n // Utility\n line._scale = scale;\n line._datasetIndex = me.index;\n // Data\n line._children = points;\n line._loop = true;\n // Model\n line._model = me._resolveDatasetElementOptions(line);\n line.pivot();\n\n // Update Points\n for (i = 0, ilen = points.length; i < ilen; ++i) {\n me.updateElement(points[i], i, reset);\n }\n\n // Update bezier control points\n me.updateBezierControlPoints();\n\n // Now pivot the point for animation\n for (i = 0, ilen = points.length; i < ilen; ++i) {\n points[i].pivot();\n }\n },\n updateElement: function (point, index, reset) {\n var me = this;\n var custom = point.custom || {};\n var dataset = me.getDataset();\n var scale = me.chart.scale;\n var pointPosition = scale.getPointPositionForValue(index, dataset.data[index]);\n var options = me._resolveDataElementOptions(point, index);\n var lineModel = me.getMeta().dataset._model;\n var x = reset ? scale.xCenter : pointPosition.x;\n var y = reset ? scale.yCenter : pointPosition.y;\n\n // Utility\n point._scale = scale;\n point._options = options;\n point._datasetIndex = me.index;\n point._index = index;\n\n // Desired view properties\n point._model = {\n x: x,\n // value not used in dataset scale, but we want a consistent API between scales\n y: y,\n skip: custom.skip || isNaN(x) || isNaN(y),\n // Appearance\n radius: options.radius,\n pointStyle: options.pointStyle,\n rotation: options.rotation,\n backgroundColor: options.backgroundColor,\n borderColor: options.borderColor,\n borderWidth: options.borderWidth,\n tension: valueOrDefault$7(custom.tension, lineModel ? lineModel.tension : 0),\n // Tooltip\n hitRadius: options.hitRadius\n };\n },\n /**\r\n * @private\r\n */\n _resolveDatasetElementOptions: function () {\n var me = this;\n var config = me._config;\n var options = me.chart.options;\n var values = core_datasetController.prototype._resolveDatasetElementOptions.apply(me, arguments);\n values.spanGaps = valueOrDefault$7(config.spanGaps, options.spanGaps);\n values.tension = valueOrDefault$7(config.lineTension, options.elements.line.tension);\n return values;\n },\n updateBezierControlPoints: function () {\n var me = this;\n var meta = me.getMeta();\n var area = me.chart.chartArea;\n var points = meta.data || [];\n var i, ilen, model, controlPoints;\n\n // Only consider points that are drawn in case the spanGaps option is used\n if (meta.dataset._model.spanGaps) {\n points = points.filter(function (pt) {\n return !pt._model.skip;\n });\n }\n function capControlPoint(pt, min, max) {\n return Math.max(Math.min(pt, max), min);\n }\n for (i = 0, ilen = points.length; i < ilen; ++i) {\n model = points[i]._model;\n controlPoints = helpers$1.splineCurve(helpers$1.previousItem(points, i, true)._model, model, helpers$1.nextItem(points, i, true)._model, model.tension);\n\n // Prevent the bezier going outside of the bounds of the graph\n model.controlPointPreviousX = capControlPoint(controlPoints.previous.x, area.left, area.right);\n model.controlPointPreviousY = capControlPoint(controlPoints.previous.y, area.top, area.bottom);\n model.controlPointNextX = capControlPoint(controlPoints.next.x, area.left, area.right);\n model.controlPointNextY = capControlPoint(controlPoints.next.y, area.top, area.bottom);\n }\n },\n setHoverStyle: function (point) {\n var model = point._model;\n var options = point._options;\n var getHoverColor = helpers$1.getHoverColor;\n point.$previousStyle = {\n backgroundColor: model.backgroundColor,\n borderColor: model.borderColor,\n borderWidth: model.borderWidth,\n radius: model.radius\n };\n model.backgroundColor = valueOrDefault$7(options.hoverBackgroundColor, getHoverColor(options.backgroundColor));\n model.borderColor = valueOrDefault$7(options.hoverBorderColor, getHoverColor(options.borderColor));\n model.borderWidth = valueOrDefault$7(options.hoverBorderWidth, options.borderWidth);\n model.radius = valueOrDefault$7(options.hoverRadius, options.radius);\n }\n });\n core_defaults._set('scatter', {\n hover: {\n mode: 'single'\n },\n scales: {\n xAxes: [{\n id: 'x-axis-1',\n // need an ID so datasets can reference the scale\n type: 'linear',\n // scatter should not use a category axis\n position: 'bottom'\n }],\n yAxes: [{\n id: 'y-axis-1',\n type: 'linear',\n position: 'left'\n }]\n },\n tooltips: {\n callbacks: {\n title: function () {\n return ''; // doesn't make sense for scatter since data are formatted as a point\n },\n label: function (item) {\n return '(' + item.xLabel + ', ' + item.yLabel + ')';\n }\n }\n }\n });\n core_defaults._set('global', {\n datasets: {\n scatter: {\n showLine: false\n }\n }\n });\n\n // Scatter charts use line controllers\n var controller_scatter = controller_line;\n\n // NOTE export a map in which the key represents the controller type, not\n // the class, and so must be CamelCase in order to be correctly retrieved\n // by the controller in core.controller.js (`controllers[meta.type]`).\n\n var controllers = {\n bar: controller_bar,\n bubble: controller_bubble,\n doughnut: controller_doughnut,\n horizontalBar: controller_horizontalBar,\n line: controller_line,\n polarArea: controller_polarArea,\n pie: controller_pie,\n radar: controller_radar,\n scatter: controller_scatter\n };\n\n /**\r\n * Helper function to get relative position for an event\r\n * @param {Event|IEvent} event - The event to get the position for\r\n * @param {Chart} chart - The chart\r\n * @returns {object} the event position\r\n */\n function getRelativePosition(e, chart) {\n if (e.native) {\n return {\n x: e.x,\n y: e.y\n };\n }\n return helpers$1.getRelativePosition(e, chart);\n }\n\n /**\r\n * Helper function to traverse all of the visible elements in the chart\r\n * @param {Chart} chart - the chart\r\n * @param {function} handler - the callback to execute for each visible item\r\n */\n function parseVisibleItems(chart, handler) {\n var metasets = chart._getSortedVisibleDatasetMetas();\n var metadata, i, j, ilen, jlen, element;\n for (i = 0, ilen = metasets.length; i < ilen; ++i) {\n metadata = metasets[i].data;\n for (j = 0, jlen = metadata.length; j < jlen; ++j) {\n element = metadata[j];\n if (!element._view.skip) {\n handler(element);\n }\n }\n }\n }\n\n /**\r\n * Helper function to get the items that intersect the event position\r\n * @param {ChartElement[]} items - elements to filter\r\n * @param {object} position - the point to be nearest to\r\n * @return {ChartElement[]} the nearest items\r\n */\n function getIntersectItems(chart, position) {\n var elements = [];\n parseVisibleItems(chart, function (element) {\n if (element.inRange(position.x, position.y)) {\n elements.push(element);\n }\n });\n return elements;\n }\n\n /**\r\n * Helper function to get the items nearest to the event position considering all visible items in teh chart\r\n * @param {Chart} chart - the chart to look at elements from\r\n * @param {object} position - the point to be nearest to\r\n * @param {boolean} intersect - if true, only consider items that intersect the position\r\n * @param {function} distanceMetric - function to provide the distance between points\r\n * @return {ChartElement[]} the nearest items\r\n */\n function getNearestItems(chart, position, intersect, distanceMetric) {\n var minDistance = Number.POSITIVE_INFINITY;\n var nearestItems = [];\n parseVisibleItems(chart, function (element) {\n if (intersect && !element.inRange(position.x, position.y)) {\n return;\n }\n var center = element.getCenterPoint();\n var distance = distanceMetric(position, center);\n if (distance < minDistance) {\n nearestItems = [element];\n minDistance = distance;\n } else if (distance === minDistance) {\n // Can have multiple items at the same distance in which case we sort by size\n nearestItems.push(element);\n }\n });\n return nearestItems;\n }\n\n /**\r\n * Get a distance metric function for two points based on the\r\n * axis mode setting\r\n * @param {string} axis - the axis mode. x|y|xy\r\n */\n function getDistanceMetricForAxis(axis) {\n var useX = axis.indexOf('x') !== -1;\n var useY = axis.indexOf('y') !== -1;\n return function (pt1, pt2) {\n var deltaX = useX ? Math.abs(pt1.x - pt2.x) : 0;\n var deltaY = useY ? Math.abs(pt1.y - pt2.y) : 0;\n return Math.sqrt(Math.pow(deltaX, 2) + Math.pow(deltaY, 2));\n };\n }\n function indexMode(chart, e, options) {\n var position = getRelativePosition(e, chart);\n // Default axis for index mode is 'x' to match old behaviour\n options.axis = options.axis || 'x';\n var distanceMetric = getDistanceMetricForAxis(options.axis);\n var items = options.intersect ? getIntersectItems(chart, position) : getNearestItems(chart, position, false, distanceMetric);\n var elements = [];\n if (!items.length) {\n return [];\n }\n chart._getSortedVisibleDatasetMetas().forEach(function (meta) {\n var element = meta.data[items[0]._index];\n\n // don't count items that are skipped (null data)\n if (element && !element._view.skip) {\n elements.push(element);\n }\n });\n return elements;\n }\n\n /**\r\n * @interface IInteractionOptions\r\n */\n /**\r\n * If true, only consider items that intersect the point\r\n * @name IInterfaceOptions#boolean\r\n * @type Boolean\r\n */\n\n /**\r\n * Contains interaction related functions\r\n * @namespace Chart.Interaction\r\n */\n var core_interaction = {\n // Helper function for different modes\n modes: {\n single: function (chart, e) {\n var position = getRelativePosition(e, chart);\n var elements = [];\n parseVisibleItems(chart, function (element) {\n if (element.inRange(position.x, position.y)) {\n elements.push(element);\n return elements;\n }\n });\n return elements.slice(0, 1);\n },\n /**\r\n * @function Chart.Interaction.modes.label\r\n * @deprecated since version 2.4.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n label: indexMode,\n /**\r\n * Returns items at the same index. If the options.intersect parameter is true, we only return items if we intersect something\r\n * If the options.intersect mode is false, we find the nearest item and return the items at the same index as that item\r\n * @function Chart.Interaction.modes.index\r\n * @since v2.4.0\r\n * @param {Chart} chart - the chart we are returning items from\r\n * @param {Event} e - the event we are find things at\r\n * @param {IInteractionOptions} options - options to use during interaction\r\n * @return {Chart.Element[]} Array of elements that are under the point. If none are found, an empty array is returned\r\n */\n index: indexMode,\n /**\r\n * Returns items in the same dataset. If the options.intersect parameter is true, we only return items if we intersect something\r\n * If the options.intersect is false, we find the nearest item and return the items in that dataset\r\n * @function Chart.Interaction.modes.dataset\r\n * @param {Chart} chart - the chart we are returning items from\r\n * @param {Event} e - the event we are find things at\r\n * @param {IInteractionOptions} options - options to use during interaction\r\n * @return {Chart.Element[]} Array of elements that are under the point. If none are found, an empty array is returned\r\n */\n dataset: function (chart, e, options) {\n var position = getRelativePosition(e, chart);\n options.axis = options.axis || 'xy';\n var distanceMetric = getDistanceMetricForAxis(options.axis);\n var items = options.intersect ? getIntersectItems(chart, position) : getNearestItems(chart, position, false, distanceMetric);\n if (items.length > 0) {\n items = chart.getDatasetMeta(items[0]._datasetIndex).data;\n }\n return items;\n },\n /**\r\n * @function Chart.Interaction.modes.x-axis\r\n * @deprecated since version 2.4.0. Use index mode and intersect == true\r\n * @todo remove at version 3\r\n * @private\r\n */\n 'x-axis': function (chart, e) {\n return indexMode(chart, e, {\n intersect: false\n });\n },\n /**\r\n * Point mode returns all elements that hit test based on the event position\r\n * of the event\r\n * @function Chart.Interaction.modes.intersect\r\n * @param {Chart} chart - the chart we are returning items from\r\n * @param {Event} e - the event we are find things at\r\n * @return {Chart.Element[]} Array of elements that are under the point. If none are found, an empty array is returned\r\n */\n point: function (chart, e) {\n var position = getRelativePosition(e, chart);\n return getIntersectItems(chart, position);\n },\n /**\r\n * nearest mode returns the element closest to the point\r\n * @function Chart.Interaction.modes.intersect\r\n * @param {Chart} chart - the chart we are returning items from\r\n * @param {Event} e - the event we are find things at\r\n * @param {IInteractionOptions} options - options to use\r\n * @return {Chart.Element[]} Array of elements that are under the point. If none are found, an empty array is returned\r\n */\n nearest: function (chart, e, options) {\n var position = getRelativePosition(e, chart);\n options.axis = options.axis || 'xy';\n var distanceMetric = getDistanceMetricForAxis(options.axis);\n return getNearestItems(chart, position, options.intersect, distanceMetric);\n },\n /**\r\n * x mode returns the elements that hit-test at the current x coordinate\r\n * @function Chart.Interaction.modes.x\r\n * @param {Chart} chart - the chart we are returning items from\r\n * @param {Event} e - the event we are find things at\r\n * @param {IInteractionOptions} options - options to use\r\n * @return {Chart.Element[]} Array of elements that are under the point. If none are found, an empty array is returned\r\n */\n x: function (chart, e, options) {\n var position = getRelativePosition(e, chart);\n var items = [];\n var intersectsItem = false;\n parseVisibleItems(chart, function (element) {\n if (element.inXRange(position.x)) {\n items.push(element);\n }\n if (element.inRange(position.x, position.y)) {\n intersectsItem = true;\n }\n });\n\n // If we want to trigger on an intersect and we don't have any items\n // that intersect the position, return nothing\n if (options.intersect && !intersectsItem) {\n items = [];\n }\n return items;\n },\n /**\r\n * y mode returns the elements that hit-test at the current y coordinate\r\n * @function Chart.Interaction.modes.y\r\n * @param {Chart} chart - the chart we are returning items from\r\n * @param {Event} e - the event we are find things at\r\n * @param {IInteractionOptions} options - options to use\r\n * @return {Chart.Element[]} Array of elements that are under the point. If none are found, an empty array is returned\r\n */\n y: function (chart, e, options) {\n var position = getRelativePosition(e, chart);\n var items = [];\n var intersectsItem = false;\n parseVisibleItems(chart, function (element) {\n if (element.inYRange(position.y)) {\n items.push(element);\n }\n if (element.inRange(position.x, position.y)) {\n intersectsItem = true;\n }\n });\n\n // If we want to trigger on an intersect and we don't have any items\n // that intersect the position, return nothing\n if (options.intersect && !intersectsItem) {\n items = [];\n }\n return items;\n }\n }\n };\n var extend = helpers$1.extend;\n function filterByPosition(array, position) {\n return helpers$1.where(array, function (v) {\n return v.pos === position;\n });\n }\n function sortByWeight(array, reverse) {\n return array.sort(function (a, b) {\n var v0 = reverse ? b : a;\n var v1 = reverse ? a : b;\n return v0.weight === v1.weight ? v0.index - v1.index : v0.weight - v1.weight;\n });\n }\n function wrapBoxes(boxes) {\n var layoutBoxes = [];\n var i, ilen, box;\n for (i = 0, ilen = (boxes || []).length; i < ilen; ++i) {\n box = boxes[i];\n layoutBoxes.push({\n index: i,\n box: box,\n pos: box.position,\n horizontal: box.isHorizontal(),\n weight: box.weight\n });\n }\n return layoutBoxes;\n }\n function setLayoutDims(layouts, params) {\n var i, ilen, layout;\n for (i = 0, ilen = layouts.length; i < ilen; ++i) {\n layout = layouts[i];\n // store width used instead of chartArea.w in fitBoxes\n layout.width = layout.horizontal ? layout.box.fullWidth && params.availableWidth : params.vBoxMaxWidth;\n // store height used instead of chartArea.h in fitBoxes\n layout.height = layout.horizontal && params.hBoxMaxHeight;\n }\n }\n function buildLayoutBoxes(boxes) {\n var layoutBoxes = wrapBoxes(boxes);\n var left = sortByWeight(filterByPosition(layoutBoxes, 'left'), true);\n var right = sortByWeight(filterByPosition(layoutBoxes, 'right'));\n var top = sortByWeight(filterByPosition(layoutBoxes, 'top'), true);\n var bottom = sortByWeight(filterByPosition(layoutBoxes, 'bottom'));\n return {\n leftAndTop: left.concat(top),\n rightAndBottom: right.concat(bottom),\n chartArea: filterByPosition(layoutBoxes, 'chartArea'),\n vertical: left.concat(right),\n horizontal: top.concat(bottom)\n };\n }\n function getCombinedMax(maxPadding, chartArea, a, b) {\n return Math.max(maxPadding[a], chartArea[a]) + Math.max(maxPadding[b], chartArea[b]);\n }\n function updateDims(chartArea, params, layout) {\n var box = layout.box;\n var maxPadding = chartArea.maxPadding;\n var newWidth, newHeight;\n if (layout.size) {\n // this layout was already counted for, lets first reduce old size\n chartArea[layout.pos] -= layout.size;\n }\n layout.size = layout.horizontal ? box.height : box.width;\n chartArea[layout.pos] += layout.size;\n if (box.getPadding) {\n var boxPadding = box.getPadding();\n maxPadding.top = Math.max(maxPadding.top, boxPadding.top);\n maxPadding.left = Math.max(maxPadding.left, boxPadding.left);\n maxPadding.bottom = Math.max(maxPadding.bottom, boxPadding.bottom);\n maxPadding.right = Math.max(maxPadding.right, boxPadding.right);\n }\n newWidth = params.outerWidth - getCombinedMax(maxPadding, chartArea, 'left', 'right');\n newHeight = params.outerHeight - getCombinedMax(maxPadding, chartArea, 'top', 'bottom');\n if (newWidth !== chartArea.w || newHeight !== chartArea.h) {\n chartArea.w = newWidth;\n chartArea.h = newHeight;\n\n // return true if chart area changed in layout's direction\n var sizes = layout.horizontal ? [newWidth, chartArea.w] : [newHeight, chartArea.h];\n return sizes[0] !== sizes[1] && (!isNaN(sizes[0]) || !isNaN(sizes[1]));\n }\n }\n function handleMaxPadding(chartArea) {\n var maxPadding = chartArea.maxPadding;\n function updatePos(pos) {\n var change = Math.max(maxPadding[pos] - chartArea[pos], 0);\n chartArea[pos] += change;\n return change;\n }\n chartArea.y += updatePos('top');\n chartArea.x += updatePos('left');\n updatePos('right');\n updatePos('bottom');\n }\n function getMargins(horizontal, chartArea) {\n var maxPadding = chartArea.maxPadding;\n function marginForPositions(positions) {\n var margin = {\n left: 0,\n top: 0,\n right: 0,\n bottom: 0\n };\n positions.forEach(function (pos) {\n margin[pos] = Math.max(chartArea[pos], maxPadding[pos]);\n });\n return margin;\n }\n return horizontal ? marginForPositions(['left', 'right']) : marginForPositions(['top', 'bottom']);\n }\n function fitBoxes(boxes, chartArea, params) {\n var refitBoxes = [];\n var i, ilen, layout, box, refit, changed;\n for (i = 0, ilen = boxes.length; i < ilen; ++i) {\n layout = boxes[i];\n box = layout.box;\n box.update(layout.width || chartArea.w, layout.height || chartArea.h, getMargins(layout.horizontal, chartArea));\n if (updateDims(chartArea, params, layout)) {\n changed = true;\n if (refitBoxes.length) {\n // Dimensions changed and there were non full width boxes before this\n // -> we have to refit those\n refit = true;\n }\n }\n if (!box.fullWidth) {\n // fullWidth boxes don't need to be re-fitted in any case\n refitBoxes.push(layout);\n }\n }\n return refit ? fitBoxes(refitBoxes, chartArea, params) || changed : changed;\n }\n function placeBoxes(boxes, chartArea, params) {\n var userPadding = params.padding;\n var x = chartArea.x;\n var y = chartArea.y;\n var i, ilen, layout, box;\n for (i = 0, ilen = boxes.length; i < ilen; ++i) {\n layout = boxes[i];\n box = layout.box;\n if (layout.horizontal) {\n box.left = box.fullWidth ? userPadding.left : chartArea.left;\n box.right = box.fullWidth ? params.outerWidth - userPadding.right : chartArea.left + chartArea.w;\n box.top = y;\n box.bottom = y + box.height;\n box.width = box.right - box.left;\n y = box.bottom;\n } else {\n box.left = x;\n box.right = x + box.width;\n box.top = chartArea.top;\n box.bottom = chartArea.top + chartArea.h;\n box.height = box.bottom - box.top;\n x = box.right;\n }\n }\n chartArea.x = x;\n chartArea.y = y;\n }\n core_defaults._set('global', {\n layout: {\n padding: {\n top: 0,\n right: 0,\n bottom: 0,\n left: 0\n }\n }\n });\n\n /**\r\n * @interface ILayoutItem\r\n * @prop {string} position - The position of the item in the chart layout. Possible values are\r\n * 'left', 'top', 'right', 'bottom', and 'chartArea'\r\n * @prop {number} weight - The weight used to sort the item. Higher weights are further away from the chart area\r\n * @prop {boolean} fullWidth - if true, and the item is horizontal, then push vertical boxes down\r\n * @prop {function} isHorizontal - returns true if the layout item is horizontal (ie. top or bottom)\r\n * @prop {function} update - Takes two parameters: width and height. Returns size of item\r\n * @prop {function} getPadding - Returns an object with padding on the edges\r\n * @prop {number} width - Width of item. Must be valid after update()\r\n * @prop {number} height - Height of item. Must be valid after update()\r\n * @prop {number} left - Left edge of the item. Set by layout system and cannot be used in update\r\n * @prop {number} top - Top edge of the item. Set by layout system and cannot be used in update\r\n * @prop {number} right - Right edge of the item. Set by layout system and cannot be used in update\r\n * @prop {number} bottom - Bottom edge of the item. Set by layout system and cannot be used in update\r\n */\n\n // The layout service is very self explanatory. It's responsible for the layout within a chart.\n // Scales, Legends and Plugins all rely on the layout service and can easily register to be placed anywhere they need\n // It is this service's responsibility of carrying out that layout.\n var core_layouts = {\n defaults: {},\n /**\r\n * Register a box to a chart.\r\n * A box is simply a reference to an object that requires layout. eg. Scales, Legend, Title.\r\n * @param {Chart} chart - the chart to use\r\n * @param {ILayoutItem} item - the item to add to be layed out\r\n */\n addBox: function (chart, item) {\n if (!chart.boxes) {\n chart.boxes = [];\n }\n\n // initialize item with default values\n item.fullWidth = item.fullWidth || false;\n item.position = item.position || 'top';\n item.weight = item.weight || 0;\n item._layers = item._layers || function () {\n return [{\n z: 0,\n draw: function () {\n item.draw.apply(item, arguments);\n }\n }];\n };\n chart.boxes.push(item);\n },\n /**\r\n * Remove a layoutItem from a chart\r\n * @param {Chart} chart - the chart to remove the box from\r\n * @param {ILayoutItem} layoutItem - the item to remove from the layout\r\n */\n removeBox: function (chart, layoutItem) {\n var index = chart.boxes ? chart.boxes.indexOf(layoutItem) : -1;\n if (index !== -1) {\n chart.boxes.splice(index, 1);\n }\n },\n /**\r\n * Sets (or updates) options on the given `item`.\r\n * @param {Chart} chart - the chart in which the item lives (or will be added to)\r\n * @param {ILayoutItem} item - the item to configure with the given options\r\n * @param {object} options - the new item options.\r\n */\n configure: function (chart, item, options) {\n var props = ['fullWidth', 'position', 'weight'];\n var ilen = props.length;\n var i = 0;\n var prop;\n for (; i < ilen; ++i) {\n prop = props[i];\n if (options.hasOwnProperty(prop)) {\n item[prop] = options[prop];\n }\n }\n },\n /**\r\n * Fits boxes of the given chart into the given size by having each box measure itself\r\n * then running a fitting algorithm\r\n * @param {Chart} chart - the chart\r\n * @param {number} width - the width to fit into\r\n * @param {number} height - the height to fit into\r\n */\n update: function (chart, width, height) {\n if (!chart) {\n return;\n }\n var layoutOptions = chart.options.layout || {};\n var padding = helpers$1.options.toPadding(layoutOptions.padding);\n var availableWidth = width - padding.width;\n var availableHeight = height - padding.height;\n var boxes = buildLayoutBoxes(chart.boxes);\n var verticalBoxes = boxes.vertical;\n var horizontalBoxes = boxes.horizontal;\n\n // Essentially we now have any number of boxes on each of the 4 sides.\n // Our canvas looks like the following.\n // The areas L1 and L2 are the left axes. R1 is the right axis, T1 is the top axis and\n // B1 is the bottom axis\n // There are also 4 quadrant-like locations (left to right instead of clockwise) reserved for chart overlays\n // These locations are single-box locations only, when trying to register a chartArea location that is already taken,\n // an error will be thrown.\n //\n // |----------------------------------------------------|\n // | T1 (Full Width) |\n // |----------------------------------------------------|\n // | | | T2 | |\n // | |----|-------------------------------------|----|\n // | | | C1 | | C2 | |\n // | | |----| |----| |\n // | | | | |\n // | L1 | L2 | ChartArea (C0) | R1 |\n // | | | | |\n // | | |----| |----| |\n // | | | C3 | | C4 | |\n // | |----|-------------------------------------|----|\n // | | | B1 | |\n // |----------------------------------------------------|\n // | B2 (Full Width) |\n // |----------------------------------------------------|\n //\n\n var params = Object.freeze({\n outerWidth: width,\n outerHeight: height,\n padding: padding,\n availableWidth: availableWidth,\n vBoxMaxWidth: availableWidth / 2 / verticalBoxes.length,\n hBoxMaxHeight: availableHeight / 2\n });\n var chartArea = extend({\n maxPadding: extend({}, padding),\n w: availableWidth,\n h: availableHeight,\n x: padding.left,\n y: padding.top\n }, padding);\n setLayoutDims(verticalBoxes.concat(horizontalBoxes), params);\n\n // First fit vertical boxes\n fitBoxes(verticalBoxes, chartArea, params);\n\n // Then fit horizontal boxes\n if (fitBoxes(horizontalBoxes, chartArea, params)) {\n // if the area changed, re-fit vertical boxes\n fitBoxes(verticalBoxes, chartArea, params);\n }\n handleMaxPadding(chartArea);\n\n // Finally place the boxes to correct coordinates\n placeBoxes(boxes.leftAndTop, chartArea, params);\n\n // Move to opposite side of chart\n chartArea.x += chartArea.w;\n chartArea.y += chartArea.h;\n placeBoxes(boxes.rightAndBottom, chartArea, params);\n chart.chartArea = {\n left: chartArea.left,\n top: chartArea.top,\n right: chartArea.left + chartArea.w,\n bottom: chartArea.top + chartArea.h\n };\n\n // Finally update boxes in chartArea (radial scale for example)\n helpers$1.each(boxes.chartArea, function (layout) {\n var box = layout.box;\n extend(box, chart.chartArea);\n box.update(chartArea.w, chartArea.h);\n });\n }\n };\n\n /**\r\n * Platform fallback implementation (minimal).\r\n * @see https://github.com/chartjs/Chart.js/pull/4591#issuecomment-319575939\r\n */\n\n var platform_basic = {\n acquireContext: function (item) {\n if (item && item.canvas) {\n // Support for any object associated to a canvas (including a context2d)\n item = item.canvas;\n }\n return item && item.getContext('2d') || null;\n }\n };\n var platform_dom = \"/*\\r\\n * DOM element rendering detection\\r\\n * https://davidwalsh.name/detect-node-insertion\\r\\n */\\r\\n@keyframes chartjs-render-animation {\\r\\n\\tfrom { opacity: 0.99; }\\r\\n\\tto { opacity: 1; }\\r\\n}\\r\\n\\r\\n.chartjs-render-monitor {\\r\\n\\tanimation: chartjs-render-animation 0.001s;\\r\\n}\\r\\n\\r\\n/*\\r\\n * DOM element resizing detection\\r\\n * https://github.com/marcj/css-element-queries\\r\\n */\\r\\n.chartjs-size-monitor,\\r\\n.chartjs-size-monitor-expand,\\r\\n.chartjs-size-monitor-shrink {\\r\\n\\tposition: absolute;\\r\\n\\tdirection: ltr;\\r\\n\\tleft: 0;\\r\\n\\ttop: 0;\\r\\n\\tright: 0;\\r\\n\\tbottom: 0;\\r\\n\\toverflow: hidden;\\r\\n\\tpointer-events: none;\\r\\n\\tvisibility: hidden;\\r\\n\\tz-index: -1;\\r\\n}\\r\\n\\r\\n.chartjs-size-monitor-expand > div {\\r\\n\\tposition: absolute;\\r\\n\\twidth: 1000000px;\\r\\n\\theight: 1000000px;\\r\\n\\tleft: 0;\\r\\n\\ttop: 0;\\r\\n}\\r\\n\\r\\n.chartjs-size-monitor-shrink > div {\\r\\n\\tposition: absolute;\\r\\n\\twidth: 200%;\\r\\n\\theight: 200%;\\r\\n\\tleft: 0;\\r\\n\\ttop: 0;\\r\\n}\\r\\n\";\n var platform_dom$1 = /*#__PURE__*/Object.freeze({\n __proto__: null,\n 'default': platform_dom\n });\n var stylesheet = getCjsExportFromNamespace(platform_dom$1);\n var EXPANDO_KEY = '$chartjs';\n var CSS_PREFIX = 'chartjs-';\n var CSS_SIZE_MONITOR = CSS_PREFIX + 'size-monitor';\n var CSS_RENDER_MONITOR = CSS_PREFIX + 'render-monitor';\n var CSS_RENDER_ANIMATION = CSS_PREFIX + 'render-animation';\n var ANIMATION_START_EVENTS = ['animationstart', 'webkitAnimationStart'];\n\n /**\r\n * DOM event types -> Chart.js event types.\r\n * Note: only events with different types are mapped.\r\n * @see https://developer.mozilla.org/en-US/docs/Web/Events\r\n */\n var EVENT_TYPES = {\n touchstart: 'mousedown',\n touchmove: 'mousemove',\n touchend: 'mouseup',\n pointerenter: 'mouseenter',\n pointerdown: 'mousedown',\n pointermove: 'mousemove',\n pointerup: 'mouseup',\n pointerleave: 'mouseout',\n pointerout: 'mouseout'\n };\n\n /**\r\n * The \"used\" size is the final value of a dimension property after all calculations have\r\n * been performed. This method uses the computed style of `element` but returns undefined\r\n * if the computed style is not expressed in pixels. That can happen in some cases where\r\n * `element` has a size relative to its parent and this last one is not yet displayed,\r\n * for example because of `display: none` on a parent node.\r\n * @see https://developer.mozilla.org/en-US/docs/Web/CSS/used_value\r\n * @returns {number} Size in pixels or undefined if unknown.\r\n */\n function readUsedSize(element, property) {\n var value = helpers$1.getStyle(element, property);\n var matches = value && value.match(/^(\\d+)(\\.\\d+)?px$/);\n return matches ? Number(matches[1]) : undefined;\n }\n\n /**\r\n * Initializes the canvas style and render size without modifying the canvas display size,\r\n * since responsiveness is handled by the controller.resize() method. The config is used\r\n * to determine the aspect ratio to apply in case no explicit height has been specified.\r\n */\n function initCanvas(canvas, config) {\n var style = canvas.style;\n\n // NOTE(SB) canvas.getAttribute('width') !== canvas.width: in the first case it\n // returns null or '' if no explicit value has been set to the canvas attribute.\n var renderHeight = canvas.getAttribute('height');\n var renderWidth = canvas.getAttribute('width');\n\n // Chart.js modifies some canvas values that we want to restore on destroy\n canvas[EXPANDO_KEY] = {\n initial: {\n height: renderHeight,\n width: renderWidth,\n style: {\n display: style.display,\n height: style.height,\n width: style.width\n }\n }\n };\n\n // Force canvas to display as block to avoid extra space caused by inline\n // elements, which would interfere with the responsive resize process.\n // https://github.com/chartjs/Chart.js/issues/2538\n style.display = style.display || 'block';\n if (renderWidth === null || renderWidth === '') {\n var displayWidth = readUsedSize(canvas, 'width');\n if (displayWidth !== undefined) {\n canvas.width = displayWidth;\n }\n }\n if (renderHeight === null || renderHeight === '') {\n if (canvas.style.height === '') {\n // If no explicit render height and style height, let's apply the aspect ratio,\n // which one can be specified by the user but also by charts as default option\n // (i.e. options.aspectRatio). If not specified, use canvas aspect ratio of 2.\n canvas.height = canvas.width / (config.options.aspectRatio || 2);\n } else {\n var displayHeight = readUsedSize(canvas, 'height');\n if (displayWidth !== undefined) {\n canvas.height = displayHeight;\n }\n }\n }\n return canvas;\n }\n\n /**\r\n * Detects support for options object argument in addEventListener.\r\n * https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener#Safely_detecting_option_support\r\n * @private\r\n */\n var supportsEventListenerOptions = function () {\n var supports = false;\n try {\n var options = Object.defineProperty({}, 'passive', {\n // eslint-disable-next-line getter-return\n get: function () {\n supports = true;\n }\n });\n window.addEventListener('e', null, options);\n } catch (e) {\n // continue regardless of error\n }\n return supports;\n }();\n\n // Default passive to true as expected by Chrome for 'touchstart' and 'touchend' events.\n // https://github.com/chartjs/Chart.js/issues/4287\n var eventListenerOptions = supportsEventListenerOptions ? {\n passive: true\n } : false;\n function addListener(node, type, listener) {\n node.addEventListener(type, listener, eventListenerOptions);\n }\n function removeListener(node, type, listener) {\n node.removeEventListener(type, listener, eventListenerOptions);\n }\n function createEvent(type, chart, x, y, nativeEvent) {\n return {\n type: type,\n chart: chart,\n native: nativeEvent || null,\n x: x !== undefined ? x : null,\n y: y !== undefined ? y : null\n };\n }\n function fromNativeEvent(event, chart) {\n var type = EVENT_TYPES[event.type] || event.type;\n var pos = helpers$1.getRelativePosition(event, chart);\n return createEvent(type, chart, pos.x, pos.y, event);\n }\n function throttled(fn, thisArg) {\n var ticking = false;\n var args = [];\n return function () {\n args = Array.prototype.slice.call(arguments);\n thisArg = thisArg || this;\n if (!ticking) {\n ticking = true;\n helpers$1.requestAnimFrame.call(window, function () {\n ticking = false;\n fn.apply(thisArg, args);\n });\n }\n };\n }\n function createDiv(cls) {\n var el = document.createElement('div');\n el.className = cls || '';\n return el;\n }\n\n // Implementation based on https://github.com/marcj/css-element-queries\n function createResizer(handler) {\n var maxSize = 1000000;\n\n // NOTE(SB) Don't use innerHTML because it could be considered unsafe.\n // https://github.com/chartjs/Chart.js/issues/5902\n var resizer = createDiv(CSS_SIZE_MONITOR);\n var expand = createDiv(CSS_SIZE_MONITOR + '-expand');\n var shrink = createDiv(CSS_SIZE_MONITOR + '-shrink');\n expand.appendChild(createDiv());\n shrink.appendChild(createDiv());\n resizer.appendChild(expand);\n resizer.appendChild(shrink);\n resizer._reset = function () {\n expand.scrollLeft = maxSize;\n expand.scrollTop = maxSize;\n shrink.scrollLeft = maxSize;\n shrink.scrollTop = maxSize;\n };\n var onScroll = function () {\n resizer._reset();\n handler();\n };\n addListener(expand, 'scroll', onScroll.bind(expand, 'expand'));\n addListener(shrink, 'scroll', onScroll.bind(shrink, 'shrink'));\n return resizer;\n }\n\n // https://davidwalsh.name/detect-node-insertion\n function watchForRender(node, handler) {\n var expando = node[EXPANDO_KEY] || (node[EXPANDO_KEY] = {});\n var proxy = expando.renderProxy = function (e) {\n if (e.animationName === CSS_RENDER_ANIMATION) {\n handler();\n }\n };\n helpers$1.each(ANIMATION_START_EVENTS, function (type) {\n addListener(node, type, proxy);\n });\n\n // #4737: Chrome might skip the CSS animation when the CSS_RENDER_MONITOR class\n // is removed then added back immediately (same animation frame?). Accessing the\n // `offsetParent` property will force a reflow and re-evaluate the CSS animation.\n // https://gist.github.com/paulirish/5d52fb081b3570c81e3a#box-metrics\n // https://github.com/chartjs/Chart.js/issues/4737\n expando.reflow = !!node.offsetParent;\n node.classList.add(CSS_RENDER_MONITOR);\n }\n function unwatchForRender(node) {\n var expando = node[EXPANDO_KEY] || {};\n var proxy = expando.renderProxy;\n if (proxy) {\n helpers$1.each(ANIMATION_START_EVENTS, function (type) {\n removeListener(node, type, proxy);\n });\n delete expando.renderProxy;\n }\n node.classList.remove(CSS_RENDER_MONITOR);\n }\n function addResizeListener(node, listener, chart) {\n var expando = node[EXPANDO_KEY] || (node[EXPANDO_KEY] = {});\n\n // Let's keep track of this added resizer and thus avoid DOM query when removing it.\n var resizer = expando.resizer = createResizer(throttled(function () {\n if (expando.resizer) {\n var container = chart.options.maintainAspectRatio && node.parentNode;\n var w = container ? container.clientWidth : 0;\n listener(createEvent('resize', chart));\n if (container && container.clientWidth < w && chart.canvas) {\n // If the container size shrank during chart resize, let's assume\n // scrollbar appeared. So we resize again with the scrollbar visible -\n // effectively making chart smaller and the scrollbar hidden again.\n // Because we are inside `throttled`, and currently `ticking`, scroll\n // events are ignored during this whole 2 resize process.\n // If we assumed wrong and something else happened, we are resizing\n // twice in a frame (potential performance issue)\n listener(createEvent('resize', chart));\n }\n }\n }));\n\n // The resizer needs to be attached to the node parent, so we first need to be\n // sure that `node` is attached to the DOM before injecting the resizer element.\n watchForRender(node, function () {\n if (expando.resizer) {\n var container = node.parentNode;\n if (container && container !== resizer.parentNode) {\n container.insertBefore(resizer, container.firstChild);\n }\n\n // The container size might have changed, let's reset the resizer state.\n resizer._reset();\n }\n });\n }\n function removeResizeListener(node) {\n var expando = node[EXPANDO_KEY] || {};\n var resizer = expando.resizer;\n delete expando.resizer;\n unwatchForRender(node);\n if (resizer && resizer.parentNode) {\n resizer.parentNode.removeChild(resizer);\n }\n }\n\n /**\r\n * Injects CSS styles inline if the styles are not already present.\r\n * @param {HTMLDocument|ShadowRoot} rootNode - the node to contain the <style>.\r\n * @param {string} css - the CSS to be injected.\r\n */\n function injectCSS(rootNode, css) {\n // https://stackoverflow.com/q/3922139\n var expando = rootNode[EXPANDO_KEY] || (rootNode[EXPANDO_KEY] = {});\n if (!expando.containsStyles) {\n expando.containsStyles = true;\n css = '/* Chart.js */\\n' + css;\n var style = document.createElement('style');\n style.setAttribute('type', 'text/css');\n style.appendChild(document.createTextNode(css));\n rootNode.appendChild(style);\n }\n }\n var platform_dom$2 = {\n /**\r\n * When `true`, prevents the automatic injection of the stylesheet required to\r\n * correctly detect when the chart is added to the DOM and then resized. This\r\n * switch has been added to allow external stylesheet (`dist/Chart(.min)?.js`)\r\n * to be manually imported to make this library compatible with any CSP.\r\n * See https://github.com/chartjs/Chart.js/issues/5208\r\n */\n disableCSSInjection: false,\n /**\r\n * This property holds whether this platform is enabled for the current environment.\r\n * Currently used by platform.js to select the proper implementation.\r\n * @private\r\n */\n _enabled: typeof window !== 'undefined' && typeof document !== 'undefined',\n /**\r\n * Initializes resources that depend on platform options.\r\n * @param {HTMLCanvasElement} canvas - The Canvas element.\r\n * @private\r\n */\n _ensureLoaded: function (canvas) {\n if (!this.disableCSSInjection) {\n // If the canvas is in a shadow DOM, then the styles must also be inserted\n // into the same shadow DOM.\n // https://github.com/chartjs/Chart.js/issues/5763\n var root = canvas.getRootNode ? canvas.getRootNode() : document;\n var targetNode = root.host ? root : document.head;\n injectCSS(targetNode, stylesheet);\n }\n },\n acquireContext: function (item, config) {\n if (typeof item === 'string') {\n item = document.getElementById(item);\n } else if (item.length) {\n // Support for array based queries (such as jQuery)\n item = item[0];\n }\n if (item && item.canvas) {\n // Support for any object associated to a canvas (including a context2d)\n item = item.canvas;\n }\n\n // To prevent canvas fingerprinting, some add-ons undefine the getContext\n // method, for example: https://github.com/kkapsner/CanvasBlocker\n // https://github.com/chartjs/Chart.js/issues/2807\n var context = item && item.getContext && item.getContext('2d');\n\n // `instanceof HTMLCanvasElement/CanvasRenderingContext2D` fails when the item is\n // inside an iframe or when running in a protected environment. We could guess the\n // types from their toString() value but let's keep things flexible and assume it's\n // a sufficient condition if the item has a context2D which has item as `canvas`.\n // https://github.com/chartjs/Chart.js/issues/3887\n // https://github.com/chartjs/Chart.js/issues/4102\n // https://github.com/chartjs/Chart.js/issues/4152\n if (context && context.canvas === item) {\n // Load platform resources on first chart creation, to make it possible to\n // import the library before setting platform options.\n this._ensureLoaded(item);\n initCanvas(item, config);\n return context;\n }\n return null;\n },\n releaseContext: function (context) {\n var canvas = context.canvas;\n if (!canvas[EXPANDO_KEY]) {\n return;\n }\n var initial = canvas[EXPANDO_KEY].initial;\n ['height', 'width'].forEach(function (prop) {\n var value = initial[prop];\n if (helpers$1.isNullOrUndef(value)) {\n canvas.removeAttribute(prop);\n } else {\n canvas.setAttribute(prop, value);\n }\n });\n helpers$1.each(initial.style || {}, function (value, key) {\n canvas.style[key] = value;\n });\n\n // The canvas render size might have been changed (and thus the state stack discarded),\n // we can't use save() and restore() to restore the initial state. So make sure that at\n // least the canvas context is reset to the default state by setting the canvas width.\n // https://www.w3.org/TR/2011/WD-html5-20110525/the-canvas-element.html\n // eslint-disable-next-line no-self-assign\n canvas.width = canvas.width;\n delete canvas[EXPANDO_KEY];\n },\n addEventListener: function (chart, type, listener) {\n var canvas = chart.canvas;\n if (type === 'resize') {\n // Note: the resize event is not supported on all browsers.\n addResizeListener(canvas, listener, chart);\n return;\n }\n var expando = listener[EXPANDO_KEY] || (listener[EXPANDO_KEY] = {});\n var proxies = expando.proxies || (expando.proxies = {});\n var proxy = proxies[chart.id + '_' + type] = function (event) {\n listener(fromNativeEvent(event, chart));\n };\n addListener(canvas, type, proxy);\n },\n removeEventListener: function (chart, type, listener) {\n var canvas = chart.canvas;\n if (type === 'resize') {\n // Note: the resize event is not supported on all browsers.\n removeResizeListener(canvas);\n return;\n }\n var expando = listener[EXPANDO_KEY] || {};\n var proxies = expando.proxies || {};\n var proxy = proxies[chart.id + '_' + type];\n if (!proxy) {\n return;\n }\n removeListener(canvas, type, proxy);\n }\n };\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, use EventTarget.addEventListener instead.\r\n * EventTarget.addEventListener compatibility: Chrome, Opera 7, Safari, FF1.5+, IE9+\r\n * @see https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener\r\n * @function Chart.helpers.addEvent\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers$1.addEvent = addListener;\n\n /**\r\n * Provided for backward compatibility, use EventTarget.removeEventListener instead.\r\n * EventTarget.removeEventListener compatibility: Chrome, Opera 7, Safari, FF1.5+, IE9+\r\n * @see https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/removeEventListener\r\n * @function Chart.helpers.removeEvent\r\n * @deprecated since version 2.7.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers$1.removeEvent = removeListener;\n\n // @TODO Make possible to select another platform at build time.\n var implementation = platform_dom$2._enabled ? platform_dom$2 : platform_basic;\n\n /**\r\n * @namespace Chart.platform\r\n * @see https://chartjs.gitbooks.io/proposals/content/Platform.html\r\n * @since 2.4.0\r\n */\n var platform = helpers$1.extend({\n /**\r\n * @since 2.7.0\r\n */\n initialize: function () {},\n /**\r\n * Called at chart construction time, returns a context2d instance implementing\r\n * the [W3C Canvas 2D Context API standard]{@link https://www.w3.org/TR/2dcontext/}.\r\n * @param {*} item - The native item from which to acquire context (platform specific)\r\n * @param {object} options - The chart options\r\n * @returns {CanvasRenderingContext2D} context2d instance\r\n */\n acquireContext: function () {},\n /**\r\n * Called at chart destruction time, releases any resources associated to the context\r\n * previously returned by the acquireContext() method.\r\n * @param {CanvasRenderingContext2D} context - The context2d instance\r\n * @returns {boolean} true if the method succeeded, else false\r\n */\n releaseContext: function () {},\n /**\r\n * Registers the specified listener on the given chart.\r\n * @param {Chart} chart - Chart from which to listen for event\r\n * @param {string} type - The ({@link IEvent}) type to listen for\r\n * @param {function} listener - Receives a notification (an object that implements\r\n * the {@link IEvent} interface) when an event of the specified type occurs.\r\n */\n addEventListener: function () {},\n /**\r\n * Removes the specified listener previously registered with addEventListener.\r\n * @param {Chart} chart - Chart from which to remove the listener\r\n * @param {string} type - The ({@link IEvent}) type to remove\r\n * @param {function} listener - The listener function to remove from the event target.\r\n */\n removeEventListener: function () {}\n }, implementation);\n core_defaults._set('global', {\n plugins: {}\n });\n\n /**\r\n * The plugin service singleton\r\n * @namespace Chart.plugins\r\n * @since 2.1.0\r\n */\n var core_plugins = {\n /**\r\n * Globally registered plugins.\r\n * @private\r\n */\n _plugins: [],\n /**\r\n * This identifier is used to invalidate the descriptors cache attached to each chart\r\n * when a global plugin is registered or unregistered. In this case, the cache ID is\r\n * incremented and descriptors are regenerated during following API calls.\r\n * @private\r\n */\n _cacheId: 0,\n /**\r\n * Registers the given plugin(s) if not already registered.\r\n * @param {IPlugin[]|IPlugin} plugins plugin instance(s).\r\n */\n register: function (plugins) {\n var p = this._plugins;\n [].concat(plugins).forEach(function (plugin) {\n if (p.indexOf(plugin) === -1) {\n p.push(plugin);\n }\n });\n this._cacheId++;\n },\n /**\r\n * Unregisters the given plugin(s) only if registered.\r\n * @param {IPlugin[]|IPlugin} plugins plugin instance(s).\r\n */\n unregister: function (plugins) {\n var p = this._plugins;\n [].concat(plugins).forEach(function (plugin) {\n var idx = p.indexOf(plugin);\n if (idx !== -1) {\n p.splice(idx, 1);\n }\n });\n this._cacheId++;\n },\n /**\r\n * Remove all registered plugins.\r\n * @since 2.1.5\r\n */\n clear: function () {\n this._plugins = [];\n this._cacheId++;\n },\n /**\r\n * Returns the number of registered plugins?\r\n * @returns {number}\r\n * @since 2.1.5\r\n */\n count: function () {\n return this._plugins.length;\n },\n /**\r\n * Returns all registered plugin instances.\r\n * @returns {IPlugin[]} array of plugin objects.\r\n * @since 2.1.5\r\n */\n getAll: function () {\n return this._plugins;\n },\n /**\r\n * Calls enabled plugins for `chart` on the specified hook and with the given args.\r\n * This method immediately returns as soon as a plugin explicitly returns false. The\r\n * returned value can be used, for instance, to interrupt the current action.\r\n * @param {Chart} chart - The chart instance for which plugins should be called.\r\n * @param {string} hook - The name of the plugin method to call (e.g. 'beforeUpdate').\r\n * @param {Array} [args] - Extra arguments to apply to the hook call.\r\n * @returns {boolean} false if any of the plugins return false, else returns true.\r\n */\n notify: function (chart, hook, args) {\n var descriptors = this.descriptors(chart);\n var ilen = descriptors.length;\n var i, descriptor, plugin, params, method;\n for (i = 0; i < ilen; ++i) {\n descriptor = descriptors[i];\n plugin = descriptor.plugin;\n method = plugin[hook];\n if (typeof method === 'function') {\n params = [chart].concat(args || []);\n params.push(descriptor.options);\n if (method.apply(plugin, params) === false) {\n return false;\n }\n }\n }\n return true;\n },\n /**\r\n * Returns descriptors of enabled plugins for the given chart.\r\n * @returns {object[]} [{ plugin, options }]\r\n * @private\r\n */\n descriptors: function (chart) {\n var cache = chart.$plugins || (chart.$plugins = {});\n if (cache.id === this._cacheId) {\n return cache.descriptors;\n }\n var plugins = [];\n var descriptors = [];\n var config = chart && chart.config || {};\n var options = config.options && config.options.plugins || {};\n this._plugins.concat(config.plugins || []).forEach(function (plugin) {\n var idx = plugins.indexOf(plugin);\n if (idx !== -1) {\n return;\n }\n var id = plugin.id;\n var opts = options[id];\n if (opts === false) {\n return;\n }\n if (opts === true) {\n opts = helpers$1.clone(core_defaults.global.plugins[id]);\n }\n plugins.push(plugin);\n descriptors.push({\n plugin: plugin,\n options: opts || {}\n });\n });\n cache.descriptors = descriptors;\n cache.id = this._cacheId;\n return descriptors;\n },\n /**\r\n * Invalidates cache for the given chart: descriptors hold a reference on plugin option,\r\n * but in some cases, this reference can be changed by the user when updating options.\r\n * https://github.com/chartjs/Chart.js/issues/5111#issuecomment-355934167\r\n * @private\r\n */\n _invalidate: function (chart) {\n delete chart.$plugins;\n }\n };\n var core_scaleService = {\n // Scale registration object. Extensions can register new scale types (such as log or DB scales) and then\n // use the new chart options to grab the correct scale\n constructors: {},\n // Use a registration function so that we can move to an ES6 map when we no longer need to support\n // old browsers\n\n // Scale config defaults\n defaults: {},\n registerScaleType: function (type, scaleConstructor, scaleDefaults) {\n this.constructors[type] = scaleConstructor;\n this.defaults[type] = helpers$1.clone(scaleDefaults);\n },\n getScaleConstructor: function (type) {\n return this.constructors.hasOwnProperty(type) ? this.constructors[type] : undefined;\n },\n getScaleDefaults: function (type) {\n // Return the scale defaults merged with the global settings so that we always use the latest ones\n return this.defaults.hasOwnProperty(type) ? helpers$1.merge(Object.create(null), [core_defaults.scale, this.defaults[type]]) : {};\n },\n updateScaleDefaults: function (type, additions) {\n var me = this;\n if (me.defaults.hasOwnProperty(type)) {\n me.defaults[type] = helpers$1.extend(me.defaults[type], additions);\n }\n },\n addScalesToLayout: function (chart) {\n // Adds each scale to the chart.boxes array to be sized accordingly\n helpers$1.each(chart.scales, function (scale) {\n // Set ILayoutItem parameters for backwards compatibility\n scale.fullWidth = scale.options.fullWidth;\n scale.position = scale.options.position;\n scale.weight = scale.options.weight;\n core_layouts.addBox(chart, scale);\n });\n }\n };\n var valueOrDefault$8 = helpers$1.valueOrDefault;\n var getRtlHelper = helpers$1.rtl.getRtlAdapter;\n core_defaults._set('global', {\n tooltips: {\n enabled: true,\n custom: null,\n mode: 'nearest',\n position: 'average',\n intersect: true,\n backgroundColor: 'rgba(0,0,0,0.8)',\n titleFontStyle: 'bold',\n titleSpacing: 2,\n titleMarginBottom: 6,\n titleFontColor: '#fff',\n titleAlign: 'left',\n bodySpacing: 2,\n bodyFontColor: '#fff',\n bodyAlign: 'left',\n footerFontStyle: 'bold',\n footerSpacing: 2,\n footerMarginTop: 6,\n footerFontColor: '#fff',\n footerAlign: 'left',\n yPadding: 6,\n xPadding: 6,\n caretPadding: 2,\n caretSize: 5,\n cornerRadius: 6,\n multiKeyBackground: '#fff',\n displayColors: true,\n borderColor: 'rgba(0,0,0,0)',\n borderWidth: 0,\n callbacks: {\n // Args are: (tooltipItems, data)\n beforeTitle: helpers$1.noop,\n title: function (tooltipItems, data) {\n var title = '';\n var labels = data.labels;\n var labelCount = labels ? labels.length : 0;\n if (tooltipItems.length > 0) {\n var item = tooltipItems[0];\n if (item.label) {\n title = item.label;\n } else if (item.xLabel) {\n title = item.xLabel;\n } else if (labelCount > 0 && item.index < labelCount) {\n title = labels[item.index];\n }\n }\n return title;\n },\n afterTitle: helpers$1.noop,\n // Args are: (tooltipItems, data)\n beforeBody: helpers$1.noop,\n // Args are: (tooltipItem, data)\n beforeLabel: helpers$1.noop,\n label: function (tooltipItem, data) {\n var label = data.datasets[tooltipItem.datasetIndex].label || '';\n if (label) {\n label += ': ';\n }\n if (!helpers$1.isNullOrUndef(tooltipItem.value)) {\n label += tooltipItem.value;\n } else {\n label += tooltipItem.yLabel;\n }\n return label;\n },\n labelColor: function (tooltipItem, chart) {\n var meta = chart.getDatasetMeta(tooltipItem.datasetIndex);\n var activeElement = meta.data[tooltipItem.index];\n var view = activeElement._view;\n return {\n borderColor: view.borderColor,\n backgroundColor: view.backgroundColor\n };\n },\n labelTextColor: function () {\n return this._options.bodyFontColor;\n },\n afterLabel: helpers$1.noop,\n // Args are: (tooltipItems, data)\n afterBody: helpers$1.noop,\n // Args are: (tooltipItems, data)\n beforeFooter: helpers$1.noop,\n footer: helpers$1.noop,\n afterFooter: helpers$1.noop\n }\n }\n });\n var positioners = {\n /**\r\n * Average mode places the tooltip at the average position of the elements shown\r\n * @function Chart.Tooltip.positioners.average\r\n * @param elements {ChartElement[]} the elements being displayed in the tooltip\r\n * @returns {object} tooltip position\r\n */\n average: function (elements) {\n if (!elements.length) {\n return false;\n }\n var i, len;\n var x = 0;\n var y = 0;\n var count = 0;\n for (i = 0, len = elements.length; i < len; ++i) {\n var el = elements[i];\n if (el && el.hasValue()) {\n var pos = el.tooltipPosition();\n x += pos.x;\n y += pos.y;\n ++count;\n }\n }\n return {\n x: x / count,\n y: y / count\n };\n },\n /**\r\n * Gets the tooltip position nearest of the item nearest to the event position\r\n * @function Chart.Tooltip.positioners.nearest\r\n * @param elements {Chart.Element[]} the tooltip elements\r\n * @param eventPosition {object} the position of the event in canvas coordinates\r\n * @returns {object} the tooltip position\r\n */\n nearest: function (elements, eventPosition) {\n var x = eventPosition.x;\n var y = eventPosition.y;\n var minDistance = Number.POSITIVE_INFINITY;\n var i, len, nearestElement;\n for (i = 0, len = elements.length; i < len; ++i) {\n var el = elements[i];\n if (el && el.hasValue()) {\n var center = el.getCenterPoint();\n var d = helpers$1.distanceBetweenPoints(eventPosition, center);\n if (d < minDistance) {\n minDistance = d;\n nearestElement = el;\n }\n }\n }\n if (nearestElement) {\n var tp = nearestElement.tooltipPosition();\n x = tp.x;\n y = tp.y;\n }\n return {\n x: x,\n y: y\n };\n }\n };\n\n // Helper to push or concat based on if the 2nd parameter is an array or not\n function pushOrConcat(base, toPush) {\n if (toPush) {\n if (helpers$1.isArray(toPush)) {\n // base = base.concat(toPush);\n Array.prototype.push.apply(base, toPush);\n } else {\n base.push(toPush);\n }\n }\n return base;\n }\n\n /**\r\n * Returns array of strings split by newline\r\n * @param {string} value - The value to split by newline.\r\n * @returns {string[]} value if newline present - Returned from String split() method\r\n * @function\r\n */\n function splitNewlines(str) {\n if ((typeof str === 'string' || str instanceof String) && str.indexOf('\\n') > -1) {\n return str.split('\\n');\n }\n return str;\n }\n\n /**\r\n * Private helper to create a tooltip item model\r\n * @param element - the chart element (point, arc, bar) to create the tooltip item for\r\n * @return new tooltip item\r\n */\n function createTooltipItem(element) {\n var xScale = element._xScale;\n var yScale = element._yScale || element._scale; // handle radar || polarArea charts\n var index = element._index;\n var datasetIndex = element._datasetIndex;\n var controller = element._chart.getDatasetMeta(datasetIndex).controller;\n var indexScale = controller._getIndexScale();\n var valueScale = controller._getValueScale();\n return {\n xLabel: xScale ? xScale.getLabelForIndex(index, datasetIndex) : '',\n yLabel: yScale ? yScale.getLabelForIndex(index, datasetIndex) : '',\n label: indexScale ? '' + indexScale.getLabelForIndex(index, datasetIndex) : '',\n value: valueScale ? '' + valueScale.getLabelForIndex(index, datasetIndex) : '',\n index: index,\n datasetIndex: datasetIndex,\n x: element._model.x,\n y: element._model.y\n };\n }\n\n /**\r\n * Helper to get the reset model for the tooltip\r\n * @param tooltipOpts {object} the tooltip options\r\n */\n function getBaseModel(tooltipOpts) {\n var globalDefaults = core_defaults.global;\n return {\n // Positioning\n xPadding: tooltipOpts.xPadding,\n yPadding: tooltipOpts.yPadding,\n xAlign: tooltipOpts.xAlign,\n yAlign: tooltipOpts.yAlign,\n // Drawing direction and text direction\n rtl: tooltipOpts.rtl,\n textDirection: tooltipOpts.textDirection,\n // Body\n bodyFontColor: tooltipOpts.bodyFontColor,\n _bodyFontFamily: valueOrDefault$8(tooltipOpts.bodyFontFamily, globalDefaults.defaultFontFamily),\n _bodyFontStyle: valueOrDefault$8(tooltipOpts.bodyFontStyle, globalDefaults.defaultFontStyle),\n _bodyAlign: tooltipOpts.bodyAlign,\n bodyFontSize: valueOrDefault$8(tooltipOpts.bodyFontSize, globalDefaults.defaultFontSize),\n bodySpacing: tooltipOpts.bodySpacing,\n // Title\n titleFontColor: tooltipOpts.titleFontColor,\n _titleFontFamily: valueOrDefault$8(tooltipOpts.titleFontFamily, globalDefaults.defaultFontFamily),\n _titleFontStyle: valueOrDefault$8(tooltipOpts.titleFontStyle, globalDefaults.defaultFontStyle),\n titleFontSize: valueOrDefault$8(tooltipOpts.titleFontSize, globalDefaults.defaultFontSize),\n _titleAlign: tooltipOpts.titleAlign,\n titleSpacing: tooltipOpts.titleSpacing,\n titleMarginBottom: tooltipOpts.titleMarginBottom,\n // Footer\n footerFontColor: tooltipOpts.footerFontColor,\n _footerFontFamily: valueOrDefault$8(tooltipOpts.footerFontFamily, globalDefaults.defaultFontFamily),\n _footerFontStyle: valueOrDefault$8(tooltipOpts.footerFontStyle, globalDefaults.defaultFontStyle),\n footerFontSize: valueOrDefault$8(tooltipOpts.footerFontSize, globalDefaults.defaultFontSize),\n _footerAlign: tooltipOpts.footerAlign,\n footerSpacing: tooltipOpts.footerSpacing,\n footerMarginTop: tooltipOpts.footerMarginTop,\n // Appearance\n caretSize: tooltipOpts.caretSize,\n cornerRadius: tooltipOpts.cornerRadius,\n backgroundColor: tooltipOpts.backgroundColor,\n opacity: 0,\n legendColorBackground: tooltipOpts.multiKeyBackground,\n displayColors: tooltipOpts.displayColors,\n borderColor: tooltipOpts.borderColor,\n borderWidth: tooltipOpts.borderWidth\n };\n }\n\n /**\r\n * Get the size of the tooltip\r\n */\n function getTooltipSize(tooltip, model) {\n var ctx = tooltip._chart.ctx;\n var height = model.yPadding * 2; // Tooltip Padding\n var width = 0;\n\n // Count of all lines in the body\n var body = model.body;\n var combinedBodyLength = body.reduce(function (count, bodyItem) {\n return count + bodyItem.before.length + bodyItem.lines.length + bodyItem.after.length;\n }, 0);\n combinedBodyLength += model.beforeBody.length + model.afterBody.length;\n var titleLineCount = model.title.length;\n var footerLineCount = model.footer.length;\n var titleFontSize = model.titleFontSize;\n var bodyFontSize = model.bodyFontSize;\n var footerFontSize = model.footerFontSize;\n height += titleLineCount * titleFontSize; // Title Lines\n height += titleLineCount ? (titleLineCount - 1) * model.titleSpacing : 0; // Title Line Spacing\n height += titleLineCount ? model.titleMarginBottom : 0; // Title's bottom Margin\n height += combinedBodyLength * bodyFontSize; // Body Lines\n height += combinedBodyLength ? (combinedBodyLength - 1) * model.bodySpacing : 0; // Body Line Spacing\n height += footerLineCount ? model.footerMarginTop : 0; // Footer Margin\n height += footerLineCount * footerFontSize; // Footer Lines\n height += footerLineCount ? (footerLineCount - 1) * model.footerSpacing : 0; // Footer Line Spacing\n\n // Title width\n var widthPadding = 0;\n var maxLineWidth = function (line) {\n width = Math.max(width, ctx.measureText(line).width + widthPadding);\n };\n ctx.font = helpers$1.fontString(titleFontSize, model._titleFontStyle, model._titleFontFamily);\n helpers$1.each(model.title, maxLineWidth);\n\n // Body width\n ctx.font = helpers$1.fontString(bodyFontSize, model._bodyFontStyle, model._bodyFontFamily);\n helpers$1.each(model.beforeBody.concat(model.afterBody), maxLineWidth);\n\n // Body lines may include some extra width due to the color box\n widthPadding = model.displayColors ? bodyFontSize + 2 : 0;\n helpers$1.each(body, function (bodyItem) {\n helpers$1.each(bodyItem.before, maxLineWidth);\n helpers$1.each(bodyItem.lines, maxLineWidth);\n helpers$1.each(bodyItem.after, maxLineWidth);\n });\n\n // Reset back to 0\n widthPadding = 0;\n\n // Footer width\n ctx.font = helpers$1.fontString(footerFontSize, model._footerFontStyle, model._footerFontFamily);\n helpers$1.each(model.footer, maxLineWidth);\n\n // Add padding\n width += 2 * model.xPadding;\n return {\n width: width,\n height: height\n };\n }\n\n /**\r\n * Helper to get the alignment of a tooltip given the size\r\n */\n function determineAlignment(tooltip, size) {\n var model = tooltip._model;\n var chart = tooltip._chart;\n var chartArea = tooltip._chart.chartArea;\n var xAlign = 'center';\n var yAlign = 'center';\n if (model.y < size.height) {\n yAlign = 'top';\n } else if (model.y > chart.height - size.height) {\n yAlign = 'bottom';\n }\n var lf, rf; // functions to determine left, right alignment\n var olf, orf; // functions to determine if left/right alignment causes tooltip to go outside chart\n var yf; // function to get the y alignment if the tooltip goes outside of the left or right edges\n var midX = (chartArea.left + chartArea.right) / 2;\n var midY = (chartArea.top + chartArea.bottom) / 2;\n if (yAlign === 'center') {\n lf = function (x) {\n return x <= midX;\n };\n rf = function (x) {\n return x > midX;\n };\n } else {\n lf = function (x) {\n return x <= size.width / 2;\n };\n rf = function (x) {\n return x >= chart.width - size.width / 2;\n };\n }\n olf = function (x) {\n return x + size.width + model.caretSize + model.caretPadding > chart.width;\n };\n orf = function (x) {\n return x - size.width - model.caretSize - model.caretPadding < 0;\n };\n yf = function (y) {\n return y <= midY ? 'top' : 'bottom';\n };\n if (lf(model.x)) {\n xAlign = 'left';\n\n // Is tooltip too wide and goes over the right side of the chart.?\n if (olf(model.x)) {\n xAlign = 'center';\n yAlign = yf(model.y);\n }\n } else if (rf(model.x)) {\n xAlign = 'right';\n\n // Is tooltip too wide and goes outside left edge of canvas?\n if (orf(model.x)) {\n xAlign = 'center';\n yAlign = yf(model.y);\n }\n }\n var opts = tooltip._options;\n return {\n xAlign: opts.xAlign ? opts.xAlign : xAlign,\n yAlign: opts.yAlign ? opts.yAlign : yAlign\n };\n }\n\n /**\r\n * Helper to get the location a tooltip needs to be placed at given the initial position (via the vm) and the size and alignment\r\n */\n function getBackgroundPoint(vm, size, alignment, chart) {\n // Background Position\n var x = vm.x;\n var y = vm.y;\n var caretSize = vm.caretSize;\n var caretPadding = vm.caretPadding;\n var cornerRadius = vm.cornerRadius;\n var xAlign = alignment.xAlign;\n var yAlign = alignment.yAlign;\n var paddingAndSize = caretSize + caretPadding;\n var radiusAndPadding = cornerRadius + caretPadding;\n if (xAlign === 'right') {\n x -= size.width;\n } else if (xAlign === 'center') {\n x -= size.width / 2;\n if (x + size.width > chart.width) {\n x = chart.width - size.width;\n }\n if (x < 0) {\n x = 0;\n }\n }\n if (yAlign === 'top') {\n y += paddingAndSize;\n } else if (yAlign === 'bottom') {\n y -= size.height + paddingAndSize;\n } else {\n y -= size.height / 2;\n }\n if (yAlign === 'center') {\n if (xAlign === 'left') {\n x += paddingAndSize;\n } else if (xAlign === 'right') {\n x -= paddingAndSize;\n }\n } else if (xAlign === 'left') {\n x -= radiusAndPadding;\n } else if (xAlign === 'right') {\n x += radiusAndPadding;\n }\n return {\n x: x,\n y: y\n };\n }\n function getAlignedX(vm, align) {\n return align === 'center' ? vm.x + vm.width / 2 : align === 'right' ? vm.x + vm.width - vm.xPadding : vm.x + vm.xPadding;\n }\n\n /**\r\n * Helper to build before and after body lines\r\n */\n function getBeforeAfterBodyLines(callback) {\n return pushOrConcat([], splitNewlines(callback));\n }\n var exports$4 = core_element.extend({\n initialize: function () {\n this._model = getBaseModel(this._options);\n this._lastActive = [];\n },\n // Get the title\n // Args are: (tooltipItem, data)\n getTitle: function () {\n var me = this;\n var opts = me._options;\n var callbacks = opts.callbacks;\n var beforeTitle = callbacks.beforeTitle.apply(me, arguments);\n var title = callbacks.title.apply(me, arguments);\n var afterTitle = callbacks.afterTitle.apply(me, arguments);\n var lines = [];\n lines = pushOrConcat(lines, splitNewlines(beforeTitle));\n lines = pushOrConcat(lines, splitNewlines(title));\n lines = pushOrConcat(lines, splitNewlines(afterTitle));\n return lines;\n },\n // Args are: (tooltipItem, data)\n getBeforeBody: function () {\n return getBeforeAfterBodyLines(this._options.callbacks.beforeBody.apply(this, arguments));\n },\n // Args are: (tooltipItem, data)\n getBody: function (tooltipItems, data) {\n var me = this;\n var callbacks = me._options.callbacks;\n var bodyItems = [];\n helpers$1.each(tooltipItems, function (tooltipItem) {\n var bodyItem = {\n before: [],\n lines: [],\n after: []\n };\n pushOrConcat(bodyItem.before, splitNewlines(callbacks.beforeLabel.call(me, tooltipItem, data)));\n pushOrConcat(bodyItem.lines, callbacks.label.call(me, tooltipItem, data));\n pushOrConcat(bodyItem.after, splitNewlines(callbacks.afterLabel.call(me, tooltipItem, data)));\n bodyItems.push(bodyItem);\n });\n return bodyItems;\n },\n // Args are: (tooltipItem, data)\n getAfterBody: function () {\n return getBeforeAfterBodyLines(this._options.callbacks.afterBody.apply(this, arguments));\n },\n // Get the footer and beforeFooter and afterFooter lines\n // Args are: (tooltipItem, data)\n getFooter: function () {\n var me = this;\n var callbacks = me._options.callbacks;\n var beforeFooter = callbacks.beforeFooter.apply(me, arguments);\n var footer = callbacks.footer.apply(me, arguments);\n var afterFooter = callbacks.afterFooter.apply(me, arguments);\n var lines = [];\n lines = pushOrConcat(lines, splitNewlines(beforeFooter));\n lines = pushOrConcat(lines, splitNewlines(footer));\n lines = pushOrConcat(lines, splitNewlines(afterFooter));\n return lines;\n },\n update: function (changed) {\n var me = this;\n var opts = me._options;\n\n // Need to regenerate the model because its faster than using extend and it is necessary due to the optimization in Chart.Element.transition\n // that does _view = _model if ease === 1. This causes the 2nd tooltip update to set properties in both the view and model at the same time\n // which breaks any animations.\n var existingModel = me._model;\n var model = me._model = getBaseModel(opts);\n var active = me._active;\n var data = me._data;\n\n // In the case where active.length === 0 we need to keep these at existing values for good animations\n var alignment = {\n xAlign: existingModel.xAlign,\n yAlign: existingModel.yAlign\n };\n var backgroundPoint = {\n x: existingModel.x,\n y: existingModel.y\n };\n var tooltipSize = {\n width: existingModel.width,\n height: existingModel.height\n };\n var tooltipPosition = {\n x: existingModel.caretX,\n y: existingModel.caretY\n };\n var i, len;\n if (active.length) {\n model.opacity = 1;\n var labelColors = [];\n var labelTextColors = [];\n tooltipPosition = positioners[opts.position].call(me, active, me._eventPosition);\n var tooltipItems = [];\n for (i = 0, len = active.length; i < len; ++i) {\n tooltipItems.push(createTooltipItem(active[i]));\n }\n\n // If the user provided a filter function, use it to modify the tooltip items\n if (opts.filter) {\n tooltipItems = tooltipItems.filter(function (a) {\n return opts.filter(a, data);\n });\n }\n\n // If the user provided a sorting function, use it to modify the tooltip items\n if (opts.itemSort) {\n tooltipItems = tooltipItems.sort(function (a, b) {\n return opts.itemSort(a, b, data);\n });\n }\n\n // Determine colors for boxes\n helpers$1.each(tooltipItems, function (tooltipItem) {\n labelColors.push(opts.callbacks.labelColor.call(me, tooltipItem, me._chart));\n labelTextColors.push(opts.callbacks.labelTextColor.call(me, tooltipItem, me._chart));\n });\n\n // Build the Text Lines\n model.title = me.getTitle(tooltipItems, data);\n model.beforeBody = me.getBeforeBody(tooltipItems, data);\n model.body = me.getBody(tooltipItems, data);\n model.afterBody = me.getAfterBody(tooltipItems, data);\n model.footer = me.getFooter(tooltipItems, data);\n\n // Initial positioning and colors\n model.x = tooltipPosition.x;\n model.y = tooltipPosition.y;\n model.caretPadding = opts.caretPadding;\n model.labelColors = labelColors;\n model.labelTextColors = labelTextColors;\n\n // data points\n model.dataPoints = tooltipItems;\n\n // We need to determine alignment of the tooltip\n tooltipSize = getTooltipSize(this, model);\n alignment = determineAlignment(this, tooltipSize);\n // Final Size and Position\n backgroundPoint = getBackgroundPoint(model, tooltipSize, alignment, me._chart);\n } else {\n model.opacity = 0;\n }\n model.xAlign = alignment.xAlign;\n model.yAlign = alignment.yAlign;\n model.x = backgroundPoint.x;\n model.y = backgroundPoint.y;\n model.width = tooltipSize.width;\n model.height = tooltipSize.height;\n\n // Point where the caret on the tooltip points to\n model.caretX = tooltipPosition.x;\n model.caretY = tooltipPosition.y;\n me._model = model;\n if (changed && opts.custom) {\n opts.custom.call(me, model);\n }\n return me;\n },\n drawCaret: function (tooltipPoint, size) {\n var ctx = this._chart.ctx;\n var vm = this._view;\n var caretPosition = this.getCaretPosition(tooltipPoint, size, vm);\n ctx.lineTo(caretPosition.x1, caretPosition.y1);\n ctx.lineTo(caretPosition.x2, caretPosition.y2);\n ctx.lineTo(caretPosition.x3, caretPosition.y3);\n },\n getCaretPosition: function (tooltipPoint, size, vm) {\n var x1, x2, x3, y1, y2, y3;\n var caretSize = vm.caretSize;\n var cornerRadius = vm.cornerRadius;\n var xAlign = vm.xAlign;\n var yAlign = vm.yAlign;\n var ptX = tooltipPoint.x;\n var ptY = tooltipPoint.y;\n var width = size.width;\n var height = size.height;\n if (yAlign === 'center') {\n y2 = ptY + height / 2;\n if (xAlign === 'left') {\n x1 = ptX;\n x2 = x1 - caretSize;\n x3 = x1;\n y1 = y2 + caretSize;\n y3 = y2 - caretSize;\n } else {\n x1 = ptX + width;\n x2 = x1 + caretSize;\n x3 = x1;\n y1 = y2 - caretSize;\n y3 = y2 + caretSize;\n }\n } else {\n if (xAlign === 'left') {\n x2 = ptX + cornerRadius + caretSize;\n x1 = x2 - caretSize;\n x3 = x2 + caretSize;\n } else if (xAlign === 'right') {\n x2 = ptX + width - cornerRadius - caretSize;\n x1 = x2 - caretSize;\n x3 = x2 + caretSize;\n } else {\n x2 = vm.caretX;\n x1 = x2 - caretSize;\n x3 = x2 + caretSize;\n }\n if (yAlign === 'top') {\n y1 = ptY;\n y2 = y1 - caretSize;\n y3 = y1;\n } else {\n y1 = ptY + height;\n y2 = y1 + caretSize;\n y3 = y1;\n // invert drawing order\n var tmp = x3;\n x3 = x1;\n x1 = tmp;\n }\n }\n return {\n x1: x1,\n x2: x2,\n x3: x3,\n y1: y1,\n y2: y2,\n y3: y3\n };\n },\n drawTitle: function (pt, vm, ctx) {\n var title = vm.title;\n var length = title.length;\n var titleFontSize, titleSpacing, i;\n if (length) {\n var rtlHelper = getRtlHelper(vm.rtl, vm.x, vm.width);\n pt.x = getAlignedX(vm, vm._titleAlign);\n ctx.textAlign = rtlHelper.textAlign(vm._titleAlign);\n ctx.textBaseline = 'middle';\n titleFontSize = vm.titleFontSize;\n titleSpacing = vm.titleSpacing;\n ctx.fillStyle = vm.titleFontColor;\n ctx.font = helpers$1.fontString(titleFontSize, vm._titleFontStyle, vm._titleFontFamily);\n for (i = 0; i < length; ++i) {\n ctx.fillText(title[i], rtlHelper.x(pt.x), pt.y + titleFontSize / 2);\n pt.y += titleFontSize + titleSpacing; // Line Height and spacing\n\n if (i + 1 === length) {\n pt.y += vm.titleMarginBottom - titleSpacing; // If Last, add margin, remove spacing\n }\n }\n }\n },\n drawBody: function (pt, vm, ctx) {\n var bodyFontSize = vm.bodyFontSize;\n var bodySpacing = vm.bodySpacing;\n var bodyAlign = vm._bodyAlign;\n var body = vm.body;\n var drawColorBoxes = vm.displayColors;\n var xLinePadding = 0;\n var colorX = drawColorBoxes ? getAlignedX(vm, 'left') : 0;\n var rtlHelper = getRtlHelper(vm.rtl, vm.x, vm.width);\n var fillLineOfText = function (line) {\n ctx.fillText(line, rtlHelper.x(pt.x + xLinePadding), pt.y + bodyFontSize / 2);\n pt.y += bodyFontSize + bodySpacing;\n };\n var bodyItem, textColor, labelColors, lines, i, j, ilen, jlen;\n var bodyAlignForCalculation = rtlHelper.textAlign(bodyAlign);\n ctx.textAlign = bodyAlign;\n ctx.textBaseline = 'middle';\n ctx.font = helpers$1.fontString(bodyFontSize, vm._bodyFontStyle, vm._bodyFontFamily);\n pt.x = getAlignedX(vm, bodyAlignForCalculation);\n\n // Before body lines\n ctx.fillStyle = vm.bodyFontColor;\n helpers$1.each(vm.beforeBody, fillLineOfText);\n xLinePadding = drawColorBoxes && bodyAlignForCalculation !== 'right' ? bodyAlign === 'center' ? bodyFontSize / 2 + 1 : bodyFontSize + 2 : 0;\n\n // Draw body lines now\n for (i = 0, ilen = body.length; i < ilen; ++i) {\n bodyItem = body[i];\n textColor = vm.labelTextColors[i];\n labelColors = vm.labelColors[i];\n ctx.fillStyle = textColor;\n helpers$1.each(bodyItem.before, fillLineOfText);\n lines = bodyItem.lines;\n for (j = 0, jlen = lines.length; j < jlen; ++j) {\n // Draw Legend-like boxes if needed\n if (drawColorBoxes) {\n var rtlColorX = rtlHelper.x(colorX);\n\n // Fill a white rect so that colours merge nicely if the opacity is < 1\n ctx.fillStyle = vm.legendColorBackground;\n ctx.fillRect(rtlHelper.leftForLtr(rtlColorX, bodyFontSize), pt.y, bodyFontSize, bodyFontSize);\n\n // Border\n ctx.lineWidth = 1;\n ctx.strokeStyle = labelColors.borderColor;\n ctx.strokeRect(rtlHelper.leftForLtr(rtlColorX, bodyFontSize), pt.y, bodyFontSize, bodyFontSize);\n\n // Inner square\n ctx.fillStyle = labelColors.backgroundColor;\n ctx.fillRect(rtlHelper.leftForLtr(rtlHelper.xPlus(rtlColorX, 1), bodyFontSize - 2), pt.y + 1, bodyFontSize - 2, bodyFontSize - 2);\n ctx.fillStyle = textColor;\n }\n fillLineOfText(lines[j]);\n }\n helpers$1.each(bodyItem.after, fillLineOfText);\n }\n\n // Reset back to 0 for after body\n xLinePadding = 0;\n\n // After body lines\n helpers$1.each(vm.afterBody, fillLineOfText);\n pt.y -= bodySpacing; // Remove last body spacing\n },\n drawFooter: function (pt, vm, ctx) {\n var footer = vm.footer;\n var length = footer.length;\n var footerFontSize, i;\n if (length) {\n var rtlHelper = getRtlHelper(vm.rtl, vm.x, vm.width);\n pt.x = getAlignedX(vm, vm._footerAlign);\n pt.y += vm.footerMarginTop;\n ctx.textAlign = rtlHelper.textAlign(vm._footerAlign);\n ctx.textBaseline = 'middle';\n footerFontSize = vm.footerFontSize;\n ctx.fillStyle = vm.footerFontColor;\n ctx.font = helpers$1.fontString(footerFontSize, vm._footerFontStyle, vm._footerFontFamily);\n for (i = 0; i < length; ++i) {\n ctx.fillText(footer[i], rtlHelper.x(pt.x), pt.y + footerFontSize / 2);\n pt.y += footerFontSize + vm.footerSpacing;\n }\n }\n },\n drawBackground: function (pt, vm, ctx, tooltipSize) {\n ctx.fillStyle = vm.backgroundColor;\n ctx.strokeStyle = vm.borderColor;\n ctx.lineWidth = vm.borderWidth;\n var xAlign = vm.xAlign;\n var yAlign = vm.yAlign;\n var x = pt.x;\n var y = pt.y;\n var width = tooltipSize.width;\n var height = tooltipSize.height;\n var radius = vm.cornerRadius;\n ctx.beginPath();\n ctx.moveTo(x + radius, y);\n if (yAlign === 'top') {\n this.drawCaret(pt, tooltipSize);\n }\n ctx.lineTo(x + width - radius, y);\n ctx.quadraticCurveTo(x + width, y, x + width, y + radius);\n if (yAlign === 'center' && xAlign === 'right') {\n this.drawCaret(pt, tooltipSize);\n }\n ctx.lineTo(x + width, y + height - radius);\n ctx.quadraticCurveTo(x + width, y + height, x + width - radius, y + height);\n if (yAlign === 'bottom') {\n this.drawCaret(pt, tooltipSize);\n }\n ctx.lineTo(x + radius, y + height);\n ctx.quadraticCurveTo(x, y + height, x, y + height - radius);\n if (yAlign === 'center' && xAlign === 'left') {\n this.drawCaret(pt, tooltipSize);\n }\n ctx.lineTo(x, y + radius);\n ctx.quadraticCurveTo(x, y, x + radius, y);\n ctx.closePath();\n ctx.fill();\n if (vm.borderWidth > 0) {\n ctx.stroke();\n }\n },\n draw: function () {\n var ctx = this._chart.ctx;\n var vm = this._view;\n if (vm.opacity === 0) {\n return;\n }\n var tooltipSize = {\n width: vm.width,\n height: vm.height\n };\n var pt = {\n x: vm.x,\n y: vm.y\n };\n\n // IE11/Edge does not like very small opacities, so snap to 0\n var opacity = Math.abs(vm.opacity < 1e-3) ? 0 : vm.opacity;\n\n // Truthy/falsey value for empty tooltip\n var hasTooltipContent = vm.title.length || vm.beforeBody.length || vm.body.length || vm.afterBody.length || vm.footer.length;\n if (this._options.enabled && hasTooltipContent) {\n ctx.save();\n ctx.globalAlpha = opacity;\n\n // Draw Background\n this.drawBackground(pt, vm, ctx, tooltipSize);\n\n // Draw Title, Body, and Footer\n pt.y += vm.yPadding;\n helpers$1.rtl.overrideTextDirection(ctx, vm.textDirection);\n\n // Titles\n this.drawTitle(pt, vm, ctx);\n\n // Body\n this.drawBody(pt, vm, ctx);\n\n // Footer\n this.drawFooter(pt, vm, ctx);\n helpers$1.rtl.restoreTextDirection(ctx, vm.textDirection);\n ctx.restore();\n }\n },\n /**\r\n * Handle an event\r\n * @private\r\n * @param {IEvent} event - The event to handle\r\n * @returns {boolean} true if the tooltip changed\r\n */\n handleEvent: function (e) {\n var me = this;\n var options = me._options;\n var changed = false;\n me._lastActive = me._lastActive || [];\n\n // Find Active Elements for tooltips\n if (e.type === 'mouseout') {\n me._active = [];\n } else {\n me._active = me._chart.getElementsAtEventForMode(e, options.mode, options);\n if (options.reverse) {\n me._active.reverse();\n }\n }\n\n // Remember Last Actives\n changed = !helpers$1.arrayEquals(me._active, me._lastActive);\n\n // Only handle target event on tooltip change\n if (changed) {\n me._lastActive = me._active;\n if (options.enabled || options.custom) {\n me._eventPosition = {\n x: e.x,\n y: e.y\n };\n me.update(true);\n me.pivot();\n }\n }\n return changed;\n }\n });\n\n /**\r\n * @namespace Chart.Tooltip.positioners\r\n */\n var positioners_1 = positioners;\n var core_tooltip = exports$4;\n core_tooltip.positioners = positioners_1;\n var valueOrDefault$9 = helpers$1.valueOrDefault;\n core_defaults._set('global', {\n elements: {},\n events: ['mousemove', 'mouseout', 'click', 'touchstart', 'touchmove'],\n hover: {\n onHover: null,\n mode: 'nearest',\n intersect: true,\n animationDuration: 400\n },\n onClick: null,\n maintainAspectRatio: true,\n responsive: true,\n responsiveAnimationDuration: 0\n });\n\n /**\r\n * Recursively merge the given config objects representing the `scales` option\r\n * by incorporating scale defaults in `xAxes` and `yAxes` array items, then\r\n * returns a deep copy of the result, thus doesn't alter inputs.\r\n */\n function mergeScaleConfig(/* config objects ... */\n ) {\n return helpers$1.merge(Object.create(null), [].slice.call(arguments), {\n merger: function (key, target, source, options) {\n if (key === 'xAxes' || key === 'yAxes') {\n var slen = source[key].length;\n var i, type, scale;\n if (!target[key]) {\n target[key] = [];\n }\n for (i = 0; i < slen; ++i) {\n scale = source[key][i];\n type = valueOrDefault$9(scale.type, key === 'xAxes' ? 'category' : 'linear');\n if (i >= target[key].length) {\n target[key].push({});\n }\n if (!target[key][i].type || scale.type && scale.type !== target[key][i].type) {\n // new/untyped scale or type changed: let's apply the new defaults\n // then merge source scale to correctly overwrite the defaults.\n helpers$1.merge(target[key][i], [core_scaleService.getScaleDefaults(type), scale]);\n } else {\n // scales type are the same\n helpers$1.merge(target[key][i], scale);\n }\n }\n } else {\n helpers$1._merger(key, target, source, options);\n }\n }\n });\n }\n\n /**\r\n * Recursively merge the given config objects as the root options by handling\r\n * default scale options for the `scales` and `scale` properties, then returns\r\n * a deep copy of the result, thus doesn't alter inputs.\r\n */\n function mergeConfig(/* config objects ... */\n ) {\n return helpers$1.merge(Object.create(null), [].slice.call(arguments), {\n merger: function (key, target, source, options) {\n var tval = target[key] || Object.create(null);\n var sval = source[key];\n if (key === 'scales') {\n // scale config merging is complex. Add our own function here for that\n target[key] = mergeScaleConfig(tval, sval);\n } else if (key === 'scale') {\n // used in polar area & radar charts since there is only one scale\n target[key] = helpers$1.merge(tval, [core_scaleService.getScaleDefaults(sval.type), sval]);\n } else {\n helpers$1._merger(key, target, source, options);\n }\n }\n });\n }\n function initConfig(config) {\n config = config || Object.create(null);\n\n // Do NOT use mergeConfig for the data object because this method merges arrays\n // and so would change references to labels and datasets, preventing data updates.\n var data = config.data = config.data || {};\n data.datasets = data.datasets || [];\n data.labels = data.labels || [];\n config.options = mergeConfig(core_defaults.global, core_defaults[config.type], config.options || {});\n return config;\n }\n function updateConfig(chart) {\n var newOptions = chart.options;\n helpers$1.each(chart.scales, function (scale) {\n core_layouts.removeBox(chart, scale);\n });\n newOptions = mergeConfig(core_defaults.global, core_defaults[chart.config.type], newOptions);\n chart.options = chart.config.options = newOptions;\n chart.ensureScalesHaveIDs();\n chart.buildOrUpdateScales();\n\n // Tooltip\n chart.tooltip._options = newOptions.tooltips;\n chart.tooltip.initialize();\n }\n function nextAvailableScaleId(axesOpts, prefix, index) {\n var id;\n var hasId = function (obj) {\n return obj.id === id;\n };\n do {\n id = prefix + index++;\n } while (helpers$1.findIndex(axesOpts, hasId) >= 0);\n return id;\n }\n function positionIsHorizontal(position) {\n return position === 'top' || position === 'bottom';\n }\n function compare2Level(l1, l2) {\n return function (a, b) {\n return a[l1] === b[l1] ? a[l2] - b[l2] : a[l1] - b[l1];\n };\n }\n var Chart = function (item, config) {\n this.construct(item, config);\n return this;\n };\n helpers$1.extend(Chart.prototype, /** @lends Chart */{\n /**\r\n * @private\r\n */\n construct: function (item, config) {\n var me = this;\n config = initConfig(config);\n var context = platform.acquireContext(item, config);\n var canvas = context && context.canvas;\n var height = canvas && canvas.height;\n var width = canvas && canvas.width;\n me.id = helpers$1.uid();\n me.ctx = context;\n me.canvas = canvas;\n me.config = config;\n me.width = width;\n me.height = height;\n me.aspectRatio = height ? width / height : null;\n me.options = config.options;\n me._bufferedRender = false;\n me._layers = [];\n\n /**\r\n * Provided for backward compatibility, Chart and Chart.Controller have been merged,\r\n * the \"instance\" still need to be defined since it might be called from plugins.\r\n * @prop Chart#chart\r\n * @deprecated since version 2.6.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n me.chart = me;\n me.controller = me; // chart.chart.controller #inception\n\n // Add the chart instance to the global namespace\n Chart.instances[me.id] = me;\n\n // Define alias to the config data: `chart.data === chart.config.data`\n Object.defineProperty(me, 'data', {\n get: function () {\n return me.config.data;\n },\n set: function (value) {\n me.config.data = value;\n }\n });\n if (!context || !canvas) {\n // The given item is not a compatible context2d element, let's return before finalizing\n // the chart initialization but after setting basic chart / controller properties that\n // can help to figure out that the chart is not valid (e.g chart.canvas !== null);\n // https://github.com/chartjs/Chart.js/issues/2807\n console.error(\"Failed to create chart: can't acquire context from the given item\");\n return;\n }\n me.initialize();\n me.update();\n },\n /**\r\n * @private\r\n */\n initialize: function () {\n var me = this;\n\n // Before init plugin notification\n core_plugins.notify(me, 'beforeInit');\n helpers$1.retinaScale(me, me.options.devicePixelRatio);\n me.bindEvents();\n if (me.options.responsive) {\n // Initial resize before chart draws (must be silent to preserve initial animations).\n me.resize(true);\n }\n me.initToolTip();\n\n // After init plugin notification\n core_plugins.notify(me, 'afterInit');\n return me;\n },\n clear: function () {\n helpers$1.canvas.clear(this);\n return this;\n },\n stop: function () {\n // Stops any current animation loop occurring\n core_animations.cancelAnimation(this);\n return this;\n },\n resize: function (silent) {\n var me = this;\n var options = me.options;\n var canvas = me.canvas;\n var aspectRatio = options.maintainAspectRatio && me.aspectRatio || null;\n\n // the canvas render width and height will be casted to integers so make sure that\n // the canvas display style uses the same integer values to avoid blurring effect.\n\n // Set to 0 instead of canvas.size because the size defaults to 300x150 if the element is collapsed\n var newWidth = Math.max(0, Math.floor(helpers$1.getMaximumWidth(canvas)));\n var newHeight = Math.max(0, Math.floor(aspectRatio ? newWidth / aspectRatio : helpers$1.getMaximumHeight(canvas)));\n if (me.width === newWidth && me.height === newHeight) {\n return;\n }\n canvas.width = me.width = newWidth;\n canvas.height = me.height = newHeight;\n canvas.style.width = newWidth + 'px';\n canvas.style.height = newHeight + 'px';\n helpers$1.retinaScale(me, options.devicePixelRatio);\n if (!silent) {\n // Notify any plugins about the resize\n var newSize = {\n width: newWidth,\n height: newHeight\n };\n core_plugins.notify(me, 'resize', [newSize]);\n\n // Notify of resize\n if (options.onResize) {\n options.onResize(me, newSize);\n }\n me.stop();\n me.update({\n duration: options.responsiveAnimationDuration\n });\n }\n },\n ensureScalesHaveIDs: function () {\n var options = this.options;\n var scalesOptions = options.scales || {};\n var scaleOptions = options.scale;\n helpers$1.each(scalesOptions.xAxes, function (xAxisOptions, index) {\n if (!xAxisOptions.id) {\n xAxisOptions.id = nextAvailableScaleId(scalesOptions.xAxes, 'x-axis-', index);\n }\n });\n helpers$1.each(scalesOptions.yAxes, function (yAxisOptions, index) {\n if (!yAxisOptions.id) {\n yAxisOptions.id = nextAvailableScaleId(scalesOptions.yAxes, 'y-axis-', index);\n }\n });\n if (scaleOptions) {\n scaleOptions.id = scaleOptions.id || 'scale';\n }\n },\n /**\r\n * Builds a map of scale ID to scale object for future lookup.\r\n */\n buildOrUpdateScales: function () {\n var me = this;\n var options = me.options;\n var scales = me.scales || {};\n var items = [];\n var updated = Object.keys(scales).reduce(function (obj, id) {\n obj[id] = false;\n return obj;\n }, {});\n if (options.scales) {\n items = items.concat((options.scales.xAxes || []).map(function (xAxisOptions) {\n return {\n options: xAxisOptions,\n dtype: 'category',\n dposition: 'bottom'\n };\n }), (options.scales.yAxes || []).map(function (yAxisOptions) {\n return {\n options: yAxisOptions,\n dtype: 'linear',\n dposition: 'left'\n };\n }));\n }\n if (options.scale) {\n items.push({\n options: options.scale,\n dtype: 'radialLinear',\n isDefault: true,\n dposition: 'chartArea'\n });\n }\n helpers$1.each(items, function (item) {\n var scaleOptions = item.options;\n var id = scaleOptions.id;\n var scaleType = valueOrDefault$9(scaleOptions.type, item.dtype);\n if (positionIsHorizontal(scaleOptions.position) !== positionIsHorizontal(item.dposition)) {\n scaleOptions.position = item.dposition;\n }\n updated[id] = true;\n var scale = null;\n if (id in scales && scales[id].type === scaleType) {\n scale = scales[id];\n scale.options = scaleOptions;\n scale.ctx = me.ctx;\n scale.chart = me;\n } else {\n var scaleClass = core_scaleService.getScaleConstructor(scaleType);\n if (!scaleClass) {\n return;\n }\n scale = new scaleClass({\n id: id,\n type: scaleType,\n options: scaleOptions,\n ctx: me.ctx,\n chart: me\n });\n scales[scale.id] = scale;\n }\n scale.mergeTicksOptions();\n\n // TODO(SB): I think we should be able to remove this custom case (options.scale)\n // and consider it as a regular scale part of the \"scales\"\" map only! This would\n // make the logic easier and remove some useless? custom code.\n if (item.isDefault) {\n me.scale = scale;\n }\n });\n // clear up discarded scales\n helpers$1.each(updated, function (hasUpdated, id) {\n if (!hasUpdated) {\n delete scales[id];\n }\n });\n me.scales = scales;\n core_scaleService.addScalesToLayout(this);\n },\n buildOrUpdateControllers: function () {\n var me = this;\n var newControllers = [];\n var datasets = me.data.datasets;\n var i, ilen;\n for (i = 0, ilen = datasets.length; i < ilen; i++) {\n var dataset = datasets[i];\n var meta = me.getDatasetMeta(i);\n var type = dataset.type || me.config.type;\n if (meta.type && meta.type !== type) {\n me.destroyDatasetMeta(i);\n meta = me.getDatasetMeta(i);\n }\n meta.type = type;\n meta.order = dataset.order || 0;\n meta.index = i;\n if (meta.controller) {\n meta.controller.updateIndex(i);\n meta.controller.linkScales();\n } else {\n var ControllerClass = controllers[meta.type];\n if (ControllerClass === undefined) {\n throw new Error('\"' + meta.type + '\" is not a chart type.');\n }\n meta.controller = new ControllerClass(me, i);\n newControllers.push(meta.controller);\n }\n }\n return newControllers;\n },\n /**\r\n * Reset the elements of all datasets\r\n * @private\r\n */\n resetElements: function () {\n var me = this;\n helpers$1.each(me.data.datasets, function (dataset, datasetIndex) {\n me.getDatasetMeta(datasetIndex).controller.reset();\n }, me);\n },\n /**\r\n * Resets the chart back to it's state before the initial animation\r\n */\n reset: function () {\n this.resetElements();\n this.tooltip.initialize();\n },\n update: function (config) {\n var me = this;\n var i, ilen;\n if (!config || typeof config !== 'object') {\n // backwards compatibility\n config = {\n duration: config,\n lazy: arguments[1]\n };\n }\n updateConfig(me);\n\n // plugins options references might have change, let's invalidate the cache\n // https://github.com/chartjs/Chart.js/issues/5111#issuecomment-355934167\n core_plugins._invalidate(me);\n if (core_plugins.notify(me, 'beforeUpdate') === false) {\n return;\n }\n\n // In case the entire data object changed\n me.tooltip._data = me.data;\n\n // Make sure dataset controllers are updated and new controllers are reset\n var newControllers = me.buildOrUpdateControllers();\n\n // Make sure all dataset controllers have correct meta data counts\n for (i = 0, ilen = me.data.datasets.length; i < ilen; i++) {\n me.getDatasetMeta(i).controller.buildOrUpdateElements();\n }\n me.updateLayout();\n\n // Can only reset the new controllers after the scales have been updated\n if (me.options.animation && me.options.animation.duration) {\n helpers$1.each(newControllers, function (controller) {\n controller.reset();\n });\n }\n me.updateDatasets();\n\n // Need to reset tooltip in case it is displayed with elements that are removed\n // after update.\n me.tooltip.initialize();\n\n // Last active contains items that were previously in the tooltip.\n // When we reset the tooltip, we need to clear it\n me.lastActive = [];\n\n // Do this before render so that any plugins that need final scale updates can use it\n core_plugins.notify(me, 'afterUpdate');\n me._layers.sort(compare2Level('z', '_idx'));\n if (me._bufferedRender) {\n me._bufferedRequest = {\n duration: config.duration,\n easing: config.easing,\n lazy: config.lazy\n };\n } else {\n me.render(config);\n }\n },\n /**\r\n * Updates the chart layout unless a plugin returns `false` to the `beforeLayout`\r\n * hook, in which case, plugins will not be called on `afterLayout`.\r\n * @private\r\n */\n updateLayout: function () {\n var me = this;\n if (core_plugins.notify(me, 'beforeLayout') === false) {\n return;\n }\n core_layouts.update(this, this.width, this.height);\n me._layers = [];\n helpers$1.each(me.boxes, function (box) {\n // _configure is called twice, once in core.scale.update and once here.\n // Here the boxes are fully updated and at their final positions.\n if (box._configure) {\n box._configure();\n }\n me._layers.push.apply(me._layers, box._layers());\n }, me);\n me._layers.forEach(function (item, index) {\n item._idx = index;\n });\n\n /**\r\n * Provided for backward compatibility, use `afterLayout` instead.\r\n * @method IPlugin#afterScaleUpdate\r\n * @deprecated since version 2.5.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_plugins.notify(me, 'afterScaleUpdate');\n core_plugins.notify(me, 'afterLayout');\n },\n /**\r\n * Updates all datasets unless a plugin returns `false` to the `beforeDatasetsUpdate`\r\n * hook, in which case, plugins will not be called on `afterDatasetsUpdate`.\r\n * @private\r\n */\n updateDatasets: function () {\n var me = this;\n if (core_plugins.notify(me, 'beforeDatasetsUpdate') === false) {\n return;\n }\n for (var i = 0, ilen = me.data.datasets.length; i < ilen; ++i) {\n me.updateDataset(i);\n }\n core_plugins.notify(me, 'afterDatasetsUpdate');\n },\n /**\r\n * Updates dataset at index unless a plugin returns `false` to the `beforeDatasetUpdate`\r\n * hook, in which case, plugins will not be called on `afterDatasetUpdate`.\r\n * @private\r\n */\n updateDataset: function (index) {\n var me = this;\n var meta = me.getDatasetMeta(index);\n var args = {\n meta: meta,\n index: index\n };\n if (core_plugins.notify(me, 'beforeDatasetUpdate', [args]) === false) {\n return;\n }\n meta.controller._update();\n core_plugins.notify(me, 'afterDatasetUpdate', [args]);\n },\n render: function (config) {\n var me = this;\n if (!config || typeof config !== 'object') {\n // backwards compatibility\n config = {\n duration: config,\n lazy: arguments[1]\n };\n }\n var animationOptions = me.options.animation;\n var duration = valueOrDefault$9(config.duration, animationOptions && animationOptions.duration);\n var lazy = config.lazy;\n if (core_plugins.notify(me, 'beforeRender') === false) {\n return;\n }\n var onComplete = function (animation) {\n core_plugins.notify(me, 'afterRender');\n helpers$1.callback(animationOptions && animationOptions.onComplete, [animation], me);\n };\n if (animationOptions && duration) {\n var animation = new core_animation({\n numSteps: duration / 16.66,\n // 60 fps\n easing: config.easing || animationOptions.easing,\n render: function (chart, animationObject) {\n var easingFunction = helpers$1.easing.effects[animationObject.easing];\n var currentStep = animationObject.currentStep;\n var stepDecimal = currentStep / animationObject.numSteps;\n chart.draw(easingFunction(stepDecimal), stepDecimal, currentStep);\n },\n onAnimationProgress: animationOptions.onProgress,\n onAnimationComplete: onComplete\n });\n core_animations.addAnimation(me, animation, duration, lazy);\n } else {\n me.draw();\n\n // See https://github.com/chartjs/Chart.js/issues/3781\n onComplete(new core_animation({\n numSteps: 0,\n chart: me\n }));\n }\n return me;\n },\n draw: function (easingValue) {\n var me = this;\n var i, layers;\n me.clear();\n if (helpers$1.isNullOrUndef(easingValue)) {\n easingValue = 1;\n }\n me.transition(easingValue);\n if (me.width <= 0 || me.height <= 0) {\n return;\n }\n if (core_plugins.notify(me, 'beforeDraw', [easingValue]) === false) {\n return;\n }\n\n // Because of plugin hooks (before/afterDatasetsDraw), datasets can't\n // currently be part of layers. Instead, we draw\n // layers <= 0 before(default, backward compat), and the rest after\n layers = me._layers;\n for (i = 0; i < layers.length && layers[i].z <= 0; ++i) {\n layers[i].draw(me.chartArea);\n }\n me.drawDatasets(easingValue);\n\n // Rest of layers\n for (; i < layers.length; ++i) {\n layers[i].draw(me.chartArea);\n }\n me._drawTooltip(easingValue);\n core_plugins.notify(me, 'afterDraw', [easingValue]);\n },\n /**\r\n * @private\r\n */\n transition: function (easingValue) {\n var me = this;\n for (var i = 0, ilen = (me.data.datasets || []).length; i < ilen; ++i) {\n if (me.isDatasetVisible(i)) {\n me.getDatasetMeta(i).controller.transition(easingValue);\n }\n }\n me.tooltip.transition(easingValue);\n },\n /**\r\n * @private\r\n */\n _getSortedDatasetMetas: function (filterVisible) {\n var me = this;\n var datasets = me.data.datasets || [];\n var result = [];\n var i, ilen;\n for (i = 0, ilen = datasets.length; i < ilen; ++i) {\n if (!filterVisible || me.isDatasetVisible(i)) {\n result.push(me.getDatasetMeta(i));\n }\n }\n result.sort(compare2Level('order', 'index'));\n return result;\n },\n /**\r\n * @private\r\n */\n _getSortedVisibleDatasetMetas: function () {\n return this._getSortedDatasetMetas(true);\n },\n /**\r\n * Draws all datasets unless a plugin returns `false` to the `beforeDatasetsDraw`\r\n * hook, in which case, plugins will not be called on `afterDatasetsDraw`.\r\n * @private\r\n */\n drawDatasets: function (easingValue) {\n var me = this;\n var metasets, i;\n if (core_plugins.notify(me, 'beforeDatasetsDraw', [easingValue]) === false) {\n return;\n }\n metasets = me._getSortedVisibleDatasetMetas();\n for (i = metasets.length - 1; i >= 0; --i) {\n me.drawDataset(metasets[i], easingValue);\n }\n core_plugins.notify(me, 'afterDatasetsDraw', [easingValue]);\n },\n /**\r\n * Draws dataset at index unless a plugin returns `false` to the `beforeDatasetDraw`\r\n * hook, in which case, plugins will not be called on `afterDatasetDraw`.\r\n * @private\r\n */\n drawDataset: function (meta, easingValue) {\n var me = this;\n var args = {\n meta: meta,\n index: meta.index,\n easingValue: easingValue\n };\n if (core_plugins.notify(me, 'beforeDatasetDraw', [args]) === false) {\n return;\n }\n meta.controller.draw(easingValue);\n core_plugins.notify(me, 'afterDatasetDraw', [args]);\n },\n /**\r\n * Draws tooltip unless a plugin returns `false` to the `beforeTooltipDraw`\r\n * hook, in which case, plugins will not be called on `afterTooltipDraw`.\r\n * @private\r\n */\n _drawTooltip: function (easingValue) {\n var me = this;\n var tooltip = me.tooltip;\n var args = {\n tooltip: tooltip,\n easingValue: easingValue\n };\n if (core_plugins.notify(me, 'beforeTooltipDraw', [args]) === false) {\n return;\n }\n tooltip.draw();\n core_plugins.notify(me, 'afterTooltipDraw', [args]);\n },\n /**\r\n * Get the single element that was clicked on\r\n * @return An object containing the dataset index and element index of the matching element. Also contains the rectangle that was draw\r\n */\n getElementAtEvent: function (e) {\n return core_interaction.modes.single(this, e);\n },\n getElementsAtEvent: function (e) {\n return core_interaction.modes.label(this, e, {\n intersect: true\n });\n },\n getElementsAtXAxis: function (e) {\n return core_interaction.modes['x-axis'](this, e, {\n intersect: true\n });\n },\n getElementsAtEventForMode: function (e, mode, options) {\n var method = core_interaction.modes[mode];\n if (typeof method === 'function') {\n return method(this, e, options);\n }\n return [];\n },\n getDatasetAtEvent: function (e) {\n return core_interaction.modes.dataset(this, e, {\n intersect: true\n });\n },\n getDatasetMeta: function (datasetIndex) {\n var me = this;\n var dataset = me.data.datasets[datasetIndex];\n if (!dataset._meta) {\n dataset._meta = {};\n }\n var meta = dataset._meta[me.id];\n if (!meta) {\n meta = dataset._meta[me.id] = {\n type: null,\n data: [],\n dataset: null,\n controller: null,\n hidden: null,\n // See isDatasetVisible() comment\n xAxisID: null,\n yAxisID: null,\n order: dataset.order || 0,\n index: datasetIndex\n };\n }\n return meta;\n },\n getVisibleDatasetCount: function () {\n var count = 0;\n for (var i = 0, ilen = this.data.datasets.length; i < ilen; ++i) {\n if (this.isDatasetVisible(i)) {\n count++;\n }\n }\n return count;\n },\n isDatasetVisible: function (datasetIndex) {\n var meta = this.getDatasetMeta(datasetIndex);\n\n // meta.hidden is a per chart dataset hidden flag override with 3 states: if true or false,\n // the dataset.hidden value is ignored, else if null, the dataset hidden state is returned.\n return typeof meta.hidden === 'boolean' ? !meta.hidden : !this.data.datasets[datasetIndex].hidden;\n },\n generateLegend: function () {\n return this.options.legendCallback(this);\n },\n /**\r\n * @private\r\n */\n destroyDatasetMeta: function (datasetIndex) {\n var id = this.id;\n var dataset = this.data.datasets[datasetIndex];\n var meta = dataset._meta && dataset._meta[id];\n if (meta) {\n meta.controller.destroy();\n delete dataset._meta[id];\n }\n },\n destroy: function () {\n var me = this;\n var canvas = me.canvas;\n var i, ilen;\n me.stop();\n\n // dataset controllers need to cleanup associated data\n for (i = 0, ilen = me.data.datasets.length; i < ilen; ++i) {\n me.destroyDatasetMeta(i);\n }\n if (canvas) {\n me.unbindEvents();\n helpers$1.canvas.clear(me);\n platform.releaseContext(me.ctx);\n me.canvas = null;\n me.ctx = null;\n }\n core_plugins.notify(me, 'destroy');\n delete Chart.instances[me.id];\n },\n toBase64Image: function () {\n return this.canvas.toDataURL.apply(this.canvas, arguments);\n },\n initToolTip: function () {\n var me = this;\n me.tooltip = new core_tooltip({\n _chart: me,\n _chartInstance: me,\n // deprecated, backward compatibility\n _data: me.data,\n _options: me.options.tooltips\n }, me);\n },\n /**\r\n * @private\r\n */\n bindEvents: function () {\n var me = this;\n var listeners = me._listeners = {};\n var listener = function () {\n me.eventHandler.apply(me, arguments);\n };\n helpers$1.each(me.options.events, function (type) {\n platform.addEventListener(me, type, listener);\n listeners[type] = listener;\n });\n\n // Elements used to detect size change should not be injected for non responsive charts.\n // See https://github.com/chartjs/Chart.js/issues/2210\n if (me.options.responsive) {\n listener = function () {\n me.resize();\n };\n platform.addEventListener(me, 'resize', listener);\n listeners.resize = listener;\n }\n },\n /**\r\n * @private\r\n */\n unbindEvents: function () {\n var me = this;\n var listeners = me._listeners;\n if (!listeners) {\n return;\n }\n delete me._listeners;\n helpers$1.each(listeners, function (listener, type) {\n platform.removeEventListener(me, type, listener);\n });\n },\n updateHoverStyle: function (elements, mode, enabled) {\n var prefix = enabled ? 'set' : 'remove';\n var element, i, ilen;\n for (i = 0, ilen = elements.length; i < ilen; ++i) {\n element = elements[i];\n if (element) {\n this.getDatasetMeta(element._datasetIndex).controller[prefix + 'HoverStyle'](element);\n }\n }\n if (mode === 'dataset') {\n this.getDatasetMeta(elements[0]._datasetIndex).controller['_' + prefix + 'DatasetHoverStyle']();\n }\n },\n /**\r\n * @private\r\n */\n eventHandler: function (e) {\n var me = this;\n var tooltip = me.tooltip;\n if (core_plugins.notify(me, 'beforeEvent', [e]) === false) {\n return;\n }\n\n // Buffer any update calls so that renders do not occur\n me._bufferedRender = true;\n me._bufferedRequest = null;\n var changed = me.handleEvent(e);\n // for smooth tooltip animations issue #4989\n // the tooltip should be the source of change\n // Animation check workaround:\n // tooltip._start will be null when tooltip isn't animating\n if (tooltip) {\n changed = tooltip._start ? tooltip.handleEvent(e) : changed | tooltip.handleEvent(e);\n }\n core_plugins.notify(me, 'afterEvent', [e]);\n var bufferedRequest = me._bufferedRequest;\n if (bufferedRequest) {\n // If we have an update that was triggered, we need to do a normal render\n me.render(bufferedRequest);\n } else if (changed && !me.animating) {\n // If entering, leaving, or changing elements, animate the change via pivot\n me.stop();\n\n // We only need to render at this point. Updating will cause scales to be\n // recomputed generating flicker & using more memory than necessary.\n me.render({\n duration: me.options.hover.animationDuration,\n lazy: true\n });\n }\n me._bufferedRender = false;\n me._bufferedRequest = null;\n return me;\n },\n /**\r\n * Handle an event\r\n * @private\r\n * @param {IEvent} event the event to handle\r\n * @return {boolean} true if the chart needs to re-render\r\n */\n handleEvent: function (e) {\n var me = this;\n var options = me.options || {};\n var hoverOptions = options.hover;\n var changed = false;\n me.lastActive = me.lastActive || [];\n\n // Find Active Elements for hover and tooltips\n if (e.type === 'mouseout') {\n me.active = [];\n } else {\n me.active = me.getElementsAtEventForMode(e, hoverOptions.mode, hoverOptions);\n }\n\n // Invoke onHover hook\n // Need to call with native event here to not break backwards compatibility\n helpers$1.callback(options.onHover || options.hover.onHover, [e.native, me.active], me);\n if (e.type === 'mouseup' || e.type === 'click') {\n if (options.onClick) {\n // Use e.native here for backwards compatibility\n options.onClick.call(me, e.native, me.active);\n }\n }\n\n // Remove styling for last active (even if it may still be active)\n if (me.lastActive.length) {\n me.updateHoverStyle(me.lastActive, hoverOptions.mode, false);\n }\n\n // Built in hover styling\n if (me.active.length && hoverOptions.mode) {\n me.updateHoverStyle(me.active, hoverOptions.mode, true);\n }\n changed = !helpers$1.arrayEquals(me.active, me.lastActive);\n\n // Remember Last Actives\n me.lastActive = me.active;\n return changed;\n }\n });\n\n /**\r\n * NOTE(SB) We actually don't use this container anymore but we need to keep it\r\n * for backward compatibility. Though, it can still be useful for plugins that\r\n * would need to work on multiple charts?!\r\n */\n Chart.instances = {};\n var core_controller = Chart;\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, use Chart instead.\r\n * @class Chart.Controller\r\n * @deprecated since version 2.6\r\n * @todo remove at version 3\r\n * @private\r\n */\n Chart.Controller = Chart;\n\n /**\r\n * Provided for backward compatibility, not available anymore.\r\n * @namespace Chart\r\n * @deprecated since version 2.8\r\n * @todo remove at version 3\r\n * @private\r\n */\n Chart.types = {};\n\n /**\r\n * Provided for backward compatibility, not available anymore.\r\n * @namespace Chart.helpers.configMerge\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers$1.configMerge = mergeConfig;\n\n /**\r\n * Provided for backward compatibility, not available anymore.\r\n * @namespace Chart.helpers.scaleMerge\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n helpers$1.scaleMerge = mergeScaleConfig;\n var core_helpers = function () {\n // -- Basic js utility methods\n\n helpers$1.where = function (collection, filterCallback) {\n if (helpers$1.isArray(collection) && Array.prototype.filter) {\n return collection.filter(filterCallback);\n }\n var filtered = [];\n helpers$1.each(collection, function (item) {\n if (filterCallback(item)) {\n filtered.push(item);\n }\n });\n return filtered;\n };\n helpers$1.findIndex = Array.prototype.findIndex ? function (array, callback, scope) {\n return array.findIndex(callback, scope);\n } : function (array, callback, scope) {\n scope = scope === undefined ? array : scope;\n for (var i = 0, ilen = array.length; i < ilen; ++i) {\n if (callback.call(scope, array[i], i, array)) {\n return i;\n }\n }\n return -1;\n };\n helpers$1.findNextWhere = function (arrayToSearch, filterCallback, startIndex) {\n // Default to start of the array\n if (helpers$1.isNullOrUndef(startIndex)) {\n startIndex = -1;\n }\n for (var i = startIndex + 1; i < arrayToSearch.length; i++) {\n var currentItem = arrayToSearch[i];\n if (filterCallback(currentItem)) {\n return currentItem;\n }\n }\n };\n helpers$1.findPreviousWhere = function (arrayToSearch, filterCallback, startIndex) {\n // Default to end of the array\n if (helpers$1.isNullOrUndef(startIndex)) {\n startIndex = arrayToSearch.length;\n }\n for (var i = startIndex - 1; i >= 0; i--) {\n var currentItem = arrayToSearch[i];\n if (filterCallback(currentItem)) {\n return currentItem;\n }\n }\n };\n\n // -- Math methods\n helpers$1.isNumber = function (n) {\n return !isNaN(parseFloat(n)) && isFinite(n);\n };\n helpers$1.almostEquals = function (x, y, epsilon) {\n return Math.abs(x - y) < epsilon;\n };\n helpers$1.almostWhole = function (x, epsilon) {\n var rounded = Math.round(x);\n return rounded - epsilon <= x && rounded + epsilon >= x;\n };\n helpers$1.max = function (array) {\n return array.reduce(function (max, value) {\n if (!isNaN(value)) {\n return Math.max(max, value);\n }\n return max;\n }, Number.NEGATIVE_INFINITY);\n };\n helpers$1.min = function (array) {\n return array.reduce(function (min, value) {\n if (!isNaN(value)) {\n return Math.min(min, value);\n }\n return min;\n }, Number.POSITIVE_INFINITY);\n };\n helpers$1.sign = Math.sign ? function (x) {\n return Math.sign(x);\n } : function (x) {\n x = +x; // convert to a number\n if (x === 0 || isNaN(x)) {\n return x;\n }\n return x > 0 ? 1 : -1;\n };\n helpers$1.toRadians = function (degrees) {\n return degrees * (Math.PI / 180);\n };\n helpers$1.toDegrees = function (radians) {\n return radians * (180 / Math.PI);\n };\n\n /**\r\n * Returns the number of decimal places\r\n * i.e. the number of digits after the decimal point, of the value of this Number.\r\n * @param {number} x - A number.\r\n * @returns {number} The number of decimal places.\r\n * @private\r\n */\n helpers$1._decimalPlaces = function (x) {\n if (!helpers$1.isFinite(x)) {\n return;\n }\n var e = 1;\n var p = 0;\n while (Math.round(x * e) / e !== x) {\n e *= 10;\n p++;\n }\n return p;\n };\n\n // Gets the angle from vertical upright to the point about a centre.\n helpers$1.getAngleFromPoint = function (centrePoint, anglePoint) {\n var distanceFromXCenter = anglePoint.x - centrePoint.x;\n var distanceFromYCenter = anglePoint.y - centrePoint.y;\n var radialDistanceFromCenter = Math.sqrt(distanceFromXCenter * distanceFromXCenter + distanceFromYCenter * distanceFromYCenter);\n var angle = Math.atan2(distanceFromYCenter, distanceFromXCenter);\n if (angle < -0.5 * Math.PI) {\n angle += 2.0 * Math.PI; // make sure the returned angle is in the range of (-PI/2, 3PI/2]\n }\n return {\n angle: angle,\n distance: radialDistanceFromCenter\n };\n };\n helpers$1.distanceBetweenPoints = function (pt1, pt2) {\n return Math.sqrt(Math.pow(pt2.x - pt1.x, 2) + Math.pow(pt2.y - pt1.y, 2));\n };\n\n /**\r\n * Provided for backward compatibility, not available anymore\r\n * @function Chart.helpers.aliasPixel\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n */\n helpers$1.aliasPixel = function (pixelWidth) {\n return pixelWidth % 2 === 0 ? 0 : 0.5;\n };\n\n /**\r\n * Returns the aligned pixel value to avoid anti-aliasing blur\r\n * @param {Chart} chart - The chart instance.\r\n * @param {number} pixel - A pixel value.\r\n * @param {number} width - The width of the element.\r\n * @returns {number} The aligned pixel value.\r\n * @private\r\n */\n helpers$1._alignPixel = function (chart, pixel, width) {\n var devicePixelRatio = chart.currentDevicePixelRatio;\n var halfWidth = width / 2;\n return Math.round((pixel - halfWidth) * devicePixelRatio) / devicePixelRatio + halfWidth;\n };\n helpers$1.splineCurve = function (firstPoint, middlePoint, afterPoint, t) {\n // Props to Rob Spencer at scaled innovation for his post on splining between points\n // http://scaledinnovation.com/analytics/splines/aboutSplines.html\n\n // This function must also respect \"skipped\" points\n\n var previous = firstPoint.skip ? middlePoint : firstPoint;\n var current = middlePoint;\n var next = afterPoint.skip ? middlePoint : afterPoint;\n var d01 = Math.sqrt(Math.pow(current.x - previous.x, 2) + Math.pow(current.y - previous.y, 2));\n var d12 = Math.sqrt(Math.pow(next.x - current.x, 2) + Math.pow(next.y - current.y, 2));\n var s01 = d01 / (d01 + d12);\n var s12 = d12 / (d01 + d12);\n\n // If all points are the same, s01 & s02 will be inf\n s01 = isNaN(s01) ? 0 : s01;\n s12 = isNaN(s12) ? 0 : s12;\n var fa = t * s01; // scaling factor for triangle Ta\n var fb = t * s12;\n return {\n previous: {\n x: current.x - fa * (next.x - previous.x),\n y: current.y - fa * (next.y - previous.y)\n },\n next: {\n x: current.x + fb * (next.x - previous.x),\n y: current.y + fb * (next.y - previous.y)\n }\n };\n };\n helpers$1.EPSILON = Number.EPSILON || 1e-14;\n helpers$1.splineCurveMonotone = function (points) {\n // This function calculates Bézier control points in a similar way than |splineCurve|,\n // but preserves monotonicity of the provided data and ensures no local extremums are added\n // between the dataset discrete points due to the interpolation.\n // See : https://en.wikipedia.org/wiki/Monotone_cubic_interpolation\n\n var pointsWithTangents = (points || []).map(function (point) {\n return {\n model: point._model,\n deltaK: 0,\n mK: 0\n };\n });\n\n // Calculate slopes (deltaK) and initialize tangents (mK)\n var pointsLen = pointsWithTangents.length;\n var i, pointBefore, pointCurrent, pointAfter;\n for (i = 0; i < pointsLen; ++i) {\n pointCurrent = pointsWithTangents[i];\n if (pointCurrent.model.skip) {\n continue;\n }\n pointBefore = i > 0 ? pointsWithTangents[i - 1] : null;\n pointAfter = i < pointsLen - 1 ? pointsWithTangents[i + 1] : null;\n if (pointAfter && !pointAfter.model.skip) {\n var slopeDeltaX = pointAfter.model.x - pointCurrent.model.x;\n\n // In the case of two points that appear at the same x pixel, slopeDeltaX is 0\n pointCurrent.deltaK = slopeDeltaX !== 0 ? (pointAfter.model.y - pointCurrent.model.y) / slopeDeltaX : 0;\n }\n if (!pointBefore || pointBefore.model.skip) {\n pointCurrent.mK = pointCurrent.deltaK;\n } else if (!pointAfter || pointAfter.model.skip) {\n pointCurrent.mK = pointBefore.deltaK;\n } else if (this.sign(pointBefore.deltaK) !== this.sign(pointCurrent.deltaK)) {\n pointCurrent.mK = 0;\n } else {\n pointCurrent.mK = (pointBefore.deltaK + pointCurrent.deltaK) / 2;\n }\n }\n\n // Adjust tangents to ensure monotonic properties\n var alphaK, betaK, tauK, squaredMagnitude;\n for (i = 0; i < pointsLen - 1; ++i) {\n pointCurrent = pointsWithTangents[i];\n pointAfter = pointsWithTangents[i + 1];\n if (pointCurrent.model.skip || pointAfter.model.skip) {\n continue;\n }\n if (helpers$1.almostEquals(pointCurrent.deltaK, 0, this.EPSILON)) {\n pointCurrent.mK = pointAfter.mK = 0;\n continue;\n }\n alphaK = pointCurrent.mK / pointCurrent.deltaK;\n betaK = pointAfter.mK / pointCurrent.deltaK;\n squaredMagnitude = Math.pow(alphaK, 2) + Math.pow(betaK, 2);\n if (squaredMagnitude <= 9) {\n continue;\n }\n tauK = 3 / Math.sqrt(squaredMagnitude);\n pointCurrent.mK = alphaK * tauK * pointCurrent.deltaK;\n pointAfter.mK = betaK * tauK * pointCurrent.deltaK;\n }\n\n // Compute control points\n var deltaX;\n for (i = 0; i < pointsLen; ++i) {\n pointCurrent = pointsWithTangents[i];\n if (pointCurrent.model.skip) {\n continue;\n }\n pointBefore = i > 0 ? pointsWithTangents[i - 1] : null;\n pointAfter = i < pointsLen - 1 ? pointsWithTangents[i + 1] : null;\n if (pointBefore && !pointBefore.model.skip) {\n deltaX = (pointCurrent.model.x - pointBefore.model.x) / 3;\n pointCurrent.model.controlPointPreviousX = pointCurrent.model.x - deltaX;\n pointCurrent.model.controlPointPreviousY = pointCurrent.model.y - deltaX * pointCurrent.mK;\n }\n if (pointAfter && !pointAfter.model.skip) {\n deltaX = (pointAfter.model.x - pointCurrent.model.x) / 3;\n pointCurrent.model.controlPointNextX = pointCurrent.model.x + deltaX;\n pointCurrent.model.controlPointNextY = pointCurrent.model.y + deltaX * pointCurrent.mK;\n }\n }\n };\n helpers$1.nextItem = function (collection, index, loop) {\n if (loop) {\n return index >= collection.length - 1 ? collection[0] : collection[index + 1];\n }\n return index >= collection.length - 1 ? collection[collection.length - 1] : collection[index + 1];\n };\n helpers$1.previousItem = function (collection, index, loop) {\n if (loop) {\n return index <= 0 ? collection[collection.length - 1] : collection[index - 1];\n }\n return index <= 0 ? collection[0] : collection[index - 1];\n };\n // Implementation of the nice number algorithm used in determining where axis labels will go\n helpers$1.niceNum = function (range, round) {\n var exponent = Math.floor(helpers$1.log10(range));\n var fraction = range / Math.pow(10, exponent);\n var niceFraction;\n if (round) {\n if (fraction < 1.5) {\n niceFraction = 1;\n } else if (fraction < 3) {\n niceFraction = 2;\n } else if (fraction < 7) {\n niceFraction = 5;\n } else {\n niceFraction = 10;\n }\n } else if (fraction <= 1.0) {\n niceFraction = 1;\n } else if (fraction <= 2) {\n niceFraction = 2;\n } else if (fraction <= 5) {\n niceFraction = 5;\n } else {\n niceFraction = 10;\n }\n return niceFraction * Math.pow(10, exponent);\n };\n // Request animation polyfill - https://www.paulirish.com/2011/requestanimationframe-for-smart-animating/\n helpers$1.requestAnimFrame = function () {\n if (typeof window === 'undefined') {\n return function (callback) {\n callback();\n };\n }\n return window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || window.oRequestAnimationFrame || window.msRequestAnimationFrame || function (callback) {\n return window.setTimeout(callback, 1000 / 60);\n };\n }();\n // -- DOM methods\n helpers$1.getRelativePosition = function (evt, chart) {\n var mouseX, mouseY;\n var e = evt.originalEvent || evt;\n var canvas = evt.target || evt.srcElement;\n var boundingRect = canvas.getBoundingClientRect();\n var touches = e.touches;\n if (touches && touches.length > 0) {\n mouseX = touches[0].clientX;\n mouseY = touches[0].clientY;\n } else {\n mouseX = e.clientX;\n mouseY = e.clientY;\n }\n\n // Scale mouse coordinates into canvas coordinates\n // by following the pattern laid out by 'jerryj' in the comments of\n // https://www.html5canvastutorials.com/advanced/html5-canvas-mouse-coordinates/\n var paddingLeft = parseFloat(helpers$1.getStyle(canvas, 'padding-left'));\n var paddingTop = parseFloat(helpers$1.getStyle(canvas, 'padding-top'));\n var paddingRight = parseFloat(helpers$1.getStyle(canvas, 'padding-right'));\n var paddingBottom = parseFloat(helpers$1.getStyle(canvas, 'padding-bottom'));\n var width = boundingRect.right - boundingRect.left - paddingLeft - paddingRight;\n var height = boundingRect.bottom - boundingRect.top - paddingTop - paddingBottom;\n\n // We divide by the current device pixel ratio, because the canvas is scaled up by that amount in each direction. However\n // the backend model is in unscaled coordinates. Since we are going to deal with our model coordinates, we go back here\n mouseX = Math.round((mouseX - boundingRect.left - paddingLeft) / width * canvas.width / chart.currentDevicePixelRatio);\n mouseY = Math.round((mouseY - boundingRect.top - paddingTop) / height * canvas.height / chart.currentDevicePixelRatio);\n return {\n x: mouseX,\n y: mouseY\n };\n };\n\n // Private helper function to convert max-width/max-height values that may be percentages into a number\n function parseMaxStyle(styleValue, node, parentProperty) {\n var valueInPixels;\n if (typeof styleValue === 'string') {\n valueInPixels = parseInt(styleValue, 10);\n if (styleValue.indexOf('%') !== -1) {\n // percentage * size in dimension\n valueInPixels = valueInPixels / 100 * node.parentNode[parentProperty];\n }\n } else {\n valueInPixels = styleValue;\n }\n return valueInPixels;\n }\n\n /**\r\n * Returns if the given value contains an effective constraint.\r\n * @private\r\n */\n function isConstrainedValue(value) {\n return value !== undefined && value !== null && value !== 'none';\n }\n\n /**\r\n * Returns the max width or height of the given DOM node in a cross-browser compatible fashion\r\n * @param {HTMLElement} domNode - the node to check the constraint on\r\n * @param {string} maxStyle - the style that defines the maximum for the direction we are using ('max-width' / 'max-height')\r\n * @param {string} percentageProperty - property of parent to use when calculating width as a percentage\r\n * @see {@link https://www.nathanaeljones.com/blog/2013/reading-max-width-cross-browser}\r\n */\n function getConstraintDimension(domNode, maxStyle, percentageProperty) {\n var view = document.defaultView;\n var parentNode = helpers$1._getParentNode(domNode);\n var constrainedNode = view.getComputedStyle(domNode)[maxStyle];\n var constrainedContainer = view.getComputedStyle(parentNode)[maxStyle];\n var hasCNode = isConstrainedValue(constrainedNode);\n var hasCContainer = isConstrainedValue(constrainedContainer);\n var infinity = Number.POSITIVE_INFINITY;\n if (hasCNode || hasCContainer) {\n return Math.min(hasCNode ? parseMaxStyle(constrainedNode, domNode, percentageProperty) : infinity, hasCContainer ? parseMaxStyle(constrainedContainer, parentNode, percentageProperty) : infinity);\n }\n return 'none';\n }\n // returns Number or undefined if no constraint\n helpers$1.getConstraintWidth = function (domNode) {\n return getConstraintDimension(domNode, 'max-width', 'clientWidth');\n };\n // returns Number or undefined if no constraint\n helpers$1.getConstraintHeight = function (domNode) {\n return getConstraintDimension(domNode, 'max-height', 'clientHeight');\n };\n /**\r\n * @private\r\n \t */\n helpers$1._calculatePadding = function (container, padding, parentDimension) {\n padding = helpers$1.getStyle(container, padding);\n return padding.indexOf('%') > -1 ? parentDimension * parseInt(padding, 10) / 100 : parseInt(padding, 10);\n };\n /**\r\n * @private\r\n */\n helpers$1._getParentNode = function (domNode) {\n var parent = domNode.parentNode;\n if (parent && parent.toString() === '[object ShadowRoot]') {\n parent = parent.host;\n }\n return parent;\n };\n helpers$1.getMaximumWidth = function (domNode) {\n var container = helpers$1._getParentNode(domNode);\n if (!container) {\n return domNode.clientWidth;\n }\n var clientWidth = container.clientWidth;\n var paddingLeft = helpers$1._calculatePadding(container, 'padding-left', clientWidth);\n var paddingRight = helpers$1._calculatePadding(container, 'padding-right', clientWidth);\n var w = clientWidth - paddingLeft - paddingRight;\n var cw = helpers$1.getConstraintWidth(domNode);\n return isNaN(cw) ? w : Math.min(w, cw);\n };\n helpers$1.getMaximumHeight = function (domNode) {\n var container = helpers$1._getParentNode(domNode);\n if (!container) {\n return domNode.clientHeight;\n }\n var clientHeight = container.clientHeight;\n var paddingTop = helpers$1._calculatePadding(container, 'padding-top', clientHeight);\n var paddingBottom = helpers$1._calculatePadding(container, 'padding-bottom', clientHeight);\n var h = clientHeight - paddingTop - paddingBottom;\n var ch = helpers$1.getConstraintHeight(domNode);\n return isNaN(ch) ? h : Math.min(h, ch);\n };\n helpers$1.getStyle = function (el, property) {\n return el.currentStyle ? el.currentStyle[property] : document.defaultView.getComputedStyle(el, null).getPropertyValue(property);\n };\n helpers$1.retinaScale = function (chart, forceRatio) {\n var pixelRatio = chart.currentDevicePixelRatio = forceRatio || typeof window !== 'undefined' && window.devicePixelRatio || 1;\n if (pixelRatio === 1) {\n return;\n }\n var canvas = chart.canvas;\n var height = chart.height;\n var width = chart.width;\n canvas.height = height * pixelRatio;\n canvas.width = width * pixelRatio;\n chart.ctx.scale(pixelRatio, pixelRatio);\n\n // If no style has been set on the canvas, the render size is used as display size,\n // making the chart visually bigger, so let's enforce it to the \"correct\" values.\n // See https://github.com/chartjs/Chart.js/issues/3575\n if (!canvas.style.height && !canvas.style.width) {\n canvas.style.height = height + 'px';\n canvas.style.width = width + 'px';\n }\n };\n // -- Canvas methods\n helpers$1.fontString = function (pixelSize, fontStyle, fontFamily) {\n return fontStyle + ' ' + pixelSize + 'px ' + fontFamily;\n };\n helpers$1.longestText = function (ctx, font, arrayOfThings, cache) {\n cache = cache || {};\n var data = cache.data = cache.data || {};\n var gc = cache.garbageCollect = cache.garbageCollect || [];\n if (cache.font !== font) {\n data = cache.data = {};\n gc = cache.garbageCollect = [];\n cache.font = font;\n }\n ctx.font = font;\n var longest = 0;\n var ilen = arrayOfThings.length;\n var i, j, jlen, thing, nestedThing;\n for (i = 0; i < ilen; i++) {\n thing = arrayOfThings[i];\n\n // Undefined strings and arrays should not be measured\n if (thing !== undefined && thing !== null && helpers$1.isArray(thing) !== true) {\n longest = helpers$1.measureText(ctx, data, gc, longest, thing);\n } else if (helpers$1.isArray(thing)) {\n // if it is an array lets measure each element\n // to do maybe simplify this function a bit so we can do this more recursively?\n for (j = 0, jlen = thing.length; j < jlen; j++) {\n nestedThing = thing[j];\n // Undefined strings and arrays should not be measured\n if (nestedThing !== undefined && nestedThing !== null && !helpers$1.isArray(nestedThing)) {\n longest = helpers$1.measureText(ctx, data, gc, longest, nestedThing);\n }\n }\n }\n }\n var gcLen = gc.length / 2;\n if (gcLen > arrayOfThings.length) {\n for (i = 0; i < gcLen; i++) {\n delete data[gc[i]];\n }\n gc.splice(0, gcLen);\n }\n return longest;\n };\n helpers$1.measureText = function (ctx, data, gc, longest, string) {\n var textWidth = data[string];\n if (!textWidth) {\n textWidth = data[string] = ctx.measureText(string).width;\n gc.push(string);\n }\n if (textWidth > longest) {\n longest = textWidth;\n }\n return longest;\n };\n\n /**\r\n * @deprecated\r\n */\n helpers$1.numberOfLabelLines = function (arrayOfThings) {\n var numberOfLines = 1;\n helpers$1.each(arrayOfThings, function (thing) {\n if (helpers$1.isArray(thing)) {\n if (thing.length > numberOfLines) {\n numberOfLines = thing.length;\n }\n }\n });\n return numberOfLines;\n };\n helpers$1.color = !chartjsColor ? function (value) {\n console.error('Color.js not found!');\n return value;\n } : function (value) {\n /* global CanvasGradient */\n if (value instanceof CanvasGradient) {\n value = core_defaults.global.defaultColor;\n }\n return chartjsColor(value);\n };\n helpers$1.getHoverColor = function (colorValue) {\n /* global CanvasPattern */\n return colorValue instanceof CanvasPattern || colorValue instanceof CanvasGradient ? colorValue : helpers$1.color(colorValue).saturate(0.5).darken(0.1).rgbString();\n };\n };\n function abstract() {\n throw new Error('This method is not implemented: either no adapter can ' + 'be found or an incomplete integration was provided.');\n }\n\n /**\r\n * Date adapter (current used by the time scale)\r\n * @namespace Chart._adapters._date\r\n * @memberof Chart._adapters\r\n * @private\r\n */\n\n /**\r\n * Currently supported unit string values.\r\n * @typedef {('millisecond'|'second'|'minute'|'hour'|'day'|'week'|'month'|'quarter'|'year')}\r\n * @memberof Chart._adapters._date\r\n * @name Unit\r\n */\n\n /**\r\n * @class\r\n */\n function DateAdapter(options) {\n this.options = options || {};\n }\n helpers$1.extend(DateAdapter.prototype, /** @lends DateAdapter */{\n /**\r\n * Returns a map of time formats for the supported formatting units defined\r\n * in Unit as well as 'datetime' representing a detailed date/time string.\r\n * @returns {{string: string}}\r\n */\n formats: abstract,\n /**\r\n * Parses the given `value` and return the associated timestamp.\r\n * @param {any} value - the value to parse (usually comes from the data)\r\n * @param {string} [format] - the expected data format\r\n * @returns {(number|null)}\r\n * @function\r\n */\n parse: abstract,\n /**\r\n * Returns the formatted date in the specified `format` for a given `timestamp`.\r\n * @param {number} timestamp - the timestamp to format\r\n * @param {string} format - the date/time token\r\n * @return {string}\r\n * @function\r\n */\n format: abstract,\n /**\r\n * Adds the specified `amount` of `unit` to the given `timestamp`.\r\n * @param {number} timestamp - the input timestamp\r\n * @param {number} amount - the amount to add\r\n * @param {Unit} unit - the unit as string\r\n * @return {number}\r\n * @function\r\n */\n add: abstract,\n /**\r\n * Returns the number of `unit` between the given timestamps.\r\n * @param {number} max - the input timestamp (reference)\r\n * @param {number} min - the timestamp to substract\r\n * @param {Unit} unit - the unit as string\r\n * @return {number}\r\n * @function\r\n */\n diff: abstract,\n /**\r\n * Returns start of `unit` for the given `timestamp`.\r\n * @param {number} timestamp - the input timestamp\r\n * @param {Unit} unit - the unit as string\r\n * @param {number} [weekday] - the ISO day of the week with 1 being Monday\r\n * and 7 being Sunday (only needed if param *unit* is `isoWeek`).\r\n * @function\r\n */\n startOf: abstract,\n /**\r\n * Returns end of `unit` for the given `timestamp`.\r\n * @param {number} timestamp - the input timestamp\r\n * @param {Unit} unit - the unit as string\r\n * @function\r\n */\n endOf: abstract,\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility for scale.getValueForPixel(),\r\n * this method should be overridden only by the moment adapter.\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n _create: function (value) {\n return value;\n }\n });\n DateAdapter.override = function (members) {\n helpers$1.extend(DateAdapter.prototype, members);\n };\n var _date = DateAdapter;\n var core_adapters = {\n _date: _date\n };\n\n /**\r\n * Namespace to hold static tick generation functions\r\n * @namespace Chart.Ticks\r\n */\n var core_ticks = {\n /**\r\n * Namespace to hold formatters for different types of ticks\r\n * @namespace Chart.Ticks.formatters\r\n */\n formatters: {\n /**\r\n * Formatter for value labels\r\n * @method Chart.Ticks.formatters.values\r\n * @param value the value to display\r\n * @return {string|string[]} the label to display\r\n */\n values: function (value) {\n return helpers$1.isArray(value) ? value : '' + value;\n },\n /**\r\n * Formatter for linear numeric ticks\r\n * @method Chart.Ticks.formatters.linear\r\n * @param tickValue {number} the value to be formatted\r\n * @param index {number} the position of the tickValue parameter in the ticks array\r\n * @param ticks {number[]} the list of ticks being converted\r\n * @return {string} string representation of the tickValue parameter\r\n */\n linear: function (tickValue, index, ticks) {\n // If we have lots of ticks, don't use the ones\n var delta = ticks.length > 3 ? ticks[2] - ticks[1] : ticks[1] - ticks[0];\n\n // If we have a number like 2.5 as the delta, figure out how many decimal places we need\n if (Math.abs(delta) > 1) {\n if (tickValue !== Math.floor(tickValue)) {\n // not an integer\n delta = tickValue - Math.floor(tickValue);\n }\n }\n var logDelta = helpers$1.log10(Math.abs(delta));\n var tickString = '';\n if (tickValue !== 0) {\n var maxTick = Math.max(Math.abs(ticks[0]), Math.abs(ticks[ticks.length - 1]));\n if (maxTick < 1e-4) {\n // all ticks are small numbers; use scientific notation\n var logTick = helpers$1.log10(Math.abs(tickValue));\n var numExponential = Math.floor(logTick) - Math.floor(logDelta);\n numExponential = Math.max(Math.min(numExponential, 20), 0);\n tickString = tickValue.toExponential(numExponential);\n } else {\n var numDecimal = -1 * Math.floor(logDelta);\n numDecimal = Math.max(Math.min(numDecimal, 20), 0); // toFixed has a max of 20 decimal places\n tickString = tickValue.toFixed(numDecimal);\n }\n } else {\n tickString = '0'; // never show decimal places for 0\n }\n return tickString;\n },\n logarithmic: function (tickValue, index, ticks) {\n var remain = tickValue / Math.pow(10, Math.floor(helpers$1.log10(tickValue)));\n if (tickValue === 0) {\n return '0';\n } else if (remain === 1 || remain === 2 || remain === 5 || index === 0 || index === ticks.length - 1) {\n return tickValue.toExponential();\n }\n return '';\n }\n }\n };\n var isArray = helpers$1.isArray;\n var isNullOrUndef = helpers$1.isNullOrUndef;\n var valueOrDefault$a = helpers$1.valueOrDefault;\n var valueAtIndexOrDefault = helpers$1.valueAtIndexOrDefault;\n core_defaults._set('scale', {\n display: true,\n position: 'left',\n offset: false,\n // grid line settings\n gridLines: {\n display: true,\n color: 'rgba(0,0,0,0.1)',\n lineWidth: 1,\n drawBorder: true,\n drawOnChartArea: true,\n drawTicks: true,\n tickMarkLength: 10,\n zeroLineWidth: 1,\n zeroLineColor: 'rgba(0,0,0,0.25)',\n zeroLineBorderDash: [],\n zeroLineBorderDashOffset: 0.0,\n offsetGridLines: false,\n borderDash: [],\n borderDashOffset: 0.0\n },\n // scale label\n scaleLabel: {\n // display property\n display: false,\n // actual label\n labelString: '',\n // top/bottom padding\n padding: {\n top: 4,\n bottom: 4\n }\n },\n // label settings\n ticks: {\n beginAtZero: false,\n minRotation: 0,\n maxRotation: 50,\n mirror: false,\n padding: 0,\n reverse: false,\n display: true,\n autoSkip: true,\n autoSkipPadding: 0,\n labelOffset: 0,\n // We pass through arrays to be rendered as multiline labels, we convert Others to strings here.\n callback: core_ticks.formatters.values,\n minor: {},\n major: {}\n }\n });\n\n /** Returns a new array containing numItems from arr */\n function sample(arr, numItems) {\n var result = [];\n var increment = arr.length / numItems;\n var i = 0;\n var len = arr.length;\n for (; i < len; i += increment) {\n result.push(arr[Math.floor(i)]);\n }\n return result;\n }\n function getPixelForGridLine(scale, index, offsetGridLines) {\n var length = scale.getTicks().length;\n var validIndex = Math.min(index, length - 1);\n var lineValue = scale.getPixelForTick(validIndex);\n var start = scale._startPixel;\n var end = scale._endPixel;\n var epsilon = 1e-6; // 1e-6 is margin in pixels for accumulated error.\n var offset;\n if (offsetGridLines) {\n if (length === 1) {\n offset = Math.max(lineValue - start, end - lineValue);\n } else if (index === 0) {\n offset = (scale.getPixelForTick(1) - lineValue) / 2;\n } else {\n offset = (lineValue - scale.getPixelForTick(validIndex - 1)) / 2;\n }\n lineValue += validIndex < index ? offset : -offset;\n\n // Return undefined if the pixel is out of the range\n if (lineValue < start - epsilon || lineValue > end + epsilon) {\n return;\n }\n }\n return lineValue;\n }\n function garbageCollect(caches, length) {\n helpers$1.each(caches, function (cache) {\n var gc = cache.gc;\n var gcLen = gc.length / 2;\n var i;\n if (gcLen > length) {\n for (i = 0; i < gcLen; ++i) {\n delete cache.data[gc[i]];\n }\n gc.splice(0, gcLen);\n }\n });\n }\n\n /**\r\n * Returns {width, height, offset} objects for the first, last, widest, highest tick\r\n * labels where offset indicates the anchor point offset from the top in pixels.\r\n */\n function computeLabelSizes(ctx, tickFonts, ticks, caches) {\n var length = ticks.length;\n var widths = [];\n var heights = [];\n var offsets = [];\n var widestLabelSize = 0;\n var highestLabelSize = 0;\n var i, j, jlen, label, tickFont, fontString, cache, lineHeight, width, height, nestedLabel, widest, highest;\n for (i = 0; i < length; ++i) {\n label = ticks[i].label;\n tickFont = ticks[i].major ? tickFonts.major : tickFonts.minor;\n ctx.font = fontString = tickFont.string;\n cache = caches[fontString] = caches[fontString] || {\n data: {},\n gc: []\n };\n lineHeight = tickFont.lineHeight;\n width = height = 0;\n // Undefined labels and arrays should not be measured\n if (!isNullOrUndef(label) && !isArray(label)) {\n width = helpers$1.measureText(ctx, cache.data, cache.gc, width, label);\n height = lineHeight;\n } else if (isArray(label)) {\n // if it is an array let's measure each element\n for (j = 0, jlen = label.length; j < jlen; ++j) {\n nestedLabel = label[j];\n // Undefined labels and arrays should not be measured\n if (!isNullOrUndef(nestedLabel) && !isArray(nestedLabel)) {\n width = helpers$1.measureText(ctx, cache.data, cache.gc, width, nestedLabel);\n height += lineHeight;\n }\n }\n }\n widths.push(width);\n heights.push(height);\n offsets.push(lineHeight / 2);\n widestLabelSize = Math.max(width, widestLabelSize);\n highestLabelSize = Math.max(height, highestLabelSize);\n }\n garbageCollect(caches, length);\n widest = widths.indexOf(widestLabelSize);\n highest = heights.indexOf(highestLabelSize);\n function valueAt(idx) {\n return {\n width: widths[idx] || 0,\n height: heights[idx] || 0,\n offset: offsets[idx] || 0\n };\n }\n return {\n first: valueAt(0),\n last: valueAt(length - 1),\n widest: valueAt(widest),\n highest: valueAt(highest)\n };\n }\n function getTickMarkLength(options) {\n return options.drawTicks ? options.tickMarkLength : 0;\n }\n function getScaleLabelHeight(options) {\n var font, padding;\n if (!options.display) {\n return 0;\n }\n font = helpers$1.options._parseFont(options);\n padding = helpers$1.options.toPadding(options.padding);\n return font.lineHeight + padding.height;\n }\n function parseFontOptions(options, nestedOpts) {\n return helpers$1.extend(helpers$1.options._parseFont({\n fontFamily: valueOrDefault$a(nestedOpts.fontFamily, options.fontFamily),\n fontSize: valueOrDefault$a(nestedOpts.fontSize, options.fontSize),\n fontStyle: valueOrDefault$a(nestedOpts.fontStyle, options.fontStyle),\n lineHeight: valueOrDefault$a(nestedOpts.lineHeight, options.lineHeight)\n }), {\n color: helpers$1.options.resolve([nestedOpts.fontColor, options.fontColor, core_defaults.global.defaultFontColor])\n });\n }\n function parseTickFontOptions(options) {\n var minor = parseFontOptions(options, options.minor);\n var major = options.major.enabled ? parseFontOptions(options, options.major) : minor;\n return {\n minor: minor,\n major: major\n };\n }\n function nonSkipped(ticksToFilter) {\n var filtered = [];\n var item, index, len;\n for (index = 0, len = ticksToFilter.length; index < len; ++index) {\n item = ticksToFilter[index];\n if (typeof item._index !== 'undefined') {\n filtered.push(item);\n }\n }\n return filtered;\n }\n function getEvenSpacing(arr) {\n var len = arr.length;\n var i, diff;\n if (len < 2) {\n return false;\n }\n for (diff = arr[0], i = 1; i < len; ++i) {\n if (arr[i] - arr[i - 1] !== diff) {\n return false;\n }\n }\n return diff;\n }\n function calculateSpacing(majorIndices, ticks, axisLength, ticksLimit) {\n var evenMajorSpacing = getEvenSpacing(majorIndices);\n var spacing = (ticks.length - 1) / ticksLimit;\n var factors, factor, i, ilen;\n\n // If the major ticks are evenly spaced apart, place the minor ticks\n // so that they divide the major ticks into even chunks\n if (!evenMajorSpacing) {\n return Math.max(spacing, 1);\n }\n factors = helpers$1.math._factorize(evenMajorSpacing);\n for (i = 0, ilen = factors.length - 1; i < ilen; i++) {\n factor = factors[i];\n if (factor > spacing) {\n return factor;\n }\n }\n return Math.max(spacing, 1);\n }\n function getMajorIndices(ticks) {\n var result = [];\n var i, ilen;\n for (i = 0, ilen = ticks.length; i < ilen; i++) {\n if (ticks[i].major) {\n result.push(i);\n }\n }\n return result;\n }\n function skipMajors(ticks, majorIndices, spacing) {\n var count = 0;\n var next = majorIndices[0];\n var i, tick;\n spacing = Math.ceil(spacing);\n for (i = 0; i < ticks.length; i++) {\n tick = ticks[i];\n if (i === next) {\n tick._index = i;\n count++;\n next = majorIndices[count * spacing];\n } else {\n delete tick.label;\n }\n }\n }\n function skip(ticks, spacing, majorStart, majorEnd) {\n var start = valueOrDefault$a(majorStart, 0);\n var end = Math.min(valueOrDefault$a(majorEnd, ticks.length), ticks.length);\n var count = 0;\n var length, i, tick, next;\n spacing = Math.ceil(spacing);\n if (majorEnd) {\n length = majorEnd - majorStart;\n spacing = length / Math.floor(length / spacing);\n }\n next = start;\n while (next < 0) {\n count++;\n next = Math.round(start + count * spacing);\n }\n for (i = Math.max(start, 0); i < end; i++) {\n tick = ticks[i];\n if (i === next) {\n tick._index = i;\n count++;\n next = Math.round(start + count * spacing);\n } else {\n delete tick.label;\n }\n }\n }\n var Scale = core_element.extend({\n zeroLineIndex: 0,\n /**\r\n * Get the padding needed for the scale\r\n * @method getPadding\r\n * @private\r\n * @returns {Padding} the necessary padding\r\n */\n getPadding: function () {\n var me = this;\n return {\n left: me.paddingLeft || 0,\n top: me.paddingTop || 0,\n right: me.paddingRight || 0,\n bottom: me.paddingBottom || 0\n };\n },\n /**\r\n * Returns the scale tick objects ({label, major})\r\n * @since 2.7\r\n */\n getTicks: function () {\n return this._ticks;\n },\n /**\r\n * @private\r\n */\n _getLabels: function () {\n var data = this.chart.data;\n return this.options.labels || (this.isHorizontal() ? data.xLabels : data.yLabels) || data.labels || [];\n },\n // These methods are ordered by lifecyle. Utilities then follow.\n // Any function defined here is inherited by all scale types.\n // Any function can be extended by the scale type\n\n /**\r\n * Provided for backward compatibility, not available anymore\r\n * @function Chart.Scale.mergeTicksOptions\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n */\n mergeTicksOptions: function () {\n // noop\n },\n beforeUpdate: function () {\n helpers$1.callback(this.options.beforeUpdate, [this]);\n },\n /**\r\n * @param {number} maxWidth - the max width in pixels\r\n * @param {number} maxHeight - the max height in pixels\r\n * @param {object} margins - the space between the edge of the other scales and edge of the chart\r\n * This space comes from two sources:\r\n * - padding - space that's required to show the labels at the edges of the scale\r\n * - thickness of scales or legends in another orientation\r\n */\n update: function (maxWidth, maxHeight, margins) {\n var me = this;\n var tickOpts = me.options.ticks;\n var sampleSize = tickOpts.sampleSize;\n var i, ilen, labels, ticks, samplingEnabled;\n\n // Update Lifecycle - Probably don't want to ever extend or overwrite this function ;)\n me.beforeUpdate();\n\n // Absorb the master measurements\n me.maxWidth = maxWidth;\n me.maxHeight = maxHeight;\n me.margins = helpers$1.extend({\n left: 0,\n right: 0,\n top: 0,\n bottom: 0\n }, margins);\n me._ticks = null;\n me.ticks = null;\n me._labelSizes = null;\n me._maxLabelLines = 0;\n me.longestLabelWidth = 0;\n me.longestTextCache = me.longestTextCache || {};\n me._gridLineItems = null;\n me._labelItems = null;\n\n // Dimensions\n me.beforeSetDimensions();\n me.setDimensions();\n me.afterSetDimensions();\n\n // Data min/max\n me.beforeDataLimits();\n me.determineDataLimits();\n me.afterDataLimits();\n\n // Ticks - `this.ticks` is now DEPRECATED!\n // Internal ticks are now stored as objects in the PRIVATE `this._ticks` member\n // and must not be accessed directly from outside this class. `this.ticks` being\n // around for long time and not marked as private, we can't change its structure\n // without unexpected breaking changes. If you need to access the scale ticks,\n // use scale.getTicks() instead.\n\n me.beforeBuildTicks();\n\n // New implementations should return an array of objects but for BACKWARD COMPAT,\n // we still support no return (`this.ticks` internally set by calling this method).\n ticks = me.buildTicks() || [];\n\n // Allow modification of ticks in callback.\n ticks = me.afterBuildTicks(ticks) || ticks;\n\n // Ensure ticks contains ticks in new tick format\n if ((!ticks || !ticks.length) && me.ticks) {\n ticks = [];\n for (i = 0, ilen = me.ticks.length; i < ilen; ++i) {\n ticks.push({\n value: me.ticks[i],\n major: false\n });\n }\n }\n me._ticks = ticks;\n\n // Compute tick rotation and fit using a sampled subset of labels\n // We generally don't need to compute the size of every single label for determining scale size\n samplingEnabled = sampleSize < ticks.length;\n labels = me._convertTicksToLabels(samplingEnabled ? sample(ticks, sampleSize) : ticks);\n\n // _configure is called twice, once here, once from core.controller.updateLayout.\n // Here we haven't been positioned yet, but dimensions are correct.\n // Variables set in _configure are needed for calculateTickRotation, and\n // it's ok that coordinates are not correct there, only dimensions matter.\n me._configure();\n\n // Tick Rotation\n me.beforeCalculateTickRotation();\n me.calculateTickRotation();\n me.afterCalculateTickRotation();\n me.beforeFit();\n me.fit();\n me.afterFit();\n\n // Auto-skip\n me._ticksToDraw = tickOpts.display && (tickOpts.autoSkip || tickOpts.source === 'auto') ? me._autoSkip(ticks) : ticks;\n if (samplingEnabled) {\n // Generate labels using all non-skipped ticks\n labels = me._convertTicksToLabels(me._ticksToDraw);\n }\n me.ticks = labels; // BACKWARD COMPATIBILITY\n\n // IMPORTANT: after this point, we consider that `this.ticks` will NEVER change!\n\n me.afterUpdate();\n\n // TODO(v3): remove minSize as a public property and return value from all layout boxes. It is unused\n // make maxWidth and maxHeight private\n return me.minSize;\n },\n /**\r\n * @private\r\n */\n _configure: function () {\n var me = this;\n var reversePixels = me.options.ticks.reverse;\n var startPixel, endPixel;\n if (me.isHorizontal()) {\n startPixel = me.left;\n endPixel = me.right;\n } else {\n startPixel = me.top;\n endPixel = me.bottom;\n // by default vertical scales are from bottom to top, so pixels are reversed\n reversePixels = !reversePixels;\n }\n me._startPixel = startPixel;\n me._endPixel = endPixel;\n me._reversePixels = reversePixels;\n me._length = endPixel - startPixel;\n },\n afterUpdate: function () {\n helpers$1.callback(this.options.afterUpdate, [this]);\n },\n //\n\n beforeSetDimensions: function () {\n helpers$1.callback(this.options.beforeSetDimensions, [this]);\n },\n setDimensions: function () {\n var me = this;\n // Set the unconstrained dimension before label rotation\n if (me.isHorizontal()) {\n // Reset position before calculating rotation\n me.width = me.maxWidth;\n me.left = 0;\n me.right = me.width;\n } else {\n me.height = me.maxHeight;\n\n // Reset position before calculating rotation\n me.top = 0;\n me.bottom = me.height;\n }\n\n // Reset padding\n me.paddingLeft = 0;\n me.paddingTop = 0;\n me.paddingRight = 0;\n me.paddingBottom = 0;\n },\n afterSetDimensions: function () {\n helpers$1.callback(this.options.afterSetDimensions, [this]);\n },\n // Data limits\n beforeDataLimits: function () {\n helpers$1.callback(this.options.beforeDataLimits, [this]);\n },\n determineDataLimits: helpers$1.noop,\n afterDataLimits: function () {\n helpers$1.callback(this.options.afterDataLimits, [this]);\n },\n //\n beforeBuildTicks: function () {\n helpers$1.callback(this.options.beforeBuildTicks, [this]);\n },\n buildTicks: helpers$1.noop,\n afterBuildTicks: function (ticks) {\n var me = this;\n // ticks is empty for old axis implementations here\n if (isArray(ticks) && ticks.length) {\n return helpers$1.callback(me.options.afterBuildTicks, [me, ticks]);\n }\n // Support old implementations (that modified `this.ticks` directly in buildTicks)\n me.ticks = helpers$1.callback(me.options.afterBuildTicks, [me, me.ticks]) || me.ticks;\n return ticks;\n },\n beforeTickToLabelConversion: function () {\n helpers$1.callback(this.options.beforeTickToLabelConversion, [this]);\n },\n convertTicksToLabels: function () {\n var me = this;\n // Convert ticks to strings\n var tickOpts = me.options.ticks;\n me.ticks = me.ticks.map(tickOpts.userCallback || tickOpts.callback, this);\n },\n afterTickToLabelConversion: function () {\n helpers$1.callback(this.options.afterTickToLabelConversion, [this]);\n },\n //\n\n beforeCalculateTickRotation: function () {\n helpers$1.callback(this.options.beforeCalculateTickRotation, [this]);\n },\n calculateTickRotation: function () {\n var me = this;\n var options = me.options;\n var tickOpts = options.ticks;\n var numTicks = me.getTicks().length;\n var minRotation = tickOpts.minRotation || 0;\n var maxRotation = tickOpts.maxRotation;\n var labelRotation = minRotation;\n var labelSizes, maxLabelWidth, maxLabelHeight, maxWidth, tickWidth, maxHeight, maxLabelDiagonal;\n if (!me._isVisible() || !tickOpts.display || minRotation >= maxRotation || numTicks <= 1 || !me.isHorizontal()) {\n me.labelRotation = minRotation;\n return;\n }\n labelSizes = me._getLabelSizes();\n maxLabelWidth = labelSizes.widest.width;\n maxLabelHeight = labelSizes.highest.height - labelSizes.highest.offset;\n\n // Estimate the width of each grid based on the canvas width, the maximum\n // label width and the number of tick intervals\n maxWidth = Math.min(me.maxWidth, me.chart.width - maxLabelWidth);\n tickWidth = options.offset ? me.maxWidth / numTicks : maxWidth / (numTicks - 1);\n\n // Allow 3 pixels x2 padding either side for label readability\n if (maxLabelWidth + 6 > tickWidth) {\n tickWidth = maxWidth / (numTicks - (options.offset ? 0.5 : 1));\n maxHeight = me.maxHeight - getTickMarkLength(options.gridLines) - tickOpts.padding - getScaleLabelHeight(options.scaleLabel);\n maxLabelDiagonal = Math.sqrt(maxLabelWidth * maxLabelWidth + maxLabelHeight * maxLabelHeight);\n labelRotation = helpers$1.toDegrees(Math.min(Math.asin(Math.min((labelSizes.highest.height + 6) / tickWidth, 1)), Math.asin(Math.min(maxHeight / maxLabelDiagonal, 1)) - Math.asin(maxLabelHeight / maxLabelDiagonal)));\n labelRotation = Math.max(minRotation, Math.min(maxRotation, labelRotation));\n }\n me.labelRotation = labelRotation;\n },\n afterCalculateTickRotation: function () {\n helpers$1.callback(this.options.afterCalculateTickRotation, [this]);\n },\n //\n\n beforeFit: function () {\n helpers$1.callback(this.options.beforeFit, [this]);\n },\n fit: function () {\n var me = this;\n // Reset\n var minSize = me.minSize = {\n width: 0,\n height: 0\n };\n var chart = me.chart;\n var opts = me.options;\n var tickOpts = opts.ticks;\n var scaleLabelOpts = opts.scaleLabel;\n var gridLineOpts = opts.gridLines;\n var display = me._isVisible();\n var isBottom = opts.position === 'bottom';\n var isHorizontal = me.isHorizontal();\n\n // Width\n if (isHorizontal) {\n minSize.width = me.maxWidth;\n } else if (display) {\n minSize.width = getTickMarkLength(gridLineOpts) + getScaleLabelHeight(scaleLabelOpts);\n }\n\n // height\n if (!isHorizontal) {\n minSize.height = me.maxHeight; // fill all the height\n } else if (display) {\n minSize.height = getTickMarkLength(gridLineOpts) + getScaleLabelHeight(scaleLabelOpts);\n }\n\n // Don't bother fitting the ticks if we are not showing the labels\n if (tickOpts.display && display) {\n var tickFonts = parseTickFontOptions(tickOpts);\n var labelSizes = me._getLabelSizes();\n var firstLabelSize = labelSizes.first;\n var lastLabelSize = labelSizes.last;\n var widestLabelSize = labelSizes.widest;\n var highestLabelSize = labelSizes.highest;\n var lineSpace = tickFonts.minor.lineHeight * 0.4;\n var tickPadding = tickOpts.padding;\n if (isHorizontal) {\n // A horizontal axis is more constrained by the height.\n var isRotated = me.labelRotation !== 0;\n var angleRadians = helpers$1.toRadians(me.labelRotation);\n var cosRotation = Math.cos(angleRadians);\n var sinRotation = Math.sin(angleRadians);\n var labelHeight = sinRotation * widestLabelSize.width + cosRotation * (highestLabelSize.height - (isRotated ? highestLabelSize.offset : 0)) + (isRotated ? 0 : lineSpace); // padding\n\n minSize.height = Math.min(me.maxHeight, minSize.height + labelHeight + tickPadding);\n var offsetLeft = me.getPixelForTick(0) - me.left;\n var offsetRight = me.right - me.getPixelForTick(me.getTicks().length - 1);\n var paddingLeft, paddingRight;\n\n // Ensure that our ticks are always inside the canvas. When rotated, ticks are right aligned\n // which means that the right padding is dominated by the font height\n if (isRotated) {\n paddingLeft = isBottom ? cosRotation * firstLabelSize.width + sinRotation * firstLabelSize.offset : sinRotation * (firstLabelSize.height - firstLabelSize.offset);\n paddingRight = isBottom ? sinRotation * (lastLabelSize.height - lastLabelSize.offset) : cosRotation * lastLabelSize.width + sinRotation * lastLabelSize.offset;\n } else {\n paddingLeft = firstLabelSize.width / 2;\n paddingRight = lastLabelSize.width / 2;\n }\n\n // Adjust padding taking into account changes in offsets\n // and add 3 px to move away from canvas edges\n me.paddingLeft = Math.max((paddingLeft - offsetLeft) * me.width / (me.width - offsetLeft), 0) + 3;\n me.paddingRight = Math.max((paddingRight - offsetRight) * me.width / (me.width - offsetRight), 0) + 3;\n } else {\n // A vertical axis is more constrained by the width. Labels are the\n // dominant factor here, so get that length first and account for padding\n var labelWidth = tickOpts.mirror ? 0 :\n // use lineSpace for consistency with horizontal axis\n // tickPadding is not implemented for horizontal\n widestLabelSize.width + tickPadding + lineSpace;\n minSize.width = Math.min(me.maxWidth, minSize.width + labelWidth);\n me.paddingTop = firstLabelSize.height / 2;\n me.paddingBottom = lastLabelSize.height / 2;\n }\n }\n me.handleMargins();\n if (isHorizontal) {\n me.width = me._length = chart.width - me.margins.left - me.margins.right;\n me.height = minSize.height;\n } else {\n me.width = minSize.width;\n me.height = me._length = chart.height - me.margins.top - me.margins.bottom;\n }\n },\n /**\r\n * Handle margins and padding interactions\r\n * @private\r\n */\n handleMargins: function () {\n var me = this;\n if (me.margins) {\n me.margins.left = Math.max(me.paddingLeft, me.margins.left);\n me.margins.top = Math.max(me.paddingTop, me.margins.top);\n me.margins.right = Math.max(me.paddingRight, me.margins.right);\n me.margins.bottom = Math.max(me.paddingBottom, me.margins.bottom);\n }\n },\n afterFit: function () {\n helpers$1.callback(this.options.afterFit, [this]);\n },\n // Shared Methods\n isHorizontal: function () {\n var pos = this.options.position;\n return pos === 'top' || pos === 'bottom';\n },\n isFullWidth: function () {\n return this.options.fullWidth;\n },\n // Get the correct value. NaN bad inputs, If the value type is object get the x or y based on whether we are horizontal or not\n getRightValue: function (rawValue) {\n // Null and undefined values first\n if (isNullOrUndef(rawValue)) {\n return NaN;\n }\n // isNaN(object) returns true, so make sure NaN is checking for a number; Discard Infinite values\n if ((typeof rawValue === 'number' || rawValue instanceof Number) && !isFinite(rawValue)) {\n return NaN;\n }\n\n // If it is in fact an object, dive in one more level\n if (rawValue) {\n if (this.isHorizontal()) {\n if (rawValue.x !== undefined) {\n return this.getRightValue(rawValue.x);\n }\n } else if (rawValue.y !== undefined) {\n return this.getRightValue(rawValue.y);\n }\n }\n\n // Value is good, return it\n return rawValue;\n },\n _convertTicksToLabels: function (ticks) {\n var me = this;\n var labels, i, ilen;\n me.ticks = ticks.map(function (tick) {\n return tick.value;\n });\n me.beforeTickToLabelConversion();\n\n // New implementations should return the formatted tick labels but for BACKWARD\n // COMPAT, we still support no return (`this.ticks` internally changed by calling\n // this method and supposed to contain only string values).\n labels = me.convertTicksToLabels(ticks) || me.ticks;\n me.afterTickToLabelConversion();\n\n // BACKWARD COMPAT: synchronize `_ticks` with labels (so potentially `this.ticks`)\n for (i = 0, ilen = ticks.length; i < ilen; ++i) {\n ticks[i].label = labels[i];\n }\n return labels;\n },\n /**\r\n * @private\r\n */\n _getLabelSizes: function () {\n var me = this;\n var labelSizes = me._labelSizes;\n if (!labelSizes) {\n me._labelSizes = labelSizes = computeLabelSizes(me.ctx, parseTickFontOptions(me.options.ticks), me.getTicks(), me.longestTextCache);\n me.longestLabelWidth = labelSizes.widest.width;\n }\n return labelSizes;\n },\n /**\r\n * @private\r\n */\n _parseValue: function (value) {\n var start, end, min, max;\n if (isArray(value)) {\n start = +this.getRightValue(value[0]);\n end = +this.getRightValue(value[1]);\n min = Math.min(start, end);\n max = Math.max(start, end);\n } else {\n value = +this.getRightValue(value);\n start = undefined;\n end = value;\n min = value;\n max = value;\n }\n return {\n min: min,\n max: max,\n start: start,\n end: end\n };\n },\n /**\r\n * @private\r\n */\n _getScaleLabel: function (rawValue) {\n var v = this._parseValue(rawValue);\n if (v.start !== undefined) {\n return '[' + v.start + ', ' + v.end + ']';\n }\n return +this.getRightValue(rawValue);\n },\n /**\r\n * Used to get the value to display in the tooltip for the data at the given index\r\n * @param index\r\n * @param datasetIndex\r\n */\n getLabelForIndex: helpers$1.noop,\n /**\r\n * Returns the location of the given data point. Value can either be an index or a numerical value\r\n * The coordinate (0, 0) is at the upper-left corner of the canvas\r\n * @param value\r\n * @param index\r\n * @param datasetIndex\r\n */\n getPixelForValue: helpers$1.noop,\n /**\r\n * Used to get the data value from a given pixel. This is the inverse of getPixelForValue\r\n * The coordinate (0, 0) is at the upper-left corner of the canvas\r\n * @param pixel\r\n */\n getValueForPixel: helpers$1.noop,\n /**\r\n * Returns the location of the tick at the given index\r\n * The coordinate (0, 0) is at the upper-left corner of the canvas\r\n */\n getPixelForTick: function (index) {\n var me = this;\n var offset = me.options.offset;\n var numTicks = me._ticks.length;\n var tickWidth = 1 / Math.max(numTicks - (offset ? 0 : 1), 1);\n return index < 0 || index > numTicks - 1 ? null : me.getPixelForDecimal(index * tickWidth + (offset ? tickWidth / 2 : 0));\n },\n /**\r\n * Utility for getting the pixel location of a percentage of scale\r\n * The coordinate (0, 0) is at the upper-left corner of the canvas\r\n */\n getPixelForDecimal: function (decimal) {\n var me = this;\n if (me._reversePixels) {\n decimal = 1 - decimal;\n }\n return me._startPixel + decimal * me._length;\n },\n getDecimalForPixel: function (pixel) {\n var decimal = (pixel - this._startPixel) / this._length;\n return this._reversePixels ? 1 - decimal : decimal;\n },\n /**\r\n * Returns the pixel for the minimum chart value\r\n * The coordinate (0, 0) is at the upper-left corner of the canvas\r\n */\n getBasePixel: function () {\n return this.getPixelForValue(this.getBaseValue());\n },\n getBaseValue: function () {\n var me = this;\n var min = me.min;\n var max = me.max;\n return me.beginAtZero ? 0 : min < 0 && max < 0 ? max : min > 0 && max > 0 ? min : 0;\n },\n /**\r\n * Returns a subset of ticks to be plotted to avoid overlapping labels.\r\n * @private\r\n */\n _autoSkip: function (ticks) {\n var me = this;\n var tickOpts = me.options.ticks;\n var axisLength = me._length;\n var ticksLimit = tickOpts.maxTicksLimit || axisLength / me._tickSize() + 1;\n var majorIndices = tickOpts.major.enabled ? getMajorIndices(ticks) : [];\n var numMajorIndices = majorIndices.length;\n var first = majorIndices[0];\n var last = majorIndices[numMajorIndices - 1];\n var i, ilen, spacing, avgMajorSpacing;\n\n // If there are too many major ticks to display them all\n if (numMajorIndices > ticksLimit) {\n skipMajors(ticks, majorIndices, numMajorIndices / ticksLimit);\n return nonSkipped(ticks);\n }\n spacing = calculateSpacing(majorIndices, ticks, axisLength, ticksLimit);\n if (numMajorIndices > 0) {\n for (i = 0, ilen = numMajorIndices - 1; i < ilen; i++) {\n skip(ticks, spacing, majorIndices[i], majorIndices[i + 1]);\n }\n avgMajorSpacing = numMajorIndices > 1 ? (last - first) / (numMajorIndices - 1) : null;\n skip(ticks, spacing, helpers$1.isNullOrUndef(avgMajorSpacing) ? 0 : first - avgMajorSpacing, first);\n skip(ticks, spacing, last, helpers$1.isNullOrUndef(avgMajorSpacing) ? ticks.length : last + avgMajorSpacing);\n return nonSkipped(ticks);\n }\n skip(ticks, spacing);\n return nonSkipped(ticks);\n },\n /**\r\n * @private\r\n */\n _tickSize: function () {\n var me = this;\n var optionTicks = me.options.ticks;\n\n // Calculate space needed by label in axis direction.\n var rot = helpers$1.toRadians(me.labelRotation);\n var cos = Math.abs(Math.cos(rot));\n var sin = Math.abs(Math.sin(rot));\n var labelSizes = me._getLabelSizes();\n var padding = optionTicks.autoSkipPadding || 0;\n var w = labelSizes ? labelSizes.widest.width + padding : 0;\n var h = labelSizes ? labelSizes.highest.height + padding : 0;\n\n // Calculate space needed for 1 tick in axis direction.\n return me.isHorizontal() ? h * cos > w * sin ? w / cos : h / sin : h * sin < w * cos ? h / cos : w / sin;\n },\n /**\r\n * @private\r\n */\n _isVisible: function () {\n var me = this;\n var chart = me.chart;\n var display = me.options.display;\n var i, ilen, meta;\n if (display !== 'auto') {\n return !!display;\n }\n\n // When 'auto', the scale is visible if at least one associated dataset is visible.\n for (i = 0, ilen = chart.data.datasets.length; i < ilen; ++i) {\n if (chart.isDatasetVisible(i)) {\n meta = chart.getDatasetMeta(i);\n if (meta.xAxisID === me.id || meta.yAxisID === me.id) {\n return true;\n }\n }\n }\n return false;\n },\n /**\r\n * @private\r\n */\n _computeGridLineItems: function (chartArea) {\n var me = this;\n var chart = me.chart;\n var options = me.options;\n var gridLines = options.gridLines;\n var position = options.position;\n var offsetGridLines = gridLines.offsetGridLines;\n var isHorizontal = me.isHorizontal();\n var ticks = me._ticksToDraw;\n var ticksLength = ticks.length + (offsetGridLines ? 1 : 0);\n var tl = getTickMarkLength(gridLines);\n var items = [];\n var axisWidth = gridLines.drawBorder ? valueAtIndexOrDefault(gridLines.lineWidth, 0, 0) : 0;\n var axisHalfWidth = axisWidth / 2;\n var alignPixel = helpers$1._alignPixel;\n var alignBorderValue = function (pixel) {\n return alignPixel(chart, pixel, axisWidth);\n };\n var borderValue, i, tick, lineValue, alignedLineValue;\n var tx1, ty1, tx2, ty2, x1, y1, x2, y2, lineWidth, lineColor, borderDash, borderDashOffset;\n if (position === 'top') {\n borderValue = alignBorderValue(me.bottom);\n ty1 = me.bottom - tl;\n ty2 = borderValue - axisHalfWidth;\n y1 = alignBorderValue(chartArea.top) + axisHalfWidth;\n y2 = chartArea.bottom;\n } else if (position === 'bottom') {\n borderValue = alignBorderValue(me.top);\n y1 = chartArea.top;\n y2 = alignBorderValue(chartArea.bottom) - axisHalfWidth;\n ty1 = borderValue + axisHalfWidth;\n ty2 = me.top + tl;\n } else if (position === 'left') {\n borderValue = alignBorderValue(me.right);\n tx1 = me.right - tl;\n tx2 = borderValue - axisHalfWidth;\n x1 = alignBorderValue(chartArea.left) + axisHalfWidth;\n x2 = chartArea.right;\n } else {\n borderValue = alignBorderValue(me.left);\n x1 = chartArea.left;\n x2 = alignBorderValue(chartArea.right) - axisHalfWidth;\n tx1 = borderValue + axisHalfWidth;\n tx2 = me.left + tl;\n }\n for (i = 0; i < ticksLength; ++i) {\n tick = ticks[i] || {};\n\n // autoskipper skipped this tick (#4635)\n if (isNullOrUndef(tick.label) && i < ticks.length) {\n continue;\n }\n if (i === me.zeroLineIndex && options.offset === offsetGridLines) {\n // Draw the first index specially\n lineWidth = gridLines.zeroLineWidth;\n lineColor = gridLines.zeroLineColor;\n borderDash = gridLines.zeroLineBorderDash || [];\n borderDashOffset = gridLines.zeroLineBorderDashOffset || 0.0;\n } else {\n lineWidth = valueAtIndexOrDefault(gridLines.lineWidth, i, 1);\n lineColor = valueAtIndexOrDefault(gridLines.color, i, 'rgba(0,0,0,0.1)');\n borderDash = gridLines.borderDash || [];\n borderDashOffset = gridLines.borderDashOffset || 0.0;\n }\n lineValue = getPixelForGridLine(me, tick._index || i, offsetGridLines);\n\n // Skip if the pixel is out of the range\n if (lineValue === undefined) {\n continue;\n }\n alignedLineValue = alignPixel(chart, lineValue, lineWidth);\n if (isHorizontal) {\n tx1 = tx2 = x1 = x2 = alignedLineValue;\n } else {\n ty1 = ty2 = y1 = y2 = alignedLineValue;\n }\n items.push({\n tx1: tx1,\n ty1: ty1,\n tx2: tx2,\n ty2: ty2,\n x1: x1,\n y1: y1,\n x2: x2,\n y2: y2,\n width: lineWidth,\n color: lineColor,\n borderDash: borderDash,\n borderDashOffset: borderDashOffset\n });\n }\n items.ticksLength = ticksLength;\n items.borderValue = borderValue;\n return items;\n },\n /**\r\n * @private\r\n */\n _computeLabelItems: function () {\n var me = this;\n var options = me.options;\n var optionTicks = options.ticks;\n var position = options.position;\n var isMirrored = optionTicks.mirror;\n var isHorizontal = me.isHorizontal();\n var ticks = me._ticksToDraw;\n var fonts = parseTickFontOptions(optionTicks);\n var tickPadding = optionTicks.padding;\n var tl = getTickMarkLength(options.gridLines);\n var rotation = -helpers$1.toRadians(me.labelRotation);\n var items = [];\n var i, ilen, tick, label, x, y, textAlign, pixel, font, lineHeight, lineCount, textOffset;\n if (position === 'top') {\n y = me.bottom - tl - tickPadding;\n textAlign = !rotation ? 'center' : 'left';\n } else if (position === 'bottom') {\n y = me.top + tl + tickPadding;\n textAlign = !rotation ? 'center' : 'right';\n } else if (position === 'left') {\n x = me.right - (isMirrored ? 0 : tl) - tickPadding;\n textAlign = isMirrored ? 'left' : 'right';\n } else {\n x = me.left + (isMirrored ? 0 : tl) + tickPadding;\n textAlign = isMirrored ? 'right' : 'left';\n }\n for (i = 0, ilen = ticks.length; i < ilen; ++i) {\n tick = ticks[i];\n label = tick.label;\n\n // autoskipper skipped this tick (#4635)\n if (isNullOrUndef(label)) {\n continue;\n }\n pixel = me.getPixelForTick(tick._index || i) + optionTicks.labelOffset;\n font = tick.major ? fonts.major : fonts.minor;\n lineHeight = font.lineHeight;\n lineCount = isArray(label) ? label.length : 1;\n if (isHorizontal) {\n x = pixel;\n textOffset = position === 'top' ? ((!rotation ? 0.5 : 1) - lineCount) * lineHeight : (!rotation ? 0.5 : 0) * lineHeight;\n } else {\n y = pixel;\n textOffset = (1 - lineCount) * lineHeight / 2;\n }\n items.push({\n x: x,\n y: y,\n rotation: rotation,\n label: label,\n font: font,\n textOffset: textOffset,\n textAlign: textAlign\n });\n }\n return items;\n },\n /**\r\n * @private\r\n */\n _drawGrid: function (chartArea) {\n var me = this;\n var gridLines = me.options.gridLines;\n if (!gridLines.display) {\n return;\n }\n var ctx = me.ctx;\n var chart = me.chart;\n var alignPixel = helpers$1._alignPixel;\n var axisWidth = gridLines.drawBorder ? valueAtIndexOrDefault(gridLines.lineWidth, 0, 0) : 0;\n var items = me._gridLineItems || (me._gridLineItems = me._computeGridLineItems(chartArea));\n var width, color, i, ilen, item;\n for (i = 0, ilen = items.length; i < ilen; ++i) {\n item = items[i];\n width = item.width;\n color = item.color;\n if (width && color) {\n ctx.save();\n ctx.lineWidth = width;\n ctx.strokeStyle = color;\n if (ctx.setLineDash) {\n ctx.setLineDash(item.borderDash);\n ctx.lineDashOffset = item.borderDashOffset;\n }\n ctx.beginPath();\n if (gridLines.drawTicks) {\n ctx.moveTo(item.tx1, item.ty1);\n ctx.lineTo(item.tx2, item.ty2);\n }\n if (gridLines.drawOnChartArea) {\n ctx.moveTo(item.x1, item.y1);\n ctx.lineTo(item.x2, item.y2);\n }\n ctx.stroke();\n ctx.restore();\n }\n }\n if (axisWidth) {\n // Draw the line at the edge of the axis\n var firstLineWidth = axisWidth;\n var lastLineWidth = valueAtIndexOrDefault(gridLines.lineWidth, items.ticksLength - 1, 1);\n var borderValue = items.borderValue;\n var x1, x2, y1, y2;\n if (me.isHorizontal()) {\n x1 = alignPixel(chart, me.left, firstLineWidth) - firstLineWidth / 2;\n x2 = alignPixel(chart, me.right, lastLineWidth) + lastLineWidth / 2;\n y1 = y2 = borderValue;\n } else {\n y1 = alignPixel(chart, me.top, firstLineWidth) - firstLineWidth / 2;\n y2 = alignPixel(chart, me.bottom, lastLineWidth) + lastLineWidth / 2;\n x1 = x2 = borderValue;\n }\n ctx.lineWidth = axisWidth;\n ctx.strokeStyle = valueAtIndexOrDefault(gridLines.color, 0);\n ctx.beginPath();\n ctx.moveTo(x1, y1);\n ctx.lineTo(x2, y2);\n ctx.stroke();\n }\n },\n /**\r\n * @private\r\n */\n _drawLabels: function () {\n var me = this;\n var optionTicks = me.options.ticks;\n if (!optionTicks.display) {\n return;\n }\n var ctx = me.ctx;\n var items = me._labelItems || (me._labelItems = me._computeLabelItems());\n var i, j, ilen, jlen, item, tickFont, label, y;\n for (i = 0, ilen = items.length; i < ilen; ++i) {\n item = items[i];\n tickFont = item.font;\n\n // Make sure we draw text in the correct color and font\n ctx.save();\n ctx.translate(item.x, item.y);\n ctx.rotate(item.rotation);\n ctx.font = tickFont.string;\n ctx.fillStyle = tickFont.color;\n ctx.textBaseline = 'middle';\n ctx.textAlign = item.textAlign;\n label = item.label;\n y = item.textOffset;\n if (isArray(label)) {\n for (j = 0, jlen = label.length; j < jlen; ++j) {\n // We just make sure the multiline element is a string here..\n ctx.fillText('' + label[j], 0, y);\n y += tickFont.lineHeight;\n }\n } else {\n ctx.fillText(label, 0, y);\n }\n ctx.restore();\n }\n },\n /**\r\n * @private\r\n */\n _drawTitle: function () {\n var me = this;\n var ctx = me.ctx;\n var options = me.options;\n var scaleLabel = options.scaleLabel;\n if (!scaleLabel.display) {\n return;\n }\n var scaleLabelFontColor = valueOrDefault$a(scaleLabel.fontColor, core_defaults.global.defaultFontColor);\n var scaleLabelFont = helpers$1.options._parseFont(scaleLabel);\n var scaleLabelPadding = helpers$1.options.toPadding(scaleLabel.padding);\n var halfLineHeight = scaleLabelFont.lineHeight / 2;\n var position = options.position;\n var rotation = 0;\n var scaleLabelX, scaleLabelY;\n if (me.isHorizontal()) {\n scaleLabelX = me.left + me.width / 2; // midpoint of the width\n scaleLabelY = position === 'bottom' ? me.bottom - halfLineHeight - scaleLabelPadding.bottom : me.top + halfLineHeight + scaleLabelPadding.top;\n } else {\n var isLeft = position === 'left';\n scaleLabelX = isLeft ? me.left + halfLineHeight + scaleLabelPadding.top : me.right - halfLineHeight - scaleLabelPadding.top;\n scaleLabelY = me.top + me.height / 2;\n rotation = isLeft ? -0.5 * Math.PI : 0.5 * Math.PI;\n }\n ctx.save();\n ctx.translate(scaleLabelX, scaleLabelY);\n ctx.rotate(rotation);\n ctx.textAlign = 'center';\n ctx.textBaseline = 'middle';\n ctx.fillStyle = scaleLabelFontColor; // render in correct colour\n ctx.font = scaleLabelFont.string;\n ctx.fillText(scaleLabel.labelString, 0, 0);\n ctx.restore();\n },\n draw: function (chartArea) {\n var me = this;\n if (!me._isVisible()) {\n return;\n }\n me._drawGrid(chartArea);\n me._drawTitle();\n me._drawLabels();\n },\n /**\r\n * @private\r\n */\n _layers: function () {\n var me = this;\n var opts = me.options;\n var tz = opts.ticks && opts.ticks.z || 0;\n var gz = opts.gridLines && opts.gridLines.z || 0;\n if (!me._isVisible() || tz === gz || me.draw !== me._draw) {\n // backward compatibility: draw has been overridden by custom scale\n return [{\n z: tz,\n draw: function () {\n me.draw.apply(me, arguments);\n }\n }];\n }\n return [{\n z: gz,\n draw: function () {\n me._drawGrid.apply(me, arguments);\n me._drawTitle.apply(me, arguments);\n }\n }, {\n z: tz,\n draw: function () {\n me._drawLabels.apply(me, arguments);\n }\n }];\n },\n /**\r\n * @private\r\n */\n _getMatchingVisibleMetas: function (type) {\n var me = this;\n var isHorizontal = me.isHorizontal();\n return me.chart._getSortedVisibleDatasetMetas().filter(function (meta) {\n return (!type || meta.type === type) && (isHorizontal ? meta.xAxisID === me.id : meta.yAxisID === me.id);\n });\n }\n });\n Scale.prototype._draw = Scale.prototype.draw;\n var core_scale = Scale;\n var isNullOrUndef$1 = helpers$1.isNullOrUndef;\n var defaultConfig = {\n position: 'bottom'\n };\n var scale_category = core_scale.extend({\n determineDataLimits: function () {\n var me = this;\n var labels = me._getLabels();\n var ticksOpts = me.options.ticks;\n var min = ticksOpts.min;\n var max = ticksOpts.max;\n var minIndex = 0;\n var maxIndex = labels.length - 1;\n var findIndex;\n if (min !== undefined) {\n // user specified min value\n findIndex = labels.indexOf(min);\n if (findIndex >= 0) {\n minIndex = findIndex;\n }\n }\n if (max !== undefined) {\n // user specified max value\n findIndex = labels.indexOf(max);\n if (findIndex >= 0) {\n maxIndex = findIndex;\n }\n }\n me.minIndex = minIndex;\n me.maxIndex = maxIndex;\n me.min = labels[minIndex];\n me.max = labels[maxIndex];\n },\n buildTicks: function () {\n var me = this;\n var labels = me._getLabels();\n var minIndex = me.minIndex;\n var maxIndex = me.maxIndex;\n\n // If we are viewing some subset of labels, slice the original array\n me.ticks = minIndex === 0 && maxIndex === labels.length - 1 ? labels : labels.slice(minIndex, maxIndex + 1);\n },\n getLabelForIndex: function (index, datasetIndex) {\n var me = this;\n var chart = me.chart;\n if (chart.getDatasetMeta(datasetIndex).controller._getValueScaleId() === me.id) {\n return me.getRightValue(chart.data.datasets[datasetIndex].data[index]);\n }\n return me._getLabels()[index];\n },\n _configure: function () {\n var me = this;\n var offset = me.options.offset;\n var ticks = me.ticks;\n core_scale.prototype._configure.call(me);\n if (!me.isHorizontal()) {\n // For backward compatibility, vertical category scale reverse is inverted.\n me._reversePixels = !me._reversePixels;\n }\n if (!ticks) {\n return;\n }\n me._startValue = me.minIndex - (offset ? 0.5 : 0);\n me._valueRange = Math.max(ticks.length - (offset ? 0 : 1), 1);\n },\n // Used to get data value locations. Value can either be an index or a numerical value\n getPixelForValue: function (value, index, datasetIndex) {\n var me = this;\n var valueCategory, labels, idx;\n if (!isNullOrUndef$1(index) && !isNullOrUndef$1(datasetIndex)) {\n value = me.chart.data.datasets[datasetIndex].data[index];\n }\n\n // If value is a data object, then index is the index in the data array,\n // not the index of the scale. We need to change that.\n if (!isNullOrUndef$1(value)) {\n valueCategory = me.isHorizontal() ? value.x : value.y;\n }\n if (valueCategory !== undefined || value !== undefined && isNaN(index)) {\n labels = me._getLabels();\n value = helpers$1.valueOrDefault(valueCategory, value);\n idx = labels.indexOf(value);\n index = idx !== -1 ? idx : index;\n if (isNaN(index)) {\n index = value;\n }\n }\n return me.getPixelForDecimal((index - me._startValue) / me._valueRange);\n },\n getPixelForTick: function (index) {\n var ticks = this.ticks;\n return index < 0 || index > ticks.length - 1 ? null : this.getPixelForValue(ticks[index], index + this.minIndex);\n },\n getValueForPixel: function (pixel) {\n var me = this;\n var value = Math.round(me._startValue + me.getDecimalForPixel(pixel) * me._valueRange);\n return Math.min(Math.max(value, 0), me.ticks.length - 1);\n },\n getBasePixel: function () {\n return this.bottom;\n }\n });\n\n // INTERNAL: static default options, registered in src/index.js\n var _defaults = defaultConfig;\n scale_category._defaults = _defaults;\n var noop = helpers$1.noop;\n var isNullOrUndef$2 = helpers$1.isNullOrUndef;\n\n /**\r\n * Generate a set of linear ticks\r\n * @param generationOptions the options used to generate the ticks\r\n * @param dataRange the range of the data\r\n * @returns {number[]} array of tick values\r\n */\n function generateTicks(generationOptions, dataRange) {\n var ticks = [];\n // To get a \"nice\" value for the tick spacing, we will use the appropriately named\n // \"nice number\" algorithm. See https://stackoverflow.com/questions/8506881/nice-label-algorithm-for-charts-with-minimum-ticks\n // for details.\n\n var MIN_SPACING = 1e-14;\n var stepSize = generationOptions.stepSize;\n var unit = stepSize || 1;\n var maxNumSpaces = generationOptions.maxTicks - 1;\n var min = generationOptions.min;\n var max = generationOptions.max;\n var precision = generationOptions.precision;\n var rmin = dataRange.min;\n var rmax = dataRange.max;\n var spacing = helpers$1.niceNum((rmax - rmin) / maxNumSpaces / unit) * unit;\n var factor, niceMin, niceMax, numSpaces;\n\n // Beyond MIN_SPACING floating point numbers being to lose precision\n // such that we can't do the math necessary to generate ticks\n if (spacing < MIN_SPACING && isNullOrUndef$2(min) && isNullOrUndef$2(max)) {\n return [rmin, rmax];\n }\n numSpaces = Math.ceil(rmax / spacing) - Math.floor(rmin / spacing);\n if (numSpaces > maxNumSpaces) {\n // If the calculated num of spaces exceeds maxNumSpaces, recalculate it\n spacing = helpers$1.niceNum(numSpaces * spacing / maxNumSpaces / unit) * unit;\n }\n if (stepSize || isNullOrUndef$2(precision)) {\n // If a precision is not specified, calculate factor based on spacing\n factor = Math.pow(10, helpers$1._decimalPlaces(spacing));\n } else {\n // If the user specified a precision, round to that number of decimal places\n factor = Math.pow(10, precision);\n spacing = Math.ceil(spacing * factor) / factor;\n }\n niceMin = Math.floor(rmin / spacing) * spacing;\n niceMax = Math.ceil(rmax / spacing) * spacing;\n\n // If min, max and stepSize is set and they make an evenly spaced scale use it.\n if (stepSize) {\n // If very close to our whole number, use it.\n if (!isNullOrUndef$2(min) && helpers$1.almostWhole(min / spacing, spacing / 1000)) {\n niceMin = min;\n }\n if (!isNullOrUndef$2(max) && helpers$1.almostWhole(max / spacing, spacing / 1000)) {\n niceMax = max;\n }\n }\n numSpaces = (niceMax - niceMin) / spacing;\n // If very close to our rounded value, use it.\n if (helpers$1.almostEquals(numSpaces, Math.round(numSpaces), spacing / 1000)) {\n numSpaces = Math.round(numSpaces);\n } else {\n numSpaces = Math.ceil(numSpaces);\n }\n niceMin = Math.round(niceMin * factor) / factor;\n niceMax = Math.round(niceMax * factor) / factor;\n ticks.push(isNullOrUndef$2(min) ? niceMin : min);\n for (var j = 1; j < numSpaces; ++j) {\n ticks.push(Math.round((niceMin + j * spacing) * factor) / factor);\n }\n ticks.push(isNullOrUndef$2(max) ? niceMax : max);\n return ticks;\n }\n var scale_linearbase = core_scale.extend({\n getRightValue: function (value) {\n if (typeof value === 'string') {\n return +value;\n }\n return core_scale.prototype.getRightValue.call(this, value);\n },\n handleTickRangeOptions: function () {\n var me = this;\n var opts = me.options;\n var tickOpts = opts.ticks;\n\n // If we are forcing it to begin at 0, but 0 will already be rendered on the chart,\n // do nothing since that would make the chart weird. If the user really wants a weird chart\n // axis, they can manually override it\n if (tickOpts.beginAtZero) {\n var minSign = helpers$1.sign(me.min);\n var maxSign = helpers$1.sign(me.max);\n if (minSign < 0 && maxSign < 0) {\n // move the top up to 0\n me.max = 0;\n } else if (minSign > 0 && maxSign > 0) {\n // move the bottom down to 0\n me.min = 0;\n }\n }\n var setMin = tickOpts.min !== undefined || tickOpts.suggestedMin !== undefined;\n var setMax = tickOpts.max !== undefined || tickOpts.suggestedMax !== undefined;\n if (tickOpts.min !== undefined) {\n me.min = tickOpts.min;\n } else if (tickOpts.suggestedMin !== undefined) {\n if (me.min === null) {\n me.min = tickOpts.suggestedMin;\n } else {\n me.min = Math.min(me.min, tickOpts.suggestedMin);\n }\n }\n if (tickOpts.max !== undefined) {\n me.max = tickOpts.max;\n } else if (tickOpts.suggestedMax !== undefined) {\n if (me.max === null) {\n me.max = tickOpts.suggestedMax;\n } else {\n me.max = Math.max(me.max, tickOpts.suggestedMax);\n }\n }\n if (setMin !== setMax) {\n // We set the min or the max but not both.\n // So ensure that our range is good\n // Inverted or 0 length range can happen when\n // ticks.min is set, and no datasets are visible\n if (me.min >= me.max) {\n if (setMin) {\n me.max = me.min + 1;\n } else {\n me.min = me.max - 1;\n }\n }\n }\n if (me.min === me.max) {\n me.max++;\n if (!tickOpts.beginAtZero) {\n me.min--;\n }\n }\n },\n getTickLimit: function () {\n var me = this;\n var tickOpts = me.options.ticks;\n var stepSize = tickOpts.stepSize;\n var maxTicksLimit = tickOpts.maxTicksLimit;\n var maxTicks;\n if (stepSize) {\n maxTicks = Math.ceil(me.max / stepSize) - Math.floor(me.min / stepSize) + 1;\n } else {\n maxTicks = me._computeTickLimit();\n maxTicksLimit = maxTicksLimit || 11;\n }\n if (maxTicksLimit) {\n maxTicks = Math.min(maxTicksLimit, maxTicks);\n }\n return maxTicks;\n },\n _computeTickLimit: function () {\n return Number.POSITIVE_INFINITY;\n },\n handleDirectionalChanges: noop,\n buildTicks: function () {\n var me = this;\n var opts = me.options;\n var tickOpts = opts.ticks;\n\n // Figure out what the max number of ticks we can support it is based on the size of\n // the axis area. For now, we say that the minimum tick spacing in pixels must be 40\n // We also limit the maximum number of ticks to 11 which gives a nice 10 squares on\n // the graph. Make sure we always have at least 2 ticks\n var maxTicks = me.getTickLimit();\n maxTicks = Math.max(2, maxTicks);\n var numericGeneratorOptions = {\n maxTicks: maxTicks,\n min: tickOpts.min,\n max: tickOpts.max,\n precision: tickOpts.precision,\n stepSize: helpers$1.valueOrDefault(tickOpts.fixedStepSize, tickOpts.stepSize)\n };\n var ticks = me.ticks = generateTicks(numericGeneratorOptions, me);\n me.handleDirectionalChanges();\n\n // At this point, we need to update our max and min given the tick values since we have expanded the\n // range of the scale\n me.max = helpers$1.max(ticks);\n me.min = helpers$1.min(ticks);\n if (tickOpts.reverse) {\n ticks.reverse();\n me.start = me.max;\n me.end = me.min;\n } else {\n me.start = me.min;\n me.end = me.max;\n }\n },\n convertTicksToLabels: function () {\n var me = this;\n me.ticksAsNumbers = me.ticks.slice();\n me.zeroLineIndex = me.ticks.indexOf(0);\n core_scale.prototype.convertTicksToLabels.call(me);\n },\n _configure: function () {\n var me = this;\n var ticks = me.getTicks();\n var start = me.min;\n var end = me.max;\n var offset;\n core_scale.prototype._configure.call(me);\n if (me.options.offset && ticks.length) {\n offset = (end - start) / Math.max(ticks.length - 1, 1) / 2;\n start -= offset;\n end += offset;\n }\n me._startValue = start;\n me._endValue = end;\n me._valueRange = end - start;\n }\n });\n var defaultConfig$1 = {\n position: 'left',\n ticks: {\n callback: core_ticks.formatters.linear\n }\n };\n var DEFAULT_MIN = 0;\n var DEFAULT_MAX = 1;\n function getOrCreateStack(stacks, stacked, meta) {\n var key = [meta.type,\n // we have a separate stack for stack=undefined datasets when the opts.stacked is undefined\n stacked === undefined && meta.stack === undefined ? meta.index : '', meta.stack].join('.');\n if (stacks[key] === undefined) {\n stacks[key] = {\n pos: [],\n neg: []\n };\n }\n return stacks[key];\n }\n function stackData(scale, stacks, meta, data) {\n var opts = scale.options;\n var stacked = opts.stacked;\n var stack = getOrCreateStack(stacks, stacked, meta);\n var pos = stack.pos;\n var neg = stack.neg;\n var ilen = data.length;\n var i, value;\n for (i = 0; i < ilen; ++i) {\n value = scale._parseValue(data[i]);\n if (isNaN(value.min) || isNaN(value.max) || meta.data[i].hidden) {\n continue;\n }\n pos[i] = pos[i] || 0;\n neg[i] = neg[i] || 0;\n if (opts.relativePoints) {\n pos[i] = 100;\n } else if (value.min < 0 || value.max < 0) {\n neg[i] += value.min;\n } else {\n pos[i] += value.max;\n }\n }\n }\n function updateMinMax(scale, meta, data) {\n var ilen = data.length;\n var i, value;\n for (i = 0; i < ilen; ++i) {\n value = scale._parseValue(data[i]);\n if (isNaN(value.min) || isNaN(value.max) || meta.data[i].hidden) {\n continue;\n }\n scale.min = Math.min(scale.min, value.min);\n scale.max = Math.max(scale.max, value.max);\n }\n }\n var scale_linear = scale_linearbase.extend({\n determineDataLimits: function () {\n var me = this;\n var opts = me.options;\n var chart = me.chart;\n var datasets = chart.data.datasets;\n var metasets = me._getMatchingVisibleMetas();\n var hasStacks = opts.stacked;\n var stacks = {};\n var ilen = metasets.length;\n var i, meta, data, values;\n me.min = Number.POSITIVE_INFINITY;\n me.max = Number.NEGATIVE_INFINITY;\n if (hasStacks === undefined) {\n for (i = 0; !hasStacks && i < ilen; ++i) {\n meta = metasets[i];\n hasStacks = meta.stack !== undefined;\n }\n }\n for (i = 0; i < ilen; ++i) {\n meta = metasets[i];\n data = datasets[meta.index].data;\n if (hasStacks) {\n stackData(me, stacks, meta, data);\n } else {\n updateMinMax(me, meta, data);\n }\n }\n helpers$1.each(stacks, function (stackValues) {\n values = stackValues.pos.concat(stackValues.neg);\n me.min = Math.min(me.min, helpers$1.min(values));\n me.max = Math.max(me.max, helpers$1.max(values));\n });\n me.min = helpers$1.isFinite(me.min) && !isNaN(me.min) ? me.min : DEFAULT_MIN;\n me.max = helpers$1.isFinite(me.max) && !isNaN(me.max) ? me.max : DEFAULT_MAX;\n\n // Common base implementation to handle ticks.min, ticks.max, ticks.beginAtZero\n me.handleTickRangeOptions();\n },\n // Returns the maximum number of ticks based on the scale dimension\n _computeTickLimit: function () {\n var me = this;\n var tickFont;\n if (me.isHorizontal()) {\n return Math.ceil(me.width / 40);\n }\n tickFont = helpers$1.options._parseFont(me.options.ticks);\n return Math.ceil(me.height / tickFont.lineHeight);\n },\n // Called after the ticks are built. We need\n handleDirectionalChanges: function () {\n if (!this.isHorizontal()) {\n // We are in a vertical orientation. The top value is the highest. So reverse the array\n this.ticks.reverse();\n }\n },\n getLabelForIndex: function (index, datasetIndex) {\n return this._getScaleLabel(this.chart.data.datasets[datasetIndex].data[index]);\n },\n // Utils\n getPixelForValue: function (value) {\n var me = this;\n return me.getPixelForDecimal((+me.getRightValue(value) - me._startValue) / me._valueRange);\n },\n getValueForPixel: function (pixel) {\n return this._startValue + this.getDecimalForPixel(pixel) * this._valueRange;\n },\n getPixelForTick: function (index) {\n var ticks = this.ticksAsNumbers;\n if (index < 0 || index > ticks.length - 1) {\n return null;\n }\n return this.getPixelForValue(ticks[index]);\n }\n });\n\n // INTERNAL: static default options, registered in src/index.js\n var _defaults$1 = defaultConfig$1;\n scale_linear._defaults = _defaults$1;\n var valueOrDefault$b = helpers$1.valueOrDefault;\n var log10 = helpers$1.math.log10;\n\n /**\r\n * Generate a set of logarithmic ticks\r\n * @param generationOptions the options used to generate the ticks\r\n * @param dataRange the range of the data\r\n * @returns {number[]} array of tick values\r\n */\n function generateTicks$1(generationOptions, dataRange) {\n var ticks = [];\n var tickVal = valueOrDefault$b(generationOptions.min, Math.pow(10, Math.floor(log10(dataRange.min))));\n var endExp = Math.floor(log10(dataRange.max));\n var endSignificand = Math.ceil(dataRange.max / Math.pow(10, endExp));\n var exp, significand;\n if (tickVal === 0) {\n exp = Math.floor(log10(dataRange.minNotZero));\n significand = Math.floor(dataRange.minNotZero / Math.pow(10, exp));\n ticks.push(tickVal);\n tickVal = significand * Math.pow(10, exp);\n } else {\n exp = Math.floor(log10(tickVal));\n significand = Math.floor(tickVal / Math.pow(10, exp));\n }\n var precision = exp < 0 ? Math.pow(10, Math.abs(exp)) : 1;\n do {\n ticks.push(tickVal);\n ++significand;\n if (significand === 10) {\n significand = 1;\n ++exp;\n precision = exp >= 0 ? 1 : precision;\n }\n tickVal = Math.round(significand * Math.pow(10, exp) * precision) / precision;\n } while (exp < endExp || exp === endExp && significand < endSignificand);\n var lastTick = valueOrDefault$b(generationOptions.max, tickVal);\n ticks.push(lastTick);\n return ticks;\n }\n var defaultConfig$2 = {\n position: 'left',\n // label settings\n ticks: {\n callback: core_ticks.formatters.logarithmic\n }\n };\n\n // TODO(v3): change this to positiveOrDefault\n function nonNegativeOrDefault(value, defaultValue) {\n return helpers$1.isFinite(value) && value >= 0 ? value : defaultValue;\n }\n var scale_logarithmic = core_scale.extend({\n determineDataLimits: function () {\n var me = this;\n var opts = me.options;\n var chart = me.chart;\n var datasets = chart.data.datasets;\n var isHorizontal = me.isHorizontal();\n function IDMatches(meta) {\n return isHorizontal ? meta.xAxisID === me.id : meta.yAxisID === me.id;\n }\n var datasetIndex, meta, value, data, i, ilen;\n\n // Calculate Range\n me.min = Number.POSITIVE_INFINITY;\n me.max = Number.NEGATIVE_INFINITY;\n me.minNotZero = Number.POSITIVE_INFINITY;\n var hasStacks = opts.stacked;\n if (hasStacks === undefined) {\n for (datasetIndex = 0; datasetIndex < datasets.length; datasetIndex++) {\n meta = chart.getDatasetMeta(datasetIndex);\n if (chart.isDatasetVisible(datasetIndex) && IDMatches(meta) && meta.stack !== undefined) {\n hasStacks = true;\n break;\n }\n }\n }\n if (opts.stacked || hasStacks) {\n var valuesPerStack = {};\n for (datasetIndex = 0; datasetIndex < datasets.length; datasetIndex++) {\n meta = chart.getDatasetMeta(datasetIndex);\n var key = [meta.type,\n // we have a separate stack for stack=undefined datasets when the opts.stacked is undefined\n opts.stacked === undefined && meta.stack === undefined ? datasetIndex : '', meta.stack].join('.');\n if (chart.isDatasetVisible(datasetIndex) && IDMatches(meta)) {\n if (valuesPerStack[key] === undefined) {\n valuesPerStack[key] = [];\n }\n data = datasets[datasetIndex].data;\n for (i = 0, ilen = data.length; i < ilen; i++) {\n var values = valuesPerStack[key];\n value = me._parseValue(data[i]);\n // invalid, hidden and negative values are ignored\n if (isNaN(value.min) || isNaN(value.max) || meta.data[i].hidden || value.min < 0 || value.max < 0) {\n continue;\n }\n values[i] = values[i] || 0;\n values[i] += value.max;\n }\n }\n }\n helpers$1.each(valuesPerStack, function (valuesForType) {\n if (valuesForType.length > 0) {\n var minVal = helpers$1.min(valuesForType);\n var maxVal = helpers$1.max(valuesForType);\n me.min = Math.min(me.min, minVal);\n me.max = Math.max(me.max, maxVal);\n }\n });\n } else {\n for (datasetIndex = 0; datasetIndex < datasets.length; datasetIndex++) {\n meta = chart.getDatasetMeta(datasetIndex);\n if (chart.isDatasetVisible(datasetIndex) && IDMatches(meta)) {\n data = datasets[datasetIndex].data;\n for (i = 0, ilen = data.length; i < ilen; i++) {\n value = me._parseValue(data[i]);\n // invalid, hidden and negative values are ignored\n if (isNaN(value.min) || isNaN(value.max) || meta.data[i].hidden || value.min < 0 || value.max < 0) {\n continue;\n }\n me.min = Math.min(value.min, me.min);\n me.max = Math.max(value.max, me.max);\n if (value.min !== 0) {\n me.minNotZero = Math.min(value.min, me.minNotZero);\n }\n }\n }\n }\n }\n me.min = helpers$1.isFinite(me.min) ? me.min : null;\n me.max = helpers$1.isFinite(me.max) ? me.max : null;\n me.minNotZero = helpers$1.isFinite(me.minNotZero) ? me.minNotZero : null;\n\n // Common base implementation to handle ticks.min, ticks.max\n this.handleTickRangeOptions();\n },\n handleTickRangeOptions: function () {\n var me = this;\n var tickOpts = me.options.ticks;\n var DEFAULT_MIN = 1;\n var DEFAULT_MAX = 10;\n me.min = nonNegativeOrDefault(tickOpts.min, me.min);\n me.max = nonNegativeOrDefault(tickOpts.max, me.max);\n if (me.min === me.max) {\n if (me.min !== 0 && me.min !== null) {\n me.min = Math.pow(10, Math.floor(log10(me.min)) - 1);\n me.max = Math.pow(10, Math.floor(log10(me.max)) + 1);\n } else {\n me.min = DEFAULT_MIN;\n me.max = DEFAULT_MAX;\n }\n }\n if (me.min === null) {\n me.min = Math.pow(10, Math.floor(log10(me.max)) - 1);\n }\n if (me.max === null) {\n me.max = me.min !== 0 ? Math.pow(10, Math.floor(log10(me.min)) + 1) : DEFAULT_MAX;\n }\n if (me.minNotZero === null) {\n if (me.min > 0) {\n me.minNotZero = me.min;\n } else if (me.max < 1) {\n me.minNotZero = Math.pow(10, Math.floor(log10(me.max)));\n } else {\n me.minNotZero = DEFAULT_MIN;\n }\n }\n },\n buildTicks: function () {\n var me = this;\n var tickOpts = me.options.ticks;\n var reverse = !me.isHorizontal();\n var generationOptions = {\n min: nonNegativeOrDefault(tickOpts.min),\n max: nonNegativeOrDefault(tickOpts.max)\n };\n var ticks = me.ticks = generateTicks$1(generationOptions, me);\n\n // At this point, we need to update our max and min given the tick values since we have expanded the\n // range of the scale\n me.max = helpers$1.max(ticks);\n me.min = helpers$1.min(ticks);\n if (tickOpts.reverse) {\n reverse = !reverse;\n me.start = me.max;\n me.end = me.min;\n } else {\n me.start = me.min;\n me.end = me.max;\n }\n if (reverse) {\n ticks.reverse();\n }\n },\n convertTicksToLabels: function () {\n this.tickValues = this.ticks.slice();\n core_scale.prototype.convertTicksToLabels.call(this);\n },\n // Get the correct tooltip label\n getLabelForIndex: function (index, datasetIndex) {\n return this._getScaleLabel(this.chart.data.datasets[datasetIndex].data[index]);\n },\n getPixelForTick: function (index) {\n var ticks = this.tickValues;\n if (index < 0 || index > ticks.length - 1) {\n return null;\n }\n return this.getPixelForValue(ticks[index]);\n },\n /**\r\n * Returns the value of the first tick.\r\n * @param {number} value - The minimum not zero value.\r\n * @return {number} The first tick value.\r\n * @private\r\n */\n _getFirstTickValue: function (value) {\n var exp = Math.floor(log10(value));\n var significand = Math.floor(value / Math.pow(10, exp));\n return significand * Math.pow(10, exp);\n },\n _configure: function () {\n var me = this;\n var start = me.min;\n var offset = 0;\n core_scale.prototype._configure.call(me);\n if (start === 0) {\n start = me._getFirstTickValue(me.minNotZero);\n offset = valueOrDefault$b(me.options.ticks.fontSize, core_defaults.global.defaultFontSize) / me._length;\n }\n me._startValue = log10(start);\n me._valueOffset = offset;\n me._valueRange = (log10(me.max) - log10(start)) / (1 - offset);\n },\n getPixelForValue: function (value) {\n var me = this;\n var decimal = 0;\n value = +me.getRightValue(value);\n if (value > me.min && value > 0) {\n decimal = (log10(value) - me._startValue) / me._valueRange + me._valueOffset;\n }\n return me.getPixelForDecimal(decimal);\n },\n getValueForPixel: function (pixel) {\n var me = this;\n var decimal = me.getDecimalForPixel(pixel);\n return decimal === 0 && me.min === 0 ? 0 : Math.pow(10, me._startValue + (decimal - me._valueOffset) * me._valueRange);\n }\n });\n\n // INTERNAL: static default options, registered in src/index.js\n var _defaults$2 = defaultConfig$2;\n scale_logarithmic._defaults = _defaults$2;\n var valueOrDefault$c = helpers$1.valueOrDefault;\n var valueAtIndexOrDefault$1 = helpers$1.valueAtIndexOrDefault;\n var resolve$4 = helpers$1.options.resolve;\n var defaultConfig$3 = {\n display: true,\n // Boolean - Whether to animate scaling the chart from the centre\n animate: true,\n position: 'chartArea',\n angleLines: {\n display: true,\n color: 'rgba(0,0,0,0.1)',\n lineWidth: 1,\n borderDash: [],\n borderDashOffset: 0.0\n },\n gridLines: {\n circular: false\n },\n // label settings\n ticks: {\n // Boolean - Show a backdrop to the scale label\n showLabelBackdrop: true,\n // String - The colour of the label backdrop\n backdropColor: 'rgba(255,255,255,0.75)',\n // Number - The backdrop padding above & below the label in pixels\n backdropPaddingY: 2,\n // Number - The backdrop padding to the side of the label in pixels\n backdropPaddingX: 2,\n callback: core_ticks.formatters.linear\n },\n pointLabels: {\n // Boolean - if true, show point labels\n display: true,\n // Number - Point label font size in pixels\n fontSize: 10,\n // Function - Used to convert point labels\n callback: function (label) {\n return label;\n }\n }\n };\n function getTickBackdropHeight(opts) {\n var tickOpts = opts.ticks;\n if (tickOpts.display && opts.display) {\n return valueOrDefault$c(tickOpts.fontSize, core_defaults.global.defaultFontSize) + tickOpts.backdropPaddingY * 2;\n }\n return 0;\n }\n function measureLabelSize(ctx, lineHeight, label) {\n if (helpers$1.isArray(label)) {\n return {\n w: helpers$1.longestText(ctx, ctx.font, label),\n h: label.length * lineHeight\n };\n }\n return {\n w: ctx.measureText(label).width,\n h: lineHeight\n };\n }\n function determineLimits(angle, pos, size, min, max) {\n if (angle === min || angle === max) {\n return {\n start: pos - size / 2,\n end: pos + size / 2\n };\n } else if (angle < min || angle > max) {\n return {\n start: pos - size,\n end: pos\n };\n }\n return {\n start: pos,\n end: pos + size\n };\n }\n\n /**\r\n * Helper function to fit a radial linear scale with point labels\r\n */\n function fitWithPointLabels(scale) {\n // Right, this is really confusing and there is a lot of maths going on here\n // The gist of the problem is here: https://gist.github.com/nnnick/696cc9c55f4b0beb8fe9\n //\n // Reaction: https://dl.dropboxusercontent.com/u/34601363/toomuchscience.gif\n //\n // Solution:\n //\n // We assume the radius of the polygon is half the size of the canvas at first\n // at each index we check if the text overlaps.\n //\n // Where it does, we store that angle and that index.\n //\n // After finding the largest index and angle we calculate how much we need to remove\n // from the shape radius to move the point inwards by that x.\n //\n // We average the left and right distances to get the maximum shape radius that can fit in the box\n // along with labels.\n //\n // Once we have that, we can find the centre point for the chart, by taking the x text protrusion\n // on each side, removing that from the size, halving it and adding the left x protrusion width.\n //\n // This will mean we have a shape fitted to the canvas, as large as it can be with the labels\n // and position it in the most space efficient manner\n //\n // https://dl.dropboxusercontent.com/u/34601363/yeahscience.gif\n\n var plFont = helpers$1.options._parseFont(scale.options.pointLabels);\n\n // Get maximum radius of the polygon. Either half the height (minus the text width) or half the width.\n // Use this to calculate the offset + change. - Make sure L/R protrusion is at least 0 to stop issues with centre points\n var furthestLimits = {\n l: 0,\n r: scale.width,\n t: 0,\n b: scale.height - scale.paddingTop\n };\n var furthestAngles = {};\n var i, textSize, pointPosition;\n scale.ctx.font = plFont.string;\n scale._pointLabelSizes = [];\n var valueCount = scale.chart.data.labels.length;\n for (i = 0; i < valueCount; i++) {\n pointPosition = scale.getPointPosition(i, scale.drawingArea + 5);\n textSize = measureLabelSize(scale.ctx, plFont.lineHeight, scale.pointLabels[i]);\n scale._pointLabelSizes[i] = textSize;\n\n // Add quarter circle to make degree 0 mean top of circle\n var angleRadians = scale.getIndexAngle(i);\n var angle = helpers$1.toDegrees(angleRadians) % 360;\n var hLimits = determineLimits(angle, pointPosition.x, textSize.w, 0, 180);\n var vLimits = determineLimits(angle, pointPosition.y, textSize.h, 90, 270);\n if (hLimits.start < furthestLimits.l) {\n furthestLimits.l = hLimits.start;\n furthestAngles.l = angleRadians;\n }\n if (hLimits.end > furthestLimits.r) {\n furthestLimits.r = hLimits.end;\n furthestAngles.r = angleRadians;\n }\n if (vLimits.start < furthestLimits.t) {\n furthestLimits.t = vLimits.start;\n furthestAngles.t = angleRadians;\n }\n if (vLimits.end > furthestLimits.b) {\n furthestLimits.b = vLimits.end;\n furthestAngles.b = angleRadians;\n }\n }\n scale.setReductions(scale.drawingArea, furthestLimits, furthestAngles);\n }\n function getTextAlignForAngle(angle) {\n if (angle === 0 || angle === 180) {\n return 'center';\n } else if (angle < 180) {\n return 'left';\n }\n return 'right';\n }\n function fillText(ctx, text, position, lineHeight) {\n var y = position.y + lineHeight / 2;\n var i, ilen;\n if (helpers$1.isArray(text)) {\n for (i = 0, ilen = text.length; i < ilen; ++i) {\n ctx.fillText(text[i], position.x, y);\n y += lineHeight;\n }\n } else {\n ctx.fillText(text, position.x, y);\n }\n }\n function adjustPointPositionForLabelHeight(angle, textSize, position) {\n if (angle === 90 || angle === 270) {\n position.y -= textSize.h / 2;\n } else if (angle > 270 || angle < 90) {\n position.y -= textSize.h;\n }\n }\n function drawPointLabels(scale) {\n var ctx = scale.ctx;\n var opts = scale.options;\n var pointLabelOpts = opts.pointLabels;\n var tickBackdropHeight = getTickBackdropHeight(opts);\n var outerDistance = scale.getDistanceFromCenterForValue(opts.ticks.reverse ? scale.min : scale.max);\n var plFont = helpers$1.options._parseFont(pointLabelOpts);\n ctx.save();\n ctx.font = plFont.string;\n ctx.textBaseline = 'middle';\n for (var i = scale.chart.data.labels.length - 1; i >= 0; i--) {\n // Extra pixels out for some label spacing\n var extra = i === 0 ? tickBackdropHeight / 2 : 0;\n var pointLabelPosition = scale.getPointPosition(i, outerDistance + extra + 5);\n\n // Keep this in loop since we may support array properties here\n var pointLabelFontColor = valueAtIndexOrDefault$1(pointLabelOpts.fontColor, i, core_defaults.global.defaultFontColor);\n ctx.fillStyle = pointLabelFontColor;\n var angleRadians = scale.getIndexAngle(i);\n var angle = helpers$1.toDegrees(angleRadians);\n ctx.textAlign = getTextAlignForAngle(angle);\n adjustPointPositionForLabelHeight(angle, scale._pointLabelSizes[i], pointLabelPosition);\n fillText(ctx, scale.pointLabels[i], pointLabelPosition, plFont.lineHeight);\n }\n ctx.restore();\n }\n function drawRadiusLine(scale, gridLineOpts, radius, index) {\n var ctx = scale.ctx;\n var circular = gridLineOpts.circular;\n var valueCount = scale.chart.data.labels.length;\n var lineColor = valueAtIndexOrDefault$1(gridLineOpts.color, index - 1);\n var lineWidth = valueAtIndexOrDefault$1(gridLineOpts.lineWidth, index - 1);\n var pointPosition;\n if (!circular && !valueCount || !lineColor || !lineWidth) {\n return;\n }\n ctx.save();\n ctx.strokeStyle = lineColor;\n ctx.lineWidth = lineWidth;\n if (ctx.setLineDash) {\n ctx.setLineDash(gridLineOpts.borderDash || []);\n ctx.lineDashOffset = gridLineOpts.borderDashOffset || 0.0;\n }\n ctx.beginPath();\n if (circular) {\n // Draw circular arcs between the points\n ctx.arc(scale.xCenter, scale.yCenter, radius, 0, Math.PI * 2);\n } else {\n // Draw straight lines connecting each index\n pointPosition = scale.getPointPosition(0, radius);\n ctx.moveTo(pointPosition.x, pointPosition.y);\n for (var i = 1; i < valueCount; i++) {\n pointPosition = scale.getPointPosition(i, radius);\n ctx.lineTo(pointPosition.x, pointPosition.y);\n }\n }\n ctx.closePath();\n ctx.stroke();\n ctx.restore();\n }\n function numberOrZero(param) {\n return helpers$1.isNumber(param) ? param : 0;\n }\n var scale_radialLinear = scale_linearbase.extend({\n setDimensions: function () {\n var me = this;\n\n // Set the unconstrained dimension before label rotation\n me.width = me.maxWidth;\n me.height = me.maxHeight;\n me.paddingTop = getTickBackdropHeight(me.options) / 2;\n me.xCenter = Math.floor(me.width / 2);\n me.yCenter = Math.floor((me.height - me.paddingTop) / 2);\n me.drawingArea = Math.min(me.height - me.paddingTop, me.width) / 2;\n },\n determineDataLimits: function () {\n var me = this;\n var chart = me.chart;\n var min = Number.POSITIVE_INFINITY;\n var max = Number.NEGATIVE_INFINITY;\n helpers$1.each(chart.data.datasets, function (dataset, datasetIndex) {\n if (chart.isDatasetVisible(datasetIndex)) {\n var meta = chart.getDatasetMeta(datasetIndex);\n helpers$1.each(dataset.data, function (rawValue, index) {\n var value = +me.getRightValue(rawValue);\n if (isNaN(value) || meta.data[index].hidden) {\n return;\n }\n min = Math.min(value, min);\n max = Math.max(value, max);\n });\n }\n });\n me.min = min === Number.POSITIVE_INFINITY ? 0 : min;\n me.max = max === Number.NEGATIVE_INFINITY ? 0 : max;\n\n // Common base implementation to handle ticks.min, ticks.max, ticks.beginAtZero\n me.handleTickRangeOptions();\n },\n // Returns the maximum number of ticks based on the scale dimension\n _computeTickLimit: function () {\n return Math.ceil(this.drawingArea / getTickBackdropHeight(this.options));\n },\n convertTicksToLabels: function () {\n var me = this;\n scale_linearbase.prototype.convertTicksToLabels.call(me);\n\n // Point labels\n me.pointLabels = me.chart.data.labels.map(function () {\n var label = helpers$1.callback(me.options.pointLabels.callback, arguments, me);\n return label || label === 0 ? label : '';\n });\n },\n getLabelForIndex: function (index, datasetIndex) {\n return +this.getRightValue(this.chart.data.datasets[datasetIndex].data[index]);\n },\n fit: function () {\n var me = this;\n var opts = me.options;\n if (opts.display && opts.pointLabels.display) {\n fitWithPointLabels(me);\n } else {\n me.setCenterPoint(0, 0, 0, 0);\n }\n },\n /**\r\n * Set radius reductions and determine new radius and center point\r\n * @private\r\n */\n setReductions: function (largestPossibleRadius, furthestLimits, furthestAngles) {\n var me = this;\n var radiusReductionLeft = furthestLimits.l / Math.sin(furthestAngles.l);\n var radiusReductionRight = Math.max(furthestLimits.r - me.width, 0) / Math.sin(furthestAngles.r);\n var radiusReductionTop = -furthestLimits.t / Math.cos(furthestAngles.t);\n var radiusReductionBottom = -Math.max(furthestLimits.b - (me.height - me.paddingTop), 0) / Math.cos(furthestAngles.b);\n radiusReductionLeft = numberOrZero(radiusReductionLeft);\n radiusReductionRight = numberOrZero(radiusReductionRight);\n radiusReductionTop = numberOrZero(radiusReductionTop);\n radiusReductionBottom = numberOrZero(radiusReductionBottom);\n me.drawingArea = Math.min(Math.floor(largestPossibleRadius - (radiusReductionLeft + radiusReductionRight) / 2), Math.floor(largestPossibleRadius - (radiusReductionTop + radiusReductionBottom) / 2));\n me.setCenterPoint(radiusReductionLeft, radiusReductionRight, radiusReductionTop, radiusReductionBottom);\n },\n setCenterPoint: function (leftMovement, rightMovement, topMovement, bottomMovement) {\n var me = this;\n var maxRight = me.width - rightMovement - me.drawingArea;\n var maxLeft = leftMovement + me.drawingArea;\n var maxTop = topMovement + me.drawingArea;\n var maxBottom = me.height - me.paddingTop - bottomMovement - me.drawingArea;\n me.xCenter = Math.floor((maxLeft + maxRight) / 2 + me.left);\n me.yCenter = Math.floor((maxTop + maxBottom) / 2 + me.top + me.paddingTop);\n },\n getIndexAngle: function (index) {\n var chart = this.chart;\n var angleMultiplier = 360 / chart.data.labels.length;\n var options = chart.options || {};\n var startAngle = options.startAngle || 0;\n\n // Start from the top instead of right, so remove a quarter of the circle\n var angle = (index * angleMultiplier + startAngle) % 360;\n return (angle < 0 ? angle + 360 : angle) * Math.PI * 2 / 360;\n },\n getDistanceFromCenterForValue: function (value) {\n var me = this;\n if (helpers$1.isNullOrUndef(value)) {\n return NaN;\n }\n\n // Take into account half font size + the yPadding of the top value\n var scalingFactor = me.drawingArea / (me.max - me.min);\n if (me.options.ticks.reverse) {\n return (me.max - value) * scalingFactor;\n }\n return (value - me.min) * scalingFactor;\n },\n getPointPosition: function (index, distanceFromCenter) {\n var me = this;\n var thisAngle = me.getIndexAngle(index) - Math.PI / 2;\n return {\n x: Math.cos(thisAngle) * distanceFromCenter + me.xCenter,\n y: Math.sin(thisAngle) * distanceFromCenter + me.yCenter\n };\n },\n getPointPositionForValue: function (index, value) {\n return this.getPointPosition(index, this.getDistanceFromCenterForValue(value));\n },\n getBasePosition: function (index) {\n var me = this;\n var min = me.min;\n var max = me.max;\n return me.getPointPositionForValue(index || 0, me.beginAtZero ? 0 : min < 0 && max < 0 ? max : min > 0 && max > 0 ? min : 0);\n },\n /**\r\n * @private\r\n */\n _drawGrid: function () {\n var me = this;\n var ctx = me.ctx;\n var opts = me.options;\n var gridLineOpts = opts.gridLines;\n var angleLineOpts = opts.angleLines;\n var lineWidth = valueOrDefault$c(angleLineOpts.lineWidth, gridLineOpts.lineWidth);\n var lineColor = valueOrDefault$c(angleLineOpts.color, gridLineOpts.color);\n var i, offset, position;\n if (opts.pointLabels.display) {\n drawPointLabels(me);\n }\n if (gridLineOpts.display) {\n helpers$1.each(me.ticks, function (label, index) {\n if (index !== 0) {\n offset = me.getDistanceFromCenterForValue(me.ticksAsNumbers[index]);\n drawRadiusLine(me, gridLineOpts, offset, index);\n }\n });\n }\n if (angleLineOpts.display && lineWidth && lineColor) {\n ctx.save();\n ctx.lineWidth = lineWidth;\n ctx.strokeStyle = lineColor;\n if (ctx.setLineDash) {\n ctx.setLineDash(resolve$4([angleLineOpts.borderDash, gridLineOpts.borderDash, []]));\n ctx.lineDashOffset = resolve$4([angleLineOpts.borderDashOffset, gridLineOpts.borderDashOffset, 0.0]);\n }\n for (i = me.chart.data.labels.length - 1; i >= 0; i--) {\n offset = me.getDistanceFromCenterForValue(opts.ticks.reverse ? me.min : me.max);\n position = me.getPointPosition(i, offset);\n ctx.beginPath();\n ctx.moveTo(me.xCenter, me.yCenter);\n ctx.lineTo(position.x, position.y);\n ctx.stroke();\n }\n ctx.restore();\n }\n },\n /**\r\n * @private\r\n */\n _drawLabels: function () {\n var me = this;\n var ctx = me.ctx;\n var opts = me.options;\n var tickOpts = opts.ticks;\n if (!tickOpts.display) {\n return;\n }\n var startAngle = me.getIndexAngle(0);\n var tickFont = helpers$1.options._parseFont(tickOpts);\n var tickFontColor = valueOrDefault$c(tickOpts.fontColor, core_defaults.global.defaultFontColor);\n var offset, width;\n ctx.save();\n ctx.font = tickFont.string;\n ctx.translate(me.xCenter, me.yCenter);\n ctx.rotate(startAngle);\n ctx.textAlign = 'center';\n ctx.textBaseline = 'middle';\n helpers$1.each(me.ticks, function (label, index) {\n if (index === 0 && !tickOpts.reverse) {\n return;\n }\n offset = me.getDistanceFromCenterForValue(me.ticksAsNumbers[index]);\n if (tickOpts.showLabelBackdrop) {\n width = ctx.measureText(label).width;\n ctx.fillStyle = tickOpts.backdropColor;\n ctx.fillRect(-width / 2 - tickOpts.backdropPaddingX, -offset - tickFont.size / 2 - tickOpts.backdropPaddingY, width + tickOpts.backdropPaddingX * 2, tickFont.size + tickOpts.backdropPaddingY * 2);\n }\n ctx.fillStyle = tickFontColor;\n ctx.fillText(label, 0, -offset);\n });\n ctx.restore();\n },\n /**\r\n * @private\r\n */\n _drawTitle: helpers$1.noop\n });\n\n // INTERNAL: static default options, registered in src/index.js\n var _defaults$3 = defaultConfig$3;\n scale_radialLinear._defaults = _defaults$3;\n var deprecated$1 = helpers$1._deprecated;\n var resolve$5 = helpers$1.options.resolve;\n var valueOrDefault$d = helpers$1.valueOrDefault;\n\n // Integer constants are from the ES6 spec.\n var MIN_INTEGER = Number.MIN_SAFE_INTEGER || -9007199254740991;\n var MAX_INTEGER = Number.MAX_SAFE_INTEGER || 9007199254740991;\n var INTERVALS = {\n millisecond: {\n common: true,\n size: 1,\n steps: 1000\n },\n second: {\n common: true,\n size: 1000,\n steps: 60\n },\n minute: {\n common: true,\n size: 60000,\n steps: 60\n },\n hour: {\n common: true,\n size: 3600000,\n steps: 24\n },\n day: {\n common: true,\n size: 86400000,\n steps: 30\n },\n week: {\n common: false,\n size: 604800000,\n steps: 4\n },\n month: {\n common: true,\n size: 2.628e9,\n steps: 12\n },\n quarter: {\n common: false,\n size: 7.884e9,\n steps: 4\n },\n year: {\n common: true,\n size: 3.154e10\n }\n };\n var UNITS = Object.keys(INTERVALS);\n function sorter(a, b) {\n return a - b;\n }\n function arrayUnique(items) {\n var hash = {};\n var out = [];\n var i, ilen, item;\n for (i = 0, ilen = items.length; i < ilen; ++i) {\n item = items[i];\n if (!hash[item]) {\n hash[item] = true;\n out.push(item);\n }\n }\n return out;\n }\n function getMin(options) {\n return helpers$1.valueOrDefault(options.time.min, options.ticks.min);\n }\n function getMax(options) {\n return helpers$1.valueOrDefault(options.time.max, options.ticks.max);\n }\n\n /**\r\n * Returns an array of {time, pos} objects used to interpolate a specific `time` or position\r\n * (`pos`) on the scale, by searching entries before and after the requested value. `pos` is\r\n * a decimal between 0 and 1: 0 being the start of the scale (left or top) and 1 the other\r\n * extremity (left + width or top + height). Note that it would be more optimized to directly\r\n * store pre-computed pixels, but the scale dimensions are not guaranteed at the time we need\r\n * to create the lookup table. The table ALWAYS contains at least two items: min and max.\r\n *\r\n * @param {number[]} timestamps - timestamps sorted from lowest to highest.\r\n * @param {string} distribution - If 'linear', timestamps will be spread linearly along the min\r\n * and max range, so basically, the table will contains only two items: {min, 0} and {max, 1}.\r\n * If 'series', timestamps will be positioned at the same distance from each other. In this\r\n * case, only timestamps that break the time linearity are registered, meaning that in the\r\n * best case, all timestamps are linear, the table contains only min and max.\r\n */\n function buildLookupTable(timestamps, min, max, distribution) {\n if (distribution === 'linear' || !timestamps.length) {\n return [{\n time: min,\n pos: 0\n }, {\n time: max,\n pos: 1\n }];\n }\n var table = [];\n var items = [min];\n var i, ilen, prev, curr, next;\n for (i = 0, ilen = timestamps.length; i < ilen; ++i) {\n curr = timestamps[i];\n if (curr > min && curr < max) {\n items.push(curr);\n }\n }\n items.push(max);\n for (i = 0, ilen = items.length; i < ilen; ++i) {\n next = items[i + 1];\n prev = items[i - 1];\n curr = items[i];\n\n // only add points that breaks the scale linearity\n if (prev === undefined || next === undefined || Math.round((next + prev) / 2) !== curr) {\n table.push({\n time: curr,\n pos: i / (ilen - 1)\n });\n }\n }\n return table;\n }\n\n // @see adapted from https://www.anujgakhar.com/2014/03/01/binary-search-in-javascript/\n function lookup(table, key, value) {\n var lo = 0;\n var hi = table.length - 1;\n var mid, i0, i1;\n while (lo >= 0 && lo <= hi) {\n mid = lo + hi >> 1;\n i0 = table[mid - 1] || null;\n i1 = table[mid];\n if (!i0) {\n // given value is outside table (before first item)\n return {\n lo: null,\n hi: i1\n };\n } else if (i1[key] < value) {\n lo = mid + 1;\n } else if (i0[key] > value) {\n hi = mid - 1;\n } else {\n return {\n lo: i0,\n hi: i1\n };\n }\n }\n\n // given value is outside table (after last item)\n return {\n lo: i1,\n hi: null\n };\n }\n\n /**\r\n * Linearly interpolates the given source `value` using the table items `skey` values and\r\n * returns the associated `tkey` value. For example, interpolate(table, 'time', 42, 'pos')\r\n * returns the position for a timestamp equal to 42. If value is out of bounds, values at\r\n * index [0, 1] or [n - 1, n] are used for the interpolation.\r\n */\n function interpolate$1(table, skey, sval, tkey) {\n var range = lookup(table, skey, sval);\n\n // Note: the lookup table ALWAYS contains at least 2 items (min and max)\n var prev = !range.lo ? table[0] : !range.hi ? table[table.length - 2] : range.lo;\n var next = !range.lo ? table[1] : !range.hi ? table[table.length - 1] : range.hi;\n var span = next[skey] - prev[skey];\n var ratio = span ? (sval - prev[skey]) / span : 0;\n var offset = (next[tkey] - prev[tkey]) * ratio;\n return prev[tkey] + offset;\n }\n function toTimestamp(scale, input) {\n var adapter = scale._adapter;\n var options = scale.options.time;\n var parser = options.parser;\n var format = parser || options.format;\n var value = input;\n if (typeof parser === 'function') {\n value = parser(value);\n }\n\n // Only parse if its not a timestamp already\n if (!helpers$1.isFinite(value)) {\n value = typeof format === 'string' ? adapter.parse(value, format) : adapter.parse(value);\n }\n if (value !== null) {\n return +value;\n }\n\n // Labels are in an incompatible format and no `parser` has been provided.\n // The user might still use the deprecated `format` option for parsing.\n if (!parser && typeof format === 'function') {\n value = format(input);\n\n // `format` could return something else than a timestamp, if so, parse it\n if (!helpers$1.isFinite(value)) {\n value = adapter.parse(value);\n }\n }\n return value;\n }\n function parse(scale, input) {\n if (helpers$1.isNullOrUndef(input)) {\n return null;\n }\n var options = scale.options.time;\n var value = toTimestamp(scale, scale.getRightValue(input));\n if (value === null) {\n return value;\n }\n if (options.round) {\n value = +scale._adapter.startOf(value, options.round);\n }\n return value;\n }\n\n /**\r\n * Figures out what unit results in an appropriate number of auto-generated ticks\r\n */\n function determineUnitForAutoTicks(minUnit, min, max, capacity) {\n var ilen = UNITS.length;\n var i, interval, factor;\n for (i = UNITS.indexOf(minUnit); i < ilen - 1; ++i) {\n interval = INTERVALS[UNITS[i]];\n factor = interval.steps ? interval.steps : MAX_INTEGER;\n if (interval.common && Math.ceil((max - min) / (factor * interval.size)) <= capacity) {\n return UNITS[i];\n }\n }\n return UNITS[ilen - 1];\n }\n\n /**\r\n * Figures out what unit to format a set of ticks with\r\n */\n function determineUnitForFormatting(scale, numTicks, minUnit, min, max) {\n var i, unit;\n for (i = UNITS.length - 1; i >= UNITS.indexOf(minUnit); i--) {\n unit = UNITS[i];\n if (INTERVALS[unit].common && scale._adapter.diff(max, min, unit) >= numTicks - 1) {\n return unit;\n }\n }\n return UNITS[minUnit ? UNITS.indexOf(minUnit) : 0];\n }\n function determineMajorUnit(unit) {\n for (var i = UNITS.indexOf(unit) + 1, ilen = UNITS.length; i < ilen; ++i) {\n if (INTERVALS[UNITS[i]].common) {\n return UNITS[i];\n }\n }\n }\n\n /**\r\n * Generates a maximum of `capacity` timestamps between min and max, rounded to the\r\n * `minor` unit using the given scale time `options`.\r\n * Important: this method can return ticks outside the min and max range, it's the\r\n * responsibility of the calling code to clamp values if needed.\r\n */\n function generate(scale, min, max, capacity) {\n var adapter = scale._adapter;\n var options = scale.options;\n var timeOpts = options.time;\n var minor = timeOpts.unit || determineUnitForAutoTicks(timeOpts.minUnit, min, max, capacity);\n var stepSize = resolve$5([timeOpts.stepSize, timeOpts.unitStepSize, 1]);\n var weekday = minor === 'week' ? timeOpts.isoWeekday : false;\n var first = min;\n var ticks = [];\n var time;\n\n // For 'week' unit, handle the first day of week option\n if (weekday) {\n first = +adapter.startOf(first, 'isoWeek', weekday);\n }\n\n // Align first ticks on unit\n first = +adapter.startOf(first, weekday ? 'day' : minor);\n\n // Prevent browser from freezing in case user options request millions of milliseconds\n if (adapter.diff(max, min, minor) > 100000 * stepSize) {\n throw min + ' and ' + max + ' are too far apart with stepSize of ' + stepSize + ' ' + minor;\n }\n for (time = first; time < max; time = +adapter.add(time, stepSize, minor)) {\n ticks.push(time);\n }\n if (time === max || options.bounds === 'ticks') {\n ticks.push(time);\n }\n return ticks;\n }\n\n /**\r\n * Returns the start and end offsets from edges in the form of {start, end}\r\n * where each value is a relative width to the scale and ranges between 0 and 1.\r\n * They add extra margins on the both sides by scaling down the original scale.\r\n * Offsets are added when the `offset` option is true.\r\n */\n function computeOffsets(table, ticks, min, max, options) {\n var start = 0;\n var end = 0;\n var first, last;\n if (options.offset && ticks.length) {\n first = interpolate$1(table, 'time', ticks[0], 'pos');\n if (ticks.length === 1) {\n start = 1 - first;\n } else {\n start = (interpolate$1(table, 'time', ticks[1], 'pos') - first) / 2;\n }\n last = interpolate$1(table, 'time', ticks[ticks.length - 1], 'pos');\n if (ticks.length === 1) {\n end = last;\n } else {\n end = (last - interpolate$1(table, 'time', ticks[ticks.length - 2], 'pos')) / 2;\n }\n }\n return {\n start: start,\n end: end,\n factor: 1 / (start + 1 + end)\n };\n }\n function setMajorTicks(scale, ticks, map, majorUnit) {\n var adapter = scale._adapter;\n var first = +adapter.startOf(ticks[0].value, majorUnit);\n var last = ticks[ticks.length - 1].value;\n var major, index;\n for (major = first; major <= last; major = +adapter.add(major, 1, majorUnit)) {\n index = map[major];\n if (index >= 0) {\n ticks[index].major = true;\n }\n }\n return ticks;\n }\n function ticksFromTimestamps(scale, values, majorUnit) {\n var ticks = [];\n var map = {};\n var ilen = values.length;\n var i, value;\n for (i = 0; i < ilen; ++i) {\n value = values[i];\n map[value] = i;\n ticks.push({\n value: value,\n major: false\n });\n }\n\n // We set the major ticks separately from the above loop because calling startOf for every tick\n // is expensive when there is a large number of ticks\n return ilen === 0 || !majorUnit ? ticks : setMajorTicks(scale, ticks, map, majorUnit);\n }\n var defaultConfig$4 = {\n position: 'bottom',\n /**\r\n * Data distribution along the scale:\r\n * - 'linear': data are spread according to their time (distances can vary),\r\n * - 'series': data are spread at the same distance from each other.\r\n * @see https://github.com/chartjs/Chart.js/pull/4507\r\n * @since 2.7.0\r\n */\n distribution: 'linear',\n /**\r\n * Scale boundary strategy (bypassed by min/max time options)\r\n * - `data`: make sure data are fully visible, ticks outside are removed\r\n * - `ticks`: make sure ticks are fully visible, data outside are truncated\r\n * @see https://github.com/chartjs/Chart.js/pull/4556\r\n * @since 2.7.0\r\n */\n bounds: 'data',\n adapters: {},\n time: {\n parser: false,\n // false == a pattern string from https://momentjs.com/docs/#/parsing/string-format/ or a custom callback that converts its argument to a moment\n unit: false,\n // false == automatic or override with week, month, year, etc.\n round: false,\n // none, or override with week, month, year, etc.\n displayFormat: false,\n // DEPRECATED\n isoWeekday: false,\n // override week start day - see https://momentjs.com/docs/#/get-set/iso-weekday/\n minUnit: 'millisecond',\n displayFormats: {}\n },\n ticks: {\n autoSkip: false,\n /**\r\n * Ticks generation input values:\r\n * - 'auto': generates \"optimal\" ticks based on scale size and time options.\r\n * - 'data': generates ticks from data (including labels from data {t|x|y} objects).\r\n * - 'labels': generates ticks from user given `data.labels` values ONLY.\r\n * @see https://github.com/chartjs/Chart.js/pull/4507\r\n * @since 2.7.0\r\n */\n source: 'auto',\n major: {\n enabled: false\n }\n }\n };\n var scale_time = core_scale.extend({\n initialize: function () {\n this.mergeTicksOptions();\n core_scale.prototype.initialize.call(this);\n },\n update: function () {\n var me = this;\n var options = me.options;\n var time = options.time || (options.time = {});\n var adapter = me._adapter = new core_adapters._date(options.adapters.date);\n\n // DEPRECATIONS: output a message only one time per update\n deprecated$1('time scale', time.format, 'time.format', 'time.parser');\n deprecated$1('time scale', time.min, 'time.min', 'ticks.min');\n deprecated$1('time scale', time.max, 'time.max', 'ticks.max');\n\n // Backward compatibility: before introducing adapter, `displayFormats` was\n // supposed to contain *all* unit/string pairs but this can't be resolved\n // when loading the scale (adapters are loaded afterward), so let's populate\n // missing formats on update\n helpers$1.mergeIf(time.displayFormats, adapter.formats());\n return core_scale.prototype.update.apply(me, arguments);\n },\n /**\r\n * Allows data to be referenced via 't' attribute\r\n */\n getRightValue: function (rawValue) {\n if (rawValue && rawValue.t !== undefined) {\n rawValue = rawValue.t;\n }\n return core_scale.prototype.getRightValue.call(this, rawValue);\n },\n determineDataLimits: function () {\n var me = this;\n var chart = me.chart;\n var adapter = me._adapter;\n var options = me.options;\n var unit = options.time.unit || 'day';\n var min = MAX_INTEGER;\n var max = MIN_INTEGER;\n var timestamps = [];\n var datasets = [];\n var labels = [];\n var i, j, ilen, jlen, data, timestamp, labelsAdded;\n var dataLabels = me._getLabels();\n for (i = 0, ilen = dataLabels.length; i < ilen; ++i) {\n labels.push(parse(me, dataLabels[i]));\n }\n for (i = 0, ilen = (chart.data.datasets || []).length; i < ilen; ++i) {\n if (chart.isDatasetVisible(i)) {\n data = chart.data.datasets[i].data;\n\n // Let's consider that all data have the same format.\n if (helpers$1.isObject(data[0])) {\n datasets[i] = [];\n for (j = 0, jlen = data.length; j < jlen; ++j) {\n timestamp = parse(me, data[j]);\n timestamps.push(timestamp);\n datasets[i][j] = timestamp;\n }\n } else {\n datasets[i] = labels.slice(0);\n if (!labelsAdded) {\n timestamps = timestamps.concat(labels);\n labelsAdded = true;\n }\n }\n } else {\n datasets[i] = [];\n }\n }\n if (labels.length) {\n min = Math.min(min, labels[0]);\n max = Math.max(max, labels[labels.length - 1]);\n }\n if (timestamps.length) {\n timestamps = ilen > 1 ? arrayUnique(timestamps).sort(sorter) : timestamps.sort(sorter);\n min = Math.min(min, timestamps[0]);\n max = Math.max(max, timestamps[timestamps.length - 1]);\n }\n min = parse(me, getMin(options)) || min;\n max = parse(me, getMax(options)) || max;\n\n // In case there is no valid min/max, set limits based on unit time option\n min = min === MAX_INTEGER ? +adapter.startOf(Date.now(), unit) : min;\n max = max === MIN_INTEGER ? +adapter.endOf(Date.now(), unit) + 1 : max;\n\n // Make sure that max is strictly higher than min (required by the lookup table)\n me.min = Math.min(min, max);\n me.max = Math.max(min + 1, max);\n\n // PRIVATE\n me._table = [];\n me._timestamps = {\n data: timestamps,\n datasets: datasets,\n labels: labels\n };\n },\n buildTicks: function () {\n var me = this;\n var min = me.min;\n var max = me.max;\n var options = me.options;\n var tickOpts = options.ticks;\n var timeOpts = options.time;\n var timestamps = me._timestamps;\n var ticks = [];\n var capacity = me.getLabelCapacity(min);\n var source = tickOpts.source;\n var distribution = options.distribution;\n var i, ilen, timestamp;\n if (source === 'data' || source === 'auto' && distribution === 'series') {\n timestamps = timestamps.data;\n } else if (source === 'labels') {\n timestamps = timestamps.labels;\n } else {\n timestamps = generate(me, min, max, capacity);\n }\n if (options.bounds === 'ticks' && timestamps.length) {\n min = timestamps[0];\n max = timestamps[timestamps.length - 1];\n }\n\n // Enforce limits with user min/max options\n min = parse(me, getMin(options)) || min;\n max = parse(me, getMax(options)) || max;\n\n // Remove ticks outside the min/max range\n for (i = 0, ilen = timestamps.length; i < ilen; ++i) {\n timestamp = timestamps[i];\n if (timestamp >= min && timestamp <= max) {\n ticks.push(timestamp);\n }\n }\n me.min = min;\n me.max = max;\n\n // PRIVATE\n // determineUnitForFormatting relies on the number of ticks so we don't use it when\n // autoSkip is enabled because we don't yet know what the final number of ticks will be\n me._unit = timeOpts.unit || (tickOpts.autoSkip ? determineUnitForAutoTicks(timeOpts.minUnit, me.min, me.max, capacity) : determineUnitForFormatting(me, ticks.length, timeOpts.minUnit, me.min, me.max));\n me._majorUnit = !tickOpts.major.enabled || me._unit === 'year' ? undefined : determineMajorUnit(me._unit);\n me._table = buildLookupTable(me._timestamps.data, min, max, distribution);\n me._offsets = computeOffsets(me._table, ticks, min, max, options);\n if (tickOpts.reverse) {\n ticks.reverse();\n }\n return ticksFromTimestamps(me, ticks, me._majorUnit);\n },\n getLabelForIndex: function (index, datasetIndex) {\n var me = this;\n var adapter = me._adapter;\n var data = me.chart.data;\n var timeOpts = me.options.time;\n var label = data.labels && index < data.labels.length ? data.labels[index] : '';\n var value = data.datasets[datasetIndex].data[index];\n if (helpers$1.isObject(value)) {\n label = me.getRightValue(value);\n }\n if (timeOpts.tooltipFormat) {\n return adapter.format(toTimestamp(me, label), timeOpts.tooltipFormat);\n }\n if (typeof label === 'string') {\n return label;\n }\n return adapter.format(toTimestamp(me, label), timeOpts.displayFormats.datetime);\n },\n /**\r\n * Function to format an individual tick mark\r\n * @private\r\n */\n tickFormatFunction: function (time, index, ticks, format) {\n var me = this;\n var adapter = me._adapter;\n var options = me.options;\n var formats = options.time.displayFormats;\n var minorFormat = formats[me._unit];\n var majorUnit = me._majorUnit;\n var majorFormat = formats[majorUnit];\n var tick = ticks[index];\n var tickOpts = options.ticks;\n var major = majorUnit && majorFormat && tick && tick.major;\n var label = adapter.format(time, format ? format : major ? majorFormat : minorFormat);\n var nestedTickOpts = major ? tickOpts.major : tickOpts.minor;\n var formatter = resolve$5([nestedTickOpts.callback, nestedTickOpts.userCallback, tickOpts.callback, tickOpts.userCallback]);\n return formatter ? formatter(label, index, ticks) : label;\n },\n convertTicksToLabels: function (ticks) {\n var labels = [];\n var i, ilen;\n for (i = 0, ilen = ticks.length; i < ilen; ++i) {\n labels.push(this.tickFormatFunction(ticks[i].value, i, ticks));\n }\n return labels;\n },\n /**\r\n * @private\r\n */\n getPixelForOffset: function (time) {\n var me = this;\n var offsets = me._offsets;\n var pos = interpolate$1(me._table, 'time', time, 'pos');\n return me.getPixelForDecimal((offsets.start + pos) * offsets.factor);\n },\n getPixelForValue: function (value, index, datasetIndex) {\n var me = this;\n var time = null;\n if (index !== undefined && datasetIndex !== undefined) {\n time = me._timestamps.datasets[datasetIndex][index];\n }\n if (time === null) {\n time = parse(me, value);\n }\n if (time !== null) {\n return me.getPixelForOffset(time);\n }\n },\n getPixelForTick: function (index) {\n var ticks = this.getTicks();\n return index >= 0 && index < ticks.length ? this.getPixelForOffset(ticks[index].value) : null;\n },\n getValueForPixel: function (pixel) {\n var me = this;\n var offsets = me._offsets;\n var pos = me.getDecimalForPixel(pixel) / offsets.factor - offsets.end;\n var time = interpolate$1(me._table, 'pos', pos, 'time');\n\n // DEPRECATION, we should return time directly\n return me._adapter._create(time);\n },\n /**\r\n * @private\r\n */\n _getLabelSize: function (label) {\n var me = this;\n var ticksOpts = me.options.ticks;\n var tickLabelWidth = me.ctx.measureText(label).width;\n var angle = helpers$1.toRadians(me.isHorizontal() ? ticksOpts.maxRotation : ticksOpts.minRotation);\n var cosRotation = Math.cos(angle);\n var sinRotation = Math.sin(angle);\n var tickFontSize = valueOrDefault$d(ticksOpts.fontSize, core_defaults.global.defaultFontSize);\n return {\n w: tickLabelWidth * cosRotation + tickFontSize * sinRotation,\n h: tickLabelWidth * sinRotation + tickFontSize * cosRotation\n };\n },\n /**\r\n * Crude approximation of what the label width might be\r\n * @private\r\n */\n getLabelWidth: function (label) {\n return this._getLabelSize(label).w;\n },\n /**\r\n * @private\r\n */\n getLabelCapacity: function (exampleTime) {\n var me = this;\n var timeOpts = me.options.time;\n var displayFormats = timeOpts.displayFormats;\n\n // pick the longest format (milliseconds) for guestimation\n var format = displayFormats[timeOpts.unit] || displayFormats.millisecond;\n var exampleLabel = me.tickFormatFunction(exampleTime, 0, ticksFromTimestamps(me, [exampleTime], me._majorUnit), format);\n var size = me._getLabelSize(exampleLabel);\n var capacity = Math.floor(me.isHorizontal() ? me.width / size.w : me.height / size.h);\n if (me.options.offset) {\n capacity--;\n }\n return capacity > 0 ? capacity : 1;\n }\n });\n\n // INTERNAL: static default options, registered in src/index.js\n var _defaults$4 = defaultConfig$4;\n scale_time._defaults = _defaults$4;\n var scales = {\n category: scale_category,\n linear: scale_linear,\n logarithmic: scale_logarithmic,\n radialLinear: scale_radialLinear,\n time: scale_time\n };\n var FORMATS = {\n datetime: 'MMM D, YYYY, h:mm:ss a',\n millisecond: 'h:mm:ss.SSS a',\n second: 'h:mm:ss a',\n minute: 'h:mm a',\n hour: 'hA',\n day: 'MMM D',\n week: 'll',\n month: 'MMM YYYY',\n quarter: '[Q]Q - YYYY',\n year: 'YYYY'\n };\n core_adapters._date.override(typeof moment === 'function' ? {\n _id: 'moment',\n // DEBUG ONLY\n\n formats: function () {\n return FORMATS;\n },\n parse: function (value, format) {\n if (typeof value === 'string' && typeof format === 'string') {\n value = moment(value, format);\n } else if (!(value instanceof moment)) {\n value = moment(value);\n }\n return value.isValid() ? value.valueOf() : null;\n },\n format: function (time, format) {\n return moment(time).format(format);\n },\n add: function (time, amount, unit) {\n return moment(time).add(amount, unit).valueOf();\n },\n diff: function (max, min, unit) {\n return moment(max).diff(moment(min), unit);\n },\n startOf: function (time, unit, weekday) {\n time = moment(time);\n if (unit === 'isoWeek') {\n return time.isoWeekday(weekday).valueOf();\n }\n return time.startOf(unit).valueOf();\n },\n endOf: function (time, unit) {\n return moment(time).endOf(unit).valueOf();\n },\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility with scale.getValueForPixel().\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n _create: function (time) {\n return moment(time);\n }\n } : {});\n core_defaults._set('global', {\n plugins: {\n filler: {\n propagate: true\n }\n }\n });\n var mappers = {\n dataset: function (source) {\n var index = source.fill;\n var chart = source.chart;\n var meta = chart.getDatasetMeta(index);\n var visible = meta && chart.isDatasetVisible(index);\n var points = visible && meta.dataset._children || [];\n var length = points.length || 0;\n return !length ? null : function (point, i) {\n return i < length && points[i]._view || null;\n };\n },\n boundary: function (source) {\n var boundary = source.boundary;\n var x = boundary ? boundary.x : null;\n var y = boundary ? boundary.y : null;\n if (helpers$1.isArray(boundary)) {\n return function (point, i) {\n return boundary[i];\n };\n }\n return function (point) {\n return {\n x: x === null ? point.x : x,\n y: y === null ? point.y : y\n };\n };\n }\n };\n\n // @todo if (fill[0] === '#')\n function decodeFill(el, index, count) {\n var model = el._model || {};\n var fill = model.fill;\n var target;\n if (fill === undefined) {\n fill = !!model.backgroundColor;\n }\n if (fill === false || fill === null) {\n return false;\n }\n if (fill === true) {\n return 'origin';\n }\n target = parseFloat(fill, 10);\n if (isFinite(target) && Math.floor(target) === target) {\n if (fill[0] === '-' || fill[0] === '+') {\n target = index + target;\n }\n if (target === index || target < 0 || target >= count) {\n return false;\n }\n return target;\n }\n switch (fill) {\n // compatibility\n case 'bottom':\n return 'start';\n case 'top':\n return 'end';\n case 'zero':\n return 'origin';\n // supported boundaries\n case 'origin':\n case 'start':\n case 'end':\n return fill;\n // invalid fill values\n default:\n return false;\n }\n }\n function computeLinearBoundary(source) {\n var model = source.el._model || {};\n var scale = source.el._scale || {};\n var fill = source.fill;\n var target = null;\n var horizontal;\n if (isFinite(fill)) {\n return null;\n }\n\n // Backward compatibility: until v3, we still need to support boundary values set on\n // the model (scaleTop, scaleBottom and scaleZero) because some external plugins and\n // controllers might still use it (e.g. the Smith chart).\n\n if (fill === 'start') {\n target = model.scaleBottom === undefined ? scale.bottom : model.scaleBottom;\n } else if (fill === 'end') {\n target = model.scaleTop === undefined ? scale.top : model.scaleTop;\n } else if (model.scaleZero !== undefined) {\n target = model.scaleZero;\n } else if (scale.getBasePixel) {\n target = scale.getBasePixel();\n }\n if (target !== undefined && target !== null) {\n if (target.x !== undefined && target.y !== undefined) {\n return target;\n }\n if (helpers$1.isFinite(target)) {\n horizontal = scale.isHorizontal();\n return {\n x: horizontal ? target : null,\n y: horizontal ? null : target\n };\n }\n }\n return null;\n }\n function computeCircularBoundary(source) {\n var scale = source.el._scale;\n var options = scale.options;\n var length = scale.chart.data.labels.length;\n var fill = source.fill;\n var target = [];\n var start, end, center, i, point;\n if (!length) {\n return null;\n }\n start = options.ticks.reverse ? scale.max : scale.min;\n end = options.ticks.reverse ? scale.min : scale.max;\n center = scale.getPointPositionForValue(0, start);\n for (i = 0; i < length; ++i) {\n point = fill === 'start' || fill === 'end' ? scale.getPointPositionForValue(i, fill === 'start' ? start : end) : scale.getBasePosition(i);\n if (options.gridLines.circular) {\n point.cx = center.x;\n point.cy = center.y;\n point.angle = scale.getIndexAngle(i) - Math.PI / 2;\n }\n target.push(point);\n }\n return target;\n }\n function computeBoundary(source) {\n var scale = source.el._scale || {};\n if (scale.getPointPositionForValue) {\n return computeCircularBoundary(source);\n }\n return computeLinearBoundary(source);\n }\n function resolveTarget(sources, index, propagate) {\n var source = sources[index];\n var fill = source.fill;\n var visited = [index];\n var target;\n if (!propagate) {\n return fill;\n }\n while (fill !== false && visited.indexOf(fill) === -1) {\n if (!isFinite(fill)) {\n return fill;\n }\n target = sources[fill];\n if (!target) {\n return false;\n }\n if (target.visible) {\n return fill;\n }\n visited.push(fill);\n fill = target.fill;\n }\n return false;\n }\n function createMapper(source) {\n var fill = source.fill;\n var type = 'dataset';\n if (fill === false) {\n return null;\n }\n if (!isFinite(fill)) {\n type = 'boundary';\n }\n return mappers[type](source);\n }\n function isDrawable(point) {\n return point && !point.skip;\n }\n function drawArea(ctx, curve0, curve1, len0, len1) {\n var i, cx, cy, r;\n if (!len0 || !len1) {\n return;\n }\n\n // building first area curve (normal)\n ctx.moveTo(curve0[0].x, curve0[0].y);\n for (i = 1; i < len0; ++i) {\n helpers$1.canvas.lineTo(ctx, curve0[i - 1], curve0[i]);\n }\n if (curve1[0].angle !== undefined) {\n cx = curve1[0].cx;\n cy = curve1[0].cy;\n r = Math.sqrt(Math.pow(curve1[0].x - cx, 2) + Math.pow(curve1[0].y - cy, 2));\n for (i = len1 - 1; i > 0; --i) {\n ctx.arc(cx, cy, r, curve1[i].angle, curve1[i - 1].angle, true);\n }\n return;\n }\n\n // joining the two area curves\n ctx.lineTo(curve1[len1 - 1].x, curve1[len1 - 1].y);\n\n // building opposite area curve (reverse)\n for (i = len1 - 1; i > 0; --i) {\n helpers$1.canvas.lineTo(ctx, curve1[i], curve1[i - 1], true);\n }\n }\n function doFill(ctx, points, mapper, view, color, loop) {\n var count = points.length;\n var span = view.spanGaps;\n var curve0 = [];\n var curve1 = [];\n var len0 = 0;\n var len1 = 0;\n var i, ilen, index, p0, p1, d0, d1, loopOffset;\n ctx.beginPath();\n for (i = 0, ilen = count; i < ilen; ++i) {\n index = i % count;\n p0 = points[index]._view;\n p1 = mapper(p0, index, view);\n d0 = isDrawable(p0);\n d1 = isDrawable(p1);\n if (loop && loopOffset === undefined && d0) {\n loopOffset = i + 1;\n ilen = count + loopOffset;\n }\n if (d0 && d1) {\n len0 = curve0.push(p0);\n len1 = curve1.push(p1);\n } else if (len0 && len1) {\n if (!span) {\n drawArea(ctx, curve0, curve1, len0, len1);\n len0 = len1 = 0;\n curve0 = [];\n curve1 = [];\n } else {\n if (d0) {\n curve0.push(p0);\n }\n if (d1) {\n curve1.push(p1);\n }\n }\n }\n }\n drawArea(ctx, curve0, curve1, len0, len1);\n ctx.closePath();\n ctx.fillStyle = color;\n ctx.fill();\n }\n var plugin_filler = {\n id: 'filler',\n afterDatasetsUpdate: function (chart, options) {\n var count = (chart.data.datasets || []).length;\n var propagate = options.propagate;\n var sources = [];\n var meta, i, el, source;\n for (i = 0; i < count; ++i) {\n meta = chart.getDatasetMeta(i);\n el = meta.dataset;\n source = null;\n if (el && el._model && el instanceof elements.Line) {\n source = {\n visible: chart.isDatasetVisible(i),\n fill: decodeFill(el, i, count),\n chart: chart,\n el: el\n };\n }\n meta.$filler = source;\n sources.push(source);\n }\n for (i = 0; i < count; ++i) {\n source = sources[i];\n if (!source) {\n continue;\n }\n source.fill = resolveTarget(sources, i, propagate);\n source.boundary = computeBoundary(source);\n source.mapper = createMapper(source);\n }\n },\n beforeDatasetsDraw: function (chart) {\n var metasets = chart._getSortedVisibleDatasetMetas();\n var ctx = chart.ctx;\n var meta, i, el, view, points, mapper, color;\n for (i = metasets.length - 1; i >= 0; --i) {\n meta = metasets[i].$filler;\n if (!meta || !meta.visible) {\n continue;\n }\n el = meta.el;\n view = el._view;\n points = el._children || [];\n mapper = meta.mapper;\n color = view.backgroundColor || core_defaults.global.defaultColor;\n if (mapper && color && points.length) {\n helpers$1.canvas.clipArea(ctx, chart.chartArea);\n doFill(ctx, points, mapper, view, color, el._loop);\n helpers$1.canvas.unclipArea(ctx);\n }\n }\n }\n };\n var getRtlHelper$1 = helpers$1.rtl.getRtlAdapter;\n var noop$1 = helpers$1.noop;\n var valueOrDefault$e = helpers$1.valueOrDefault;\n core_defaults._set('global', {\n legend: {\n display: true,\n position: 'top',\n align: 'center',\n fullWidth: true,\n reverse: false,\n weight: 1000,\n // a callback that will handle\n onClick: function (e, legendItem) {\n var index = legendItem.datasetIndex;\n var ci = this.chart;\n var meta = ci.getDatasetMeta(index);\n\n // See controller.isDatasetVisible comment\n meta.hidden = meta.hidden === null ? !ci.data.datasets[index].hidden : null;\n\n // We hid a dataset ... rerender the chart\n ci.update();\n },\n onHover: null,\n onLeave: null,\n labels: {\n boxWidth: 40,\n padding: 10,\n // Generates labels shown in the legend\n // Valid properties to return:\n // text : text to display\n // fillStyle : fill of coloured box\n // strokeStyle: stroke of coloured box\n // hidden : if this legend item refers to a hidden item\n // lineCap : cap style for line\n // lineDash\n // lineDashOffset :\n // lineJoin :\n // lineWidth :\n generateLabels: function (chart) {\n var datasets = chart.data.datasets;\n var options = chart.options.legend || {};\n var usePointStyle = options.labels && options.labels.usePointStyle;\n return chart._getSortedDatasetMetas().map(function (meta) {\n var style = meta.controller.getStyle(usePointStyle ? 0 : undefined);\n return {\n text: datasets[meta.index].label,\n fillStyle: style.backgroundColor,\n hidden: !chart.isDatasetVisible(meta.index),\n lineCap: style.borderCapStyle,\n lineDash: style.borderDash,\n lineDashOffset: style.borderDashOffset,\n lineJoin: style.borderJoinStyle,\n lineWidth: style.borderWidth,\n strokeStyle: style.borderColor,\n pointStyle: style.pointStyle,\n rotation: style.rotation,\n // Below is extra data used for toggling the datasets\n datasetIndex: meta.index\n };\n }, this);\n }\n }\n },\n legendCallback: function (chart) {\n var list = document.createElement('ul');\n var datasets = chart.data.datasets;\n var i, ilen, listItem, listItemSpan;\n list.setAttribute('class', chart.id + '-legend');\n for (i = 0, ilen = datasets.length; i < ilen; i++) {\n listItem = list.appendChild(document.createElement('li'));\n listItemSpan = listItem.appendChild(document.createElement('span'));\n listItemSpan.style.backgroundColor = datasets[i].backgroundColor;\n if (datasets[i].label) {\n listItem.appendChild(document.createTextNode(datasets[i].label));\n }\n }\n return list.outerHTML;\n }\n });\n\n /**\r\n * Helper function to get the box width based on the usePointStyle option\r\n * @param {object} labelopts - the label options on the legend\r\n * @param {number} fontSize - the label font size\r\n * @return {number} width of the color box area\r\n */\n function getBoxWidth(labelOpts, fontSize) {\n return labelOpts.usePointStyle && labelOpts.boxWidth > fontSize ? fontSize : labelOpts.boxWidth;\n }\n\n /**\r\n * IMPORTANT: this class is exposed publicly as Chart.Legend, backward compatibility required!\r\n */\n var Legend = core_element.extend({\n initialize: function (config) {\n var me = this;\n helpers$1.extend(me, config);\n\n // Contains hit boxes for each dataset (in dataset order)\n me.legendHitBoxes = [];\n\n /**\r\n \t * @private\r\n \t */\n me._hoveredItem = null;\n\n // Are we in doughnut mode which has a different data type\n me.doughnutMode = false;\n },\n // These methods are ordered by lifecycle. Utilities then follow.\n // Any function defined here is inherited by all legend types.\n // Any function can be extended by the legend type\n\n beforeUpdate: noop$1,\n update: function (maxWidth, maxHeight, margins) {\n var me = this;\n\n // Update Lifecycle - Probably don't want to ever extend or overwrite this function ;)\n me.beforeUpdate();\n\n // Absorb the master measurements\n me.maxWidth = maxWidth;\n me.maxHeight = maxHeight;\n me.margins = margins;\n\n // Dimensions\n me.beforeSetDimensions();\n me.setDimensions();\n me.afterSetDimensions();\n // Labels\n me.beforeBuildLabels();\n me.buildLabels();\n me.afterBuildLabels();\n\n // Fit\n me.beforeFit();\n me.fit();\n me.afterFit();\n //\n me.afterUpdate();\n return me.minSize;\n },\n afterUpdate: noop$1,\n //\n\n beforeSetDimensions: noop$1,\n setDimensions: function () {\n var me = this;\n // Set the unconstrained dimension before label rotation\n if (me.isHorizontal()) {\n // Reset position before calculating rotation\n me.width = me.maxWidth;\n me.left = 0;\n me.right = me.width;\n } else {\n me.height = me.maxHeight;\n\n // Reset position before calculating rotation\n me.top = 0;\n me.bottom = me.height;\n }\n\n // Reset padding\n me.paddingLeft = 0;\n me.paddingTop = 0;\n me.paddingRight = 0;\n me.paddingBottom = 0;\n\n // Reset minSize\n me.minSize = {\n width: 0,\n height: 0\n };\n },\n afterSetDimensions: noop$1,\n //\n\n beforeBuildLabels: noop$1,\n buildLabels: function () {\n var me = this;\n var labelOpts = me.options.labels || {};\n var legendItems = helpers$1.callback(labelOpts.generateLabels, [me.chart], me) || [];\n if (labelOpts.filter) {\n legendItems = legendItems.filter(function (item) {\n return labelOpts.filter(item, me.chart.data);\n });\n }\n if (me.options.reverse) {\n legendItems.reverse();\n }\n me.legendItems = legendItems;\n },\n afterBuildLabels: noop$1,\n //\n\n beforeFit: noop$1,\n fit: function () {\n var me = this;\n var opts = me.options;\n var labelOpts = opts.labels;\n var display = opts.display;\n var ctx = me.ctx;\n var labelFont = helpers$1.options._parseFont(labelOpts);\n var fontSize = labelFont.size;\n\n // Reset hit boxes\n var hitboxes = me.legendHitBoxes = [];\n var minSize = me.minSize;\n var isHorizontal = me.isHorizontal();\n if (isHorizontal) {\n minSize.width = me.maxWidth; // fill all the width\n minSize.height = display ? 10 : 0;\n } else {\n minSize.width = display ? 10 : 0;\n minSize.height = me.maxHeight; // fill all the height\n }\n\n // Increase sizes here\n if (!display) {\n me.width = minSize.width = me.height = minSize.height = 0;\n return;\n }\n ctx.font = labelFont.string;\n if (isHorizontal) {\n // Labels\n\n // Width of each line of legend boxes. Labels wrap onto multiple lines when there are too many to fit on one\n var lineWidths = me.lineWidths = [0];\n var totalHeight = 0;\n ctx.textAlign = 'left';\n ctx.textBaseline = 'middle';\n helpers$1.each(me.legendItems, function (legendItem, i) {\n var boxWidth = getBoxWidth(labelOpts, fontSize);\n var width = boxWidth + fontSize / 2 + ctx.measureText(legendItem.text).width;\n if (i === 0 || lineWidths[lineWidths.length - 1] + width + 2 * labelOpts.padding > minSize.width) {\n totalHeight += fontSize + labelOpts.padding;\n lineWidths[lineWidths.length - (i > 0 ? 0 : 1)] = 0;\n }\n\n // Store the hitbox width and height here. Final position will be updated in `draw`\n hitboxes[i] = {\n left: 0,\n top: 0,\n width: width,\n height: fontSize\n };\n lineWidths[lineWidths.length - 1] += width + labelOpts.padding;\n });\n minSize.height += totalHeight;\n } else {\n var vPadding = labelOpts.padding;\n var columnWidths = me.columnWidths = [];\n var columnHeights = me.columnHeights = [];\n var totalWidth = labelOpts.padding;\n var currentColWidth = 0;\n var currentColHeight = 0;\n helpers$1.each(me.legendItems, function (legendItem, i) {\n var boxWidth = getBoxWidth(labelOpts, fontSize);\n var itemWidth = boxWidth + fontSize / 2 + ctx.measureText(legendItem.text).width;\n\n // If too tall, go to new column\n if (i > 0 && currentColHeight + fontSize + 2 * vPadding > minSize.height) {\n totalWidth += currentColWidth + labelOpts.padding;\n columnWidths.push(currentColWidth); // previous column width\n columnHeights.push(currentColHeight);\n currentColWidth = 0;\n currentColHeight = 0;\n }\n\n // Get max width\n currentColWidth = Math.max(currentColWidth, itemWidth);\n currentColHeight += fontSize + vPadding;\n\n // Store the hitbox width and height here. Final position will be updated in `draw`\n hitboxes[i] = {\n left: 0,\n top: 0,\n width: itemWidth,\n height: fontSize\n };\n });\n totalWidth += currentColWidth;\n columnWidths.push(currentColWidth);\n columnHeights.push(currentColHeight);\n minSize.width += totalWidth;\n }\n me.width = minSize.width;\n me.height = minSize.height;\n },\n afterFit: noop$1,\n // Shared Methods\n isHorizontal: function () {\n return this.options.position === 'top' || this.options.position === 'bottom';\n },\n // Actually draw the legend on the canvas\n draw: function () {\n var me = this;\n var opts = me.options;\n var labelOpts = opts.labels;\n var globalDefaults = core_defaults.global;\n var defaultColor = globalDefaults.defaultColor;\n var lineDefault = globalDefaults.elements.line;\n var legendHeight = me.height;\n var columnHeights = me.columnHeights;\n var legendWidth = me.width;\n var lineWidths = me.lineWidths;\n if (!opts.display) {\n return;\n }\n var rtlHelper = getRtlHelper$1(opts.rtl, me.left, me.minSize.width);\n var ctx = me.ctx;\n var fontColor = valueOrDefault$e(labelOpts.fontColor, globalDefaults.defaultFontColor);\n var labelFont = helpers$1.options._parseFont(labelOpts);\n var fontSize = labelFont.size;\n var cursor;\n\n // Canvas setup\n ctx.textAlign = rtlHelper.textAlign('left');\n ctx.textBaseline = 'middle';\n ctx.lineWidth = 0.5;\n ctx.strokeStyle = fontColor; // for strikethrough effect\n ctx.fillStyle = fontColor; // render in correct colour\n ctx.font = labelFont.string;\n var boxWidth = getBoxWidth(labelOpts, fontSize);\n var hitboxes = me.legendHitBoxes;\n\n // current position\n var drawLegendBox = function (x, y, legendItem) {\n if (isNaN(boxWidth) || boxWidth <= 0) {\n return;\n }\n\n // Set the ctx for the box\n ctx.save();\n var lineWidth = valueOrDefault$e(legendItem.lineWidth, lineDefault.borderWidth);\n ctx.fillStyle = valueOrDefault$e(legendItem.fillStyle, defaultColor);\n ctx.lineCap = valueOrDefault$e(legendItem.lineCap, lineDefault.borderCapStyle);\n ctx.lineDashOffset = valueOrDefault$e(legendItem.lineDashOffset, lineDefault.borderDashOffset);\n ctx.lineJoin = valueOrDefault$e(legendItem.lineJoin, lineDefault.borderJoinStyle);\n ctx.lineWidth = lineWidth;\n ctx.strokeStyle = valueOrDefault$e(legendItem.strokeStyle, defaultColor);\n if (ctx.setLineDash) {\n // IE 9 and 10 do not support line dash\n ctx.setLineDash(valueOrDefault$e(legendItem.lineDash, lineDefault.borderDash));\n }\n if (labelOpts && labelOpts.usePointStyle) {\n // Recalculate x and y for drawPoint() because its expecting\n // x and y to be center of figure (instead of top left)\n var radius = boxWidth * Math.SQRT2 / 2;\n var centerX = rtlHelper.xPlus(x, boxWidth / 2);\n var centerY = y + fontSize / 2;\n\n // Draw pointStyle as legend symbol\n helpers$1.canvas.drawPoint(ctx, legendItem.pointStyle, radius, centerX, centerY, legendItem.rotation);\n } else {\n // Draw box as legend symbol\n ctx.fillRect(rtlHelper.leftForLtr(x, boxWidth), y, boxWidth, fontSize);\n if (lineWidth !== 0) {\n ctx.strokeRect(rtlHelper.leftForLtr(x, boxWidth), y, boxWidth, fontSize);\n }\n }\n ctx.restore();\n };\n var fillText = function (x, y, legendItem, textWidth) {\n var halfFontSize = fontSize / 2;\n var xLeft = rtlHelper.xPlus(x, boxWidth + halfFontSize);\n var yMiddle = y + halfFontSize;\n ctx.fillText(legendItem.text, xLeft, yMiddle);\n if (legendItem.hidden) {\n // Strikethrough the text if hidden\n ctx.beginPath();\n ctx.lineWidth = 2;\n ctx.moveTo(xLeft, yMiddle);\n ctx.lineTo(rtlHelper.xPlus(xLeft, textWidth), yMiddle);\n ctx.stroke();\n }\n };\n var alignmentOffset = function (dimension, blockSize) {\n switch (opts.align) {\n case 'start':\n return labelOpts.padding;\n case 'end':\n return dimension - blockSize;\n default:\n // center\n return (dimension - blockSize + labelOpts.padding) / 2;\n }\n };\n\n // Horizontal\n var isHorizontal = me.isHorizontal();\n if (isHorizontal) {\n cursor = {\n x: me.left + alignmentOffset(legendWidth, lineWidths[0]),\n y: me.top + labelOpts.padding,\n line: 0\n };\n } else {\n cursor = {\n x: me.left + labelOpts.padding,\n y: me.top + alignmentOffset(legendHeight, columnHeights[0]),\n line: 0\n };\n }\n helpers$1.rtl.overrideTextDirection(me.ctx, opts.textDirection);\n var itemHeight = fontSize + labelOpts.padding;\n helpers$1.each(me.legendItems, function (legendItem, i) {\n var textWidth = ctx.measureText(legendItem.text).width;\n var width = boxWidth + fontSize / 2 + textWidth;\n var x = cursor.x;\n var y = cursor.y;\n rtlHelper.setWidth(me.minSize.width);\n\n // Use (me.left + me.minSize.width) and (me.top + me.minSize.height)\n // instead of me.right and me.bottom because me.width and me.height\n // may have been changed since me.minSize was calculated\n if (isHorizontal) {\n if (i > 0 && x + width + labelOpts.padding > me.left + me.minSize.width) {\n y = cursor.y += itemHeight;\n cursor.line++;\n x = cursor.x = me.left + alignmentOffset(legendWidth, lineWidths[cursor.line]);\n }\n } else if (i > 0 && y + itemHeight > me.top + me.minSize.height) {\n x = cursor.x = x + me.columnWidths[cursor.line] + labelOpts.padding;\n cursor.line++;\n y = cursor.y = me.top + alignmentOffset(legendHeight, columnHeights[cursor.line]);\n }\n var realX = rtlHelper.x(x);\n drawLegendBox(realX, y, legendItem);\n hitboxes[i].left = rtlHelper.leftForLtr(realX, hitboxes[i].width);\n hitboxes[i].top = y;\n\n // Fill the actual label\n fillText(realX, y, legendItem, textWidth);\n if (isHorizontal) {\n cursor.x += width + labelOpts.padding;\n } else {\n cursor.y += itemHeight;\n }\n });\n helpers$1.rtl.restoreTextDirection(me.ctx, opts.textDirection);\n },\n /**\r\n * @private\r\n */\n _getLegendItemAt: function (x, y) {\n var me = this;\n var i, hitBox, lh;\n if (x >= me.left && x <= me.right && y >= me.top && y <= me.bottom) {\n // See if we are touching one of the dataset boxes\n lh = me.legendHitBoxes;\n for (i = 0; i < lh.length; ++i) {\n hitBox = lh[i];\n if (x >= hitBox.left && x <= hitBox.left + hitBox.width && y >= hitBox.top && y <= hitBox.top + hitBox.height) {\n // Touching an element\n return me.legendItems[i];\n }\n }\n }\n return null;\n },\n /**\r\n * Handle an event\r\n * @private\r\n * @param {IEvent} event - The event to handle\r\n */\n handleEvent: function (e) {\n var me = this;\n var opts = me.options;\n var type = e.type === 'mouseup' ? 'click' : e.type;\n var hoveredItem;\n if (type === 'mousemove') {\n if (!opts.onHover && !opts.onLeave) {\n return;\n }\n } else if (type === 'click') {\n if (!opts.onClick) {\n return;\n }\n } else {\n return;\n }\n\n // Chart event already has relative position in it\n hoveredItem = me._getLegendItemAt(e.x, e.y);\n if (type === 'click') {\n if (hoveredItem && opts.onClick) {\n // use e.native for backwards compatibility\n opts.onClick.call(me, e.native, hoveredItem);\n }\n } else {\n if (opts.onLeave && hoveredItem !== me._hoveredItem) {\n if (me._hoveredItem) {\n opts.onLeave.call(me, e.native, me._hoveredItem);\n }\n me._hoveredItem = hoveredItem;\n }\n if (opts.onHover && hoveredItem) {\n // use e.native for backwards compatibility\n opts.onHover.call(me, e.native, hoveredItem);\n }\n }\n }\n });\n function createNewLegendAndAttach(chart, legendOpts) {\n var legend = new Legend({\n ctx: chart.ctx,\n options: legendOpts,\n chart: chart\n });\n core_layouts.configure(chart, legend, legendOpts);\n core_layouts.addBox(chart, legend);\n chart.legend = legend;\n }\n var plugin_legend = {\n id: 'legend',\n /**\r\n * Backward compatibility: since 2.1.5, the legend is registered as a plugin, making\r\n * Chart.Legend obsolete. To avoid a breaking change, we export the Legend as part of\r\n * the plugin, which one will be re-exposed in the chart.js file.\r\n * https://github.com/chartjs/Chart.js/pull/2640\r\n * @private\r\n */\n _element: Legend,\n beforeInit: function (chart) {\n var legendOpts = chart.options.legend;\n if (legendOpts) {\n createNewLegendAndAttach(chart, legendOpts);\n }\n },\n beforeUpdate: function (chart) {\n var legendOpts = chart.options.legend;\n var legend = chart.legend;\n if (legendOpts) {\n helpers$1.mergeIf(legendOpts, core_defaults.global.legend);\n if (legend) {\n core_layouts.configure(chart, legend, legendOpts);\n legend.options = legendOpts;\n } else {\n createNewLegendAndAttach(chart, legendOpts);\n }\n } else if (legend) {\n core_layouts.removeBox(chart, legend);\n delete chart.legend;\n }\n },\n afterEvent: function (chart, e) {\n var legend = chart.legend;\n if (legend) {\n legend.handleEvent(e);\n }\n }\n };\n var noop$2 = helpers$1.noop;\n core_defaults._set('global', {\n title: {\n display: false,\n fontStyle: 'bold',\n fullWidth: true,\n padding: 10,\n position: 'top',\n text: '',\n weight: 2000 // by default greater than legend (1000) to be above\n }\n });\n\n /**\r\n * IMPORTANT: this class is exposed publicly as Chart.Legend, backward compatibility required!\r\n */\n var Title = core_element.extend({\n initialize: function (config) {\n var me = this;\n helpers$1.extend(me, config);\n\n // Contains hit boxes for each dataset (in dataset order)\n me.legendHitBoxes = [];\n },\n // These methods are ordered by lifecycle. Utilities then follow.\n\n beforeUpdate: noop$2,\n update: function (maxWidth, maxHeight, margins) {\n var me = this;\n\n // Update Lifecycle - Probably don't want to ever extend or overwrite this function ;)\n me.beforeUpdate();\n\n // Absorb the master measurements\n me.maxWidth = maxWidth;\n me.maxHeight = maxHeight;\n me.margins = margins;\n\n // Dimensions\n me.beforeSetDimensions();\n me.setDimensions();\n me.afterSetDimensions();\n // Labels\n me.beforeBuildLabels();\n me.buildLabels();\n me.afterBuildLabels();\n\n // Fit\n me.beforeFit();\n me.fit();\n me.afterFit();\n //\n me.afterUpdate();\n return me.minSize;\n },\n afterUpdate: noop$2,\n //\n\n beforeSetDimensions: noop$2,\n setDimensions: function () {\n var me = this;\n // Set the unconstrained dimension before label rotation\n if (me.isHorizontal()) {\n // Reset position before calculating rotation\n me.width = me.maxWidth;\n me.left = 0;\n me.right = me.width;\n } else {\n me.height = me.maxHeight;\n\n // Reset position before calculating rotation\n me.top = 0;\n me.bottom = me.height;\n }\n\n // Reset padding\n me.paddingLeft = 0;\n me.paddingTop = 0;\n me.paddingRight = 0;\n me.paddingBottom = 0;\n\n // Reset minSize\n me.minSize = {\n width: 0,\n height: 0\n };\n },\n afterSetDimensions: noop$2,\n //\n\n beforeBuildLabels: noop$2,\n buildLabels: noop$2,\n afterBuildLabels: noop$2,\n //\n\n beforeFit: noop$2,\n fit: function () {\n var me = this;\n var opts = me.options;\n var minSize = me.minSize = {};\n var isHorizontal = me.isHorizontal();\n var lineCount, textSize;\n if (!opts.display) {\n me.width = minSize.width = me.height = minSize.height = 0;\n return;\n }\n lineCount = helpers$1.isArray(opts.text) ? opts.text.length : 1;\n textSize = lineCount * helpers$1.options._parseFont(opts).lineHeight + opts.padding * 2;\n me.width = minSize.width = isHorizontal ? me.maxWidth : textSize;\n me.height = minSize.height = isHorizontal ? textSize : me.maxHeight;\n },\n afterFit: noop$2,\n // Shared Methods\n isHorizontal: function () {\n var pos = this.options.position;\n return pos === 'top' || pos === 'bottom';\n },\n // Actually draw the title block on the canvas\n draw: function () {\n var me = this;\n var ctx = me.ctx;\n var opts = me.options;\n if (!opts.display) {\n return;\n }\n var fontOpts = helpers$1.options._parseFont(opts);\n var lineHeight = fontOpts.lineHeight;\n var offset = lineHeight / 2 + opts.padding;\n var rotation = 0;\n var top = me.top;\n var left = me.left;\n var bottom = me.bottom;\n var right = me.right;\n var maxWidth, titleX, titleY;\n ctx.fillStyle = helpers$1.valueOrDefault(opts.fontColor, core_defaults.global.defaultFontColor); // render in correct colour\n ctx.font = fontOpts.string;\n\n // Horizontal\n if (me.isHorizontal()) {\n titleX = left + (right - left) / 2; // midpoint of the width\n titleY = top + offset;\n maxWidth = right - left;\n } else {\n titleX = opts.position === 'left' ? left + offset : right - offset;\n titleY = top + (bottom - top) / 2;\n maxWidth = bottom - top;\n rotation = Math.PI * (opts.position === 'left' ? -0.5 : 0.5);\n }\n ctx.save();\n ctx.translate(titleX, titleY);\n ctx.rotate(rotation);\n ctx.textAlign = 'center';\n ctx.textBaseline = 'middle';\n var text = opts.text;\n if (helpers$1.isArray(text)) {\n var y = 0;\n for (var i = 0; i < text.length; ++i) {\n ctx.fillText(text[i], 0, y, maxWidth);\n y += lineHeight;\n }\n } else {\n ctx.fillText(text, 0, 0, maxWidth);\n }\n ctx.restore();\n }\n });\n function createNewTitleBlockAndAttach(chart, titleOpts) {\n var title = new Title({\n ctx: chart.ctx,\n options: titleOpts,\n chart: chart\n });\n core_layouts.configure(chart, title, titleOpts);\n core_layouts.addBox(chart, title);\n chart.titleBlock = title;\n }\n var plugin_title = {\n id: 'title',\n /**\r\n * Backward compatibility: since 2.1.5, the title is registered as a plugin, making\r\n * Chart.Title obsolete. To avoid a breaking change, we export the Title as part of\r\n * the plugin, which one will be re-exposed in the chart.js file.\r\n * https://github.com/chartjs/Chart.js/pull/2640\r\n * @private\r\n */\n _element: Title,\n beforeInit: function (chart) {\n var titleOpts = chart.options.title;\n if (titleOpts) {\n createNewTitleBlockAndAttach(chart, titleOpts);\n }\n },\n beforeUpdate: function (chart) {\n var titleOpts = chart.options.title;\n var titleBlock = chart.titleBlock;\n if (titleOpts) {\n helpers$1.mergeIf(titleOpts, core_defaults.global.title);\n if (titleBlock) {\n core_layouts.configure(chart, titleBlock, titleOpts);\n titleBlock.options = titleOpts;\n } else {\n createNewTitleBlockAndAttach(chart, titleOpts);\n }\n } else if (titleBlock) {\n core_layouts.removeBox(chart, titleBlock);\n delete chart.titleBlock;\n }\n }\n };\n var plugins = {};\n var filler = plugin_filler;\n var legend = plugin_legend;\n var title = plugin_title;\n plugins.filler = filler;\n plugins.legend = legend;\n plugins.title = title;\n\n /**\r\n * @namespace Chart\r\n */\n\n core_controller.helpers = helpers$1;\n\n // @todo dispatch these helpers into appropriated helpers/helpers.* file and write unit tests!\n core_helpers();\n core_controller._adapters = core_adapters;\n core_controller.Animation = core_animation;\n core_controller.animationService = core_animations;\n core_controller.controllers = controllers;\n core_controller.DatasetController = core_datasetController;\n core_controller.defaults = core_defaults;\n core_controller.Element = core_element;\n core_controller.elements = elements;\n core_controller.Interaction = core_interaction;\n core_controller.layouts = core_layouts;\n core_controller.platform = platform;\n core_controller.plugins = core_plugins;\n core_controller.Scale = core_scale;\n core_controller.scaleService = core_scaleService;\n core_controller.Ticks = core_ticks;\n core_controller.Tooltip = core_tooltip;\n\n // Register built-in scales\n\n core_controller.helpers.each(scales, function (scale, type) {\n core_controller.scaleService.registerScaleType(type, scale, scale._defaults);\n });\n\n // Load to register built-in adapters (as side effects)\n\n // Loading built-in plugins\n\n for (var k in plugins) {\n if (plugins.hasOwnProperty(k)) {\n core_controller.plugins.register(plugins[k]);\n }\n }\n core_controller.platform.initialize();\n var src = core_controller;\n if (typeof window !== 'undefined') {\n window.Chart = core_controller;\n }\n\n // DEPRECATIONS\n\n /**\r\n * Provided for backward compatibility, not available anymore\r\n * @namespace Chart.Chart\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.Chart = core_controller;\n\n /**\r\n * Provided for backward compatibility, not available anymore\r\n * @namespace Chart.Legend\r\n * @deprecated since version 2.1.5\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.Legend = plugins.legend._element;\n\n /**\r\n * Provided for backward compatibility, not available anymore\r\n * @namespace Chart.Title\r\n * @deprecated since version 2.1.5\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.Title = plugins.title._element;\n\n /**\r\n * Provided for backward compatibility, use Chart.plugins instead\r\n * @namespace Chart.pluginService\r\n * @deprecated since version 2.1.5\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.pluginService = core_controller.plugins;\n\n /**\r\n * Provided for backward compatibility, inheriting from Chart.PlugingBase has no\r\n * effect, instead simply create/register plugins via plain JavaScript objects.\r\n * @interface Chart.PluginBase\r\n * @deprecated since version 2.5.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.PluginBase = core_controller.Element.extend({});\n\n /**\r\n * Provided for backward compatibility, use Chart.helpers.canvas instead.\r\n * @namespace Chart.canvasHelpers\r\n * @deprecated since version 2.6.0\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.canvasHelpers = core_controller.helpers.canvas;\n\n /**\r\n * Provided for backward compatibility, use Chart.layouts instead.\r\n * @namespace Chart.layoutService\r\n * @deprecated since version 2.7.3\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.layoutService = core_controller.layouts;\n\n /**\r\n * Provided for backward compatibility, not available anymore.\r\n * @namespace Chart.LinearScaleBase\r\n * @deprecated since version 2.8\r\n * @todo remove at version 3\r\n * @private\r\n */\n core_controller.LinearScaleBase = scale_linearbase;\n\n /**\r\n * Provided for backward compatibility, instead we should create a new Chart\r\n * by setting the type in the config (`new Chart(id, {type: '{chart-type}'}`).\r\n * @deprecated since version 2.8.0\r\n * @todo remove at version 3\r\n */\n core_controller.helpers.each(['Bar', 'Bubble', 'Doughnut', 'Line', 'PolarArea', 'Radar', 'Scatter'], function (klass) {\n core_controller[klass] = function (ctx, cfg) {\n return new core_controller(ctx, core_controller.helpers.merge(cfg || {}, {\n type: klass.charAt(0).toLowerCase() + klass.slice(1)\n }));\n };\n });\n return src;\n});","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\n/**\n * The default equality function used for `signal` and `computed`, which uses referential equality.\n */\nfunction defaultEquals(a, b) {\n return Object.is(a, b);\n}\n\n/**\n * The currently active consumer `ReactiveNode`, if running code in a reactive context.\n *\n * Change this via `setActiveConsumer`.\n */\nlet activeConsumer = null;\nlet inNotificationPhase = false;\n/**\n * Global epoch counter. Incremented whenever a source signal is set.\n */\nlet epoch = 1;\n/**\n * Symbol used to tell `Signal`s apart from other functions.\n *\n * This can be used to auto-unwrap signals in various cases, or to auto-wrap non-signal values.\n */\nconst SIGNAL = /* @__PURE__ */Symbol('SIGNAL');\nfunction setActiveConsumer(consumer) {\n const prev = activeConsumer;\n activeConsumer = consumer;\n return prev;\n}\nfunction getActiveConsumer() {\n return activeConsumer;\n}\nfunction isInNotificationPhase() {\n return inNotificationPhase;\n}\nfunction isReactive(value) {\n return value[SIGNAL] !== undefined;\n}\nconst REACTIVE_NODE = {\n version: 0,\n lastCleanEpoch: 0,\n dirty: false,\n producerNode: undefined,\n producerLastReadVersion: undefined,\n producerIndexOfThis: undefined,\n nextProducerIndex: 0,\n liveConsumerNode: undefined,\n liveConsumerIndexOfThis: undefined,\n consumerAllowSignalWrites: false,\n consumerIsAlwaysLive: false,\n kind: 'unknown',\n producerMustRecompute: () => false,\n producerRecomputeValue: () => {},\n consumerMarkedDirty: () => {},\n consumerOnSignalRead: () => {}\n};\n/**\n * Called by implementations when a producer's signal is read.\n */\nfunction producerAccessed(node) {\n if (inNotificationPhase) {\n throw new Error(typeof ngDevMode !== 'undefined' && ngDevMode ? `Assertion error: signal read during notification phase` : '');\n }\n if (activeConsumer === null) {\n // Accessed outside of a reactive context, so nothing to record.\n return;\n }\n activeConsumer.consumerOnSignalRead(node);\n // This producer is the `idx`th dependency of `activeConsumer`.\n const idx = activeConsumer.nextProducerIndex++;\n assertConsumerNode(activeConsumer);\n if (idx < activeConsumer.producerNode.length && activeConsumer.producerNode[idx] !== node) {\n // There's been a change in producers since the last execution of `activeConsumer`.\n // `activeConsumer.producerNode[idx]` holds a stale dependency which will be be removed and\n // replaced with `this`.\n //\n // If `activeConsumer` isn't live, then this is a no-op, since we can replace the producer in\n // `activeConsumer.producerNode` directly. However, if `activeConsumer` is live, then we need\n // to remove it from the stale producer's `liveConsumer`s.\n if (consumerIsLive(activeConsumer)) {\n const staleProducer = activeConsumer.producerNode[idx];\n producerRemoveLiveConsumerAtIndex(staleProducer, activeConsumer.producerIndexOfThis[idx]);\n // At this point, the only record of `staleProducer` is the reference at\n // `activeConsumer.producerNode[idx]` which will be overwritten below.\n }\n }\n if (activeConsumer.producerNode[idx] !== node) {\n // We're a new dependency of the consumer (at `idx`).\n activeConsumer.producerNode[idx] = node;\n // If the active consumer is live, then add it as a live consumer. If not, then use 0 as a\n // placeholder value.\n activeConsumer.producerIndexOfThis[idx] = consumerIsLive(activeConsumer) ? producerAddLiveConsumer(node, activeConsumer, idx) : 0;\n }\n activeConsumer.producerLastReadVersion[idx] = node.version;\n}\n/**\n * Increment the global epoch counter.\n *\n * Called by source producers (that is, not computeds) whenever their values change.\n */\nfunction producerIncrementEpoch() {\n epoch++;\n}\n/**\n * Ensure this producer's `version` is up-to-date.\n */\nfunction producerUpdateValueVersion(node) {\n if (consumerIsLive(node) && !node.dirty) {\n // A live consumer will be marked dirty by producers, so a clean state means that its version\n // is guaranteed to be up-to-date.\n return;\n }\n if (!node.dirty && node.lastCleanEpoch === epoch) {\n // Even non-live consumers can skip polling if they previously found themselves to be clean at\n // the current epoch, since their dependencies could not possibly have changed (such a change\n // would've increased the epoch).\n return;\n }\n if (!node.producerMustRecompute(node) && !consumerPollProducersForChange(node)) {\n // None of our producers report a change since the last time they were read, so no\n // recomputation of our value is necessary, and we can consider ourselves clean.\n producerMarkClean(node);\n return;\n }\n node.producerRecomputeValue(node);\n // After recomputing the value, we're no longer dirty.\n producerMarkClean(node);\n}\n/**\n * Propagate a dirty notification to live consumers of this producer.\n */\nfunction producerNotifyConsumers(node) {\n if (node.liveConsumerNode === undefined) {\n return;\n }\n // Prevent signal reads when we're updating the graph\n const prev = inNotificationPhase;\n inNotificationPhase = true;\n try {\n for (const consumer of node.liveConsumerNode) {\n if (!consumer.dirty) {\n consumerMarkDirty(consumer);\n }\n }\n } finally {\n inNotificationPhase = prev;\n }\n}\n/**\n * Whether this `ReactiveNode` in its producer capacity is currently allowed to initiate updates,\n * based on the current consumer context.\n */\nfunction producerUpdatesAllowed() {\n return activeConsumer?.consumerAllowSignalWrites !== false;\n}\nfunction consumerMarkDirty(node) {\n node.dirty = true;\n producerNotifyConsumers(node);\n node.consumerMarkedDirty?.(node);\n}\nfunction producerMarkClean(node) {\n node.dirty = false;\n node.lastCleanEpoch = epoch;\n}\n/**\n * Prepare this consumer to run a computation in its reactive context.\n *\n * Must be called by subclasses which represent reactive computations, before those computations\n * begin.\n */\nfunction consumerBeforeComputation(node) {\n node && (node.nextProducerIndex = 0);\n return setActiveConsumer(node);\n}\n/**\n * Finalize this consumer's state after a reactive computation has run.\n *\n * Must be called by subclasses which represent reactive computations, after those computations\n * have finished.\n */\nfunction consumerAfterComputation(node, prevConsumer) {\n setActiveConsumer(prevConsumer);\n if (!node || node.producerNode === undefined || node.producerIndexOfThis === undefined || node.producerLastReadVersion === undefined) {\n return;\n }\n if (consumerIsLive(node)) {\n // For live consumers, we need to remove the producer -> consumer edge for any stale producers\n // which weren't dependencies after the recomputation.\n for (let i = node.nextProducerIndex; i < node.producerNode.length; i++) {\n producerRemoveLiveConsumerAtIndex(node.producerNode[i], node.producerIndexOfThis[i]);\n }\n }\n // Truncate the producer tracking arrays.\n // Perf note: this is essentially truncating the length to `node.nextProducerIndex`, but\n // benchmarking has shown that individual pop operations are faster.\n while (node.producerNode.length > node.nextProducerIndex) {\n node.producerNode.pop();\n node.producerLastReadVersion.pop();\n node.producerIndexOfThis.pop();\n }\n}\n/**\n * Determine whether this consumer has any dependencies which have changed since the last time\n * they were read.\n */\nfunction consumerPollProducersForChange(node) {\n assertConsumerNode(node);\n // Poll producers for change.\n for (let i = 0; i < node.producerNode.length; i++) {\n const producer = node.producerNode[i];\n const seenVersion = node.producerLastReadVersion[i];\n // First check the versions. A mismatch means that the producer's value is known to have\n // changed since the last time we read it.\n if (seenVersion !== producer.version) {\n return true;\n }\n // The producer's version is the same as the last time we read it, but it might itself be\n // stale. Force the producer to recompute its version (calculating a new value if necessary).\n producerUpdateValueVersion(producer);\n // Now when we do this check, `producer.version` is guaranteed to be up to date, so if the\n // versions still match then it has not changed since the last time we read it.\n if (seenVersion !== producer.version) {\n return true;\n }\n }\n return false;\n}\n/**\n * Disconnect this consumer from the graph.\n */\nfunction consumerDestroy(node) {\n assertConsumerNode(node);\n if (consumerIsLive(node)) {\n // Drop all connections from the graph to this node.\n for (let i = 0; i < node.producerNode.length; i++) {\n producerRemoveLiveConsumerAtIndex(node.producerNode[i], node.producerIndexOfThis[i]);\n }\n }\n // Truncate all the arrays to drop all connection from this node to the graph.\n node.producerNode.length = node.producerLastReadVersion.length = node.producerIndexOfThis.length = 0;\n if (node.liveConsumerNode) {\n node.liveConsumerNode.length = node.liveConsumerIndexOfThis.length = 0;\n }\n}\n/**\n * Add `consumer` as a live consumer of this node.\n *\n * Note that this operation is potentially transitive. If this node becomes live, then it becomes\n * a live consumer of all of its current producers.\n */\nfunction producerAddLiveConsumer(node, consumer, indexOfThis) {\n assertProducerNode(node);\n if (node.liveConsumerNode.length === 0 && isConsumerNode(node)) {\n // When going from 0 to 1 live consumers, we become a live consumer to our producers.\n for (let i = 0; i < node.producerNode.length; i++) {\n node.producerIndexOfThis[i] = producerAddLiveConsumer(node.producerNode[i], node, i);\n }\n }\n node.liveConsumerIndexOfThis.push(indexOfThis);\n return node.liveConsumerNode.push(consumer) - 1;\n}\n/**\n * Remove the live consumer at `idx`.\n */\nfunction producerRemoveLiveConsumerAtIndex(node, idx) {\n assertProducerNode(node);\n if (typeof ngDevMode !== 'undefined' && ngDevMode && idx >= node.liveConsumerNode.length) {\n throw new Error(`Assertion error: active consumer index ${idx} is out of bounds of ${node.liveConsumerNode.length} consumers)`);\n }\n if (node.liveConsumerNode.length === 1 && isConsumerNode(node)) {\n // When removing the last live consumer, we will no longer be live. We need to remove\n // ourselves from our producers' tracking (which may cause consumer-producers to lose\n // liveness as well).\n for (let i = 0; i < node.producerNode.length; i++) {\n producerRemoveLiveConsumerAtIndex(node.producerNode[i], node.producerIndexOfThis[i]);\n }\n }\n // Move the last value of `liveConsumers` into `idx`. Note that if there's only a single\n // live consumer, this is a no-op.\n const lastIdx = node.liveConsumerNode.length - 1;\n node.liveConsumerNode[idx] = node.liveConsumerNode[lastIdx];\n node.liveConsumerIndexOfThis[idx] = node.liveConsumerIndexOfThis[lastIdx];\n // Truncate the array.\n node.liveConsumerNode.length--;\n node.liveConsumerIndexOfThis.length--;\n // If the index is still valid, then we need to fix the index pointer from the producer to this\n // consumer, and update it from `lastIdx` to `idx` (accounting for the move above).\n if (idx < node.liveConsumerNode.length) {\n const idxProducer = node.liveConsumerIndexOfThis[idx];\n const consumer = node.liveConsumerNode[idx];\n assertConsumerNode(consumer);\n consumer.producerIndexOfThis[idxProducer] = idx;\n }\n}\nfunction consumerIsLive(node) {\n return node.consumerIsAlwaysLive || (node?.liveConsumerNode?.length ?? 0) > 0;\n}\nfunction assertConsumerNode(node) {\n node.producerNode ??= [];\n node.producerIndexOfThis ??= [];\n node.producerLastReadVersion ??= [];\n}\nfunction assertProducerNode(node) {\n node.liveConsumerNode ??= [];\n node.liveConsumerIndexOfThis ??= [];\n}\nfunction isConsumerNode(node) {\n return node.producerNode !== undefined;\n}\n\n/**\n * Create a computed signal which derives a reactive value from an expression.\n */\nfunction createComputed(computation) {\n const node = Object.create(COMPUTED_NODE);\n node.computation = computation;\n const computed = () => {\n // Check if the value needs updating before returning it.\n producerUpdateValueVersion(node);\n // Record that someone looked at this signal.\n producerAccessed(node);\n if (node.value === ERRORED) {\n throw node.error;\n }\n return node.value;\n };\n computed[SIGNAL] = node;\n return computed;\n}\n/**\n * A dedicated symbol used before a computed value has been calculated for the first time.\n * Explicitly typed as `any` so we can use it as signal's value.\n */\nconst UNSET = /* @__PURE__ */Symbol('UNSET');\n/**\n * A dedicated symbol used in place of a computed signal value to indicate that a given computation\n * is in progress. Used to detect cycles in computation chains.\n * Explicitly typed as `any` so we can use it as signal's value.\n */\nconst COMPUTING = /* @__PURE__ */Symbol('COMPUTING');\n/**\n * A dedicated symbol used in place of a computed signal value to indicate that a given computation\n * failed. The thrown error is cached until the computation gets dirty again.\n * Explicitly typed as `any` so we can use it as signal's value.\n */\nconst ERRORED = /* @__PURE__ */Symbol('ERRORED');\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `COMPUTED_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst COMPUTED_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n value: UNSET,\n dirty: true,\n error: null,\n equal: defaultEquals,\n kind: 'computed',\n producerMustRecompute(node) {\n // Force a recomputation if there's no current value, or if the current value is in the\n // process of being calculated (which should throw an error).\n return node.value === UNSET || node.value === COMPUTING;\n },\n producerRecomputeValue(node) {\n if (node.value === COMPUTING) {\n // Our computation somehow led to a cyclic read of itself.\n throw new Error('Detected cycle in computations.');\n }\n const oldValue = node.value;\n node.value = COMPUTING;\n const prevConsumer = consumerBeforeComputation(node);\n let newValue;\n let wasEqual = false;\n try {\n newValue = node.computation();\n // We want to mark this node as errored if calling `equal` throws; however, we don't want\n // to track any reactive reads inside `equal`.\n setActiveConsumer(null);\n wasEqual = oldValue !== UNSET && oldValue !== ERRORED && newValue !== ERRORED && node.equal(oldValue, newValue);\n } catch (err) {\n newValue = ERRORED;\n node.error = err;\n } finally {\n consumerAfterComputation(node, prevConsumer);\n }\n if (wasEqual) {\n // No change to `valueVersion` - old and new values are\n // semantically equivalent.\n node.value = oldValue;\n return;\n }\n node.value = newValue;\n node.version++;\n }\n };\n})();\nfunction defaultThrowError() {\n throw new Error();\n}\nlet throwInvalidWriteToSignalErrorFn = defaultThrowError;\nfunction throwInvalidWriteToSignalError(node) {\n throwInvalidWriteToSignalErrorFn(node);\n}\nfunction setThrowInvalidWriteToSignalError(fn) {\n throwInvalidWriteToSignalErrorFn = fn;\n}\n\n/**\n * If set, called after `WritableSignal`s are updated.\n *\n * This hook can be used to achieve various effects, such as running effects synchronously as part\n * of setting a signal.\n */\nlet postSignalSetFn = null;\n/**\n * Create a `Signal` that can be set or updated directly.\n */\nfunction createSignal(initialValue) {\n const node = Object.create(SIGNAL_NODE);\n node.value = initialValue;\n const getter = () => {\n producerAccessed(node);\n return node.value;\n };\n getter[SIGNAL] = node;\n return getter;\n}\nfunction setPostSignalSetFn(fn) {\n const prev = postSignalSetFn;\n postSignalSetFn = fn;\n return prev;\n}\nfunction signalGetFn() {\n producerAccessed(this);\n return this.value;\n}\nfunction signalSetFn(node, newValue) {\n if (!producerUpdatesAllowed()) {\n throwInvalidWriteToSignalError(node);\n }\n if (!node.equal(node.value, newValue)) {\n node.value = newValue;\n signalValueChanged(node);\n }\n}\nfunction signalUpdateFn(node, updater) {\n if (!producerUpdatesAllowed()) {\n throwInvalidWriteToSignalError(node);\n }\n signalSetFn(node, updater(node.value));\n}\nfunction runPostSignalSetFn() {\n postSignalSetFn?.();\n}\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `COMPUTED_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst SIGNAL_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n equal: defaultEquals,\n value: undefined,\n kind: 'signal'\n };\n})();\nfunction signalValueChanged(node) {\n node.version++;\n producerIncrementEpoch();\n producerNotifyConsumers(node);\n postSignalSetFn?.();\n}\nfunction createLinkedSignal(sourceFn, computationFn, equalityFn) {\n const node = Object.create(LINKED_SIGNAL_NODE);\n node.source = sourceFn;\n node.computation = computationFn;\n if (equalityFn != undefined) {\n node.equal = equalityFn;\n }\n const linkedSignalGetter = () => {\n // Check if the value needs updating before returning it.\n producerUpdateValueVersion(node);\n // Record that someone looked at this signal.\n producerAccessed(node);\n if (node.value === ERRORED) {\n throw node.error;\n }\n return node.value;\n };\n const getter = linkedSignalGetter;\n getter[SIGNAL] = node;\n return getter;\n}\nfunction linkedSignalSetFn(node, newValue) {\n producerUpdateValueVersion(node);\n signalSetFn(node, newValue);\n producerMarkClean(node);\n}\nfunction linkedSignalUpdateFn(node, updater) {\n producerUpdateValueVersion(node);\n signalUpdateFn(node, updater);\n producerMarkClean(node);\n}\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `LINKED_SIGNAL_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst LINKED_SIGNAL_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n value: UNSET,\n dirty: true,\n error: null,\n equal: defaultEquals,\n producerMustRecompute(node) {\n // Force a recomputation if there's no current value, or if the current value is in the\n // process of being calculated (which should throw an error).\n return node.value === UNSET || node.value === COMPUTING;\n },\n producerRecomputeValue(node) {\n if (node.value === COMPUTING) {\n // Our computation somehow led to a cyclic read of itself.\n throw new Error('Detected cycle in computations.');\n }\n const oldValue = node.value;\n node.value = COMPUTING;\n const prevConsumer = consumerBeforeComputation(node);\n let newValue;\n try {\n const newSourceValue = node.source();\n const prev = oldValue === UNSET || oldValue === ERRORED ? undefined : {\n source: node.sourceValue,\n value: oldValue\n };\n newValue = node.computation(newSourceValue, prev);\n node.sourceValue = newSourceValue;\n } catch (err) {\n newValue = ERRORED;\n node.error = err;\n } finally {\n consumerAfterComputation(node, prevConsumer);\n }\n if (oldValue !== UNSET && newValue !== ERRORED && node.equal(oldValue, newValue)) {\n // No change to `valueVersion` - old and new values are\n // semantically equivalent.\n node.value = oldValue;\n return;\n }\n node.value = newValue;\n node.version++;\n }\n };\n})();\nfunction createWatch(fn, schedule, allowSignalWrites) {\n const node = Object.create(WATCH_NODE);\n if (allowSignalWrites) {\n node.consumerAllowSignalWrites = true;\n }\n node.fn = fn;\n node.schedule = schedule;\n const registerOnCleanup = cleanupFn => {\n node.cleanupFn = cleanupFn;\n };\n function isWatchNodeDestroyed(node) {\n return node.fn === null && node.schedule === null;\n }\n function destroyWatchNode(node) {\n if (!isWatchNodeDestroyed(node)) {\n consumerDestroy(node); // disconnect watcher from the reactive graph\n node.cleanupFn();\n // nullify references to the integration functions to mark node as destroyed\n node.fn = null;\n node.schedule = null;\n node.cleanupFn = NOOP_CLEANUP_FN;\n }\n }\n const run = () => {\n if (node.fn === null) {\n // trying to run a destroyed watch is noop\n return;\n }\n if (isInNotificationPhase()) {\n throw new Error(`Schedulers cannot synchronously execute watches while scheduling.`);\n }\n node.dirty = false;\n if (node.hasRun && !consumerPollProducersForChange(node)) {\n return;\n }\n node.hasRun = true;\n const prevConsumer = consumerBeforeComputation(node);\n try {\n node.cleanupFn();\n node.cleanupFn = NOOP_CLEANUP_FN;\n node.fn(registerOnCleanup);\n } finally {\n consumerAfterComputation(node, prevConsumer);\n }\n };\n node.ref = {\n notify: () => consumerMarkDirty(node),\n run,\n cleanup: () => node.cleanupFn(),\n destroy: () => destroyWatchNode(node),\n [SIGNAL]: node\n };\n return node.ref;\n}\nconst NOOP_CLEANUP_FN = () => {};\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `COMPUTED_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst WATCH_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n consumerIsAlwaysLive: true,\n consumerAllowSignalWrites: false,\n consumerMarkedDirty: node => {\n if (node.schedule !== null) {\n node.schedule(node.ref);\n }\n },\n hasRun: false,\n cleanupFn: NOOP_CLEANUP_FN\n };\n})();\nfunction setAlternateWeakRefImpl(impl) {\n // TODO: remove this function\n}\nexport { REACTIVE_NODE, SIGNAL, SIGNAL_NODE, consumerAfterComputation, consumerBeforeComputation, consumerDestroy, consumerMarkDirty, consumerPollProducersForChange, createComputed, createLinkedSignal, createSignal, createWatch, defaultEquals, getActiveConsumer, isInNotificationPhase, isReactive, linkedSignalSetFn, linkedSignalUpdateFn, producerAccessed, producerIncrementEpoch, producerMarkClean, producerNotifyConsumers, producerUpdateValueVersion, producerUpdatesAllowed, runPostSignalSetFn, setActiveConsumer, setAlternateWeakRefImpl, setPostSignalSetFn, setThrowInvalidWriteToSignalError, signalSetFn, signalUpdateFn };\n","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\n/**\n * Current injector value used by `inject`.\n * - `undefined`: it is an error to call `inject`\n * - `null`: `inject` can be called but there is no injector (limp-mode).\n * - Injector instance: Use the injector for resolution.\n */\nlet _currentInjector = undefined;\nfunction getCurrentInjector() {\n return _currentInjector;\n}\nfunction setCurrentInjector(injector) {\n const former = _currentInjector;\n _currentInjector = injector;\n return former;\n}\n\n/**\n * Value returned if the key-value pair couldn't be found in the context\n * hierarchy.\n */\nconst NOT_FOUND = Symbol('NotFound');\n/**\n * Error thrown when the key-value pair couldn't be found in the context\n * hierarchy. Context can be attached below.\n */\nclass NotFoundError extends Error {\n constructor(message) {\n super(message);\n }\n}\n/**\n * Type guard for checking if an unknown value is a NotFound.\n */\nfunction isNotFound(e) {\n return e === NOT_FOUND || e instanceof NotFoundError;\n}\nexport { NOT_FOUND, NotFoundError, getCurrentInjector, isNotFound, setCurrentInjector };\n","export function isFunction(x) {\n return typeof x === 'function';\n}\n","let _enable_super_gross_mode_that_will_cause_bad_things = false;\nexport const config = {\n Promise: undefined,\n set useDeprecatedSynchronousErrorHandling(value) {\n if (value) {\n const error = new Error();\n console.warn('DEPRECATED! RxJS was set to use deprecated synchronous error handling behavior by code at: \\n' + error.stack);\n } else if (_enable_super_gross_mode_that_will_cause_bad_things) {\n console.log('RxJS: Back to a better error behavior. Thank you. <3');\n }\n _enable_super_gross_mode_that_will_cause_bad_things = value;\n },\n get useDeprecatedSynchronousErrorHandling() {\n return _enable_super_gross_mode_that_will_cause_bad_things;\n }\n};\n","export function hostReportError(err) {\n setTimeout(() => {\n throw err;\n }, 0);\n}\n","import { config } from './config';\nimport { hostReportError } from './util/hostReportError';\nexport const empty = {\n closed: true,\n next(value) {},\n error(err) {\n if (config.useDeprecatedSynchronousErrorHandling) {\n throw err;\n } else {\n hostReportError(err);\n }\n },\n complete() {}\n};\n","export const isArray = (() => Array.isArray || (x => x && typeof x.length === 'number'))();\n","export function isObject(x) {\n return x !== null && typeof x === 'object';\n}\n","const UnsubscriptionErrorImpl = (() => {\n function UnsubscriptionErrorImpl(errors) {\n Error.call(this);\n this.message = errors ? `${errors.length} errors occurred during unsubscription:\n${errors.map((err, i) => `${i + 1}) ${err.toString()}`).join('\\n ')}` : '';\n this.name = 'UnsubscriptionError';\n this.errors = errors;\n return this;\n }\n UnsubscriptionErrorImpl.prototype = Object.create(Error.prototype);\n return UnsubscriptionErrorImpl;\n})();\nexport const UnsubscriptionError = UnsubscriptionErrorImpl;\n","import { isArray } from './util/isArray';\nimport { isObject } from './util/isObject';\nimport { isFunction } from './util/isFunction';\nimport { UnsubscriptionError } from './util/UnsubscriptionError';\nexport class Subscription {\n constructor(unsubscribe) {\n this.closed = false;\n this._parentOrParents = null;\n this._subscriptions = null;\n if (unsubscribe) {\n this._ctorUnsubscribe = true;\n this._unsubscribe = unsubscribe;\n }\n }\n unsubscribe() {\n let errors;\n if (this.closed) {\n return;\n }\n let {\n _parentOrParents,\n _ctorUnsubscribe,\n _unsubscribe,\n _subscriptions\n } = this;\n this.closed = true;\n this._parentOrParents = null;\n this._subscriptions = null;\n if (_parentOrParents instanceof Subscription) {\n _parentOrParents.remove(this);\n } else if (_parentOrParents !== null) {\n for (let index = 0; index < _parentOrParents.length; ++index) {\n const parent = _parentOrParents[index];\n parent.remove(this);\n }\n }\n if (isFunction(_unsubscribe)) {\n if (_ctorUnsubscribe) {\n this._unsubscribe = undefined;\n }\n try {\n _unsubscribe.call(this);\n } catch (e) {\n errors = e instanceof UnsubscriptionError ? flattenUnsubscriptionErrors(e.errors) : [e];\n }\n }\n if (isArray(_subscriptions)) {\n let index = -1;\n let len = _subscriptions.length;\n while (++index < len) {\n const sub = _subscriptions[index];\n if (isObject(sub)) {\n try {\n sub.unsubscribe();\n } catch (e) {\n errors = errors || [];\n if (e instanceof UnsubscriptionError) {\n errors = errors.concat(flattenUnsubscriptionErrors(e.errors));\n } else {\n errors.push(e);\n }\n }\n }\n }\n }\n if (errors) {\n throw new UnsubscriptionError(errors);\n }\n }\n add(teardown) {\n let subscription = teardown;\n if (!teardown) {\n return Subscription.EMPTY;\n }\n switch (typeof teardown) {\n case 'function':\n subscription = new Subscription(teardown);\n case 'object':\n if (subscription === this || subscription.closed || typeof subscription.unsubscribe !== 'function') {\n return subscription;\n } else if (this.closed) {\n subscription.unsubscribe();\n return subscription;\n } else if (!(subscription instanceof Subscription)) {\n const tmp = subscription;\n subscription = new Subscription();\n subscription._subscriptions = [tmp];\n }\n break;\n default:\n {\n throw new Error('unrecognized teardown ' + teardown + ' added to Subscription.');\n }\n }\n let {\n _parentOrParents\n } = subscription;\n if (_parentOrParents === null) {\n subscription._parentOrParents = this;\n } else if (_parentOrParents instanceof Subscription) {\n if (_parentOrParents === this) {\n return subscription;\n }\n subscription._parentOrParents = [_parentOrParents, this];\n } else if (_parentOrParents.indexOf(this) === -1) {\n _parentOrParents.push(this);\n } else {\n return subscription;\n }\n const subscriptions = this._subscriptions;\n if (subscriptions === null) {\n this._subscriptions = [subscription];\n } else {\n subscriptions.push(subscription);\n }\n return subscription;\n }\n remove(subscription) {\n const subscriptions = this._subscriptions;\n if (subscriptions) {\n const subscriptionIndex = subscriptions.indexOf(subscription);\n if (subscriptionIndex !== -1) {\n subscriptions.splice(subscriptionIndex, 1);\n }\n }\n }\n}\nSubscription.EMPTY = function (empty) {\n empty.closed = true;\n return empty;\n}(new Subscription());\nfunction flattenUnsubscriptionErrors(errors) {\n return errors.reduce((errs, err) => errs.concat(err instanceof UnsubscriptionError ? err.errors : err), []);\n}\n","export const rxSubscriber = (() => typeof Symbol === 'function' ? Symbol('rxSubscriber') : '@@rxSubscriber_' + Math.random())();\nexport const $$rxSubscriber = rxSubscriber;\n","import { isFunction } from './util/isFunction';\nimport { empty as emptyObserver } from './Observer';\nimport { Subscription } from './Subscription';\nimport { rxSubscriber as rxSubscriberSymbol } from '../internal/symbol/rxSubscriber';\nimport { config } from './config';\nimport { hostReportError } from './util/hostReportError';\nexport class Subscriber extends Subscription {\n constructor(destinationOrNext, error, complete) {\n super();\n this.syncErrorValue = null;\n this.syncErrorThrown = false;\n this.syncErrorThrowable = false;\n this.isStopped = false;\n switch (arguments.length) {\n case 0:\n this.destination = emptyObserver;\n break;\n case 1:\n if (!destinationOrNext) {\n this.destination = emptyObserver;\n break;\n }\n if (typeof destinationOrNext === 'object') {\n if (destinationOrNext instanceof Subscriber) {\n this.syncErrorThrowable = destinationOrNext.syncErrorThrowable;\n this.destination = destinationOrNext;\n destinationOrNext.add(this);\n } else {\n this.syncErrorThrowable = true;\n this.destination = new SafeSubscriber(this, destinationOrNext);\n }\n break;\n }\n default:\n this.syncErrorThrowable = true;\n this.destination = new SafeSubscriber(this, destinationOrNext, error, complete);\n break;\n }\n }\n [rxSubscriberSymbol]() {\n return this;\n }\n static create(next, error, complete) {\n const subscriber = new Subscriber(next, error, complete);\n subscriber.syncErrorThrowable = false;\n return subscriber;\n }\n next(value) {\n if (!this.isStopped) {\n this._next(value);\n }\n }\n error(err) {\n if (!this.isStopped) {\n this.isStopped = true;\n this._error(err);\n }\n }\n complete() {\n if (!this.isStopped) {\n this.isStopped = true;\n this._complete();\n }\n }\n unsubscribe() {\n if (this.closed) {\n return;\n }\n this.isStopped = true;\n super.unsubscribe();\n }\n _next(value) {\n this.destination.next(value);\n }\n _error(err) {\n this.destination.error(err);\n this.unsubscribe();\n }\n _complete() {\n this.destination.complete();\n this.unsubscribe();\n }\n _unsubscribeAndRecycle() {\n const {\n _parentOrParents\n } = this;\n this._parentOrParents = null;\n this.unsubscribe();\n this.closed = false;\n this.isStopped = false;\n this._parentOrParents = _parentOrParents;\n return this;\n }\n}\nexport class SafeSubscriber extends Subscriber {\n constructor(_parentSubscriber, observerOrNext, error, complete) {\n super();\n this._parentSubscriber = _parentSubscriber;\n let next;\n let context = this;\n if (isFunction(observerOrNext)) {\n next = observerOrNext;\n } else if (observerOrNext) {\n next = observerOrNext.next;\n error = observerOrNext.error;\n complete = observerOrNext.complete;\n if (observerOrNext !== emptyObserver) {\n context = Object.create(observerOrNext);\n if (isFunction(context.unsubscribe)) {\n this.add(context.unsubscribe.bind(context));\n }\n context.unsubscribe = this.unsubscribe.bind(this);\n }\n }\n this._context = context;\n this._next = next;\n this._error = error;\n this._complete = complete;\n }\n next(value) {\n if (!this.isStopped && this._next) {\n const {\n _parentSubscriber\n } = this;\n if (!config.useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) {\n this.__tryOrUnsub(this._next, value);\n } else if (this.__tryOrSetError(_parentSubscriber, this._next, value)) {\n this.unsubscribe();\n }\n }\n }\n error(err) {\n if (!this.isStopped) {\n const {\n _parentSubscriber\n } = this;\n const {\n useDeprecatedSynchronousErrorHandling\n } = config;\n if (this._error) {\n if (!useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) {\n this.__tryOrUnsub(this._error, err);\n this.unsubscribe();\n } else {\n this.__tryOrSetError(_parentSubscriber, this._error, err);\n this.unsubscribe();\n }\n } else if (!_parentSubscriber.syncErrorThrowable) {\n this.unsubscribe();\n if (useDeprecatedSynchronousErrorHandling) {\n throw err;\n }\n hostReportError(err);\n } else {\n if (useDeprecatedSynchronousErrorHandling) {\n _parentSubscriber.syncErrorValue = err;\n _parentSubscriber.syncErrorThrown = true;\n } else {\n hostReportError(err);\n }\n this.unsubscribe();\n }\n }\n }\n complete() {\n if (!this.isStopped) {\n const {\n _parentSubscriber\n } = this;\n if (this._complete) {\n const wrappedComplete = () => this._complete.call(this._context);\n if (!config.useDeprecatedSynchronousErrorHandling || !_parentSubscriber.syncErrorThrowable) {\n this.__tryOrUnsub(wrappedComplete);\n this.unsubscribe();\n } else {\n this.__tryOrSetError(_parentSubscriber, wrappedComplete);\n this.unsubscribe();\n }\n } else {\n this.unsubscribe();\n }\n }\n }\n __tryOrUnsub(fn, value) {\n try {\n fn.call(this._context, value);\n } catch (err) {\n this.unsubscribe();\n if (config.useDeprecatedSynchronousErrorHandling) {\n throw err;\n } else {\n hostReportError(err);\n }\n }\n }\n __tryOrSetError(parent, fn, value) {\n if (!config.useDeprecatedSynchronousErrorHandling) {\n throw new Error('bad call');\n }\n try {\n fn.call(this._context, value);\n } catch (err) {\n if (config.useDeprecatedSynchronousErrorHandling) {\n parent.syncErrorValue = err;\n parent.syncErrorThrown = true;\n return true;\n } else {\n hostReportError(err);\n return true;\n }\n }\n return false;\n }\n _unsubscribe() {\n const {\n _parentSubscriber\n } = this;\n this._context = null;\n this._parentSubscriber = null;\n _parentSubscriber.unsubscribe();\n }\n}\n","import { Subscriber } from '../Subscriber';\nexport function canReportError(observer) {\n while (observer) {\n const {\n closed,\n destination,\n isStopped\n } = observer;\n if (closed || isStopped) {\n return false;\n } else if (destination && destination instanceof Subscriber) {\n observer = destination;\n } else {\n observer = null;\n }\n }\n return true;\n}\n","import { Subscriber } from '../Subscriber';\nimport { rxSubscriber as rxSubscriberSymbol } from '../symbol/rxSubscriber';\nimport { empty as emptyObserver } from '../Observer';\nexport function toSubscriber(nextOrObserver, error, complete) {\n if (nextOrObserver) {\n if (nextOrObserver instanceof Subscriber) {\n return nextOrObserver;\n }\n if (nextOrObserver[rxSubscriberSymbol]) {\n return nextOrObserver[rxSubscriberSymbol]();\n }\n }\n if (!nextOrObserver && !error && !complete) {\n return new Subscriber(emptyObserver);\n }\n return new Subscriber(nextOrObserver, error, complete);\n}\n","export const observable = (() => typeof Symbol === 'function' && Symbol.observable || '@@observable')();\n","export function identity(x) {\n return x;\n}\n","import { identity } from './identity';\nexport function pipe(...fns) {\n return pipeFromArray(fns);\n}\nexport function pipeFromArray(fns) {\n if (fns.length === 0) {\n return identity;\n }\n if (fns.length === 1) {\n return fns[0];\n }\n return function piped(input) {\n return fns.reduce((prev, fn) => fn(prev), input);\n };\n}\n","import { canReportError } from './util/canReportError';\nimport { toSubscriber } from './util/toSubscriber';\nimport { observable as Symbol_observable } from './symbol/observable';\nimport { pipeFromArray } from './util/pipe';\nimport { config } from './config';\nexport class Observable {\n constructor(subscribe) {\n this._isScalar = false;\n if (subscribe) {\n this._subscribe = subscribe;\n }\n }\n lift(operator) {\n const observable = new Observable();\n observable.source = this;\n observable.operator = operator;\n return observable;\n }\n subscribe(observerOrNext, error, complete) {\n const {\n operator\n } = this;\n const sink = toSubscriber(observerOrNext, error, complete);\n if (operator) {\n sink.add(operator.call(sink, this.source));\n } else {\n sink.add(this.source || config.useDeprecatedSynchronousErrorHandling && !sink.syncErrorThrowable ? this._subscribe(sink) : this._trySubscribe(sink));\n }\n if (config.useDeprecatedSynchronousErrorHandling) {\n if (sink.syncErrorThrowable) {\n sink.syncErrorThrowable = false;\n if (sink.syncErrorThrown) {\n throw sink.syncErrorValue;\n }\n }\n }\n return sink;\n }\n _trySubscribe(sink) {\n try {\n return this._subscribe(sink);\n } catch (err) {\n if (config.useDeprecatedSynchronousErrorHandling) {\n sink.syncErrorThrown = true;\n sink.syncErrorValue = err;\n }\n if (canReportError(sink)) {\n sink.error(err);\n } else {\n console.warn(err);\n }\n }\n }\n forEach(next, promiseCtor) {\n promiseCtor = getPromiseCtor(promiseCtor);\n return new promiseCtor((resolve, reject) => {\n let subscription;\n subscription = this.subscribe(value => {\n try {\n next(value);\n } catch (err) {\n reject(err);\n if (subscription) {\n subscription.unsubscribe();\n }\n }\n }, reject, resolve);\n });\n }\n _subscribe(subscriber) {\n const {\n source\n } = this;\n return source && source.subscribe(subscriber);\n }\n [Symbol_observable]() {\n return this;\n }\n pipe(...operations) {\n if (operations.length === 0) {\n return this;\n }\n return pipeFromArray(operations)(this);\n }\n toPromise(promiseCtor) {\n promiseCtor = getPromiseCtor(promiseCtor);\n return new promiseCtor((resolve, reject) => {\n let value;\n this.subscribe(x => value = x, err => reject(err), () => resolve(value));\n });\n }\n}\nObservable.create = subscribe => {\n return new Observable(subscribe);\n};\nfunction getPromiseCtor(promiseCtor) {\n if (!promiseCtor) {\n promiseCtor = config.Promise || Promise;\n }\n if (!promiseCtor) {\n throw new Error('no Promise impl found');\n }\n return promiseCtor;\n}\n","const ObjectUnsubscribedErrorImpl = (() => {\n function ObjectUnsubscribedErrorImpl() {\n Error.call(this);\n this.message = 'object unsubscribed';\n this.name = 'ObjectUnsubscribedError';\n return this;\n }\n ObjectUnsubscribedErrorImpl.prototype = Object.create(Error.prototype);\n return ObjectUnsubscribedErrorImpl;\n})();\nexport const ObjectUnsubscribedError = ObjectUnsubscribedErrorImpl;\n","import { Subscription } from './Subscription';\nexport class SubjectSubscription extends Subscription {\n constructor(subject, subscriber) {\n super();\n this.subject = subject;\n this.subscriber = subscriber;\n this.closed = false;\n }\n unsubscribe() {\n if (this.closed) {\n return;\n }\n this.closed = true;\n const subject = this.subject;\n const observers = subject.observers;\n this.subject = null;\n if (!observers || observers.length === 0 || subject.isStopped || subject.closed) {\n return;\n }\n const subscriberIndex = observers.indexOf(this.subscriber);\n if (subscriberIndex !== -1) {\n observers.splice(subscriberIndex, 1);\n }\n }\n}\n","import { Observable } from './Observable';\nimport { Subscriber } from './Subscriber';\nimport { Subscription } from './Subscription';\nimport { ObjectUnsubscribedError } from './util/ObjectUnsubscribedError';\nimport { SubjectSubscription } from './SubjectSubscription';\nimport { rxSubscriber as rxSubscriberSymbol } from '../internal/symbol/rxSubscriber';\nexport class SubjectSubscriber extends Subscriber {\n constructor(destination) {\n super(destination);\n this.destination = destination;\n }\n}\nexport class Subject extends Observable {\n constructor() {\n super();\n this.observers = [];\n this.closed = false;\n this.isStopped = false;\n this.hasError = false;\n this.thrownError = null;\n }\n [rxSubscriberSymbol]() {\n return new SubjectSubscriber(this);\n }\n lift(operator) {\n const subject = new AnonymousSubject(this, this);\n subject.operator = operator;\n return subject;\n }\n next(value) {\n if (this.closed) {\n throw new ObjectUnsubscribedError();\n }\n if (!this.isStopped) {\n const {\n observers\n } = this;\n const len = observers.length;\n const copy = observers.slice();\n for (let i = 0; i < len; i++) {\n copy[i].next(value);\n }\n }\n }\n error(err) {\n if (this.closed) {\n throw new ObjectUnsubscribedError();\n }\n this.hasError = true;\n this.thrownError = err;\n this.isStopped = true;\n const {\n observers\n } = this;\n const len = observers.length;\n const copy = observers.slice();\n for (let i = 0; i < len; i++) {\n copy[i].error(err);\n }\n this.observers.length = 0;\n }\n complete() {\n if (this.closed) {\n throw new ObjectUnsubscribedError();\n }\n this.isStopped = true;\n const {\n observers\n } = this;\n const len = observers.length;\n const copy = observers.slice();\n for (let i = 0; i < len; i++) {\n copy[i].complete();\n }\n this.observers.length = 0;\n }\n unsubscribe() {\n this.isStopped = true;\n this.closed = true;\n this.observers = null;\n }\n _trySubscribe(subscriber) {\n if (this.closed) {\n throw new ObjectUnsubscribedError();\n } else {\n return super._trySubscribe(subscriber);\n }\n }\n _subscribe(subscriber) {\n if (this.closed) {\n throw new ObjectUnsubscribedError();\n } else if (this.hasError) {\n subscriber.error(this.thrownError);\n return Subscription.EMPTY;\n } else if (this.isStopped) {\n subscriber.complete();\n return Subscription.EMPTY;\n } else {\n this.observers.push(subscriber);\n return new SubjectSubscription(this, subscriber);\n }\n }\n asObservable() {\n const observable = new Observable();\n observable.source = this;\n return observable;\n }\n}\nSubject.create = (destination, source) => {\n return new AnonymousSubject(destination, source);\n};\nexport class AnonymousSubject extends Subject {\n constructor(destination, source) {\n super();\n this.destination = destination;\n this.source = source;\n }\n next(value) {\n const {\n destination\n } = this;\n if (destination && destination.next) {\n destination.next(value);\n }\n }\n error(err) {\n const {\n destination\n } = this;\n if (destination && destination.error) {\n this.destination.error(err);\n }\n }\n complete() {\n const {\n destination\n } = this;\n if (destination && destination.complete) {\n this.destination.complete();\n }\n }\n _subscribe(subscriber) {\n const {\n source\n } = this;\n if (source) {\n return this.source.subscribe(subscriber);\n } else {\n return Subscription.EMPTY;\n }\n }\n}\n","import { Subscriber } from '../Subscriber';\nexport function refCount() {\n return function refCountOperatorFunction(source) {\n return source.lift(new RefCountOperator(source));\n };\n}\nclass RefCountOperator {\n constructor(connectable) {\n this.connectable = connectable;\n }\n call(subscriber, source) {\n const {\n connectable\n } = this;\n connectable._refCount++;\n const refCounter = new RefCountSubscriber(subscriber, connectable);\n const subscription = source.subscribe(refCounter);\n if (!refCounter.closed) {\n refCounter.connection = connectable.connect();\n }\n return subscription;\n }\n}\nclass RefCountSubscriber extends Subscriber {\n constructor(destination, connectable) {\n super(destination);\n this.connectable = connectable;\n }\n _unsubscribe() {\n const {\n connectable\n } = this;\n if (!connectable) {\n this.connection = null;\n return;\n }\n this.connectable = null;\n const refCount = connectable._refCount;\n if (refCount <= 0) {\n this.connection = null;\n return;\n }\n connectable._refCount = refCount - 1;\n if (refCount > 1) {\n this.connection = null;\n return;\n }\n const {\n connection\n } = this;\n const sharedConnection = connectable._connection;\n this.connection = null;\n if (sharedConnection && (!connection || sharedConnection === connection)) {\n sharedConnection.unsubscribe();\n }\n }\n}\n","import { SubjectSubscriber } from '../Subject';\nimport { Observable } from '../Observable';\nimport { Subscriber } from '../Subscriber';\nimport { Subscription } from '../Subscription';\nimport { refCount as higherOrderRefCount } from '../operators/refCount';\nexport class ConnectableObservable extends Observable {\n constructor(source, subjectFactory) {\n super();\n this.source = source;\n this.subjectFactory = subjectFactory;\n this._refCount = 0;\n this._isComplete = false;\n }\n _subscribe(subscriber) {\n return this.getSubject().subscribe(subscriber);\n }\n getSubject() {\n const subject = this._subject;\n if (!subject || subject.isStopped) {\n this._subject = this.subjectFactory();\n }\n return this._subject;\n }\n connect() {\n let connection = this._connection;\n if (!connection) {\n this._isComplete = false;\n connection = this._connection = new Subscription();\n connection.add(this.source.subscribe(new ConnectableSubscriber(this.getSubject(), this)));\n if (connection.closed) {\n this._connection = null;\n connection = Subscription.EMPTY;\n }\n }\n return connection;\n }\n refCount() {\n return higherOrderRefCount()(this);\n }\n}\nexport const connectableObservableDescriptor = (() => {\n const connectableProto = ConnectableObservable.prototype;\n return {\n operator: {\n value: null\n },\n _refCount: {\n value: 0,\n writable: true\n },\n _subject: {\n value: null,\n writable: true\n },\n _connection: {\n value: null,\n writable: true\n },\n _subscribe: {\n value: connectableProto._subscribe\n },\n _isComplete: {\n value: connectableProto._isComplete,\n writable: true\n },\n getSubject: {\n value: connectableProto.getSubject\n },\n connect: {\n value: connectableProto.connect\n },\n refCount: {\n value: connectableProto.refCount\n }\n };\n})();\nclass ConnectableSubscriber extends SubjectSubscriber {\n constructor(destination, connectable) {\n super(destination);\n this.connectable = connectable;\n }\n _error(err) {\n this._unsubscribe();\n super._error(err);\n }\n _complete() {\n this.connectable._isComplete = true;\n this._unsubscribe();\n super._complete();\n }\n _unsubscribe() {\n const connectable = this.connectable;\n if (connectable) {\n this.connectable = null;\n const connection = connectable._connection;\n connectable._refCount = 0;\n connectable._subject = null;\n connectable._connection = null;\n if (connection) {\n connection.unsubscribe();\n }\n }\n }\n}\nclass RefCountOperator {\n constructor(connectable) {\n this.connectable = connectable;\n }\n call(subscriber, source) {\n const {\n connectable\n } = this;\n connectable._refCount++;\n const refCounter = new RefCountSubscriber(subscriber, connectable);\n const subscription = source.subscribe(refCounter);\n if (!refCounter.closed) {\n refCounter.connection = connectable.connect();\n }\n return subscription;\n }\n}\nclass RefCountSubscriber extends Subscriber {\n constructor(destination, connectable) {\n super(destination);\n this.connectable = connectable;\n }\n _unsubscribe() {\n const {\n connectable\n } = this;\n if (!connectable) {\n this.connection = null;\n return;\n }\n this.connectable = null;\n const refCount = connectable._refCount;\n if (refCount <= 0) {\n this.connection = null;\n return;\n }\n connectable._refCount = refCount - 1;\n if (refCount > 1) {\n this.connection = null;\n return;\n }\n const {\n connection\n } = this;\n const sharedConnection = connectable._connection;\n this.connection = null;\n if (sharedConnection && (!connection || sharedConnection === connection)) {\n sharedConnection.unsubscribe();\n }\n }\n}\n","import { Subject } from './Subject';\nimport { ObjectUnsubscribedError } from './util/ObjectUnsubscribedError';\nexport class BehaviorSubject extends Subject {\n constructor(_value) {\n super();\n this._value = _value;\n }\n get value() {\n return this.getValue();\n }\n _subscribe(subscriber) {\n const subscription = super._subscribe(subscriber);\n if (subscription && !subscription.closed) {\n subscriber.next(this._value);\n }\n return subscription;\n }\n getValue() {\n if (this.hasError) {\n throw this.thrownError;\n } else if (this.closed) {\n throw new ObjectUnsubscribedError();\n } else {\n return this._value;\n }\n }\n next(value) {\n super.next(this._value = value);\n }\n}\n","import { Subscription } from '../Subscription';\nexport class Action extends Subscription {\n constructor(scheduler, work) {\n super();\n }\n schedule(state, delay = 0) {\n return this;\n }\n}\n","import { Action } from './Action';\nexport class AsyncAction extends Action {\n constructor(scheduler, work) {\n super(scheduler, work);\n this.scheduler = scheduler;\n this.work = work;\n this.pending = false;\n }\n schedule(state, delay = 0) {\n if (this.closed) {\n return this;\n }\n this.state = state;\n const id = this.id;\n const scheduler = this.scheduler;\n if (id != null) {\n this.id = this.recycleAsyncId(scheduler, id, delay);\n }\n this.pending = true;\n this.delay = delay;\n this.id = this.id || this.requestAsyncId(scheduler, this.id, delay);\n return this;\n }\n requestAsyncId(scheduler, id, delay = 0) {\n return setInterval(scheduler.flush.bind(scheduler, this), delay);\n }\n recycleAsyncId(scheduler, id, delay = 0) {\n if (delay !== null && this.delay === delay && this.pending === false) {\n return id;\n }\n clearInterval(id);\n return undefined;\n }\n execute(state, delay) {\n if (this.closed) {\n return new Error('executing a cancelled action');\n }\n this.pending = false;\n const error = this._execute(state, delay);\n if (error) {\n return error;\n } else if (this.pending === false && this.id != null) {\n this.id = this.recycleAsyncId(this.scheduler, this.id, null);\n }\n }\n _execute(state, delay) {\n let errored = false;\n let errorValue = undefined;\n try {\n this.work(state);\n } catch (e) {\n errored = true;\n errorValue = !!e && e || new Error(e);\n }\n if (errored) {\n this.unsubscribe();\n return errorValue;\n }\n }\n _unsubscribe() {\n const id = this.id;\n const scheduler = this.scheduler;\n const actions = scheduler.actions;\n const index = actions.indexOf(this);\n this.work = null;\n this.state = null;\n this.pending = false;\n this.scheduler = null;\n if (index !== -1) {\n actions.splice(index, 1);\n }\n if (id != null) {\n this.id = this.recycleAsyncId(scheduler, id, null);\n }\n this.delay = null;\n }\n}\n","import { AsyncAction } from './AsyncAction';\nexport class QueueAction extends AsyncAction {\n constructor(scheduler, work) {\n super(scheduler, work);\n this.scheduler = scheduler;\n this.work = work;\n }\n schedule(state, delay = 0) {\n if (delay > 0) {\n return super.schedule(state, delay);\n }\n this.delay = delay;\n this.state = state;\n this.scheduler.flush(this);\n return this;\n }\n execute(state, delay) {\n return delay > 0 || this.closed ? super.execute(state, delay) : this._execute(state, delay);\n }\n requestAsyncId(scheduler, id, delay = 0) {\n if (delay !== null && delay > 0 || delay === null && this.delay > 0) {\n return super.requestAsyncId(scheduler, id, delay);\n }\n return scheduler.flush(this);\n }\n}\n","export class Scheduler {\n constructor(SchedulerAction, now = Scheduler.now) {\n this.SchedulerAction = SchedulerAction;\n this.now = now;\n }\n schedule(work, delay = 0, state) {\n return new this.SchedulerAction(this, work).schedule(state, delay);\n }\n}\nScheduler.now = () => Date.now();\n","import { Scheduler } from '../Scheduler';\nexport class AsyncScheduler extends Scheduler {\n constructor(SchedulerAction, now = Scheduler.now) {\n super(SchedulerAction, () => {\n if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) {\n return AsyncScheduler.delegate.now();\n } else {\n return now();\n }\n });\n this.actions = [];\n this.active = false;\n this.scheduled = undefined;\n }\n schedule(work, delay = 0, state) {\n if (AsyncScheduler.delegate && AsyncScheduler.delegate !== this) {\n return AsyncScheduler.delegate.schedule(work, delay, state);\n } else {\n return super.schedule(work, delay, state);\n }\n }\n flush(action) {\n const {\n actions\n } = this;\n if (this.active) {\n actions.push(action);\n return;\n }\n let error;\n this.active = true;\n do {\n if (error = action.execute(action.state, action.delay)) {\n break;\n }\n } while (action = actions.shift());\n this.active = false;\n if (error) {\n while (action = actions.shift()) {\n action.unsubscribe();\n }\n throw error;\n }\n }\n}\n","import { AsyncScheduler } from './AsyncScheduler';\nexport class QueueScheduler extends AsyncScheduler {}\n","import { QueueAction } from './QueueAction';\nimport { QueueScheduler } from './QueueScheduler';\nexport const queueScheduler = new QueueScheduler(QueueAction);\nexport const queue = queueScheduler;\n","import { Observable } from '../Observable';\nexport const EMPTY = new Observable(subscriber => subscriber.complete());\nexport function empty(scheduler) {\n return scheduler ? emptyScheduled(scheduler) : EMPTY;\n}\nfunction emptyScheduled(scheduler) {\n return new Observable(subscriber => scheduler.schedule(() => subscriber.complete()));\n}\n","export function isScheduler(value) {\n return value && typeof value.schedule === 'function';\n}\n","export const subscribeToArray = array => subscriber => {\n for (let i = 0, len = array.length; i < len && !subscriber.closed; i++) {\n subscriber.next(array[i]);\n }\n subscriber.complete();\n};\n","import { Observable } from '../Observable';\nimport { Subscription } from '../Subscription';\nexport function scheduleArray(input, scheduler) {\n return new Observable(subscriber => {\n const sub = new Subscription();\n let i = 0;\n sub.add(scheduler.schedule(function () {\n if (i === input.length) {\n subscriber.complete();\n return;\n }\n subscriber.next(input[i++]);\n if (!subscriber.closed) {\n sub.add(this.schedule());\n }\n }));\n return sub;\n });\n}\n","import { Observable } from '../Observable';\nimport { subscribeToArray } from '../util/subscribeToArray';\nimport { scheduleArray } from '../scheduled/scheduleArray';\nexport function fromArray(input, scheduler) {\n if (!scheduler) {\n return new Observable(subscribeToArray(input));\n } else {\n return scheduleArray(input, scheduler);\n }\n}\n","import { isScheduler } from '../util/isScheduler';\nimport { fromArray } from './fromArray';\nimport { scheduleArray } from '../scheduled/scheduleArray';\nexport function of(...args) {\n let scheduler = args[args.length - 1];\n if (isScheduler(scheduler)) {\n args.pop();\n return scheduleArray(args, scheduler);\n } else {\n return fromArray(args);\n }\n}\n","import { Observable } from '../Observable';\nexport function throwError(error, scheduler) {\n if (!scheduler) {\n return new Observable(subscriber => subscriber.error(error));\n } else {\n return new Observable(subscriber => scheduler.schedule(dispatch, 0, {\n error,\n subscriber\n }));\n }\n}\nfunction dispatch({\n error,\n subscriber\n}) {\n subscriber.error(error);\n}\n","import { empty } from './observable/empty';\nimport { of } from './observable/of';\nimport { throwError } from './observable/throwError';\nexport var NotificationKind;\n(function (NotificationKind) {\n NotificationKind[\"NEXT\"] = \"N\";\n NotificationKind[\"ERROR\"] = \"E\";\n NotificationKind[\"COMPLETE\"] = \"C\";\n})(NotificationKind || (NotificationKind = {}));\nexport class Notification {\n constructor(kind, value, error) {\n this.kind = kind;\n this.value = value;\n this.error = error;\n this.hasValue = kind === 'N';\n }\n observe(observer) {\n switch (this.kind) {\n case 'N':\n return observer.next && observer.next(this.value);\n case 'E':\n return observer.error && observer.error(this.error);\n case 'C':\n return observer.complete && observer.complete();\n }\n }\n do(next, error, complete) {\n const kind = this.kind;\n switch (kind) {\n case 'N':\n return next && next(this.value);\n case 'E':\n return error && error(this.error);\n case 'C':\n return complete && complete();\n }\n }\n accept(nextOrObserver, error, complete) {\n if (nextOrObserver && typeof nextOrObserver.next === 'function') {\n return this.observe(nextOrObserver);\n } else {\n return this.do(nextOrObserver, error, complete);\n }\n }\n toObservable() {\n const kind = this.kind;\n switch (kind) {\n case 'N':\n return of(this.value);\n case 'E':\n return throwError(this.error);\n case 'C':\n return empty();\n }\n throw new Error('unexpected notification kind value');\n }\n static createNext(value) {\n if (typeof value !== 'undefined') {\n return new Notification('N', value);\n }\n return Notification.undefinedValueNotification;\n }\n static createError(err) {\n return new Notification('E', undefined, err);\n }\n static createComplete() {\n return Notification.completeNotification;\n }\n}\nNotification.completeNotification = new Notification('C');\nNotification.undefinedValueNotification = new Notification('N', undefined);\n","import { Subscriber } from '../Subscriber';\nimport { Notification } from '../Notification';\nexport function observeOn(scheduler, delay = 0) {\n return function observeOnOperatorFunction(source) {\n return source.lift(new ObserveOnOperator(scheduler, delay));\n };\n}\nexport class ObserveOnOperator {\n constructor(scheduler, delay = 0) {\n this.scheduler = scheduler;\n this.delay = delay;\n }\n call(subscriber, source) {\n return source.subscribe(new ObserveOnSubscriber(subscriber, this.scheduler, this.delay));\n }\n}\nexport class ObserveOnSubscriber extends Subscriber {\n constructor(destination, scheduler, delay = 0) {\n super(destination);\n this.scheduler = scheduler;\n this.delay = delay;\n }\n static dispatch(arg) {\n const {\n notification,\n destination\n } = arg;\n notification.observe(destination);\n this.unsubscribe();\n }\n scheduleMessage(notification) {\n const destination = this.destination;\n destination.add(this.scheduler.schedule(ObserveOnSubscriber.dispatch, this.delay, new ObserveOnMessage(notification, this.destination)));\n }\n _next(value) {\n this.scheduleMessage(Notification.createNext(value));\n }\n _error(err) {\n this.scheduleMessage(Notification.createError(err));\n this.unsubscribe();\n }\n _complete() {\n this.scheduleMessage(Notification.createComplete());\n this.unsubscribe();\n }\n}\nexport class ObserveOnMessage {\n constructor(notification, destination) {\n this.notification = notification;\n this.destination = destination;\n }\n}\n","import { Subject } from './Subject';\nimport { queue } from './scheduler/queue';\nimport { Subscription } from './Subscription';\nimport { ObserveOnSubscriber } from './operators/observeOn';\nimport { ObjectUnsubscribedError } from './util/ObjectUnsubscribedError';\nimport { SubjectSubscription } from './SubjectSubscription';\nexport class ReplaySubject extends Subject {\n constructor(bufferSize = Number.POSITIVE_INFINITY, windowTime = Number.POSITIVE_INFINITY, scheduler) {\n super();\n this.scheduler = scheduler;\n this._events = [];\n this._infiniteTimeWindow = false;\n this._bufferSize = bufferSize < 1 ? 1 : bufferSize;\n this._windowTime = windowTime < 1 ? 1 : windowTime;\n if (windowTime === Number.POSITIVE_INFINITY) {\n this._infiniteTimeWindow = true;\n this.next = this.nextInfiniteTimeWindow;\n } else {\n this.next = this.nextTimeWindow;\n }\n }\n nextInfiniteTimeWindow(value) {\n if (!this.isStopped) {\n const _events = this._events;\n _events.push(value);\n if (_events.length > this._bufferSize) {\n _events.shift();\n }\n }\n super.next(value);\n }\n nextTimeWindow(value) {\n if (!this.isStopped) {\n this._events.push(new ReplayEvent(this._getNow(), value));\n this._trimBufferThenGetEvents();\n }\n super.next(value);\n }\n _subscribe(subscriber) {\n const _infiniteTimeWindow = this._infiniteTimeWindow;\n const _events = _infiniteTimeWindow ? this._events : this._trimBufferThenGetEvents();\n const scheduler = this.scheduler;\n const len = _events.length;\n let subscription;\n if (this.closed) {\n throw new ObjectUnsubscribedError();\n } else if (this.isStopped || this.hasError) {\n subscription = Subscription.EMPTY;\n } else {\n this.observers.push(subscriber);\n subscription = new SubjectSubscription(this, subscriber);\n }\n if (scheduler) {\n subscriber.add(subscriber = new ObserveOnSubscriber(subscriber, scheduler));\n }\n if (_infiniteTimeWindow) {\n for (let i = 0; i < len && !subscriber.closed; i++) {\n subscriber.next(_events[i]);\n }\n } else {\n for (let i = 0; i < len && !subscriber.closed; i++) {\n subscriber.next(_events[i].value);\n }\n }\n if (this.hasError) {\n subscriber.error(this.thrownError);\n } else if (this.isStopped) {\n subscriber.complete();\n }\n return subscription;\n }\n _getNow() {\n return (this.scheduler || queue).now();\n }\n _trimBufferThenGetEvents() {\n const now = this._getNow();\n const _bufferSize = this._bufferSize;\n const _windowTime = this._windowTime;\n const _events = this._events;\n const eventsCount = _events.length;\n let spliceCount = 0;\n while (spliceCount < eventsCount) {\n if (now - _events[spliceCount].time < _windowTime) {\n break;\n }\n spliceCount++;\n }\n if (eventsCount > _bufferSize) {\n spliceCount = Math.max(spliceCount, eventsCount - _bufferSize);\n }\n if (spliceCount > 0) {\n _events.splice(0, spliceCount);\n }\n return _events;\n }\n}\nclass ReplayEvent {\n constructor(time, value) {\n this.time = time;\n this.value = value;\n }\n}\n","import { AsyncAction } from './AsyncAction';\nimport { AsyncScheduler } from './AsyncScheduler';\nexport const asyncScheduler = new AsyncScheduler(AsyncAction);\nexport const async = asyncScheduler;\n","export function noop() {}\n","import { Observable } from '../Observable';\nexport function isObservable(obj) {\n return !!obj && (obj instanceof Observable || typeof obj.lift === 'function' && typeof obj.subscribe === 'function');\n}\n","const ArgumentOutOfRangeErrorImpl = (() => {\n function ArgumentOutOfRangeErrorImpl() {\n Error.call(this);\n this.message = 'argument out of range';\n this.name = 'ArgumentOutOfRangeError';\n return this;\n }\n ArgumentOutOfRangeErrorImpl.prototype = Object.create(Error.prototype);\n return ArgumentOutOfRangeErrorImpl;\n})();\nexport const ArgumentOutOfRangeError = ArgumentOutOfRangeErrorImpl;\n","const EmptyErrorImpl = (() => {\n function EmptyErrorImpl() {\n Error.call(this);\n this.message = 'no elements in sequence';\n this.name = 'EmptyError';\n return this;\n }\n EmptyErrorImpl.prototype = Object.create(Error.prototype);\n return EmptyErrorImpl;\n})();\nexport const EmptyError = EmptyErrorImpl;\n","import { Subscriber } from '../Subscriber';\nexport function map(project, thisArg) {\n return function mapOperation(source) {\n if (typeof project !== 'function') {\n throw new TypeError('argument is not a function. Are you looking for `mapTo()`?');\n }\n return source.lift(new MapOperator(project, thisArg));\n };\n}\nexport class MapOperator {\n constructor(project, thisArg) {\n this.project = project;\n this.thisArg = thisArg;\n }\n call(subscriber, source) {\n return source.subscribe(new MapSubscriber(subscriber, this.project, this.thisArg));\n }\n}\nclass MapSubscriber extends Subscriber {\n constructor(destination, project, thisArg) {\n super(destination);\n this.project = project;\n this.count = 0;\n this.thisArg = thisArg || this;\n }\n _next(value) {\n let result;\n try {\n result = this.project.call(this.thisArg, value, this.count++);\n } catch (err) {\n this.destination.error(err);\n return;\n }\n this.destination.next(result);\n }\n}\n","import { Subscriber } from './Subscriber';\nexport class OuterSubscriber extends Subscriber {\n notifyNext(outerValue, innerValue, outerIndex, innerIndex, innerSub) {\n this.destination.next(innerValue);\n }\n notifyError(error, innerSub) {\n this.destination.error(error);\n }\n notifyComplete(innerSub) {\n this.destination.complete();\n }\n}\n","import { Subscriber } from './Subscriber';\nexport class InnerSubscriber extends Subscriber {\n constructor(parent, outerValue, outerIndex) {\n super();\n this.parent = parent;\n this.outerValue = outerValue;\n this.outerIndex = outerIndex;\n this.index = 0;\n }\n _next(value) {\n this.parent.notifyNext(this.outerValue, value, this.outerIndex, this.index++, this);\n }\n _error(error) {\n this.parent.notifyError(error, this);\n this.unsubscribe();\n }\n _complete() {\n this.parent.notifyComplete(this);\n this.unsubscribe();\n }\n}\n","import { hostReportError } from './hostReportError';\nexport const subscribeToPromise = promise => subscriber => {\n promise.then(value => {\n if (!subscriber.closed) {\n subscriber.next(value);\n subscriber.complete();\n }\n }, err => subscriber.error(err)).then(null, hostReportError);\n return subscriber;\n};\n","export function getSymbolIterator() {\n if (typeof Symbol !== 'function' || !Symbol.iterator) {\n return '@@iterator';\n }\n return Symbol.iterator;\n}\nexport const iterator = getSymbolIterator();\nexport const $$iterator = iterator;\n","import { iterator as Symbol_iterator } from '../symbol/iterator';\nexport const subscribeToIterable = iterable => subscriber => {\n const iterator = iterable[Symbol_iterator]();\n do {\n let item;\n try {\n item = iterator.next();\n } catch (err) {\n subscriber.error(err);\n return subscriber;\n }\n if (item.done) {\n subscriber.complete();\n break;\n }\n subscriber.next(item.value);\n if (subscriber.closed) {\n break;\n }\n } while (true);\n if (typeof iterator.return === 'function') {\n subscriber.add(() => {\n if (iterator.return) {\n iterator.return();\n }\n });\n }\n return subscriber;\n};\n","import { observable as Symbol_observable } from '../symbol/observable';\nexport const subscribeToObservable = obj => subscriber => {\n const obs = obj[Symbol_observable]();\n if (typeof obs.subscribe !== 'function') {\n throw new TypeError('Provided object does not correctly implement Symbol.observable');\n } else {\n return obs.subscribe(subscriber);\n }\n};\n","export const isArrayLike = x => x && typeof x.length === 'number' && typeof x !== 'function';\n","export function isPromise(value) {\n return !!value && typeof value.subscribe !== 'function' && typeof value.then === 'function';\n}\n","import { subscribeToArray } from './subscribeToArray';\nimport { subscribeToPromise } from './subscribeToPromise';\nimport { subscribeToIterable } from './subscribeToIterable';\nimport { subscribeToObservable } from './subscribeToObservable';\nimport { isArrayLike } from './isArrayLike';\nimport { isPromise } from './isPromise';\nimport { isObject } from './isObject';\nimport { iterator as Symbol_iterator } from '../symbol/iterator';\nimport { observable as Symbol_observable } from '../symbol/observable';\nexport const subscribeTo = result => {\n if (!!result && typeof result[Symbol_observable] === 'function') {\n return subscribeToObservable(result);\n } else if (isArrayLike(result)) {\n return subscribeToArray(result);\n } else if (isPromise(result)) {\n return subscribeToPromise(result);\n } else if (!!result && typeof result[Symbol_iterator] === 'function') {\n return subscribeToIterable(result);\n } else {\n const value = isObject(result) ? 'an invalid object' : `'${result}'`;\n const msg = `You provided ${value} where a stream was expected.` + ' You can provide an Observable, Promise, Array, or Iterable.';\n throw new TypeError(msg);\n }\n};\n","import { InnerSubscriber } from '../InnerSubscriber';\nimport { subscribeTo } from './subscribeTo';\nimport { Observable } from '../Observable';\nexport function subscribeToResult(outerSubscriber, result, outerValue, outerIndex, innerSubscriber = new InnerSubscriber(outerSubscriber, outerValue, outerIndex)) {\n if (innerSubscriber.closed) {\n return undefined;\n }\n if (result instanceof Observable) {\n return result.subscribe(innerSubscriber);\n }\n return subscribeTo(result)(innerSubscriber);\n}\n","import { isScheduler } from '../util/isScheduler';\nimport { isArray } from '../util/isArray';\nimport { OuterSubscriber } from '../OuterSubscriber';\nimport { subscribeToResult } from '../util/subscribeToResult';\nimport { fromArray } from './fromArray';\nconst NONE = {};\nexport function combineLatest(...observables) {\n let resultSelector = undefined;\n let scheduler = undefined;\n if (isScheduler(observables[observables.length - 1])) {\n scheduler = observables.pop();\n }\n if (typeof observables[observables.length - 1] === 'function') {\n resultSelector = observables.pop();\n }\n if (observables.length === 1 && isArray(observables[0])) {\n observables = observables[0];\n }\n return fromArray(observables, scheduler).lift(new CombineLatestOperator(resultSelector));\n}\nexport class CombineLatestOperator {\n constructor(resultSelector) {\n this.resultSelector = resultSelector;\n }\n call(subscriber, source) {\n return source.subscribe(new CombineLatestSubscriber(subscriber, this.resultSelector));\n }\n}\nexport class CombineLatestSubscriber extends OuterSubscriber {\n constructor(destination, resultSelector) {\n super(destination);\n this.resultSelector = resultSelector;\n this.active = 0;\n this.values = [];\n this.observables = [];\n }\n _next(observable) {\n this.values.push(NONE);\n this.observables.push(observable);\n }\n _complete() {\n const observables = this.observables;\n const len = observables.length;\n if (len === 0) {\n this.destination.complete();\n } else {\n this.active = len;\n this.toRespond = len;\n for (let i = 0; i < len; i++) {\n const observable = observables[i];\n this.add(subscribeToResult(this, observable, undefined, i));\n }\n }\n }\n notifyComplete(unused) {\n if ((this.active -= 1) === 0) {\n this.destination.complete();\n }\n }\n notifyNext(_outerValue, innerValue, outerIndex) {\n const values = this.values;\n const oldVal = values[outerIndex];\n const toRespond = !this.toRespond ? 0 : oldVal === NONE ? --this.toRespond : this.toRespond;\n values[outerIndex] = innerValue;\n if (toRespond === 0) {\n if (this.resultSelector) {\n this._tryResultSelector(values);\n } else {\n this.destination.next(values.slice());\n }\n }\n }\n _tryResultSelector(values) {\n let result;\n try {\n result = this.resultSelector.apply(this, values);\n } catch (err) {\n this.destination.error(err);\n return;\n }\n this.destination.next(result);\n }\n}\n","import { Observable } from '../Observable';\nimport { Subscription } from '../Subscription';\nimport { observable as Symbol_observable } from '../symbol/observable';\nexport function scheduleObservable(input, scheduler) {\n return new Observable(subscriber => {\n const sub = new Subscription();\n sub.add(scheduler.schedule(() => {\n const observable = input[Symbol_observable]();\n sub.add(observable.subscribe({\n next(value) {\n sub.add(scheduler.schedule(() => subscriber.next(value)));\n },\n error(err) {\n sub.add(scheduler.schedule(() => subscriber.error(err)));\n },\n complete() {\n sub.add(scheduler.schedule(() => subscriber.complete()));\n }\n }));\n }));\n return sub;\n });\n}\n","import { Observable } from '../Observable';\nimport { Subscription } from '../Subscription';\nexport function schedulePromise(input, scheduler) {\n return new Observable(subscriber => {\n const sub = new Subscription();\n sub.add(scheduler.schedule(() => input.then(value => {\n sub.add(scheduler.schedule(() => {\n subscriber.next(value);\n sub.add(scheduler.schedule(() => subscriber.complete()));\n }));\n }, err => {\n sub.add(scheduler.schedule(() => subscriber.error(err)));\n })));\n return sub;\n });\n}\n","import { Observable } from '../Observable';\nimport { Subscription } from '../Subscription';\nimport { iterator as Symbol_iterator } from '../symbol/iterator';\nexport function scheduleIterable(input, scheduler) {\n if (!input) {\n throw new Error('Iterable cannot be null');\n }\n return new Observable(subscriber => {\n const sub = new Subscription();\n let iterator;\n sub.add(() => {\n if (iterator && typeof iterator.return === 'function') {\n iterator.return();\n }\n });\n sub.add(scheduler.schedule(() => {\n iterator = input[Symbol_iterator]();\n sub.add(scheduler.schedule(function () {\n if (subscriber.closed) {\n return;\n }\n let value;\n let done;\n try {\n const result = iterator.next();\n value = result.value;\n done = result.done;\n } catch (err) {\n subscriber.error(err);\n return;\n }\n if (done) {\n subscriber.complete();\n } else {\n subscriber.next(value);\n this.schedule();\n }\n }));\n }));\n return sub;\n });\n}\n","import { observable as Symbol_observable } from '../symbol/observable';\nexport function isInteropObservable(input) {\n return input && typeof input[Symbol_observable] === 'function';\n}\n","import { iterator as Symbol_iterator } from '../symbol/iterator';\nexport function isIterable(input) {\n return input && typeof input[Symbol_iterator] === 'function';\n}\n","import { scheduleObservable } from './scheduleObservable';\nimport { schedulePromise } from './schedulePromise';\nimport { scheduleArray } from './scheduleArray';\nimport { scheduleIterable } from './scheduleIterable';\nimport { isInteropObservable } from '../util/isInteropObservable';\nimport { isPromise } from '../util/isPromise';\nimport { isArrayLike } from '../util/isArrayLike';\nimport { isIterable } from '../util/isIterable';\nexport function scheduled(input, scheduler) {\n if (input != null) {\n if (isInteropObservable(input)) {\n return scheduleObservable(input, scheduler);\n } else if (isPromise(input)) {\n return schedulePromise(input, scheduler);\n } else if (isArrayLike(input)) {\n return scheduleArray(input, scheduler);\n } else if (isIterable(input) || typeof input === 'string') {\n return scheduleIterable(input, scheduler);\n }\n }\n throw new TypeError((input !== null && typeof input || input) + ' is not observable');\n}\n","import { Observable } from '../Observable';\nimport { subscribeTo } from '../util/subscribeTo';\nimport { scheduled } from '../scheduled/scheduled';\nexport function from(input, scheduler) {\n if (!scheduler) {\n if (input instanceof Observable) {\n return input;\n }\n return new Observable(subscribeTo(input));\n } else {\n return scheduled(input, scheduler);\n }\n}\n","import { Subscriber } from './Subscriber';\nimport { Observable } from './Observable';\nimport { subscribeTo } from './util/subscribeTo';\nexport class SimpleInnerSubscriber extends Subscriber {\n constructor(parent) {\n super();\n this.parent = parent;\n }\n _next(value) {\n this.parent.notifyNext(value);\n }\n _error(error) {\n this.parent.notifyError(error);\n this.unsubscribe();\n }\n _complete() {\n this.parent.notifyComplete();\n this.unsubscribe();\n }\n}\nexport class ComplexInnerSubscriber extends Subscriber {\n constructor(parent, outerValue, outerIndex) {\n super();\n this.parent = parent;\n this.outerValue = outerValue;\n this.outerIndex = outerIndex;\n }\n _next(value) {\n this.parent.notifyNext(this.outerValue, value, this.outerIndex, this);\n }\n _error(error) {\n this.parent.notifyError(error);\n this.unsubscribe();\n }\n _complete() {\n this.parent.notifyComplete(this);\n this.unsubscribe();\n }\n}\nexport class SimpleOuterSubscriber extends Subscriber {\n notifyNext(innerValue) {\n this.destination.next(innerValue);\n }\n notifyError(err) {\n this.destination.error(err);\n }\n notifyComplete() {\n this.destination.complete();\n }\n}\nexport class ComplexOuterSubscriber extends Subscriber {\n notifyNext(_outerValue, innerValue, _outerIndex, _innerSub) {\n this.destination.next(innerValue);\n }\n notifyError(error) {\n this.destination.error(error);\n }\n notifyComplete(_innerSub) {\n this.destination.complete();\n }\n}\nexport function innerSubscribe(result, innerSubscriber) {\n if (innerSubscriber.closed) {\n return undefined;\n }\n if (result instanceof Observable) {\n return result.subscribe(innerSubscriber);\n }\n let subscription;\n try {\n subscription = subscribeTo(result)(innerSubscriber);\n } catch (error) {\n innerSubscriber.error(error);\n }\n return subscription;\n}\n","import { map } from './map';\nimport { from } from '../observable/from';\nimport { SimpleOuterSubscriber, SimpleInnerSubscriber, innerSubscribe } from '../innerSubscribe';\nexport function mergeMap(project, resultSelector, concurrent = Number.POSITIVE_INFINITY) {\n if (typeof resultSelector === 'function') {\n return source => source.pipe(mergeMap((a, i) => from(project(a, i)).pipe(map((b, ii) => resultSelector(a, b, i, ii))), concurrent));\n } else if (typeof resultSelector === 'number') {\n concurrent = resultSelector;\n }\n return source => source.lift(new MergeMapOperator(project, concurrent));\n}\nexport class MergeMapOperator {\n constructor(project, concurrent = Number.POSITIVE_INFINITY) {\n this.project = project;\n this.concurrent = concurrent;\n }\n call(observer, source) {\n return source.subscribe(new MergeMapSubscriber(observer, this.project, this.concurrent));\n }\n}\nexport class MergeMapSubscriber extends SimpleOuterSubscriber {\n constructor(destination, project, concurrent = Number.POSITIVE_INFINITY) {\n super(destination);\n this.project = project;\n this.concurrent = concurrent;\n this.hasCompleted = false;\n this.buffer = [];\n this.active = 0;\n this.index = 0;\n }\n _next(value) {\n if (this.active < this.concurrent) {\n this._tryNext(value);\n } else {\n this.buffer.push(value);\n }\n }\n _tryNext(value) {\n let result;\n const index = this.index++;\n try {\n result = this.project(value, index);\n } catch (err) {\n this.destination.error(err);\n return;\n }\n this.active++;\n this._innerSub(result);\n }\n _innerSub(ish) {\n const innerSubscriber = new SimpleInnerSubscriber(this);\n const destination = this.destination;\n destination.add(innerSubscriber);\n const innerSubscription = innerSubscribe(ish, innerSubscriber);\n if (innerSubscription !== innerSubscriber) {\n destination.add(innerSubscription);\n }\n }\n _complete() {\n this.hasCompleted = true;\n if (this.active === 0 && this.buffer.length === 0) {\n this.destination.complete();\n }\n this.unsubscribe();\n }\n notifyNext(innerValue) {\n this.destination.next(innerValue);\n }\n notifyComplete() {\n const buffer = this.buffer;\n this.active--;\n if (buffer.length > 0) {\n this._next(buffer.shift());\n } else if (this.active === 0 && this.hasCompleted) {\n this.destination.complete();\n }\n }\n}\nexport const flatMap = mergeMap;\n","import { mergeMap } from './mergeMap';\nimport { identity } from '../util/identity';\nexport function mergeAll(concurrent = Number.POSITIVE_INFINITY) {\n return mergeMap(identity, concurrent);\n}\n","import { mergeAll } from './mergeAll';\nexport function concatAll() {\n return mergeAll(1);\n}\n","import { of } from './of';\nimport { concatAll } from '../operators/concatAll';\nexport function concat(...observables) {\n return concatAll()(of(...observables));\n}\n","import { Observable } from '../Observable';\nimport { from } from './from';\nimport { empty } from './empty';\nexport function defer(observableFactory) {\n return new Observable(subscriber => {\n let input;\n try {\n input = observableFactory();\n } catch (err) {\n subscriber.error(err);\n return undefined;\n }\n const source = input ? from(input) : empty();\n return source.subscribe(subscriber);\n });\n}\n","import { Observable } from '../Observable';\nimport { isArray } from '../util/isArray';\nimport { map } from '../operators/map';\nimport { isObject } from '../util/isObject';\nimport { from } from './from';\nexport function forkJoin(...sources) {\n if (sources.length === 1) {\n const first = sources[0];\n if (isArray(first)) {\n return forkJoinInternal(first, null);\n }\n if (isObject(first) && Object.getPrototypeOf(first) === Object.prototype) {\n const keys = Object.keys(first);\n return forkJoinInternal(keys.map(key => first[key]), keys);\n }\n }\n if (typeof sources[sources.length - 1] === 'function') {\n const resultSelector = sources.pop();\n sources = sources.length === 1 && isArray(sources[0]) ? sources[0] : sources;\n return forkJoinInternal(sources, null).pipe(map(args => resultSelector(...args)));\n }\n return forkJoinInternal(sources, null);\n}\nfunction forkJoinInternal(sources, keys) {\n return new Observable(subscriber => {\n const len = sources.length;\n if (len === 0) {\n subscriber.complete();\n return;\n }\n const values = new Array(len);\n let completed = 0;\n let emitted = 0;\n for (let i = 0; i < len; i++) {\n const source = from(sources[i]);\n let hasValue = false;\n subscriber.add(source.subscribe({\n next: value => {\n if (!hasValue) {\n hasValue = true;\n emitted++;\n }\n values[i] = value;\n },\n error: err => subscriber.error(err),\n complete: () => {\n completed++;\n if (completed === len || !hasValue) {\n if (emitted === len) {\n subscriber.next(keys ? keys.reduce((result, key, i) => (result[key] = values[i], result), {}) : values);\n }\n subscriber.complete();\n }\n }\n }));\n }\n });\n}\n","import { Subscriber } from '../Subscriber';\nexport function filter(predicate, thisArg) {\n return function filterOperatorFunction(source) {\n return source.lift(new FilterOperator(predicate, thisArg));\n };\n}\nclass FilterOperator {\n constructor(predicate, thisArg) {\n this.predicate = predicate;\n this.thisArg = thisArg;\n }\n call(subscriber, source) {\n return source.subscribe(new FilterSubscriber(subscriber, this.predicate, this.thisArg));\n }\n}\nclass FilterSubscriber extends Subscriber {\n constructor(destination, predicate, thisArg) {\n super(destination);\n this.predicate = predicate;\n this.thisArg = thisArg;\n this.count = 0;\n }\n _next(value) {\n let result;\n try {\n result = this.predicate.call(this.thisArg, value, this.count++);\n } catch (err) {\n this.destination.error(err);\n return;\n }\n if (result) {\n this.destination.next(value);\n }\n }\n}\n","import { SimpleOuterSubscriber, SimpleInnerSubscriber, innerSubscribe } from '../innerSubscribe';\nexport function catchError(selector) {\n return function catchErrorOperatorFunction(source) {\n const operator = new CatchOperator(selector);\n const caught = source.lift(operator);\n return operator.caught = caught;\n };\n}\nclass CatchOperator {\n constructor(selector) {\n this.selector = selector;\n }\n call(subscriber, source) {\n return source.subscribe(new CatchSubscriber(subscriber, this.selector, this.caught));\n }\n}\nclass CatchSubscriber extends SimpleOuterSubscriber {\n constructor(destination, selector, caught) {\n super(destination);\n this.selector = selector;\n this.caught = caught;\n }\n error(err) {\n if (!this.isStopped) {\n let result;\n try {\n result = this.selector(err, this.caught);\n } catch (err2) {\n super.error(err2);\n return;\n }\n this._unsubscribeAndRecycle();\n const innerSubscriber = new SimpleInnerSubscriber(this);\n this.add(innerSubscriber);\n const innerSubscription = innerSubscribe(result, innerSubscriber);\n if (innerSubscription !== innerSubscriber) {\n this.add(innerSubscription);\n }\n }\n }\n}\n","import { mergeMap } from './mergeMap';\nexport function concatMap(project, resultSelector) {\n return mergeMap(project, resultSelector, 1);\n}\n","import { Subscriber } from '../Subscriber';\nexport function defaultIfEmpty(defaultValue = null) {\n return source => source.lift(new DefaultIfEmptyOperator(defaultValue));\n}\nclass DefaultIfEmptyOperator {\n constructor(defaultValue) {\n this.defaultValue = defaultValue;\n }\n call(subscriber, source) {\n return source.subscribe(new DefaultIfEmptySubscriber(subscriber, this.defaultValue));\n }\n}\nclass DefaultIfEmptySubscriber extends Subscriber {\n constructor(destination, defaultValue) {\n super(destination);\n this.defaultValue = defaultValue;\n this.isEmpty = true;\n }\n _next(value) {\n this.isEmpty = false;\n this.destination.next(value);\n }\n _complete() {\n if (this.isEmpty) {\n this.destination.next(this.defaultValue);\n }\n this.destination.complete();\n }\n}\n","export function isDate(value) {\n return value instanceof Date && !isNaN(+value);\n}\n","import { async } from '../scheduler/async';\nimport { isDate } from '../util/isDate';\nimport { Subscriber } from '../Subscriber';\nimport { Notification } from '../Notification';\nexport function delay(delay, scheduler = async) {\n const absoluteDelay = isDate(delay);\n const delayFor = absoluteDelay ? +delay - scheduler.now() : Math.abs(delay);\n return source => source.lift(new DelayOperator(delayFor, scheduler));\n}\nclass DelayOperator {\n constructor(delay, scheduler) {\n this.delay = delay;\n this.scheduler = scheduler;\n }\n call(subscriber, source) {\n return source.subscribe(new DelaySubscriber(subscriber, this.delay, this.scheduler));\n }\n}\nclass DelaySubscriber extends Subscriber {\n constructor(destination, delay, scheduler) {\n super(destination);\n this.delay = delay;\n this.scheduler = scheduler;\n this.queue = [];\n this.active = false;\n this.errored = false;\n }\n static dispatch(state) {\n const source = state.source;\n const queue = source.queue;\n const scheduler = state.scheduler;\n const destination = state.destination;\n while (queue.length > 0 && queue[0].time - scheduler.now() <= 0) {\n queue.shift().notification.observe(destination);\n }\n if (queue.length > 0) {\n const delay = Math.max(0, queue[0].time - scheduler.now());\n this.schedule(state, delay);\n } else {\n this.unsubscribe();\n source.active = false;\n }\n }\n _schedule(scheduler) {\n this.active = true;\n const destination = this.destination;\n destination.add(scheduler.schedule(DelaySubscriber.dispatch, this.delay, {\n source: this,\n destination: this.destination,\n scheduler: scheduler\n }));\n }\n scheduleNotification(notification) {\n if (this.errored === true) {\n return;\n }\n const scheduler = this.scheduler;\n const message = new DelayMessage(scheduler.now() + this.delay, notification);\n this.queue.push(message);\n if (this.active === false) {\n this._schedule(scheduler);\n }\n }\n _next(value) {\n this.scheduleNotification(Notification.createNext(value));\n }\n _error(err) {\n this.errored = true;\n this.queue = [];\n this.destination.error(err);\n this.unsubscribe();\n }\n _complete() {\n this.scheduleNotification(Notification.createComplete());\n this.unsubscribe();\n }\n}\nclass DelayMessage {\n constructor(time, notification) {\n this.time = time;\n this.notification = notification;\n }\n}\n","import { EmptyError } from '../util/EmptyError';\nimport { Subscriber } from '../Subscriber';\nexport function throwIfEmpty(errorFactory = defaultErrorFactory) {\n return source => {\n return source.lift(new ThrowIfEmptyOperator(errorFactory));\n };\n}\nclass ThrowIfEmptyOperator {\n constructor(errorFactory) {\n this.errorFactory = errorFactory;\n }\n call(subscriber, source) {\n return source.subscribe(new ThrowIfEmptySubscriber(subscriber, this.errorFactory));\n }\n}\nclass ThrowIfEmptySubscriber extends Subscriber {\n constructor(destination, errorFactory) {\n super(destination);\n this.errorFactory = errorFactory;\n this.hasValue = false;\n }\n _next(value) {\n this.hasValue = true;\n this.destination.next(value);\n }\n _complete() {\n if (!this.hasValue) {\n let err;\n try {\n err = this.errorFactory();\n } catch (e) {\n err = e;\n }\n this.destination.error(err);\n } else {\n return this.destination.complete();\n }\n }\n}\nfunction defaultErrorFactory() {\n return new EmptyError();\n}\n","import { Subscriber } from '../Subscriber';\nimport { ArgumentOutOfRangeError } from '../util/ArgumentOutOfRangeError';\nimport { empty } from '../observable/empty';\nexport function take(count) {\n return source => {\n if (count === 0) {\n return empty();\n } else {\n return source.lift(new TakeOperator(count));\n }\n };\n}\nclass TakeOperator {\n constructor(total) {\n this.total = total;\n if (this.total < 0) {\n throw new ArgumentOutOfRangeError();\n }\n }\n call(subscriber, source) {\n return source.subscribe(new TakeSubscriber(subscriber, this.total));\n }\n}\nclass TakeSubscriber extends Subscriber {\n constructor(destination, total) {\n super(destination);\n this.total = total;\n this.count = 0;\n }\n _next(value) {\n const total = this.total;\n const count = ++this.count;\n if (count <= total) {\n this.destination.next(value);\n if (count === total) {\n this.destination.complete();\n this.unsubscribe();\n }\n }\n }\n}\n","import { Subscriber } from '../Subscriber';\nimport { Subscription } from '../Subscription';\nexport function finalize(callback) {\n return source => source.lift(new FinallyOperator(callback));\n}\nclass FinallyOperator {\n constructor(callback) {\n this.callback = callback;\n }\n call(subscriber, source) {\n return source.subscribe(new FinallySubscriber(subscriber, this.callback));\n }\n}\nclass FinallySubscriber extends Subscriber {\n constructor(destination, callback) {\n super(destination);\n this.add(new Subscription(callback));\n }\n}\n","import { EmptyError } from '../util/EmptyError';\nimport { filter } from './filter';\nimport { take } from './take';\nimport { defaultIfEmpty } from './defaultIfEmpty';\nimport { throwIfEmpty } from './throwIfEmpty';\nimport { identity } from '../util/identity';\nexport function first(predicate, defaultValue) {\n const hasDefaultValue = arguments.length >= 2;\n return source => source.pipe(predicate ? filter((v, i) => predicate(v, i, source)) : identity, take(1), hasDefaultValue ? defaultIfEmpty(defaultValue) : throwIfEmpty(() => new EmptyError()));\n}\n","import { Subscriber } from '../Subscriber';\nimport { ArgumentOutOfRangeError } from '../util/ArgumentOutOfRangeError';\nimport { empty } from '../observable/empty';\nexport function takeLast(count) {\n return function takeLastOperatorFunction(source) {\n if (count === 0) {\n return empty();\n } else {\n return source.lift(new TakeLastOperator(count));\n }\n };\n}\nclass TakeLastOperator {\n constructor(total) {\n this.total = total;\n if (this.total < 0) {\n throw new ArgumentOutOfRangeError();\n }\n }\n call(subscriber, source) {\n return source.subscribe(new TakeLastSubscriber(subscriber, this.total));\n }\n}\nclass TakeLastSubscriber extends Subscriber {\n constructor(destination, total) {\n super(destination);\n this.total = total;\n this.ring = new Array();\n this.count = 0;\n }\n _next(value) {\n const ring = this.ring;\n const total = this.total;\n const count = this.count++;\n if (ring.length < total) {\n ring.push(value);\n } else {\n const index = count % total;\n ring[index] = value;\n }\n }\n _complete() {\n const destination = this.destination;\n let count = this.count;\n if (count > 0) {\n const total = this.count >= this.total ? this.total : this.count;\n const ring = this.ring;\n for (let i = 0; i < total; i++) {\n const idx = count++ % total;\n destination.next(ring[idx]);\n }\n }\n destination.complete();\n }\n}\n","import { EmptyError } from '../util/EmptyError';\nimport { filter } from './filter';\nimport { takeLast } from './takeLast';\nimport { throwIfEmpty } from './throwIfEmpty';\nimport { defaultIfEmpty } from './defaultIfEmpty';\nimport { identity } from '../util/identity';\nexport function last(predicate, defaultValue) {\n const hasDefaultValue = arguments.length >= 2;\n return source => source.pipe(predicate ? filter((v, i) => predicate(v, i, source)) : identity, takeLast(1), hasDefaultValue ? defaultIfEmpty(defaultValue) : throwIfEmpty(() => new EmptyError()));\n}\n","import { Subscriber } from '../Subscriber';\nexport function scan(accumulator, seed) {\n let hasSeed = false;\n if (arguments.length >= 2) {\n hasSeed = true;\n }\n return function scanOperatorFunction(source) {\n return source.lift(new ScanOperator(accumulator, seed, hasSeed));\n };\n}\nclass ScanOperator {\n constructor(accumulator, seed, hasSeed = false) {\n this.accumulator = accumulator;\n this.seed = seed;\n this.hasSeed = hasSeed;\n }\n call(subscriber, source) {\n return source.subscribe(new ScanSubscriber(subscriber, this.accumulator, this.seed, this.hasSeed));\n }\n}\nclass ScanSubscriber extends Subscriber {\n constructor(destination, accumulator, _seed, hasSeed) {\n super(destination);\n this.accumulator = accumulator;\n this._seed = _seed;\n this.hasSeed = hasSeed;\n this.index = 0;\n }\n get seed() {\n return this._seed;\n }\n set seed(value) {\n this.hasSeed = true;\n this._seed = value;\n }\n _next(value) {\n if (!this.hasSeed) {\n this.seed = value;\n this.destination.next(value);\n } else {\n return this._tryNext(value);\n }\n }\n _tryNext(value) {\n const index = this.index++;\n let result;\n try {\n result = this.accumulator(this.seed, value, index);\n } catch (err) {\n this.destination.error(err);\n }\n this.seed = result;\n this.destination.next(result);\n }\n}\n","import { ReplaySubject } from '../ReplaySubject';\nexport function shareReplay(configOrBufferSize, windowTime, scheduler) {\n let config;\n if (configOrBufferSize && typeof configOrBufferSize === 'object') {\n config = configOrBufferSize;\n } else {\n config = {\n bufferSize: configOrBufferSize,\n windowTime,\n refCount: false,\n scheduler\n };\n }\n return source => source.lift(shareReplayOperator(config));\n}\nfunction shareReplayOperator({\n bufferSize = Number.POSITIVE_INFINITY,\n windowTime = Number.POSITIVE_INFINITY,\n refCount: useRefCount,\n scheduler\n}) {\n let subject;\n let refCount = 0;\n let subscription;\n let hasError = false;\n let isComplete = false;\n return function shareReplayOperation(source) {\n refCount++;\n let innerSub;\n if (!subject || hasError) {\n hasError = false;\n subject = new ReplaySubject(bufferSize, windowTime, scheduler);\n innerSub = subject.subscribe(this);\n subscription = source.subscribe({\n next(value) {\n subject.next(value);\n },\n error(err) {\n hasError = true;\n subject.error(err);\n },\n complete() {\n isComplete = true;\n subscription = undefined;\n subject.complete();\n }\n });\n if (isComplete) {\n subscription = undefined;\n }\n } else {\n innerSub = subject.subscribe(this);\n }\n this.add(() => {\n refCount--;\n innerSub.unsubscribe();\n innerSub = undefined;\n if (subscription && !isComplete && useRefCount && refCount === 0) {\n subscription.unsubscribe();\n subscription = undefined;\n subject = undefined;\n }\n });\n };\n}\n","import { concat } from '../observable/concat';\nimport { isScheduler } from '../util/isScheduler';\nexport function startWith(...array) {\n const scheduler = array[array.length - 1];\n if (isScheduler(scheduler)) {\n array.pop();\n return source => concat(array, source, scheduler);\n } else {\n return source => concat(array, source);\n }\n}\n","import { map } from './map';\nimport { from } from '../observable/from';\nimport { SimpleOuterSubscriber, SimpleInnerSubscriber, innerSubscribe } from '../innerSubscribe';\nexport function switchMap(project, resultSelector) {\n if (typeof resultSelector === 'function') {\n return source => source.pipe(switchMap((a, i) => from(project(a, i)).pipe(map((b, ii) => resultSelector(a, b, i, ii)))));\n }\n return source => source.lift(new SwitchMapOperator(project));\n}\nclass SwitchMapOperator {\n constructor(project) {\n this.project = project;\n }\n call(subscriber, source) {\n return source.subscribe(new SwitchMapSubscriber(subscriber, this.project));\n }\n}\nclass SwitchMapSubscriber extends SimpleOuterSubscriber {\n constructor(destination, project) {\n super(destination);\n this.project = project;\n this.index = 0;\n }\n _next(value) {\n let result;\n const index = this.index++;\n try {\n result = this.project(value, index);\n } catch (error) {\n this.destination.error(error);\n return;\n }\n this._innerSub(result);\n }\n _innerSub(result) {\n const innerSubscription = this.innerSubscription;\n if (innerSubscription) {\n innerSubscription.unsubscribe();\n }\n const innerSubscriber = new SimpleInnerSubscriber(this);\n const destination = this.destination;\n destination.add(innerSubscriber);\n this.innerSubscription = innerSubscribe(result, innerSubscriber);\n if (this.innerSubscription !== innerSubscriber) {\n destination.add(this.innerSubscription);\n }\n }\n _complete() {\n const {\n innerSubscription\n } = this;\n if (!innerSubscription || innerSubscription.closed) {\n super._complete();\n }\n this.unsubscribe();\n }\n _unsubscribe() {\n this.innerSubscription = undefined;\n }\n notifyComplete() {\n this.innerSubscription = undefined;\n if (this.isStopped) {\n super._complete();\n }\n }\n notifyNext(innerValue) {\n this.destination.next(innerValue);\n }\n}\n","import { innerSubscribe, SimpleInnerSubscriber, SimpleOuterSubscriber } from '../innerSubscribe';\nexport function takeUntil(notifier) {\n return source => source.lift(new TakeUntilOperator(notifier));\n}\nclass TakeUntilOperator {\n constructor(notifier) {\n this.notifier = notifier;\n }\n call(subscriber, source) {\n const takeUntilSubscriber = new TakeUntilSubscriber(subscriber);\n const notifierSubscription = innerSubscribe(this.notifier, new SimpleInnerSubscriber(takeUntilSubscriber));\n if (notifierSubscription && !takeUntilSubscriber.seenValue) {\n takeUntilSubscriber.add(notifierSubscription);\n return source.subscribe(takeUntilSubscriber);\n }\n return takeUntilSubscriber;\n }\n}\nclass TakeUntilSubscriber extends SimpleOuterSubscriber {\n constructor(destination) {\n super(destination);\n this.seenValue = false;\n }\n notifyNext() {\n this.seenValue = true;\n this.complete();\n }\n notifyComplete() {}\n}\n","import { Subscriber } from '../Subscriber';\nimport { noop } from '../util/noop';\nimport { isFunction } from '../util/isFunction';\nexport function tap(nextOrObserver, error, complete) {\n return function tapOperatorFunction(source) {\n return source.lift(new DoOperator(nextOrObserver, error, complete));\n };\n}\nclass DoOperator {\n constructor(nextOrObserver, error, complete) {\n this.nextOrObserver = nextOrObserver;\n this.error = error;\n this.complete = complete;\n }\n call(subscriber, source) {\n return source.subscribe(new TapSubscriber(subscriber, this.nextOrObserver, this.error, this.complete));\n }\n}\nclass TapSubscriber extends Subscriber {\n constructor(destination, observerOrNext, error, complete) {\n super(destination);\n this._tapNext = noop;\n this._tapError = noop;\n this._tapComplete = noop;\n this._tapError = error || noop;\n this._tapComplete = complete || noop;\n if (isFunction(observerOrNext)) {\n this._context = this;\n this._tapNext = observerOrNext;\n } else if (observerOrNext) {\n this._context = observerOrNext;\n this._tapNext = observerOrNext.next || noop;\n this._tapError = observerOrNext.error || noop;\n this._tapComplete = observerOrNext.complete || noop;\n }\n }\n _next(value) {\n try {\n this._tapNext.call(this._context, value);\n } catch (err) {\n this.destination.error(err);\n return;\n }\n this.destination.next(value);\n }\n _error(err) {\n try {\n this._tapError.call(this._context, err);\n } catch (err) {\n this.destination.error(err);\n return;\n }\n this.destination.error(err);\n }\n _complete() {\n try {\n this._tapComplete.call(this._context);\n } catch (err) {\n this.destination.error(err);\n return;\n }\n return this.destination.complete();\n }\n}\n","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\nimport { SIGNAL_NODE as SIGNAL_NODE$1, signalSetFn as signalSetFn$1, producerAccessed as producerAccessed$1, SIGNAL as SIGNAL$1, getActiveConsumer as getActiveConsumer$1, setActiveConsumer as setActiveConsumer$1, createSignal as createSignal$1, signalUpdateFn as signalUpdateFn$1, consumerDestroy as consumerDestroy$1, REACTIVE_NODE as REACTIVE_NODE$1, consumerBeforeComputation as consumerBeforeComputation$1, consumerAfterComputation as consumerAfterComputation$1, consumerPollProducersForChange as consumerPollProducersForChange$1, createComputed as createComputed$1, setThrowInvalidWriteToSignalError as setThrowInvalidWriteToSignalError$1, createWatch as createWatch$1, isInNotificationPhase as isInNotificationPhase$1, createLinkedSignal as createLinkedSignal$1, linkedSignalSetFn as linkedSignalSetFn$1, linkedSignalUpdateFn as linkedSignalUpdateFn$1 } from '@angular/core/primitives/signals';\nexport { SIGNAL as ɵSIGNAL } from '@angular/core/primitives/signals';\nimport * as di from '@angular/core/primitives/di';\nimport { BehaviorSubject, Subject, Subscription } from 'rxjs';\nimport { Attribute as Attribute$1, clearAppScopedEarlyEventContract, EventContract, EventContractContainer, getAppScopedQueuedEventInfos, EventDispatcher, registerDispatcher, isEarlyEventType, isCaptureEventType, EventPhase } from '@angular/core/primitives/event-dispatch';\nimport { map } from 'rxjs/operators';\n\n/**\n * Base URL for the error details page.\n *\n * Keep this constant in sync across:\n * - packages/compiler-cli/src/ngtsc/diagnostics/src/error_details_base_url.ts\n * - packages/core/src/error_details_base_url.ts\n */\nconst ERROR_DETAILS_PAGE_BASE_URL = 'https://angular.dev/errors';\n/**\n * URL for the XSS security documentation.\n */\nconst XSS_SECURITY_URL = 'https://g.co/ng/security#xss';\n\n/**\n * Class that represents a runtime error.\n * Formats and outputs the error message in a consistent way.\n *\n * Example:\n * ```ts\n * throw new RuntimeError(\n * RuntimeErrorCode.INJECTOR_ALREADY_DESTROYED,\n * ngDevMode && 'Injector has already been destroyed.');\n * ```\n *\n * Note: the `message` argument contains a descriptive error message as a string in development\n * mode (when the `ngDevMode` is defined). In production mode (after tree-shaking pass), the\n * `message` argument becomes `false`, thus we account for it in the typings and the runtime\n * logic.\n */\nclass RuntimeError extends Error {\n code;\n constructor(code, message) {\n super(formatRuntimeError(code, message));\n this.code = code;\n }\n}\n/**\n * Called to format a runtime error.\n * See additional info on the `message` argument type in the `RuntimeError` class description.\n */\nfunction formatRuntimeError(code, message) {\n // Error code might be a negative number, which is a special marker that instructs the logic to\n // generate a link to the error details page on angular.io.\n // We also prepend `0` to non-compile-time errors.\n const fullCode = `NG0${Math.abs(code)}`;\n let errorMessage = `${fullCode}${message ? ': ' + message : ''}`;\n if (ngDevMode && code < 0) {\n const addPeriodSeparator = !errorMessage.match(/[.,;!?\\n]$/);\n const separator = addPeriodSeparator ? '.' : '';\n errorMessage = `${errorMessage}${separator} Find more at ${ERROR_DETAILS_PAGE_BASE_URL}/${fullCode}`;\n }\n return errorMessage;\n}\nconst REQUIRED_UNSET_VALUE = /* @__PURE__ */Symbol('InputSignalNode#UNSET');\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `COMPUTED_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst INPUT_SIGNAL_NODE = /* @__PURE__ */(() => {\n return {\n ...SIGNAL_NODE$1,\n transformFn: undefined,\n applyValueToInputSignal(node, value) {\n signalSetFn$1(node, value);\n }\n };\n})();\nconst ɵINPUT_SIGNAL_BRAND_READ_TYPE = /* @__PURE__ */Symbol();\nconst ɵINPUT_SIGNAL_BRAND_WRITE_TYPE = /* @__PURE__ */Symbol();\n/**\n * Creates an input signal.\n *\n * @param initialValue The initial value.\n * Can be set to {@link REQUIRED_UNSET_VALUE} for required inputs.\n * @param options Additional options for the input. e.g. a transform, or an alias.\n */\nfunction createInputSignal(initialValue, options) {\n const node = Object.create(INPUT_SIGNAL_NODE);\n node.value = initialValue;\n // Perf note: Always set `transformFn` here to ensure that `node` always\n // has the same v8 class shape, allowing monomorphic reads on input signals.\n node.transformFn = options?.transform;\n function inputValueFn() {\n // Record that someone looked at this signal.\n producerAccessed$1(node);\n if (node.value === REQUIRED_UNSET_VALUE) {\n throw new RuntimeError(-950 /* RuntimeErrorCode.REQUIRED_INPUT_NO_VALUE */, ngDevMode && 'Input is required but no value is available yet.');\n }\n return node.value;\n }\n inputValueFn[SIGNAL$1] = node;\n if (ngDevMode) {\n inputValueFn.toString = () => `[Input Signal: ${inputValueFn()}]`;\n node.debugName = options?.debugName;\n }\n return inputValueFn;\n}\n\n/**\n * Convince closure compiler that the wrapped function has no side-effects.\n *\n * Closure compiler always assumes that `toString` has no side-effects. We use this quirk to\n * allow us to execute a function but have closure compiler mark the call as no-side-effects.\n * It is important that the return value for the `noSideEffects` function be assigned\n * to something which is retained otherwise the call to `noSideEffects` will be removed by closure\n * compiler.\n */\nfunction noSideEffects(fn) {\n return {\n toString: fn\n }.toString();\n}\nconst ANNOTATIONS = '__annotations__';\nconst PARAMETERS = '__parameters__';\nconst PROP_METADATA = '__prop__metadata__';\n/**\n * @suppress {globalThis}\n */\nfunction makeDecorator(name, props, parentClass, additionalProcessing, typeFn) {\n return noSideEffects(() => {\n const metaCtor = makeMetadataCtor(props);\n function DecoratorFactory(...args) {\n if (this instanceof DecoratorFactory) {\n metaCtor.call(this, ...args);\n return this;\n }\n const annotationInstance = new DecoratorFactory(...args);\n return function TypeDecorator(cls) {\n if (typeFn) typeFn(cls, ...args);\n // Use of Object.defineProperty is important since it creates non-enumerable property which\n // prevents the property is copied during subclassing.\n const annotations = cls.hasOwnProperty(ANNOTATIONS) ? cls[ANNOTATIONS] : Object.defineProperty(cls, ANNOTATIONS, {\n value: []\n })[ANNOTATIONS];\n annotations.push(annotationInstance);\n if (additionalProcessing) additionalProcessing(cls);\n return cls;\n };\n }\n if (parentClass) {\n DecoratorFactory.prototype = Object.create(parentClass.prototype);\n }\n DecoratorFactory.prototype.ngMetadataName = name;\n DecoratorFactory.annotationCls = DecoratorFactory;\n return DecoratorFactory;\n });\n}\nfunction makeMetadataCtor(props) {\n return function ctor(...args) {\n if (props) {\n const values = props(...args);\n for (const propName in values) {\n this[propName] = values[propName];\n }\n }\n };\n}\nfunction makeParamDecorator(name, props, parentClass) {\n return noSideEffects(() => {\n const metaCtor = makeMetadataCtor(props);\n function ParamDecoratorFactory(...args) {\n if (this instanceof ParamDecoratorFactory) {\n metaCtor.apply(this, args);\n return this;\n }\n const annotationInstance = new ParamDecoratorFactory(...args);\n ParamDecorator.annotation = annotationInstance;\n return ParamDecorator;\n function ParamDecorator(cls, unusedKey, index) {\n // Use of Object.defineProperty is important since it creates non-enumerable property which\n // prevents the property is copied during subclassing.\n const parameters = cls.hasOwnProperty(PARAMETERS) ? cls[PARAMETERS] : Object.defineProperty(cls, PARAMETERS, {\n value: []\n })[PARAMETERS];\n // there might be gaps if some in between parameters do not have annotations.\n // we pad with nulls.\n while (parameters.length <= index) {\n parameters.push(null);\n }\n (parameters[index] = parameters[index] || []).push(annotationInstance);\n return cls;\n }\n }\n if (parentClass) {\n ParamDecoratorFactory.prototype = Object.create(parentClass.prototype);\n }\n ParamDecoratorFactory.prototype.ngMetadataName = name;\n ParamDecoratorFactory.annotationCls = ParamDecoratorFactory;\n return ParamDecoratorFactory;\n });\n}\nfunction makePropDecorator(name, props, parentClass, additionalProcessing) {\n return noSideEffects(() => {\n const metaCtor = makeMetadataCtor(props);\n function PropDecoratorFactory(...args) {\n if (this instanceof PropDecoratorFactory) {\n metaCtor.apply(this, args);\n return this;\n }\n const decoratorInstance = new PropDecoratorFactory(...args);\n function PropDecorator(target, name) {\n // target is undefined with standard decorators. This case is not supported and will throw\n // if this decorator is used in JIT mode with standard decorators.\n if (target === undefined) {\n throw new Error('Standard Angular field decorators are not supported in JIT mode.');\n }\n const constructor = target.constructor;\n // Use of Object.defineProperty is important because it creates a non-enumerable property\n // which prevents the property from being copied during subclassing.\n const meta = constructor.hasOwnProperty(PROP_METADATA) ? constructor[PROP_METADATA] : Object.defineProperty(constructor, PROP_METADATA, {\n value: {}\n })[PROP_METADATA];\n meta[name] = meta.hasOwnProperty(name) && meta[name] || [];\n meta[name].unshift(decoratorInstance);\n if (additionalProcessing) additionalProcessing(target, name, ...args);\n }\n return PropDecorator;\n }\n if (parentClass) {\n PropDecoratorFactory.prototype = Object.create(parentClass.prototype);\n }\n PropDecoratorFactory.prototype.ngMetadataName = name;\n PropDecoratorFactory.annotationCls = PropDecoratorFactory;\n return PropDecoratorFactory;\n });\n}\nconst _global = globalThis;\nfunction ngDevModeResetPerfCounters() {\n const locationString = typeof location !== 'undefined' ? location.toString() : '';\n const newCounters = {\n namedConstructors: locationString.indexOf('ngDevMode=namedConstructors') != -1,\n firstCreatePass: 0,\n tNode: 0,\n tView: 0,\n rendererCreateTextNode: 0,\n rendererSetText: 0,\n rendererCreateElement: 0,\n rendererAddEventListener: 0,\n rendererSetAttribute: 0,\n rendererRemoveAttribute: 0,\n rendererSetProperty: 0,\n rendererSetClassName: 0,\n rendererAddClass: 0,\n rendererRemoveClass: 0,\n rendererSetStyle: 0,\n rendererRemoveStyle: 0,\n rendererDestroy: 0,\n rendererDestroyNode: 0,\n rendererMoveNode: 0,\n rendererRemoveNode: 0,\n rendererAppendChild: 0,\n rendererInsertBefore: 0,\n rendererCreateComment: 0,\n hydratedNodes: 0,\n hydratedComponents: 0,\n dehydratedViewsRemoved: 0,\n dehydratedViewsCleanupRuns: 0,\n componentsSkippedHydration: 0,\n deferBlocksWithIncrementalHydration: 0\n };\n // Make sure to refer to ngDevMode as ['ngDevMode'] for closure.\n const allowNgDevModeTrue = locationString.indexOf('ngDevMode=false') === -1;\n if (!allowNgDevModeTrue) {\n _global['ngDevMode'] = false;\n } else {\n if (typeof _global['ngDevMode'] !== 'object') {\n _global['ngDevMode'] = {};\n }\n Object.assign(_global['ngDevMode'], newCounters);\n }\n return newCounters;\n}\n/**\n * This function checks to see if the `ngDevMode` has been set. If yes,\n * then we honor it, otherwise we default to dev mode with additional checks.\n *\n * The idea is that unless we are doing production build where we explicitly\n * set `ngDevMode == false` we should be helping the developer by providing\n * as much early warning and errors as possible.\n *\n * `ɵɵdefineComponent` is guaranteed to have been called before any component template functions\n * (and thus Ivy instructions), so a single initialization there is sufficient to ensure ngDevMode\n * is defined for the entire instruction set.\n *\n * When checking `ngDevMode` on toplevel, always init it before referencing it\n * (e.g. `((typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode())`), otherwise you can\n * get a `ReferenceError` like in https://github.com/angular/angular/issues/31595.\n *\n * Details on possible values for `ngDevMode` can be found on its docstring.\n *\n * NOTE:\n * - changes to the `ngDevMode` name must be synced with `compiler-cli/src/tooling.ts`.\n */\nfunction initNgDevMode() {\n // The below checks are to ensure that calling `initNgDevMode` multiple times does not\n // reset the counters.\n // If the `ngDevMode` is not an object, then it means we have not created the perf counters\n // yet.\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (typeof ngDevMode !== 'object' || Object.keys(ngDevMode).length === 0) {\n ngDevModeResetPerfCounters();\n }\n return typeof ngDevMode !== 'undefined' && !!ngDevMode;\n }\n return false;\n}\nfunction getClosureSafeProperty(objWithPropertyToExtract) {\n for (let key in objWithPropertyToExtract) {\n if (objWithPropertyToExtract[key] === getClosureSafeProperty) {\n return key;\n }\n }\n throw Error('Could not find renamed property on target object.');\n}\n/**\n * Sets properties on a target object from a source object, but only if\n * the property doesn't already exist on the target object.\n * @param target The target to set properties on\n * @param source The source of the property keys and values to set\n */\nfunction fillProperties(target, source) {\n for (const key in source) {\n if (source.hasOwnProperty(key) && !target.hasOwnProperty(key)) {\n target[key] = source[key];\n }\n }\n}\nfunction stringify(token) {\n if (typeof token === 'string') {\n return token;\n }\n if (Array.isArray(token)) {\n return `[${token.map(stringify).join(', ')}]`;\n }\n if (token == null) {\n return '' + token;\n }\n const name = token.overriddenName || token.name;\n if (name) {\n return `${name}`;\n }\n const result = token.toString();\n if (result == null) {\n return '' + result;\n }\n const newLineIndex = result.indexOf('\\n');\n return newLineIndex >= 0 ? result.slice(0, newLineIndex) : result;\n}\n/**\n * Concatenates two strings with separator, allocating new strings only when necessary.\n *\n * @param before before string.\n * @param separator separator string.\n * @param after after string.\n * @returns concatenated string.\n */\nfunction concatStringsWithSpace(before, after) {\n if (!before) return after || '';\n if (!after) return before;\n return `${before} ${after}`;\n}\n/**\n * Ellipses the string in the middle when longer than the max length\n *\n * @param string\n * @param maxLength of the output string\n * @returns ellipsed string with ... in the middle\n */\nfunction truncateMiddle(str, maxLength = 100) {\n if (!str || maxLength < 1 || str.length <= maxLength) return str;\n if (maxLength == 1) return str.substring(0, 1) + '...';\n const halfLimit = Math.round(maxLength / 2);\n return str.substring(0, halfLimit) + '...' + str.substring(str.length - halfLimit);\n}\nconst __forward_ref__ = getClosureSafeProperty({\n __forward_ref__: getClosureSafeProperty\n});\n/**\n * Allows to refer to references which are not yet defined.\n *\n * For instance, `forwardRef` is used when the `token` which we need to refer to for the purposes of\n * DI is declared, but not yet defined. It is also used when the `token` which we use when creating\n * a query is not yet defined.\n *\n * `forwardRef` is also used to break circularities in standalone components imports.\n *\n * @usageNotes\n * ### Circular dependency example\n * {@example core/di/ts/forward_ref/forward_ref_spec.ts region='forward_ref'}\n *\n * ### Circular standalone reference import example\n * ```angular-ts\n * @Component({\n * standalone: true,\n * imports: [ChildComponent],\n * selector: 'app-parent',\n * template: `<app-child [hideParent]=\"hideParent\"></app-child>`,\n * })\n * export class ParentComponent {\n * @Input() hideParent: boolean;\n * }\n *\n *\n * @Component({\n * standalone: true,\n * imports: [CommonModule, forwardRef(() => ParentComponent)],\n * selector: 'app-child',\n * template: `<app-parent *ngIf=\"!hideParent\"></app-parent>`,\n * })\n * export class ChildComponent {\n * @Input() hideParent: boolean;\n * }\n * ```\n *\n * @publicApi\n */\nfunction forwardRef(forwardRefFn) {\n forwardRefFn.__forward_ref__ = forwardRef;\n forwardRefFn.toString = function () {\n return stringify(this());\n };\n return forwardRefFn;\n}\n/**\n * Lazily retrieves the reference value from a forwardRef.\n *\n * Acts as the identity function when given a non-forward-ref value.\n *\n * @usageNotes\n * ### Example\n *\n * {@example core/di/ts/forward_ref/forward_ref_spec.ts region='resolve_forward_ref'}\n *\n * @see {@link forwardRef}\n * @publicApi\n */\nfunction resolveForwardRef(type) {\n return isForwardRef(type) ? type() : type;\n}\n/** Checks whether a function is wrapped by a `forwardRef`. */\nfunction isForwardRef(fn) {\n return typeof fn === 'function' && fn.hasOwnProperty(__forward_ref__) && fn.__forward_ref__ === forwardRef;\n}\n\n// The functions in this file verify that the assumptions we are making\nfunction assertNumber(actual, msg) {\n if (!(typeof actual === 'number')) {\n throwError(msg, typeof actual, 'number', '===');\n }\n}\nfunction assertNumberInRange(actual, minInclusive, maxInclusive) {\n assertNumber(actual, 'Expected a number');\n assertLessThanOrEqual(actual, maxInclusive, 'Expected number to be less than or equal to');\n assertGreaterThanOrEqual(actual, minInclusive, 'Expected number to be greater than or equal to');\n}\nfunction assertString(actual, msg) {\n if (!(typeof actual === 'string')) {\n throwError(msg, actual === null ? 'null' : typeof actual, 'string', '===');\n }\n}\nfunction assertFunction(actual, msg) {\n if (!(typeof actual === 'function')) {\n throwError(msg, actual === null ? 'null' : typeof actual, 'function', '===');\n }\n}\nfunction assertEqual(actual, expected, msg) {\n if (!(actual == expected)) {\n throwError(msg, actual, expected, '==');\n }\n}\nfunction assertNotEqual(actual, expected, msg) {\n if (!(actual != expected)) {\n throwError(msg, actual, expected, '!=');\n }\n}\nfunction assertSame(actual, expected, msg) {\n if (!(actual === expected)) {\n throwError(msg, actual, expected, '===');\n }\n}\nfunction assertNotSame(actual, expected, msg) {\n if (!(actual !== expected)) {\n throwError(msg, actual, expected, '!==');\n }\n}\nfunction assertLessThan(actual, expected, msg) {\n if (!(actual < expected)) {\n throwError(msg, actual, expected, '<');\n }\n}\nfunction assertLessThanOrEqual(actual, expected, msg) {\n if (!(actual <= expected)) {\n throwError(msg, actual, expected, '<=');\n }\n}\nfunction assertGreaterThan(actual, expected, msg) {\n if (!(actual > expected)) {\n throwError(msg, actual, expected, '>');\n }\n}\nfunction assertGreaterThanOrEqual(actual, expected, msg) {\n if (!(actual >= expected)) {\n throwError(msg, actual, expected, '>=');\n }\n}\nfunction assertNotDefined(actual, msg) {\n if (actual != null) {\n throwError(msg, actual, null, '==');\n }\n}\nfunction assertDefined(actual, msg) {\n if (actual == null) {\n throwError(msg, actual, null, '!=');\n }\n}\nfunction throwError(msg, actual, expected, comparison) {\n throw new Error(`ASSERTION ERROR: ${msg}` + (comparison == null ? '' : ` [Expected=> ${expected} ${comparison} ${actual} <=Actual]`));\n}\nfunction assertDomNode(node) {\n if (!(node instanceof Node)) {\n throwError(`The provided value must be an instance of a DOM Node but got ${stringify(node)}`);\n }\n}\nfunction assertElement(node) {\n if (!(node instanceof Element)) {\n throwError(`The provided value must be an element but got ${stringify(node)}`);\n }\n}\nfunction assertIndexInRange(arr, index) {\n assertDefined(arr, 'Array must be defined.');\n const maxLen = arr.length;\n if (index < 0 || index >= maxLen) {\n throwError(`Index expected to be less than ${maxLen} but got ${index}`);\n }\n}\nfunction assertOneOf(value, ...validValues) {\n if (validValues.indexOf(value) !== -1) return true;\n throwError(`Expected value to be one of ${JSON.stringify(validValues)} but was ${JSON.stringify(value)}.`);\n}\nfunction assertNotReactive(fn) {\n if (getActiveConsumer$1() !== null) {\n throwError(`${fn}() should never be called in a reactive context.`);\n }\n}\n\n/**\n * Construct an injectable definition which defines how a token will be constructed by the DI\n * system, and in which injectors (if any) it will be available.\n *\n * This should be assigned to a static `ɵprov` field on a type, which will then be an\n * `InjectableType`.\n *\n * Options:\n * * `providedIn` determines which injectors will include the injectable, by either associating it\n * with an `@NgModule` or other `InjectorType`, or by specifying that this injectable should be\n * provided in the `'root'` injector, which will be the application-level injector in most apps.\n * * `factory` gives the zero argument function which will create an instance of the injectable.\n * The factory can call [`inject`](api/core/inject) to access the `Injector` and request injection\n * of dependencies.\n *\n * @codeGenApi\n * @publicApi This instruction has been emitted by ViewEngine for some time and is deployed to npm.\n */\nfunction ɵɵdefineInjectable(opts) {\n return {\n token: opts.token,\n providedIn: opts.providedIn || null,\n factory: opts.factory,\n value: undefined\n };\n}\n/**\n * @deprecated in v8, delete after v10. This API should be used only by generated code, and that\n * code should now use ɵɵdefineInjectable instead.\n * @publicApi\n */\nconst defineInjectable = ɵɵdefineInjectable;\n/**\n * Construct an `InjectorDef` which configures an injector.\n *\n * This should be assigned to a static injector def (`ɵinj`) field on a type, which will then be an\n * `InjectorType`.\n *\n * Options:\n *\n * * `providers`: an optional array of providers to add to the injector. Each provider must\n * either have a factory or point to a type which has a `ɵprov` static property (the\n * type must be an `InjectableType`).\n * * `imports`: an optional array of imports of other `InjectorType`s or `InjectorTypeWithModule`s\n * whose providers will also be added to the injector. Locally provided types will override\n * providers from imports.\n *\n * @codeGenApi\n */\nfunction ɵɵdefineInjector(options) {\n return {\n providers: options.providers || [],\n imports: options.imports || []\n };\n}\n/**\n * Read the injectable def (`ɵprov`) for `type` in a way which is immune to accidentally reading\n * inherited value.\n *\n * @param type A type which may have its own (non-inherited) `ɵprov`.\n */\nfunction getInjectableDef(type) {\n return getOwnDefinition(type, NG_PROV_DEF) || getOwnDefinition(type, NG_INJECTABLE_DEF);\n}\nfunction isInjectable(type) {\n return getInjectableDef(type) !== null;\n}\n/**\n * Return definition only if it is defined directly on `type` and is not inherited from a base\n * class of `type`.\n */\nfunction getOwnDefinition(type, field) {\n return type.hasOwnProperty(field) ? type[field] : null;\n}\n/**\n * Read the injectable def (`ɵprov`) for `type` or read the `ɵprov` from one of its ancestors.\n *\n * @param type A type which may have `ɵprov`, via inheritance.\n *\n * @deprecated Will be removed in a future version of Angular, where an error will occur in the\n * scenario if we find the `ɵprov` on an ancestor only.\n */\nfunction getInheritedInjectableDef(type) {\n const def = type && (type[NG_PROV_DEF] || type[NG_INJECTABLE_DEF]);\n if (def) {\n ngDevMode && console.warn(`DEPRECATED: DI is instantiating a token \"${type.name}\" 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 \"${type.name}\" class.`);\n return def;\n } else {\n return null;\n }\n}\n/**\n * Read the injector def type in a way which is immune to accidentally reading inherited value.\n *\n * @param type type which may have an injector def (`ɵinj`)\n */\nfunction getInjectorDef(type) {\n return type && (type.hasOwnProperty(NG_INJ_DEF) || type.hasOwnProperty(NG_INJECTOR_DEF)) ? type[NG_INJ_DEF] : null;\n}\nconst NG_PROV_DEF = getClosureSafeProperty({\n ɵprov: getClosureSafeProperty\n});\nconst NG_INJ_DEF = getClosureSafeProperty({\n ɵinj: getClosureSafeProperty\n});\n// We need to keep these around so we can read off old defs if new defs are unavailable\nconst NG_INJECTABLE_DEF = getClosureSafeProperty({\n ngInjectableDef: getClosureSafeProperty\n});\nconst NG_INJECTOR_DEF = getClosureSafeProperty({\n ngInjectorDef: getClosureSafeProperty\n});\n\n/**\n * Creates a token that can be used in a DI Provider.\n *\n * Use an `InjectionToken` whenever the type you are injecting is not reified (does not have a\n * runtime representation) such as when injecting an interface, callable type, array or\n * parameterized type.\n *\n * `InjectionToken` is parameterized on `T` which is the type of object which will be returned by\n * the `Injector`. This provides an additional level of type safety.\n *\n * <div class=\"docs-alert docs-alert-helpful\">\n *\n * **Important Note**: Ensure that you use the same instance of the `InjectionToken` in both the\n * provider and the injection call. Creating a new instance of `InjectionToken` in different places,\n * even with the same description, will be treated as different tokens by Angular's DI system,\n * leading to a `NullInjectorError`.\n *\n * </div>\n *\n * {@example injection-token/src/main.ts region='InjectionToken'}\n *\n * When creating an `InjectionToken`, you can optionally specify a factory function which returns\n * (possibly by creating) a default value of the parameterized type `T`. This sets up the\n * `InjectionToken` using this factory as a provider as if it was defined explicitly in the\n * application's root injector. If the factory function, which takes zero arguments, needs to inject\n * dependencies, it can do so using the [`inject`](api/core/inject) function.\n * As you can see in the Tree-shakable InjectionToken example below.\n *\n * Additionally, if a `factory` is specified you can also specify the `providedIn` option, which\n * overrides the above behavior and marks the token as belonging to a particular `@NgModule` (note:\n * this option is now deprecated). As mentioned above, `'root'` is the default value for\n * `providedIn`.\n *\n * The `providedIn: NgModule` and `providedIn: 'any'` options are deprecated.\n *\n * @usageNotes\n * ### Basic Examples\n *\n * ### Plain InjectionToken\n *\n * {@example core/di/ts/injector_spec.ts region='InjectionToken'}\n *\n * ### Tree-shakable InjectionToken\n *\n * {@example core/di/ts/injector_spec.ts region='ShakableInjectionToken'}\n *\n * @publicApi\n */\nclass InjectionToken {\n _desc;\n /** @internal */\n ngMetadataName = 'InjectionToken';\n ɵprov;\n /**\n * @param _desc Description for the token,\n * used only for debugging purposes,\n * it should but does not need to be unique\n * @param options Options for the token's usage, as described above\n */\n constructor(_desc, options) {\n this._desc = _desc;\n this.ɵprov = undefined;\n if (typeof options == 'number') {\n (typeof ngDevMode === 'undefined' || ngDevMode) && assertLessThan(options, 0, 'Only negative numbers are supported here');\n // This is a special hack to assign __NG_ELEMENT_ID__ to this instance.\n // See `InjectorMarkers`\n this.__NG_ELEMENT_ID__ = options;\n } else if (options !== undefined) {\n this.ɵprov = ɵɵdefineInjectable({\n token: this,\n providedIn: options.providedIn || 'root',\n factory: options.factory\n });\n }\n }\n /**\n * @internal\n */\n get multi() {\n return this;\n }\n toString() {\n return `InjectionToken ${this._desc}`;\n }\n}\nlet _injectorProfilerContext;\nfunction getInjectorProfilerContext() {\n !ngDevMode && throwError('getInjectorProfilerContext should never be called in production mode');\n return _injectorProfilerContext;\n}\nfunction setInjectorProfilerContext(context) {\n !ngDevMode && throwError('setInjectorProfilerContext should never be called in production mode');\n const previous = _injectorProfilerContext;\n _injectorProfilerContext = context;\n return previous;\n}\nlet injectorProfilerCallback = null;\n/**\n * Sets the callback function which will be invoked during certain DI events within the\n * runtime (for example: injecting services, creating injectable instances, configuring providers)\n *\n * Warning: this function is *INTERNAL* and should not be relied upon in application's code.\n * The contract of the function might be changed in any release and/or the function can be removed\n * completely.\n *\n * @param profiler function provided by the caller or null value to disable profiling.\n */\nconst setInjectorProfiler = injectorProfiler => {\n !ngDevMode && throwError('setInjectorProfiler should never be called in production mode');\n injectorProfilerCallback = injectorProfiler;\n};\n/**\n * Injector profiler function which emits on DI events executed by the runtime.\n *\n * @param event InjectorProfilerEvent corresponding to the DI event being emitted\n */\nfunction injectorProfiler(event) {\n !ngDevMode && throwError('Injector profiler should never be called in production mode');\n if (injectorProfilerCallback != null /* both `null` and `undefined` */) {\n injectorProfilerCallback(event);\n }\n}\n/**\n * Emits an InjectorProfilerEventType.ProviderConfigured to the injector profiler. The data in the\n * emitted event includes the raw provider, as well as the token that provider is providing.\n *\n * @param eventProvider A provider object\n */\nfunction emitProviderConfiguredEvent(eventProvider, isViewProvider = false) {\n !ngDevMode && throwError('Injector profiler should never be called in production mode');\n let token;\n // if the provider is a TypeProvider (typeof provider is function) then the token is the\n // provider itself\n if (typeof eventProvider === 'function') {\n token = eventProvider;\n }\n // if the provider is an injection token, then the token is the injection token.\n else if (eventProvider instanceof InjectionToken) {\n token = eventProvider;\n }\n // in all other cases we can access the token via the `provide` property of the provider\n else {\n token = resolveForwardRef(eventProvider.provide);\n }\n let provider = eventProvider;\n // Injection tokens may define their own default provider which gets attached to the token itself\n // as `ɵprov`. In this case, we want to emit the provider that is attached to the token, not the\n // token itself.\n if (eventProvider instanceof InjectionToken) {\n provider = eventProvider.ɵprov || eventProvider;\n }\n injectorProfiler({\n type: 2 /* InjectorProfilerEventType.ProviderConfigured */,\n context: getInjectorProfilerContext(),\n providerRecord: {\n token,\n provider,\n isViewProvider\n }\n });\n}\n/**\n * Emits an event to the injector profiler with the instance that was created. Note that\n * the injector associated with this emission can be accessed by using getDebugInjectContext()\n *\n * @param instance an object created by an injector\n */\nfunction emitInstanceCreatedByInjectorEvent(instance) {\n !ngDevMode && throwError('Injector profiler should never be called in production mode');\n injectorProfiler({\n type: 1 /* InjectorProfilerEventType.InstanceCreatedByInjector */,\n context: getInjectorProfilerContext(),\n instance: {\n value: instance\n }\n });\n}\n/**\n * @param token DI token associated with injected service\n * @param value the instance of the injected service (i.e the result of `inject(token)`)\n * @param flags the flags that the token was injected with\n */\nfunction emitInjectEvent(token, value, flags) {\n !ngDevMode && throwError('Injector profiler should never be called in production mode');\n injectorProfiler({\n type: 0 /* InjectorProfilerEventType.Inject */,\n context: getInjectorProfilerContext(),\n service: {\n token,\n value,\n flags\n }\n });\n}\nfunction emitEffectCreatedEvent(effect) {\n !ngDevMode && throwError('Injector profiler should never be called in production mode');\n injectorProfiler({\n type: 3 /* InjectorProfilerEventType.EffectCreated */,\n context: getInjectorProfilerContext(),\n effect\n });\n}\nfunction runInInjectorProfilerContext(injector, token, callback) {\n !ngDevMode && throwError('runInInjectorProfilerContext should never be called in production mode');\n const prevInjectContext = setInjectorProfilerContext({\n injector,\n token\n });\n try {\n callback();\n } finally {\n setInjectorProfilerContext(prevInjectContext);\n }\n}\nfunction isEnvironmentProviders(value) {\n return value && !!value.ɵproviders;\n}\nconst NG_COMP_DEF = getClosureSafeProperty({\n ɵcmp: getClosureSafeProperty\n});\nconst NG_DIR_DEF = getClosureSafeProperty({\n ɵdir: getClosureSafeProperty\n});\nconst NG_PIPE_DEF = getClosureSafeProperty({\n ɵpipe: getClosureSafeProperty\n});\nconst NG_MOD_DEF = getClosureSafeProperty({\n ɵmod: getClosureSafeProperty\n});\nconst NG_FACTORY_DEF = getClosureSafeProperty({\n ɵfac: getClosureSafeProperty\n});\n/**\n * If a directive is diPublic, bloomAdd sets a property on the type with this constant as\n * the key and the directive's unique ID as the value. This allows us to map directives to their\n * bloom filter bit for DI.\n */\n// TODO(misko): This is wrong. The NG_ELEMENT_ID should never be minified.\nconst NG_ELEMENT_ID = getClosureSafeProperty({\n __NG_ELEMENT_ID__: getClosureSafeProperty\n});\n/**\n * The `NG_ENV_ID` field on a DI token indicates special processing in the `EnvironmentInjector`:\n * getting such tokens from the `EnvironmentInjector` will bypass the standard DI resolution\n * strategy and instead will return implementation produced by the `NG_ENV_ID` factory function.\n *\n * This particular retrieval of DI tokens is mostly done to eliminate circular dependencies and\n * improve tree-shaking.\n */\nconst NG_ENV_ID = getClosureSafeProperty({\n __NG_ENV_ID__: getClosureSafeProperty\n});\n\n/**\n * Used for stringify render output in Ivy.\n * Important! This function is very performance-sensitive and we should\n * be extra careful not to introduce megamorphic reads in it.\n * Check `core/test/render3/perf/render_stringify` for benchmarks and alternate implementations.\n */\nfunction renderStringify(value) {\n if (typeof value === 'string') return value;\n if (value == null) return '';\n // Use `String` so that it invokes the `toString` method of the value. Note that this\n // appears to be faster than calling `value.toString` (see `render_stringify` benchmark).\n return String(value);\n}\n/**\n * Used to stringify a value so that it can be displayed in an error message.\n *\n * Important! This function contains a megamorphic read and should only be\n * used for error messages.\n */\nfunction stringifyForError(value) {\n if (typeof value === 'function') return value.name || value.toString();\n if (typeof value === 'object' && value != null && typeof value.type === 'function') {\n return value.type.name || value.type.toString();\n }\n return renderStringify(value);\n}\n/**\n * Used to stringify a `Type` and including the file path and line number in which it is defined, if\n * possible, for better debugging experience.\n *\n * Important! This function contains a megamorphic read and should only be used for error messages.\n */\nfunction debugStringifyTypeForError(type) {\n // TODO(pmvald): Do some refactoring so that we can use getComponentDef here without creating\n // circular deps.\n let componentDef = type[NG_COMP_DEF] || null;\n if (componentDef !== null && componentDef.debugInfo) {\n return stringifyTypeFromDebugInfo(componentDef.debugInfo);\n }\n return stringifyForError(type);\n}\n// TODO(pmvald): Do some refactoring so that we can use the type ClassDebugInfo for the param\n// debugInfo here without creating circular deps.\nfunction stringifyTypeFromDebugInfo(debugInfo) {\n if (!debugInfo.filePath || !debugInfo.lineNumber) {\n return debugInfo.className;\n } else {\n return `${debugInfo.className} (at ${debugInfo.filePath}:${debugInfo.lineNumber})`;\n }\n}\n\n/** Called when directives inject each other (creating a circular dependency) */\nfunction throwCyclicDependencyError(token, path) {\n throw new RuntimeError(-200 /* RuntimeErrorCode.CYCLIC_DI_DEPENDENCY */, ngDevMode ? `Circular dependency in DI detected for ${token}${path ? `. Dependency path: ${path.join(' > ')} > ${token}` : ''}` : token);\n}\nfunction throwMixedMultiProviderError() {\n throw new Error(`Cannot mix multi providers and regular providers`);\n}\nfunction throwInvalidProviderError(ngModuleType, providers, provider) {\n if (ngModuleType && providers) {\n const providerDetail = providers.map(v => v == provider ? '?' + provider + '?' : '...');\n throw new Error(`Invalid provider for the NgModule '${stringify(ngModuleType)}' - only instances of Provider and Type are allowed, got: [${providerDetail.join(', ')}]`);\n } else if (isEnvironmentProviders(provider)) {\n if (provider.ɵfromNgModule) {\n throw new RuntimeError(207 /* RuntimeErrorCode.PROVIDER_IN_WRONG_CONTEXT */, `Invalid providers from 'importProvidersFrom' present in a non-environment injector. 'importProvidersFrom' can't be used for component providers.`);\n } else {\n throw new RuntimeError(207 /* RuntimeErrorCode.PROVIDER_IN_WRONG_CONTEXT */, `Invalid providers present in a non-environment injector. 'EnvironmentProviders' can't be used for component providers.`);\n }\n } else {\n throw new Error('Invalid provider');\n }\n}\n/** Throws an error when a token is not found in DI. */\nfunction throwProviderNotFoundError(token, injectorName) {\n const errorMessage = ngDevMode && `No provider for ${stringifyForError(token)} found${injectorName ? ` in ${injectorName}` : ''}`;\n throw new RuntimeError(-201 /* RuntimeErrorCode.PROVIDER_NOT_FOUND */, errorMessage);\n}\n\n/**\n * Injection flags for DI.\n *\n * @publicApi\n * @deprecated use an options object for [`inject`](api/core/inject) instead.\n */\nvar InjectFlags;\n(function (InjectFlags) {\n // TODO(alxhub): make this 'const' (and remove `InternalInjectFlags` enum) when ngc no longer\n // writes exports of it into ngfactory files.\n /** Check self and check parent injector if needed */\n InjectFlags[InjectFlags[\"Default\"] = 0] = \"Default\";\n /**\n * Specifies that an injector should retrieve a dependency from any injector until reaching the\n * host element of the current component. (Only used with Element Injector)\n */\n InjectFlags[InjectFlags[\"Host\"] = 1] = \"Host\";\n /** Don't ascend to ancestors of the node requesting injection. */\n InjectFlags[InjectFlags[\"Self\"] = 2] = \"Self\";\n /** Skip the node that is requesting injection. */\n InjectFlags[InjectFlags[\"SkipSelf\"] = 4] = \"SkipSelf\";\n /** Inject `defaultValue` instead if token not found. */\n InjectFlags[InjectFlags[\"Optional\"] = 8] = \"Optional\";\n})(InjectFlags || (InjectFlags = {}));\n\n/**\n * Current implementation of inject.\n *\n * By default, it is `injectInjectorOnly`, which makes it `Injector`-only aware. It can be changed\n * to `directiveInject`, which brings in the `NodeInjector` system of ivy. It is designed this\n * way for two reasons:\n * 1. `Injector` should not depend on ivy logic.\n * 2. To maintain tree shake-ability we don't want to bring in unnecessary code.\n */\nlet _injectImplementation;\nfunction getInjectImplementation() {\n return _injectImplementation;\n}\n/**\n * Sets the current inject implementation.\n */\nfunction setInjectImplementation(impl) {\n const previous = _injectImplementation;\n _injectImplementation = impl;\n return previous;\n}\n/**\n * Injects `root` tokens in limp mode.\n *\n * If no injector exists, we can still inject tree-shakable providers which have `providedIn` set to\n * `\"root\"`. This is known as the limp mode injection. In such case the value is stored in the\n * injectable definition.\n */\nfunction injectRootLimpMode(token, notFoundValue, flags) {\n const injectableDef = getInjectableDef(token);\n if (injectableDef && injectableDef.providedIn == 'root') {\n return injectableDef.value === undefined ? injectableDef.value = injectableDef.factory() : injectableDef.value;\n }\n if (flags & InjectFlags.Optional) return null;\n if (notFoundValue !== undefined) return notFoundValue;\n throwProviderNotFoundError(token, 'Injector');\n}\n/**\n * Assert that `_injectImplementation` is not `fn`.\n *\n * This is useful, to prevent infinite recursion.\n *\n * @param fn Function which it should not equal to\n */\nfunction assertInjectImplementationNotEqual(fn) {\n ngDevMode && assertNotEqual(_injectImplementation, fn, 'Calling ɵɵinject would cause infinite recursion');\n}\nconst _THROW_IF_NOT_FOUND = {};\nconst THROW_IF_NOT_FOUND = _THROW_IF_NOT_FOUND;\nfunction getCurrentInjector() {\n return di.getCurrentInjector();\n}\nfunction setCurrentInjector(injector) {\n return di.setCurrentInjector(injector);\n}\n/*\n * Name of a property (that we patch onto DI decorator), which is used as an annotation of which\n * InjectFlag this decorator represents. This allows to avoid direct references to the DI decorators\n * in the code, thus making them tree-shakable.\n */\nconst DI_DECORATOR_FLAG = '__NG_DI_FLAG__';\nconst NG_TEMP_TOKEN_PATH = 'ngTempTokenPath';\nconst NG_TOKEN_PATH = 'ngTokenPath';\nconst NEW_LINE = /\\n/gm;\nconst NO_NEW_LINE = 'ɵ';\nconst SOURCE = '__source';\nfunction injectInjectorOnly(token, flags = InjectFlags.Default) {\n if (getCurrentInjector() === undefined) {\n throw new RuntimeError(-203 /* RuntimeErrorCode.MISSING_INJECTION_CONTEXT */, ngDevMode && `inject() must be called from an injection context such as a constructor, a factory function, a field initializer, or a function used with \\`runInInjectionContext\\`.`);\n } else if (getCurrentInjector() === null) {\n return injectRootLimpMode(token, undefined, flags);\n } else {\n const value = getCurrentInjector().get(token, flags & InjectFlags.Optional ? null : undefined, flags);\n ngDevMode && emitInjectEvent(token, value, flags);\n return value;\n }\n}\nfunction ɵɵinject(token, flags = InjectFlags.Default) {\n return (getInjectImplementation() || injectInjectorOnly)(resolveForwardRef(token), flags);\n}\n/**\n * Throws an error indicating that a factory function could not be generated by the compiler for a\n * particular class.\n *\n * The name of the class is not mentioned here, but will be in the generated factory function name\n * and thus in the stack trace.\n *\n * @codeGenApi\n */\nfunction ɵɵinvalidFactoryDep(index) {\n throw new RuntimeError(202 /* RuntimeErrorCode.INVALID_FACTORY_DEPENDENCY */, ngDevMode && `This constructor is not compatible with Angular Dependency Injection because its dependency at index ${index} of the parameter list is invalid.\nThis can happen if the dependency type is a primitive like a string or if an ancestor of this class is missing an Angular decorator.\n\nPlease check that 1) the type for the parameter at index ${index} is correct and 2) the correct Angular decorators are defined for this class and its ancestors.`);\n}\n/**\n * Injects a token from the currently active injector.\n * `inject` is only supported in an [injection context](guide/di/dependency-injection-context). It\n * can be used during:\n * - Construction (via the `constructor`) of a class being instantiated by the DI system, such\n * as an `@Injectable` or `@Component`.\n * - In the initializer for fields of such classes.\n * - In the factory function specified for `useFactory` of a `Provider` or an `@Injectable`.\n * - In the `factory` function specified for an `InjectionToken`.\n * - In a stackframe of a function call in a DI context\n *\n * @param token A token that represents a dependency that should be injected.\n * @param flags Optional flags that control how injection is executed.\n * The flags correspond to injection strategies that can be specified with\n * parameter decorators `@Host`, `@Self`, `@SkipSelf`, and `@Optional`.\n * @returns the injected value if operation is successful, `null` otherwise.\n * @throws if called outside of a supported context.\n *\n * @usageNotes\n * In practice the `inject()` calls are allowed in a constructor, a constructor parameter and a\n * field initializer:\n *\n * ```ts\n * @Injectable({providedIn: 'root'})\n * export class Car {\n * radio: Radio|undefined;\n * // OK: field initializer\n * spareTyre = inject(Tyre);\n *\n * constructor() {\n * // OK: constructor body\n * this.radio = inject(Radio);\n * }\n * }\n * ```\n *\n * It is also legal to call `inject` from a provider's factory:\n *\n * ```ts\n * providers: [\n * {provide: Car, useFactory: () => {\n * // OK: a class factory\n * const engine = inject(Engine);\n * return new Car(engine);\n * }}\n * ]\n * ```\n *\n * Calls to the `inject()` function outside of the class creation context will result in error. Most\n * notably, calls to `inject()` are disallowed after a class instance was created, in methods\n * (including lifecycle hooks):\n *\n * ```ts\n * @Component({ ... })\n * export class CarComponent {\n * ngOnInit() {\n * // ERROR: too late, the component instance was already created\n * const engine = inject(Engine);\n * engine.start();\n * }\n * }\n * ```\n *\n * @publicApi\n */\nfunction inject(token, flags = InjectFlags.Default) {\n // The `as any` here _shouldn't_ be necessary, but without it JSCompiler\n // throws a disambiguation error due to the multiple signatures.\n return ɵɵinject(token, convertToBitFlags(flags));\n}\n// Converts object-based DI flags (`InjectOptions`) to bit flags (`InjectFlags`).\nfunction convertToBitFlags(flags) {\n if (typeof flags === 'undefined' || typeof flags === 'number') {\n return flags;\n }\n // While TypeScript doesn't accept it without a cast, bitwise OR with false-y values in\n // JavaScript is a no-op. We can use that for a very codesize-efficient conversion from\n // `InjectOptions` to `InjectFlags`.\n return 0 /* InternalInjectFlags.Default */ | (\n // comment to force a line break in the formatter\n flags.optional && 8 /* InternalInjectFlags.Optional */) | (flags.host && 1 /* InternalInjectFlags.Host */) | (flags.self && 2 /* InternalInjectFlags.Self */) | (flags.skipSelf && 4 /* InternalInjectFlags.SkipSelf */);\n}\nfunction injectArgs(types) {\n const args = [];\n for (let i = 0; i < types.length; i++) {\n const arg = resolveForwardRef(types[i]);\n if (Array.isArray(arg)) {\n if (arg.length === 0) {\n throw new RuntimeError(900 /* RuntimeErrorCode.INVALID_DIFFER_INPUT */, ngDevMode && 'Arguments array must have arguments.');\n }\n let type = undefined;\n let flags = InjectFlags.Default;\n for (let j = 0; j < arg.length; j++) {\n const meta = arg[j];\n const flag = getInjectFlag(meta);\n if (typeof flag === 'number') {\n // Special case when we handle @Inject decorator.\n if (flag === -1 /* DecoratorFlags.Inject */) {\n type = meta.token;\n } else {\n flags |= flag;\n }\n } else {\n type = meta;\n }\n }\n args.push(ɵɵinject(type, flags));\n } else {\n args.push(ɵɵinject(arg));\n }\n }\n return args;\n}\n/**\n * Attaches a given InjectFlag to a given decorator using monkey-patching.\n * Since DI decorators can be used in providers `deps` array (when provider is configured using\n * `useFactory`) without initialization (e.g. `Host`) and as an instance (e.g. `new Host()`), we\n * attach the flag to make it available both as a static property and as a field on decorator\n * instance.\n *\n * @param decorator Provided DI decorator.\n * @param flag InjectFlag that should be applied.\n */\nfunction attachInjectFlag(decorator, flag) {\n decorator[DI_DECORATOR_FLAG] = flag;\n decorator.prototype[DI_DECORATOR_FLAG] = flag;\n return decorator;\n}\n/**\n * Reads monkey-patched property that contains InjectFlag attached to a decorator.\n *\n * @param token Token that may contain monkey-patched DI flags property.\n */\nfunction getInjectFlag(token) {\n return token[DI_DECORATOR_FLAG];\n}\nfunction catchInjectorError(e, token, injectorErrorName, source) {\n const tokenPath = e[NG_TEMP_TOKEN_PATH];\n if (token[SOURCE]) {\n tokenPath.unshift(token[SOURCE]);\n }\n e.message = formatError('\\n' + e.message, tokenPath, injectorErrorName, source);\n e[NG_TOKEN_PATH] = tokenPath;\n e[NG_TEMP_TOKEN_PATH] = null;\n throw e;\n}\nfunction formatError(text, obj, injectorErrorName, source = null) {\n text = text && text.charAt(0) === '\\n' && text.charAt(1) == NO_NEW_LINE ? text.slice(2) : text;\n let context = stringify(obj);\n if (Array.isArray(obj)) {\n context = obj.map(stringify).join(' -> ');\n } else if (typeof obj === 'object') {\n let parts = [];\n for (let key in obj) {\n if (obj.hasOwnProperty(key)) {\n let value = obj[key];\n parts.push(key + ':' + (typeof value === 'string' ? JSON.stringify(value) : stringify(value)));\n }\n }\n context = `{${parts.join(', ')}}`;\n }\n return `${injectorErrorName}${source ? '(' + source + ')' : ''}[${context}]: ${text.replace(NEW_LINE, '\\n ')}`;\n}\n\n/**\n * Inject decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst Inject = attachInjectFlag(\n// Disable tslint because `DecoratorFlags` is a const enum which gets inlined.\nmakeParamDecorator('Inject', token => ({\n token\n})), -1 /* DecoratorFlags.Inject */);\n/**\n * Optional decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst Optional =\n// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined.\n// tslint:disable-next-line: no-toplevel-property-access\nattachInjectFlag(makeParamDecorator('Optional'), 8 /* InternalInjectFlags.Optional */);\n/**\n * Self decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst Self =\n// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined.\n// tslint:disable-next-line: no-toplevel-property-access\nattachInjectFlag(makeParamDecorator('Self'), 2 /* InternalInjectFlags.Self */);\n/**\n * `SkipSelf` decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst SkipSelf =\n// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined.\n// tslint:disable-next-line: no-toplevel-property-access\nattachInjectFlag(makeParamDecorator('SkipSelf'), 4 /* InternalInjectFlags.SkipSelf */);\n/**\n * Host decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst Host =\n// Disable tslint because `InternalInjectFlags` is a const enum which gets inlined.\n// tslint:disable-next-line: no-toplevel-property-access\nattachInjectFlag(makeParamDecorator('Host'), 1 /* InternalInjectFlags.Host */);\nfunction getFactoryDef(type, throwNotFound) {\n const hasFactoryDef = type.hasOwnProperty(NG_FACTORY_DEF);\n if (!hasFactoryDef && throwNotFound === true && ngDevMode) {\n throw new Error(`Type ${stringify(type)} does not have 'ɵfac' property.`);\n }\n return hasFactoryDef ? type[NG_FACTORY_DEF] : null;\n}\n\n/**\n * Determines if the contents of two arrays is identical\n *\n * @param a first array\n * @param b second array\n * @param identityAccessor Optional function for extracting stable object identity from a value in\n * the array.\n */\nfunction arrayEquals(a, b, identityAccessor) {\n if (a.length !== b.length) return false;\n for (let i = 0; i < a.length; i++) {\n let valueA = a[i];\n let valueB = b[i];\n if (identityAccessor) {\n valueA = identityAccessor(valueA);\n valueB = identityAccessor(valueB);\n }\n if (valueB !== valueA) {\n return false;\n }\n }\n return true;\n}\n/**\n * Flattens an array.\n */\nfunction flatten(list) {\n return list.flat(Number.POSITIVE_INFINITY);\n}\nfunction deepForEach(input, fn) {\n input.forEach(value => Array.isArray(value) ? deepForEach(value, fn) : fn(value));\n}\nfunction addToArray(arr, index, value) {\n // perf: array.push is faster than array.splice!\n if (index >= arr.length) {\n arr.push(value);\n } else {\n arr.splice(index, 0, value);\n }\n}\nfunction removeFromArray(arr, index) {\n // perf: array.pop is faster than array.splice!\n if (index >= arr.length - 1) {\n return arr.pop();\n } else {\n return arr.splice(index, 1)[0];\n }\n}\nfunction newArray(size, value) {\n const list = [];\n for (let i = 0; i < size; i++) {\n list.push(value);\n }\n return list;\n}\n/**\n * Remove item from array (Same as `Array.splice()` but faster.)\n *\n * `Array.splice()` is not as fast because it has to allocate an array for the elements which were\n * removed. This causes memory pressure and slows down code when most of the time we don't\n * care about the deleted items array.\n *\n * https://jsperf.com/fast-array-splice (About 20x faster)\n *\n * @param array Array to splice\n * @param index Index of element in array to remove.\n * @param count Number of items to remove.\n */\nfunction arraySplice(array, index, count) {\n const length = array.length - count;\n while (index < length) {\n array[index] = array[index + count];\n index++;\n }\n while (count--) {\n array.pop(); // shrink the array\n }\n}\n/**\n * Same as `Array.splice(index, 0, value)` but faster.\n *\n * `Array.splice()` is not fast because it has to allocate an array for the elements which were\n * removed. This causes memory pressure and slows down code when most of the time we don't\n * care about the deleted items array.\n *\n * @param array Array to splice.\n * @param index Index in array where the `value` should be added.\n * @param value Value to add to array.\n */\nfunction arrayInsert(array, index, value) {\n ngDevMode && assertLessThanOrEqual(index, array.length, \"Can't insert past array end.\");\n let end = array.length;\n while (end > index) {\n const previousEnd = end - 1;\n array[end] = array[previousEnd];\n end = previousEnd;\n }\n array[index] = value;\n}\n/**\n * Same as `Array.splice2(index, 0, value1, value2)` but faster.\n *\n * `Array.splice()` is not fast because it has to allocate an array for the elements which were\n * removed. This causes memory pressure and slows down code when most of the time we don't\n * care about the deleted items array.\n *\n * @param array Array to splice.\n * @param index Index in array where the `value` should be added.\n * @param value1 Value to add to array.\n * @param value2 Value to add to array.\n */\nfunction arrayInsert2(array, index, value1, value2) {\n ngDevMode && assertLessThanOrEqual(index, array.length, \"Can't insert past array end.\");\n let end = array.length;\n if (end == index) {\n // inserting at the end.\n array.push(value1, value2);\n } else if (end === 1) {\n // corner case when we have less items in array than we have items to insert.\n array.push(value2, array[0]);\n array[0] = value1;\n } else {\n end--;\n array.push(array[end - 1], array[end]);\n while (end > index) {\n const previousEnd = end - 2;\n array[end] = array[previousEnd];\n end--;\n }\n array[index] = value1;\n array[index + 1] = value2;\n }\n}\n/**\n * Get an index of an `value` in a sorted `array`.\n *\n * NOTE:\n * - This uses binary search algorithm for fast removals.\n *\n * @param array A sorted array to binary search.\n * @param value The value to look for.\n * @returns index of the value.\n * - positive index if value found.\n * - negative index if value not found. (`~index` to get the value where it should have been\n * located)\n */\nfunction arrayIndexOfSorted(array, value) {\n return _arrayIndexOfSorted(array, value, 0);\n}\n/**\n * Set a `value` for a `key`.\n *\n * @param keyValueArray to modify.\n * @param key The key to locate or create.\n * @param value The value to set for a `key`.\n * @returns index (always even) of where the value vas set.\n */\nfunction keyValueArraySet(keyValueArray, key, value) {\n let index = keyValueArrayIndexOf(keyValueArray, key);\n if (index >= 0) {\n // if we found it set it.\n keyValueArray[index | 1] = value;\n } else {\n index = ~index;\n arrayInsert2(keyValueArray, index, key, value);\n }\n return index;\n}\n/**\n * Retrieve a `value` for a `key` (on `undefined` if not found.)\n *\n * @param keyValueArray to search.\n * @param key The key to locate.\n * @return The `value` stored at the `key` location or `undefined if not found.\n */\nfunction keyValueArrayGet(keyValueArray, key) {\n const index = keyValueArrayIndexOf(keyValueArray, key);\n if (index >= 0) {\n // if we found it retrieve it.\n return keyValueArray[index | 1];\n }\n return undefined;\n}\n/**\n * Retrieve a `key` index value in the array or `-1` if not found.\n *\n * @param keyValueArray to search.\n * @param key The key to locate.\n * @returns index of where the key is (or should have been.)\n * - positive (even) index if key found.\n * - negative index if key not found. (`~index` (even) to get the index where it should have\n * been inserted.)\n */\nfunction keyValueArrayIndexOf(keyValueArray, key) {\n return _arrayIndexOfSorted(keyValueArray, key, 1);\n}\n/**\n * Delete a `key` (and `value`) from the `KeyValueArray`.\n *\n * @param keyValueArray to modify.\n * @param key The key to locate or delete (if exist).\n * @returns index of where the key was (or should have been.)\n * - positive (even) index if key found and deleted.\n * - negative index if key not found. (`~index` (even) to get the index where it should have\n * been.)\n */\nfunction keyValueArrayDelete(keyValueArray, key) {\n const index = keyValueArrayIndexOf(keyValueArray, key);\n if (index >= 0) {\n // if we found it remove it.\n arraySplice(keyValueArray, index, 2);\n }\n return index;\n}\n/**\n * INTERNAL: Get an index of an `value` in a sorted `array` by grouping search by `shift`.\n *\n * NOTE:\n * - This uses binary search algorithm for fast removals.\n *\n * @param array A sorted array to binary search.\n * @param value The value to look for.\n * @param shift grouping shift.\n * - `0` means look at every location\n * - `1` means only look at every other (even) location (the odd locations are to be ignored as\n * they are values.)\n * @returns index of the value.\n * - positive index if value found.\n * - negative index if value not found. (`~index` to get the value where it should have been\n * inserted)\n */\nfunction _arrayIndexOfSorted(array, value, shift) {\n ngDevMode && assertEqual(Array.isArray(array), true, 'Expecting an array');\n let start = 0;\n let end = array.length >> shift;\n while (end !== start) {\n const middle = start + (end - start >> 1); // find the middle.\n const current = array[middle << shift];\n if (value === current) {\n return middle << shift;\n } else if (current > value) {\n end = middle;\n } else {\n start = middle + 1; // We already searched middle so make it non-inclusive by adding 1\n }\n }\n return ~(end << shift);\n}\n\n/**\n * This file contains reuseable \"empty\" symbols that can be used as default return values\n * in different parts of the rendering code. Because the same symbols are returned, this\n * allows for identity checks against these values to be consistently used by the framework\n * code.\n */\nconst EMPTY_OBJ = {};\nconst EMPTY_ARRAY = [];\n// freezing the values prevents any code from accidentally inserting new values in\nif ((typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode()) {\n // These property accesses can be ignored because ngDevMode will be set to false\n // when optimizing code and the whole if statement will be dropped.\n // tslint:disable-next-line:no-toplevel-property-access\n Object.freeze(EMPTY_OBJ);\n // tslint:disable-next-line:no-toplevel-property-access\n Object.freeze(EMPTY_ARRAY);\n}\n\n/**\n * A multi-provider token for initialization functions that will run upon construction of an\n * environment injector.\n *\n * @deprecated from v19.0.0, use provideEnvironmentInitializer instead\n *\n * @see {@link provideEnvironmentInitializer}\n *\n * Note: As opposed to the `APP_INITIALIZER` token, the `ENVIRONMENT_INITIALIZER` functions are not awaited,\n * hence they should not be `async`.\n *\n * @publicApi\n */\nconst ENVIRONMENT_INITIALIZER = new InjectionToken(ngDevMode ? 'ENVIRONMENT_INITIALIZER' : '');\n\n/**\n * An InjectionToken that gets the current `Injector` for `createInjector()`-style injectors.\n *\n * Requesting this token instead of `Injector` allows `StaticInjector` to be tree-shaken from a\n * project.\n *\n * @publicApi\n */\nconst INJECTOR$1 = new InjectionToken(ngDevMode ? 'INJECTOR' : '',\n// Disable tslint because this is const enum which gets inlined not top level prop access.\n// tslint:disable-next-line: no-toplevel-property-access\n-1 /* InjectorMarkers.Injector */);\nconst INJECTOR_DEF_TYPES = new InjectionToken(ngDevMode ? 'INJECTOR_DEF_TYPES' : '');\nclass NullInjector {\n get(token, notFoundValue = THROW_IF_NOT_FOUND) {\n if (notFoundValue === THROW_IF_NOT_FOUND) {\n const error = new Error(`NullInjectorError: No provider for ${stringify(token)}!`);\n error.name = 'NullInjectorError';\n throw error;\n }\n return notFoundValue;\n }\n}\nfunction getNgModuleDef(type, throwNotFound) {\n const ngModuleDef = type[NG_MOD_DEF] || null;\n if (!ngModuleDef && throwNotFound === true) {\n throw new Error(`Type ${stringify(type)} does not have 'ɵmod' property.`);\n }\n return ngModuleDef;\n}\n/**\n * The following getter methods retrieve the definition from the type. Currently the retrieval\n * honors inheritance, but in the future we may change the rule to require that definitions are\n * explicit. This would require some sort of migration strategy.\n */\nfunction getComponentDef(type) {\n return type[NG_COMP_DEF] || null;\n}\nfunction getDirectiveDef(type) {\n return type[NG_DIR_DEF] || null;\n}\nfunction getPipeDef$1(type) {\n return type[NG_PIPE_DEF] || null;\n}\n/**\n * Checks whether a given Component, Directive or Pipe is marked as standalone.\n * This will return false if passed anything other than a Component, Directive, or Pipe class\n * See [this guide](guide/components/importing) for additional information:\n *\n * @param type A reference to a Component, Directive or Pipe.\n * @publicApi\n */\nfunction isStandalone(type) {\n const def = getComponentDef(type) || getDirectiveDef(type) || getPipeDef$1(type);\n return def !== null && def.standalone;\n}\n\n/**\n * Wrap an array of `Provider`s into `EnvironmentProviders`, preventing them from being accidentally\n * referenced in `@Component` in a component injector.\n */\nfunction makeEnvironmentProviders(providers) {\n return {\n ɵproviders: providers\n };\n}\n/**\n * @description\n * This function is used to provide initialization functions that will be executed upon construction\n * of an environment injector.\n *\n * Note that the provided initializer is run in the injection context.\n *\n * Previously, this was achieved using the `ENVIRONMENT_INITIALIZER` token which is now deprecated.\n *\n * @see {@link ENVIRONMENT_INITIALIZER}\n *\n * @usageNotes\n * The following example illustrates how to configure an initialization function using\n * `provideEnvironmentInitializer()`\n * ```ts\n * createEnvironmentInjector(\n * [\n * provideEnvironmentInitializer(() => {\n * console.log('environment initialized');\n * }),\n * ],\n * parentInjector\n * );\n * ```\n *\n * @publicApi\n */\nfunction provideEnvironmentInitializer(initializerFn) {\n return makeEnvironmentProviders([{\n provide: ENVIRONMENT_INITIALIZER,\n multi: true,\n useValue: initializerFn\n }]);\n}\n/**\n * Collects providers from all NgModules and standalone components, including transitively imported\n * ones.\n *\n * Providers extracted via `importProvidersFrom` are only usable in an application injector or\n * another environment injector (such as a route injector). They should not be used in component\n * providers.\n *\n * More information about standalone components can be found in [this\n * guide](guide/components/importing).\n *\n * @usageNotes\n * The results of the `importProvidersFrom` call can be used in the `bootstrapApplication` call:\n *\n * ```ts\n * await bootstrapApplication(RootComponent, {\n * providers: [\n * importProvidersFrom(NgModuleOne, NgModuleTwo)\n * ]\n * });\n * ```\n *\n * You can also use the `importProvidersFrom` results in the `providers` field of a route, when a\n * standalone component is used:\n *\n * ```ts\n * export const ROUTES: Route[] = [\n * {\n * path: 'foo',\n * providers: [\n * importProvidersFrom(NgModuleOne, NgModuleTwo)\n * ],\n * component: YourStandaloneComponent\n * }\n * ];\n * ```\n *\n * @returns Collected providers from the specified list of types.\n * @publicApi\n */\nfunction importProvidersFrom(...sources) {\n return {\n ɵproviders: internalImportProvidersFrom(true, sources),\n ɵfromNgModule: true\n };\n}\nfunction internalImportProvidersFrom(checkForStandaloneCmp, ...sources) {\n const providersOut = [];\n const dedup = new Set(); // already seen types\n let injectorTypesWithProviders;\n const collectProviders = provider => {\n providersOut.push(provider);\n };\n deepForEach(sources, source => {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && checkForStandaloneCmp) {\n const cmpDef = getComponentDef(source);\n if (cmpDef?.standalone) {\n throw new RuntimeError(800 /* RuntimeErrorCode.IMPORT_PROVIDERS_FROM_STANDALONE */, `Importing providers supports NgModule or ModuleWithProviders but got a standalone component \"${stringifyForError(source)}\"`);\n }\n }\n // Narrow `source` to access the internal type analogue for `ModuleWithProviders`.\n const internalSource = source;\n if (walkProviderTree(internalSource, collectProviders, [], dedup)) {\n injectorTypesWithProviders ||= [];\n injectorTypesWithProviders.push(internalSource);\n }\n });\n // Collect all providers from `ModuleWithProviders` types.\n if (injectorTypesWithProviders !== undefined) {\n processInjectorTypesWithProviders(injectorTypesWithProviders, collectProviders);\n }\n return providersOut;\n}\n/**\n * Collects all providers from the list of `ModuleWithProviders` and appends them to the provided\n * array.\n */\nfunction processInjectorTypesWithProviders(typesWithProviders, visitor) {\n for (let i = 0; i < typesWithProviders.length; i++) {\n const {\n ngModule,\n providers\n } = typesWithProviders[i];\n deepForEachProvider(providers, provider => {\n ngDevMode && validateProvider(provider, providers || EMPTY_ARRAY, ngModule);\n visitor(provider, ngModule);\n });\n }\n}\n/**\n * The logic visits an `InjectorType`, an `InjectorTypeWithProviders`, or a standalone\n * `ComponentType`, and all of its transitive providers and collects providers.\n *\n * If an `InjectorTypeWithProviders` that declares providers besides the type is specified,\n * the function will return \"true\" to indicate that the providers of the type definition need\n * to be processed. This allows us to process providers of injector types after all imports of\n * an injector definition are processed. (following View Engine semantics: see FW-1349)\n */\nfunction walkProviderTree(container, visitor, parents, dedup) {\n container = resolveForwardRef(container);\n if (!container) return false;\n // The actual type which had the definition. Usually `container`, but may be an unwrapped type\n // from `InjectorTypeWithProviders`.\n let defType = null;\n let injDef = getInjectorDef(container);\n const cmpDef = !injDef && getComponentDef(container);\n if (!injDef && !cmpDef) {\n // `container` is not an injector type or a component type. It might be:\n // * An `InjectorTypeWithProviders` that wraps an injector type.\n // * A standalone directive or pipe that got pulled in from a standalone component's\n // dependencies.\n // Try to unwrap it as an `InjectorTypeWithProviders` first.\n const ngModule = container.ngModule;\n injDef = getInjectorDef(ngModule);\n if (injDef) {\n defType = ngModule;\n } else {\n // Not a component or injector type, so ignore it.\n return false;\n }\n } else if (cmpDef && !cmpDef.standalone) {\n return false;\n } else {\n defType = container;\n }\n // Check for circular dependencies.\n if (ngDevMode && parents.indexOf(defType) !== -1) {\n const defName = stringify(defType);\n const path = parents.map(stringify);\n throwCyclicDependencyError(defName, path);\n }\n // Check for multiple imports of the same module\n const isDuplicate = dedup.has(defType);\n if (cmpDef) {\n if (isDuplicate) {\n // This component definition has already been processed.\n return false;\n }\n dedup.add(defType);\n if (cmpDef.dependencies) {\n const deps = typeof cmpDef.dependencies === 'function' ? cmpDef.dependencies() : cmpDef.dependencies;\n for (const dep of deps) {\n walkProviderTree(dep, visitor, parents, dedup);\n }\n }\n } else if (injDef) {\n // First, include providers from any imports.\n if (injDef.imports != null && !isDuplicate) {\n // Before processing defType's imports, add it to the set of parents. This way, if it ends\n // up deeply importing itself, this can be detected.\n ngDevMode && parents.push(defType);\n // Add it to the set of dedups. This way we can detect multiple imports of the same module\n dedup.add(defType);\n let importTypesWithProviders;\n try {\n deepForEach(injDef.imports, imported => {\n if (walkProviderTree(imported, visitor, parents, dedup)) {\n importTypesWithProviders ||= [];\n // If the processed import is an injector type with providers, we store it in the\n // list of import types with providers, so that we can process those afterwards.\n importTypesWithProviders.push(imported);\n }\n });\n } finally {\n // Remove it from the parents set when finished.\n ngDevMode && parents.pop();\n }\n // Imports which are declared with providers (TypeWithProviders) need to be processed\n // after all imported modules are processed. This is similar to how View Engine\n // processes/merges module imports in the metadata resolver. See: FW-1349.\n if (importTypesWithProviders !== undefined) {\n processInjectorTypesWithProviders(importTypesWithProviders, visitor);\n }\n }\n if (!isDuplicate) {\n // Track the InjectorType and add a provider for it.\n // It's important that this is done after the def's imports.\n const factory = getFactoryDef(defType) || (() => new defType());\n // Append extra providers to make more info available for consumers (to retrieve an injector\n // type), as well as internally (to calculate an injection scope correctly and eagerly\n // instantiate a `defType` when an injector is created).\n // Provider to create `defType` using its factory.\n visitor({\n provide: defType,\n useFactory: factory,\n deps: EMPTY_ARRAY\n }, defType);\n // Make this `defType` available to an internal logic that calculates injector scope.\n visitor({\n provide: INJECTOR_DEF_TYPES,\n useValue: defType,\n multi: true\n }, defType);\n // Provider to eagerly instantiate `defType` via `INJECTOR_INITIALIZER`.\n visitor({\n provide: ENVIRONMENT_INITIALIZER,\n useValue: () => ɵɵinject(defType),\n multi: true\n }, defType);\n }\n // Next, include providers listed on the definition itself.\n const defProviders = injDef.providers;\n if (defProviders != null && !isDuplicate) {\n const injectorType = container;\n deepForEachProvider(defProviders, provider => {\n ngDevMode && validateProvider(provider, defProviders, injectorType);\n visitor(provider, injectorType);\n });\n }\n } else {\n // Should not happen, but just in case.\n return false;\n }\n return defType !== container && container.providers !== undefined;\n}\nfunction validateProvider(provider, providers, containerType) {\n if (isTypeProvider(provider) || isValueProvider(provider) || isFactoryProvider(provider) || isExistingProvider(provider)) {\n return;\n }\n // Here we expect the provider to be a `useClass` provider (by elimination).\n const classRef = resolveForwardRef(provider && (provider.useClass || provider.provide));\n if (!classRef) {\n throwInvalidProviderError(containerType, providers, provider);\n }\n}\nfunction deepForEachProvider(providers, fn) {\n for (let provider of providers) {\n if (isEnvironmentProviders(provider)) {\n provider = provider.ɵproviders;\n }\n if (Array.isArray(provider)) {\n deepForEachProvider(provider, fn);\n } else {\n fn(provider);\n }\n }\n}\nconst USE_VALUE$1 = getClosureSafeProperty({\n provide: String,\n useValue: getClosureSafeProperty\n});\nfunction isValueProvider(value) {\n return value !== null && typeof value == 'object' && USE_VALUE$1 in value;\n}\nfunction isExistingProvider(value) {\n return !!(value && value.useExisting);\n}\nfunction isFactoryProvider(value) {\n return !!(value && value.useFactory);\n}\nfunction isTypeProvider(value) {\n return typeof value === 'function';\n}\nfunction isClassProvider(value) {\n return !!value.useClass;\n}\n\n/**\n * An internal token whose presence in an injector indicates that the injector should treat itself\n * as a root scoped injector when processing requests for unknown tokens which may indicate\n * they are provided in the root scope.\n */\nconst INJECTOR_SCOPE = new InjectionToken(ngDevMode ? 'Set Injector scope.' : '');\n\n/**\n * Marker which indicates that a value has not yet been created from the factory function.\n */\nconst NOT_YET = {};\n/**\n * Marker which indicates that the factory function for a token is in the process of being called.\n *\n * If the injector is asked to inject a token with its value set to CIRCULAR, that indicates\n * injection of a dependency has recursively attempted to inject the original token, and there is\n * a circular dependency among the providers.\n */\nconst CIRCULAR = {};\n/**\n * A lazily initialized NullInjector.\n */\nlet NULL_INJECTOR = undefined;\nfunction getNullInjector() {\n if (NULL_INJECTOR === undefined) {\n NULL_INJECTOR = new NullInjector();\n }\n return NULL_INJECTOR;\n}\n/**\n * An `Injector` that's part of the environment injector hierarchy, which exists outside of the\n * component tree.\n */\nclass EnvironmentInjector {}\nclass R3Injector extends EnvironmentInjector {\n parent;\n source;\n scopes;\n /**\n * Map of tokens to records which contain the instances of those tokens.\n * - `null` value implies that we don't have the record. Used by tree-shakable injectors\n * to prevent further searches.\n */\n records = new Map();\n /**\n * Set of values instantiated by this injector which contain `ngOnDestroy` lifecycle hooks.\n */\n _ngOnDestroyHooks = new Set();\n _onDestroyHooks = [];\n /**\n * Flag indicating that this injector was previously destroyed.\n */\n get destroyed() {\n return this._destroyed;\n }\n _destroyed = false;\n injectorDefTypes;\n constructor(providers, parent, source, scopes) {\n super();\n this.parent = parent;\n this.source = source;\n this.scopes = scopes;\n // Start off by creating Records for every provider.\n forEachSingleProvider(providers, provider => this.processProvider(provider));\n // Make sure the INJECTOR token provides this injector.\n this.records.set(INJECTOR$1, makeRecord(undefined, this));\n // And `EnvironmentInjector` if the current injector is supposed to be env-scoped.\n if (scopes.has('environment')) {\n this.records.set(EnvironmentInjector, makeRecord(undefined, this));\n }\n // Detect whether this injector has the APP_ROOT_SCOPE token and thus should provide\n // any injectable scoped to APP_ROOT_SCOPE.\n const record = this.records.get(INJECTOR_SCOPE);\n if (record != null && typeof record.value === 'string') {\n this.scopes.add(record.value);\n }\n this.injectorDefTypes = new Set(this.get(INJECTOR_DEF_TYPES, EMPTY_ARRAY, InjectFlags.Self));\n }\n /**\n * Destroy the injector and release references to every instance or provider associated with it.\n *\n * Also calls the `OnDestroy` lifecycle hooks of every instance that was created for which a\n * hook was found.\n */\n destroy() {\n assertNotDestroyed(this);\n // Set destroyed = true first, in case lifecycle hooks re-enter destroy().\n this._destroyed = true;\n const prevConsumer = setActiveConsumer$1(null);\n try {\n // Call all the lifecycle hooks.\n for (const service of this._ngOnDestroyHooks) {\n service.ngOnDestroy();\n }\n const onDestroyHooks = this._onDestroyHooks;\n // Reset the _onDestroyHooks array before iterating over it to prevent hooks that unregister\n // themselves from mutating the array during iteration.\n this._onDestroyHooks = [];\n for (const hook of onDestroyHooks) {\n hook();\n }\n } finally {\n // Release all references.\n this.records.clear();\n this._ngOnDestroyHooks.clear();\n this.injectorDefTypes.clear();\n setActiveConsumer$1(prevConsumer);\n }\n }\n onDestroy(callback) {\n assertNotDestroyed(this);\n this._onDestroyHooks.push(callback);\n return () => this.removeOnDestroy(callback);\n }\n runInContext(fn) {\n assertNotDestroyed(this);\n const previousInjector = setCurrentInjector(this);\n const previousInjectImplementation = setInjectImplementation(undefined);\n let prevInjectContext;\n if (ngDevMode) {\n prevInjectContext = setInjectorProfilerContext({\n injector: this,\n token: null\n });\n }\n try {\n return fn();\n } finally {\n setCurrentInjector(previousInjector);\n setInjectImplementation(previousInjectImplementation);\n ngDevMode && setInjectorProfilerContext(prevInjectContext);\n }\n }\n get(token, notFoundValue = THROW_IF_NOT_FOUND, flags = InjectFlags.Default) {\n assertNotDestroyed(this);\n if (token.hasOwnProperty(NG_ENV_ID)) {\n return token[NG_ENV_ID](this);\n }\n flags = convertToBitFlags(flags);\n // Set the injection context.\n let prevInjectContext;\n if (ngDevMode) {\n prevInjectContext = setInjectorProfilerContext({\n injector: this,\n token: token\n });\n }\n const previousInjector = setCurrentInjector(this);\n const previousInjectImplementation = setInjectImplementation(undefined);\n try {\n // Check for the SkipSelf flag.\n if (!(flags & InjectFlags.SkipSelf)) {\n // SkipSelf isn't set, check if the record belongs to this injector.\n let record = this.records.get(token);\n if (record === undefined) {\n // No record, but maybe the token is scoped to this injector. Look for an injectable\n // def with a scope matching this injector.\n const def = couldBeInjectableType(token) && getInjectableDef(token);\n if (def && this.injectableDefInScope(def)) {\n // Found an injectable def and it's scoped to this injector. Pretend as if it was here\n // all along.\n if (ngDevMode) {\n runInInjectorProfilerContext(this, token, () => {\n emitProviderConfiguredEvent(token);\n });\n }\n record = makeRecord(injectableDefOrInjectorDefFactory(token), NOT_YET);\n } else {\n record = null;\n }\n this.records.set(token, record);\n }\n // If a record was found, get the instance for it and return it.\n if (record != null /* NOT null || undefined */) {\n return this.hydrate(token, record);\n }\n }\n // Select the next injector based on the Self flag - if self is set, the next injector is\n // the NullInjector, otherwise it's the parent.\n const nextInjector = !(flags & InjectFlags.Self) ? this.parent : getNullInjector();\n // Set the notFoundValue based on the Optional flag - if optional is set and notFoundValue\n // is undefined, the value is null, otherwise it's the notFoundValue.\n notFoundValue = flags & InjectFlags.Optional && notFoundValue === THROW_IF_NOT_FOUND ? null : notFoundValue;\n return nextInjector.get(token, notFoundValue);\n } catch (e) {\n if (e.name === 'NullInjectorError') {\n const path = e[NG_TEMP_TOKEN_PATH] = e[NG_TEMP_TOKEN_PATH] || [];\n path.unshift(stringify(token));\n if (previousInjector) {\n // We still have a parent injector, keep throwing\n throw e;\n } else {\n // Format & throw the final error message when we don't have any previous injector\n return catchInjectorError(e, token, 'R3InjectorError', this.source);\n }\n } else {\n throw e;\n }\n } finally {\n // Lastly, restore the previous injection context.\n setInjectImplementation(previousInjectImplementation);\n setCurrentInjector(previousInjector);\n ngDevMode && setInjectorProfilerContext(prevInjectContext);\n }\n }\n /** @internal */\n resolveInjectorInitializers() {\n const prevConsumer = setActiveConsumer$1(null);\n const previousInjector = setCurrentInjector(this);\n const previousInjectImplementation = setInjectImplementation(undefined);\n let prevInjectContext;\n if (ngDevMode) {\n prevInjectContext = setInjectorProfilerContext({\n injector: this,\n token: null\n });\n }\n try {\n const initializers = this.get(ENVIRONMENT_INITIALIZER, EMPTY_ARRAY, InjectFlags.Self);\n if (ngDevMode && !Array.isArray(initializers)) {\n throw new RuntimeError(-209 /* RuntimeErrorCode.INVALID_MULTI_PROVIDER */, 'Unexpected type of the `ENVIRONMENT_INITIALIZER` token value ' + `(expected an array, but got ${typeof initializers}). ` + 'Please check that the `ENVIRONMENT_INITIALIZER` token is configured as a ' + '`multi: true` provider.');\n }\n for (const initializer of initializers) {\n initializer();\n }\n } finally {\n setCurrentInjector(previousInjector);\n setInjectImplementation(previousInjectImplementation);\n ngDevMode && setInjectorProfilerContext(prevInjectContext);\n setActiveConsumer$1(prevConsumer);\n }\n }\n toString() {\n const tokens = [];\n const records = this.records;\n for (const token of records.keys()) {\n tokens.push(stringify(token));\n }\n return `R3Injector[${tokens.join(', ')}]`;\n }\n /**\n * Process a `SingleProvider` and add it.\n */\n processProvider(provider) {\n // Determine the token from the provider. Either it's its own token, or has a {provide: ...}\n // property.\n provider = resolveForwardRef(provider);\n let token = isTypeProvider(provider) ? provider : resolveForwardRef(provider && provider.provide);\n // Construct a `Record` for the provider.\n const record = providerToRecord(provider);\n if (ngDevMode) {\n runInInjectorProfilerContext(this, token, () => {\n // Emit InjectorProfilerEventType.Create if provider is a value provider because\n // these are the only providers that do not go through the value hydration logic\n // where this event would normally be emitted from.\n if (isValueProvider(provider)) {\n emitInstanceCreatedByInjectorEvent(provider.useValue);\n }\n emitProviderConfiguredEvent(provider);\n });\n }\n if (!isTypeProvider(provider) && provider.multi === true) {\n // If the provider indicates that it's a multi-provider, process it specially.\n // First check whether it's been defined already.\n let multiRecord = this.records.get(token);\n if (multiRecord) {\n // It has. Throw a nice error if\n if (ngDevMode && multiRecord.multi === undefined) {\n throwMixedMultiProviderError();\n }\n } else {\n multiRecord = makeRecord(undefined, NOT_YET, true);\n multiRecord.factory = () => injectArgs(multiRecord.multi);\n this.records.set(token, multiRecord);\n }\n token = provider;\n multiRecord.multi.push(provider);\n } else {\n if (ngDevMode) {\n const existing = this.records.get(token);\n if (existing && existing.multi !== undefined) {\n throwMixedMultiProviderError();\n }\n }\n }\n this.records.set(token, record);\n }\n hydrate(token, record) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n if (record.value === CIRCULAR) {\n throwCyclicDependencyError(stringify(token));\n } else if (record.value === NOT_YET) {\n record.value = CIRCULAR;\n if (ngDevMode) {\n runInInjectorProfilerContext(this, token, () => {\n record.value = record.factory();\n emitInstanceCreatedByInjectorEvent(record.value);\n });\n } else {\n record.value = record.factory();\n }\n }\n if (typeof record.value === 'object' && record.value && hasOnDestroy(record.value)) {\n this._ngOnDestroyHooks.add(record.value);\n }\n return record.value;\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n injectableDefInScope(def) {\n if (!def.providedIn) {\n return false;\n }\n const providedIn = resolveForwardRef(def.providedIn);\n if (typeof providedIn === 'string') {\n return providedIn === 'any' || this.scopes.has(providedIn);\n } else {\n return this.injectorDefTypes.has(providedIn);\n }\n }\n removeOnDestroy(callback) {\n const destroyCBIdx = this._onDestroyHooks.indexOf(callback);\n if (destroyCBIdx !== -1) {\n this._onDestroyHooks.splice(destroyCBIdx, 1);\n }\n }\n}\nfunction injectableDefOrInjectorDefFactory(token) {\n // Most tokens will have an injectable def directly on them, which specifies a factory directly.\n const injectableDef = getInjectableDef(token);\n const factory = injectableDef !== null ? injectableDef.factory : getFactoryDef(token);\n if (factory !== null) {\n return factory;\n }\n // InjectionTokens should have an injectable def (ɵprov) and thus should be handled above.\n // If it's missing that, it's an error.\n if (token instanceof InjectionToken) {\n throw new RuntimeError(204 /* RuntimeErrorCode.INVALID_INJECTION_TOKEN */, ngDevMode && `Token ${stringify(token)} is missing a ɵprov definition.`);\n }\n // Undecorated types can sometimes be created if they have no constructor arguments.\n if (token instanceof Function) {\n return getUndecoratedInjectableFactory(token);\n }\n // There was no way to resolve a factory for this token.\n throw new RuntimeError(204 /* RuntimeErrorCode.INVALID_INJECTION_TOKEN */, ngDevMode && 'unreachable');\n}\nfunction getUndecoratedInjectableFactory(token) {\n // If the token has parameters then it has dependencies that we cannot resolve implicitly.\n const paramLength = token.length;\n if (paramLength > 0) {\n throw new RuntimeError(204 /* RuntimeErrorCode.INVALID_INJECTION_TOKEN */, ngDevMode && `Can't resolve all parameters for ${stringify(token)}: (${newArray(paramLength, '?').join(', ')}).`);\n }\n // The constructor function appears to have no parameters.\n // This might be because it inherits from a super-class. In which case, use an injectable\n // def from an ancestor if there is one.\n // Otherwise this really is a simple class with no dependencies, so return a factory that\n // just instantiates the zero-arg constructor.\n const inheritedInjectableDef = getInheritedInjectableDef(token);\n if (inheritedInjectableDef !== null) {\n return () => inheritedInjectableDef.factory(token);\n } else {\n return () => new token();\n }\n}\nfunction providerToRecord(provider) {\n if (isValueProvider(provider)) {\n return makeRecord(undefined, provider.useValue);\n } else {\n const factory = providerToFactory(provider);\n return makeRecord(factory, NOT_YET);\n }\n}\n/**\n * Converts a `SingleProvider` into a factory function.\n *\n * @param provider provider to convert to factory\n */\nfunction providerToFactory(provider, ngModuleType, providers) {\n let factory = undefined;\n if (ngDevMode && isEnvironmentProviders(provider)) {\n throwInvalidProviderError(undefined, providers, provider);\n }\n if (isTypeProvider(provider)) {\n const unwrappedProvider = resolveForwardRef(provider);\n return getFactoryDef(unwrappedProvider) || injectableDefOrInjectorDefFactory(unwrappedProvider);\n } else {\n if (isValueProvider(provider)) {\n factory = () => resolveForwardRef(provider.useValue);\n } else if (isFactoryProvider(provider)) {\n factory = () => provider.useFactory(...injectArgs(provider.deps || []));\n } else if (isExistingProvider(provider)) {\n factory = () => ɵɵinject(resolveForwardRef(provider.useExisting));\n } else {\n const classRef = resolveForwardRef(provider && (provider.useClass || provider.provide));\n if (ngDevMode && !classRef) {\n throwInvalidProviderError(ngModuleType, providers, provider);\n }\n if (hasDeps(provider)) {\n factory = () => new classRef(...injectArgs(provider.deps));\n } else {\n return getFactoryDef(classRef) || injectableDefOrInjectorDefFactory(classRef);\n }\n }\n }\n return factory;\n}\nfunction assertNotDestroyed(injector) {\n if (injector.destroyed) {\n throw new RuntimeError(205 /* RuntimeErrorCode.INJECTOR_ALREADY_DESTROYED */, ngDevMode && 'Injector has already been destroyed.');\n }\n}\nfunction makeRecord(factory, value, multi = false) {\n return {\n factory: factory,\n value: value,\n multi: multi ? [] : undefined\n };\n}\nfunction hasDeps(value) {\n return !!value.deps;\n}\nfunction hasOnDestroy(value) {\n return value !== null && typeof value === 'object' && typeof value.ngOnDestroy === 'function';\n}\nfunction couldBeInjectableType(value) {\n return typeof value === 'function' || typeof value === 'object' && value instanceof InjectionToken;\n}\nfunction forEachSingleProvider(providers, fn) {\n for (const provider of providers) {\n if (Array.isArray(provider)) {\n forEachSingleProvider(provider, fn);\n } else if (provider && isEnvironmentProviders(provider)) {\n forEachSingleProvider(provider.ɵproviders, fn);\n } else {\n fn(provider);\n }\n }\n}\n\n/**\n * Runs the given function in the [context](guide/di/dependency-injection-context) of the given\n * `Injector`.\n *\n * Within the function's stack frame, [`inject`](api/core/inject) can be used to inject dependencies\n * from the given `Injector`. Note that `inject` is only usable synchronously, and cannot be used in\n * any asynchronous callbacks or after any `await` points.\n *\n * @param injector the injector which will satisfy calls to [`inject`](api/core/inject) while `fn`\n * is executing\n * @param fn the closure to be run in the context of `injector`\n * @returns the return value of the function, if any\n * @publicApi\n */\nfunction runInInjectionContext(injector, fn) {\n if (injector instanceof R3Injector) {\n assertNotDestroyed(injector);\n }\n let prevInjectorProfilerContext;\n if (ngDevMode) {\n prevInjectorProfilerContext = setInjectorProfilerContext({\n injector,\n token: null\n });\n }\n const prevInjector = setCurrentInjector(injector);\n const previousInjectImplementation = setInjectImplementation(undefined);\n try {\n return fn();\n } finally {\n setCurrentInjector(prevInjector);\n ngDevMode && setInjectorProfilerContext(prevInjectorProfilerContext);\n setInjectImplementation(previousInjectImplementation);\n }\n}\n/**\n * Whether the current stack frame is inside an injection context.\n */\nfunction isInInjectionContext() {\n return getInjectImplementation() !== undefined || getCurrentInjector() != null;\n}\n/**\n * Asserts that the current stack frame is within an [injection\n * context](guide/di/dependency-injection-context) and has access to `inject`.\n *\n * @param debugFn a reference to the function making the assertion (used for the error message).\n *\n * @publicApi\n */\nfunction assertInInjectionContext(debugFn) {\n // Taking a `Function` instead of a string name here prevents the unminified name of the function\n // from being retained in the bundle regardless of minification.\n if (!isInInjectionContext()) {\n throw new RuntimeError(-203 /* RuntimeErrorCode.MISSING_INJECTION_CONTEXT */, ngDevMode && debugFn.name + '() can only be used within an injection context such as a constructor, a factory function, a field initializer, or a function used with `runInInjectionContext`');\n }\n}\nvar FactoryTarget;\n(function (FactoryTarget) {\n FactoryTarget[FactoryTarget[\"Directive\"] = 0] = \"Directive\";\n FactoryTarget[FactoryTarget[\"Component\"] = 1] = \"Component\";\n FactoryTarget[FactoryTarget[\"Injectable\"] = 2] = \"Injectable\";\n FactoryTarget[FactoryTarget[\"Pipe\"] = 3] = \"Pipe\";\n FactoryTarget[FactoryTarget[\"NgModule\"] = 4] = \"NgModule\";\n})(FactoryTarget || (FactoryTarget = {}));\nvar R3TemplateDependencyKind;\n(function (R3TemplateDependencyKind) {\n R3TemplateDependencyKind[R3TemplateDependencyKind[\"Directive\"] = 0] = \"Directive\";\n R3TemplateDependencyKind[R3TemplateDependencyKind[\"Pipe\"] = 1] = \"Pipe\";\n R3TemplateDependencyKind[R3TemplateDependencyKind[\"NgModule\"] = 2] = \"NgModule\";\n})(R3TemplateDependencyKind || (R3TemplateDependencyKind = {}));\nvar ViewEncapsulation$1;\n(function (ViewEncapsulation) {\n ViewEncapsulation[ViewEncapsulation[\"Emulated\"] = 0] = \"Emulated\";\n // Historically the 1 value was for `Native` encapsulation which has been removed as of v11.\n ViewEncapsulation[ViewEncapsulation[\"None\"] = 2] = \"None\";\n ViewEncapsulation[ViewEncapsulation[\"ShadowDom\"] = 3] = \"ShadowDom\";\n})(ViewEncapsulation$1 || (ViewEncapsulation$1 = {}));\nfunction getCompilerFacade(request) {\n const globalNg = _global['ng'];\n if (globalNg && globalNg.ɵcompilerFacade) {\n return globalNg.ɵcompilerFacade;\n }\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n // Log the type as an error so that a developer can easily navigate to the type from the\n // console.\n console.error(`JIT compilation failed for ${request.kind}`, request.type);\n let message = `The ${request.kind} '${request.type.name}' needs to be compiled using the JIT compiler, but '@angular/compiler' is not available.\\n\\n`;\n if (request.usage === 1 /* JitCompilerUsage.PartialDeclaration */) {\n message += `The ${request.kind} is part of a library that has been partially compiled.\\n`;\n message += `However, the Angular Linker has not processed the library such that JIT compilation is used as fallback.\\n`;\n message += '\\n';\n message += `Ideally, the library is processed using the Angular Linker to become fully AOT compiled.\\n`;\n } else {\n message += `JIT compilation is discouraged for production use-cases! Consider using AOT mode instead.\\n`;\n }\n message += `Alternatively, the JIT compiler should be loaded by bootstrapping using '@angular/platform-browser-dynamic' or '@angular/platform-server',\\n`;\n message += `or manually provide the compiler with 'import \"@angular/compiler\";' before bootstrapping.`;\n throw new Error(message);\n } else {\n throw new Error('JIT compiler unavailable');\n }\n}\n\n/**\n * A mapping of the @angular/core API surface used in generated expressions to the actual symbols.\n *\n * This should be kept up to date with the public exports of @angular/core.\n */\nconst angularCoreDiEnv = {\n 'ɵɵdefineInjectable': ɵɵdefineInjectable,\n 'ɵɵdefineInjector': ɵɵdefineInjector,\n 'ɵɵinject': ɵɵinject,\n 'ɵɵinvalidFactoryDep': ɵɵinvalidFactoryDep,\n 'resolveForwardRef': resolveForwardRef\n};\n\n/**\n * @description\n *\n * Represents a type that a Component or other object is instances of.\n *\n * An example of a `Type` is `MyCustomComponent` class, which in JavaScript is represented by\n * the `MyCustomComponent` constructor function.\n *\n * @publicApi\n */\nconst Type = Function;\nfunction isType(v) {\n return typeof v === 'function';\n}\n\n/*\n * #########################\n * Attention: These Regular expressions have to hold even if the code is minified!\n * ##########################\n */\n/**\n * Regular expression that detects pass-through constructors for ES5 output. This Regex\n * intends to capture the common delegation pattern emitted by TypeScript and Babel. Also\n * it intends to capture the pattern where existing constructors have been downleveled from\n * ES2015 to ES5 using TypeScript w/ downlevel iteration. e.g.\n *\n * ```ts\n * function MyClass() {\n * var _this = _super.apply(this, arguments) || this;\n * ```\n *\n * downleveled to ES5 with `downlevelIteration` for TypeScript < 4.2:\n * ```ts\n * function MyClass() {\n * var _this = _super.apply(this, __spread(arguments)) || this;\n * ```\n *\n * or downleveled to ES5 with `downlevelIteration` for TypeScript >= 4.2:\n * ```ts\n * function MyClass() {\n * var _this = _super.apply(this, __spreadArray([], __read(arguments), false)) || this;\n * ```\n *\n * More details can be found in: https://github.com/angular/angular/issues/38453.\n */\nconst ES5_DELEGATE_CTOR = /^function\\s+\\S+\\(\\)\\s*{[\\s\\S]+\\.apply\\(this,\\s*(arguments|(?:[^()]+\\(\\[\\],)?[^()]+\\(arguments\\).*)\\)/;\n/** Regular expression that detects ES2015 classes which extend from other classes. */\nconst ES2015_INHERITED_CLASS = /^class\\s+[A-Za-z\\d$_]*\\s*extends\\s+[^{]+{/;\n/**\n * Regular expression that detects ES2015 classes which extend from other classes and\n * have an explicit constructor defined.\n */\nconst ES2015_INHERITED_CLASS_WITH_CTOR = /^class\\s+[A-Za-z\\d$_]*\\s*extends\\s+[^{]+{[\\s\\S]*constructor\\s*\\(/;\n/**\n * Regular expression that detects ES2015 classes which extend from other classes\n * and inherit a constructor.\n */\nconst ES2015_INHERITED_CLASS_WITH_DELEGATE_CTOR = /^class\\s+[A-Za-z\\d$_]*\\s*extends\\s+[^{]+{[\\s\\S]*constructor\\s*\\(\\)\\s*{[^}]*super\\(\\.\\.\\.arguments\\)/;\n/**\n * Determine whether a stringified type is a class which delegates its constructor\n * to its parent.\n *\n * This is not trivial since compiled code can actually contain a constructor function\n * even if the original source code did not. For instance, when the child class contains\n * an initialized instance property.\n */\nfunction isDelegateCtor(typeStr) {\n 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);\n}\nclass ReflectionCapabilities {\n _reflect;\n constructor(reflect) {\n this._reflect = reflect || _global['Reflect'];\n }\n factory(t) {\n return (...args) => new t(...args);\n }\n /** @internal */\n _zipTypesAndAnnotations(paramTypes, paramAnnotations) {\n let result;\n if (typeof paramTypes === 'undefined') {\n result = newArray(paramAnnotations.length);\n } else {\n result = newArray(paramTypes.length);\n }\n for (let i = 0; i < result.length; i++) {\n // TS outputs Object for parameters without types, while Traceur omits\n // the annotations. For now we preserve the Traceur behavior to aid\n // migration, but this can be revisited.\n if (typeof paramTypes === 'undefined') {\n result[i] = [];\n } else if (paramTypes[i] && paramTypes[i] != Object) {\n result[i] = [paramTypes[i]];\n } else {\n result[i] = [];\n }\n if (paramAnnotations && paramAnnotations[i] != null) {\n result[i] = result[i].concat(paramAnnotations[i]);\n }\n }\n return result;\n }\n _ownParameters(type, parentCtor) {\n const typeStr = type.toString();\n // If we have no decorators, we only have function.length as metadata.\n // In that case, to detect whether a child class declared an own constructor or not,\n // we need to look inside of that constructor to check whether it is\n // just calling the parent.\n // This also helps to work around for https://github.com/Microsoft/TypeScript/issues/12439\n // that sets 'design:paramtypes' to []\n // if a class inherits from another class but has no ctor declared itself.\n if (isDelegateCtor(typeStr)) {\n return null;\n }\n // Prefer the direct API.\n if (type.parameters && type.parameters !== parentCtor.parameters) {\n return type.parameters;\n }\n // API of tsickle for lowering decorators to properties on the class.\n const tsickleCtorParams = type.ctorParameters;\n if (tsickleCtorParams && tsickleCtorParams !== parentCtor.ctorParameters) {\n // Newer tsickle uses a function closure\n // Retain the non-function case for compatibility with older tsickle\n const ctorParameters = typeof tsickleCtorParams === 'function' ? tsickleCtorParams() : tsickleCtorParams;\n const paramTypes = ctorParameters.map(ctorParam => ctorParam && ctorParam.type);\n const paramAnnotations = ctorParameters.map(ctorParam => ctorParam && convertTsickleDecoratorIntoMetadata(ctorParam.decorators));\n return this._zipTypesAndAnnotations(paramTypes, paramAnnotations);\n }\n // API for metadata created by invoking the decorators.\n const paramAnnotations = type.hasOwnProperty(PARAMETERS) && type[PARAMETERS];\n const paramTypes = this._reflect && this._reflect.getOwnMetadata && this._reflect.getOwnMetadata('design:paramtypes', type);\n if (paramTypes || paramAnnotations) {\n return this._zipTypesAndAnnotations(paramTypes, paramAnnotations);\n }\n // If a class has no decorators, at least create metadata\n // based on function.length.\n // Note: We know that this is a real constructor as we checked\n // the content of the constructor above.\n return newArray(type.length);\n }\n parameters(type) {\n // Note: only report metadata if we have at least one class decorator\n // to stay in sync with the static reflector.\n if (!isType(type)) {\n return [];\n }\n const parentCtor = getParentCtor(type);\n let parameters = this._ownParameters(type, parentCtor);\n if (!parameters && parentCtor !== Object) {\n parameters = this.parameters(parentCtor);\n }\n return parameters || [];\n }\n _ownAnnotations(typeOrFunc, parentCtor) {\n // Prefer the direct API.\n if (typeOrFunc.annotations && typeOrFunc.annotations !== parentCtor.annotations) {\n let annotations = typeOrFunc.annotations;\n if (typeof annotations === 'function' && annotations.annotations) {\n annotations = annotations.annotations;\n }\n return annotations;\n }\n // API of tsickle for lowering decorators to properties on the class.\n if (typeOrFunc.decorators && typeOrFunc.decorators !== parentCtor.decorators) {\n return convertTsickleDecoratorIntoMetadata(typeOrFunc.decorators);\n }\n // API for metadata created by invoking the decorators.\n if (typeOrFunc.hasOwnProperty(ANNOTATIONS)) {\n return typeOrFunc[ANNOTATIONS];\n }\n return null;\n }\n annotations(typeOrFunc) {\n if (!isType(typeOrFunc)) {\n return [];\n }\n const parentCtor = getParentCtor(typeOrFunc);\n const ownAnnotations = this._ownAnnotations(typeOrFunc, parentCtor) || [];\n const parentAnnotations = parentCtor !== Object ? this.annotations(parentCtor) : [];\n return parentAnnotations.concat(ownAnnotations);\n }\n _ownPropMetadata(typeOrFunc, parentCtor) {\n // Prefer the direct API.\n if (typeOrFunc.propMetadata && typeOrFunc.propMetadata !== parentCtor.propMetadata) {\n let propMetadata = typeOrFunc.propMetadata;\n if (typeof propMetadata === 'function' && propMetadata.propMetadata) {\n propMetadata = propMetadata.propMetadata;\n }\n return propMetadata;\n }\n // API of tsickle for lowering decorators to properties on the class.\n if (typeOrFunc.propDecorators && typeOrFunc.propDecorators !== parentCtor.propDecorators) {\n const propDecorators = typeOrFunc.propDecorators;\n const propMetadata = {};\n Object.keys(propDecorators).forEach(prop => {\n propMetadata[prop] = convertTsickleDecoratorIntoMetadata(propDecorators[prop]);\n });\n return propMetadata;\n }\n // API for metadata created by invoking the decorators.\n if (typeOrFunc.hasOwnProperty(PROP_METADATA)) {\n return typeOrFunc[PROP_METADATA];\n }\n return null;\n }\n propMetadata(typeOrFunc) {\n if (!isType(typeOrFunc)) {\n return {};\n }\n const parentCtor = getParentCtor(typeOrFunc);\n const propMetadata = {};\n if (parentCtor !== Object) {\n const parentPropMetadata = this.propMetadata(parentCtor);\n Object.keys(parentPropMetadata).forEach(propName => {\n propMetadata[propName] = parentPropMetadata[propName];\n });\n }\n const ownPropMetadata = this._ownPropMetadata(typeOrFunc, parentCtor);\n if (ownPropMetadata) {\n Object.keys(ownPropMetadata).forEach(propName => {\n const decorators = [];\n if (propMetadata.hasOwnProperty(propName)) {\n decorators.push(...propMetadata[propName]);\n }\n decorators.push(...ownPropMetadata[propName]);\n propMetadata[propName] = decorators;\n });\n }\n return propMetadata;\n }\n ownPropMetadata(typeOrFunc) {\n if (!isType(typeOrFunc)) {\n return {};\n }\n return this._ownPropMetadata(typeOrFunc, getParentCtor(typeOrFunc)) || {};\n }\n hasLifecycleHook(type, lcProperty) {\n return type instanceof Type && lcProperty in type.prototype;\n }\n}\nfunction convertTsickleDecoratorIntoMetadata(decoratorInvocations) {\n if (!decoratorInvocations) {\n return [];\n }\n return decoratorInvocations.map(decoratorInvocation => {\n const decoratorType = decoratorInvocation.type;\n const annotationCls = decoratorType.annotationCls;\n const annotationArgs = decoratorInvocation.args ? decoratorInvocation.args : [];\n return new annotationCls(...annotationArgs);\n });\n}\nfunction getParentCtor(ctor) {\n const parentProto = ctor.prototype ? Object.getPrototypeOf(ctor.prototype) : null;\n const parentCtor = parentProto ? parentProto.constructor : null;\n // Note: We always use `Object` as the null value\n // to simplify checking later on.\n return parentCtor || Object;\n}\n\n// Below are constants for LView indices to help us look up LView members\n// without having to remember the specific indices.\n// Uglify will inline these when minifying so there shouldn't be a cost.\nconst HOST = 0;\nconst TVIEW = 1;\n// Shared with LContainer\nconst FLAGS = 2;\nconst PARENT = 3;\nconst NEXT = 4;\nconst T_HOST = 5;\n// End shared with LContainer\nconst HYDRATION = 6;\nconst CLEANUP = 7;\nconst CONTEXT = 8;\nconst INJECTOR = 9;\nconst ENVIRONMENT = 10;\nconst RENDERER = 11;\nconst CHILD_HEAD = 12;\nconst CHILD_TAIL = 13;\n// FIXME(misko): Investigate if the three declarations aren't all same thing.\nconst DECLARATION_VIEW = 14;\nconst DECLARATION_COMPONENT_VIEW = 15;\nconst DECLARATION_LCONTAINER = 16;\nconst PREORDER_HOOK_FLAGS = 17;\nconst QUERIES = 18;\nconst ID = 19;\nconst EMBEDDED_VIEW_INJECTOR = 20;\nconst ON_DESTROY_HOOKS = 21;\nconst EFFECTS_TO_SCHEDULE = 22;\nconst EFFECTS = 23;\nconst REACTIVE_TEMPLATE_CONSUMER = 24;\nconst AFTER_RENDER_SEQUENCES_TO_ADD = 25;\n/**\n * Size of LView's header. Necessary to adjust for it when setting slots.\n *\n * IMPORTANT: `HEADER_OFFSET` should only be referred to the in the `ɵɵ*` instructions to translate\n * instruction index into `LView` index. All other indexes should be in the `LView` index space and\n * there should be no need to refer to `HEADER_OFFSET` anywhere else.\n */\nconst HEADER_OFFSET = 26;\n\n/**\n * Special location which allows easy identification of type. If we have an array which was\n * retrieved from the `LView` and that array has `true` at `TYPE` location, we know it is\n * `LContainer`.\n */\nconst TYPE = 1;\n/**\n * Below are constants for LContainer indices to help us look up LContainer members\n * without having to remember the specific indices.\n * Uglify will inline these when minifying so there shouldn't be a cost.\n */\n// FLAGS, PARENT, NEXT, and T_HOST are indices 2, 3, 4, and 5\n// As we already have these constants in LView, we don't need to re-create them.\nconst DEHYDRATED_VIEWS = 6;\nconst NATIVE = 7;\nconst VIEW_REFS = 8;\nconst MOVED_VIEWS = 9;\n/**\n * Size of LContainer's header. Represents the index after which all views in the\n * container will be inserted. We need to keep a record of current views so we know\n * which views are already in the DOM (and don't need to be re-added) and so we can\n * remove views from the DOM when they are no longer required.\n */\nconst CONTAINER_HEADER_OFFSET = 10;\n\n/**\n * True if `value` is `LView`.\n * @param value wrapped value of `RNode`, `LView`, `LContainer`\n */\nfunction isLView(value) {\n return Array.isArray(value) && typeof value[TYPE] === 'object';\n}\n/**\n * True if `value` is `LContainer`.\n * @param value wrapped value of `RNode`, `LView`, `LContainer`\n */\nfunction isLContainer(value) {\n return Array.isArray(value) && value[TYPE] === true;\n}\nfunction isContentQueryHost(tNode) {\n return (tNode.flags & 4 /* TNodeFlags.hasContentQuery */) !== 0;\n}\nfunction isComponentHost(tNode) {\n return tNode.componentOffset > -1;\n}\nfunction isDirectiveHost(tNode) {\n return (tNode.flags & 1 /* TNodeFlags.isDirectiveHost */) === 1 /* TNodeFlags.isDirectiveHost */;\n}\nfunction isComponentDef(def) {\n return !!def.template;\n}\nfunction isRootView(target) {\n // Determines whether a given LView is marked as a root view.\n return (target[FLAGS] & 512 /* LViewFlags.IsRoot */) !== 0;\n}\nfunction isProjectionTNode(tNode) {\n return (tNode.type & 16 /* TNodeType.Projection */) === 16 /* TNodeType.Projection */;\n}\nfunction hasI18n(lView) {\n return (lView[FLAGS] & 32 /* LViewFlags.HasI18n */) === 32 /* LViewFlags.HasI18n */;\n}\nfunction isDestroyed(lView) {\n // Determines whether a given LView is marked as destroyed.\n return (lView[FLAGS] & 256 /* LViewFlags.Destroyed */) === 256 /* LViewFlags.Destroyed */;\n}\n\n// [Assert functions do not constraint type when they are guarded by a truthy\n// expression.](https://github.com/microsoft/TypeScript/issues/37295)\nfunction assertTNodeForLView(tNode, lView) {\n assertTNodeForTView(tNode, lView[TVIEW]);\n}\nfunction assertTNodeForTView(tNode, tView) {\n assertTNode(tNode);\n const tData = tView.data;\n for (let i = HEADER_OFFSET; i < tData.length; i++) {\n if (tData[i] === tNode) {\n return;\n }\n }\n throwError('This TNode does not belong to this TView.');\n}\nfunction assertTNode(tNode) {\n assertDefined(tNode, 'TNode must be defined');\n if (!(tNode && typeof tNode === 'object' && tNode.hasOwnProperty('directiveStylingLast'))) {\n throwError('Not of type TNode, got: ' + tNode);\n }\n}\nfunction assertTIcu(tIcu) {\n assertDefined(tIcu, 'Expected TIcu to be defined');\n if (!(typeof tIcu.currentCaseLViewIndex === 'number')) {\n throwError('Object is not of TIcu type.');\n }\n}\nfunction assertComponentType(actual, msg = \"Type passed in is not ComponentType, it does not have 'ɵcmp' property.\") {\n if (!getComponentDef(actual)) {\n throwError(msg);\n }\n}\nfunction assertNgModuleType(actual, msg = \"Type passed in is not NgModuleType, it does not have 'ɵmod' property.\") {\n if (!getNgModuleDef(actual)) {\n throwError(msg);\n }\n}\nfunction assertCurrentTNodeIsParent(isParent) {\n assertEqual(isParent, true, 'currentTNode should be a parent');\n}\nfunction assertHasParent(tNode) {\n assertDefined(tNode, 'currentTNode should exist!');\n assertDefined(tNode.parent, 'currentTNode should have a parent');\n}\nfunction assertLContainer(value) {\n assertDefined(value, 'LContainer must be defined');\n assertEqual(isLContainer(value), true, 'Expecting LContainer');\n}\nfunction assertLViewOrUndefined(value) {\n value && assertEqual(isLView(value), true, 'Expecting LView or undefined or null');\n}\nfunction assertLView(value) {\n assertDefined(value, 'LView must be defined');\n assertEqual(isLView(value), true, 'Expecting LView');\n}\nfunction assertFirstCreatePass(tView, errMessage) {\n assertEqual(tView.firstCreatePass, true, errMessage || 'Should only be called in first create pass.');\n}\nfunction assertFirstUpdatePass(tView, errMessage) {\n assertEqual(tView.firstUpdatePass, true, errMessage || 'Should only be called in first update pass.');\n}\n/**\n * This is a basic sanity check that an object is probably a directive def. DirectiveDef is\n * an interface, so we can't do a direct instanceof check.\n */\nfunction assertDirectiveDef(obj) {\n if (obj.type === undefined || obj.selectors == undefined || obj.inputs === undefined) {\n throwError(`Expected a DirectiveDef/ComponentDef and this object does not seem to have the expected shape.`);\n }\n}\nfunction assertIndexInDeclRange(tView, index) {\n assertBetween(HEADER_OFFSET, tView.bindingStartIndex, index);\n}\nfunction assertIndexInExpandoRange(lView, index) {\n const tView = lView[1];\n assertBetween(tView.expandoStartIndex, lView.length, index);\n}\nfunction assertBetween(lower, upper, index) {\n if (!(lower <= index && index < upper)) {\n throwError(`Index out of range (expecting ${lower} <= ${index} < ${upper})`);\n }\n}\nfunction assertProjectionSlots(lView, errMessage) {\n assertDefined(lView[DECLARATION_COMPONENT_VIEW], 'Component views should exist.');\n assertDefined(lView[DECLARATION_COMPONENT_VIEW][T_HOST].projection, errMessage || 'Components with projection nodes (<ng-content>) must have projection slots defined.');\n}\nfunction assertParentView(lView, errMessage) {\n assertDefined(lView, errMessage || \"Component views should always have a parent view (component's host view)\");\n}\nfunction assertNoDuplicateDirectives$1(directives) {\n // The array needs at least two elements in order to have duplicates.\n if (directives.length < 2) {\n return;\n }\n const seenDirectives = new Set();\n for (const current of directives) {\n if (seenDirectives.has(current)) {\n throw new RuntimeError(309 /* RuntimeErrorCode.DUPLICATE_DIRECTIVE */, `Directive ${current.type.name} matches multiple times on the same element. ` + `Directives can only match an element once.`);\n }\n seenDirectives.add(current);\n }\n}\n/**\n * This is a basic sanity check that the `injectorIndex` seems to point to what looks like a\n * NodeInjector data structure.\n *\n * @param lView `LView` which should be checked.\n * @param injectorIndex index into the `LView` where the `NodeInjector` is expected.\n */\nfunction assertNodeInjector(lView, injectorIndex) {\n assertIndexInExpandoRange(lView, injectorIndex);\n assertIndexInExpandoRange(lView, injectorIndex + 8 /* NodeInjectorOffset.PARENT */);\n assertNumber(lView[injectorIndex + 0], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 1], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 2], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 3], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 4], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 5], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 6], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 7], 'injectorIndex should point to a bloom filter');\n assertNumber(lView[injectorIndex + 8 /* NodeInjectorOffset.PARENT */], 'injectorIndex should point to parent injector');\n}\n\n/**\n * Represents a basic change from a previous to a new value for a single\n * property on a directive instance. Passed as a value in a\n * {@link SimpleChanges} object to the `ngOnChanges` hook.\n *\n * @see {@link OnChanges}\n *\n * @publicApi\n */\nclass SimpleChange {\n previousValue;\n currentValue;\n firstChange;\n constructor(previousValue, currentValue, firstChange) {\n this.previousValue = previousValue;\n this.currentValue = currentValue;\n this.firstChange = firstChange;\n }\n /**\n * Check whether the new value is the first value assigned.\n */\n isFirstChange() {\n return this.firstChange;\n }\n}\nfunction applyValueToInputField(instance, inputSignalNode, privateName, value) {\n if (inputSignalNode !== null) {\n inputSignalNode.applyValueToInputSignal(inputSignalNode, value);\n } else {\n instance[privateName] = value;\n }\n}\n\n/**\n * The NgOnChangesFeature decorates a component with support for the ngOnChanges\n * lifecycle hook, so it should be included in any component that implements\n * that hook.\n *\n * If the component or directive uses inheritance, the NgOnChangesFeature MUST\n * be included as a feature AFTER {@link InheritDefinitionFeature}, otherwise\n * inherited properties will not be propagated to the ngOnChanges lifecycle\n * hook.\n *\n * Example usage:\n *\n * ```ts\n * static ɵcmp = defineComponent({\n * ...\n * inputs: {name: 'publicName'},\n * features: [NgOnChangesFeature]\n * });\n * ```\n *\n * @codeGenApi\n */\nconst ɵɵNgOnChangesFeature = /* @__PURE__ */(() => {\n const ɵɵNgOnChangesFeatureImpl = () => NgOnChangesFeatureImpl;\n // This option ensures that the ngOnChanges lifecycle hook will be inherited\n // from superclasses (in InheritDefinitionFeature).\n /** @nocollapse */\n ɵɵNgOnChangesFeatureImpl.ngInherit = true;\n return ɵɵNgOnChangesFeatureImpl;\n})();\nfunction NgOnChangesFeatureImpl(definition) {\n if (definition.type.prototype.ngOnChanges) {\n definition.setInput = ngOnChangesSetInput;\n }\n return rememberChangeHistoryAndInvokeOnChangesHook;\n}\n/**\n * This is a synthetic lifecycle hook which gets inserted into `TView.preOrderHooks` to simulate\n * `ngOnChanges`.\n *\n * The hook reads the `NgSimpleChangesStore` data from the component instance and if changes are\n * found it invokes `ngOnChanges` on the component instance.\n *\n * @param this Component instance. Because this function gets inserted into `TView.preOrderHooks`,\n * it is guaranteed to be called with component instance.\n */\nfunction rememberChangeHistoryAndInvokeOnChangesHook() {\n const simpleChangesStore = getSimpleChangesStore(this);\n const current = simpleChangesStore?.current;\n if (current) {\n const previous = simpleChangesStore.previous;\n if (previous === EMPTY_OBJ) {\n simpleChangesStore.previous = current;\n } else {\n // New changes are copied to the previous store, so that we don't lose history for inputs\n // which were not changed this time\n for (let key in current) {\n previous[key] = current[key];\n }\n }\n simpleChangesStore.current = null;\n this.ngOnChanges(current);\n }\n}\nfunction ngOnChangesSetInput(instance, inputSignalNode, value, publicName, privateName) {\n const declaredName = this.declaredInputs[publicName];\n ngDevMode && assertString(declaredName, 'Name of input in ngOnChanges has to be a string');\n const simpleChangesStore = getSimpleChangesStore(instance) || setSimpleChangesStore(instance, {\n previous: EMPTY_OBJ,\n current: null\n });\n const current = simpleChangesStore.current || (simpleChangesStore.current = {});\n const previous = simpleChangesStore.previous;\n const previousChange = previous[declaredName];\n current[declaredName] = new SimpleChange(previousChange && previousChange.currentValue, value, previous === EMPTY_OBJ);\n applyValueToInputField(instance, inputSignalNode, privateName, value);\n}\nconst SIMPLE_CHANGES_STORE = '__ngSimpleChanges__';\nfunction getSimpleChangesStore(instance) {\n return instance[SIMPLE_CHANGES_STORE] || null;\n}\nfunction setSimpleChangesStore(instance, store) {\n return instance[SIMPLE_CHANGES_STORE] = store;\n}\nlet profilerCallback = null;\n/**\n * Sets the callback function which will be invoked before and after performing certain actions at\n * runtime (for example, before and after running change detection).\n *\n * Warning: this function is *INTERNAL* and should not be relied upon in application's code.\n * The contract of the function might be changed in any release and/or the function can be removed\n * completely.\n *\n * @param profiler function provided by the caller or null value to disable profiling.\n */\nconst setProfiler = profiler => {\n profilerCallback = profiler;\n};\n/**\n * Profiler function which wraps user code executed by the runtime.\n *\n * @param event ProfilerEvent corresponding to the execution context\n * @param instance component instance\n * @param hookOrListener lifecycle hook function or output listener. The value depends on the\n * execution context\n * @returns\n */\nconst profiler = function (event, instance = null, hookOrListener) {\n if (profilerCallback != null /* both `null` and `undefined` */) {\n profilerCallback(event, instance, hookOrListener);\n }\n};\nconst SVG_NAMESPACE = 'svg';\nconst MATH_ML_NAMESPACE = 'math';\n\n/**\n * For efficiency reasons we often put several different data types (`RNode`, `LView`, `LContainer`)\n * in same location in `LView`. This is because we don't want to pre-allocate space for it\n * because the storage is sparse. This file contains utilities for dealing with such data types.\n *\n * How do we know what is stored at a given location in `LView`.\n * - `Array.isArray(value) === false` => `RNode` (The normal storage value)\n * - `Array.isArray(value) === true` => then the `value[0]` represents the wrapped value.\n * - `typeof value[TYPE] === 'object'` => `LView`\n * - This happens when we have a component at a given location\n * - `typeof value[TYPE] === true` => `LContainer`\n * - This happens when we have `LContainer` binding at a given location.\n *\n *\n * NOTE: it is assumed that `Array.isArray` and `typeof` operations are very efficient.\n */\n/**\n * Returns `RNode`.\n * @param value wrapped value of `RNode`, `LView`, `LContainer`\n */\nfunction unwrapRNode(value) {\n while (Array.isArray(value)) {\n value = value[HOST];\n }\n return value;\n}\n/**\n * Returns `LView` or `null` if not found.\n * @param value wrapped value of `RNode`, `LView`, `LContainer`\n */\nfunction unwrapLView(value) {\n while (Array.isArray(value)) {\n // This check is same as `isLView()` but we don't call at as we don't want to call\n // `Array.isArray()` twice and give JITer more work for inlining.\n if (typeof value[TYPE] === 'object') return value;\n value = value[HOST];\n }\n return null;\n}\n/**\n * Retrieves an element value from the provided `viewData`, by unwrapping\n * from any containers, component views, or style contexts.\n */\nfunction getNativeByIndex(index, lView) {\n ngDevMode && assertIndexInRange(lView, index);\n ngDevMode && assertGreaterThanOrEqual(index, HEADER_OFFSET, 'Expected to be past HEADER_OFFSET');\n return unwrapRNode(lView[index]);\n}\n/**\n * Retrieve an `RNode` for a given `TNode` and `LView`.\n *\n * This function guarantees in dev mode to retrieve a non-null `RNode`.\n *\n * @param tNode\n * @param lView\n */\nfunction getNativeByTNode(tNode, lView) {\n ngDevMode && assertTNodeForLView(tNode, lView);\n ngDevMode && assertIndexInRange(lView, tNode.index);\n const node = unwrapRNode(lView[tNode.index]);\n return node;\n}\n/**\n * Retrieve an `RNode` or `null` for a given `TNode` and `LView`.\n *\n * Some `TNode`s don't have associated `RNode`s. For example `Projection`\n *\n * @param tNode\n * @param lView\n */\nfunction getNativeByTNodeOrNull(tNode, lView) {\n const index = tNode === null ? -1 : tNode.index;\n if (index !== -1) {\n ngDevMode && assertTNodeForLView(tNode, lView);\n const node = unwrapRNode(lView[index]);\n return node;\n }\n return null;\n}\n// fixme(misko): The return Type should be `TNode|null`\nfunction getTNode(tView, index) {\n ngDevMode && assertGreaterThan(index, -1, 'wrong index for TNode');\n ngDevMode && assertLessThan(index, tView.data.length, 'wrong index for TNode');\n const tNode = tView.data[index];\n ngDevMode && tNode !== null && assertTNode(tNode);\n return tNode;\n}\n/** Retrieves a value from any `LView` or `TData`. */\nfunction load(view, index) {\n ngDevMode && assertIndexInRange(view, index);\n return view[index];\n}\nfunction getComponentLViewByIndex(nodeIndex, hostView) {\n // Could be an LView or an LContainer. If LContainer, unwrap to find LView.\n ngDevMode && assertIndexInRange(hostView, nodeIndex);\n const slotValue = hostView[nodeIndex];\n const lView = isLView(slotValue) ? slotValue : slotValue[HOST];\n return lView;\n}\n/** Checks whether a given view is in creation mode */\nfunction isCreationMode(view) {\n return (view[FLAGS] & 4 /* LViewFlags.CreationMode */) === 4 /* LViewFlags.CreationMode */;\n}\n/**\n * Returns a boolean for whether the view is attached to the change detection tree.\n *\n * Note: This determines whether a view should be checked, not whether it's inserted\n * into a container. For that, you'll want `viewAttachedToContainer` below.\n */\nfunction viewAttachedToChangeDetector(view) {\n return (view[FLAGS] & 128 /* LViewFlags.Attached */) === 128 /* LViewFlags.Attached */;\n}\n/** Returns a boolean for whether the view is attached to a container. */\nfunction viewAttachedToContainer(view) {\n return isLContainer(view[PARENT]);\n}\nfunction getConstant(consts, index) {\n if (index === null || index === undefined) return null;\n ngDevMode && assertIndexInRange(consts, index);\n return consts[index];\n}\n/**\n * Resets the pre-order hook flags of the view.\n * @param lView the LView on which the flags are reset\n */\nfunction resetPreOrderHookFlags(lView) {\n lView[PREORDER_HOOK_FLAGS] = 0;\n}\n/**\n * Adds the `RefreshView` flag from the lView and updates HAS_CHILD_VIEWS_TO_REFRESH flag of\n * parents.\n */\nfunction markViewForRefresh(lView) {\n if (lView[FLAGS] & 1024 /* LViewFlags.RefreshView */) {\n return;\n }\n lView[FLAGS] |= 1024 /* LViewFlags.RefreshView */;\n if (viewAttachedToChangeDetector(lView)) {\n markAncestorsForTraversal(lView);\n }\n}\n/**\n * Walks up the LView hierarchy.\n * @param nestingLevel Number of times to walk up in hierarchy.\n * @param currentView View from which to start the lookup.\n */\nfunction walkUpViews(nestingLevel, currentView) {\n while (nestingLevel > 0) {\n ngDevMode && assertDefined(currentView[DECLARATION_VIEW], 'Declaration view should be defined if nesting level is greater than 0.');\n currentView = currentView[DECLARATION_VIEW];\n nestingLevel--;\n }\n return currentView;\n}\nfunction requiresRefreshOrTraversal(lView) {\n return !!(lView[FLAGS] & (1024 /* LViewFlags.RefreshView */ | 8192 /* LViewFlags.HasChildViewsToRefresh */) || lView[REACTIVE_TEMPLATE_CONSUMER]?.dirty);\n}\n/**\n * Updates the `HasChildViewsToRefresh` flag on the parents of the `LView` as well as the\n * parents above.\n */\nfunction updateAncestorTraversalFlagsOnAttach(lView) {\n lView[ENVIRONMENT].changeDetectionScheduler?.notify(8 /* NotificationSource.ViewAttached */);\n if (lView[FLAGS] & 64 /* LViewFlags.Dirty */) {\n lView[FLAGS] |= 1024 /* LViewFlags.RefreshView */;\n }\n if (requiresRefreshOrTraversal(lView)) {\n markAncestorsForTraversal(lView);\n }\n}\n/**\n * Ensures views above the given `lView` are traversed during change detection even when they are\n * not dirty.\n *\n * This is done by setting the `HAS_CHILD_VIEWS_TO_REFRESH` flag up to the root, stopping when the\n * flag is already `true` or the `lView` is detached.\n */\nfunction markAncestorsForTraversal(lView) {\n lView[ENVIRONMENT].changeDetectionScheduler?.notify(0 /* NotificationSource.MarkAncestorsForTraversal */);\n let parent = getLViewParent(lView);\n while (parent !== null) {\n // We stop adding markers to the ancestors once we reach one that already has the marker. This\n // is to avoid needlessly traversing all the way to the root when the marker already exists.\n if (parent[FLAGS] & 8192 /* LViewFlags.HasChildViewsToRefresh */) {\n break;\n }\n parent[FLAGS] |= 8192 /* LViewFlags.HasChildViewsToRefresh */;\n if (!viewAttachedToChangeDetector(parent)) {\n break;\n }\n parent = getLViewParent(parent);\n }\n}\n/**\n * Stores a LView-specific destroy callback.\n */\nfunction storeLViewOnDestroy(lView, onDestroyCallback) {\n if (isDestroyed(lView)) {\n throw new RuntimeError(911 /* RuntimeErrorCode.VIEW_ALREADY_DESTROYED */, ngDevMode && 'View has already been destroyed.');\n }\n if (lView[ON_DESTROY_HOOKS] === null) {\n lView[ON_DESTROY_HOOKS] = [];\n }\n lView[ON_DESTROY_HOOKS].push(onDestroyCallback);\n}\n/**\n * Removes previously registered LView-specific destroy callback.\n */\nfunction removeLViewOnDestroy(lView, onDestroyCallback) {\n if (lView[ON_DESTROY_HOOKS] === null) return;\n const destroyCBIdx = lView[ON_DESTROY_HOOKS].indexOf(onDestroyCallback);\n if (destroyCBIdx !== -1) {\n lView[ON_DESTROY_HOOKS].splice(destroyCBIdx, 1);\n }\n}\n/**\n * Gets the parent LView of the passed LView, if the PARENT is an LContainer, will get the parent of\n * that LContainer, which is an LView\n * @param lView the lView whose parent to get\n */\nfunction getLViewParent(lView) {\n ngDevMode && assertLView(lView);\n const parent = lView[PARENT];\n return isLContainer(parent) ? parent[PARENT] : parent;\n}\nfunction getOrCreateLViewCleanup(view) {\n // top level variables should not be exported for performance reasons (PERF_NOTES.md)\n return view[CLEANUP] ??= [];\n}\nfunction getOrCreateTViewCleanup(tView) {\n return tView.cleanup ??= [];\n}\n/**\n * Saves context for this cleanup function in LView.cleanupInstances.\n *\n * On the first template pass, saves in TView:\n * - Cleanup function\n * - Index of context we just saved in LView.cleanupInstances\n */\nfunction storeCleanupWithContext(tView, lView, context, cleanupFn) {\n const lCleanup = getOrCreateLViewCleanup(lView);\n // Historically the `storeCleanupWithContext` was used to register both framework-level and\n // user-defined cleanup callbacks, but over time those two types of cleanups were separated.\n // This dev mode checks assures that user-level cleanup callbacks are _not_ stored in data\n // structures reserved for framework-specific hooks.\n ngDevMode && assertDefined(context, 'Cleanup context is mandatory when registering framework-level destroy hooks');\n lCleanup.push(context);\n if (tView.firstCreatePass) {\n getOrCreateTViewCleanup(tView).push(cleanupFn, lCleanup.length - 1);\n } else {\n // Make sure that no new framework-level cleanup functions are registered after the first\n // template pass is done (and TView data structures are meant to fully constructed).\n if (ngDevMode) {\n Object.freeze(getOrCreateTViewCleanup(tView));\n }\n }\n}\nconst instructionState = {\n lFrame: createLFrame(null),\n bindingsEnabled: true,\n skipHydrationRootTNode: null\n};\nvar CheckNoChangesMode;\n(function (CheckNoChangesMode) {\n CheckNoChangesMode[CheckNoChangesMode[\"Off\"] = 0] = \"Off\";\n CheckNoChangesMode[CheckNoChangesMode[\"Exhaustive\"] = 1] = \"Exhaustive\";\n CheckNoChangesMode[CheckNoChangesMode[\"OnlyDirtyViews\"] = 2] = \"OnlyDirtyViews\";\n})(CheckNoChangesMode || (CheckNoChangesMode = {}));\n/**\n * In this mode, any changes in bindings will throw an ExpressionChangedAfterChecked error.\n *\n * Necessary to support ChangeDetectorRef.checkNoChanges().\n *\n * The `checkNoChanges` function is invoked only in ngDevMode=true and verifies that no unintended\n * changes exist in the change detector or its children.\n */\nlet _checkNoChangesMode = 0; /* CheckNoChangesMode.Off */\n/**\n * Flag used to indicate that we are in the middle running change detection on a view\n *\n * @see detectChangesInViewWhileDirty\n */\nlet _isRefreshingViews = false;\n/**\n * Returns true if the instruction state stack is empty.\n *\n * Intended to be called from tests only (tree shaken otherwise).\n */\nfunction specOnlyIsInstructionStateEmpty() {\n return instructionState.lFrame.parent === null;\n}\nfunction getElementDepthCount() {\n return instructionState.lFrame.elementDepthCount;\n}\nfunction increaseElementDepthCount() {\n instructionState.lFrame.elementDepthCount++;\n}\nfunction decreaseElementDepthCount() {\n instructionState.lFrame.elementDepthCount--;\n}\nfunction getBindingsEnabled() {\n return instructionState.bindingsEnabled;\n}\n/**\n * Returns true if currently inside a skip hydration block.\n * @returns boolean\n */\nfunction isInSkipHydrationBlock$1() {\n return instructionState.skipHydrationRootTNode !== null;\n}\n/**\n * Returns true if this is the root TNode of the skip hydration block.\n * @param tNode the current TNode\n * @returns boolean\n */\nfunction isSkipHydrationRootTNode(tNode) {\n return instructionState.skipHydrationRootTNode === tNode;\n}\n/**\n * Enables directive matching on elements.\n *\n * * Example:\n * ```html\n * <my-comp my-directive>\n * Should match component / directive.\n * </my-comp>\n * <div ngNonBindable>\n * <!-- ɵɵdisableBindings() -->\n * <my-comp my-directive>\n * Should not match component / directive because we are in ngNonBindable.\n * </my-comp>\n * <!-- ɵɵenableBindings() -->\n * </div>\n * ```\n *\n * @codeGenApi\n */\nfunction ɵɵenableBindings() {\n instructionState.bindingsEnabled = true;\n}\n/**\n * Sets a flag to specify that the TNode is in a skip hydration block.\n * @param tNode the current TNode\n */\nfunction enterSkipHydrationBlock(tNode) {\n instructionState.skipHydrationRootTNode = tNode;\n}\n/**\n * Disables directive matching on element.\n *\n * * Example:\n * ```html\n * <my-comp my-directive>\n * Should match component / directive.\n * </my-comp>\n * <div ngNonBindable>\n * <!-- ɵɵdisableBindings() -->\n * <my-comp my-directive>\n * Should not match component / directive because we are in ngNonBindable.\n * </my-comp>\n * <!-- ɵɵenableBindings() -->\n * </div>\n * ```\n *\n * @codeGenApi\n */\nfunction ɵɵdisableBindings() {\n instructionState.bindingsEnabled = false;\n}\n/**\n * Clears the root skip hydration node when leaving a skip hydration block.\n */\nfunction leaveSkipHydrationBlock() {\n instructionState.skipHydrationRootTNode = null;\n}\n/**\n * Return the current `LView`.\n */\nfunction getLView() {\n return instructionState.lFrame.lView;\n}\n/**\n * Return the current `TView`.\n */\nfunction getTView() {\n return instructionState.lFrame.tView;\n}\n/**\n * Restores `contextViewData` to the given OpaqueViewState instance.\n *\n * Used in conjunction with the getCurrentView() instruction to save a snapshot\n * of the current view and restore it when listeners are invoked. This allows\n * walking the declaration view tree in listeners to get vars from parent views.\n *\n * @param viewToRestore The OpaqueViewState instance to restore.\n * @returns Context of the restored OpaqueViewState instance.\n *\n * @codeGenApi\n */\nfunction ɵɵrestoreView(viewToRestore) {\n instructionState.lFrame.contextLView = viewToRestore;\n return viewToRestore[CONTEXT];\n}\n/**\n * Clears the view set in `ɵɵrestoreView` from memory. Returns the passed in\n * value so that it can be used as a return value of an instruction.\n *\n * @codeGenApi\n */\nfunction ɵɵresetView(value) {\n instructionState.lFrame.contextLView = null;\n return value;\n}\nfunction getCurrentTNode() {\n let currentTNode = getCurrentTNodePlaceholderOk();\n while (currentTNode !== null && currentTNode.type === 64 /* TNodeType.Placeholder */) {\n currentTNode = currentTNode.parent;\n }\n return currentTNode;\n}\nfunction getCurrentTNodePlaceholderOk() {\n return instructionState.lFrame.currentTNode;\n}\nfunction getCurrentParentTNode() {\n const lFrame = instructionState.lFrame;\n const currentTNode = lFrame.currentTNode;\n return lFrame.isParent ? currentTNode : currentTNode.parent;\n}\nfunction setCurrentTNode(tNode, isParent) {\n ngDevMode && tNode && assertTNodeForTView(tNode, instructionState.lFrame.tView);\n const lFrame = instructionState.lFrame;\n lFrame.currentTNode = tNode;\n lFrame.isParent = isParent;\n}\nfunction isCurrentTNodeParent() {\n return instructionState.lFrame.isParent;\n}\nfunction setCurrentTNodeAsNotParent() {\n instructionState.lFrame.isParent = false;\n}\nfunction getContextLView() {\n const contextLView = instructionState.lFrame.contextLView;\n ngDevMode && assertDefined(contextLView, 'contextLView must be defined.');\n return contextLView;\n}\nfunction isInCheckNoChangesMode() {\n !ngDevMode && throwError('Must never be called in production mode');\n return _checkNoChangesMode !== CheckNoChangesMode.Off;\n}\nfunction isExhaustiveCheckNoChanges() {\n !ngDevMode && throwError('Must never be called in production mode');\n return _checkNoChangesMode === CheckNoChangesMode.Exhaustive;\n}\nfunction setIsInCheckNoChangesMode(mode) {\n !ngDevMode && throwError('Must never be called in production mode');\n _checkNoChangesMode = mode;\n}\nfunction isRefreshingViews() {\n return _isRefreshingViews;\n}\nfunction setIsRefreshingViews(mode) {\n const prev = _isRefreshingViews;\n _isRefreshingViews = mode;\n return prev;\n}\n// top level variables should not be exported for performance reasons (PERF_NOTES.md)\nfunction getBindingRoot() {\n const lFrame = instructionState.lFrame;\n let index = lFrame.bindingRootIndex;\n if (index === -1) {\n index = lFrame.bindingRootIndex = lFrame.tView.bindingStartIndex;\n }\n return index;\n}\nfunction getBindingIndex() {\n return instructionState.lFrame.bindingIndex;\n}\nfunction setBindingIndex(value) {\n return instructionState.lFrame.bindingIndex = value;\n}\nfunction nextBindingIndex() {\n return instructionState.lFrame.bindingIndex++;\n}\nfunction incrementBindingIndex(count) {\n const lFrame = instructionState.lFrame;\n const index = lFrame.bindingIndex;\n lFrame.bindingIndex = lFrame.bindingIndex + count;\n return index;\n}\nfunction isInI18nBlock() {\n return instructionState.lFrame.inI18n;\n}\nfunction setInI18nBlock(isInI18nBlock) {\n instructionState.lFrame.inI18n = isInI18nBlock;\n}\n/**\n * Set a new binding root index so that host template functions can execute.\n *\n * Bindings inside the host template are 0 index. But because we don't know ahead of time\n * how many host bindings we have we can't pre-compute them. For this reason they are all\n * 0 index and we just shift the root so that they match next available location in the LView.\n *\n * @param bindingRootIndex Root index for `hostBindings`\n * @param currentDirectiveIndex `TData[currentDirectiveIndex]` will point to the current directive\n * whose `hostBindings` are being processed.\n */\nfunction setBindingRootForHostBindings(bindingRootIndex, currentDirectiveIndex) {\n const lFrame = instructionState.lFrame;\n lFrame.bindingIndex = lFrame.bindingRootIndex = bindingRootIndex;\n setCurrentDirectiveIndex(currentDirectiveIndex);\n}\n/**\n * When host binding is executing this points to the directive index.\n * `TView.data[getCurrentDirectiveIndex()]` is `DirectiveDef`\n * `LView[getCurrentDirectiveIndex()]` is directive instance.\n */\nfunction getCurrentDirectiveIndex() {\n return instructionState.lFrame.currentDirectiveIndex;\n}\n/**\n * Sets an index of a directive whose `hostBindings` are being processed.\n *\n * @param currentDirectiveIndex `TData` index where current directive instance can be found.\n */\nfunction setCurrentDirectiveIndex(currentDirectiveIndex) {\n instructionState.lFrame.currentDirectiveIndex = currentDirectiveIndex;\n}\n/**\n * Retrieve the current `DirectiveDef` which is active when `hostBindings` instruction is being\n * executed.\n *\n * @param tData Current `TData` where the `DirectiveDef` will be looked up at.\n */\nfunction getCurrentDirectiveDef(tData) {\n const currentDirectiveIndex = instructionState.lFrame.currentDirectiveIndex;\n return currentDirectiveIndex === -1 ? null : tData[currentDirectiveIndex];\n}\nfunction getCurrentQueryIndex() {\n return instructionState.lFrame.currentQueryIndex;\n}\nfunction setCurrentQueryIndex(value) {\n instructionState.lFrame.currentQueryIndex = value;\n}\n/**\n * Returns a `TNode` of the location where the current `LView` is declared at.\n *\n * @param lView an `LView` that we want to find parent `TNode` for.\n */\nfunction getDeclarationTNode(lView) {\n const tView = lView[TVIEW];\n // Return the declaration parent for embedded views\n if (tView.type === 2 /* TViewType.Embedded */) {\n ngDevMode && assertDefined(tView.declTNode, 'Embedded TNodes should have declaration parents.');\n return tView.declTNode;\n }\n // Components don't have `TView.declTNode` because each instance of component could be\n // inserted in different location, hence `TView.declTNode` is meaningless.\n // Falling back to `T_HOST` in case we cross component boundary.\n if (tView.type === 1 /* TViewType.Component */) {\n return lView[T_HOST];\n }\n // Remaining TNode type is `TViewType.Root` which doesn't have a parent TNode.\n return null;\n}\n/**\n * This is a light weight version of the `enterView` which is needed by the DI system.\n *\n * @param lView `LView` location of the DI context.\n * @param tNode `TNode` for DI context\n * @param flags DI context flags. if `SkipSelf` flag is set than we walk up the declaration\n * tree from `tNode` until we find parent declared `TElementNode`.\n * @returns `true` if we have successfully entered DI associated with `tNode` (or with declared\n * `TNode` if `flags` has `SkipSelf`). Failing to enter DI implies that no associated\n * `NodeInjector` can be found and we should instead use `ModuleInjector`.\n * - If `true` than this call must be fallowed by `leaveDI`\n * - If `false` than this call failed and we should NOT call `leaveDI`\n */\nfunction enterDI(lView, tNode, flags) {\n ngDevMode && assertLViewOrUndefined(lView);\n if (flags & InjectFlags.SkipSelf) {\n ngDevMode && assertTNodeForTView(tNode, lView[TVIEW]);\n let parentTNode = tNode;\n let parentLView = lView;\n while (true) {\n ngDevMode && assertDefined(parentTNode, 'Parent TNode should be defined');\n parentTNode = parentTNode.parent;\n if (parentTNode === null && !(flags & InjectFlags.Host)) {\n parentTNode = getDeclarationTNode(parentLView);\n if (parentTNode === null) break;\n // In this case, a parent exists and is definitely an element. So it will definitely\n // have an existing lView as the declaration view, which is why we can assume it's defined.\n ngDevMode && assertDefined(parentLView, 'Parent LView should be defined');\n parentLView = parentLView[DECLARATION_VIEW];\n // In Ivy there are Comment nodes that correspond to ngIf and NgFor embedded directives\n // We want to skip those and look only at Elements and ElementContainers to ensure\n // we're looking at true parent nodes, and not content or other types.\n if (parentTNode.type & (2 /* TNodeType.Element */ | 8 /* TNodeType.ElementContainer */)) {\n break;\n }\n } else {\n break;\n }\n }\n if (parentTNode === null) {\n // If we failed to find a parent TNode this means that we should use module injector.\n return false;\n } else {\n tNode = parentTNode;\n lView = parentLView;\n }\n }\n ngDevMode && assertTNodeForLView(tNode, lView);\n const lFrame = instructionState.lFrame = allocLFrame();\n lFrame.currentTNode = tNode;\n lFrame.lView = lView;\n return true;\n}\n/**\n * Swap the current lView with a new lView.\n *\n * For performance reasons we store the lView in the top level of the module.\n * This way we minimize the number of properties to read. Whenever a new view\n * is entered we have to store the lView for later, and when the view is\n * exited the state has to be restored\n *\n * @param newView New lView to become active\n * @returns the previously active lView;\n */\nfunction enterView(newView) {\n ngDevMode && assertNotEqual(newView[0], newView[1], '????');\n ngDevMode && assertLViewOrUndefined(newView);\n const newLFrame = allocLFrame();\n if (ngDevMode) {\n assertEqual(newLFrame.isParent, true, 'Expected clean LFrame');\n assertEqual(newLFrame.lView, null, 'Expected clean LFrame');\n assertEqual(newLFrame.tView, null, 'Expected clean LFrame');\n assertEqual(newLFrame.selectedIndex, -1, 'Expected clean LFrame');\n assertEqual(newLFrame.elementDepthCount, 0, 'Expected clean LFrame');\n assertEqual(newLFrame.currentDirectiveIndex, -1, 'Expected clean LFrame');\n assertEqual(newLFrame.currentNamespace, null, 'Expected clean LFrame');\n assertEqual(newLFrame.bindingRootIndex, -1, 'Expected clean LFrame');\n assertEqual(newLFrame.currentQueryIndex, 0, 'Expected clean LFrame');\n }\n const tView = newView[TVIEW];\n instructionState.lFrame = newLFrame;\n ngDevMode && tView.firstChild && assertTNodeForTView(tView.firstChild, tView);\n newLFrame.currentTNode = tView.firstChild;\n newLFrame.lView = newView;\n newLFrame.tView = tView;\n newLFrame.contextLView = newView;\n newLFrame.bindingIndex = tView.bindingStartIndex;\n newLFrame.inI18n = false;\n}\n/**\n * Allocates next free LFrame. This function tries to reuse the `LFrame`s to lower memory pressure.\n */\nfunction allocLFrame() {\n const currentLFrame = instructionState.lFrame;\n const childLFrame = currentLFrame === null ? null : currentLFrame.child;\n const newLFrame = childLFrame === null ? createLFrame(currentLFrame) : childLFrame;\n return newLFrame;\n}\nfunction createLFrame(parent) {\n const lFrame = {\n currentTNode: null,\n isParent: true,\n lView: null,\n tView: null,\n selectedIndex: -1,\n contextLView: null,\n elementDepthCount: 0,\n currentNamespace: null,\n currentDirectiveIndex: -1,\n bindingRootIndex: -1,\n bindingIndex: -1,\n currentQueryIndex: 0,\n parent: parent,\n child: null,\n inI18n: false\n };\n parent !== null && (parent.child = lFrame); // link the new LFrame for reuse.\n return lFrame;\n}\n/**\n * A lightweight version of leave which is used with DI.\n *\n * This function only resets `currentTNode` and `LView` as those are the only properties\n * used with DI (`enterDI()`).\n *\n * NOTE: This function is reexported as `leaveDI`. However `leaveDI` has return type of `void` where\n * as `leaveViewLight` has `LFrame`. This is so that `leaveViewLight` can be used in `leaveView`.\n */\nfunction leaveViewLight() {\n const oldLFrame = instructionState.lFrame;\n instructionState.lFrame = oldLFrame.parent;\n oldLFrame.currentTNode = null;\n oldLFrame.lView = null;\n return oldLFrame;\n}\n/**\n * This is a lightweight version of the `leaveView` which is needed by the DI system.\n *\n * NOTE: this function is an alias so that we can change the type of the function to have `void`\n * return type.\n */\nconst leaveDI = leaveViewLight;\n/**\n * Leave the current `LView`\n *\n * This pops the `LFrame` with the associated `LView` from the stack.\n *\n * IMPORTANT: We must zero out the `LFrame` values here otherwise they will be retained. This is\n * because for performance reasons we don't release `LFrame` but rather keep it for next use.\n */\nfunction leaveView() {\n const oldLFrame = leaveViewLight();\n oldLFrame.isParent = true;\n oldLFrame.tView = null;\n oldLFrame.selectedIndex = -1;\n oldLFrame.contextLView = null;\n oldLFrame.elementDepthCount = 0;\n oldLFrame.currentDirectiveIndex = -1;\n oldLFrame.currentNamespace = null;\n oldLFrame.bindingRootIndex = -1;\n oldLFrame.bindingIndex = -1;\n oldLFrame.currentQueryIndex = 0;\n}\nfunction nextContextImpl(level) {\n const contextLView = instructionState.lFrame.contextLView = walkUpViews(level, instructionState.lFrame.contextLView);\n return contextLView[CONTEXT];\n}\n/**\n * Gets the currently selected element index.\n *\n * Used with {@link property} instruction (and more in the future) to identify the index in the\n * current `LView` to act on.\n */\nfunction getSelectedIndex() {\n return instructionState.lFrame.selectedIndex;\n}\n/**\n * Sets the most recent index passed to {@link select}\n *\n * Used with {@link property} instruction (and more in the future) to identify the index in the\n * current `LView` to act on.\n *\n * (Note that if an \"exit function\" was set earlier (via `setElementExitFn()`) then that will be\n * run if and when the provided `index` value is different from the current selected index value.)\n */\nfunction setSelectedIndex(index) {\n ngDevMode && index !== -1 && assertGreaterThanOrEqual(index, HEADER_OFFSET, 'Index must be past HEADER_OFFSET (or -1).');\n ngDevMode && assertLessThan(index, instructionState.lFrame.lView.length, \"Can't set index passed end of LView\");\n instructionState.lFrame.selectedIndex = index;\n}\n/**\n * Gets the `tNode` that represents currently selected element.\n */\nfunction getSelectedTNode() {\n const lFrame = instructionState.lFrame;\n return getTNode(lFrame.tView, lFrame.selectedIndex);\n}\n/**\n * Sets the namespace used to create elements to `'http://www.w3.org/2000/svg'` in global state.\n *\n * @codeGenApi\n */\nfunction ɵɵnamespaceSVG() {\n instructionState.lFrame.currentNamespace = SVG_NAMESPACE;\n}\n/**\n * Sets the namespace used to create elements to `'http://www.w3.org/1998/MathML/'` in global state.\n *\n * @codeGenApi\n */\nfunction ɵɵnamespaceMathML() {\n instructionState.lFrame.currentNamespace = MATH_ML_NAMESPACE;\n}\n/**\n * Sets the namespace used to create elements to `null`, which forces element creation to use\n * `createElement` rather than `createElementNS`.\n *\n * @codeGenApi\n */\nfunction ɵɵnamespaceHTML() {\n namespaceHTMLInternal();\n}\n/**\n * Sets the namespace used to create elements to `null`, which forces element creation to use\n * `createElement` rather than `createElementNS`.\n */\nfunction namespaceHTMLInternal() {\n instructionState.lFrame.currentNamespace = null;\n}\nfunction getNamespace() {\n return instructionState.lFrame.currentNamespace;\n}\nlet _wasLastNodeCreated = true;\n/**\n * Retrieves a global flag that indicates whether the most recent DOM node\n * was created or hydrated.\n */\nfunction wasLastNodeCreated() {\n return _wasLastNodeCreated;\n}\n/**\n * Sets a global flag to indicate whether the most recent DOM node\n * was created or hydrated.\n */\nfunction lastNodeWasCreated(flag) {\n _wasLastNodeCreated = flag;\n}\n\n/**\n * Adds all directive lifecycle hooks from the given `DirectiveDef` to the given `TView`.\n *\n * Must be run *only* on the first template pass.\n *\n * Sets up the pre-order hooks on the provided `tView`,\n * see {@link HookData} for details about the data structure.\n *\n * @param directiveIndex The index of the directive in LView\n * @param directiveDef The definition containing the hooks to setup in tView\n * @param tView The current TView\n */\nfunction registerPreOrderHooks(directiveIndex, directiveDef, tView) {\n ngDevMode && assertFirstCreatePass(tView);\n const {\n ngOnChanges,\n ngOnInit,\n ngDoCheck\n } = directiveDef.type.prototype;\n if (ngOnChanges) {\n const wrappedOnChanges = NgOnChangesFeatureImpl(directiveDef);\n (tView.preOrderHooks ??= []).push(directiveIndex, wrappedOnChanges);\n (tView.preOrderCheckHooks ??= []).push(directiveIndex, wrappedOnChanges);\n }\n if (ngOnInit) {\n (tView.preOrderHooks ??= []).push(0 - directiveIndex, ngOnInit);\n }\n if (ngDoCheck) {\n (tView.preOrderHooks ??= []).push(directiveIndex, ngDoCheck);\n (tView.preOrderCheckHooks ??= []).push(directiveIndex, ngDoCheck);\n }\n}\n/**\n *\n * Loops through the directives on the provided `tNode` and queues hooks to be\n * run that are not initialization hooks.\n *\n * Should be executed during `elementEnd()` and similar to\n * preserve hook execution order. Content, view, and destroy hooks for projected\n * components and directives must be called *before* their hosts.\n *\n * Sets up the content, view, and destroy hooks on the provided `tView`,\n * see {@link HookData} for details about the data structure.\n *\n * NOTE: This does not set up `onChanges`, `onInit` or `doCheck`, those are set up\n * separately at `elementStart`.\n *\n * @param tView The current TView\n * @param tNode The TNode whose directives are to be searched for hooks to queue\n */\nfunction registerPostOrderHooks(tView, tNode) {\n ngDevMode && assertFirstCreatePass(tView);\n // It's necessary to loop through the directives at elementEnd() (rather than processing in\n // directiveCreate) so we can preserve the current hook order. Content, view, and destroy\n // hooks for projected components and directives must be called *before* their hosts.\n for (let i = tNode.directiveStart, end = tNode.directiveEnd; i < end; i++) {\n const directiveDef = tView.data[i];\n ngDevMode && assertDefined(directiveDef, 'Expecting DirectiveDef');\n const lifecycleHooks = directiveDef.type.prototype;\n const {\n ngAfterContentInit,\n ngAfterContentChecked,\n ngAfterViewInit,\n ngAfterViewChecked,\n ngOnDestroy\n } = lifecycleHooks;\n if (ngAfterContentInit) {\n (tView.contentHooks ??= []).push(-i, ngAfterContentInit);\n }\n if (ngAfterContentChecked) {\n (tView.contentHooks ??= []).push(i, ngAfterContentChecked);\n (tView.contentCheckHooks ??= []).push(i, ngAfterContentChecked);\n }\n if (ngAfterViewInit) {\n (tView.viewHooks ??= []).push(-i, ngAfterViewInit);\n }\n if (ngAfterViewChecked) {\n (tView.viewHooks ??= []).push(i, ngAfterViewChecked);\n (tView.viewCheckHooks ??= []).push(i, ngAfterViewChecked);\n }\n if (ngOnDestroy != null) {\n (tView.destroyHooks ??= []).push(i, ngOnDestroy);\n }\n }\n}\n/**\n * Executing hooks requires complex logic as we need to deal with 2 constraints.\n *\n * 1. Init hooks (ngOnInit, ngAfterContentInit, ngAfterViewInit) must all be executed once and only\n * once, across many change detection cycles. This must be true even if some hooks throw, or if\n * some recursively trigger a change detection cycle.\n * To solve that, it is required to track the state of the execution of these init hooks.\n * This is done by storing and maintaining flags in the view: the {@link InitPhaseState},\n * and the index within that phase. They can be seen as a cursor in the following structure:\n * [[onInit1, onInit2], [afterContentInit1], [afterViewInit1, afterViewInit2, afterViewInit3]]\n * They are stored as flags in LView[FLAGS].\n *\n * 2. Pre-order hooks can be executed in batches, because of the select instruction.\n * To be able to pause and resume their execution, we also need some state about the hook's array\n * that is being processed:\n * - the index of the next hook to be executed\n * - the number of init hooks already found in the processed part of the array\n * They are stored as flags in LView[PREORDER_HOOK_FLAGS].\n */\n/**\n * Executes pre-order check hooks ( OnChanges, DoChanges) given a view where all the init hooks were\n * executed once. This is a light version of executeInitAndCheckPreOrderHooks where we can skip read\n * / write of the init-hooks related flags.\n * @param lView The LView where hooks are defined\n * @param hooks Hooks to be run\n * @param nodeIndex 3 cases depending on the value:\n * - undefined: all hooks from the array should be executed (post-order case)\n * - null: execute hooks only from the saved index until the end of the array (pre-order case, when\n * flushing the remaining hooks)\n * - number: execute hooks only from the saved index until that node index exclusive (pre-order\n * case, when executing select(number))\n */\nfunction executeCheckHooks(lView, hooks, nodeIndex) {\n callHooks(lView, hooks, 3 /* InitPhaseState.InitPhaseCompleted */, nodeIndex);\n}\n/**\n * Executes post-order init and check hooks (one of AfterContentInit, AfterContentChecked,\n * AfterViewInit, AfterViewChecked) given a view where there are pending init hooks to be executed.\n * @param lView The LView where hooks are defined\n * @param hooks Hooks to be run\n * @param initPhase A phase for which hooks should be run\n * @param nodeIndex 3 cases depending on the value:\n * - undefined: all hooks from the array should be executed (post-order case)\n * - null: execute hooks only from the saved index until the end of the array (pre-order case, when\n * flushing the remaining hooks)\n * - number: execute hooks only from the saved index until that node index exclusive (pre-order\n * case, when executing select(number))\n */\nfunction executeInitAndCheckHooks(lView, hooks, initPhase, nodeIndex) {\n ngDevMode && assertNotEqual(initPhase, 3 /* InitPhaseState.InitPhaseCompleted */, 'Init pre-order hooks should not be called more than once');\n if ((lView[FLAGS] & 3 /* LViewFlags.InitPhaseStateMask */) === initPhase) {\n callHooks(lView, hooks, initPhase, nodeIndex);\n }\n}\nfunction incrementInitPhaseFlags(lView, initPhase) {\n ngDevMode && assertNotEqual(initPhase, 3 /* InitPhaseState.InitPhaseCompleted */, 'Init hooks phase should not be incremented after all init hooks have been run.');\n let flags = lView[FLAGS];\n if ((flags & 3 /* LViewFlags.InitPhaseStateMask */) === initPhase) {\n flags &= 16383 /* LViewFlags.IndexWithinInitPhaseReset */;\n flags += 1 /* LViewFlags.InitPhaseStateIncrementer */;\n lView[FLAGS] = flags;\n }\n}\n/**\n * Calls lifecycle hooks with their contexts, skipping init hooks if it's not\n * the first LView pass\n *\n * @param currentView The current view\n * @param arr The array in which the hooks are found\n * @param initPhaseState the current state of the init phase\n * @param currentNodeIndex 3 cases depending on the value:\n * - undefined: all hooks from the array should be executed (post-order case)\n * - null: execute hooks only from the saved index until the end of the array (pre-order case, when\n * flushing the remaining hooks)\n * - number: execute hooks only from the saved index until that node index exclusive (pre-order\n * case, when executing select(number))\n */\nfunction callHooks(currentView, arr, initPhase, currentNodeIndex) {\n ngDevMode && assertEqual(isInCheckNoChangesMode(), false, 'Hooks should never be run when in check no changes mode.');\n const startIndex = currentNodeIndex !== undefined ? currentView[PREORDER_HOOK_FLAGS] & 65535 /* PreOrderHookFlags.IndexOfTheNextPreOrderHookMaskMask */ : 0;\n const nodeIndexLimit = currentNodeIndex != null ? currentNodeIndex : -1;\n const max = arr.length - 1; // Stop the loop at length - 1, because we look for the hook at i + 1\n let lastNodeIndexFound = 0;\n for (let i = startIndex; i < max; i++) {\n const hook = arr[i + 1];\n if (typeof hook === 'number') {\n lastNodeIndexFound = arr[i];\n if (currentNodeIndex != null && lastNodeIndexFound >= currentNodeIndex) {\n break;\n }\n } else {\n const isInitHook = arr[i] < 0;\n if (isInitHook) {\n currentView[PREORDER_HOOK_FLAGS] += 65536 /* PreOrderHookFlags.NumberOfInitHooksCalledIncrementer */;\n }\n if (lastNodeIndexFound < nodeIndexLimit || nodeIndexLimit == -1) {\n callHook(currentView, initPhase, arr, i);\n currentView[PREORDER_HOOK_FLAGS] = (currentView[PREORDER_HOOK_FLAGS] & 4294901760 /* PreOrderHookFlags.NumberOfInitHooksCalledMask */) + i + 2;\n }\n i++;\n }\n }\n}\n/**\n * Executes a single lifecycle hook, making sure that:\n * - it is called in the non-reactive context;\n * - profiling data are registered.\n */\nfunction callHookInternal(directive, hook) {\n profiler(4 /* ProfilerEvent.LifecycleHookStart */, directive, hook);\n const prevConsumer = setActiveConsumer$1(null);\n try {\n hook.call(directive);\n } finally {\n setActiveConsumer$1(prevConsumer);\n profiler(5 /* ProfilerEvent.LifecycleHookEnd */, directive, hook);\n }\n}\n/**\n * Execute one hook against the current `LView`.\n *\n * @param currentView The current view\n * @param initPhaseState the current state of the init phase\n * @param arr The array in which the hooks are found\n * @param i The current index within the hook data array\n */\nfunction callHook(currentView, initPhase, arr, i) {\n const isInitHook = arr[i] < 0;\n const hook = arr[i + 1];\n const directiveIndex = isInitHook ? -arr[i] : arr[i];\n const directive = currentView[directiveIndex];\n if (isInitHook) {\n const indexWithintInitPhase = currentView[FLAGS] >> 14 /* LViewFlags.IndexWithinInitPhaseShift */;\n // The init phase state must be always checked here as it may have been recursively updated.\n if (indexWithintInitPhase < currentView[PREORDER_HOOK_FLAGS] >> 16 /* PreOrderHookFlags.NumberOfInitHooksCalledShift */ && (currentView[FLAGS] & 3 /* LViewFlags.InitPhaseStateMask */) === initPhase) {\n currentView[FLAGS] += 16384 /* LViewFlags.IndexWithinInitPhaseIncrementer */;\n callHookInternal(directive, hook);\n }\n } else {\n callHookInternal(directive, hook);\n }\n}\nconst NO_PARENT_INJECTOR = -1;\n/**\n * Each injector is saved in 9 contiguous slots in `LView` and 9 contiguous slots in\n * `TView.data`. This allows us to store information about the current node's tokens (which\n * can be shared in `TView`) as well as the tokens of its ancestor nodes (which cannot be\n * shared, so they live in `LView`).\n *\n * Each of these slots (aside from the last slot) contains a bloom filter. This bloom filter\n * determines whether a directive is available on the associated node or not. This prevents us\n * from searching the directives array at this level unless it's probable the directive is in it.\n *\n * See: https://en.wikipedia.org/wiki/Bloom_filter for more about bloom filters.\n *\n * Because all injectors have been flattened into `LView` and `TViewData`, they cannot typed\n * using interfaces as they were previously. The start index of each `LInjector` and `TInjector`\n * will differ based on where it is flattened into the main array, so it's not possible to know\n * the indices ahead of time and save their types here. The interfaces are still included here\n * for documentation purposes.\n *\n * export interface LInjector extends Array<any> {\n *\n * // Cumulative bloom for directive IDs 0-31 (IDs are % BLOOM_SIZE)\n * [0]: number;\n *\n * // Cumulative bloom for directive IDs 32-63\n * [1]: number;\n *\n * // Cumulative bloom for directive IDs 64-95\n * [2]: number;\n *\n * // Cumulative bloom for directive IDs 96-127\n * [3]: number;\n *\n * // Cumulative bloom for directive IDs 128-159\n * [4]: number;\n *\n * // Cumulative bloom for directive IDs 160 - 191\n * [5]: number;\n *\n * // Cumulative bloom for directive IDs 192 - 223\n * [6]: number;\n *\n * // Cumulative bloom for directive IDs 224 - 255\n * [7]: number;\n *\n * // We need to store a reference to the injector's parent so DI can keep looking up\n * // the injector tree until it finds the dependency it's looking for.\n * [PARENT_INJECTOR]: number;\n * }\n *\n * export interface TInjector extends Array<any> {\n *\n * // Shared node bloom for directive IDs 0-31 (IDs are % BLOOM_SIZE)\n * [0]: number;\n *\n * // Shared node bloom for directive IDs 32-63\n * [1]: number;\n *\n * // Shared node bloom for directive IDs 64-95\n * [2]: number;\n *\n * // Shared node bloom for directive IDs 96-127\n * [3]: number;\n *\n * // Shared node bloom for directive IDs 128-159\n * [4]: number;\n *\n * // Shared node bloom for directive IDs 160 - 191\n * [5]: number;\n *\n * // Shared node bloom for directive IDs 192 - 223\n * [6]: number;\n *\n * // Shared node bloom for directive IDs 224 - 255\n * [7]: number;\n *\n * // Necessary to find directive indices for a particular node.\n * [TNODE]: TElementNode|TElementContainerNode|TContainerNode;\n * }\n */\n/**\n * Factory for creating instances of injectors in the NodeInjector.\n *\n * This factory is complicated by the fact that it can resolve `multi` factories as well.\n *\n * NOTE: Some of the fields are optional which means that this class has two hidden classes.\n * - One without `multi` support (most common)\n * - One with `multi` values, (rare).\n *\n * Since VMs can cache up to 4 inline hidden classes this is OK.\n *\n * - Single factory: Only `resolving` and `factory` is defined.\n * - `providers` factory: `componentProviders` is a number and `index = -1`.\n * - `viewProviders` factory: `componentProviders` is a number and `index` points to `providers`.\n */\nclass NodeInjectorFactory {\n factory;\n /**\n * The inject implementation to be activated when using the factory.\n */\n injectImpl;\n /**\n * Marker set to true during factory invocation to see if we get into recursive loop.\n * Recursive loop causes an error to be displayed.\n */\n resolving = false;\n /**\n * Marks that the token can see other Tokens declared in `viewProviders` on the same node.\n */\n canSeeViewProviders;\n /**\n * An array of factories to use in case of `multi` provider.\n */\n multi;\n /**\n * Number of `multi`-providers which belong to the component.\n *\n * This is needed because when multiple components and directives declare the `multi` provider\n * they have to be concatenated in the correct order.\n *\n * Example:\n *\n * If we have a component and directive active an a single element as declared here\n * ```ts\n * component:\n * providers: [ {provide: String, useValue: 'component', multi: true} ],\n * viewProviders: [ {provide: String, useValue: 'componentView', multi: true} ],\n *\n * directive:\n * providers: [ {provide: String, useValue: 'directive', multi: true} ],\n * ```\n *\n * Then the expected results are:\n *\n * ```ts\n * providers: ['component', 'directive']\n * viewProviders: ['component', 'componentView', 'directive']\n * ```\n *\n * The way to think about it is that the `viewProviders` have been inserted after the component\n * but before the directives, which is why we need to know how many `multi`s have been declared by\n * the component.\n */\n componentProviders;\n /**\n * Current index of the Factory in the `data`. Needed for `viewProviders` and `providers` merging.\n * See `providerFactory`.\n */\n index;\n /**\n * Because the same `multi` provider can be declared in `providers` and `viewProviders` it is\n * possible for `viewProviders` to shadow the `providers`. For this reason we store the\n * `provideFactory` of the `providers` so that `providers` can be extended with `viewProviders`.\n *\n * Example:\n *\n * Given:\n * ```ts\n * providers: [ {provide: String, useValue: 'all', multi: true} ],\n * viewProviders: [ {provide: String, useValue: 'viewOnly', multi: true} ],\n * ```\n *\n * We have to return `['all']` in case of content injection, but `['all', 'viewOnly']` in case\n * of view injection. We further have to make sure that the shared instances (in our case\n * `all`) are the exact same instance in both the content as well as the view injection. (We\n * have to make sure that we don't double instantiate.) For this reason the `viewProviders`\n * `Factory` has a pointer to the shadowed `providers` factory so that it can instantiate the\n * `providers` (`['all']`) and then extend it with `viewProviders` (`['all'] + ['viewOnly'] =\n * ['all', 'viewOnly']`).\n */\n providerFactory;\n constructor(\n /**\n * Factory to invoke in order to create a new instance.\n */\n factory,\n /**\n * Set to `true` if the token is declared in `viewProviders` (or if it is component).\n */\n isViewProvider, injectImplementation) {\n this.factory = factory;\n ngDevMode && assertDefined(factory, 'Factory not specified');\n ngDevMode && assertEqual(typeof factory, 'function', 'Expected factory function.');\n this.canSeeViewProviders = isViewProvider;\n this.injectImpl = injectImplementation;\n }\n}\n\n/**\n * Converts `TNodeType` into human readable text.\n * Make sure this matches with `TNodeType`\n */\nfunction toTNodeTypeAsString(tNodeType) {\n let text = '';\n tNodeType & 1 /* TNodeType.Text */ && (text += '|Text');\n tNodeType & 2 /* TNodeType.Element */ && (text += '|Element');\n tNodeType & 4 /* TNodeType.Container */ && (text += '|Container');\n tNodeType & 8 /* TNodeType.ElementContainer */ && (text += '|ElementContainer');\n tNodeType & 16 /* TNodeType.Projection */ && (text += '|Projection');\n tNodeType & 32 /* TNodeType.Icu */ && (text += '|IcuContainer');\n tNodeType & 64 /* TNodeType.Placeholder */ && (text += '|Placeholder');\n tNodeType & 128 /* TNodeType.LetDeclaration */ && (text += '|LetDeclaration');\n return text.length > 0 ? text.substring(1) : text;\n}\n/**\n * Helper function to detect if a given value matches a `TNode` shape.\n *\n * The logic uses the `insertBeforeIndex` and its possible values as\n * a way to differentiate a TNode shape from other types of objects\n * within the `TView.data`. This is not a perfect check, but it can\n * be a reasonable differentiator, since we control the shapes of objects\n * within `TView.data`.\n */\nfunction isTNodeShape(value) {\n return value != null && typeof value === 'object' && (value.insertBeforeIndex === null || typeof value.insertBeforeIndex === 'number' || Array.isArray(value.insertBeforeIndex));\n}\nfunction isLetDeclaration(tNode) {\n return !!(tNode.type & 128 /* TNodeType.LetDeclaration */);\n}\n/**\n * Returns `true` if the `TNode` has a directive which has `@Input()` for `class` binding.\n *\n * ```html\n * <div my-dir [class]=\"exp\"></div>\n * ```\n * and\n * ```ts\n * @Directive({\n * })\n * class MyDirective {\n * @Input()\n * class: string;\n * }\n * ```\n *\n * In the above case it is necessary to write the reconciled styling information into the\n * directive's input.\n *\n * @param tNode\n */\nfunction hasClassInput(tNode) {\n return (tNode.flags & 8 /* TNodeFlags.hasClassInput */) !== 0;\n}\n/**\n * Returns `true` if the `TNode` has a directive which has `@Input()` for `style` binding.\n *\n * ```html\n * <div my-dir [style]=\"exp\"></div>\n * ```\n * and\n * ```ts\n * @Directive({\n * })\n * class MyDirective {\n * @Input()\n * class: string;\n * }\n * ```\n *\n * In the above case it is necessary to write the reconciled styling information into the\n * directive's input.\n *\n * @param tNode\n */\nfunction hasStyleInput(tNode) {\n return (tNode.flags & 16 /* TNodeFlags.hasStyleInput */) !== 0;\n}\nfunction assertTNodeType(tNode, expectedTypes, message) {\n assertDefined(tNode, 'should be called with a TNode');\n if ((tNode.type & expectedTypes) === 0) {\n throwError(message || `Expected [${toTNodeTypeAsString(expectedTypes)}] but got ${toTNodeTypeAsString(tNode.type)}.`);\n }\n}\nfunction assertPureTNodeType(type) {\n if (!(type === 2 /* TNodeType.Element */ || type === 1 /* TNodeType.Text */ || type === 4 /* TNodeType.Container */ || type === 8 /* TNodeType.ElementContainer */ || type === 32 /* TNodeType.Icu */ || type === 16 /* TNodeType.Projection */ || type === 64 /* TNodeType.Placeholder */ || type === 128 /* TNodeType.LetDeclaration */)) {\n throwError(`Expected TNodeType to have only a single type selected, but got ${toTNodeTypeAsString(type)}.`);\n }\n}\n\n/**\n * Assigns all attribute values to the provided element via the inferred renderer.\n *\n * This function accepts two forms of attribute entries:\n *\n * default: (key, value):\n * attrs = [key1, value1, key2, value2]\n *\n * namespaced: (NAMESPACE_MARKER, uri, name, value)\n * attrs = [NAMESPACE_MARKER, uri, name, value, NAMESPACE_MARKER, uri, name, value]\n *\n * The `attrs` array can contain a mix of both the default and namespaced entries.\n * The \"default\" values are set without a marker, but if the function comes across\n * a marker value then it will attempt to set a namespaced value. If the marker is\n * not of a namespaced value then the function will quit and return the index value\n * where it stopped during the iteration of the attrs array.\n *\n * See [AttributeMarker] to understand what the namespace marker value is.\n *\n * Note that this instruction does not support assigning style and class values to\n * an element. See `elementStart` and `elementHostAttrs` to learn how styling values\n * are applied to an element.\n * @param renderer The renderer to be used\n * @param native The element that the attributes will be assigned to\n * @param attrs The attribute array of values that will be assigned to the element\n * @returns the index value that was last accessed in the attributes array\n */\nfunction setUpAttributes(renderer, native, attrs) {\n let i = 0;\n while (i < attrs.length) {\n const value = attrs[i];\n if (typeof value === 'number') {\n // only namespaces are supported. Other value types (such as style/class\n // entries) are not supported in this function.\n if (value !== 0 /* AttributeMarker.NamespaceURI */) {\n break;\n }\n // we just landed on the marker value ... therefore\n // we should skip to the next entry\n i++;\n const namespaceURI = attrs[i++];\n const attrName = attrs[i++];\n const attrVal = attrs[i++];\n ngDevMode && ngDevMode.rendererSetAttribute++;\n renderer.setAttribute(native, attrName, attrVal, namespaceURI);\n } else {\n // attrName is string;\n const attrName = value;\n const attrVal = attrs[++i];\n // Standard attributes\n ngDevMode && ngDevMode.rendererSetAttribute++;\n if (isAnimationProp(attrName)) {\n renderer.setProperty(native, attrName, attrVal);\n } else {\n renderer.setAttribute(native, attrName, attrVal);\n }\n i++;\n }\n }\n // another piece of code may iterate over the same attributes array. Therefore\n // it may be helpful to return the exact spot where the attributes array exited\n // whether by running into an unsupported marker or if all the static values were\n // iterated over.\n return i;\n}\n/**\n * Test whether the given value is a marker that indicates that the following\n * attribute values in a `TAttributes` array are only the names of attributes,\n * and not name-value pairs.\n * @param marker The attribute marker to test.\n * @returns true if the marker is a \"name-only\" marker (e.g. `Bindings`, `Template` or `I18n`).\n */\nfunction isNameOnlyAttributeMarker(marker) {\n return marker === 3 /* AttributeMarker.Bindings */ || marker === 4 /* AttributeMarker.Template */ || marker === 6 /* AttributeMarker.I18n */;\n}\nfunction isAnimationProp(name) {\n // Perf note: accessing charCodeAt to check for the first character of a string is faster as\n // compared to accessing a character at index 0 (ex. name[0]). The main reason for this is that\n // charCodeAt doesn't allocate memory to return a substring.\n return name.charCodeAt(0) === 64 /* CharCode.AT_SIGN */;\n}\n/**\n * Merges `src` `TAttributes` into `dst` `TAttributes` removing any duplicates in the process.\n *\n * This merge function keeps the order of attrs same.\n *\n * @param dst Location of where the merged `TAttributes` should end up.\n * @param src `TAttributes` which should be appended to `dst`\n */\nfunction mergeHostAttrs(dst, src) {\n if (src === null || src.length === 0) {\n // do nothing\n } else if (dst === null || dst.length === 0) {\n // We have source, but dst is empty, just make a copy.\n dst = src.slice();\n } else {\n let srcMarker = -1 /* AttributeMarker.ImplicitAttributes */;\n for (let i = 0; i < src.length; i++) {\n const item = src[i];\n if (typeof item === 'number') {\n srcMarker = item;\n } else {\n if (srcMarker === 0 /* AttributeMarker.NamespaceURI */) {\n // Case where we need to consume `key1`, `key2`, `value` items.\n } else if (srcMarker === -1 /* AttributeMarker.ImplicitAttributes */ || srcMarker === 2 /* AttributeMarker.Styles */) {\n // Case where we have to consume `key1` and `value` only.\n mergeHostAttribute(dst, srcMarker, item, null, src[++i]);\n } else {\n // Case where we have to consume `key1` only.\n mergeHostAttribute(dst, srcMarker, item, null, null);\n }\n }\n }\n }\n return dst;\n}\n/**\n * Append `key`/`value` to existing `TAttributes` taking region marker and duplicates into account.\n *\n * @param dst `TAttributes` to append to.\n * @param marker Region where the `key`/`value` should be added.\n * @param key1 Key to add to `TAttributes`\n * @param key2 Key to add to `TAttributes` (in case of `AttributeMarker.NamespaceURI`)\n * @param value Value to add or to overwrite to `TAttributes` Only used if `marker` is not Class.\n */\nfunction mergeHostAttribute(dst, marker, key1, key2, value) {\n let i = 0;\n // Assume that new markers will be inserted at the end.\n let markerInsertPosition = dst.length;\n // scan until correct type.\n if (marker === -1 /* AttributeMarker.ImplicitAttributes */) {\n markerInsertPosition = -1;\n } else {\n while (i < dst.length) {\n const dstValue = dst[i++];\n if (typeof dstValue === 'number') {\n if (dstValue === marker) {\n markerInsertPosition = -1;\n break;\n } else if (dstValue > marker) {\n // We need to save this as we want the markers to be inserted in specific order.\n markerInsertPosition = i - 1;\n break;\n }\n }\n }\n }\n // search until you find place of insertion\n while (i < dst.length) {\n const item = dst[i];\n if (typeof item === 'number') {\n // since `i` started as the index after the marker, we did not find it if we are at the next\n // marker\n break;\n } else if (item === key1) {\n // We already have same token\n if (key2 === null) {\n if (value !== null) {\n dst[i + 1] = value;\n }\n return;\n } else if (key2 === dst[i + 1]) {\n dst[i + 2] = value;\n return;\n }\n }\n // Increment counter.\n i++;\n if (key2 !== null) i++;\n if (value !== null) i++;\n }\n // insert at location.\n if (markerInsertPosition !== -1) {\n dst.splice(markerInsertPosition, 0, marker);\n i = markerInsertPosition + 1;\n }\n dst.splice(i++, 0, key1);\n if (key2 !== null) {\n dst.splice(i++, 0, key2);\n }\n if (value !== null) {\n dst.splice(i++, 0, value);\n }\n}\n\n// This default value is when checking the hierarchy for a token.\n//\n// It means both:\n// - the token is not provided by the current injector,\n// - only the element injectors should be checked (ie do not check module injectors\n//\n// mod1\n// /\n// el1 mod2\n// \\ /\n// el2\n//\n// When requesting el2.injector.get(token), we should check in the following order and return the\n// first found value:\n// - el2.injector.get(token, default)\n// - el1.injector.get(token, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR) -> do not check the module\n// - mod2.injector.get(token, default)\nconst NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR = {};\n\n/**\n * Injector that looks up a value using a specific injector, before falling back to the module\n * injector. Used primarily when creating components or embedded views dynamically.\n */\nclass ChainedInjector {\n injector;\n parentInjector;\n constructor(injector, parentInjector) {\n this.injector = injector;\n this.parentInjector = parentInjector;\n }\n get(token, notFoundValue, flags) {\n flags = convertToBitFlags(flags);\n const value = this.injector.get(token, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, flags);\n if (value !== NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR || notFoundValue === NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR) {\n // Return the value from the root element injector when\n // - it provides it\n // (value !== NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR)\n // - the module injector should not be checked\n // (notFoundValue === NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR)\n return value;\n }\n return this.parentInjector.get(token, notFoundValue, flags);\n }\n}\n\n/// Parent Injector Utils ///////////////////////////////////////////////////////////////\nfunction hasParentInjector(parentLocation) {\n return parentLocation !== NO_PARENT_INJECTOR;\n}\nfunction getParentInjectorIndex(parentLocation) {\n if (ngDevMode) {\n assertNumber(parentLocation, 'Number expected');\n assertNotEqual(parentLocation, -1, 'Not a valid state.');\n const parentInjectorIndex = parentLocation & 32767 /* RelativeInjectorLocationFlags.InjectorIndexMask */;\n assertGreaterThan(parentInjectorIndex, HEADER_OFFSET, 'Parent injector must be pointing past HEADER_OFFSET.');\n }\n return parentLocation & 32767 /* RelativeInjectorLocationFlags.InjectorIndexMask */;\n}\nfunction getParentInjectorViewOffset(parentLocation) {\n return parentLocation >> 16 /* RelativeInjectorLocationFlags.ViewOffsetShift */;\n}\n/**\n * Unwraps a parent injector location number to find the view offset from the current injector,\n * then walks up the declaration view tree until the view is found that contains the parent\n * injector.\n *\n * @param location The location of the parent injector, which contains the view offset\n * @param startView The LView instance from which to start walking up the view tree\n * @returns The LView instance that contains the parent injector\n */\nfunction getParentInjectorView(location, startView) {\n let viewOffset = getParentInjectorViewOffset(location);\n let parentView = startView;\n // For most cases, the parent injector can be found on the host node (e.g. for component\n // or container), but we must keep the loop here to support the rarer case of deeply nested\n // <ng-template> tags or inline views, where the parent injector might live many views\n // above the child injector.\n while (viewOffset > 0) {\n parentView = parentView[DECLARATION_VIEW];\n viewOffset--;\n }\n return parentView;\n}\n/**\n * Detects whether an injector is an instance of a `ChainedInjector`,\n * created based on the `OutletInjector`.\n */\nfunction isRouterOutletInjector(currentInjector) {\n return currentInjector instanceof ChainedInjector && typeof currentInjector.injector.__ngOutletInjector === 'function';\n}\n\n/**\n * Defines if the call to `inject` should include `viewProviders` in its resolution.\n *\n * This is set to true when we try to instantiate a component. This value is reset in\n * `getNodeInjectable` to a value which matches the declaration location of the token about to be\n * instantiated. This is done so that if we are injecting a token which was declared outside of\n * `viewProviders` we don't accidentally pull `viewProviders` in.\n *\n * Example:\n *\n * ```ts\n * @Injectable()\n * class MyService {\n * constructor(public value: String) {}\n * }\n *\n * @Component({\n * providers: [\n * MyService,\n * {provide: String, value: 'providers' }\n * ]\n * viewProviders: [\n * {provide: String, value: 'viewProviders'}\n * ]\n * })\n * class MyComponent {\n * constructor(myService: MyService, value: String) {\n * // We expect that Component can see into `viewProviders`.\n * expect(value).toEqual('viewProviders');\n * // `MyService` was not declared in `viewProviders` hence it can't see it.\n * expect(myService.value).toEqual('providers');\n * }\n * }\n *\n * ```\n */\nlet includeViewProviders = true;\nfunction setIncludeViewProviders(v) {\n const oldValue = includeViewProviders;\n includeViewProviders = v;\n return oldValue;\n}\n/**\n * The number of slots in each bloom filter (used by DI). The larger this number, the fewer\n * directives that will share slots, and thus, the fewer false positives when checking for\n * the existence of a directive.\n */\nconst BLOOM_SIZE = 256;\nconst BLOOM_MASK = BLOOM_SIZE - 1;\n/**\n * The number of bits that is represented by a single bloom bucket. JS bit operations are 32 bits,\n * so each bucket represents 32 distinct tokens which accounts for log2(32) = 5 bits of a bloom hash\n * number.\n */\nconst BLOOM_BUCKET_BITS = 5;\n/** Counter used to generate unique IDs for directives. */\nlet nextNgElementId = 0;\n/** Value used when something wasn't found by an injector. */\nconst NOT_FOUND = {};\n/**\n * Registers this directive as present in its node's injector by flipping the directive's\n * corresponding bit in the injector's bloom filter.\n *\n * @param injectorIndex The index of the node injector where this token should be registered\n * @param tView The TView for the injector's bloom filters\n * @param type The directive token to register\n */\nfunction bloomAdd(injectorIndex, tView, type) {\n ngDevMode && assertEqual(tView.firstCreatePass, true, 'expected firstCreatePass to be true');\n let id;\n if (typeof type === 'string') {\n id = type.charCodeAt(0) || 0;\n } else if (type.hasOwnProperty(NG_ELEMENT_ID)) {\n id = type[NG_ELEMENT_ID];\n }\n // Set a unique ID on the directive type, so if something tries to inject the directive,\n // we can easily retrieve the ID and hash it into the bloom bit that should be checked.\n if (id == null) {\n id = type[NG_ELEMENT_ID] = nextNgElementId++;\n }\n // We only have BLOOM_SIZE (256) slots in our bloom filter (8 buckets * 32 bits each),\n // so all unique IDs must be modulo-ed into a number from 0 - 255 to fit into the filter.\n const bloomHash = id & BLOOM_MASK;\n // Create a mask that targets the specific bit associated with the directive.\n // JS bit operations are 32 bits, so this will be a number between 2^0 and 2^31, corresponding\n // to bit positions 0 - 31 in a 32 bit integer.\n const mask = 1 << bloomHash;\n // Each bloom bucket in `tData` represents `BLOOM_BUCKET_BITS` number of bits of `bloomHash`.\n // Any bits in `bloomHash` beyond `BLOOM_BUCKET_BITS` indicate the bucket offset that the mask\n // should be written to.\n tView.data[injectorIndex + (bloomHash >> BLOOM_BUCKET_BITS)] |= mask;\n}\n/**\n * Creates (or gets an existing) injector for a given element or container.\n *\n * @param tNode for which an injector should be retrieved / created.\n * @param lView View where the node is stored\n * @returns Node injector\n */\nfunction getOrCreateNodeInjectorForNode(tNode, lView) {\n const existingInjectorIndex = getInjectorIndex(tNode, lView);\n if (existingInjectorIndex !== -1) {\n return existingInjectorIndex;\n }\n const tView = lView[TVIEW];\n if (tView.firstCreatePass) {\n tNode.injectorIndex = lView.length;\n insertBloom(tView.data, tNode); // foundation for node bloom\n insertBloom(lView, null); // foundation for cumulative bloom\n insertBloom(tView.blueprint, null);\n }\n const parentLoc = getParentInjectorLocation(tNode, lView);\n const injectorIndex = tNode.injectorIndex;\n // If a parent injector can't be found, its location is set to -1.\n // In that case, we don't need to set up a cumulative bloom\n if (hasParentInjector(parentLoc)) {\n const parentIndex = getParentInjectorIndex(parentLoc);\n const parentLView = getParentInjectorView(parentLoc, lView);\n const parentData = parentLView[TVIEW].data;\n // Creates a cumulative bloom filter that merges the parent's bloom filter\n // and its own cumulative bloom (which contains tokens for all ancestors)\n for (let i = 0; i < 8 /* NodeInjectorOffset.BLOOM_SIZE */; i++) {\n lView[injectorIndex + i] = parentLView[parentIndex + i] | parentData[parentIndex + i];\n }\n }\n lView[injectorIndex + 8 /* NodeInjectorOffset.PARENT */] = parentLoc;\n return injectorIndex;\n}\nfunction insertBloom(arr, footer) {\n arr.push(0, 0, 0, 0, 0, 0, 0, 0, footer);\n}\nfunction getInjectorIndex(tNode, lView) {\n if (tNode.injectorIndex === -1 ||\n // If the injector index is the same as its parent's injector index, then the index has been\n // copied down from the parent node. No injector has been created yet on this node.\n tNode.parent && tNode.parent.injectorIndex === tNode.injectorIndex ||\n // After the first template pass, the injector index might exist but the parent values\n // might not have been calculated yet for this instance\n lView[tNode.injectorIndex + 8 /* NodeInjectorOffset.PARENT */] === null) {\n return -1;\n } else {\n ngDevMode && assertIndexInRange(lView, tNode.injectorIndex);\n return tNode.injectorIndex;\n }\n}\n/**\n * Finds the index of the parent injector, with a view offset if applicable. Used to set the\n * parent injector initially.\n *\n * @returns Returns a number that is the combination of the number of LViews that we have to go up\n * to find the LView containing the parent inject AND the index of the injector within that LView.\n */\nfunction getParentInjectorLocation(tNode, lView) {\n if (tNode.parent && tNode.parent.injectorIndex !== -1) {\n // If we have a parent `TNode` and there is an injector associated with it we are done, because\n // the parent injector is within the current `LView`.\n return tNode.parent.injectorIndex; // ViewOffset is 0\n }\n // When parent injector location is computed it may be outside of the current view. (ie it could\n // be pointing to a declared parent location). This variable stores number of declaration parents\n // we need to walk up in order to find the parent injector location.\n let declarationViewOffset = 0;\n let parentTNode = null;\n let lViewCursor = lView;\n // The parent injector is not in the current `LView`. We will have to walk the declared parent\n // `LView` hierarchy and look for it. If we walk of the top, that means that there is no parent\n // `NodeInjector`.\n while (lViewCursor !== null) {\n parentTNode = getTNodeFromLView(lViewCursor);\n if (parentTNode === null) {\n // If we have no parent, than we are done.\n return NO_PARENT_INJECTOR;\n }\n ngDevMode && parentTNode && assertTNodeForLView(parentTNode, lViewCursor[DECLARATION_VIEW]);\n // Every iteration of the loop requires that we go to the declared parent.\n declarationViewOffset++;\n lViewCursor = lViewCursor[DECLARATION_VIEW];\n if (parentTNode.injectorIndex !== -1) {\n // We found a NodeInjector which points to something.\n return parentTNode.injectorIndex | declarationViewOffset << 16 /* RelativeInjectorLocationFlags.ViewOffsetShift */;\n }\n }\n return NO_PARENT_INJECTOR;\n}\n/**\n * Makes a type or an injection token public to the DI system by adding it to an\n * injector's bloom filter.\n *\n * @param di The node injector in which a directive will be added\n * @param token The type or the injection token to be made public\n */\nfunction diPublicInInjector(injectorIndex, tView, token) {\n bloomAdd(injectorIndex, tView, token);\n}\n/**\n * Inject static attribute value into directive constructor.\n *\n * This method is used with `factory` functions which are generated as part of\n * `defineDirective` or `defineComponent`. The method retrieves the static value\n * of an attribute. (Dynamic attributes are not supported since they are not resolved\n * at the time of injection and can change over time.)\n *\n * # Example\n * Given:\n * ```ts\n * @Component(...)\n * class MyComponent {\n * constructor(@Attribute('title') title: string) { ... }\n * }\n * ```\n * When instantiated with\n * ```html\n * <my-component title=\"Hello\"></my-component>\n * ```\n *\n * Then factory method generated is:\n * ```ts\n * MyComponent.ɵcmp = defineComponent({\n * factory: () => new MyComponent(injectAttribute('title'))\n * ...\n * })\n * ```\n *\n * @publicApi\n */\nfunction injectAttributeImpl(tNode, attrNameToInject) {\n ngDevMode && assertTNodeType(tNode, 12 /* TNodeType.AnyContainer */ | 3 /* TNodeType.AnyRNode */);\n ngDevMode && assertDefined(tNode, 'expecting tNode');\n if (attrNameToInject === 'class') {\n return tNode.classes;\n }\n if (attrNameToInject === 'style') {\n return tNode.styles;\n }\n const attrs = tNode.attrs;\n if (attrs) {\n const attrsLength = attrs.length;\n let i = 0;\n while (i < attrsLength) {\n const value = attrs[i];\n // If we hit a `Bindings` or `Template` marker then we are done.\n if (isNameOnlyAttributeMarker(value)) break;\n // Skip namespaced attributes\n if (value === 0 /* AttributeMarker.NamespaceURI */) {\n // we skip the next two values\n // as namespaced attributes looks like\n // [..., AttributeMarker.NamespaceURI, 'http://someuri.com/test', 'test:exist',\n // 'existValue', ...]\n i = i + 2;\n } else if (typeof value === 'number') {\n // Skip to the first value of the marked attribute.\n i++;\n while (i < attrsLength && typeof attrs[i] === 'string') {\n i++;\n }\n } else if (value === attrNameToInject) {\n return attrs[i + 1];\n } else {\n i = i + 2;\n }\n }\n }\n return null;\n}\nfunction notFoundValueOrThrow(notFoundValue, token, flags) {\n if (flags & InjectFlags.Optional || notFoundValue !== undefined) {\n return notFoundValue;\n } else {\n throwProviderNotFoundError(token, 'NodeInjector');\n }\n}\n/**\n * Returns the value associated to the given token from the ModuleInjector or throws exception\n *\n * @param lView The `LView` that contains the `tNode`\n * @param token The token to look for\n * @param flags Injection flags\n * @param notFoundValue The value to return when the injection flags is `InjectFlags.Optional`\n * @returns the value from the injector or throws an exception\n */\nfunction lookupTokenUsingModuleInjector(lView, token, flags, notFoundValue) {\n if (flags & InjectFlags.Optional && notFoundValue === undefined) {\n // This must be set or the NullInjector will throw for optional deps\n notFoundValue = null;\n }\n if ((flags & (InjectFlags.Self | InjectFlags.Host)) === 0) {\n const moduleInjector = lView[INJECTOR];\n // switch to `injectInjectorOnly` implementation for module injector, since module injector\n // should not have access to Component/Directive DI scope (that may happen through\n // `directiveInject` implementation)\n const previousInjectImplementation = setInjectImplementation(undefined);\n try {\n if (moduleInjector) {\n return moduleInjector.get(token, notFoundValue, flags & InjectFlags.Optional);\n } else {\n return injectRootLimpMode(token, notFoundValue, flags & InjectFlags.Optional);\n }\n } finally {\n setInjectImplementation(previousInjectImplementation);\n }\n }\n return notFoundValueOrThrow(notFoundValue, token, flags);\n}\n/**\n * Returns the value associated to the given token from the NodeInjectors => ModuleInjector.\n *\n * Look for the injector providing the token by walking up the node injector tree and then\n * the module injector tree.\n *\n * This function patches `token` with `__NG_ELEMENT_ID__` which contains the id for the bloom\n * filter. `-1` is reserved for injecting `Injector` (implemented by `NodeInjector`)\n *\n * @param tNode The Node where the search for the injector should start\n * @param lView The `LView` that contains the `tNode`\n * @param token The token to look for\n * @param flags Injection flags\n * @param notFoundValue The value to return when the injection flags is `InjectFlags.Optional`\n * @returns the value from the injector, `null` when not found, or `notFoundValue` if provided\n */\nfunction getOrCreateInjectable(tNode, lView, token, flags = InjectFlags.Default, notFoundValue) {\n if (tNode !== null) {\n // If the view or any of its ancestors have an embedded\n // view injector, we have to look it up there first.\n if (lView[FLAGS] & 2048 /* LViewFlags.HasEmbeddedViewInjector */ &&\n // The token must be present on the current node injector when the `Self`\n // flag is set, so the lookup on embedded view injector(s) can be skipped.\n !(flags & InjectFlags.Self)) {\n const embeddedInjectorValue = lookupTokenUsingEmbeddedInjector(tNode, lView, token, flags, NOT_FOUND);\n if (embeddedInjectorValue !== NOT_FOUND) {\n return embeddedInjectorValue;\n }\n }\n // Otherwise try the node injector.\n const value = lookupTokenUsingNodeInjector(tNode, lView, token, flags, NOT_FOUND);\n if (value !== NOT_FOUND) {\n return value;\n }\n }\n // Finally, fall back to the module injector.\n return lookupTokenUsingModuleInjector(lView, token, flags, notFoundValue);\n}\n/**\n * Returns the value associated to the given token from the node injector.\n *\n * @param tNode The Node where the search for the injector should start\n * @param lView The `LView` that contains the `tNode`\n * @param token The token to look for\n * @param flags Injection flags\n * @param notFoundValue The value to return when the injection flags is `InjectFlags.Optional`\n * @returns the value from the injector, `null` when not found, or `notFoundValue` if provided\n */\nfunction lookupTokenUsingNodeInjector(tNode, lView, token, flags, notFoundValue) {\n const bloomHash = bloomHashBitOrFactory(token);\n // If the ID stored here is a function, this is a special object like ElementRef or TemplateRef\n // so just call the factory function to create it.\n if (typeof bloomHash === 'function') {\n if (!enterDI(lView, tNode, flags)) {\n // Failed to enter DI, try module injector instead. If a token is injected with the @Host\n // flag, the module injector is not searched for that token in Ivy.\n return flags & InjectFlags.Host ? notFoundValueOrThrow(notFoundValue, token, flags) : lookupTokenUsingModuleInjector(lView, token, flags, notFoundValue);\n }\n try {\n let value;\n if (ngDevMode) {\n runInInjectorProfilerContext(new NodeInjector(getCurrentTNode(), getLView()), token, () => {\n value = bloomHash(flags);\n if (value != null) {\n emitInstanceCreatedByInjectorEvent(value);\n }\n });\n } else {\n value = bloomHash(flags);\n }\n if (value == null && !(flags & InjectFlags.Optional)) {\n throwProviderNotFoundError(token);\n } else {\n return value;\n }\n } finally {\n leaveDI();\n }\n } else if (typeof bloomHash === 'number') {\n // A reference to the previous injector TView that was found while climbing the element\n // injector tree. This is used to know if viewProviders can be accessed on the current\n // injector.\n let previousTView = null;\n let injectorIndex = getInjectorIndex(tNode, lView);\n let parentLocation = NO_PARENT_INJECTOR;\n let hostTElementNode = flags & InjectFlags.Host ? lView[DECLARATION_COMPONENT_VIEW][T_HOST] : null;\n // If we should skip this injector, or if there is no injector on this node, start by\n // searching the parent injector.\n if (injectorIndex === -1 || flags & InjectFlags.SkipSelf) {\n parentLocation = injectorIndex === -1 ? getParentInjectorLocation(tNode, lView) : lView[injectorIndex + 8 /* NodeInjectorOffset.PARENT */];\n if (parentLocation === NO_PARENT_INJECTOR || !shouldSearchParent(flags, false)) {\n injectorIndex = -1;\n } else {\n previousTView = lView[TVIEW];\n injectorIndex = getParentInjectorIndex(parentLocation);\n lView = getParentInjectorView(parentLocation, lView);\n }\n }\n // Traverse up the injector tree until we find a potential match or until we know there\n // *isn't* a match.\n while (injectorIndex !== -1) {\n ngDevMode && assertNodeInjector(lView, injectorIndex);\n // Check the current injector. If it matches, see if it contains token.\n const tView = lView[TVIEW];\n ngDevMode && assertTNodeForLView(tView.data[injectorIndex + 8 /* NodeInjectorOffset.TNODE */], lView);\n if (bloomHasToken(bloomHash, injectorIndex, tView.data)) {\n // At this point, we have an injector which *may* contain the token, so we step through\n // the providers and directives associated with the injector's corresponding node to get\n // the instance.\n const instance = searchTokensOnInjector(injectorIndex, lView, token, previousTView, flags, hostTElementNode);\n if (instance !== NOT_FOUND) {\n return instance;\n }\n }\n parentLocation = lView[injectorIndex + 8 /* NodeInjectorOffset.PARENT */];\n if (parentLocation !== NO_PARENT_INJECTOR && shouldSearchParent(flags, lView[TVIEW].data[injectorIndex + 8 /* NodeInjectorOffset.TNODE */] === hostTElementNode) && bloomHasToken(bloomHash, injectorIndex, lView)) {\n // The def wasn't found anywhere on this node, so it was a false positive.\n // Traverse up the tree and continue searching.\n previousTView = tView;\n injectorIndex = getParentInjectorIndex(parentLocation);\n lView = getParentInjectorView(parentLocation, lView);\n } else {\n // If we should not search parent OR If the ancestor bloom filter value does not have the\n // bit corresponding to the directive we can give up on traversing up to find the specific\n // injector.\n injectorIndex = -1;\n }\n }\n }\n return notFoundValue;\n}\nfunction searchTokensOnInjector(injectorIndex, lView, token, previousTView, flags, hostTElementNode) {\n const currentTView = lView[TVIEW];\n const tNode = currentTView.data[injectorIndex + 8 /* NodeInjectorOffset.TNODE */];\n // First, we need to determine if view providers can be accessed by the starting element.\n // There are two possibilities\n const canAccessViewProviders = previousTView == null ?\n // 1) This is the first invocation `previousTView == null` which means that we are at the\n // `TNode` of where injector is starting to look. In such a case the only time we are allowed\n // to look into the ViewProviders is if:\n // - we are on a component\n // - AND the injector set `includeViewProviders` to true (implying that the token can see\n // ViewProviders because it is the Component or a Service which itself was declared in\n // ViewProviders)\n isComponentHost(tNode) && includeViewProviders :\n // 2) `previousTView != null` which means that we are now walking across the parent nodes.\n // In such a case we are only allowed to look into the ViewProviders if:\n // - We just crossed from child View to Parent View `previousTView != currentTView`\n // - AND the parent TNode is an Element.\n // This means that we just came from the Component's View and therefore are allowed to see\n // into the ViewProviders.\n previousTView != currentTView && (tNode.type & 3 /* TNodeType.AnyRNode */) !== 0;\n // This special case happens when there is a @host on the inject and when we are searching\n // on the host element node.\n const isHostSpecialCase = flags & InjectFlags.Host && hostTElementNode === tNode;\n const injectableIdx = locateDirectiveOrProvider(tNode, currentTView, token, canAccessViewProviders, isHostSpecialCase);\n if (injectableIdx !== null) {\n return getNodeInjectable(lView, currentTView, injectableIdx, tNode);\n } else {\n return NOT_FOUND;\n }\n}\n/**\n * Searches for the given token among the node's directives and providers.\n *\n * @param tNode TNode on which directives are present.\n * @param tView The tView we are currently processing\n * @param token Provider token or type of a directive to look for.\n * @param canAccessViewProviders Whether view providers should be considered.\n * @param isHostSpecialCase Whether the host special case applies.\n * @returns Index of a found directive or provider, or null when none found.\n */\nfunction locateDirectiveOrProvider(tNode, tView, token, canAccessViewProviders, isHostSpecialCase) {\n const nodeProviderIndexes = tNode.providerIndexes;\n const tInjectables = tView.data;\n const injectablesStart = nodeProviderIndexes & 1048575 /* TNodeProviderIndexes.ProvidersStartIndexMask */;\n const directivesStart = tNode.directiveStart;\n const directiveEnd = tNode.directiveEnd;\n const cptViewProvidersCount = nodeProviderIndexes >> 20 /* TNodeProviderIndexes.CptViewProvidersCountShift */;\n const startingIndex = canAccessViewProviders ? injectablesStart : injectablesStart + cptViewProvidersCount;\n // When the host special case applies, only the viewProviders and the component are visible\n const endIndex = isHostSpecialCase ? injectablesStart + cptViewProvidersCount : directiveEnd;\n for (let i = startingIndex; i < endIndex; i++) {\n const providerTokenOrDef = tInjectables[i];\n if (i < directivesStart && token === providerTokenOrDef || i >= directivesStart && providerTokenOrDef.type === token) {\n return i;\n }\n }\n if (isHostSpecialCase) {\n const dirDef = tInjectables[directivesStart];\n if (dirDef && isComponentDef(dirDef) && dirDef.type === token) {\n return directivesStart;\n }\n }\n return null;\n}\n/**\n * Retrieve or instantiate the injectable from the `LView` at particular `index`.\n *\n * This function checks to see if the value has already been instantiated and if so returns the\n * cached `injectable`. Otherwise if it detects that the value is still a factory it\n * instantiates the `injectable` and caches the value.\n */\nfunction getNodeInjectable(lView, tView, index, tNode) {\n let value = lView[index];\n const tData = tView.data;\n if (value instanceof NodeInjectorFactory) {\n const factory = value;\n if (factory.resolving) {\n throwCyclicDependencyError(stringifyForError(tData[index]));\n }\n const previousIncludeViewProviders = setIncludeViewProviders(factory.canSeeViewProviders);\n factory.resolving = true;\n let prevInjectContext;\n if (ngDevMode) {\n // tData indexes mirror the concrete instances in its corresponding LView.\n // lView[index] here is either the injectable instace itself or a factory,\n // therefore tData[index] is the constructor of that injectable or a\n // definition object that contains the constructor in a `.type` field.\n const token = tData[index].type || tData[index];\n const injector = new NodeInjector(tNode, lView);\n prevInjectContext = setInjectorProfilerContext({\n injector,\n token\n });\n }\n const previousInjectImplementation = factory.injectImpl ? setInjectImplementation(factory.injectImpl) : null;\n const success = enterDI(lView, tNode, InjectFlags.Default);\n ngDevMode && assertEqual(success, true, \"Because flags do not contain `SkipSelf' we expect this to always succeed.\");\n try {\n value = lView[index] = factory.factory(undefined, tData, lView, tNode);\n ngDevMode && emitInstanceCreatedByInjectorEvent(value);\n // This code path is hit for both directives and providers.\n // For perf reasons, we want to avoid searching for hooks on providers.\n // It does no harm to try (the hooks just won't exist), but the extra\n // checks are unnecessary and this is a hot path. So we check to see\n // if the index of the dependency is in the directive range for this\n // tNode. If it's not, we know it's a provider and skip hook registration.\n if (tView.firstCreatePass && index >= tNode.directiveStart) {\n ngDevMode && assertDirectiveDef(tData[index]);\n registerPreOrderHooks(index, tData[index], tView);\n }\n } finally {\n ngDevMode && setInjectorProfilerContext(prevInjectContext);\n previousInjectImplementation !== null && setInjectImplementation(previousInjectImplementation);\n setIncludeViewProviders(previousIncludeViewProviders);\n factory.resolving = false;\n leaveDI();\n }\n }\n return value;\n}\n/**\n * Returns the bit in an injector's bloom filter that should be used to determine whether or not\n * the directive might be provided by the injector.\n *\n * When a directive is public, it is added to the bloom filter and given a unique ID that can be\n * retrieved on the Type. When the directive isn't public or the token is not a directive `null`\n * is returned as the node injector can not possibly provide that token.\n *\n * @param token the injection token\n * @returns the matching bit to check in the bloom filter or `null` if the token is not known.\n * When the returned value is negative then it represents special values such as `Injector`.\n */\nfunction bloomHashBitOrFactory(token) {\n ngDevMode && assertDefined(token, 'token must be defined');\n if (typeof token === 'string') {\n return token.charCodeAt(0) || 0;\n }\n const tokenId =\n // First check with `hasOwnProperty` so we don't get an inherited ID.\n token.hasOwnProperty(NG_ELEMENT_ID) ? token[NG_ELEMENT_ID] : undefined;\n // Negative token IDs are used for special objects such as `Injector`\n if (typeof tokenId === 'number') {\n if (tokenId >= 0) {\n return tokenId & BLOOM_MASK;\n } else {\n ngDevMode && assertEqual(tokenId, -1 /* InjectorMarkers.Injector */, 'Expecting to get Special Injector Id');\n return createNodeInjector;\n }\n } else {\n return tokenId;\n }\n}\nfunction bloomHasToken(bloomHash, injectorIndex, injectorView) {\n // Create a mask that targets the specific bit associated with the directive we're looking for.\n // JS bit operations are 32 bits, so this will be a number between 2^0 and 2^31, corresponding\n // to bit positions 0 - 31 in a 32 bit integer.\n const mask = 1 << bloomHash;\n // Each bloom bucket in `injectorView` represents `BLOOM_BUCKET_BITS` number of bits of\n // `bloomHash`. Any bits in `bloomHash` beyond `BLOOM_BUCKET_BITS` indicate the bucket offset\n // that should be used.\n const value = injectorView[injectorIndex + (bloomHash >> BLOOM_BUCKET_BITS)];\n // If the bloom filter value has the bit corresponding to the directive's bloomBit flipped on,\n // this injector is a potential match.\n return !!(value & mask);\n}\n/** Returns true if flags prevent parent injector from being searched for tokens */\nfunction shouldSearchParent(flags, isFirstHostTNode) {\n return !(flags & InjectFlags.Self) && !(flags & InjectFlags.Host && isFirstHostTNode);\n}\nfunction getNodeInjectorLView(nodeInjector) {\n return nodeInjector._lView;\n}\nfunction getNodeInjectorTNode(nodeInjector) {\n return nodeInjector._tNode;\n}\nclass NodeInjector {\n _tNode;\n _lView;\n constructor(_tNode, _lView) {\n this._tNode = _tNode;\n this._lView = _lView;\n }\n get(token, notFoundValue, flags) {\n return getOrCreateInjectable(this._tNode, this._lView, token, convertToBitFlags(flags), notFoundValue);\n }\n}\n/** Creates a `NodeInjector` for the current node. */\nfunction createNodeInjector() {\n return new NodeInjector(getCurrentTNode(), getLView());\n}\n/**\n * @codeGenApi\n */\nfunction ɵɵgetInheritedFactory(type) {\n return noSideEffects(() => {\n const ownConstructor = type.prototype.constructor;\n const ownFactory = ownConstructor[NG_FACTORY_DEF] || getFactoryOf(ownConstructor);\n const objectPrototype = Object.prototype;\n let parent = Object.getPrototypeOf(type.prototype).constructor;\n // Go up the prototype until we hit `Object`.\n while (parent && parent !== objectPrototype) {\n const factory = parent[NG_FACTORY_DEF] || getFactoryOf(parent);\n // If we hit something that has a factory and the factory isn't the same as the type,\n // we've found the inherited factory. Note the check that the factory isn't the type's\n // own factory is redundant in most cases, but if the user has custom decorators on the\n // class, this lookup will start one level down in the prototype chain, causing us to\n // find the own factory first and potentially triggering an infinite loop downstream.\n if (factory && factory !== ownFactory) {\n return factory;\n }\n parent = Object.getPrototypeOf(parent);\n }\n // There is no factory defined. Either this was improper usage of inheritance\n // (no Angular decorator on the superclass) or there is no constructor at all\n // in the inheritance chain. Since the two cases cannot be distinguished, the\n // latter has to be assumed.\n return t => new t();\n });\n}\nfunction getFactoryOf(type) {\n if (isForwardRef(type)) {\n return () => {\n const factory = getFactoryOf(resolveForwardRef(type));\n return factory && factory();\n };\n }\n return getFactoryDef(type);\n}\n/**\n * Returns a value from the closest embedded or node injector.\n *\n * @param tNode The Node where the search for the injector should start\n * @param lView The `LView` that contains the `tNode`\n * @param token The token to look for\n * @param flags Injection flags\n * @param notFoundValue The value to return when the injection flags is `InjectFlags.Optional`\n * @returns the value from the injector, `null` when not found, or `notFoundValue` if provided\n */\nfunction lookupTokenUsingEmbeddedInjector(tNode, lView, token, flags, notFoundValue) {\n let currentTNode = tNode;\n let currentLView = lView;\n // When an LView with an embedded view injector is inserted, it'll likely be interlaced with\n // nodes who may have injectors (e.g. node injector -> embedded view injector -> node injector).\n // Since the bloom filters for the node injectors have already been constructed and we don't\n // have a way of extracting the records from an injector, the only way to maintain the correct\n // hierarchy when resolving the value is to walk it node-by-node while attempting to resolve\n // the token at each level.\n while (currentTNode !== null && currentLView !== null && currentLView[FLAGS] & 2048 /* LViewFlags.HasEmbeddedViewInjector */ && !isRootView(currentLView)) {\n ngDevMode && assertTNodeForLView(currentTNode, currentLView);\n // Note that this lookup on the node injector is using the `Self` flag, because\n // we don't want the node injector to look at any parent injectors since we\n // may hit the embedded view injector first.\n const nodeInjectorValue = lookupTokenUsingNodeInjector(currentTNode, currentLView, token, flags | InjectFlags.Self, NOT_FOUND);\n if (nodeInjectorValue !== NOT_FOUND) {\n return nodeInjectorValue;\n }\n // Has an explicit type due to a TS bug: https://github.com/microsoft/TypeScript/issues/33191\n let parentTNode = currentTNode.parent;\n // `TNode.parent` includes the parent within the current view only. If it doesn't exist,\n // it means that we've hit the view boundary and we need to go up to the next view.\n if (!parentTNode) {\n // Before we go to the next LView, check if the token exists on the current embedded injector.\n const embeddedViewInjector = currentLView[EMBEDDED_VIEW_INJECTOR];\n if (embeddedViewInjector) {\n const embeddedViewInjectorValue = embeddedViewInjector.get(token, NOT_FOUND, flags);\n if (embeddedViewInjectorValue !== NOT_FOUND) {\n return embeddedViewInjectorValue;\n }\n }\n // Otherwise keep going up the tree.\n parentTNode = getTNodeFromLView(currentLView);\n currentLView = currentLView[DECLARATION_VIEW];\n }\n currentTNode = parentTNode;\n }\n return notFoundValue;\n}\n/** Gets the TNode associated with an LView inside of the declaration view. */\nfunction getTNodeFromLView(lView) {\n const tView = lView[TVIEW];\n const tViewType = tView.type;\n // The parent pointer differs based on `TView.type`.\n if (tViewType === 2 /* TViewType.Embedded */) {\n ngDevMode && assertDefined(tView.declTNode, 'Embedded TNodes should have declaration parents.');\n return tView.declTNode;\n } else if (tViewType === 1 /* TViewType.Component */) {\n // Components don't have `TView.declTNode` because each instance of component could be\n // inserted in different location, hence `TView.declTNode` is meaningless.\n return lView[T_HOST];\n }\n return null;\n}\n\n/**\n * Facade for the attribute injection from DI.\n *\n * @codeGenApi\n */\nfunction ɵɵinjectAttribute(attrNameToInject) {\n return injectAttributeImpl(getCurrentTNode(), attrNameToInject);\n}\n\n/**\n * Attribute decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst Attribute = makeParamDecorator('Attribute', attributeName => ({\n attributeName,\n __NG_ELEMENT_ID__: () => ɵɵinjectAttribute(attributeName)\n}));\nlet _reflect = null;\nfunction getReflect() {\n return _reflect = _reflect || new ReflectionCapabilities();\n}\nfunction reflectDependencies(type) {\n return convertDependencies(getReflect().parameters(type));\n}\nfunction convertDependencies(deps) {\n return deps.map(dep => reflectDependency(dep));\n}\nfunction reflectDependency(dep) {\n const meta = {\n token: null,\n attribute: null,\n host: false,\n optional: false,\n self: false,\n skipSelf: false\n };\n if (Array.isArray(dep) && dep.length > 0) {\n for (let j = 0; j < dep.length; j++) {\n const param = dep[j];\n if (param === undefined) {\n // param may be undefined if type of dep is not set by ngtsc\n continue;\n }\n const proto = Object.getPrototypeOf(param);\n if (param instanceof Optional || proto.ngMetadataName === 'Optional') {\n meta.optional = true;\n } else if (param instanceof SkipSelf || proto.ngMetadataName === 'SkipSelf') {\n meta.skipSelf = true;\n } else if (param instanceof Self || proto.ngMetadataName === 'Self') {\n meta.self = true;\n } else if (param instanceof Host || proto.ngMetadataName === 'Host') {\n meta.host = true;\n } else if (param instanceof Inject) {\n meta.token = param.token;\n } else if (param instanceof Attribute) {\n if (param.attributeName === undefined) {\n throw new RuntimeError(204 /* RuntimeErrorCode.INVALID_INJECTION_TOKEN */, ngDevMode && `Attribute name must be defined.`);\n }\n meta.attribute = param.attributeName;\n } else {\n meta.token = param;\n }\n }\n } else if (dep === undefined || Array.isArray(dep) && dep.length === 0) {\n meta.token = null;\n } else {\n meta.token = dep;\n }\n return meta;\n}\n\n/**\n * Compile an Angular injectable according to its `Injectable` metadata, and patch the resulting\n * injectable def (`ɵprov`) onto the injectable type.\n */\nfunction compileInjectable(type, meta) {\n let ngInjectableDef = null;\n let ngFactoryDef = null;\n // if NG_PROV_DEF is already defined on this class then don't overwrite it\n if (!type.hasOwnProperty(NG_PROV_DEF)) {\n Object.defineProperty(type, NG_PROV_DEF, {\n get: () => {\n if (ngInjectableDef === null) {\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'injectable',\n type\n });\n ngInjectableDef = compiler.compileInjectable(angularCoreDiEnv, `ng:///${type.name}/ɵprov.js`, getInjectableMetadata(type, meta));\n }\n return ngInjectableDef;\n }\n });\n }\n // if NG_FACTORY_DEF is already defined on this class then don't overwrite it\n if (!type.hasOwnProperty(NG_FACTORY_DEF)) {\n Object.defineProperty(type, NG_FACTORY_DEF, {\n get: () => {\n if (ngFactoryDef === null) {\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'injectable',\n type\n });\n ngFactoryDef = compiler.compileFactory(angularCoreDiEnv, `ng:///${type.name}/ɵfac.js`, {\n name: type.name,\n type,\n typeArgumentCount: 0,\n // In JIT mode types are not available nor used.\n deps: reflectDependencies(type),\n target: compiler.FactoryTarget.Injectable\n });\n }\n return ngFactoryDef;\n },\n // Leave this configurable so that the factories from directives or pipes can take precedence.\n configurable: true\n });\n }\n}\nconst USE_VALUE = getClosureSafeProperty({\n provide: String,\n useValue: getClosureSafeProperty\n});\nfunction isUseClassProvider(meta) {\n return meta.useClass !== undefined;\n}\nfunction isUseValueProvider(meta) {\n return USE_VALUE in meta;\n}\nfunction isUseFactoryProvider(meta) {\n return meta.useFactory !== undefined;\n}\nfunction isUseExistingProvider(meta) {\n return meta.useExisting !== undefined;\n}\nfunction getInjectableMetadata(type, srcMeta) {\n // Allow the compilation of a class with a `@Injectable()` decorator without parameters\n const meta = srcMeta || {\n providedIn: null\n };\n const compilerMeta = {\n name: type.name,\n type: type,\n typeArgumentCount: 0,\n providedIn: meta.providedIn\n };\n if ((isUseClassProvider(meta) || isUseFactoryProvider(meta)) && meta.deps !== undefined) {\n compilerMeta.deps = convertDependencies(meta.deps);\n }\n // Check to see if the user explicitly provided a `useXxxx` property.\n if (isUseClassProvider(meta)) {\n compilerMeta.useClass = meta.useClass;\n } else if (isUseValueProvider(meta)) {\n compilerMeta.useValue = meta.useValue;\n } else if (isUseFactoryProvider(meta)) {\n compilerMeta.useFactory = meta.useFactory;\n } else if (isUseExistingProvider(meta)) {\n compilerMeta.useExisting = meta.useExisting;\n }\n return compilerMeta;\n}\n\n/**\n * Injectable decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst Injectable = makeDecorator('Injectable', undefined, undefined, undefined, (type, meta) => compileInjectable(type, meta));\n\n/**\n * Create a new `Injector` which is configured using a `defType` of `InjectorType<any>`s.\n */\nfunction createInjector(defType, parent = null, additionalProviders = null, name) {\n const injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);\n injector.resolveInjectorInitializers();\n return injector;\n}\n/**\n * Creates a new injector without eagerly resolving its injector types. Can be used in places\n * where resolving the injector types immediately can lead to an infinite loop. The injector types\n * should be resolved at a later point by calling `_resolveInjectorDefTypes`.\n */\nfunction createInjectorWithoutInjectorInstances(defType, parent = null, additionalProviders = null, name, scopes = new Set()) {\n const providers = [additionalProviders || EMPTY_ARRAY, importProvidersFrom(defType)];\n name = name || (typeof defType === 'object' ? undefined : stringify(defType));\n return new R3Injector(providers, parent || getNullInjector(), name || null, scopes);\n}\n\n/**\n * Concrete injectors implement this interface. Injectors are configured\n * with [providers](guide/di/dependency-injection-providers) that associate\n * dependencies of various types with [injection tokens](guide/di/dependency-injection-providers).\n *\n * @see [DI Providers](guide/di/dependency-injection-providers).\n * @see {@link StaticProvider}\n *\n * @usageNotes\n *\n * The following example creates a service injector instance.\n *\n * {@example core/di/ts/provider_spec.ts region='ConstructorProvider'}\n *\n * ### Usage example\n *\n * {@example core/di/ts/injector_spec.ts region='Injector'}\n *\n * `Injector` returns itself when given `Injector` as a token:\n *\n * {@example core/di/ts/injector_spec.ts region='injectInjector'}\n *\n * @publicApi\n */\nclass Injector {\n static THROW_IF_NOT_FOUND = THROW_IF_NOT_FOUND;\n static NULL = new NullInjector();\n static create(options, parent) {\n if (Array.isArray(options)) {\n return createInjector({\n name: ''\n }, parent, options, '');\n } else {\n const name = options.name ?? '';\n return createInjector({\n name\n }, options.parent, options.providers, name);\n }\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: Injector,\n providedIn: 'any',\n factory: () => ɵɵinject(INJECTOR$1)\n });\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = -1 /* InjectorMarkers.Injector */;\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Creates a token that can be used to inject static attributes of the host node.\n *\n * @usageNotes\n * ### Injecting an attribute that is known to exist\n * ```ts\n * @Directive()\n * class MyDir {\n * attr: string = inject(new HostAttributeToken('some-attr'));\n * }\n * ```\n *\n * ### Optionally injecting an attribute\n * ```ts\n * @Directive()\n * class MyDir {\n * attr: string | null = inject(new HostAttributeToken('some-attr'), {optional: true});\n * }\n * ```\n * @publicApi\n */\nclass HostAttributeToken {\n attributeName;\n constructor(attributeName) {\n this.attributeName = attributeName;\n }\n /** @internal */\n __NG_ELEMENT_ID__ = () => ɵɵinjectAttribute(this.attributeName);\n toString() {\n return `HostAttributeToken ${this.attributeName}`;\n }\n}\n\n/**\n * A token that can be used to inject the tag name of the host node.\n *\n * @usageNotes\n * ### Injecting a tag name that is known to exist\n * ```ts\n * @Directive()\n * class MyDir {\n * tagName: string = inject(HOST_TAG_NAME);\n * }\n * ```\n *\n * ### Optionally injecting a tag name\n * ```ts\n * @Directive()\n * class MyDir {\n * tagName: string | null = inject(HOST_TAG_NAME, {optional: true});\n * }\n * ```\n * @publicApi\n */\nconst HOST_TAG_NAME = new InjectionToken(ngDevMode ? 'HOST_TAG_NAME' : '');\n// HOST_TAG_NAME should be resolved at the current node, similar to e.g. ElementRef,\n// so we manually specify __NG_ELEMENT_ID__ here, instead of using a factory.\n// tslint:disable-next-line:no-toplevel-property-access\nHOST_TAG_NAME.__NG_ELEMENT_ID__ = flags => {\n const tNode = getCurrentTNode();\n if (tNode === null) {\n throw new RuntimeError(204 /* RuntimeErrorCode.INVALID_INJECTION_TOKEN */, ngDevMode && 'HOST_TAG_NAME can only be injected in directives and components ' + 'during construction time (in a class constructor or as a class field initializer)');\n }\n if (tNode.type & 2 /* TNodeType.Element */) {\n return tNode.value;\n }\n if (flags & InjectFlags.Optional) {\n return null;\n }\n throw new RuntimeError(204 /* RuntimeErrorCode.INVALID_INJECTION_TOKEN */, ngDevMode && `HOST_TAG_NAME was used on ${getDevModeNodeName(tNode)} which doesn't have an underlying element in the DOM. ` + `This is invalid, and so the dependency should be marked as optional.`);\n};\nfunction getDevModeNodeName(tNode) {\n if (tNode.type & 8 /* TNodeType.ElementContainer */) {\n return 'an <ng-container>';\n } else if (tNode.type & 4 /* TNodeType.Container */) {\n return 'an <ng-template>';\n } else if (tNode.type & 128 /* TNodeType.LetDeclaration */) {\n return 'an @let declaration';\n } else {\n return 'a node';\n }\n}\n\n/**\n * @module\n * @description\n * The `di` module provides dependency injection container services.\n */\n\n/**\n * This file should not be necessary because node resolution should just default to `./di/index`!\n *\n * However it does not seem to work and it breaks:\n * - //packages/animations/browser/test:test_web_chromium-local\n * - //packages/compiler-cli/test:extract_i18n\n * - //packages/compiler-cli/test:ngc\n * - //packages/compiler-cli/test:perform_watch\n * - //packages/compiler-cli/test/diagnostics:check_types\n * - //packages/compiler-cli/test/transformers:test\n * - //packages/compiler/test:test\n * - //tools/public_api_guard:core_api\n *\n * Remove this file once the above is solved or wait until `ngc` is deleted and then it should be\n * safe to delete this file.\n */\n\nconst SCHEDULE_IN_ROOT_ZONE_DEFAULT = false;\n\n/**\n * `DestroyRef` lets you set callbacks to run for any cleanup or destruction behavior.\n * The scope of this destruction depends on where `DestroyRef` is injected. If `DestroyRef`\n * is injected in a component or directive, the callbacks run when that component or\n * directive is destroyed. Otherwise the callbacks run when a corresponding injector is destroyed.\n *\n * @publicApi\n */\nclass DestroyRef {\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = injectDestroyRef;\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ENV_ID__ = injector => injector;\n}\nclass NodeInjectorDestroyRef extends DestroyRef {\n _lView;\n constructor(_lView) {\n super();\n this._lView = _lView;\n }\n onDestroy(callback) {\n storeLViewOnDestroy(this._lView, callback);\n return () => removeLViewOnDestroy(this._lView, callback);\n }\n}\nfunction injectDestroyRef() {\n return new NodeInjectorDestroyRef(getLView());\n}\n\n/**\n * Injectable that is notified when an `LView` is made aware of changes to application state.\n */\nclass ChangeDetectionScheduler {}\n/** Token used to indicate if zoneless was enabled via provideZonelessChangeDetection(). */\nconst ZONELESS_ENABLED = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'Zoneless enabled' : '', {\n providedIn: 'root',\n factory: () => false\n});\n/** Token used to indicate `provideExperimentalZonelessChangeDetection` was used. */\nconst PROVIDED_ZONELESS = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'Zoneless provided' : '', {\n providedIn: 'root',\n factory: () => false\n});\nconst ZONELESS_SCHEDULER_DISABLED = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'scheduler disabled' : '');\n// TODO(atscott): Remove in v19. Scheduler should be done with runOutsideAngular.\nconst SCHEDULE_IN_ROOT_ZONE = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'run changes outside zone in root' : '');\n\n/**\n * Internal implementation of the pending tasks service.\n */\nclass PendingTasksInternal {\n taskId = 0;\n pendingTasks = new Set();\n get _hasPendingTasks() {\n return this.hasPendingTasks.value;\n }\n hasPendingTasks = new BehaviorSubject(false);\n add() {\n if (!this._hasPendingTasks) {\n this.hasPendingTasks.next(true);\n }\n const taskId = this.taskId++;\n this.pendingTasks.add(taskId);\n return taskId;\n }\n has(taskId) {\n return this.pendingTasks.has(taskId);\n }\n remove(taskId) {\n this.pendingTasks.delete(taskId);\n if (this.pendingTasks.size === 0 && this._hasPendingTasks) {\n this.hasPendingTasks.next(false);\n }\n }\n ngOnDestroy() {\n this.pendingTasks.clear();\n if (this._hasPendingTasks) {\n this.hasPendingTasks.next(false);\n }\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: PendingTasksInternal,\n providedIn: 'root',\n factory: () => new PendingTasksInternal()\n });\n}\n/**\n * Service that keeps track of pending tasks contributing to the stableness of Angular\n * application. While several existing Angular services (ex.: `HttpClient`) will internally manage\n * tasks influencing stability, this API gives control over stability to library and application\n * developers for specific cases not covered by Angular internals.\n *\n * The concept of stability comes into play in several important scenarios:\n * - SSR process needs to wait for the application stability before serializing and sending rendered\n * HTML;\n * - tests might want to delay assertions until the application becomes stable;\n *\n * @usageNotes\n * ```ts\n * const pendingTasks = inject(PendingTasks);\n * const taskCleanup = pendingTasks.add();\n * // do work that should block application's stability and then:\n * taskCleanup();\n * ```\n *\n * @publicApi\n * @developerPreview\n */\nclass PendingTasks {\n internalPendingTasks = inject(PendingTasksInternal);\n scheduler = inject(ChangeDetectionScheduler);\n /**\n * Adds a new task that should block application's stability.\n * @returns A cleanup function that removes a task when called.\n */\n add() {\n const taskId = this.internalPendingTasks.add();\n return () => {\n if (!this.internalPendingTasks.has(taskId)) {\n // This pending task has already been cleared.\n return;\n }\n // Notifying the scheduler will hold application stability open until the next tick.\n this.scheduler.notify(11 /* NotificationSource.PendingTaskRemoved */);\n this.internalPendingTasks.remove(taskId);\n };\n }\n /**\n * Runs an asynchronous function and blocks the application's stability until the function completes.\n *\n * ```ts\n * pendingTasks.run(async () => {\n * const userData = await fetch('/api/user');\n * this.userData.set(userData);\n * });\n * ```\n *\n * Application stability is at least delayed until the next tick after the `run` method resolves\n * so it is safe to make additional updates to application state that would require UI synchronization:\n *\n * ```ts\n * const userData = await pendingTasks.run(() => fetch('/api/user'));\n * this.userData.set(userData);\n * ```\n *\n * @param fn The asynchronous function to execute\n */\n async run(fn) {\n const removeTask = this.add();\n try {\n return await fn();\n } finally {\n removeTask();\n }\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: PendingTasks,\n providedIn: 'root',\n factory: () => new PendingTasks()\n });\n}\nclass EventEmitter_ extends Subject {\n // tslint:disable-next-line:require-internal-with-underscore\n __isAsync;\n destroyRef = undefined;\n pendingTasks = undefined;\n constructor(isAsync = false) {\n super();\n this.__isAsync = isAsync;\n // Attempt to retrieve a `DestroyRef` and `PendingTasks` optionally.\n // For backwards compatibility reasons, this cannot be required.\n if (isInInjectionContext()) {\n // `DestroyRef` is optional because it is not available in all contexts.\n // But it is useful to properly complete the `EventEmitter` if used with `outputToObservable`\n // when the component/directive is destroyed. (See `outputToObservable` for more details.)\n this.destroyRef = inject(DestroyRef, {\n optional: true\n }) ?? undefined;\n this.pendingTasks = inject(PendingTasksInternal, {\n optional: true\n }) ?? undefined;\n }\n }\n emit(value) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n super.next(value);\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n subscribe(observerOrNext, error, complete) {\n let nextFn = observerOrNext;\n let errorFn = error || (() => null);\n let completeFn = complete;\n if (observerOrNext && typeof observerOrNext === 'object') {\n const observer = observerOrNext;\n nextFn = observer.next?.bind(observer);\n errorFn = observer.error?.bind(observer);\n completeFn = observer.complete?.bind(observer);\n }\n if (this.__isAsync) {\n errorFn = this.wrapInTimeout(errorFn);\n if (nextFn) {\n nextFn = this.wrapInTimeout(nextFn);\n }\n if (completeFn) {\n completeFn = this.wrapInTimeout(completeFn);\n }\n }\n const sink = super.subscribe({\n next: nextFn,\n error: errorFn,\n complete: completeFn\n });\n if (observerOrNext instanceof Subscription) {\n observerOrNext.add(sink);\n }\n return sink;\n }\n wrapInTimeout(fn) {\n return value => {\n const taskId = this.pendingTasks?.add();\n setTimeout(() => {\n fn(value);\n if (taskId !== undefined) {\n this.pendingTasks?.remove(taskId);\n }\n });\n };\n }\n}\n/**\n * @publicApi\n */\nconst EventEmitter = EventEmitter_;\nfunction noop(...args) {\n // Do nothing.\n}\n\n/**\n * Gets a scheduling function that runs the callback after the first of setTimeout and\n * requestAnimationFrame resolves.\n *\n * - `requestAnimationFrame` ensures that change detection runs ahead of a browser repaint.\n * This ensures that the create and update passes of a change detection always happen\n * in the same frame.\n * - When the browser is resource-starved, `rAF` can execute _before_ a `setTimeout` because\n * rendering is a very high priority process. This means that `setTimeout` cannot guarantee\n * same-frame create and update pass, when `setTimeout` is used to schedule the update phase.\n * - While `rAF` gives us the desirable same-frame updates, it has two limitations that\n * prevent it from being used alone. First, it does not run in background tabs, which would\n * prevent Angular from initializing an application when opened in a new tab (for example).\n * Second, repeated calls to requestAnimationFrame will execute at the refresh rate of the\n * hardware (~16ms for a 60Hz display). This would cause significant slowdown of tests that\n * are written with several updates and asserts in the form of \"update; await stable; assert;\".\n * - Both `setTimeout` and `rAF` are able to \"coalesce\" several events from a single user\n * interaction into a single change detection. Importantly, this reduces view tree traversals when\n * compared to an alternative timing mechanism like `queueMicrotask`, where change detection would\n * then be interleaves between each event.\n *\n * By running change detection after the first of `setTimeout` and `rAF` to execute, we get the\n * best of both worlds.\n *\n * @returns a function to cancel the scheduled callback\n */\nfunction scheduleCallbackWithRafRace(callback) {\n let timeoutId;\n let animationFrameId;\n function cleanup() {\n callback = noop;\n try {\n if (animationFrameId !== undefined && typeof cancelAnimationFrame === 'function') {\n cancelAnimationFrame(animationFrameId);\n }\n if (timeoutId !== undefined) {\n clearTimeout(timeoutId);\n }\n } catch {\n // Clearing/canceling can fail in tests due to the timing of functions being patched and unpatched\n // Just ignore the errors - we protect ourselves from this issue by also making the callback a no-op.\n }\n }\n timeoutId = setTimeout(() => {\n callback();\n cleanup();\n });\n if (typeof requestAnimationFrame === 'function') {\n animationFrameId = requestAnimationFrame(() => {\n callback();\n cleanup();\n });\n }\n return () => cleanup();\n}\nfunction scheduleCallbackWithMicrotask(callback) {\n queueMicrotask(() => callback());\n return () => {\n callback = noop;\n };\n}\nclass AsyncStackTaggingZoneSpec {\n createTask;\n constructor(namePrefix, consoleAsyncStackTaggingImpl = console) {\n this.name = 'asyncStackTagging for ' + namePrefix;\n this.createTask = consoleAsyncStackTaggingImpl?.createTask ?? (() => null);\n }\n // ZoneSpec implementation below.\n name;\n onScheduleTask(delegate, _current, target, task) {\n task.consoleTask = this.createTask(`Zone - ${task.source || task.type}`);\n return delegate.scheduleTask(target, task);\n }\n onInvokeTask(delegate, _currentZone, targetZone, task, applyThis, applyArgs) {\n let ret;\n if (task.consoleTask) {\n ret = task.consoleTask.run(() => delegate.invokeTask(targetZone, task, applyThis, applyArgs));\n } else {\n ret = delegate.invokeTask(targetZone, task, applyThis, applyArgs);\n }\n return ret;\n }\n}\nconst isAngularZoneProperty = 'isAngularZone';\nconst angularZoneInstanceIdProperty = isAngularZoneProperty + '_ID';\nlet ngZoneInstanceId = 0;\n/**\n * An injectable service for executing work inside or outside of the Angular zone.\n *\n * The most common use of this service is to optimize performance when starting a work consisting of\n * one or more asynchronous tasks that don't require UI updates or error handling to be handled by\n * Angular. Such tasks can be kicked off via {@link #runOutsideAngular} and if needed, these tasks\n * can reenter the Angular zone via {@link #run}.\n *\n * <!-- TODO: add/fix links to:\n * - docs explaining zones and the use of zones in Angular and change-detection\n * - link to runOutsideAngular/run (throughout this file!)\n * -->\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * import {Component, NgZone} from '@angular/core';\n * import {NgIf} from '@angular/common';\n *\n * @Component({\n * selector: 'ng-zone-demo',\n * template: `\n * <h2>Demo: NgZone</h2>\n *\n * <p>Progress: {{progress}}%</p>\n * <p *ngIf=\"progress >= 100\">Done processing {{label}} of Angular zone!</p>\n *\n * <button (click)=\"processWithinAngularZone()\">Process within Angular zone</button>\n * <button (click)=\"processOutsideOfAngularZone()\">Process outside of Angular zone</button>\n * `,\n * })\n * export class NgZoneDemo {\n * progress: number = 0;\n * label: string;\n *\n * constructor(private _ngZone: NgZone) {}\n *\n * // Loop inside the Angular zone\n * // so the UI DOES refresh after each setTimeout cycle\n * processWithinAngularZone() {\n * this.label = 'inside';\n * this.progress = 0;\n * this._increaseProgress(() => console.log('Inside Done!'));\n * }\n *\n * // Loop outside of the Angular zone\n * // so the UI DOES NOT refresh after each setTimeout cycle\n * processOutsideOfAngularZone() {\n * this.label = 'outside';\n * this.progress = 0;\n * this._ngZone.runOutsideAngular(() => {\n * this._increaseProgress(() => {\n * // reenter the Angular zone and display done\n * this._ngZone.run(() => { console.log('Outside Done!'); });\n * });\n * });\n * }\n *\n * _increaseProgress(doneCallback: () => void) {\n * this.progress += 1;\n * console.log(`Current progress: ${this.progress}%`);\n *\n * if (this.progress < 100) {\n * window.setTimeout(() => this._increaseProgress(doneCallback), 10);\n * } else {\n * doneCallback();\n * }\n * }\n * }\n * ```\n *\n * @publicApi\n */\nclass NgZone {\n hasPendingMacrotasks = false;\n hasPendingMicrotasks = false;\n /**\n * Whether there are no outstanding microtasks or macrotasks.\n */\n isStable = true;\n /**\n * Notifies when code enters Angular Zone. This gets fired first on VM Turn.\n */\n onUnstable = new EventEmitter(false);\n /**\n * Notifies when there is no more microtasks enqueued in the current VM Turn.\n * This is a hint for Angular to do change detection, which may enqueue more microtasks.\n * For this reason this event can fire multiple times per VM Turn.\n */\n onMicrotaskEmpty = new EventEmitter(false);\n /**\n * Notifies when the last `onMicrotaskEmpty` has run and there are no more microtasks, which\n * implies we are about to relinquish VM turn.\n * This event gets called just once.\n */\n onStable = new EventEmitter(false);\n /**\n * Notifies that an error has been delivered.\n */\n onError = new EventEmitter(false);\n constructor(options) {\n const {\n enableLongStackTrace = false,\n shouldCoalesceEventChangeDetection = false,\n shouldCoalesceRunChangeDetection = false,\n scheduleInRootZone = SCHEDULE_IN_ROOT_ZONE_DEFAULT\n } = options;\n if (typeof Zone == 'undefined') {\n throw new RuntimeError(908 /* RuntimeErrorCode.MISSING_ZONEJS */, ngDevMode && `In this configuration Angular requires Zone.js`);\n }\n Zone.assertZonePatched();\n const self = this;\n self._nesting = 0;\n self._outer = self._inner = Zone.current;\n // AsyncStackTaggingZoneSpec provides `linked stack traces` to show\n // where the async operation is scheduled. For more details, refer\n // to this article, https://developer.chrome.com/blog/devtools-better-angular-debugging/\n // And we only import this AsyncStackTaggingZoneSpec in development mode,\n // in the production mode, the AsyncStackTaggingZoneSpec will be tree shaken away.\n if (ngDevMode) {\n self._inner = self._inner.fork(new AsyncStackTaggingZoneSpec('Angular'));\n }\n if (Zone['TaskTrackingZoneSpec']) {\n self._inner = self._inner.fork(new Zone['TaskTrackingZoneSpec']());\n }\n if (enableLongStackTrace && Zone['longStackTraceZoneSpec']) {\n self._inner = self._inner.fork(Zone['longStackTraceZoneSpec']);\n }\n // if shouldCoalesceRunChangeDetection is true, all tasks including event tasks will be\n // coalesced, so shouldCoalesceEventChangeDetection option is not necessary and can be skipped.\n self.shouldCoalesceEventChangeDetection = !shouldCoalesceRunChangeDetection && shouldCoalesceEventChangeDetection;\n self.shouldCoalesceRunChangeDetection = shouldCoalesceRunChangeDetection;\n self.callbackScheduled = false;\n self.scheduleInRootZone = scheduleInRootZone;\n forkInnerZoneWithAngularBehavior(self);\n }\n /**\n This method checks whether the method call happens within an Angular Zone instance.\n */\n static isInAngularZone() {\n // Zone needs to be checked, because this method might be called even when NoopNgZone is used.\n return typeof Zone !== 'undefined' && Zone.current.get(isAngularZoneProperty) === true;\n }\n /**\n Assures that the method is called within the Angular Zone, otherwise throws an error.\n */\n static assertInAngularZone() {\n if (!NgZone.isInAngularZone()) {\n throw new RuntimeError(909 /* RuntimeErrorCode.UNEXPECTED_ZONE_STATE */, ngDevMode && 'Expected to be in Angular Zone, but it is not!');\n }\n }\n /**\n Assures that the method is called outside of the Angular Zone, otherwise throws an error.\n */\n static assertNotInAngularZone() {\n if (NgZone.isInAngularZone()) {\n throw new RuntimeError(909 /* RuntimeErrorCode.UNEXPECTED_ZONE_STATE */, ngDevMode && 'Expected to not be in Angular Zone, but it is!');\n }\n }\n /**\n * Executes the `fn` function synchronously within the Angular zone and returns value returned by\n * the function.\n *\n * Running functions via `run` allows you to reenter Angular zone from a task that was executed\n * outside of the Angular zone (typically started via {@link #runOutsideAngular}).\n *\n * Any future tasks or microtasks scheduled from within this function will continue executing from\n * within the Angular zone.\n *\n * If a synchronous error happens it will be rethrown and not reported via `onError`.\n */\n run(fn, applyThis, applyArgs) {\n return this._inner.run(fn, applyThis, applyArgs);\n }\n /**\n * Executes the `fn` function synchronously within the Angular zone as a task and returns value\n * returned by the function.\n *\n * Running functions via `runTask` allows you to reenter Angular zone from a task that was executed\n * outside of the Angular zone (typically started via {@link #runOutsideAngular}).\n *\n * Any future tasks or microtasks scheduled from within this function will continue executing from\n * within the Angular zone.\n *\n * If a synchronous error happens it will be rethrown and not reported via `onError`.\n */\n runTask(fn, applyThis, applyArgs, name) {\n const zone = this._inner;\n const task = zone.scheduleEventTask('NgZoneEvent: ' + name, fn, EMPTY_PAYLOAD, noop, noop);\n try {\n return zone.runTask(task, applyThis, applyArgs);\n } finally {\n zone.cancelTask(task);\n }\n }\n /**\n * Same as `run`, except that synchronous errors are caught and forwarded via `onError` and not\n * rethrown.\n */\n runGuarded(fn, applyThis, applyArgs) {\n return this._inner.runGuarded(fn, applyThis, applyArgs);\n }\n /**\n * Executes the `fn` function synchronously in Angular's parent zone and returns value returned by\n * the function.\n *\n * Running functions via {@link #runOutsideAngular} allows you to escape Angular's zone and do\n * work that\n * doesn't trigger Angular change-detection or is subject to Angular's error handling.\n *\n * Any future tasks or microtasks scheduled from within this function will continue executing from\n * outside of the Angular zone.\n *\n * Use {@link #run} to reenter the Angular zone and do work that updates the application model.\n */\n runOutsideAngular(fn) {\n return this._outer.run(fn);\n }\n}\nconst EMPTY_PAYLOAD = {};\nfunction checkStable(zone) {\n // TODO: @JiaLiPassion, should check zone.isCheckStableRunning to prevent\n // re-entry. The case is:\n //\n // @Component({...})\n // export class AppComponent {\n // constructor(private ngZone: NgZone) {\n // this.ngZone.onStable.subscribe(() => {\n // this.ngZone.run(() => console.log('stable'););\n // });\n // }\n //\n // The onStable subscriber run another function inside ngZone\n // which causes `checkStable()` re-entry.\n // But this fix causes some issues in g3, so this fix will be\n // launched in another PR.\n if (zone._nesting == 0 && !zone.hasPendingMicrotasks && !zone.isStable) {\n try {\n zone._nesting++;\n zone.onMicrotaskEmpty.emit(null);\n } finally {\n zone._nesting--;\n if (!zone.hasPendingMicrotasks) {\n try {\n zone.runOutsideAngular(() => zone.onStable.emit(null));\n } finally {\n zone.isStable = true;\n }\n }\n }\n }\n}\nfunction delayChangeDetectionForEvents(zone) {\n /**\n * We also need to check _nesting here\n * Consider the following case with shouldCoalesceRunChangeDetection = true\n *\n * ngZone.run(() => {});\n * ngZone.run(() => {});\n *\n * We want the two `ngZone.run()` only trigger one change detection\n * when shouldCoalesceRunChangeDetection is true.\n * And because in this case, change detection run in async way(requestAnimationFrame),\n * so we also need to check the _nesting here to prevent multiple\n * change detections.\n */\n if (zone.isCheckStableRunning || zone.callbackScheduled) {\n return;\n }\n zone.callbackScheduled = true;\n function scheduleCheckStable() {\n scheduleCallbackWithRafRace(() => {\n zone.callbackScheduled = false;\n updateMicroTaskStatus(zone);\n zone.isCheckStableRunning = true;\n checkStable(zone);\n zone.isCheckStableRunning = false;\n });\n }\n if (zone.scheduleInRootZone) {\n Zone.root.run(() => {\n scheduleCheckStable();\n });\n } else {\n zone._outer.run(() => {\n scheduleCheckStable();\n });\n }\n updateMicroTaskStatus(zone);\n}\nfunction forkInnerZoneWithAngularBehavior(zone) {\n const delayChangeDetectionForEventsDelegate = () => {\n delayChangeDetectionForEvents(zone);\n };\n const instanceId = ngZoneInstanceId++;\n zone._inner = zone._inner.fork({\n name: 'angular',\n properties: {\n [isAngularZoneProperty]: true,\n [angularZoneInstanceIdProperty]: instanceId,\n [angularZoneInstanceIdProperty + instanceId]: true\n },\n onInvokeTask: (delegate, current, target, task, applyThis, applyArgs) => {\n // Prevent triggering change detection when the flag is detected.\n if (shouldBeIgnoredByZone(applyArgs)) {\n return delegate.invokeTask(target, task, applyThis, applyArgs);\n }\n try {\n onEnter(zone);\n return delegate.invokeTask(target, task, applyThis, applyArgs);\n } finally {\n if (zone.shouldCoalesceEventChangeDetection && task.type === 'eventTask' || zone.shouldCoalesceRunChangeDetection) {\n delayChangeDetectionForEventsDelegate();\n }\n onLeave(zone);\n }\n },\n onInvoke: (delegate, current, target, callback, applyThis, applyArgs, source) => {\n try {\n onEnter(zone);\n return delegate.invoke(target, callback, applyThis, applyArgs, source);\n } finally {\n if (zone.shouldCoalesceRunChangeDetection &&\n // Do not delay change detection when the task is the scheduler's tick.\n // We need to synchronously trigger the stability logic so that the\n // zone-based scheduler can prevent a duplicate ApplicationRef.tick\n // by first checking if the scheduler tick is running. This does seem a bit roundabout,\n // but we _do_ still want to trigger all the correct events when we exit the zone.run\n // (`onMicrotaskEmpty` and `onStable` _should_ emit; developers can have code which\n // relies on these events happening after change detection runs).\n // Note: `zone.callbackScheduled` is already in delayChangeDetectionForEventsDelegate\n // but is added here as well to prevent reads of applyArgs when not necessary\n !zone.callbackScheduled && !isSchedulerTick(applyArgs)) {\n delayChangeDetectionForEventsDelegate();\n }\n onLeave(zone);\n }\n },\n onHasTask: (delegate, current, target, hasTaskState) => {\n delegate.hasTask(target, hasTaskState);\n if (current === target) {\n // We are only interested in hasTask events which originate from our zone\n // (A child hasTask event is not interesting to us)\n if (hasTaskState.change == 'microTask') {\n zone._hasPendingMicrotasks = hasTaskState.microTask;\n updateMicroTaskStatus(zone);\n checkStable(zone);\n } else if (hasTaskState.change == 'macroTask') {\n zone.hasPendingMacrotasks = hasTaskState.macroTask;\n }\n }\n },\n onHandleError: (delegate, current, target, error) => {\n delegate.handleError(target, error);\n zone.runOutsideAngular(() => zone.onError.emit(error));\n return false;\n }\n });\n}\nfunction updateMicroTaskStatus(zone) {\n if (zone._hasPendingMicrotasks || (zone.shouldCoalesceEventChangeDetection || zone.shouldCoalesceRunChangeDetection) && zone.callbackScheduled === true) {\n zone.hasPendingMicrotasks = true;\n } else {\n zone.hasPendingMicrotasks = false;\n }\n}\nfunction onEnter(zone) {\n zone._nesting++;\n if (zone.isStable) {\n zone.isStable = false;\n zone.onUnstable.emit(null);\n }\n}\nfunction onLeave(zone) {\n zone._nesting--;\n checkStable(zone);\n}\n/**\n * Provides a noop implementation of `NgZone` which does nothing. This zone requires explicit calls\n * to framework to perform rendering.\n */\nclass NoopNgZone {\n hasPendingMicrotasks = false;\n hasPendingMacrotasks = false;\n isStable = true;\n onUnstable = new EventEmitter();\n onMicrotaskEmpty = new EventEmitter();\n onStable = new EventEmitter();\n onError = new EventEmitter();\n run(fn, applyThis, applyArgs) {\n return fn.apply(applyThis, applyArgs);\n }\n runGuarded(fn, applyThis, applyArgs) {\n return fn.apply(applyThis, applyArgs);\n }\n runOutsideAngular(fn) {\n return fn();\n }\n runTask(fn, applyThis, applyArgs, name) {\n return fn.apply(applyThis, applyArgs);\n }\n}\nfunction shouldBeIgnoredByZone(applyArgs) {\n return hasApplyArgsData(applyArgs, '__ignore_ng_zone__');\n}\nfunction isSchedulerTick(applyArgs) {\n return hasApplyArgsData(applyArgs, '__scheduler_tick__');\n}\nfunction hasApplyArgsData(applyArgs, key) {\n if (!Array.isArray(applyArgs)) {\n return false;\n }\n // We should only ever get 1 arg passed through to invokeTask.\n // Short circuit here incase that behavior changes.\n if (applyArgs.length !== 1) {\n return false;\n }\n return applyArgs[0]?.data?.[key] === true;\n}\nfunction getNgZone(ngZoneToUse = 'zone.js', options) {\n if (ngZoneToUse === 'noop') {\n return new NoopNgZone();\n }\n if (ngZoneToUse === 'zone.js') {\n return new NgZone(options);\n }\n return ngZoneToUse;\n}\n\n// Public API for Zone\n\n/**\n * Provides a hook for centralized exception handling.\n *\n * The default implementation of `ErrorHandler` prints error messages to the `console`. To\n * intercept error handling, write a custom exception handler that replaces this default as\n * appropriate for your app.\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * class MyErrorHandler implements ErrorHandler {\n * handleError(error) {\n * // do something with the exception\n * }\n * }\n *\n * // Provide in standalone apps\n * bootstrapApplication(AppComponent, {\n * providers: [{provide: ErrorHandler, useClass: MyErrorHandler}]\n * })\n *\n * // Provide in module-based apps\n * @NgModule({\n * providers: [{provide: ErrorHandler, useClass: MyErrorHandler}]\n * })\n * class MyModule {}\n * ```\n *\n * @publicApi\n */\nclass ErrorHandler {\n /**\n * @internal\n */\n _console = console;\n handleError(error) {\n this._console.error('ERROR', error);\n }\n}\n/**\n * `InjectionToken` used to configure how to call the `ErrorHandler`.\n *\n * `NgZone` is provided by default today so the default (and only) implementation for this\n * is calling `ErrorHandler.handleError` outside of the Angular zone.\n */\nconst INTERNAL_APPLICATION_ERROR_HANDLER = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'internal error handler' : '', {\n providedIn: 'root',\n factory: () => {\n const zone = inject(NgZone);\n const userErrorHandler = inject(ErrorHandler);\n return e => zone.runOutsideAngular(() => userErrorHandler.handleError(e));\n }\n});\n\n/**\n * An `OutputEmitterRef` is created by the `output()` function and can be\n * used to emit values to consumers of your directive or component.\n *\n * Consumers of your directive/component can bind to the output and\n * subscribe to changes via the bound event syntax. For example:\n *\n * ```html\n * <my-comp (valueChange)=\"processNewValue($event)\" />\n * ```\n *\n * @publicAPI\n */\nclass OutputEmitterRef {\n destroyed = false;\n listeners = null;\n errorHandler = inject(ErrorHandler, {\n optional: true\n });\n /** @internal */\n destroyRef = inject(DestroyRef);\n constructor() {\n // Clean-up all listeners and mark as destroyed upon destroy.\n this.destroyRef.onDestroy(() => {\n this.destroyed = true;\n this.listeners = null;\n });\n }\n subscribe(callback) {\n if (this.destroyed) {\n throw new RuntimeError(953 /* RuntimeErrorCode.OUTPUT_REF_DESTROYED */, ngDevMode && 'Unexpected subscription to destroyed `OutputRef`. ' + 'The owning directive/component is destroyed.');\n }\n (this.listeners ??= []).push(callback);\n return {\n unsubscribe: () => {\n const idx = this.listeners?.indexOf(callback);\n if (idx !== undefined && idx !== -1) {\n this.listeners?.splice(idx, 1);\n }\n }\n };\n }\n /** Emits a new value to the output. */\n emit(value) {\n if (this.destroyed) {\n throw new RuntimeError(953 /* RuntimeErrorCode.OUTPUT_REF_DESTROYED */, ngDevMode && 'Unexpected emit for destroyed `OutputRef`. ' + 'The owning directive/component is destroyed.');\n }\n if (this.listeners === null) {\n return;\n }\n const previousConsumer = setActiveConsumer$1(null);\n try {\n for (const listenerFn of this.listeners) {\n try {\n listenerFn(value);\n } catch (err) {\n this.errorHandler?.handleError(err);\n }\n }\n } finally {\n setActiveConsumer$1(previousConsumer);\n }\n }\n}\n/** Gets the owning `DestroyRef` for the given output. */\nfunction getOutputDestroyRef(ref) {\n return ref.destroyRef;\n}\n\n/**\n * The `output` function allows declaration of Angular outputs in\n * directives and components.\n *\n * You can use outputs to emit values to parent directives and component.\n * Parents can subscribe to changes via:\n *\n * - template event bindings. For example, `(myOutput)=\"doSomething($event)\"`\n * - programmatic subscription by using `OutputRef#subscribe`.\n *\n * @usageNotes\n *\n * To use `output()`, import the function from `@angular/core`.\n *\n * ```ts\n * import {output} from '@angular/core';\n * ```\n *\n * Inside your component, introduce a new class member and initialize\n * it with a call to `output`.\n *\n * ```ts\n * @Directive({\n * ...\n * })\n * export class MyDir {\n * nameChange = output<string>(); // OutputEmitterRef<string>\n * onClick = output(); // OutputEmitterRef<void>\n * }\n * ```\n *\n * You can emit values to consumers of your directive, by using\n * the `emit` method from `OutputEmitterRef`.\n *\n * ```ts\n * updateName(newName: string): void {\n * this.nameChange.emit(newName);\n * }\n * ```\n * @initializerApiFunction {\"showTypesInSignaturePreview\": true}\n * @publicAPI\n */\nfunction output(opts) {\n ngDevMode && assertInInjectionContext(output);\n return new OutputEmitterRef();\n}\nfunction inputFunction(initialValue, opts) {\n ngDevMode && assertInInjectionContext(input);\n return createInputSignal(initialValue, opts);\n}\nfunction inputRequiredFunction(opts) {\n ngDevMode && assertInInjectionContext(input);\n return createInputSignal(REQUIRED_UNSET_VALUE, opts);\n}\n/**\n * The `input` function allows declaration of Angular inputs in directives\n * and components.\n *\n * There are two variants of inputs that can be declared:\n *\n * 1. **Optional inputs** with an initial value.\n * 2. **Required inputs** that consumers need to set.\n *\n * By default, the `input` function will declare optional inputs that\n * always have an initial value. Required inputs can be declared\n * using the `input.required()` function.\n *\n * Inputs are signals. The values of an input are exposed as a `Signal`.\n * The signal always holds the latest value of the input that is bound\n * from the parent.\n *\n * @usageNotes\n * To use signal-based inputs, import `input` from `@angular/core`.\n *\n * ```ts\n * import {input} from '@angular/core`;\n * ```\n *\n * Inside your component, introduce a new class member and initialize\n * it with a call to `input` or `input.required`.\n *\n * ```ts\n * @Component({\n * ...\n * })\n * export class UserProfileComponent {\n * firstName = input<string>(); // Signal<string|undefined>\n * lastName = input.required<string>(); // Signal<string>\n * age = input(0) // Signal<number>\n * }\n * ```\n *\n * Inside your component template, you can display values of the inputs\n * by calling the signal.\n *\n * ```html\n * <span>{{firstName()}}</span>\n * ```\n *\n * @publicAPI\n * @initializerApiFunction\n */\nconst input = (() => {\n // Note: This may be considered a side-effect, but nothing will depend on\n // this assignment, unless this `input` constant export is accessed. It's a\n // self-contained side effect that is local to the user facing`input` export.\n inputFunction.required = inputRequiredFunction;\n return inputFunction;\n})();\n\n/**\n * Creates an ElementRef from the most recent node.\n *\n * @returns The ElementRef instance to use\n */\nfunction injectElementRef() {\n return createElementRef(getCurrentTNode(), getLView());\n}\n/**\n * Creates an ElementRef given a node.\n *\n * @param tNode The node for which you'd like an ElementRef\n * @param lView The view to which the node belongs\n * @returns The ElementRef instance to use\n */\nfunction createElementRef(tNode, lView) {\n return new ElementRef(getNativeByTNode(tNode, lView));\n}\n/**\n * A wrapper around a native element inside of a View.\n *\n * An `ElementRef` is backed by a render-specific element. In the browser, this is usually a DOM\n * element.\n *\n * @security Permitting direct access to the DOM can make your application more vulnerable to\n * XSS attacks. Carefully review any use of `ElementRef` in your code. For more detail, see the\n * [Security Guide](https://g.co/ng/security).\n *\n * @publicApi\n */\n// Note: We don't expose things like `Injector`, `ViewContainer`, ... here,\n// i.e. users have to ask for what they need. With that, we can build better analysis tools\n// and could do better codegen in the future.\nclass ElementRef {\n /**\n * <div class=\"callout is-critical\">\n * <header>Use with caution</header>\n * <p>\n * Use this API as the last resort when direct access to DOM is needed. Use templating and\n * data-binding provided by Angular instead. Alternatively you can take a look at\n * {@link Renderer2} which provides an API that can be safely used.\n * </p>\n * </div>\n */\n nativeElement;\n constructor(nativeElement) {\n this.nativeElement = nativeElement;\n }\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = injectElementRef;\n}\n/**\n * Unwraps `ElementRef` and return the `nativeElement`.\n *\n * @param value value to unwrap\n * @returns `nativeElement` if `ElementRef` otherwise returns value as is.\n */\nfunction unwrapElementRef(value) {\n return value instanceof ElementRef ? value.nativeElement : value;\n}\n\n/**\n * Checks if the given `value` is a reactive `Signal`.\n */\nfunction isSignal(value) {\n return typeof value === 'function' && value[SIGNAL$1] !== undefined;\n}\n\n/** Symbol used distinguish `WritableSignal` from other non-writable signals and functions. */\nconst ɵWRITABLE_SIGNAL = /* @__PURE__ */Symbol('WRITABLE_SIGNAL');\n/**\n * Utility function used during template type checking to extract the value from a `WritableSignal`.\n * @codeGenApi\n */\nfunction ɵunwrapWritableSignal(value) {\n // Note: the function uses `WRITABLE_SIGNAL` as a brand instead of `WritableSignal<T>`,\n // because the latter incorrectly unwraps non-signal getter functions.\n return null;\n}\n/**\n * Create a `Signal` that can be set or updated directly.\n */\nfunction signal(initialValue, options) {\n const signalFn = createSignal$1(initialValue);\n const node = signalFn[SIGNAL$1];\n if (options?.equal) {\n node.equal = options.equal;\n }\n signalFn.set = newValue => signalSetFn$1(node, newValue);\n signalFn.update = updateFn => signalUpdateFn$1(node, updateFn);\n signalFn.asReadonly = signalAsReadonlyFn.bind(signalFn);\n if (ngDevMode) {\n signalFn.toString = () => `[Signal: ${signalFn()}]`;\n node.debugName = options?.debugName;\n }\n return signalFn;\n}\nfunction signalAsReadonlyFn() {\n const node = this[SIGNAL$1];\n if (node.readonlyFn === undefined) {\n const readonlyFn = () => this();\n readonlyFn[SIGNAL$1] = node;\n node.readonlyFn = readonlyFn;\n }\n return node.readonlyFn;\n}\n/**\n * Checks if the given `value` is a writeable signal.\n */\nfunction isWritableSignal(value) {\n return isSignal(value) && typeof value.set === 'function';\n}\nfunction symbolIterator() {\n // @ts-expect-error accessing a private member\n return this._results[Symbol.iterator]();\n}\n/**\n * An unmodifiable list of items that Angular keeps up to date when the state\n * of the application changes.\n *\n * The type of object that {@link ViewChildren}, {@link ContentChildren}, and {@link QueryList}\n * provide.\n *\n * Implements an iterable interface, therefore it can be used in both ES6\n * javascript `for (var i of items)` loops as well as in Angular templates with\n * `*ngFor=\"let i of myList\"`.\n *\n * Changes can be observed by subscribing to the changes `Observable`.\n *\n * NOTE: In the future this class will implement an `Observable` interface.\n *\n * @usageNotes\n * ### Example\n * ```ts\n * @Component({...})\n * class Container {\n * @ViewChildren(Item) items:QueryList<Item>;\n * }\n * ```\n *\n * @publicApi\n */\nclass QueryList {\n _emitDistinctChangesOnly;\n dirty = true;\n _onDirty = undefined;\n _results = [];\n _changesDetected = false;\n _changes = undefined;\n length = 0;\n first = undefined;\n last = undefined;\n /**\n * Returns `Observable` of `QueryList` notifying the subscriber of changes.\n */\n get changes() {\n return this._changes ??= new Subject();\n }\n /**\n * @param emitDistinctChangesOnly Whether `QueryList.changes` should fire only when actual change\n * has occurred. Or if it should fire when query is recomputed. (recomputing could resolve in\n * the same result)\n */\n constructor(_emitDistinctChangesOnly = false) {\n this._emitDistinctChangesOnly = _emitDistinctChangesOnly;\n }\n /**\n * Returns the QueryList entry at `index`.\n */\n get(index) {\n return this._results[index];\n }\n /**\n * See\n * [Array.map](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/map)\n */\n map(fn) {\n return this._results.map(fn);\n }\n filter(fn) {\n return this._results.filter(fn);\n }\n /**\n * See\n * [Array.find](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/find)\n */\n find(fn) {\n return this._results.find(fn);\n }\n /**\n * See\n * [Array.reduce](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/reduce)\n */\n reduce(fn, init) {\n return this._results.reduce(fn, init);\n }\n /**\n * See\n * [Array.forEach](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/forEach)\n */\n forEach(fn) {\n this._results.forEach(fn);\n }\n /**\n * See\n * [Array.some](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/some)\n */\n some(fn) {\n return this._results.some(fn);\n }\n /**\n * Returns a copy of the internal results list as an Array.\n */\n toArray() {\n return this._results.slice();\n }\n toString() {\n return this._results.toString();\n }\n /**\n * Updates the stored data of the query list, and resets the `dirty` flag to `false`, so that\n * on change detection, it will not notify of changes to the queries, unless a new change\n * occurs.\n *\n * @param resultsTree The query results to store\n * @param identityAccessor Optional function for extracting stable object identity from a value\n * in the array. This function is executed for each element of the query result list while\n * comparing current query list with the new one (provided as a first argument of the `reset`\n * function) to detect if the lists are different. If the function is not provided, elements\n * are compared as is (without any pre-processing).\n */\n reset(resultsTree, identityAccessor) {\n this.dirty = false;\n const newResultFlat = flatten(resultsTree);\n if (this._changesDetected = !arrayEquals(this._results, newResultFlat, identityAccessor)) {\n this._results = newResultFlat;\n this.length = newResultFlat.length;\n this.last = newResultFlat[this.length - 1];\n this.first = newResultFlat[0];\n }\n }\n /**\n * Triggers a change event by emitting on the `changes` {@link EventEmitter}.\n */\n notifyOnChanges() {\n if (this._changes !== undefined && (this._changesDetected || !this._emitDistinctChangesOnly)) this._changes.next(this);\n }\n /** @internal */\n onDirty(cb) {\n this._onDirty = cb;\n }\n /** internal */\n setDirty() {\n this.dirty = true;\n this._onDirty?.();\n }\n /** internal */\n destroy() {\n if (this._changes !== undefined) {\n this._changes.complete();\n this._changes.unsubscribe();\n }\n }\n [Symbol.iterator] = (() => symbolIterator)();\n}\n\n/**\n * The name of an attribute that can be added to the hydration boundary node\n * (component host node) to disable hydration for the content within that boundary.\n */\nconst SKIP_HYDRATION_ATTR_NAME = 'ngSkipHydration';\n/** Lowercase name of the `ngSkipHydration` attribute used for case-insensitive comparisons. */\nconst SKIP_HYDRATION_ATTR_NAME_LOWER_CASE = 'ngskiphydration';\n/**\n * Helper function to check if a given TNode has the 'ngSkipHydration' attribute.\n */\nfunction hasSkipHydrationAttrOnTNode(tNode) {\n const attrs = tNode.mergedAttrs;\n if (attrs === null) return false;\n // only ever look at the attribute name and skip the values\n for (let i = 0; i < attrs.length; i += 2) {\n const value = attrs[i];\n // This is a marker, which means that the static attributes section is over,\n // so we can exit early.\n if (typeof value === 'number') return false;\n if (typeof value === 'string' && value.toLowerCase() === SKIP_HYDRATION_ATTR_NAME_LOWER_CASE) {\n return true;\n }\n }\n return false;\n}\n/**\n * Helper function to check if a given RElement has the 'ngSkipHydration' attribute.\n */\nfunction hasSkipHydrationAttrOnRElement(rNode) {\n return rNode.hasAttribute(SKIP_HYDRATION_ATTR_NAME);\n}\n/**\n * Checks whether a TNode has a flag to indicate that it's a part of\n * a skip hydration block.\n */\nfunction hasInSkipHydrationBlockFlag(tNode) {\n return (tNode.flags & 128 /* TNodeFlags.inSkipHydrationBlock */) === 128 /* TNodeFlags.inSkipHydrationBlock */;\n}\n/**\n * Helper function that determines if a given node is within a skip hydration block\n * by navigating up the TNode tree to see if any parent nodes have skip hydration\n * attribute.\n */\nfunction isInSkipHydrationBlock(tNode) {\n if (hasInSkipHydrationBlockFlag(tNode)) {\n return true;\n }\n let currentTNode = tNode.parent;\n while (currentTNode) {\n if (hasInSkipHydrationBlockFlag(tNode) || hasSkipHydrationAttrOnTNode(currentTNode)) {\n return true;\n }\n currentTNode = currentTNode.parent;\n }\n return false;\n}\n/**\n * Check if an i18n block is in a skip hydration section by looking at a parent TNode\n * to determine if this TNode is in a skip hydration section or the TNode has\n * the `ngSkipHydration` attribute.\n */\nfunction isI18nInSkipHydrationBlock(parentTNode) {\n return hasInSkipHydrationBlockFlag(parentTNode) || hasSkipHydrationAttrOnTNode(parentTNode) || isInSkipHydrationBlock(parentTNode);\n}\n\n/**\n * The strategy that the default change detector uses to detect changes.\n * When set, takes effect the next time change detection is triggered.\n *\n * @see {@link /api/core/ChangeDetectorRef?tab=usage-notes Change detection usage}\n * @see {@link /best-practices/skipping-subtrees Skipping component subtrees}\n *\n * @publicApi\n */\nvar ChangeDetectionStrategy;\n(function (ChangeDetectionStrategy) {\n /**\n * Use the `CheckOnce` strategy, meaning that automatic change detection is deactivated\n * until reactivated by setting the strategy to `Default` (`CheckAlways`).\n * Change detection can still be explicitly invoked.\n * This strategy applies to all child directives and cannot be overridden.\n */\n ChangeDetectionStrategy[ChangeDetectionStrategy[\"OnPush\"] = 0] = \"OnPush\";\n /**\n * Use the default `CheckAlways` strategy, in which change detection is automatic until\n * explicitly deactivated.\n */\n ChangeDetectionStrategy[ChangeDetectionStrategy[\"Default\"] = 1] = \"Default\";\n})(ChangeDetectionStrategy || (ChangeDetectionStrategy = {}));\n\n// Keeps track of the currently-active LViews.\nconst TRACKED_LVIEWS = new Map();\n// Used for generating unique IDs for LViews.\nlet uniqueIdCounter = 0;\n/** Gets a unique ID that can be assigned to an LView. */\nfunction getUniqueLViewId() {\n return uniqueIdCounter++;\n}\n/** Starts tracking an LView. */\nfunction registerLView(lView) {\n ngDevMode && assertNumber(lView[ID], 'LView must have an ID in order to be registered');\n TRACKED_LVIEWS.set(lView[ID], lView);\n}\n/** Gets an LView by its unique ID. */\nfunction getLViewById(id) {\n ngDevMode && assertNumber(id, 'ID used for LView lookup must be a number');\n return TRACKED_LVIEWS.get(id) || null;\n}\n/** Stops tracking an LView. */\nfunction unregisterLView(lView) {\n ngDevMode && assertNumber(lView[ID], 'Cannot stop tracking an LView that does not have an ID');\n TRACKED_LVIEWS.delete(lView[ID]);\n}\n/** Gets the currently-tracked views. */\nfunction getTrackedLViews() {\n return TRACKED_LVIEWS;\n}\n\n/**\n * The internal view context which is specific to a given DOM element, directive or\n * component instance. Each value in here (besides the LView and element node details)\n * can be present, null or undefined. If undefined then it implies the value has not been\n * looked up yet, otherwise, if null, then a lookup was executed and nothing was found.\n *\n * Each value will get filled when the respective value is examined within the getContext\n * function. The component, element and each directive instance will share the same instance\n * of the context.\n */\nclass LContext {\n lViewId;\n nodeIndex;\n native;\n /**\n * The instance of the Component node.\n */\n component;\n /**\n * The list of active directives that exist on this element.\n */\n directives;\n /**\n * The map of local references (local reference name => element or directive instance) that\n * exist on this element.\n */\n localRefs;\n /** Component's parent view data. */\n get lView() {\n return getLViewById(this.lViewId);\n }\n constructor(\n /**\n * ID of the component's parent view data.\n */\n lViewId,\n /**\n * The index instance of the node.\n */\n nodeIndex,\n /**\n * The instance of the DOM node that is attached to the lNode.\n */\n native) {\n this.lViewId = lViewId;\n this.nodeIndex = nodeIndex;\n this.native = native;\n }\n}\n\n/**\n * Returns the matching `LContext` data for a given DOM node, directive or component instance.\n *\n * This function will examine the provided DOM element, component, or directive instance\\'s\n * monkey-patched property to derive the `LContext` data. Once called then the monkey-patched\n * value will be that of the newly created `LContext`.\n *\n * If the monkey-patched value is the `LView` instance then the context value for that\n * target will be created and the monkey-patch reference will be updated. Therefore when this\n * function is called it may mutate the provided element\\'s, component\\'s or any of the associated\n * directive\\'s monkey-patch values.\n *\n * If the monkey-patch value is not detected then the code will walk up the DOM until an element\n * is found which contains a monkey-patch reference. When that occurs then the provided element\n * will be updated with a new context (which is then returned). If the monkey-patch value is not\n * detected for a component/directive instance then it will throw an error (all components and\n * directives should be automatically monkey-patched by ivy).\n *\n * @param target Component, Directive or DOM Node.\n */\nfunction getLContext(target) {\n let mpValue = readPatchedData(target);\n if (mpValue) {\n // only when it's an array is it considered an LView instance\n // ... otherwise it's an already constructed LContext instance\n if (isLView(mpValue)) {\n const lView = mpValue;\n let nodeIndex;\n let component = undefined;\n let directives = undefined;\n if (isComponentInstance(target)) {\n nodeIndex = findViaComponent(lView, target);\n if (nodeIndex == -1) {\n throw new Error('The provided component was not found in the application');\n }\n component = target;\n } else if (isDirectiveInstance(target)) {\n nodeIndex = findViaDirective(lView, target);\n if (nodeIndex == -1) {\n throw new Error('The provided directive was not found in the application');\n }\n directives = getDirectivesAtNodeIndex(nodeIndex, lView);\n } else {\n nodeIndex = findViaNativeElement(lView, target);\n if (nodeIndex == -1) {\n return null;\n }\n }\n // the goal is not to fill the entire context full of data because the lookups\n // are expensive. Instead, only the target data (the element, component, container, ICU\n // expression or directive details) are filled into the context. If called multiple times\n // with different target values then the missing target data will be filled in.\n const native = unwrapRNode(lView[nodeIndex]);\n const existingCtx = readPatchedData(native);\n const context = existingCtx && !Array.isArray(existingCtx) ? existingCtx : createLContext(lView, nodeIndex, native);\n // only when the component has been discovered then update the monkey-patch\n if (component && context.component === undefined) {\n context.component = component;\n attachPatchData(context.component, context);\n }\n // only when the directives have been discovered then update the monkey-patch\n if (directives && context.directives === undefined) {\n context.directives = directives;\n for (let i = 0; i < directives.length; i++) {\n attachPatchData(directives[i], context);\n }\n }\n attachPatchData(context.native, context);\n mpValue = context;\n }\n } else {\n const rElement = target;\n ngDevMode && assertDomNode(rElement);\n // if the context is not found then we need to traverse upwards up the DOM\n // to find the nearest element that has already been monkey patched with data\n let parent = rElement;\n while (parent = parent.parentNode) {\n const parentContext = readPatchedData(parent);\n if (parentContext) {\n const lView = Array.isArray(parentContext) ? parentContext : parentContext.lView;\n // the edge of the app was also reached here through another means\n // (maybe because the DOM was changed manually).\n if (!lView) {\n return null;\n }\n const index = findViaNativeElement(lView, rElement);\n if (index >= 0) {\n const native = unwrapRNode(lView[index]);\n const context = createLContext(lView, index, native);\n attachPatchData(native, context);\n mpValue = context;\n break;\n }\n }\n }\n }\n return mpValue || null;\n}\n/**\n * Creates an empty instance of a `LContext` context\n */\nfunction createLContext(lView, nodeIndex, native) {\n return new LContext(lView[ID], nodeIndex, native);\n}\n/**\n * Takes a component instance and returns the view for that component.\n *\n * @param componentInstance\n * @returns The component's view\n */\nfunction getComponentViewByInstance(componentInstance) {\n let patchedData = readPatchedData(componentInstance);\n let lView;\n if (isLView(patchedData)) {\n const contextLView = patchedData;\n const nodeIndex = findViaComponent(contextLView, componentInstance);\n lView = getComponentLViewByIndex(nodeIndex, contextLView);\n const context = createLContext(contextLView, nodeIndex, lView[HOST]);\n context.component = componentInstance;\n attachPatchData(componentInstance, context);\n attachPatchData(context.native, context);\n } else {\n const context = patchedData;\n const contextLView = context.lView;\n ngDevMode && assertLView(contextLView);\n lView = getComponentLViewByIndex(context.nodeIndex, contextLView);\n }\n return lView;\n}\n/**\n * This property will be monkey-patched on elements, components and directives.\n */\nconst MONKEY_PATCH_KEY_NAME = '__ngContext__';\nfunction attachLViewId(target, data) {\n target[MONKEY_PATCH_KEY_NAME] = data[ID];\n}\n/**\n * Returns the monkey-patch value data present on the target (which could be\n * a component, directive or a DOM node).\n */\nfunction readLView(target) {\n const data = readPatchedData(target);\n if (isLView(data)) {\n return data;\n }\n return data ? data.lView : null;\n}\n/**\n * Assigns the given data to the given target (which could be a component,\n * directive or DOM node instance) using monkey-patching.\n */\nfunction attachPatchData(target, data) {\n ngDevMode && assertDefined(target, 'Target expected');\n // Only attach the ID of the view in order to avoid memory leaks (see #41047). We only do this\n // for `LView`, because we have control over when an `LView` is created and destroyed, whereas\n // we can't know when to remove an `LContext`.\n if (isLView(data)) {\n target[MONKEY_PATCH_KEY_NAME] = data[ID];\n registerLView(data);\n } else {\n target[MONKEY_PATCH_KEY_NAME] = data;\n }\n}\n/**\n * Returns the monkey-patch value data present on the target (which could be\n * a component, directive or a DOM node).\n */\nfunction readPatchedData(target) {\n ngDevMode && assertDefined(target, 'Target expected');\n const data = target[MONKEY_PATCH_KEY_NAME];\n return typeof data === 'number' ? getLViewById(data) : data || null;\n}\nfunction readPatchedLView(target) {\n const value = readPatchedData(target);\n if (value) {\n return isLView(value) ? value : value.lView;\n }\n return null;\n}\nfunction isComponentInstance(instance) {\n return instance && instance.constructor && instance.constructor.ɵcmp;\n}\nfunction isDirectiveInstance(instance) {\n return instance && instance.constructor && instance.constructor.ɵdir;\n}\n/**\n * Locates the element within the given LView and returns the matching index\n */\nfunction findViaNativeElement(lView, target) {\n const tView = lView[TVIEW];\n for (let i = HEADER_OFFSET; i < tView.bindingStartIndex; i++) {\n if (unwrapRNode(lView[i]) === target) {\n return i;\n }\n }\n return -1;\n}\n/**\n * Locates the next tNode (child, sibling or parent).\n */\nfunction traverseNextElement(tNode) {\n if (tNode.child) {\n return tNode.child;\n } else if (tNode.next) {\n return tNode.next;\n } else {\n // Let's take the following template: <div><span>text</span></div><component/>\n // After checking the text node, we need to find the next parent that has a \"next\" TNode,\n // in this case the parent `div`, so that we can find the component.\n while (tNode.parent && !tNode.parent.next) {\n tNode = tNode.parent;\n }\n return tNode.parent && tNode.parent.next;\n }\n}\n/**\n * Locates the component within the given LView and returns the matching index\n */\nfunction findViaComponent(lView, componentInstance) {\n const componentIndices = lView[TVIEW].components;\n if (componentIndices) {\n for (let i = 0; i < componentIndices.length; i++) {\n const elementComponentIndex = componentIndices[i];\n const componentView = getComponentLViewByIndex(elementComponentIndex, lView);\n if (componentView[CONTEXT] === componentInstance) {\n return elementComponentIndex;\n }\n }\n } else {\n const rootComponentView = getComponentLViewByIndex(HEADER_OFFSET, lView);\n const rootComponent = rootComponentView[CONTEXT];\n if (rootComponent === componentInstance) {\n // we are dealing with the root element here therefore we know that the\n // element is the very first element after the HEADER data in the lView\n return HEADER_OFFSET;\n }\n }\n return -1;\n}\n/**\n * Locates the directive within the given LView and returns the matching index\n */\nfunction findViaDirective(lView, directiveInstance) {\n // if a directive is monkey patched then it will (by default)\n // have a reference to the LView of the current view. The\n // element bound to the directive being search lives somewhere\n // in the view data. We loop through the nodes and check their\n // list of directives for the instance.\n let tNode = lView[TVIEW].firstChild;\n while (tNode) {\n const directiveIndexStart = tNode.directiveStart;\n const directiveIndexEnd = tNode.directiveEnd;\n for (let i = directiveIndexStart; i < directiveIndexEnd; i++) {\n if (lView[i] === directiveInstance) {\n return tNode.index;\n }\n }\n tNode = traverseNextElement(tNode);\n }\n return -1;\n}\n/**\n * Returns a list of directives applied to a node at a specific index. The list includes\n * directives matched by selector and any host directives, but it excludes components.\n * Use `getComponentAtNodeIndex` to find the component applied to a node.\n *\n * @param nodeIndex The node index\n * @param lView The target view data\n */\nfunction getDirectivesAtNodeIndex(nodeIndex, lView) {\n const tNode = lView[TVIEW].data[nodeIndex];\n if (tNode.directiveStart === 0) return EMPTY_ARRAY;\n const results = [];\n for (let i = tNode.directiveStart; i < tNode.directiveEnd; i++) {\n const directiveInstance = lView[i];\n if (!isComponentInstance(directiveInstance)) {\n results.push(directiveInstance);\n }\n }\n return results;\n}\nfunction getComponentAtNodeIndex(nodeIndex, lView) {\n const tNode = lView[TVIEW].data[nodeIndex];\n return isComponentHost(tNode) ? lView[tNode.directiveStart + tNode.componentOffset] : null;\n}\n/**\n * Returns a map of local references (local reference name => element or directive instance) that\n * exist on a given element.\n */\nfunction discoverLocalRefs(lView, nodeIndex) {\n const tNode = lView[TVIEW].data[nodeIndex];\n if (tNode && tNode.localNames) {\n const result = {};\n let localIndex = tNode.index + 1;\n for (let i = 0; i < tNode.localNames.length; i += 2) {\n result[tNode.localNames[i]] = lView[localIndex];\n localIndex++;\n }\n return result;\n }\n return null;\n}\n\n/**\n * Retrieve the root view from any component or `LView` by walking the parent `LView` until\n * reaching the root `LView`.\n *\n * @param componentOrLView any component or `LView`\n */\nfunction getRootView(componentOrLView) {\n ngDevMode && assertDefined(componentOrLView, 'component');\n let lView = isLView(componentOrLView) ? componentOrLView : readPatchedLView(componentOrLView);\n while (lView && !isRootView(lView)) {\n lView = getLViewParent(lView);\n }\n ngDevMode && assertLView(lView);\n return lView;\n}\n/**\n * Returns the context information associated with the application where the target is situated. It\n * does this by walking the parent views until it gets to the root view, then getting the context\n * off of that.\n *\n * @param viewOrComponent the `LView` or component to get the root context for.\n */\nfunction getRootContext(viewOrComponent) {\n const rootView = getRootView(viewOrComponent);\n ngDevMode && assertDefined(rootView[CONTEXT], 'Root view has no context. Perhaps it is disconnected?');\n return rootView[CONTEXT];\n}\n/**\n * Gets the first `LContainer` in the LView or `null` if none exists.\n */\nfunction getFirstLContainer(lView) {\n return getNearestLContainer(lView[CHILD_HEAD]);\n}\n/**\n * Gets the next `LContainer` that is a sibling of the given container.\n */\nfunction getNextLContainer(container) {\n return getNearestLContainer(container[NEXT]);\n}\nfunction getNearestLContainer(viewOrContainer) {\n while (viewOrContainer !== null && !isLContainer(viewOrContainer)) {\n viewOrContainer = viewOrContainer[NEXT];\n }\n return viewOrContainer;\n}\n\n/**\n * Retrieves the component instance associated with a given DOM element.\n *\n * @usageNotes\n * Given the following DOM structure:\n *\n * ```html\n * <app-root>\n * <div>\n * <child-comp></child-comp>\n * </div>\n * </app-root>\n * ```\n *\n * Calling `getComponent` on `<child-comp>` will return the instance of `ChildComponent`\n * associated with this DOM element.\n *\n * Calling the function on `<app-root>` will return the `MyApp` instance.\n *\n *\n * @param element DOM element from which the component should be retrieved.\n * @returns Component instance associated with the element or `null` if there\n * is no component associated with it.\n *\n * @publicApi\n */\nfunction getComponent(element) {\n ngDevMode && assertDomElement(element);\n const context = getLContext(element);\n if (context === null) return null;\n if (context.component === undefined) {\n const lView = context.lView;\n if (lView === null) {\n return null;\n }\n context.component = getComponentAtNodeIndex(context.nodeIndex, lView);\n }\n return context.component;\n}\n/**\n * If inside an embedded view (e.g. `*ngIf` or `*ngFor`), retrieves the context of the embedded\n * view that the element is part of. Otherwise retrieves the instance of the component whose view\n * owns the element (in this case, the result is the same as calling `getOwningComponent`).\n *\n * @param element Element for which to get the surrounding component instance.\n * @returns Instance of the component that is around the element or null if the element isn't\n * inside any component.\n *\n * @publicApi\n */\nfunction getContext(element) {\n assertDomElement(element);\n const context = getLContext(element);\n const lView = context ? context.lView : null;\n return lView === null ? null : lView[CONTEXT];\n}\n/**\n * Retrieves the component instance whose view contains the DOM element.\n *\n * For example, if `<child-comp>` is used in the template of `<app-comp>`\n * (i.e. a `ViewChild` of `<app-comp>`), calling `getOwningComponent` on `<child-comp>`\n * would return `<app-comp>`.\n *\n * @param elementOrDir DOM element, component or directive instance\n * for which to retrieve the root components.\n * @returns Component instance whose view owns the DOM element or null if the element is not\n * part of a component view.\n *\n * @publicApi\n */\nfunction getOwningComponent(elementOrDir) {\n const context = getLContext(elementOrDir);\n let lView = context ? context.lView : null;\n if (lView === null) return null;\n let parent;\n while (lView[TVIEW].type === 2 /* TViewType.Embedded */ && (parent = getLViewParent(lView))) {\n lView = parent;\n }\n return isRootView(lView) ? null : lView[CONTEXT];\n}\n/**\n * Retrieves all root components associated with a DOM element, directive or component instance.\n * Root components are those which have been bootstrapped by Angular.\n *\n * @param elementOrDir DOM element, component or directive instance\n * for which to retrieve the root components.\n * @returns Root components associated with the target object.\n *\n * @publicApi\n */\nfunction getRootComponents(elementOrDir) {\n const lView = readPatchedLView(elementOrDir);\n return lView !== null ? [getRootContext(lView)] : [];\n}\n/**\n * Retrieves an `Injector` associated with an element, component or directive instance.\n *\n * @param elementOrDir DOM element, component or directive instance for which to\n * retrieve the injector.\n * @returns Injector associated with the element, component or directive instance.\n *\n * @publicApi\n */\nfunction getInjector(elementOrDir) {\n const context = getLContext(elementOrDir);\n const lView = context ? context.lView : null;\n if (lView === null) return Injector.NULL;\n const tNode = lView[TVIEW].data[context.nodeIndex];\n return new NodeInjector(tNode, lView);\n}\n/**\n * Retrieve a set of injection tokens at a given DOM node.\n *\n * @param element Element for which the injection tokens should be retrieved.\n */\nfunction getInjectionTokens(element) {\n const context = getLContext(element);\n const lView = context ? context.lView : null;\n if (lView === null) return [];\n const tView = lView[TVIEW];\n const tNode = tView.data[context.nodeIndex];\n const providerTokens = [];\n const startIndex = tNode.providerIndexes & 1048575 /* TNodeProviderIndexes.ProvidersStartIndexMask */;\n const endIndex = tNode.directiveEnd;\n for (let i = startIndex; i < endIndex; i++) {\n let value = tView.data[i];\n if (isDirectiveDefHack(value)) {\n // The fact that we sometimes store Type and sometimes DirectiveDef in this location is a\n // design flaw. We should always store same type so that we can be monomorphic. The issue\n // is that for Components/Directives we store the def instead the type. The correct behavior\n // is that we should always be storing injectable type in this location.\n value = value.type;\n }\n providerTokens.push(value);\n }\n return providerTokens;\n}\n/**\n * Retrieves directive instances associated with a given DOM node. Does not include\n * component instances.\n *\n * @usageNotes\n * Given the following DOM structure:\n *\n * ```html\n * <app-root>\n * <button my-button></button>\n * <my-comp></my-comp>\n * </app-root>\n * ```\n *\n * Calling `getDirectives` on `<button>` will return an array with an instance of the `MyButton`\n * directive that is associated with the DOM node.\n *\n * Calling `getDirectives` on `<my-comp>` will return an empty array.\n *\n * @param node DOM node for which to get the directives.\n * @returns Array of directives associated with the node.\n *\n * @publicApi\n */\nfunction getDirectives(node) {\n // Skip text nodes because we can't have directives associated with them.\n if (node instanceof Text) {\n return [];\n }\n const context = getLContext(node);\n const lView = context ? context.lView : null;\n if (lView === null) {\n return [];\n }\n const tView = lView[TVIEW];\n const nodeIndex = context.nodeIndex;\n if (!tView?.data[nodeIndex]) {\n return [];\n }\n if (context.directives === undefined) {\n context.directives = getDirectivesAtNodeIndex(nodeIndex, lView);\n }\n // The `directives` in this case are a named array called `LComponentView`. Clone the\n // result so we don't expose an internal data structure in the user's console.\n return context.directives === null ? [] : [...context.directives];\n}\n/**\n * Returns the debug (partial) metadata for a particular directive or component instance.\n * The function accepts an instance of a directive or component and returns the corresponding\n * metadata.\n *\n * @param directiveOrComponentInstance Instance of a directive or component\n * @returns metadata of the passed directive or component\n *\n * @publicApi\n */\nfunction getDirectiveMetadata$1(directiveOrComponentInstance) {\n const {\n constructor\n } = directiveOrComponentInstance;\n if (!constructor) {\n throw new Error('Unable to find the instance constructor');\n }\n // In case a component inherits from a directive, we may have component and directive metadata\n // To ensure we don't get the metadata of the directive, we want to call `getComponentDef` first.\n const componentDef = getComponentDef(constructor);\n if (componentDef) {\n const inputs = extractInputDebugMetadata(componentDef.inputs);\n return {\n inputs,\n outputs: componentDef.outputs,\n encapsulation: componentDef.encapsulation,\n changeDetection: componentDef.onPush ? ChangeDetectionStrategy.OnPush : ChangeDetectionStrategy.Default\n };\n }\n const directiveDef = getDirectiveDef(constructor);\n if (directiveDef) {\n const inputs = extractInputDebugMetadata(directiveDef.inputs);\n return {\n inputs,\n outputs: directiveDef.outputs\n };\n }\n return null;\n}\n/**\n * Retrieve map of local references.\n *\n * The references are retrieved as a map of local reference name to element or directive instance.\n *\n * @param target DOM element, component or directive instance for which to retrieve\n * the local references.\n */\nfunction getLocalRefs(target) {\n const context = getLContext(target);\n if (context === null) return {};\n if (context.localRefs === undefined) {\n const lView = context.lView;\n if (lView === null) {\n return {};\n }\n context.localRefs = discoverLocalRefs(lView, context.nodeIndex);\n }\n return context.localRefs || {};\n}\n/**\n * Retrieves the host element of a component or directive instance.\n * The host element is the DOM element that matched the selector of the directive.\n *\n * @param componentOrDirective Component or directive instance for which the host\n * element should be retrieved.\n * @returns Host element of the target.\n *\n * @publicApi\n */\nfunction getHostElement(componentOrDirective) {\n return getLContext(componentOrDirective).native;\n}\n/**\n * Retrieves the rendered text for a given component.\n *\n * This function retrieves the host element of a component and\n * and then returns the `textContent` for that element. This implies\n * that the text returned will include re-projected content of\n * the component as well.\n *\n * @param component The component to return the content text for.\n */\nfunction getRenderedText(component) {\n const hostElement = getHostElement(component);\n return hostElement.textContent || '';\n}\n/**\n * Retrieves a list of event listeners associated with a DOM element. The list does include host\n * listeners, but it does not include event listeners defined outside of the Angular context\n * (e.g. through `addEventListener`).\n *\n * @usageNotes\n * Given the following DOM structure:\n *\n * ```html\n * <app-root>\n * <div (click)=\"doSomething()\"></div>\n * </app-root>\n * ```\n *\n * Calling `getListeners` on `<div>` will return an object that looks as follows:\n *\n * ```ts\n * {\n * name: 'click',\n * element: <div>,\n * callback: () => doSomething(),\n * useCapture: false\n * }\n * ```\n *\n * @param element Element for which the DOM listeners should be retrieved.\n * @returns Array of event listeners on the DOM element.\n *\n * @publicApi\n */\nfunction getListeners(element) {\n ngDevMode && assertDomElement(element);\n const lContext = getLContext(element);\n const lView = lContext === null ? null : lContext.lView;\n if (lView === null) return [];\n const tView = lView[TVIEW];\n const lCleanup = lView[CLEANUP];\n const tCleanup = tView.cleanup;\n const listeners = [];\n if (tCleanup && lCleanup) {\n for (let i = 0; i < tCleanup.length;) {\n const firstParam = tCleanup[i++];\n const secondParam = tCleanup[i++];\n if (typeof firstParam === 'string') {\n const name = firstParam;\n const listenerElement = unwrapRNode(lView[secondParam]);\n const callback = lCleanup[tCleanup[i++]];\n const useCaptureOrIndx = tCleanup[i++];\n // if useCaptureOrIndx is boolean then report it as is.\n // if useCaptureOrIndx is positive number then it in unsubscribe method\n // if useCaptureOrIndx is negative number then it is a Subscription\n const type = typeof useCaptureOrIndx === 'boolean' || useCaptureOrIndx >= 0 ? 'dom' : 'output';\n const useCapture = typeof useCaptureOrIndx === 'boolean' ? useCaptureOrIndx : false;\n if (element == listenerElement) {\n listeners.push({\n element,\n name,\n callback,\n useCapture,\n type\n });\n }\n }\n }\n }\n listeners.sort(sortListeners);\n return listeners;\n}\nfunction sortListeners(a, b) {\n if (a.name == b.name) return 0;\n return a.name < b.name ? -1 : 1;\n}\n/**\n * This function should not exist because it is megamorphic and only mostly correct.\n *\n * See call site for more info.\n */\nfunction isDirectiveDefHack(obj) {\n return obj.type !== undefined && obj.declaredInputs !== undefined && obj.findHostDirectiveDefs !== undefined;\n}\n/**\n * Retrieve the component `LView` from component/element.\n *\n * NOTE: `LView` is a private and should not be leaked outside.\n * Don't export this method to `ng.*` on window.\n *\n * @param target DOM element or component instance for which to retrieve the LView.\n */\nfunction getComponentLView(target) {\n const lContext = getLContext(target);\n const nodeIndx = lContext.nodeIndex;\n const lView = lContext.lView;\n ngDevMode && assertLView(lView);\n const componentLView = lView[nodeIndx];\n ngDevMode && assertLView(componentLView);\n return componentLView;\n}\n/** Asserts that a value is a DOM Element. */\nfunction assertDomElement(value) {\n if (typeof Element !== 'undefined' && !(value instanceof Element)) {\n throw new Error('Expecting instance of DOM Element');\n }\n}\n/**\n * A directive definition holds additional metadata using bitwise flags to indicate\n * for example whether it is signal based.\n *\n * This information needs to be separate from the `publicName -> minifiedName`\n * mappings for backwards compatibility.\n */\nfunction extractInputDebugMetadata(inputs) {\n const res = {};\n for (const key in inputs) {\n if (inputs.hasOwnProperty(key)) {\n const value = inputs[key];\n if (value !== undefined) {\n res[key] = value[0];\n }\n }\n }\n return res;\n}\n\n/**\n * Most of the use of `document` in Angular is from within the DI system so it is possible to simply\n * inject the `DOCUMENT` token and are done.\n *\n * Ivy is special because it does not rely upon the DI and must get hold of the document some other\n * way.\n *\n * The solution is to define `getDocument()` and `setDocument()` top-level functions for ivy.\n * Wherever ivy needs the global document, it calls `getDocument()` instead.\n *\n * When running ivy outside of a browser environment, it is necessary to call `setDocument()` to\n * tell ivy what the global `document` is.\n *\n * Angular does this for us in each of the standard platforms (`Browser` and `Server`)\n * by calling `setDocument()` when providing the `DOCUMENT` token.\n */\nlet DOCUMENT = undefined;\n/**\n * Tell ivy what the `document` is for this platform.\n *\n * It is only necessary to call this if the current platform is not a browser.\n *\n * @param document The object representing the global `document` in this environment.\n */\nfunction setDocument(document) {\n DOCUMENT = document;\n}\n/**\n * Access the object that represents the `document` for this platform.\n *\n * Ivy calls this whenever it needs to access the `document` object.\n * For example to create the renderer or to do sanitization.\n */\nfunction getDocument() {\n if (DOCUMENT !== undefined) {\n return DOCUMENT;\n } else if (typeof document !== 'undefined') {\n return document;\n }\n throw new RuntimeError(210 /* RuntimeErrorCode.MISSING_DOCUMENT */, (typeof ngDevMode === 'undefined' || ngDevMode) && `The document object is not available in this context. Make sure the DOCUMENT injection token is provided.`);\n // No \"document\" can be found. This should only happen if we are running ivy outside Angular and\n // the current platform is not a browser. Since this is not a supported scenario at the moment\n // this should not happen in Angular apps.\n // Once we support running ivy outside of Angular we will need to publish `setDocument()` as a\n // public API.\n}\n\n/**\n * A DI token representing a string ID, used\n * primarily for prefixing application attributes and CSS styles when\n * {@link ViewEncapsulation#Emulated} is being used.\n *\n * The token is needed in cases when multiple applications are bootstrapped on a page\n * (for example, using `bootstrapApplication` calls). In this case, ensure that those applications\n * have different `APP_ID` value setup. For example:\n *\n * ```ts\n * bootstrapApplication(ComponentA, {\n * providers: [\n * { provide: APP_ID, useValue: 'app-a' },\n * // ... other providers ...\n * ]\n * });\n *\n * bootstrapApplication(ComponentB, {\n * providers: [\n * { provide: APP_ID, useValue: 'app-b' },\n * // ... other providers ...\n * ]\n * });\n * ```\n *\n * By default, when there is only one application bootstrapped, you don't need to provide the\n * `APP_ID` token (the `ng` will be used as an app ID).\n *\n * @publicApi\n */\nconst APP_ID = new InjectionToken(ngDevMode ? 'AppId' : '', {\n providedIn: 'root',\n factory: () => DEFAULT_APP_ID\n});\n/** Default value of the `APP_ID` token. */\nconst DEFAULT_APP_ID = 'ng';\n/**\n * A function that is executed when a platform is initialized.\n *\n * @deprecated from v19.0.0, use providePlatformInitializer instead\n *\n * @see {@link providePlatformInitializer}\n *\n * @publicApi\n */\nconst PLATFORM_INITIALIZER = new InjectionToken(ngDevMode ? 'Platform Initializer' : '');\n/**\n * A token that indicates an opaque platform ID.\n * @publicApi\n */\nconst PLATFORM_ID = new InjectionToken(ngDevMode ? 'Platform ID' : '', {\n providedIn: 'platform',\n factory: () => 'unknown' // set a default platform name, when none set explicitly\n});\n/**\n * A DI token that indicates the root directory of\n * the application\n * @publicApi\n * @deprecated\n */\nconst PACKAGE_ROOT_URL = new InjectionToken(ngDevMode ? 'Application Packages Root URL' : '');\n// We keep this token here, rather than the animations package, so that modules that only care\n// about which animations module is loaded (e.g. the CDK) can retrieve it without having to\n// include extra dependencies. See #44970 for more context.\n/**\n * A [DI token](api/core/InjectionToken) that indicates which animations\n * module has been loaded.\n * @publicApi\n */\nconst ANIMATION_MODULE_TYPE = new InjectionToken(ngDevMode ? 'AnimationModuleType' : '');\n// TODO(crisbeto): link to CSP guide here.\n/**\n * Token used to configure the [Content Security Policy](https://web.dev/strict-csp/) nonce that\n * Angular will apply when inserting inline styles. If not provided, Angular will look up its value\n * from the `ngCspNonce` attribute of the application root node.\n *\n * @publicApi\n */\nconst CSP_NONCE = new InjectionToken(ngDevMode ? 'CSP nonce' : '', {\n providedIn: 'root',\n factory: () => {\n // Ideally we wouldn't have to use `querySelector` here since we know that the nonce will be on\n // the root node, but because the token value is used in renderers, it has to be available\n // *very* early in the bootstrapping process. This should be a fairly shallow search, because\n // the app won't have been added to the DOM yet. Some approaches that were considered:\n // 1. Find the root node through `ApplicationRef.components[i].location` - normally this would\n // be enough for our purposes, but the token is injected very early so the `components` array\n // isn't populated yet.\n // 2. Find the root `LView` through the current `LView` - renderers are a prerequisite to\n // creating the `LView`. This means that no `LView` will have been entered when this factory is\n // invoked for the root component.\n // 3. Have the token factory return `() => string` which is invoked when a nonce is requested -\n // the slightly later execution does allow us to get an `LView` reference, but the fact that\n // it is a function means that it could be executed at *any* time (including immediately) which\n // may lead to weird bugs.\n // 4. Have the `ComponentFactory` read the attribute and provide it to the injector under the\n // hood - has the same problem as #1 and #2 in that the renderer is used to query for the root\n // node and the nonce value needs to be available when the renderer is created.\n return getDocument().body?.querySelector('[ngCspNonce]')?.getAttribute('ngCspNonce') || null;\n }\n});\nconst IMAGE_CONFIG_DEFAULTS = {\n breakpoints: [16, 32, 48, 64, 96, 128, 256, 384, 640, 750, 828, 1080, 1200, 1920, 2048, 3840],\n placeholderResolution: 30,\n disableImageSizeWarning: false,\n disableImageLazyLoadWarning: false\n};\n/**\n * Injection token that configures the image optimized image functionality.\n * See {@link ImageConfig} for additional information about parameters that\n * can be used.\n *\n * @see {@link NgOptimizedImage}\n * @see {@link ImageConfig}\n * @publicApi\n */\nconst IMAGE_CONFIG = new InjectionToken(ngDevMode ? 'ImageConfig' : '', {\n providedIn: 'root',\n factory: () => IMAGE_CONFIG_DEFAULTS\n});\n\n/**\n * Create a `StateKey<T>` that can be used to store value of type T with `TransferState`.\n *\n * Example:\n *\n * ```ts\n * const COUNTER_KEY = makeStateKey<number>('counter');\n * let value = 10;\n *\n * transferState.set(COUNTER_KEY, value);\n * ```\n *\n * @publicApi\n */\nfunction makeStateKey(key) {\n return key;\n}\nfunction initTransferState() {\n const transferState = new TransferState();\n if (inject(PLATFORM_ID) === 'browser') {\n transferState.store = retrieveTransferredState(getDocument(), inject(APP_ID));\n }\n return transferState;\n}\n/**\n * A key value store that is transferred from the application on the server side to the application\n * on the client side.\n *\n * The `TransferState` is available as an injectable token.\n * On the client, just inject this token using DI and use it, it will be lazily initialized.\n * On the server it's already included if `renderApplication` function is used. Otherwise, import\n * the `ServerTransferStateModule` module to make the `TransferState` available.\n *\n * The values in the store are serialized/deserialized using JSON.stringify/JSON.parse. So only\n * boolean, number, string, null and non-class objects will be serialized and deserialized in a\n * non-lossy manner.\n *\n * @publicApi\n */\nclass TransferState {\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: TransferState,\n providedIn: 'root',\n factory: initTransferState\n });\n /** @internal */\n store = {};\n onSerializeCallbacks = {};\n /**\n * Get the value corresponding to a key. Return `defaultValue` if key is not found.\n */\n get(key, defaultValue) {\n return this.store[key] !== undefined ? this.store[key] : defaultValue;\n }\n /**\n * Set the value corresponding to a key.\n */\n set(key, value) {\n this.store[key] = value;\n }\n /**\n * Remove a key from the store.\n */\n remove(key) {\n delete this.store[key];\n }\n /**\n * Test whether a key exists in the store.\n */\n hasKey(key) {\n return this.store.hasOwnProperty(key);\n }\n /**\n * Indicates whether the state is empty.\n */\n get isEmpty() {\n return Object.keys(this.store).length === 0;\n }\n /**\n * Register a callback to provide the value for a key when `toJson` is called.\n */\n onSerialize(key, callback) {\n this.onSerializeCallbacks[key] = callback;\n }\n /**\n * Serialize the current state of the store to JSON.\n */\n toJson() {\n // Call the onSerialize callbacks and put those values into the store.\n for (const key in this.onSerializeCallbacks) {\n if (this.onSerializeCallbacks.hasOwnProperty(key)) {\n try {\n this.store[key] = this.onSerializeCallbacks[key]();\n } catch (e) {\n console.warn('Exception in onSerialize callback: ', e);\n }\n }\n }\n // Escape script tag to avoid break out of <script> tag in serialized output.\n // Encoding of `<` is the same behaviour as G3 script_builders.\n return JSON.stringify(this.store).replace(/</g, '\\\\u003C');\n }\n}\nfunction retrieveTransferredState(doc, appId) {\n // Locate the script tag with the JSON data transferred from the server.\n // The id of the script tag is set to the Angular appId + 'state'.\n const script = doc.getElementById(appId + '-state');\n if (script?.textContent) {\n try {\n // Avoid using any here as it triggers lint errors in google3 (any is not allowed).\n // Decoding of `<` is done of the box by browsers and node.js, same behaviour as G3\n // script_builders.\n return JSON.parse(script.textContent);\n } catch (e) {\n console.warn('Exception while restoring TransferState for app ' + appId, e);\n }\n }\n return {};\n}\n\n/** Encodes that the node lookup should start from the host node of this component. */\nconst REFERENCE_NODE_HOST = 'h';\n/** Encodes that the node lookup should start from the document body node. */\nconst REFERENCE_NODE_BODY = 'b';\nconst NODE_NAVIGATION_STEP_FIRST_CHILD = 'f';\nconst NODE_NAVIGATION_STEP_NEXT_SIBLING = 'n';\n/**\n * Keys within serialized view data structure to represent various\n * parts. See the `SerializedView` interface below for additional information.\n */\nconst ELEMENT_CONTAINERS = 'e';\nconst TEMPLATES = 't';\nconst CONTAINERS = 'c';\nconst MULTIPLIER = 'x';\nconst NUM_ROOT_NODES = 'r';\nconst TEMPLATE_ID = 'i'; // as it's also an \"id\"\nconst NODES = 'n';\nconst DISCONNECTED_NODES = 'd';\nconst I18N_DATA = 'l';\nconst DEFER_BLOCK_ID = 'di';\nconst DEFER_BLOCK_STATE$1 = 's';\nconst DEFER_PARENT_BLOCK_ID = 'p';\nconst DEFER_HYDRATE_TRIGGERS = 't';\nconst DEFER_PREFETCH_TRIGGERS = 'pt';\n\n/**\n * Internal token that specifies whether DOM reuse logic\n * during hydration is enabled.\n */\nconst IS_HYDRATION_DOM_REUSE_ENABLED = new InjectionToken(typeof ngDevMode === 'undefined' || !!ngDevMode ? 'IS_HYDRATION_DOM_REUSE_ENABLED' : '');\n// By default (in client rendering mode), we remove all the contents\n// of the host element and render an application after that.\nconst PRESERVE_HOST_CONTENT_DEFAULT = false;\n/**\n * Internal token that indicates whether host element content should be\n * retained during the bootstrap.\n */\nconst PRESERVE_HOST_CONTENT = new InjectionToken(typeof ngDevMode === 'undefined' || !!ngDevMode ? 'PRESERVE_HOST_CONTENT' : '', {\n providedIn: 'root',\n factory: () => PRESERVE_HOST_CONTENT_DEFAULT\n});\n/**\n * Internal token that indicates whether hydration support for i18n\n * is enabled.\n */\nconst IS_I18N_HYDRATION_ENABLED = new InjectionToken(typeof ngDevMode === 'undefined' || !!ngDevMode ? 'IS_I18N_HYDRATION_ENABLED' : '');\n/**\n * Internal token that indicates whether event replay support for SSR\n * is enabled.\n */\nconst IS_EVENT_REPLAY_ENABLED = new InjectionToken(typeof ngDevMode === 'undefined' || !!ngDevMode ? 'IS_EVENT_REPLAY_ENABLED' : '');\nconst EVENT_REPLAY_ENABLED_DEFAULT = false;\n/**\n * Internal token that indicates whether incremental hydration support\n * is enabled.\n */\nconst IS_INCREMENTAL_HYDRATION_ENABLED = new InjectionToken(typeof ngDevMode === 'undefined' || !!ngDevMode ? 'IS_INCREMENTAL_HYDRATION_ENABLED' : '');\n/**\n * A map of DOM elements with `jsaction` attributes grouped by action names.\n */\nconst JSACTION_BLOCK_ELEMENT_MAP = new InjectionToken(ngDevMode ? 'JSACTION_BLOCK_ELEMENT_MAP' : '', {\n providedIn: 'root',\n factory: () => new Map()\n});\n\n/** Actions that are supported by the tracing framework. */\nvar TracingAction;\n(function (TracingAction) {\n TracingAction[TracingAction[\"CHANGE_DETECTION\"] = 0] = \"CHANGE_DETECTION\";\n TracingAction[TracingAction[\"AFTER_NEXT_RENDER\"] = 1] = \"AFTER_NEXT_RENDER\";\n})(TracingAction || (TracingAction = {}));\n/**\n * Injection token for a `TracingService`, optionally provided.\n */\nconst TracingService = new InjectionToken(ngDevMode ? 'TracingService' : '');\nconst markedFeatures = new Set();\n// tslint:disable:ban\n/**\n * A guarded `performance.mark` for feature marking.\n *\n * This method exists because while all supported browser and node.js version supported by Angular\n * support performance.mark API. This is not the case for other environments such as JSDOM and\n * Cloudflare workers.\n */\nfunction performanceMarkFeature(feature) {\n if (markedFeatures.has(feature)) {\n return;\n }\n markedFeatures.add(feature);\n performance?.mark?.('mark_feature_usage', {\n detail: {\n feature\n }\n });\n}\n\n/**\n * Asserts that the current stack frame is not within a reactive context. Useful\n * to disallow certain code from running inside a reactive context (see {@link /api/core/rxjs/toSignal toSignal})\n *\n * @param debugFn a reference to the function making the assertion (used for the error message).\n *\n * @publicApi\n */\nfunction assertNotInReactiveContext(debugFn, extraContext) {\n // Taking a `Function` instead of a string name here prevents the un-minified name of the function\n // from being retained in the bundle regardless of minification.\n if (getActiveConsumer$1() !== null) {\n throw new RuntimeError(-602 /* RuntimeErrorCode.ASSERTION_NOT_INSIDE_REACTIVE_CONTEXT */, ngDevMode && `${debugFn.name}() cannot be called from within a reactive context.${extraContext ? ` ${extraContext}` : ''}`);\n }\n}\nclass ViewContext {\n view;\n node;\n constructor(view, node) {\n this.view = view;\n this.node = node;\n }\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = injectViewContext;\n}\nfunction injectViewContext() {\n return new ViewContext(getLView(), getCurrentTNode());\n}\n\n/**\n * The phase to run an `afterRender` or `afterNextRender` callback in.\n *\n * Callbacks in the same phase run in the order they are registered. Phases run in the\n * following order after each render:\n *\n * 1. `AfterRenderPhase.EarlyRead`\n * 2. `AfterRenderPhase.Write`\n * 3. `AfterRenderPhase.MixedReadWrite`\n * 4. `AfterRenderPhase.Read`\n *\n * Angular is unable to verify or enforce that phases are used correctly, and instead\n * relies on each developer to follow the guidelines documented for each value and\n * carefully choose the appropriate one, refactoring their code if necessary. By doing\n * so, Angular is better able to minimize the performance degradation associated with\n * manual DOM access, ensuring the best experience for the end users of your application\n * or library.\n *\n * @deprecated Specify the phase for your callback to run in by passing a spec-object as the first\n * parameter to `afterRender` or `afterNextRender` instead of a function.\n */\nvar AfterRenderPhase;\n(function (AfterRenderPhase) {\n /**\n * Use `AfterRenderPhase.EarlyRead` for callbacks that only need to **read** from the\n * DOM before a subsequent `AfterRenderPhase.Write` callback, for example to perform\n * custom layout that the browser doesn't natively support. Prefer the\n * `AfterRenderPhase.EarlyRead` phase if reading can wait until after the write phase.\n * **Never** write to the DOM in this phase.\n *\n * <div class=\"docs-alert docs-alert-important\">\n *\n * Using this value can degrade performance.\n * Instead, prefer using built-in browser functionality when possible.\n *\n * </div>\n */\n AfterRenderPhase[AfterRenderPhase[\"EarlyRead\"] = 0] = \"EarlyRead\";\n /**\n * Use `AfterRenderPhase.Write` for callbacks that only **write** to the DOM. **Never**\n * read from the DOM in this phase.\n */\n AfterRenderPhase[AfterRenderPhase[\"Write\"] = 1] = \"Write\";\n /**\n * Use `AfterRenderPhase.MixedReadWrite` for callbacks that read from or write to the\n * DOM, that haven't been refactored to use a different phase. **Never** use this phase if\n * it is possible to divide the work among the other phases instead.\n *\n * <div class=\"docs-alert docs-alert-critical\">\n *\n * Using this value can **significantly** degrade performance.\n * Instead, prefer dividing work into the appropriate phase callbacks.\n *\n * </div>\n */\n AfterRenderPhase[AfterRenderPhase[\"MixedReadWrite\"] = 2] = \"MixedReadWrite\";\n /**\n * Use `AfterRenderPhase.Read` for callbacks that only **read** from the DOM. **Never**\n * write to the DOM in this phase.\n */\n AfterRenderPhase[AfterRenderPhase[\"Read\"] = 3] = \"Read\";\n})(AfterRenderPhase || (AfterRenderPhase = {}));\nclass AfterRenderManager {\n impl = null;\n execute() {\n this.impl?.execute();\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: AfterRenderManager,\n providedIn: 'root',\n factory: () => new AfterRenderManager()\n });\n}\nconst AFTER_RENDER_PHASES = /* @__PURE__ **/(() => [AfterRenderPhase.EarlyRead, AfterRenderPhase.Write, AfterRenderPhase.MixedReadWrite, AfterRenderPhase.Read])();\nclass AfterRenderImpl {\n ngZone = inject(NgZone);\n scheduler = inject(ChangeDetectionScheduler);\n errorHandler = inject(ErrorHandler, {\n optional: true\n });\n /** Current set of active sequences. */\n sequences = new Set();\n /** Tracks registrations made during the current set of executions. */\n deferredRegistrations = new Set();\n /** Whether the `AfterRenderManager` is currently executing hooks. */\n executing = false;\n constructor() {\n // Inject the tracing service to make sure it's initialized.\n inject(TracingService, {\n optional: true\n });\n }\n /**\n * Run the sequence of phases of hooks, once through. As a result of executing some hooks, more\n * might be scheduled.\n */\n execute() {\n const hasSequencesToExecute = this.sequences.size > 0;\n if (hasSequencesToExecute) {\n profiler(16 /* ProfilerEvent.AfterRenderHooksStart */);\n }\n this.executing = true;\n for (const phase of AFTER_RENDER_PHASES) {\n for (const sequence of this.sequences) {\n if (sequence.erroredOrDestroyed || !sequence.hooks[phase]) {\n continue;\n }\n try {\n sequence.pipelinedValue = this.ngZone.runOutsideAngular(() => this.maybeTrace(() => {\n const hookFn = sequence.hooks[phase];\n const value = hookFn(sequence.pipelinedValue);\n return value;\n }, sequence.snapshot));\n } catch (err) {\n sequence.erroredOrDestroyed = true;\n this.errorHandler?.handleError(err);\n }\n }\n }\n this.executing = false;\n // Cleanup step to reset sequence state and also collect one-shot sequences for removal.\n for (const sequence of this.sequences) {\n sequence.afterRun();\n if (sequence.once) {\n this.sequences.delete(sequence);\n // Destroy the sequence so its on destroy callbacks can be cleaned up\n // immediately, instead of waiting until the injector is destroyed.\n sequence.destroy();\n }\n }\n for (const sequence of this.deferredRegistrations) {\n this.sequences.add(sequence);\n }\n if (this.deferredRegistrations.size > 0) {\n this.scheduler.notify(7 /* NotificationSource.RenderHook */);\n }\n this.deferredRegistrations.clear();\n if (hasSequencesToExecute) {\n profiler(17 /* ProfilerEvent.AfterRenderHooksEnd */);\n }\n }\n register(sequence) {\n const {\n view\n } = sequence;\n if (view !== undefined) {\n // Delay adding it to the manager, add it to the view instead.\n (view[AFTER_RENDER_SEQUENCES_TO_ADD] ??= []).push(sequence);\n // Mark the view for traversal to ensure we eventually schedule the afterNextRender.\n markAncestorsForTraversal(view);\n view[FLAGS] |= 8192 /* LViewFlags.HasChildViewsToRefresh */;\n } else if (!this.executing) {\n this.addSequence(sequence);\n } else {\n this.deferredRegistrations.add(sequence);\n }\n }\n addSequence(sequence) {\n this.sequences.add(sequence);\n // Trigger an `ApplicationRef.tick()` if one is not already pending/running, because we have a\n // new render hook that needs to run.\n this.scheduler.notify(7 /* NotificationSource.RenderHook */);\n }\n unregister(sequence) {\n if (this.executing && this.sequences.has(sequence)) {\n // We can't remove an `AfterRenderSequence` in the middle of iteration.\n // Instead, mark it as destroyed so it doesn't run any more, and mark it as one-shot so it'll\n // be removed at the end of the current execution.\n sequence.erroredOrDestroyed = true;\n sequence.pipelinedValue = undefined;\n sequence.once = true;\n } else {\n // It's safe to directly remove this sequence.\n this.sequences.delete(sequence);\n this.deferredRegistrations.delete(sequence);\n }\n }\n maybeTrace(fn, snapshot) {\n // Only trace the execution if the snapshot is defined.\n return snapshot ? snapshot.run(TracingAction.AFTER_NEXT_RENDER, fn) : fn();\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: AfterRenderImpl,\n providedIn: 'root',\n factory: () => new AfterRenderImpl()\n });\n}\nclass AfterRenderSequence {\n impl;\n hooks;\n view;\n once;\n snapshot;\n /**\n * Whether this sequence errored or was destroyed during this execution, and hooks should no\n * longer run for it.\n */\n erroredOrDestroyed = false;\n /**\n * The value returned by the last hook execution (if any), ready to be pipelined into the next\n * one.\n */\n pipelinedValue = undefined;\n unregisterOnDestroy;\n constructor(impl, hooks, view, once, destroyRef, snapshot = null) {\n this.impl = impl;\n this.hooks = hooks;\n this.view = view;\n this.once = once;\n this.snapshot = snapshot;\n this.unregisterOnDestroy = destroyRef?.onDestroy(() => this.destroy());\n }\n afterRun() {\n this.erroredOrDestroyed = false;\n this.pipelinedValue = undefined;\n // Clear the tracing snapshot after the initial run. This snapshot only\n // associates the initial run of the hook with the context that created it.\n // Follow-up runs are independent of that initial context and have different\n // triggers.\n this.snapshot?.dispose();\n this.snapshot = null;\n }\n destroy() {\n this.impl.unregister(this);\n this.unregisterOnDestroy?.();\n const scheduled = this.view?.[AFTER_RENDER_SEQUENCES_TO_ADD];\n if (scheduled) {\n this.view[AFTER_RENDER_SEQUENCES_TO_ADD] = scheduled.filter(s => s !== this);\n }\n }\n}\nfunction afterRender(callbackOrSpec, options) {\n ngDevMode && assertNotInReactiveContext(afterRender, 'Call `afterRender` outside of a reactive context. For example, schedule the render ' + 'callback inside the component constructor`.');\n !options?.injector && assertInInjectionContext(afterRender);\n const injector = options?.injector ?? inject(Injector);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n return NOOP_AFTER_RENDER_REF;\n }\n performanceMarkFeature('NgAfterRender');\n return afterRenderImpl(callbackOrSpec, injector, options, /* once */false);\n}\nfunction afterNextRender(callbackOrSpec, options) {\n !options?.injector && assertInInjectionContext(afterNextRender);\n const injector = options?.injector ?? inject(Injector);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n return NOOP_AFTER_RENDER_REF;\n }\n performanceMarkFeature('NgAfterNextRender');\n return afterRenderImpl(callbackOrSpec, injector, options, /* once */true);\n}\nfunction getHooks(callbackOrSpec, phase) {\n if (callbackOrSpec instanceof Function) {\n const hooks = [undefined, undefined, undefined, undefined];\n hooks[phase] = callbackOrSpec;\n return hooks;\n } else {\n return [callbackOrSpec.earlyRead, callbackOrSpec.write, callbackOrSpec.mixedReadWrite, callbackOrSpec.read];\n }\n}\n/**\n * Shared implementation for `afterRender` and `afterNextRender`.\n */\nfunction afterRenderImpl(callbackOrSpec, injector, options, once) {\n const manager = injector.get(AfterRenderManager);\n // Lazily initialize the handler implementation, if necessary. This is so that it can be\n // tree-shaken if `afterRender` and `afterNextRender` aren't used.\n manager.impl ??= injector.get(AfterRenderImpl);\n const tracing = injector.get(TracingService, null, {\n optional: true\n });\n const hooks = options?.phase ?? AfterRenderPhase.MixedReadWrite;\n const destroyRef = options?.manualCleanup !== true ? injector.get(DestroyRef) : null;\n const viewContext = injector.get(ViewContext, null, {\n optional: true\n });\n const sequence = new AfterRenderSequence(manager.impl, getHooks(callbackOrSpec, hooks), viewContext?.view, once, destroyRef, tracing?.snapshot(null));\n manager.impl.register(sequence);\n return sequence;\n}\n/** `AfterRenderRef` that does nothing. */\nconst NOOP_AFTER_RENDER_REF = {\n destroy() {}\n};\n\n/**\n * Describes the state of defer block dependency loading.\n */\nvar DeferDependenciesLoadingState;\n(function (DeferDependenciesLoadingState) {\n /** Initial state, dependency loading is not yet triggered */\n DeferDependenciesLoadingState[DeferDependenciesLoadingState[\"NOT_STARTED\"] = 0] = \"NOT_STARTED\";\n /** Dependency loading is in progress */\n DeferDependenciesLoadingState[DeferDependenciesLoadingState[\"IN_PROGRESS\"] = 1] = \"IN_PROGRESS\";\n /** Dependency loading has completed successfully */\n DeferDependenciesLoadingState[DeferDependenciesLoadingState[\"COMPLETE\"] = 2] = \"COMPLETE\";\n /** Dependency loading has failed */\n DeferDependenciesLoadingState[DeferDependenciesLoadingState[\"FAILED\"] = 3] = \"FAILED\";\n})(DeferDependenciesLoadingState || (DeferDependenciesLoadingState = {}));\n/** Slot index where `minimum` parameter value is stored. */\nconst MINIMUM_SLOT = 0;\n/** Slot index where `after` parameter value is stored. */\nconst LOADING_AFTER_SLOT = 1;\n/**\n * Describes the current state of this defer block instance.\n *\n * @publicApi\n */\nvar DeferBlockState;\n(function (DeferBlockState) {\n /** The placeholder block content is rendered */\n DeferBlockState[DeferBlockState[\"Placeholder\"] = 0] = \"Placeholder\";\n /** The loading block content is rendered */\n DeferBlockState[DeferBlockState[\"Loading\"] = 1] = \"Loading\";\n /** The main content block content is rendered */\n DeferBlockState[DeferBlockState[\"Complete\"] = 2] = \"Complete\";\n /** The error block content is rendered */\n DeferBlockState[DeferBlockState[\"Error\"] = 3] = \"Error\";\n})(DeferBlockState || (DeferBlockState = {}));\n/**\n * Describes the initial state of this defer block instance.\n *\n * Note: this state is internal only and *must* be represented\n * with a number lower than any value in the `DeferBlockState` enum.\n */\nvar DeferBlockInternalState;\n(function (DeferBlockInternalState) {\n /** Initial state. Nothing is rendered yet. */\n DeferBlockInternalState[DeferBlockInternalState[\"Initial\"] = -1] = \"Initial\";\n})(DeferBlockInternalState || (DeferBlockInternalState = {}));\nconst NEXT_DEFER_BLOCK_STATE = 0;\n// Note: it's *important* to keep the state in this slot, because this slot\n// is used by runtime logic to differentiate between LViews, LContainers and\n// other types (see `isLView` and `isLContainer` functions). In case of defer\n// blocks, this slot would always be a number.\nconst DEFER_BLOCK_STATE = 1;\nconst STATE_IS_FROZEN_UNTIL = 2;\nconst LOADING_AFTER_CLEANUP_FN = 3;\nconst TRIGGER_CLEANUP_FNS = 4;\nconst PREFETCH_TRIGGER_CLEANUP_FNS = 5;\nconst SSR_UNIQUE_ID = 6;\nconst SSR_BLOCK_STATE = 7;\nconst ON_COMPLETE_FNS = 8;\nconst HYDRATE_TRIGGER_CLEANUP_FNS = 9;\n/**\n * Options for configuring defer blocks behavior.\n * @publicApi\n */\nvar DeferBlockBehavior;\n(function (DeferBlockBehavior) {\n /**\n * Manual triggering mode for defer blocks. Provides control over when defer blocks render\n * and which state they render.\n */\n DeferBlockBehavior[DeferBlockBehavior[\"Manual\"] = 0] = \"Manual\";\n /**\n * Playthrough mode for defer blocks. This mode behaves like defer blocks would in a browser.\n * This is the default behavior in test environments.\n */\n DeferBlockBehavior[DeferBlockBehavior[\"Playthrough\"] = 1] = \"Playthrough\";\n})(DeferBlockBehavior || (DeferBlockBehavior = {}));\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Registers a cleanup function associated with a prefetching trigger\n * or a regular trigger of a defer block.\n */\nfunction storeTriggerCleanupFn(type, lDetails, cleanupFn) {\n const key = getCleanupFnKeyByType(type);\n if (lDetails[key] === null) {\n lDetails[key] = [];\n }\n lDetails[key].push(cleanupFn);\n}\n/**\n * Invokes registered cleanup functions either for prefetch or for regular triggers.\n */\nfunction invokeTriggerCleanupFns(type, lDetails) {\n const key = getCleanupFnKeyByType(type);\n const cleanupFns = lDetails[key];\n if (cleanupFns !== null) {\n for (const cleanupFn of cleanupFns) {\n cleanupFn();\n }\n lDetails[key] = null;\n }\n}\n/**\n * Invokes registered cleanup functions for prefetch, hydrate, and regular triggers.\n */\nfunction invokeAllTriggerCleanupFns(lDetails) {\n invokeTriggerCleanupFns(1 /* TriggerType.Prefetch */, lDetails);\n invokeTriggerCleanupFns(0 /* TriggerType.Regular */, lDetails);\n invokeTriggerCleanupFns(2 /* TriggerType.Hydrate */, lDetails);\n}\nfunction getCleanupFnKeyByType(type) {\n let key = TRIGGER_CLEANUP_FNS;\n if (type === 1 /* TriggerType.Prefetch */) {\n key = PREFETCH_TRIGGER_CLEANUP_FNS;\n } else if (type === 2 /* TriggerType.Hydrate */) {\n key = HYDRATE_TRIGGER_CLEANUP_FNS;\n }\n return key;\n}\n\n/**\n * Calculates a data slot index for defer block info (either static or\n * instance-specific), given an index of a defer instruction.\n */\nfunction getDeferBlockDataIndex(deferBlockIndex) {\n // Instance state is located at the *next* position\n // after the defer block slot in an LView or TView.data.\n return deferBlockIndex + 1;\n}\n/** Retrieves a defer block state from an LView, given a TNode that represents a block. */\nfunction getLDeferBlockDetails(lView, tNode) {\n const tView = lView[TVIEW];\n const slotIndex = getDeferBlockDataIndex(tNode.index);\n ngDevMode && assertIndexInDeclRange(tView, slotIndex);\n return lView[slotIndex];\n}\n/** Stores a defer block instance state in LView. */\nfunction setLDeferBlockDetails(lView, deferBlockIndex, lDetails) {\n const tView = lView[TVIEW];\n const slotIndex = getDeferBlockDataIndex(deferBlockIndex);\n ngDevMode && assertIndexInDeclRange(tView, slotIndex);\n lView[slotIndex] = lDetails;\n}\n/** Retrieves static info about a defer block, given a TView and a TNode that represents a block. */\nfunction getTDeferBlockDetails(tView, tNode) {\n const slotIndex = getDeferBlockDataIndex(tNode.index);\n ngDevMode && assertIndexInDeclRange(tView, slotIndex);\n return tView.data[slotIndex];\n}\n/** Stores a defer block static info in `TView.data`. */\nfunction setTDeferBlockDetails(tView, deferBlockIndex, deferBlockConfig) {\n const slotIndex = getDeferBlockDataIndex(deferBlockIndex);\n ngDevMode && assertIndexInDeclRange(tView, slotIndex);\n tView.data[slotIndex] = deferBlockConfig;\n}\nfunction getTemplateIndexForState(newState, hostLView, tNode) {\n const tView = hostLView[TVIEW];\n const tDetails = getTDeferBlockDetails(tView, tNode);\n switch (newState) {\n case DeferBlockState.Complete:\n return tDetails.primaryTmplIndex;\n case DeferBlockState.Loading:\n return tDetails.loadingTmplIndex;\n case DeferBlockState.Error:\n return tDetails.errorTmplIndex;\n case DeferBlockState.Placeholder:\n return tDetails.placeholderTmplIndex;\n default:\n ngDevMode && throwError(`Unexpected defer block state: ${newState}`);\n return null;\n }\n}\n/**\n * Returns a minimum amount of time that a given state should be rendered for,\n * taking into account `minimum` parameter value. If the `minimum` value is\n * not specified - returns `null`.\n */\nfunction getMinimumDurationForState(tDetails, currentState) {\n if (currentState === DeferBlockState.Placeholder) {\n return tDetails.placeholderBlockConfig?.[MINIMUM_SLOT] ?? null;\n } else if (currentState === DeferBlockState.Loading) {\n return tDetails.loadingBlockConfig?.[MINIMUM_SLOT] ?? null;\n }\n return null;\n}\n/** Retrieves the value of the `after` parameter on the @loading block. */\nfunction getLoadingBlockAfter(tDetails) {\n return tDetails.loadingBlockConfig?.[LOADING_AFTER_SLOT] ?? null;\n}\n/**\n * Adds downloaded dependencies into a directive or a pipe registry,\n * making sure that a dependency doesn't yet exist in the registry.\n */\nfunction addDepsToRegistry(currentDeps, newDeps) {\n if (!currentDeps || currentDeps.length === 0) {\n return newDeps;\n }\n const currentDepSet = new Set(currentDeps);\n for (const dep of newDeps) {\n currentDepSet.add(dep);\n }\n // If `currentDeps` is the same length, there were no new deps and can\n // return the original array.\n return currentDeps.length === currentDepSet.size ? currentDeps : Array.from(currentDepSet);\n}\n/** Retrieves a TNode that represents main content of a defer block. */\nfunction getPrimaryBlockTNode(tView, tDetails) {\n const adjustedIndex = tDetails.primaryTmplIndex + HEADER_OFFSET;\n return getTNode(tView, adjustedIndex);\n}\n/**\n * Asserts whether all dependencies for a defer block are loaded.\n * Always run this function (in dev mode) before rendering a defer\n * block in completed state.\n */\nfunction assertDeferredDependenciesLoaded(tDetails) {\n assertEqual(tDetails.loadingState, DeferDependenciesLoadingState.COMPLETE, 'Expecting all deferred dependencies to be loaded.');\n}\n/**\n * Determines if a given value matches the expected structure of a defer block\n *\n * We can safely rely on the primaryTmplIndex because every defer block requires\n * that a primary template exists. All the other template options are optional.\n */\nfunction isTDeferBlockDetails(value) {\n return value !== null && typeof value === 'object' && typeof value.primaryTmplIndex === 'number';\n}\n/**\n * Whether a given TNode represents a defer block.\n */\nfunction isDeferBlock(tView, tNode) {\n let tDetails = null;\n const slotIndex = getDeferBlockDataIndex(tNode.index);\n // Check if a slot index is in the reasonable range.\n // Note: we do `-1` on the right border, since defer block details are stored\n // in the `n+1` slot, see `getDeferBlockDataIndex` for more info.\n if (HEADER_OFFSET < slotIndex && slotIndex < tView.bindingStartIndex) {\n tDetails = getTDeferBlockDetails(tView, tNode);\n }\n return !!tDetails && isTDeferBlockDetails(tDetails);\n}\n/**\n * Tracks debugging information about a trigger.\n * @param tView TView in which the trigger is declared.\n * @param tNode TNode on which the trigger is declared.\n * @param textRepresentation Text representation of the trigger to be used for debugging purposes.\n */\nfunction trackTriggerForDebugging(tView, tNode, textRepresentation) {\n const tDetails = getTDeferBlockDetails(tView, tNode);\n tDetails.debug ??= {};\n tDetails.debug.triggers ??= new Set();\n tDetails.debug.triggers.add(textRepresentation);\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/** Configuration object used to register passive and capturing events. */\nconst eventListenerOptions = {\n passive: true,\n capture: true\n};\n/** Keeps track of the currently-registered `on hover` triggers. */\nconst hoverTriggers = new WeakMap();\n/** Keeps track of the currently-registered `on interaction` triggers. */\nconst interactionTriggers = new WeakMap();\n/** Currently-registered `viewport` triggers. */\nconst viewportTriggers = new WeakMap();\n/** Names of the events considered as interaction events. */\nconst interactionEventNames = ['click', 'keydown'];\n/** Names of the events considered as hover events. */\nconst hoverEventNames = ['mouseenter', 'mouseover', 'focusin'];\n/** `IntersectionObserver` used to observe `viewport` triggers. */\nlet intersectionObserver = null;\n/** Number of elements currently observed with `viewport` triggers. */\nlet observedViewportElements = 0;\n/** Object keeping track of registered callbacks for a deferred block trigger. */\nclass DeferEventEntry {\n callbacks = new Set();\n listener = () => {\n for (const callback of this.callbacks) {\n callback();\n }\n };\n}\n/**\n * Registers an interaction trigger.\n * @param trigger Element that is the trigger.\n * @param callback Callback to be invoked when the trigger is interacted with.\n */\nfunction onInteraction(trigger, callback) {\n let entry = interactionTriggers.get(trigger);\n // If this is the first entry for this element, add the listeners.\n if (!entry) {\n // Note that managing events centrally like this lends itself well to using global\n // event delegation. It currently does delegation at the element level, rather than the\n // document level, because:\n // 1. Global delegation is the most effective when there are a lot of events being registered\n // at the same time. Deferred blocks are unlikely to be used in such a way.\n // 2. Matching events to their target isn't free. For each `click` and `keydown` event we\n // would have look through all the triggers and check if the target either is the element\n // itself or it's contained within the element. Given that `click` and `keydown` are some\n // of the most common events, this may end up introducing a lot of runtime overhead.\n // 3. We're still registering only two events per element, no matter how many deferred blocks\n // are referencing it.\n entry = new DeferEventEntry();\n interactionTriggers.set(trigger, entry);\n for (const name of interactionEventNames) {\n trigger.addEventListener(name, entry.listener, eventListenerOptions);\n }\n }\n entry.callbacks.add(callback);\n return () => {\n const {\n callbacks,\n listener\n } = entry;\n callbacks.delete(callback);\n if (callbacks.size === 0) {\n interactionTriggers.delete(trigger);\n for (const name of interactionEventNames) {\n trigger.removeEventListener(name, listener, eventListenerOptions);\n }\n }\n };\n}\n/**\n * Registers a hover trigger.\n * @param trigger Element that is the trigger.\n * @param callback Callback to be invoked when the trigger is hovered over.\n */\nfunction onHover(trigger, callback) {\n let entry = hoverTriggers.get(trigger);\n // If this is the first entry for this element, add the listener.\n if (!entry) {\n entry = new DeferEventEntry();\n hoverTriggers.set(trigger, entry);\n for (const name of hoverEventNames) {\n trigger.addEventListener(name, entry.listener, eventListenerOptions);\n }\n }\n entry.callbacks.add(callback);\n return () => {\n const {\n callbacks,\n listener\n } = entry;\n callbacks.delete(callback);\n if (callbacks.size === 0) {\n for (const name of hoverEventNames) {\n trigger.removeEventListener(name, listener, eventListenerOptions);\n }\n hoverTriggers.delete(trigger);\n }\n };\n}\n/**\n * Registers a viewport trigger.\n * @param trigger Element that is the trigger.\n * @param callback Callback to be invoked when the trigger comes into the viewport.\n * @param injector Injector that can be used by the trigger to resolve DI tokens.\n */\nfunction onViewport(trigger, callback, injector) {\n const ngZone = injector.get(NgZone);\n let entry = viewportTriggers.get(trigger);\n intersectionObserver = intersectionObserver || ngZone.runOutsideAngular(() => {\n return new IntersectionObserver(entries => {\n for (const current of entries) {\n // Only invoke the callbacks if the specific element is intersecting.\n if (current.isIntersecting && viewportTriggers.has(current.target)) {\n ngZone.run(viewportTriggers.get(current.target).listener);\n }\n }\n });\n });\n if (!entry) {\n entry = new DeferEventEntry();\n ngZone.runOutsideAngular(() => intersectionObserver.observe(trigger));\n viewportTriggers.set(trigger, entry);\n observedViewportElements++;\n }\n entry.callbacks.add(callback);\n return () => {\n // It's possible that a different cleanup callback fully removed this element already.\n if (!viewportTriggers.has(trigger)) {\n return;\n }\n entry.callbacks.delete(callback);\n if (entry.callbacks.size === 0) {\n intersectionObserver?.unobserve(trigger);\n viewportTriggers.delete(trigger);\n observedViewportElements--;\n }\n if (observedViewportElements === 0) {\n intersectionObserver?.disconnect();\n intersectionObserver = null;\n }\n };\n}\n/**\n * Helper function to get the LView in which a deferred block's trigger is rendered.\n * @param deferredHostLView LView in which the deferred block is defined.\n * @param deferredTNode TNode defining the deferred block.\n * @param walkUpTimes Number of times to go up in the view hierarchy to find the trigger's view.\n * A negative value means that the trigger is inside the block's placeholder, while an undefined\n * value means that the trigger is in the same LView as the deferred block.\n */\nfunction getTriggerLView(deferredHostLView, deferredTNode, walkUpTimes) {\n // The trigger is in the same view, we don't need to traverse.\n if (walkUpTimes == null) {\n return deferredHostLView;\n }\n // A positive value or zero means that the trigger is in a parent view.\n if (walkUpTimes >= 0) {\n return walkUpViews(walkUpTimes, deferredHostLView);\n }\n // If the value is negative, it means that the trigger is inside the placeholder.\n const deferredContainer = deferredHostLView[deferredTNode.index];\n ngDevMode && assertLContainer(deferredContainer);\n const triggerLView = deferredContainer[CONTAINER_HEADER_OFFSET] ?? null;\n // We need to null check, because the placeholder might not have been rendered yet.\n if (ngDevMode && triggerLView !== null) {\n const lDetails = getLDeferBlockDetails(deferredHostLView, deferredTNode);\n const renderedState = lDetails[DEFER_BLOCK_STATE];\n assertEqual(renderedState, DeferBlockState.Placeholder, 'Expected a placeholder to be rendered in this defer block.');\n assertLView(triggerLView);\n }\n return triggerLView;\n}\n/**\n * Gets the element that a deferred block's trigger is pointing to.\n * @param triggerLView LView in which the trigger is defined.\n * @param triggerIndex Index at which the trigger element should've been rendered.\n */\nfunction getTriggerElement(triggerLView, triggerIndex) {\n const element = getNativeByIndex(HEADER_OFFSET + triggerIndex, triggerLView);\n ngDevMode && assertElement(element);\n return element;\n}\n/**\n * Registers a DOM-node based trigger.\n * @param initialLView LView in which the defer block is rendered.\n * @param tNode TNode representing the defer block.\n * @param triggerIndex Index at which to find the trigger element.\n * @param walkUpTimes Number of times to go up/down in the view hierarchy to find the trigger.\n * @param registerFn Function that will register the DOM events.\n * @param callback Callback to be invoked when the trigger receives the event that should render\n * the deferred block.\n * @param type Trigger type to distinguish between regular and prefetch triggers.\n */\nfunction registerDomTrigger(initialLView, tNode, triggerIndex, walkUpTimes, registerFn, callback, type) {\n const injector = initialLView[INJECTOR];\n const zone = injector.get(NgZone);\n let poll;\n function pollDomTrigger() {\n // If the initial view was destroyed, we don't need to do anything.\n if (isDestroyed(initialLView)) {\n poll.destroy();\n return;\n }\n const lDetails = getLDeferBlockDetails(initialLView, tNode);\n const renderedState = lDetails[DEFER_BLOCK_STATE];\n // If the block was loaded before the trigger was resolved, we don't need to do anything.\n if (renderedState !== DeferBlockInternalState.Initial && renderedState !== DeferBlockState.Placeholder) {\n poll.destroy();\n return;\n }\n const triggerLView = getTriggerLView(initialLView, tNode, walkUpTimes);\n // Keep polling until we resolve the trigger's LView.\n if (!triggerLView) {\n // Keep polling.\n return;\n }\n poll.destroy();\n // It's possible that the trigger's view was destroyed before we resolved the trigger element.\n if (isDestroyed(triggerLView)) {\n return;\n }\n const element = getTriggerElement(triggerLView, triggerIndex);\n const cleanup = registerFn(element, () => {\n // `pollDomTrigger` runs outside the zone (because of `afterNextRender`) and registers its\n // listeners outside the zone, so we jump back into the zone prior to running the callback.\n zone.run(() => {\n if (initialLView !== triggerLView) {\n removeLViewOnDestroy(triggerLView, cleanup);\n }\n callback();\n });\n }, injector);\n // The trigger and deferred block might be in different LViews.\n // For the main LView the cleanup would happen as a part of\n // `storeTriggerCleanupFn` logic. For trigger LView we register\n // a cleanup function there to remove event handlers in case an\n // LView gets destroyed before a trigger is invoked.\n if (initialLView !== triggerLView) {\n storeLViewOnDestroy(triggerLView, cleanup);\n }\n storeTriggerCleanupFn(type, lDetails, cleanup);\n }\n // Begin polling for the trigger.\n poll = afterRender({\n read: pollDomTrigger\n }, {\n injector\n });\n}\nconst DEFER_BLOCK_SSR_ID_ATTRIBUTE = 'ngb';\nfunction setJSActionAttributes(nativeElement, eventTypes, parentDeferBlockId = null) {\n // jsaction attributes specifically should be applied to elements and not comment nodes.\n // Comment nodes also have no setAttribute function. So this avoids errors.\n if (eventTypes.length === 0 || nativeElement.nodeType !== Node.ELEMENT_NODE) {\n return;\n }\n const existingAttr = nativeElement.getAttribute(Attribute$1.JSACTION);\n // we dedupe cases where hydrate triggers are used as it's possible that\n // someone may have added an event binding to the root node that matches what the\n // hydrate trigger adds.\n const parts = eventTypes.reduce((prev, curr) => {\n // if there is no existing attribute OR it's not in the existing one, we need to add it\n return (existingAttr?.indexOf(curr) ?? -1) === -1 ? prev + curr + ':;' : prev;\n }, '');\n // This is required to be a module accessor to appease security tests on setAttribute.\n nativeElement.setAttribute(Attribute$1.JSACTION, `${existingAttr ?? ''}${parts}`);\n const blockName = parentDeferBlockId ?? '';\n if (blockName !== '' && parts.length > 0) {\n nativeElement.setAttribute(DEFER_BLOCK_SSR_ID_ATTRIBUTE, blockName);\n }\n}\nconst sharedStashFunction = (rEl, eventType, listenerFn) => {\n const el = rEl;\n const eventListenerMap = el.__jsaction_fns ?? new Map();\n const eventListeners = eventListenerMap.get(eventType) ?? [];\n eventListeners.push(listenerFn);\n eventListenerMap.set(eventType, eventListeners);\n el.__jsaction_fns = eventListenerMap;\n};\nconst sharedMapFunction = (rEl, jsActionMap) => {\n const el = rEl;\n let blockName = el.getAttribute(DEFER_BLOCK_SSR_ID_ATTRIBUTE) ?? '';\n const blockSet = jsActionMap.get(blockName) ?? new Set();\n if (!blockSet.has(el)) {\n blockSet.add(el);\n }\n jsActionMap.set(blockName, blockSet);\n};\nfunction removeListenersFromBlocks(blockNames, jsActionMap) {\n if (blockNames.length > 0) {\n let blockList = [];\n for (let blockName of blockNames) {\n if (jsActionMap.has(blockName)) {\n blockList = [...blockList, ...jsActionMap.get(blockName)];\n }\n }\n const replayList = new Set(blockList);\n replayList.forEach(removeListeners);\n }\n}\nconst removeListeners = el => {\n el.removeAttribute(Attribute$1.JSACTION);\n el.removeAttribute(DEFER_BLOCK_SSR_ID_ATTRIBUTE);\n el.__jsaction_fns = undefined;\n};\nconst JSACTION_EVENT_CONTRACT = new InjectionToken(ngDevMode ? 'EVENT_CONTRACT_DETAILS' : '', {\n providedIn: 'root',\n factory: () => ({})\n});\nfunction invokeListeners(event, currentTarget) {\n const handlerFns = currentTarget?.__jsaction_fns?.get(event.type);\n if (!handlerFns || !currentTarget?.isConnected) {\n return;\n }\n for (const handler of handlerFns) {\n handler(event);\n }\n}\n\n/**\n * An internal injection token to reference `DehydratedBlockRegistry` implementation\n * in a tree-shakable way.\n */\nconst DEHYDRATED_BLOCK_REGISTRY = new InjectionToken(ngDevMode ? 'DEHYDRATED_BLOCK_REGISTRY' : '');\n/**\n * The DehydratedBlockRegistry is used for incremental hydration purposes. It keeps\n * track of the Defer Blocks that need hydration so we can effectively\n * navigate up to the top dehydrated defer block and fire appropriate cleanup\n * functions post hydration.\n */\nclass DehydratedBlockRegistry {\n registry = new Map();\n cleanupFns = new Map();\n jsActionMap = inject(JSACTION_BLOCK_ELEMENT_MAP);\n contract = inject(JSACTION_EVENT_CONTRACT);\n add(blockId, info) {\n this.registry.set(blockId, info);\n }\n get(blockId) {\n return this.registry.get(blockId) ?? null;\n }\n has(blockId) {\n return this.registry.has(blockId);\n }\n cleanup(hydratedBlocks) {\n removeListenersFromBlocks(hydratedBlocks, this.jsActionMap);\n for (let blockId of hydratedBlocks) {\n this.registry.delete(blockId);\n this.jsActionMap.delete(blockId);\n this.invokeTriggerCleanupFns(blockId);\n this.hydrating.delete(blockId);\n }\n if (this.size === 0) {\n this.contract.instance?.cleanUp();\n }\n }\n get size() {\n return this.registry.size;\n }\n // we have to leave the lowest block Id in the registry\n // unless that block has no children\n addCleanupFn(blockId, fn) {\n let cleanupFunctions = [];\n if (this.cleanupFns.has(blockId)) {\n cleanupFunctions = this.cleanupFns.get(blockId);\n }\n cleanupFunctions.push(fn);\n this.cleanupFns.set(blockId, cleanupFunctions);\n }\n invokeTriggerCleanupFns(blockId) {\n const fns = this.cleanupFns.get(blockId) ?? [];\n for (let fn of fns) {\n fn();\n }\n this.cleanupFns.delete(blockId);\n }\n // Blocks that are being hydrated.\n hydrating = new Map();\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: DehydratedBlockRegistry,\n providedIn: null,\n factory: () => new DehydratedBlockRegistry()\n });\n}\n\n/**\n * The name of the key used in the TransferState collection,\n * where hydration information is located.\n */\nconst TRANSFER_STATE_TOKEN_ID = '__nghData__';\n/**\n * Lookup key used to reference DOM hydration data (ngh) in `TransferState`.\n */\nconst NGH_DATA_KEY = makeStateKey(TRANSFER_STATE_TOKEN_ID);\n/**\n * The name of the key used in the TransferState collection,\n * where serialized defer block information is located.\n */\nconst TRANSFER_STATE_DEFER_BLOCKS_INFO = '__nghDeferData__';\n/**\n * Lookup key used to retrieve defer block datain `TransferState`.\n */\nconst NGH_DEFER_BLOCKS_KEY = makeStateKey(TRANSFER_STATE_DEFER_BLOCKS_INFO);\n/**\n * The name of the attribute that would be added to host component\n * nodes and contain a reference to a particular slot in transferred\n * state that contains the necessary hydration info for this component.\n */\nconst NGH_ATTR_NAME = 'ngh';\n/**\n * Marker used in a comment node to ensure hydration content integrity\n */\nconst SSR_CONTENT_INTEGRITY_MARKER = 'nghm';\n/**\n * Reference to a function that reads `ngh` attribute value from a given RNode\n * and retrieves hydration information from the TransferState using that value\n * as an index. Returns `null` by default, when hydration is not enabled.\n *\n * @param rNode Component's host element.\n * @param injector Injector that this component has access to.\n * @param isRootView Specifies whether we trying to read hydration info for the root view.\n */\nlet _retrieveHydrationInfoImpl = () => null;\nfunction retrieveHydrationInfoImpl(rNode, injector, isRootView = false) {\n let nghAttrValue = rNode.getAttribute(NGH_ATTR_NAME);\n if (nghAttrValue == null) return null;\n // For cases when a root component also acts as an anchor node for a ViewContainerRef\n // (for example, when ViewContainerRef is injected in a root component), there is a need\n // to serialize information about the component itself, as well as an LContainer that\n // represents this ViewContainerRef. Effectively, we need to serialize 2 pieces of info:\n // (1) hydration info for the root component itself and (2) hydration info for the\n // ViewContainerRef instance (an LContainer). Each piece of information is included into\n // the hydration data (in the TransferState object) separately, thus we end up with 2 ids.\n // Since we only have 1 root element, we encode both bits of info into a single string:\n // ids are separated by the `|` char (e.g. `10|25`, where `10` is the ngh for a component view\n // and 25 is the `ngh` for a root view which holds LContainer).\n const [componentViewNgh, rootViewNgh] = nghAttrValue.split('|');\n nghAttrValue = isRootView ? rootViewNgh : componentViewNgh;\n if (!nghAttrValue) return null;\n // We've read one of the ngh ids, keep the remaining one, so that\n // we can set it back on the DOM element.\n const rootNgh = rootViewNgh ? `|${rootViewNgh}` : '';\n const remainingNgh = isRootView ? componentViewNgh : rootNgh;\n let data = {};\n // An element might have an empty `ngh` attribute value (e.g. `<comp ngh=\"\" />`),\n // which means that no special annotations are required. Do not attempt to read\n // from the TransferState in this case.\n if (nghAttrValue !== '') {\n const transferState = injector.get(TransferState, null, {\n optional: true\n });\n if (transferState !== null) {\n const nghData = transferState.get(NGH_DATA_KEY, []);\n // The nghAttrValue is always a number referencing an index\n // in the hydration TransferState data.\n data = nghData[Number(nghAttrValue)];\n // If the `ngh` attribute exists and has a non-empty value,\n // the hydration info *must* be present in the TransferState.\n // If there is no data for some reasons, this is an error.\n ngDevMode && assertDefined(data, 'Unable to retrieve hydration info from the TransferState.');\n }\n }\n const dehydratedView = {\n data,\n firstChild: rNode.firstChild ?? null\n };\n if (isRootView) {\n // If there is hydration info present for the root view, it means that there was\n // a ViewContainerRef injected in the root component. The root component host element\n // acted as an anchor node in this scenario. As a result, the DOM nodes that represent\n // embedded views in this ViewContainerRef are located as siblings to the host node,\n // i.e. `<app-root /><#VIEW1><#VIEW2>...<!--container-->`. In this case, the current\n // node becomes the first child of this root view and the next sibling is the first\n // element in the DOM segment.\n dehydratedView.firstChild = rNode;\n // We use `0` here, since this is the slot (right after the HEADER_OFFSET)\n // where a component LView or an LContainer is located in a root LView.\n setSegmentHead(dehydratedView, 0, rNode.nextSibling);\n }\n if (remainingNgh) {\n // If we have only used one of the ngh ids, store the remaining one\n // back on this RNode.\n rNode.setAttribute(NGH_ATTR_NAME, remainingNgh);\n } else {\n // The `ngh` attribute is cleared from the DOM node now\n // that the data has been retrieved for all indices.\n rNode.removeAttribute(NGH_ATTR_NAME);\n }\n // Note: don't check whether this node was claimed for hydration,\n // because this node might've been previously claimed while processing\n // template instructions.\n ngDevMode && markRNodeAsClaimedByHydration(rNode, /* checkIfAlreadyClaimed */false);\n ngDevMode && ngDevMode.hydratedComponents++;\n return dehydratedView;\n}\n/**\n * Sets the implementation for the `retrieveHydrationInfo` function.\n */\nfunction enableRetrieveHydrationInfoImpl() {\n _retrieveHydrationInfoImpl = retrieveHydrationInfoImpl;\n}\n/**\n * Retrieves hydration info by reading the value from the `ngh` attribute\n * and accessing a corresponding slot in TransferState storage.\n */\nfunction retrieveHydrationInfo(rNode, injector, isRootView = false) {\n return _retrieveHydrationInfoImpl(rNode, injector, isRootView);\n}\n/**\n * Retrieves the necessary object from a given ViewRef to serialize:\n * - an LView for component views\n * - an LContainer for cases when component acts as a ViewContainerRef anchor\n * - `null` in case of an embedded view\n */\nfunction getLNodeForHydration(viewRef) {\n // Reading an internal field from `ViewRef` instance.\n let lView = viewRef._lView;\n const tView = lView[TVIEW];\n // A registered ViewRef might represent an instance of an\n // embedded view, in which case we do not need to annotate it.\n if (tView.type === 2 /* TViewType.Embedded */) {\n return null;\n }\n // Check if it's a root view and if so, retrieve component's\n // LView from the first slot after the header.\n if (isRootView(lView)) {\n lView = lView[HEADER_OFFSET];\n }\n return lView;\n}\nfunction getTextNodeContent(node) {\n return node.textContent?.replace(/\\s/gm, '');\n}\n/**\n * Restores text nodes and separators into the DOM that were lost during SSR\n * serialization. The hydration process replaces empty text nodes and text\n * nodes that are immediately adjacent to other text nodes with comment nodes\n * that this method filters on to restore those missing nodes that the\n * hydration process is expecting to be present.\n *\n * @param node The app's root HTML Element\n */\nfunction processTextNodeMarkersBeforeHydration(node) {\n const doc = getDocument();\n const commentNodesIterator = doc.createNodeIterator(node, NodeFilter.SHOW_COMMENT, {\n acceptNode(node) {\n const content = getTextNodeContent(node);\n const isTextNodeMarker = content === \"ngetn\" /* TextNodeMarker.EmptyNode */ || content === \"ngtns\" /* TextNodeMarker.Separator */;\n return isTextNodeMarker ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_REJECT;\n }\n });\n let currentNode;\n // We cannot modify the DOM while using the commentIterator,\n // because it throws off the iterator state.\n // So we collect all marker nodes first and then follow up with\n // applying the changes to the DOM: either inserting an empty node\n // or just removing the marker if it was used as a separator.\n const nodes = [];\n while (currentNode = commentNodesIterator.nextNode()) {\n nodes.push(currentNode);\n }\n for (const node of nodes) {\n if (node.textContent === \"ngetn\" /* TextNodeMarker.EmptyNode */) {\n node.replaceWith(doc.createTextNode(''));\n } else {\n node.remove();\n }\n }\n}\n/**\n * Internal type that represents a claimed node.\n * Only used in dev mode.\n */\nvar HydrationStatus;\n(function (HydrationStatus) {\n HydrationStatus[\"Hydrated\"] = \"hydrated\";\n HydrationStatus[\"Skipped\"] = \"skipped\";\n HydrationStatus[\"Mismatched\"] = \"mismatched\";\n})(HydrationStatus || (HydrationStatus = {}));\nconst HYDRATION_INFO_KEY = '__ngDebugHydrationInfo__';\nfunction patchHydrationInfo(node, info) {\n node[HYDRATION_INFO_KEY] = info;\n}\nfunction readHydrationInfo(node) {\n return node[HYDRATION_INFO_KEY] ?? null;\n}\n/**\n * Marks a node as \"claimed\" by hydration process.\n * This is needed to make assessments in tests whether\n * the hydration process handled all nodes.\n */\nfunction markRNodeAsClaimedByHydration(node, checkIfAlreadyClaimed = true) {\n if (!ngDevMode) {\n throw new Error('Calling `markRNodeAsClaimedByHydration` in prod mode ' + 'is not supported and likely a mistake.');\n }\n if (checkIfAlreadyClaimed && isRNodeClaimedForHydration(node)) {\n throw new Error('Trying to claim a node, which was claimed already.');\n }\n patchHydrationInfo(node, {\n status: HydrationStatus.Hydrated\n });\n ngDevMode.hydratedNodes++;\n}\nfunction markRNodeAsSkippedByHydration(node) {\n if (!ngDevMode) {\n throw new Error('Calling `markRNodeAsSkippedByHydration` in prod mode ' + 'is not supported and likely a mistake.');\n }\n patchHydrationInfo(node, {\n status: HydrationStatus.Skipped\n });\n ngDevMode.componentsSkippedHydration++;\n}\nfunction countBlocksSkippedByHydration(injector) {\n const transferState = injector.get(TransferState);\n const nghDeferData = transferState.get(NGH_DEFER_BLOCKS_KEY, {});\n if (ngDevMode) {\n ngDevMode.deferBlocksWithIncrementalHydration = Object.keys(nghDeferData).length;\n }\n}\nfunction markRNodeAsHavingHydrationMismatch(node, expectedNodeDetails = null, actualNodeDetails = null) {\n if (!ngDevMode) {\n throw new Error('Calling `markRNodeAsMismatchedByHydration` in prod mode ' + 'is not supported and likely a mistake.');\n }\n // The RNode can be a standard HTMLElement (not an Angular component or directive)\n // The devtools component tree only displays Angular components & directives\n // Therefore we attach the debug info to the closest component/directive\n while (node && !getComponent(node)) {\n node = node?.parentNode;\n }\n if (node) {\n patchHydrationInfo(node, {\n status: HydrationStatus.Mismatched,\n expectedNodeDetails,\n actualNodeDetails\n });\n }\n}\nfunction isRNodeClaimedForHydration(node) {\n return readHydrationInfo(node)?.status === HydrationStatus.Hydrated;\n}\nfunction setSegmentHead(hydrationInfo, index, node) {\n hydrationInfo.segmentHeads ??= {};\n hydrationInfo.segmentHeads[index] = node;\n}\nfunction getSegmentHead(hydrationInfo, index) {\n return hydrationInfo.segmentHeads?.[index] ?? null;\n}\nfunction isIncrementalHydrationEnabled(injector) {\n return injector.get(IS_INCREMENTAL_HYDRATION_ENABLED, false, {\n optional: true\n });\n}\n/** Throws an error if the incremental hydration is not enabled */\nfunction assertIncrementalHydrationIsConfigured(injector) {\n if (!isIncrementalHydrationEnabled(injector)) {\n throw new RuntimeError(508 /* RuntimeErrorCode.MISCONFIGURED_INCREMENTAL_HYDRATION */, 'Angular has detected that some `@defer` blocks use `hydrate` triggers, ' + 'but incremental hydration was not enabled. Please ensure that the `withIncrementalHydration()` ' + 'call is added as an argument for the `provideClientHydration()` function call ' + 'in your application config.');\n }\n}\n/** Throws an error if the ssrUniqueId on the LDeferBlockDetails is not present */\nfunction assertSsrIdDefined(ssrUniqueId) {\n assertDefined(ssrUniqueId, 'Internal error: expecting an SSR id for a defer block that should be hydrated, but the id is not present');\n}\n/**\n * Returns the size of an <ng-container>, using either the information\n * serialized in `ELEMENT_CONTAINERS` (element container size) or by\n * computing the sum of root nodes in all dehydrated views in a given\n * container (in case this `<ng-container>` was also used as a view\n * container host node, e.g. <ng-container *ngIf>).\n */\nfunction getNgContainerSize(hydrationInfo, index) {\n const data = hydrationInfo.data;\n let size = data[ELEMENT_CONTAINERS]?.[index] ?? null;\n // If there is no serialized information available in the `ELEMENT_CONTAINERS` slot,\n // check if we have info about view containers at this location (e.g.\n // `<ng-container *ngIf>`) and use container size as a number of root nodes in this\n // element container.\n if (size === null && data[CONTAINERS]?.[index]) {\n size = calcSerializedContainerSize(hydrationInfo, index);\n }\n return size;\n}\nfunction isSerializedElementContainer(hydrationInfo, index) {\n return hydrationInfo.data[ELEMENT_CONTAINERS]?.[index] !== undefined;\n}\nfunction getSerializedContainerViews(hydrationInfo, index) {\n return hydrationInfo.data[CONTAINERS]?.[index] ?? null;\n}\n/**\n * Computes the size of a serialized container (the number of root nodes)\n * by calculating the sum of root nodes in all dehydrated views in this container.\n */\nfunction calcSerializedContainerSize(hydrationInfo, index) {\n const views = getSerializedContainerViews(hydrationInfo, index) ?? [];\n let numNodes = 0;\n for (let view of views) {\n numNodes += view[NUM_ROOT_NODES] * (view[MULTIPLIER] ?? 1);\n }\n return numNodes;\n}\n/**\n * Attempt to initialize the `disconnectedNodes` field of the given\n * `DehydratedView`. Returns the initialized value.\n */\nfunction initDisconnectedNodes(hydrationInfo) {\n // Check if we are processing disconnected info for the first time.\n if (typeof hydrationInfo.disconnectedNodes === 'undefined') {\n const nodeIds = hydrationInfo.data[DISCONNECTED_NODES];\n hydrationInfo.disconnectedNodes = nodeIds ? new Set(nodeIds) : null;\n }\n return hydrationInfo.disconnectedNodes;\n}\n/**\n * Checks whether a node is annotated as \"disconnected\", i.e. not present\n * in the DOM at serialization time. We should not attempt hydration for\n * such nodes and instead, use a regular \"creation mode\".\n */\nfunction isDisconnectedNode$1(hydrationInfo, index) {\n // Check if we are processing disconnected info for the first time.\n if (typeof hydrationInfo.disconnectedNodes === 'undefined') {\n const nodeIds = hydrationInfo.data[DISCONNECTED_NODES];\n hydrationInfo.disconnectedNodes = nodeIds ? new Set(nodeIds) : null;\n }\n return !!initDisconnectedNodes(hydrationInfo)?.has(index);\n}\n/**\n * Helper function to prepare text nodes for serialization by ensuring\n * that seperate logical text blocks in the DOM remain separate after\n * serialization.\n */\nfunction processTextNodeBeforeSerialization(context, node) {\n // Handle cases where text nodes can be lost after DOM serialization:\n // 1. When there is an *empty text node* in DOM: in this case, this\n // node would not make it into the serialized string and as a result,\n // this node wouldn't be created in a browser. This would result in\n // a mismatch during the hydration, where the runtime logic would expect\n // a text node to be present in live DOM, but no text node would exist.\n // Example: `<span>{{ name }}</span>` when the `name` is an empty string.\n // This would result in `<span></span>` string after serialization and\n // in a browser only the `span` element would be created. To resolve that,\n // an extra comment node is appended in place of an empty text node and\n // that special comment node is replaced with an empty text node *before*\n // hydration.\n // 2. When there are 2 consecutive text nodes present in the DOM.\n // Example: `<div>Hello <ng-container *ngIf=\"true\">world</ng-container></div>`.\n // In this scenario, the live DOM would look like this:\n // <div>#text('Hello ') #text('world') #comment('container')</div>\n // Serialized string would look like this: `<div>Hello world<!--container--></div>`.\n // The live DOM in a browser after that would be:\n // <div>#text('Hello world') #comment('container')</div>\n // Notice how 2 text nodes are now \"merged\" into one. This would cause hydration\n // logic to fail, since it'd expect 2 text nodes being present, not one.\n // To fix this, we insert a special comment node in between those text nodes, so\n // serialized representation is: `<div>Hello <!--ngtns-->world<!--container--></div>`.\n // This forces browser to create 2 text nodes separated by a comment node.\n // Before running a hydration process, this special comment node is removed, so the\n // live DOM has exactly the same state as it was before serialization.\n // Collect this node as required special annotation only when its\n // contents is empty. Otherwise, such text node would be present on\n // the client after server-side rendering and no special handling needed.\n const el = node;\n const corruptedTextNodes = context.corruptedTextNodes;\n if (el.textContent === '') {\n corruptedTextNodes.set(el, \"ngetn\" /* TextNodeMarker.EmptyNode */);\n } else if (el.nextSibling?.nodeType === Node.TEXT_NODE) {\n corruptedTextNodes.set(el, \"ngtns\" /* TextNodeMarker.Separator */);\n }\n}\nfunction convertHydrateTriggersToJsAction(triggers) {\n let actionList = [];\n if (triggers !== null) {\n if (triggers.has(4 /* DeferBlockTrigger.Hover */)) {\n actionList.push(...hoverEventNames);\n }\n if (triggers.has(3 /* DeferBlockTrigger.Interaction */)) {\n actionList.push(...interactionEventNames);\n }\n }\n return actionList;\n}\n/**\n * Builds a queue of blocks that need to be hydrated, looking up the\n * tree to the topmost defer block that exists in the tree that hasn't\n * been hydrated, but exists in the registry. This queue is in top down\n * hierarchical order as a list of defer block ids.\n * Note: This is utilizing serialized information to navigate up the tree\n */\nfunction getParentBlockHydrationQueue(deferBlockId, injector) {\n const dehydratedBlockRegistry = injector.get(DEHYDRATED_BLOCK_REGISTRY);\n const transferState = injector.get(TransferState);\n const deferBlockParents = transferState.get(NGH_DEFER_BLOCKS_KEY, {});\n let isTopMostDeferBlock = false;\n let currentBlockId = deferBlockId;\n let parentBlockPromise = null;\n const hydrationQueue = [];\n while (!isTopMostDeferBlock && currentBlockId) {\n ngDevMode && assertEqual(hydrationQueue.indexOf(currentBlockId), -1, 'Internal error: defer block hierarchy has a cycle.');\n isTopMostDeferBlock = dehydratedBlockRegistry.has(currentBlockId);\n const hydratingParentBlock = dehydratedBlockRegistry.hydrating.get(currentBlockId);\n if (parentBlockPromise === null && hydratingParentBlock != null) {\n // TODO: add an ngDevMode asset that `hydratingParentBlock.promise` exists and is of type Promise.\n parentBlockPromise = hydratingParentBlock.promise;\n break;\n }\n hydrationQueue.unshift(currentBlockId);\n currentBlockId = deferBlockParents[currentBlockId][DEFER_PARENT_BLOCK_ID];\n }\n return {\n parentBlockPromise,\n hydrationQueue\n };\n}\nfunction gatherDeferBlocksByJSActionAttribute(doc) {\n const jsactionNodes = doc.body.querySelectorAll('[jsaction]');\n const blockMap = new Set();\n for (let node of jsactionNodes) {\n const attr = node.getAttribute('jsaction');\n const blockId = node.getAttribute('ngb');\n const eventTypes = [...hoverEventNames.join(':;'), ...interactionEventNames.join(':;')].join('|');\n if (attr?.match(eventTypes) && blockId !== null) {\n blockMap.add(node);\n }\n }\n return blockMap;\n}\nfunction appendDeferBlocksToJSActionMap(doc, injector) {\n const blockMap = gatherDeferBlocksByJSActionAttribute(doc);\n for (let rNode of blockMap) {\n const jsActionMap = injector.get(JSACTION_BLOCK_ELEMENT_MAP);\n sharedMapFunction(rNode, jsActionMap);\n }\n}\n/**\n * Retrieves defer block hydration information from the TransferState.\n *\n * @param injector Injector that this component has access to.\n */\nlet _retrieveDeferBlockDataImpl = () => {\n return {};\n};\nfunction retrieveDeferBlockDataImpl(injector) {\n const transferState = injector.get(TransferState, null, {\n optional: true\n });\n if (transferState !== null) {\n const nghDeferData = transferState.get(NGH_DEFER_BLOCKS_KEY, {});\n ngDevMode && assertDefined(nghDeferData, 'Unable to retrieve defer block info from the TransferState.');\n return nghDeferData;\n }\n return {};\n}\n/**\n * Sets the implementation for the `retrieveDeferBlockData` function.\n */\nfunction enableRetrieveDeferBlockDataImpl() {\n _retrieveDeferBlockDataImpl = retrieveDeferBlockDataImpl;\n}\n/**\n * Retrieves defer block data from TransferState storage\n */\nfunction retrieveDeferBlockData(injector) {\n return _retrieveDeferBlockDataImpl(injector);\n}\nfunction isTimerTrigger(triggerInfo) {\n return typeof triggerInfo === 'object' && triggerInfo.trigger === 5 /* DeferBlockTrigger.Timer */;\n}\nfunction getHydrateTimerTrigger(blockData) {\n const trigger = blockData[DEFER_HYDRATE_TRIGGERS]?.find(t => isTimerTrigger(t));\n return trigger?.delay ?? null;\n}\nfunction hasHydrateTrigger(blockData, trigger) {\n return blockData[DEFER_HYDRATE_TRIGGERS]?.includes(trigger) ?? false;\n}\n/**\n * Creates a summary of the given serialized defer block, which is used later to properly initialize\n * specific triggers.\n */\nfunction createBlockSummary(blockInfo) {\n return {\n data: blockInfo,\n hydrate: {\n idle: hasHydrateTrigger(blockInfo, 0 /* DeferBlockTrigger.Idle */),\n immediate: hasHydrateTrigger(blockInfo, 1 /* DeferBlockTrigger.Immediate */),\n timer: getHydrateTimerTrigger(blockInfo),\n viewport: hasHydrateTrigger(blockInfo, 2 /* DeferBlockTrigger.Viewport */)\n }\n };\n}\n/**\n * Processes all of the defer block data in the transfer state and creates a map of the summaries\n */\nfunction processBlockData(injector) {\n const blockData = retrieveDeferBlockData(injector);\n let blockDetails = new Map();\n for (let blockId in blockData) {\n blockDetails.set(blockId, createBlockSummary(blockData[blockId]));\n }\n return blockDetails;\n}\n\n/** Refreshes all content queries declared by directives in a given view */\nfunction refreshContentQueries(tView, lView) {\n const contentQueries = tView.contentQueries;\n if (contentQueries !== null) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n for (let i = 0; i < contentQueries.length; i += 2) {\n const queryStartIdx = contentQueries[i];\n const directiveDefIdx = contentQueries[i + 1];\n if (directiveDefIdx !== -1) {\n const directiveDef = tView.data[directiveDefIdx];\n ngDevMode && assertDefined(directiveDef, 'DirectiveDef not found.');\n ngDevMode && assertDefined(directiveDef.contentQueries, 'contentQueries function should be defined');\n setCurrentQueryIndex(queryStartIdx);\n directiveDef.contentQueries(2 /* RenderFlags.Update */, lView[directiveDefIdx], directiveDefIdx);\n }\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n}\nfunction executeViewQueryFn(flags, viewQueryFn, component) {\n ngDevMode && assertDefined(viewQueryFn, 'View queries function to execute must be defined.');\n setCurrentQueryIndex(0);\n const prevConsumer = setActiveConsumer$1(null);\n try {\n viewQueryFn(flags, component);\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n}\nfunction executeContentQueries(tView, tNode, lView) {\n if (isContentQueryHost(tNode)) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n const start = tNode.directiveStart;\n const end = tNode.directiveEnd;\n for (let directiveIndex = start; directiveIndex < end; directiveIndex++) {\n const def = tView.data[directiveIndex];\n if (def.contentQueries) {\n const directiveInstance = lView[directiveIndex];\n ngDevMode && assertDefined(directiveIndex, 'Incorrect reference to a directive defining a content query');\n def.contentQueries(1 /* RenderFlags.Create */, directiveInstance, directiveIndex);\n }\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n}\n\n/**\n * Defines the CSS styles encapsulation policies for the {@link /api/core/Component Component} decorator's\n * `encapsulation` option.\n *\n * See {@link Component#encapsulation encapsulation}.\n *\n * @usageNotes\n * ### Example\n *\n * {@example core/ts/metadata/encapsulation.ts region='longform'}\n *\n * @publicApi\n */\nvar ViewEncapsulation;\n(function (ViewEncapsulation) {\n // TODO: consider making `ViewEncapsulation` a `const enum` instead. See\n // https://github.com/angular/angular/issues/44119 for additional information.\n /**\n * Emulates a native Shadow DOM encapsulation behavior by adding a specific attribute to the\n * component's host element and applying the same attribute to all the CSS selectors provided\n * via {@link Component#styles styles} or {@link Component#styleUrls styleUrls}.\n *\n * This is the default option.\n */\n ViewEncapsulation[ViewEncapsulation[\"Emulated\"] = 0] = \"Emulated\";\n // Historically the 1 value was for `Native` encapsulation which has been removed as of v11.\n /**\n * Doesn't provide any sort of CSS style encapsulation, meaning that all the styles provided\n * via {@link Component#styles styles} or {@link Component#styleUrls styleUrls} are applicable\n * to any HTML element of the application regardless of their host Component.\n */\n ViewEncapsulation[ViewEncapsulation[\"None\"] = 2] = \"None\";\n /**\n * Uses the browser's native Shadow DOM API to encapsulate CSS styles, meaning that it creates\n * a ShadowRoot for the component's host element which is then used to encapsulate\n * all the Component's styling.\n */\n ViewEncapsulation[ViewEncapsulation[\"ShadowDom\"] = 3] = \"ShadowDom\";\n})(ViewEncapsulation || (ViewEncapsulation = {}));\n\n/**\n * @fileoverview\n * A module to facilitate use of a Trusted Types policy internally within\n * Angular. It lazily constructs the Trusted Types policy, providing helper\n * utilities for promoting strings to Trusted Types. When Trusted Types are not\n * available, strings are used as a fallback.\n * @security All use of this module is security-sensitive and should go through\n * security review.\n */\n/**\n * The Trusted Types policy, or null if Trusted Types are not\n * enabled/supported, or undefined if the policy has not been created yet.\n */\nlet policy$1;\n/**\n * Returns the Trusted Types policy, or null if Trusted Types are not\n * enabled/supported. The first call to this function will create the policy.\n */\nfunction getPolicy$1() {\n if (policy$1 === undefined) {\n policy$1 = null;\n if (_global.trustedTypes) {\n try {\n policy$1 = _global.trustedTypes.createPolicy('angular', {\n createHTML: s => s,\n createScript: s => s,\n createScriptURL: s => s\n });\n } catch {\n // trustedTypes.createPolicy throws if called with a name that is\n // already registered, even in report-only mode. Until the API changes,\n // catch the error not to break the applications functionally. In such\n // cases, the code will fall back to using strings.\n }\n }\n }\n return policy$1;\n}\n/**\n * Unsafely promote a string to a TrustedHTML, falling back to strings when\n * Trusted Types are not available.\n * @security This is a security-sensitive function; any use of this function\n * must go through security review. In particular, it must be assured that the\n * provided string will never cause an XSS vulnerability if used in a context\n * that will be interpreted as HTML by a browser, e.g. when assigning to\n * element.innerHTML.\n */\nfunction trustedHTMLFromString(html) {\n return getPolicy$1()?.createHTML(html) || html;\n}\n/**\n * Unsafely promote a string to a TrustedScript, falling back to strings when\n * Trusted Types are not available.\n * @security In particular, it must be assured that the provided string will\n * never cause an XSS vulnerability if used in a context that will be\n * interpreted and executed as a script by a browser, e.g. when calling eval.\n */\nfunction trustedScriptFromString(script) {\n return getPolicy$1()?.createScript(script) || script;\n}\n/**\n * Unsafely promote a string to a TrustedScriptURL, falling back to strings\n * when Trusted Types are not available.\n * @security This is a security-sensitive function; any use of this function\n * must go through security review. In particular, it must be assured that the\n * provided string will never cause an XSS vulnerability if used in a context\n * that will cause a browser to load and execute a resource, e.g. when\n * assigning to script.src.\n */\nfunction trustedScriptURLFromString(url) {\n return getPolicy$1()?.createScriptURL(url) || url;\n}\n/**\n * Unsafely call the Function constructor with the given string arguments. It\n * is only available in development mode, and should be stripped out of\n * production code.\n * @security This is a security-sensitive function; any use of this function\n * must go through security review. In particular, it must be assured that it\n * is only called from development code, as use in production code can lead to\n * XSS vulnerabilities.\n */\nfunction newTrustedFunctionForDev(...args) {\n if (typeof ngDevMode === 'undefined') {\n throw new Error('newTrustedFunctionForDev should never be called in production');\n }\n if (!_global.trustedTypes) {\n // In environments that don't support Trusted Types, fall back to the most\n // straightforward implementation:\n return new Function(...args);\n }\n // Chrome currently does not support passing TrustedScript to the Function\n // constructor. The following implements the workaround proposed on the page\n // below, where the Chromium bug is also referenced:\n // https://github.com/w3c/webappsec-trusted-types/wiki/Trusted-Types-for-function-constructor\n const fnArgs = args.slice(0, -1).join(',');\n const fnBody = args[args.length - 1];\n const body = `(function anonymous(${fnArgs}\n) { ${fnBody}\n})`;\n // Using eval directly confuses the compiler and prevents this module from\n // being stripped out of JS binaries even if not used. The global['eval']\n // indirection fixes that.\n const fn = _global['eval'](trustedScriptFromString(body));\n if (fn.bind === undefined) {\n // Workaround for a browser bug that only exists in Chrome 83, where passing\n // a TrustedScript to eval just returns the TrustedScript back without\n // evaluating it. In that case, fall back to the most straightforward\n // implementation:\n return new Function(...args);\n }\n // To completely mimic the behavior of calling \"new Function\", two more\n // things need to happen:\n // 1. Stringifying the resulting function should return its source code\n fn.toString = () => body;\n // 2. When calling the resulting function, `this` should refer to `global`\n return fn.bind(_global);\n // When Trusted Types support in Function constructors is widely available,\n // the implementation of this function can be simplified to:\n // return new Function(...args.map(a => trustedScriptFromString(a)));\n}\n\n/**\n * @fileoverview\n * A module to facilitate use of a Trusted Types policy internally within\n * Angular specifically for bypassSecurityTrust* and custom sanitizers. It\n * lazily constructs the Trusted Types policy, providing helper utilities for\n * promoting strings to Trusted Types. When Trusted Types are not available,\n * strings are used as a fallback.\n * @security All use of this module is security-sensitive and should go through\n * security review.\n */\n/**\n * The Trusted Types policy, or null if Trusted Types are not\n * enabled/supported, or undefined if the policy has not been created yet.\n */\nlet policy;\n/**\n * Returns the Trusted Types policy, or null if Trusted Types are not\n * enabled/supported. The first call to this function will create the policy.\n */\nfunction getPolicy() {\n if (policy === undefined) {\n policy = null;\n if (_global.trustedTypes) {\n try {\n policy = _global.trustedTypes.createPolicy('angular#unsafe-bypass', {\n createHTML: s => s,\n createScript: s => s,\n createScriptURL: s => s\n });\n } catch {\n // trustedTypes.createPolicy throws if called with a name that is\n // already registered, even in report-only mode. Until the API changes,\n // catch the error not to break the applications functionally. In such\n // cases, the code will fall back to using strings.\n }\n }\n }\n return policy;\n}\n/**\n * Unsafely promote a string to a TrustedHTML, falling back to strings when\n * Trusted Types are not available.\n * @security This is a security-sensitive function; any use of this function\n * must go through security review. In particular, it must be assured that it\n * is only passed strings that come directly from custom sanitizers or the\n * bypassSecurityTrust* functions.\n */\nfunction trustedHTMLFromStringBypass(html) {\n return getPolicy()?.createHTML(html) || html;\n}\n/**\n * Unsafely promote a string to a TrustedScript, falling back to strings when\n * Trusted Types are not available.\n * @security This is a security-sensitive function; any use of this function\n * must go through security review. In particular, it must be assured that it\n * is only passed strings that come directly from custom sanitizers or the\n * bypassSecurityTrust* functions.\n */\nfunction trustedScriptFromStringBypass(script) {\n return getPolicy()?.createScript(script) || script;\n}\n/**\n * Unsafely promote a string to a TrustedScriptURL, falling back to strings\n * when Trusted Types are not available.\n * @security This is a security-sensitive function; any use of this function\n * must go through security review. In particular, it must be assured that it\n * is only passed strings that come directly from custom sanitizers or the\n * bypassSecurityTrust* functions.\n */\nfunction trustedScriptURLFromStringBypass(url) {\n return getPolicy()?.createScriptURL(url) || url;\n}\nclass SafeValueImpl {\n changingThisBreaksApplicationSecurity;\n constructor(changingThisBreaksApplicationSecurity) {\n this.changingThisBreaksApplicationSecurity = changingThisBreaksApplicationSecurity;\n }\n toString() {\n return `SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity}` + ` (see ${XSS_SECURITY_URL})`;\n }\n}\nclass SafeHtmlImpl extends SafeValueImpl {\n getTypeName() {\n return \"HTML\" /* BypassType.Html */;\n }\n}\nclass SafeStyleImpl extends SafeValueImpl {\n getTypeName() {\n return \"Style\" /* BypassType.Style */;\n }\n}\nclass SafeScriptImpl extends SafeValueImpl {\n getTypeName() {\n return \"Script\" /* BypassType.Script */;\n }\n}\nclass SafeUrlImpl extends SafeValueImpl {\n getTypeName() {\n return \"URL\" /* BypassType.Url */;\n }\n}\nclass SafeResourceUrlImpl extends SafeValueImpl {\n getTypeName() {\n return \"ResourceURL\" /* BypassType.ResourceUrl */;\n }\n}\nfunction unwrapSafeValue(value) {\n return value instanceof SafeValueImpl ? value.changingThisBreaksApplicationSecurity : value;\n}\nfunction allowSanitizationBypassAndThrow(value, type) {\n const actualType = getSanitizationBypassType(value);\n if (actualType != null && actualType !== type) {\n // Allow ResourceURLs in URL contexts, they are strictly more trusted.\n if (actualType === \"ResourceURL\" /* BypassType.ResourceUrl */ && type === \"URL\" /* BypassType.Url */) return true;\n throw new Error(`Required a safe ${type}, got a ${actualType} (see ${XSS_SECURITY_URL})`);\n }\n return actualType === type;\n}\nfunction getSanitizationBypassType(value) {\n return value instanceof SafeValueImpl && value.getTypeName() || null;\n}\n/**\n * Mark `html` string as trusted.\n *\n * This function wraps the trusted string in `String` and brands it in a way which makes it\n * recognizable to {@link htmlSanitizer} to be trusted implicitly.\n *\n * @param trustedHtml `html` string which needs to be implicitly trusted.\n * @returns a `html` which has been branded to be implicitly trusted.\n */\nfunction bypassSanitizationTrustHtml(trustedHtml) {\n return new SafeHtmlImpl(trustedHtml);\n}\n/**\n * Mark `style` string as trusted.\n *\n * This function wraps the trusted string in `String` and brands it in a way which makes it\n * recognizable to {@link styleSanitizer} to be trusted implicitly.\n *\n * @param trustedStyle `style` string which needs to be implicitly trusted.\n * @returns a `style` hich has been branded to be implicitly trusted.\n */\nfunction bypassSanitizationTrustStyle(trustedStyle) {\n return new SafeStyleImpl(trustedStyle);\n}\n/**\n * Mark `script` string as trusted.\n *\n * This function wraps the trusted string in `String` and brands it in a way which makes it\n * recognizable to {@link scriptSanitizer} to be trusted implicitly.\n *\n * @param trustedScript `script` string which needs to be implicitly trusted.\n * @returns a `script` which has been branded to be implicitly trusted.\n */\nfunction bypassSanitizationTrustScript(trustedScript) {\n return new SafeScriptImpl(trustedScript);\n}\n/**\n * Mark `url` string as trusted.\n *\n * This function wraps the trusted string in `String` and brands it in a way which makes it\n * recognizable to {@link urlSanitizer} to be trusted implicitly.\n *\n * @param trustedUrl `url` string which needs to be implicitly trusted.\n * @returns a `url` which has been branded to be implicitly trusted.\n */\nfunction bypassSanitizationTrustUrl(trustedUrl) {\n return new SafeUrlImpl(trustedUrl);\n}\n/**\n * Mark `url` string as trusted.\n *\n * This function wraps the trusted string in `String` and brands it in a way which makes it\n * recognizable to {@link resourceUrlSanitizer} to be trusted implicitly.\n *\n * @param trustedResourceUrl `url` string which needs to be implicitly trusted.\n * @returns a `url` which has been branded to be implicitly trusted.\n */\nfunction bypassSanitizationTrustResourceUrl(trustedResourceUrl) {\n return new SafeResourceUrlImpl(trustedResourceUrl);\n}\n\n/**\n * This helper is used to get hold of an inert tree of DOM elements containing dirty HTML\n * that needs sanitizing.\n * Depending upon browser support we use one of two strategies for doing this.\n * Default: DOMParser strategy\n * Fallback: InertDocument strategy\n */\nfunction getInertBodyHelper(defaultDoc) {\n const inertDocumentHelper = new InertDocumentHelper(defaultDoc);\n return isDOMParserAvailable() ? new DOMParserHelper(inertDocumentHelper) : inertDocumentHelper;\n}\n/**\n * Uses DOMParser to create and fill an inert body element.\n * This is the default strategy used in browsers that support it.\n */\nclass DOMParserHelper {\n inertDocumentHelper;\n constructor(inertDocumentHelper) {\n this.inertDocumentHelper = inertDocumentHelper;\n }\n getInertBodyElement(html) {\n // We add these extra elements to ensure that the rest of the content is parsed as expected\n // e.g. leading whitespace is maintained and tags like `<meta>` do not get hoisted to the\n // `<head>` tag. Note that the `<body>` tag is closed implicitly to prevent unclosed tags\n // in `html` from consuming the otherwise explicit `</body>` tag.\n html = '<body><remove></remove>' + html;\n try {\n const body = new window.DOMParser().parseFromString(trustedHTMLFromString(html), 'text/html').body;\n if (body === null) {\n // In some browsers (e.g. Mozilla/5.0 iPad AppleWebKit Mobile) the `body` property only\n // becomes available in the following tick of the JS engine. In that case we fall back to\n // the `inertDocumentHelper` instead.\n return this.inertDocumentHelper.getInertBodyElement(html);\n }\n body.firstChild?.remove();\n return body;\n } catch {\n return null;\n }\n }\n}\n/**\n * Use an HTML5 `template` element to create and fill an inert DOM element.\n * This is the fallback strategy if the browser does not support DOMParser.\n */\nclass InertDocumentHelper {\n defaultDoc;\n inertDocument;\n constructor(defaultDoc) {\n this.defaultDoc = defaultDoc;\n this.inertDocument = this.defaultDoc.implementation.createHTMLDocument('sanitization-inert');\n }\n getInertBodyElement(html) {\n const templateEl = this.inertDocument.createElement('template');\n templateEl.innerHTML = trustedHTMLFromString(html);\n return templateEl;\n }\n}\n/**\n * We need to determine whether the DOMParser exists in the global context and\n * supports parsing HTML; HTML parsing support is not as wide as other formats, see\n * https://developer.mozilla.org/en-US/docs/Web/API/DOMParser#Browser_compatibility.\n *\n * @suppress {uselessCode}\n */\nfunction isDOMParserAvailable() {\n try {\n return !!new window.DOMParser().parseFromString(trustedHTMLFromString(''), 'text/html');\n } catch {\n return false;\n }\n}\n\n/**\n * A pattern that recognizes URLs that are safe wrt. XSS in URL navigation\n * contexts.\n *\n * This regular expression matches a subset of URLs that will not cause script\n * execution if used in URL context within a HTML document. Specifically, this\n * regular expression matches if:\n * (1) Either a protocol that is not javascript:, and that has valid characters\n * (alphanumeric or [+-.]).\n * (2) or no protocol. A protocol must be followed by a colon. The below\n * allows that by allowing colons only after one of the characters [/?#].\n * A colon after a hash (#) must be in the fragment.\n * Otherwise, a colon after a (?) must be in a query.\n * Otherwise, a colon after a single solidus (/) must be in a path.\n * Otherwise, a colon after a double solidus (//) must be in the authority\n * (before port).\n *\n * The pattern disallows &, used in HTML entity declarations before\n * one of the characters in [/?#]. This disallows HTML entities used in the\n * protocol name, which should never happen, e.g. \"http\" for \"http\".\n * It also disallows HTML entities in the first path part of a relative path,\n * e.g. \"foo<bar/baz\". Our existing escaping functions should not produce\n * that. More importantly, it disallows masking of a colon,\n * e.g. \"javascript:...\".\n *\n * This regular expression was taken from the Closure sanitization library.\n */\nconst SAFE_URL_PATTERN = /^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\\/?#]*(?:[\\/?#]|$))/i;\nfunction _sanitizeUrl(url) {\n url = String(url);\n if (url.match(SAFE_URL_PATTERN)) return url;\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n console.warn(`WARNING: sanitizing unsafe URL value ${url} (see ${XSS_SECURITY_URL})`);\n }\n return 'unsafe:' + url;\n}\nfunction tagSet(tags) {\n const res = {};\n for (const t of tags.split(',')) res[t] = true;\n return res;\n}\nfunction merge(...sets) {\n const res = {};\n for (const s of sets) {\n for (const v in s) {\n if (s.hasOwnProperty(v)) res[v] = true;\n }\n }\n return res;\n}\n// Good source of info about elements and attributes\n// https://html.spec.whatwg.org/#semantics\n// https://simon.html5.org/html-elements\n// Safe Void Elements - HTML5\n// https://html.spec.whatwg.org/#void-elements\nconst VOID_ELEMENTS = tagSet('area,br,col,hr,img,wbr');\n// Elements that you can, intentionally, leave open (and which close themselves)\n// https://html.spec.whatwg.org/#optional-tags\nconst OPTIONAL_END_TAG_BLOCK_ELEMENTS = tagSet('colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr');\nconst OPTIONAL_END_TAG_INLINE_ELEMENTS = tagSet('rp,rt');\nconst OPTIONAL_END_TAG_ELEMENTS = merge(OPTIONAL_END_TAG_INLINE_ELEMENTS, OPTIONAL_END_TAG_BLOCK_ELEMENTS);\n// Safe Block Elements - HTML5\nconst BLOCK_ELEMENTS = merge(OPTIONAL_END_TAG_BLOCK_ELEMENTS, tagSet('address,article,' + 'aside,blockquote,caption,center,del,details,dialog,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,' + 'h6,header,hgroup,hr,ins,main,map,menu,nav,ol,pre,section,summary,table,ul'));\n// Inline Elements - HTML5\nconst INLINE_ELEMENTS = merge(OPTIONAL_END_TAG_INLINE_ELEMENTS, tagSet('a,abbr,acronym,audio,b,' + 'bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,picture,q,ruby,rp,rt,s,' + 'samp,small,source,span,strike,strong,sub,sup,time,track,tt,u,var,video'));\nconst VALID_ELEMENTS = merge(VOID_ELEMENTS, BLOCK_ELEMENTS, INLINE_ELEMENTS, OPTIONAL_END_TAG_ELEMENTS);\n// Attributes that have href and hence need to be sanitized\nconst URI_ATTRS = tagSet('background,cite,href,itemtype,longdesc,poster,src,xlink:href');\nconst HTML_ATTRS = tagSet('abbr,accesskey,align,alt,autoplay,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,' + 'compact,controls,coords,datetime,default,dir,download,face,headers,height,hidden,hreflang,hspace,' + 'ismap,itemscope,itemprop,kind,label,lang,language,loop,media,muted,nohref,nowrap,open,preload,rel,rev,role,rows,rowspan,rules,' + 'scope,scrolling,shape,size,sizes,span,srclang,srcset,start,summary,tabindex,target,title,translate,type,usemap,' + 'valign,value,vspace,width');\n// Accessibility attributes as per WAI-ARIA 1.1 (W3C Working Draft 14 December 2018)\nconst ARIA_ATTRS = tagSet('aria-activedescendant,aria-atomic,aria-autocomplete,aria-busy,aria-checked,aria-colcount,aria-colindex,' + 'aria-colspan,aria-controls,aria-current,aria-describedby,aria-details,aria-disabled,aria-dropeffect,' + 'aria-errormessage,aria-expanded,aria-flowto,aria-grabbed,aria-haspopup,aria-hidden,aria-invalid,' + 'aria-keyshortcuts,aria-label,aria-labelledby,aria-level,aria-live,aria-modal,aria-multiline,' + 'aria-multiselectable,aria-orientation,aria-owns,aria-placeholder,aria-posinset,aria-pressed,aria-readonly,' + 'aria-relevant,aria-required,aria-roledescription,aria-rowcount,aria-rowindex,aria-rowspan,aria-selected,' + 'aria-setsize,aria-sort,aria-valuemax,aria-valuemin,aria-valuenow,aria-valuetext');\n// NB: This currently consciously doesn't support SVG. SVG sanitization has had several security\n// issues in the past, so it seems safer to leave it out if possible. If support for binding SVG via\n// innerHTML is required, SVG attributes should be added here.\n// NB: Sanitization does not allow <form> elements or other active elements (<button> etc). Those\n// can be sanitized, but they increase security surface area without a legitimate use case, so they\n// are left out here.\nconst VALID_ATTRS = merge(URI_ATTRS, HTML_ATTRS, ARIA_ATTRS);\n// Elements whose content should not be traversed/preserved, if the elements themselves are invalid.\n//\n// Typically, `<invalid>Some content</invalid>` would traverse (and in this case preserve)\n// `Some content`, but strip `invalid-element` opening/closing tags. For some elements, though, we\n// don't want to preserve the content, if the elements themselves are going to be removed.\nconst SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS = tagSet('script,style,template');\n/**\n * SanitizingHtmlSerializer serializes a DOM fragment, stripping out any unsafe elements and unsafe\n * attributes.\n */\nclass SanitizingHtmlSerializer {\n // Explicitly track if something was stripped, to avoid accidentally warning of sanitization just\n // because characters were re-encoded.\n sanitizedSomething = false;\n buf = [];\n sanitizeChildren(el) {\n // This cannot use a TreeWalker, as it has to run on Angular's various DOM adapters.\n // However this code never accesses properties off of `document` before deleting its contents\n // again, so it shouldn't be vulnerable to DOM clobbering.\n let current = el.firstChild;\n let traverseContent = true;\n let parentNodes = [];\n while (current) {\n if (current.nodeType === Node.ELEMENT_NODE) {\n traverseContent = this.startElement(current);\n } else if (current.nodeType === Node.TEXT_NODE) {\n this.chars(current.nodeValue);\n } else {\n // Strip non-element, non-text nodes.\n this.sanitizedSomething = true;\n }\n if (traverseContent && current.firstChild) {\n // Push current node to the parent stack before entering its content.\n parentNodes.push(current);\n current = getFirstChild(current);\n continue;\n }\n while (current) {\n // Leaving the element.\n // Walk up and to the right, closing tags as we go.\n if (current.nodeType === Node.ELEMENT_NODE) {\n this.endElement(current);\n }\n let next = getNextSibling(current);\n if (next) {\n current = next;\n break;\n }\n // There was no next sibling, walk up to the parent node (extract it from the stack).\n current = parentNodes.pop();\n }\n }\n return this.buf.join('');\n }\n /**\n * Sanitizes an opening element tag (if valid) and returns whether the element's contents should\n * be traversed. Element content must always be traversed (even if the element itself is not\n * valid/safe), unless the element is one of `SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS`.\n *\n * @param element The element to sanitize.\n * @return True if the element's contents should be traversed.\n */\n startElement(element) {\n const tagName = getNodeName(element).toLowerCase();\n if (!VALID_ELEMENTS.hasOwnProperty(tagName)) {\n this.sanitizedSomething = true;\n return !SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS.hasOwnProperty(tagName);\n }\n this.buf.push('<');\n this.buf.push(tagName);\n const elAttrs = element.attributes;\n for (let i = 0; i < elAttrs.length; i++) {\n const elAttr = elAttrs.item(i);\n const attrName = elAttr.name;\n const lower = attrName.toLowerCase();\n if (!VALID_ATTRS.hasOwnProperty(lower)) {\n this.sanitizedSomething = true;\n continue;\n }\n let value = elAttr.value;\n // TODO(martinprobst): Special case image URIs for data:image/...\n if (URI_ATTRS[lower]) value = _sanitizeUrl(value);\n this.buf.push(' ', attrName, '=\"', encodeEntities(value), '\"');\n }\n this.buf.push('>');\n return true;\n }\n endElement(current) {\n const tagName = getNodeName(current).toLowerCase();\n if (VALID_ELEMENTS.hasOwnProperty(tagName) && !VOID_ELEMENTS.hasOwnProperty(tagName)) {\n this.buf.push('</');\n this.buf.push(tagName);\n this.buf.push('>');\n }\n }\n chars(chars) {\n this.buf.push(encodeEntities(chars));\n }\n}\n/**\n * Verifies whether a given child node is a descendant of a given parent node.\n * It may not be the case when properties like `.firstChild` are clobbered and\n * accessing `.firstChild` results in an unexpected node returned.\n */\nfunction isClobberedElement(parentNode, childNode) {\n return (parentNode.compareDocumentPosition(childNode) & Node.DOCUMENT_POSITION_CONTAINED_BY) !== Node.DOCUMENT_POSITION_CONTAINED_BY;\n}\n/**\n * Retrieves next sibling node and makes sure that there is no\n * clobbering of the `nextSibling` property happening.\n */\nfunction getNextSibling(node) {\n const nextSibling = node.nextSibling;\n // Make sure there is no `nextSibling` clobbering: navigating to\n // the next sibling and going back to the previous one should result\n // in the original node.\n if (nextSibling && node !== nextSibling.previousSibling) {\n throw clobberedElementError(nextSibling);\n }\n return nextSibling;\n}\n/**\n * Retrieves first child node and makes sure that there is no\n * clobbering of the `firstChild` property happening.\n */\nfunction getFirstChild(node) {\n const firstChild = node.firstChild;\n if (firstChild && isClobberedElement(node, firstChild)) {\n throw clobberedElementError(firstChild);\n }\n return firstChild;\n}\n/** Gets a reasonable nodeName, even for clobbered nodes. */\nfunction getNodeName(node) {\n const nodeName = node.nodeName;\n // If the property is clobbered, assume it is an `HTMLFormElement`.\n return typeof nodeName === 'string' ? nodeName : 'FORM';\n}\nfunction clobberedElementError(node) {\n return new Error(`Failed to sanitize html because the element is clobbered: ${node.outerHTML}`);\n}\n// Regular Expressions for parsing tags and attributes\nconst SURROGATE_PAIR_REGEXP = /[\\uD800-\\uDBFF][\\uDC00-\\uDFFF]/g;\n// ! to ~ is the ASCII range.\nconst NON_ALPHANUMERIC_REGEXP = /([^\\#-~ |!])/g;\n/**\n * Escapes all potentially dangerous characters, so that the\n * resulting string can be safely inserted into attribute or\n * element text.\n * @param value\n */\nfunction encodeEntities(value) {\n return value.replace(/&/g, '&').replace(SURROGATE_PAIR_REGEXP, function (match) {\n const hi = match.charCodeAt(0);\n const low = match.charCodeAt(1);\n return '&#' + ((hi - 0xd800) * 0x400 + (low - 0xdc00) + 0x10000) + ';';\n }).replace(NON_ALPHANUMERIC_REGEXP, function (match) {\n return '&#' + match.charCodeAt(0) + ';';\n }).replace(/</g, '<').replace(/>/g, '>');\n}\nlet inertBodyHelper;\n/**\n * Sanitizes the given unsafe, untrusted HTML fragment, and returns HTML text that is safe to add to\n * the DOM in a browser environment.\n */\nfunction _sanitizeHtml(defaultDoc, unsafeHtmlInput) {\n let inertBodyElement = null;\n try {\n inertBodyHelper = inertBodyHelper || getInertBodyHelper(defaultDoc);\n // Make sure unsafeHtml is actually a string (TypeScript types are not enforced at runtime).\n let unsafeHtml = unsafeHtmlInput ? String(unsafeHtmlInput) : '';\n inertBodyElement = inertBodyHelper.getInertBodyElement(unsafeHtml);\n // mXSS protection. Repeatedly parse the document to make sure it stabilizes, so that a browser\n // trying to auto-correct incorrect HTML cannot cause formerly inert HTML to become dangerous.\n let mXSSAttempts = 5;\n let parsedHtml = unsafeHtml;\n do {\n if (mXSSAttempts === 0) {\n throw new Error('Failed to sanitize html because the input is unstable');\n }\n mXSSAttempts--;\n unsafeHtml = parsedHtml;\n parsedHtml = inertBodyElement.innerHTML;\n inertBodyElement = inertBodyHelper.getInertBodyElement(unsafeHtml);\n } while (unsafeHtml !== parsedHtml);\n const sanitizer = new SanitizingHtmlSerializer();\n const safeHtml = sanitizer.sanitizeChildren(getTemplateContent(inertBodyElement) || inertBodyElement);\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && sanitizer.sanitizedSomething) {\n console.warn(`WARNING: sanitizing HTML stripped some content, see ${XSS_SECURITY_URL}`);\n }\n return trustedHTMLFromString(safeHtml);\n } finally {\n // In case anything goes wrong, clear out inertElement to reset the entire DOM structure.\n if (inertBodyElement) {\n const parent = getTemplateContent(inertBodyElement) || inertBodyElement;\n while (parent.firstChild) {\n parent.firstChild.remove();\n }\n }\n }\n}\nfunction getTemplateContent(el) {\n return 'content' in el /** Microsoft/TypeScript#21517 */ && isTemplateElement(el) ? el.content : null;\n}\nfunction isTemplateElement(el) {\n return el.nodeType === Node.ELEMENT_NODE && el.nodeName === 'TEMPLATE';\n}\n\n/**\n * A SecurityContext marks a location that has dangerous security implications, e.g. a DOM property\n * like `innerHTML` that could cause Cross Site Scripting (XSS) security bugs when improperly\n * handled.\n *\n * See DomSanitizer for more details on security in Angular applications.\n *\n * @publicApi\n */\nvar SecurityContext;\n(function (SecurityContext) {\n SecurityContext[SecurityContext[\"NONE\"] = 0] = \"NONE\";\n SecurityContext[SecurityContext[\"HTML\"] = 1] = \"HTML\";\n SecurityContext[SecurityContext[\"STYLE\"] = 2] = \"STYLE\";\n SecurityContext[SecurityContext[\"SCRIPT\"] = 3] = \"SCRIPT\";\n SecurityContext[SecurityContext[\"URL\"] = 4] = \"URL\";\n SecurityContext[SecurityContext[\"RESOURCE_URL\"] = 5] = \"RESOURCE_URL\";\n})(SecurityContext || (SecurityContext = {}));\n\n/**\n * An `html` sanitizer which converts untrusted `html` **string** into trusted string by removing\n * dangerous content.\n *\n * This method parses the `html` and locates potentially dangerous content (such as urls and\n * javascript) and removes it.\n *\n * It is possible to mark a string as trusted by calling {@link bypassSanitizationTrustHtml}.\n *\n * @param unsafeHtml untrusted `html`, typically from the user.\n * @returns `html` string which is safe to display to user, because all of the dangerous javascript\n * and urls have been removed.\n *\n * @codeGenApi\n */\nfunction ɵɵsanitizeHtml(unsafeHtml) {\n const sanitizer = getSanitizer();\n if (sanitizer) {\n return trustedHTMLFromStringBypass(sanitizer.sanitize(SecurityContext.HTML, unsafeHtml) || '');\n }\n if (allowSanitizationBypassAndThrow(unsafeHtml, \"HTML\" /* BypassType.Html */)) {\n return trustedHTMLFromStringBypass(unwrapSafeValue(unsafeHtml));\n }\n return _sanitizeHtml(getDocument(), renderStringify(unsafeHtml));\n}\n/**\n * A `style` sanitizer which converts untrusted `style` **string** into trusted string by removing\n * dangerous content.\n *\n * It is possible to mark a string as trusted by calling {@link bypassSanitizationTrustStyle}.\n *\n * @param unsafeStyle untrusted `style`, typically from the user.\n * @returns `style` string which is safe to bind to the `style` properties.\n *\n * @codeGenApi\n */\nfunction ɵɵsanitizeStyle(unsafeStyle) {\n const sanitizer = getSanitizer();\n if (sanitizer) {\n return sanitizer.sanitize(SecurityContext.STYLE, unsafeStyle) || '';\n }\n if (allowSanitizationBypassAndThrow(unsafeStyle, \"Style\" /* BypassType.Style */)) {\n return unwrapSafeValue(unsafeStyle);\n }\n return renderStringify(unsafeStyle);\n}\n/**\n * A `url` sanitizer which converts untrusted `url` **string** into trusted string by removing\n * dangerous\n * content.\n *\n * This method parses the `url` and locates potentially dangerous content (such as javascript) and\n * removes it.\n *\n * It is possible to mark a string as trusted by calling {@link bypassSanitizationTrustUrl}.\n *\n * @param unsafeUrl untrusted `url`, typically from the user.\n * @returns `url` string which is safe to bind to the `src` properties such as `<img src>`, because\n * all of the dangerous javascript has been removed.\n *\n * @codeGenApi\n */\nfunction ɵɵsanitizeUrl(unsafeUrl) {\n const sanitizer = getSanitizer();\n if (sanitizer) {\n return sanitizer.sanitize(SecurityContext.URL, unsafeUrl) || '';\n }\n if (allowSanitizationBypassAndThrow(unsafeUrl, \"URL\" /* BypassType.Url */)) {\n return unwrapSafeValue(unsafeUrl);\n }\n return _sanitizeUrl(renderStringify(unsafeUrl));\n}\n/**\n * A `url` sanitizer which only lets trusted `url`s through.\n *\n * This passes only `url`s marked trusted by calling {@link bypassSanitizationTrustResourceUrl}.\n *\n * @param unsafeResourceUrl untrusted `url`, typically from the user.\n * @returns `url` string which is safe to bind to the `src` properties such as `<img src>`, because\n * only trusted `url`s have been allowed to pass.\n *\n * @codeGenApi\n */\nfunction ɵɵsanitizeResourceUrl(unsafeResourceUrl) {\n const sanitizer = getSanitizer();\n if (sanitizer) {\n return trustedScriptURLFromStringBypass(sanitizer.sanitize(SecurityContext.RESOURCE_URL, unsafeResourceUrl) || '');\n }\n if (allowSanitizationBypassAndThrow(unsafeResourceUrl, \"ResourceURL\" /* BypassType.ResourceUrl */)) {\n return trustedScriptURLFromStringBypass(unwrapSafeValue(unsafeResourceUrl));\n }\n throw new RuntimeError(904 /* RuntimeErrorCode.UNSAFE_VALUE_IN_RESOURCE_URL */, ngDevMode && `unsafe value used in a resource URL context (see ${XSS_SECURITY_URL})`);\n}\n/**\n * A `script` sanitizer which only lets trusted javascript through.\n *\n * This passes only `script`s marked trusted by calling {@link\n * bypassSanitizationTrustScript}.\n *\n * @param unsafeScript untrusted `script`, typically from the user.\n * @returns `url` string which is safe to bind to the `<script>` element such as `<img src>`,\n * because only trusted `scripts` have been allowed to pass.\n *\n * @codeGenApi\n */\nfunction ɵɵsanitizeScript(unsafeScript) {\n const sanitizer = getSanitizer();\n if (sanitizer) {\n return trustedScriptFromStringBypass(sanitizer.sanitize(SecurityContext.SCRIPT, unsafeScript) || '');\n }\n if (allowSanitizationBypassAndThrow(unsafeScript, \"Script\" /* BypassType.Script */)) {\n return trustedScriptFromStringBypass(unwrapSafeValue(unsafeScript));\n }\n throw new RuntimeError(905 /* RuntimeErrorCode.UNSAFE_VALUE_IN_SCRIPT */, ngDevMode && 'unsafe value used in a script context');\n}\n/**\n * A template tag function for promoting the associated constant literal to a\n * TrustedHTML. Interpolation is explicitly not allowed.\n *\n * @param html constant template literal containing trusted HTML.\n * @returns TrustedHTML wrapping `html`.\n *\n * @security This is a security-sensitive function and should only be used to\n * convert constant values of attributes and properties found in\n * application-provided Angular templates to TrustedHTML.\n *\n * @codeGenApi\n */\nfunction ɵɵtrustConstantHtml(html) {\n // The following runtime check ensures that the function was called as a\n // template tag (e.g. ɵɵtrustConstantHtml`content`), without any interpolation\n // (e.g. not ɵɵtrustConstantHtml`content ${variable}`). A TemplateStringsArray\n // is an array with a `raw` property that is also an array. The associated\n // template literal has no interpolation if and only if the length of the\n // TemplateStringsArray is 1.\n if (ngDevMode && (!Array.isArray(html) || !Array.isArray(html.raw) || html.length !== 1)) {\n throw new Error(`Unexpected interpolation in trusted HTML constant: ${html.join('?')}`);\n }\n return trustedHTMLFromString(html[0]);\n}\n/**\n * A template tag function for promoting the associated constant literal to a\n * TrustedScriptURL. Interpolation is explicitly not allowed.\n *\n * @param url constant template literal containing a trusted script URL.\n * @returns TrustedScriptURL wrapping `url`.\n *\n * @security This is a security-sensitive function and should only be used to\n * convert constant values of attributes and properties found in\n * application-provided Angular templates to TrustedScriptURL.\n *\n * @codeGenApi\n */\nfunction ɵɵtrustConstantResourceUrl(url) {\n // The following runtime check ensures that the function was called as a\n // template tag (e.g. ɵɵtrustConstantResourceUrl`content`), without any\n // interpolation (e.g. not ɵɵtrustConstantResourceUrl`content ${variable}`). A\n // TemplateStringsArray is an array with a `raw` property that is also an\n // array. The associated template literal has no interpolation if and only if\n // the length of the TemplateStringsArray is 1.\n if (ngDevMode && (!Array.isArray(url) || !Array.isArray(url.raw) || url.length !== 1)) {\n throw new Error(`Unexpected interpolation in trusted URL constant: ${url.join('?')}`);\n }\n return trustedScriptURLFromString(url[0]);\n}\n/**\n * Detects which sanitizer to use for URL property, based on tag name and prop name.\n *\n * The rules are based on the RESOURCE_URL context config from\n * `packages/compiler/src/schema/dom_security_schema.ts`.\n * If tag and prop names don't match Resource URL schema, use URL sanitizer.\n */\nfunction getUrlSanitizer(tag, prop) {\n if (prop === 'src' && (tag === 'embed' || tag === 'frame' || tag === 'iframe' || tag === 'media' || tag === 'script') || prop === 'href' && (tag === 'base' || tag === 'link')) {\n return ɵɵsanitizeResourceUrl;\n }\n return ɵɵsanitizeUrl;\n}\n/**\n * Sanitizes URL, selecting sanitizer function based on tag and property names.\n *\n * This function is used in case we can't define security context at compile time, when only prop\n * name is available. This happens when we generate host bindings for Directives/Components. The\n * host element is unknown at compile time, so we defer calculation of specific sanitizer to\n * runtime.\n *\n * @param unsafeUrl untrusted `url`, typically from the user.\n * @param tag target element tag name.\n * @param prop name of the property that contains the value.\n * @returns `url` string which is safe to bind.\n *\n * @codeGenApi\n */\nfunction ɵɵsanitizeUrlOrResourceUrl(unsafeUrl, tag, prop) {\n return getUrlSanitizer(tag, prop)(unsafeUrl);\n}\nfunction validateAgainstEventProperties(name) {\n if (name.toLowerCase().startsWith('on')) {\n const errorMessage = `Binding to event property '${name}' is disallowed for security reasons, ` + `please use (${name.slice(2)})=...` + `\\nIf '${name}' is a directive input, make sure the directive is imported by the` + ` current module.`;\n throw new RuntimeError(306 /* RuntimeErrorCode.INVALID_EVENT_BINDING */, errorMessage);\n }\n}\nfunction validateAgainstEventAttributes(name) {\n if (name.toLowerCase().startsWith('on')) {\n const errorMessage = `Binding to event attribute '${name}' is disallowed for security reasons, ` + `please use (${name.slice(2)})=...`;\n throw new RuntimeError(306 /* RuntimeErrorCode.INVALID_EVENT_BINDING */, errorMessage);\n }\n}\nfunction getSanitizer() {\n const lView = getLView();\n return lView && lView[ENVIRONMENT].sanitizer;\n}\n\n/**\n * Disallowed strings in the comment.\n *\n * see: https://html.spec.whatwg.org/multipage/syntax.html#comments\n */\nconst COMMENT_DISALLOWED = /^>|^->|<!--|-->|--!>|<!-$/g;\n/**\n * Delimiter in the disallowed strings which needs to be wrapped with zero with character.\n */\nconst COMMENT_DELIMITER = /(<|>)/g;\nconst COMMENT_DELIMITER_ESCAPED = '\\u200B$1\\u200B';\n/**\n * Escape the content of comment strings so that it can be safely inserted into a comment node.\n *\n * The issue is that HTML does not specify any way to escape comment end text inside the comment.\n * Consider: `<!-- The way you close a comment is with \">\", and \"->\" at the beginning or by \"-->\" or\n * \"--!>\" at the end. -->`. Above the `\"-->\"` is meant to be text not an end to the comment. This\n * can be created programmatically through DOM APIs. (`<!--` are also disallowed.)\n *\n * see: https://html.spec.whatwg.org/multipage/syntax.html#comments\n *\n * ```ts\n * div.innerHTML = div.innerHTML\n * ```\n *\n * One would expect that the above code would be safe to do, but it turns out that because comment\n * text is not escaped, the comment may contain text which will prematurely close the comment\n * opening up the application for XSS attack. (In SSR we programmatically create comment nodes which\n * may contain such text and expect them to be safe.)\n *\n * This function escapes the comment text by looking for comment delimiters (`<` and `>`) and\n * surrounding them with `_>_` where the `_` is a zero width space `\\u200B`. The result is that if a\n * comment contains any of the comment start/end delimiters (such as `<!--`, `-->` or `--!>`) the\n * text it will render normally but it will not cause the HTML parser to close/open the comment.\n *\n * @param value text to make safe for comment node by escaping the comment open/close character\n * sequence.\n */\nfunction escapeCommentText(value) {\n return value.replace(COMMENT_DISALLOWED, text => text.replace(COMMENT_DELIMITER, COMMENT_DELIMITER_ESCAPED));\n}\nfunction normalizeDebugBindingName(name) {\n // Attribute names with `$` (eg `x-y$`) are valid per spec, but unsupported by some browsers\n name = camelCaseToDashCase(name.replace(/[$@]/g, '_'));\n return `ng-reflect-${name}`;\n}\nconst CAMEL_CASE_REGEXP = /([A-Z])/g;\nfunction camelCaseToDashCase(input) {\n return input.replace(CAMEL_CASE_REGEXP, (...m) => '-' + m[1].toLowerCase());\n}\nfunction normalizeDebugBindingValue(value) {\n try {\n // Limit the size of the value as otherwise the DOM just gets polluted.\n return value != null ? value.toString().slice(0, 30) : value;\n } catch (e) {\n return '[ERROR] Exception while trying to serialize the value';\n }\n}\n\n/**\n * Defines a schema that allows an NgModule to contain the following:\n * - Non-Angular elements named with dash case (`-`).\n * - Element properties named with dash case (`-`).\n * Dash case is the naming convention for custom elements.\n *\n * @publicApi\n */\nconst CUSTOM_ELEMENTS_SCHEMA = {\n name: 'custom-elements'\n};\n/**\n * Defines a schema that allows any property on any element.\n *\n * This schema allows you to ignore the errors related to any unknown elements or properties in a\n * template. The usage of this schema is generally discouraged because it prevents useful validation\n * and may hide real errors in your template. Consider using the `CUSTOM_ELEMENTS_SCHEMA` instead.\n *\n * @publicApi\n */\nconst NO_ERRORS_SCHEMA = {\n name: 'no-errors-schema'\n};\nlet shouldThrowErrorOnUnknownElement = false;\n/**\n * Sets a strict mode for JIT-compiled components to throw an error on unknown elements,\n * instead of just logging the error.\n * (for AOT-compiled ones this check happens at build time).\n */\nfunction ɵsetUnknownElementStrictMode(shouldThrow) {\n shouldThrowErrorOnUnknownElement = shouldThrow;\n}\n/**\n * Gets the current value of the strict mode.\n */\nfunction ɵgetUnknownElementStrictMode() {\n return shouldThrowErrorOnUnknownElement;\n}\nlet shouldThrowErrorOnUnknownProperty = false;\n/**\n * Sets a strict mode for JIT-compiled components to throw an error on unknown properties,\n * instead of just logging the error.\n * (for AOT-compiled ones this check happens at build time).\n */\nfunction ɵsetUnknownPropertyStrictMode(shouldThrow) {\n shouldThrowErrorOnUnknownProperty = shouldThrow;\n}\n/**\n * Gets the current value of the strict mode.\n */\nfunction ɵgetUnknownPropertyStrictMode() {\n return shouldThrowErrorOnUnknownProperty;\n}\n/**\n * Validates that the element is known at runtime and produces\n * an error if it's not the case.\n * This check is relevant for JIT-compiled components (for AOT-compiled\n * ones this check happens at build time).\n *\n * The element is considered known if either:\n * - it's a known HTML element\n * - it's a known custom element\n * - the element matches any directive\n * - the element is allowed by one of the schemas\n *\n * @param element Element to validate\n * @param lView An `LView` that represents a current component that is being rendered\n * @param tagName Name of the tag to check\n * @param schemas Array of schemas\n * @param hasDirectives Boolean indicating that the element matches any directive\n */\nfunction validateElementIsKnown(element, lView, tagName, schemas, hasDirectives) {\n // If `schemas` is set to `null`, that's an indication that this Component was compiled in AOT\n // mode where this check happens at compile time. In JIT mode, `schemas` is always present and\n // defined as an array (as an empty array in case `schemas` field is not defined) and we should\n // execute the check below.\n if (schemas === null) return;\n // If the element matches any directive, it's considered as valid.\n if (!hasDirectives && tagName !== null) {\n // The element is unknown if it's an instance of HTMLUnknownElement, or it isn't registered\n // as a custom element. Note that unknown elements with a dash in their name won't be instances\n // of HTMLUnknownElement in browsers that support web components.\n const isUnknown =\n // Note that we can't check for `typeof HTMLUnknownElement === 'function'` because\n // Domino doesn't expose HTMLUnknownElement globally.\n typeof HTMLUnknownElement !== 'undefined' && HTMLUnknownElement && element instanceof HTMLUnknownElement || typeof customElements !== 'undefined' && tagName.indexOf('-') > -1 && !customElements.get(tagName);\n if (isUnknown && !matchingSchemas(schemas, tagName)) {\n const isHostStandalone = isHostComponentStandalone(lView);\n const templateLocation = getTemplateLocationDetails(lView);\n const schemas = `'${isHostStandalone ? '@Component' : '@NgModule'}.schemas'`;\n let message = `'${tagName}' is not a known element${templateLocation}:\\n`;\n message += `1. If '${tagName}' is an Angular component, then verify that it is ${isHostStandalone ? \"included in the '@Component.imports' of this component\" : 'a part of an @NgModule where this component is declared'}.\\n`;\n if (tagName && tagName.indexOf('-') > -1) {\n message += `2. If '${tagName}' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the ${schemas} of this component to suppress this message.`;\n } else {\n message += `2. To allow any element add 'NO_ERRORS_SCHEMA' to the ${schemas} of this component.`;\n }\n if (shouldThrowErrorOnUnknownElement) {\n throw new RuntimeError(304 /* RuntimeErrorCode.UNKNOWN_ELEMENT */, message);\n } else {\n console.error(formatRuntimeError(304 /* RuntimeErrorCode.UNKNOWN_ELEMENT */, message));\n }\n }\n }\n}\n/**\n * Validates that the property of the element is known at runtime and returns\n * false if it's not the case.\n * This check is relevant for JIT-compiled components (for AOT-compiled\n * ones this check happens at build time).\n *\n * The property is considered known if either:\n * - it's a known property of the element\n * - the element is allowed by one of the schemas\n * - the property is used for animations\n *\n * @param element Element to validate\n * @param propName Name of the property to check\n * @param tagName Name of the tag hosting the property\n * @param schemas Array of schemas\n */\nfunction isPropertyValid(element, propName, tagName, schemas) {\n // If `schemas` is set to `null`, that's an indication that this Component was compiled in AOT\n // mode where this check happens at compile time. In JIT mode, `schemas` is always present and\n // defined as an array (as an empty array in case `schemas` field is not defined) and we should\n // execute the check below.\n if (schemas === null) return true;\n // The property is considered valid if the element matches the schema, it exists on the element,\n // or it is synthetic.\n if (matchingSchemas(schemas, tagName) || propName in element || isAnimationProp(propName)) {\n return true;\n }\n // Note: `typeof Node` returns 'function' in most browsers, but is undefined with domino.\n return typeof Node === 'undefined' || Node === null || !(element instanceof Node);\n}\n/**\n * Logs or throws an error that a property is not supported on an element.\n *\n * @param propName Name of the invalid property\n * @param tagName Name of the tag hosting the property\n * @param nodeType Type of the node hosting the property\n * @param lView An `LView` that represents a current component\n */\nfunction handleUnknownPropertyError(propName, tagName, nodeType, lView) {\n // Special-case a situation when a structural directive is applied to\n // an `<ng-template>` element, for example: `<ng-template *ngIf=\"true\">`.\n // In this case the compiler generates the `ɵɵtemplate` instruction with\n // the `null` as the tagName. The directive matching logic at runtime relies\n // on this effect (see `isInlineTemplate`), thus using the 'ng-template' as\n // a default value of the `tNode.value` is not feasible at this moment.\n if (!tagName && nodeType === 4 /* TNodeType.Container */) {\n tagName = 'ng-template';\n }\n const isHostStandalone = isHostComponentStandalone(lView);\n const templateLocation = getTemplateLocationDetails(lView);\n let message = `Can't bind to '${propName}' since it isn't a known property of '${tagName}'${templateLocation}.`;\n const schemas = `'${isHostStandalone ? '@Component' : '@NgModule'}.schemas'`;\n const importLocation = isHostStandalone ? \"included in the '@Component.imports' of this component\" : 'a part of an @NgModule where this component is declared';\n if (KNOWN_CONTROL_FLOW_DIRECTIVES.has(propName)) {\n // Most likely this is a control flow directive (such as `*ngIf`) used in\n // a template, but the directive or the `CommonModule` is not imported.\n const correspondingImport = KNOWN_CONTROL_FLOW_DIRECTIVES.get(propName);\n message += `\\nIf the '${propName}' is an Angular control flow directive, ` + `please make sure that either the '${correspondingImport}' directive or the 'CommonModule' is ${importLocation}.`;\n } else {\n // May be an Angular component, which is not imported/declared?\n message += `\\n1. If '${tagName}' is an Angular component and it has the ` + `'${propName}' input, then verify that it is ${importLocation}.`;\n // May be a Web Component?\n if (tagName && tagName.indexOf('-') > -1) {\n message += `\\n2. If '${tagName}' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' ` + `to the ${schemas} of this component to suppress this message.`;\n message += `\\n3. To allow any property add 'NO_ERRORS_SCHEMA' to ` + `the ${schemas} of this component.`;\n } else {\n // If it's expected, the error can be suppressed by the `NO_ERRORS_SCHEMA` schema.\n message += `\\n2. To allow any property add 'NO_ERRORS_SCHEMA' to ` + `the ${schemas} of this component.`;\n }\n }\n reportUnknownPropertyError(message);\n}\nfunction reportUnknownPropertyError(message) {\n if (shouldThrowErrorOnUnknownProperty) {\n throw new RuntimeError(303 /* RuntimeErrorCode.UNKNOWN_BINDING */, message);\n } else {\n console.error(formatRuntimeError(303 /* RuntimeErrorCode.UNKNOWN_BINDING */, message));\n }\n}\n/**\n * WARNING: this is a **dev-mode only** function (thus should always be guarded by the `ngDevMode`)\n * and must **not** be used in production bundles. The function makes megamorphic reads, which might\n * be too slow for production mode and also it relies on the constructor function being available.\n *\n * Gets a reference to the host component def (where a current component is declared).\n *\n * @param lView An `LView` that represents a current component that is being rendered.\n */\nfunction getDeclarationComponentDef(lView) {\n !ngDevMode && throwError('Must never be called in production mode');\n const declarationLView = lView[DECLARATION_COMPONENT_VIEW];\n const context = declarationLView[CONTEXT];\n // Unable to obtain a context.\n if (!context) return null;\n return context.constructor ? getComponentDef(context.constructor) : null;\n}\n/**\n * WARNING: this is a **dev-mode only** function (thus should always be guarded by the `ngDevMode`)\n * and must **not** be used in production bundles. The function makes megamorphic reads, which might\n * be too slow for production mode.\n *\n * Checks if the current component is declared inside of a standalone component template.\n *\n * @param lView An `LView` that represents a current component that is being rendered.\n */\nfunction isHostComponentStandalone(lView) {\n !ngDevMode && throwError('Must never be called in production mode');\n const componentDef = getDeclarationComponentDef(lView);\n // Treat host component as non-standalone if we can't obtain the def.\n return !!componentDef?.standalone;\n}\n/**\n * WARNING: this is a **dev-mode only** function (thus should always be guarded by the `ngDevMode`)\n * and must **not** be used in production bundles. The function makes megamorphic reads, which might\n * be too slow for production mode.\n *\n * Constructs a string describing the location of the host component template. The function is used\n * in dev mode to produce error messages.\n *\n * @param lView An `LView` that represents a current component that is being rendered.\n */\nfunction getTemplateLocationDetails(lView) {\n !ngDevMode && throwError('Must never be called in production mode');\n const hostComponentDef = getDeclarationComponentDef(lView);\n const componentClassName = hostComponentDef?.type?.name;\n return componentClassName ? ` (used in the '${componentClassName}' component template)` : '';\n}\n/**\n * The set of known control flow directives and their corresponding imports.\n * We use this set to produce a more precises error message with a note\n * that the `CommonModule` should also be included.\n */\nconst KNOWN_CONTROL_FLOW_DIRECTIVES = new Map([['ngIf', 'NgIf'], ['ngFor', 'NgFor'], ['ngSwitchCase', 'NgSwitchCase'], ['ngSwitchDefault', 'NgSwitchDefault']]);\n/**\n * Returns true if the tag name is allowed by specified schemas.\n * @param schemas Array of schemas\n * @param tagName Name of the tag\n */\nfunction matchingSchemas(schemas, tagName) {\n if (schemas !== null) {\n for (let i = 0; i < schemas.length; i++) {\n const schema = schemas[i];\n if (schema === NO_ERRORS_SCHEMA || schema === CUSTOM_ELEMENTS_SCHEMA && tagName && tagName.indexOf('-') > -1) {\n return true;\n }\n }\n }\n return false;\n}\n\n/**\n *\n * @codeGenApi\n */\nfunction ɵɵresolveWindow(element) {\n return element.ownerDocument.defaultView;\n}\n/**\n *\n * @codeGenApi\n */\nfunction ɵɵresolveDocument(element) {\n return element.ownerDocument;\n}\n/**\n *\n * @codeGenApi\n */\nfunction ɵɵresolveBody(element) {\n return element.ownerDocument.body;\n}\n/**\n * The special delimiter we use to separate property names, prefixes, and suffixes\n * in property binding metadata. See storeBindingMetadata().\n *\n * We intentionally use the Unicode \"REPLACEMENT CHARACTER\" (U+FFFD) as a delimiter\n * because it is a very uncommon character that is unlikely to be part of a user's\n * property names or interpolation strings. If it is in fact used in a property\n * binding, DebugElement.properties will not return the correct value for that\n * binding. However, there should be no runtime effect for real applications.\n *\n * This character is typically rendered as a question mark inside of a diamond.\n * See https://en.wikipedia.org/wiki/Specials_(Unicode_block)\n *\n */\nconst INTERPOLATION_DELIMITER = `�`;\n/**\n * Unwrap a value which might be behind a closure (for forward declaration reasons).\n */\nfunction maybeUnwrapFn(value) {\n if (value instanceof Function) {\n return value();\n } else {\n return value;\n }\n}\n\n/**\n * The max length of the string representation of a value in an error message\n */\nconst VALUE_STRING_LENGTH_LIMIT = 200;\n/** Verifies that a given type is a Standalone Component. */\nfunction assertStandaloneComponentType(type) {\n assertComponentDef(type);\n const componentDef = getComponentDef(type);\n if (!componentDef.standalone) {\n throw new RuntimeError(907 /* RuntimeErrorCode.TYPE_IS_NOT_STANDALONE */, `The ${stringifyForError(type)} component is not marked as standalone, ` + `but Angular expects to have a standalone component here. ` + `Please make sure the ${stringifyForError(type)} component has ` + `the \\`standalone: true\\` flag in the decorator.`);\n }\n}\n/** Verifies whether a given type is a component */\nfunction assertComponentDef(type) {\n if (!getComponentDef(type)) {\n throw new RuntimeError(906 /* RuntimeErrorCode.MISSING_GENERATED_DEF */, `The ${stringifyForError(type)} is not an Angular component, ` + `make sure it has the \\`@Component\\` decorator.`);\n }\n}\n/** Called when there are multiple component selectors that match a given node */\nfunction throwMultipleComponentError(tNode, first, second) {\n throw new RuntimeError(-300 /* RuntimeErrorCode.MULTIPLE_COMPONENTS_MATCH */, `Multiple components match node with tagname ${tNode.value}: ` + `${stringifyForError(first)} and ` + `${stringifyForError(second)}`);\n}\n/** Throws an ExpressionChangedAfterChecked error if checkNoChanges mode is on. */\nfunction throwErrorIfNoChangesMode(creationMode, oldValue, currValue, propName, lView) {\n const hostComponentDef = getDeclarationComponentDef(lView);\n const componentClassName = hostComponentDef?.type?.name;\n const field = propName ? ` for '${propName}'` : '';\n let msg = `ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value${field}: '${formatValue(oldValue)}'. Current value: '${formatValue(currValue)}'.${componentClassName ? ` Expression location: ${componentClassName} component` : ''}`;\n if (creationMode) {\n msg += ` It seems like the view has been created after its parent and its children have been dirty checked.` + ` Has it been created in a change detection hook?`;\n }\n throw new RuntimeError(-100 /* RuntimeErrorCode.EXPRESSION_CHANGED_AFTER_CHECKED */, msg);\n}\nfunction formatValue(value) {\n let strValue = String(value);\n // JSON.stringify will throw on circular references\n try {\n if (Array.isArray(value) || strValue === '[object Object]') {\n strValue = JSON.stringify(value);\n }\n } catch (error) {}\n return strValue.length > VALUE_STRING_LENGTH_LIMIT ? strValue.substring(0, VALUE_STRING_LENGTH_LIMIT) + '…' : strValue;\n}\nfunction constructDetailsForInterpolation(lView, rootIndex, expressionIndex, meta, changedValue) {\n const [propName, prefix, ...chunks] = meta.split(INTERPOLATION_DELIMITER);\n let oldValue = prefix,\n newValue = prefix;\n for (let i = 0; i < chunks.length; i++) {\n const slotIdx = rootIndex + i;\n oldValue += `${lView[slotIdx]}${chunks[i]}`;\n newValue += `${slotIdx === expressionIndex ? changedValue : lView[slotIdx]}${chunks[i]}`;\n }\n return {\n propName,\n oldValue,\n newValue\n };\n}\n/**\n * Constructs an object that contains details for the ExpressionChangedAfterItHasBeenCheckedError:\n * - property name (for property bindings or interpolations)\n * - old and new values, enriched using information from metadata\n *\n * More information on the metadata storage format can be found in `storePropertyBindingMetadata`\n * function description.\n */\nfunction getExpressionChangedErrorDetails(lView, bindingIndex, oldValue, newValue) {\n const tData = lView[TVIEW].data;\n const metadata = tData[bindingIndex];\n if (typeof metadata === 'string') {\n // metadata for property interpolation\n if (metadata.indexOf(INTERPOLATION_DELIMITER) > -1) {\n return constructDetailsForInterpolation(lView, bindingIndex, bindingIndex, metadata, newValue);\n }\n // metadata for property binding\n return {\n propName: metadata,\n oldValue,\n newValue\n };\n }\n // metadata is not available for this expression, check if this expression is a part of the\n // property interpolation by going from the current binding index left and look for a string that\n // contains INTERPOLATION_DELIMITER, the layout in tView.data for this case will look like this:\n // [..., 'id�Prefix � and � suffix', null, null, null, ...]\n if (metadata === null) {\n let idx = bindingIndex - 1;\n while (typeof tData[idx] !== 'string' && tData[idx + 1] === null) {\n idx--;\n }\n const meta = tData[idx];\n if (typeof meta === 'string') {\n const matches = meta.match(new RegExp(INTERPOLATION_DELIMITER, 'g'));\n // first interpolation delimiter separates property name from interpolation parts (in case of\n // property interpolations), so we subtract one from total number of found delimiters\n if (matches && matches.length - 1 > bindingIndex - idx) {\n return constructDetailsForInterpolation(lView, idx, bindingIndex, meta, newValue);\n }\n }\n }\n return {\n propName: undefined,\n oldValue,\n newValue\n };\n}\n\n/**\n * Returns an index of `classToSearch` in `className` taking token boundaries into account.\n *\n * `classIndexOf('AB A', 'A', 0)` will be 3 (not 0 since `AB!==A`)\n *\n * @param className A string containing classes (whitespace separated)\n * @param classToSearch A class name to locate\n * @param startingIndex Starting location of search\n * @returns an index of the located class (or -1 if not found)\n */\nfunction classIndexOf(className, classToSearch, startingIndex) {\n ngDevMode && assertNotEqual(classToSearch, '', 'can not look for \"\" string.');\n let end = className.length;\n while (true) {\n const foundIndex = className.indexOf(classToSearch, startingIndex);\n if (foundIndex === -1) return foundIndex;\n if (foundIndex === 0 || className.charCodeAt(foundIndex - 1) <= 32 /* CharCode.SPACE */) {\n // Ensure that it has leading whitespace\n const length = classToSearch.length;\n if (foundIndex + length === end || className.charCodeAt(foundIndex + length) <= 32 /* CharCode.SPACE */) {\n // Ensure that it has trailing whitespace\n return foundIndex;\n }\n }\n // False positive, keep searching from where we left off.\n startingIndex = foundIndex + 1;\n }\n}\nconst NG_TEMPLATE_SELECTOR = 'ng-template';\n/**\n * Search the `TAttributes` to see if it contains `cssClassToMatch` (case insensitive)\n *\n * @param tNode static data of the node to match\n * @param attrs `TAttributes` to search through.\n * @param cssClassToMatch class to match (lowercase)\n * @param isProjectionMode Whether or not class matching should look into the attribute `class` in\n * addition to the `AttributeMarker.Classes`.\n */\nfunction isCssClassMatching(tNode, attrs, cssClassToMatch, isProjectionMode) {\n ngDevMode && assertEqual(cssClassToMatch, cssClassToMatch.toLowerCase(), 'Class name expected to be lowercase.');\n let i = 0;\n if (isProjectionMode) {\n for (; i < attrs.length && typeof attrs[i] === 'string'; i += 2) {\n // Search for an implicit `class` attribute and check if its value matches `cssClassToMatch`.\n if (attrs[i] === 'class' && classIndexOf(attrs[i + 1].toLowerCase(), cssClassToMatch, 0) !== -1) {\n return true;\n }\n }\n } else if (isInlineTemplate(tNode)) {\n // Matching directives (i.e. when not matching for projection mode) should not consider the\n // class bindings that are present on inline templates, as those class bindings only target\n // the root node of the template, not the template itself.\n return false;\n }\n // Resume the search for classes after the `Classes` marker.\n i = attrs.indexOf(1 /* AttributeMarker.Classes */, i);\n if (i > -1) {\n // We found the classes section. Start searching for the class.\n let item;\n while (++i < attrs.length && typeof (item = attrs[i]) === 'string') {\n if (item.toLowerCase() === cssClassToMatch) {\n return true;\n }\n }\n }\n return false;\n}\n/**\n * Checks whether the `tNode` represents an inline template (e.g. `*ngFor`).\n *\n * @param tNode current TNode\n */\nfunction isInlineTemplate(tNode) {\n return tNode.type === 4 /* TNodeType.Container */ && tNode.value !== NG_TEMPLATE_SELECTOR;\n}\n/**\n * Function that checks whether a given tNode matches tag-based selector and has a valid type.\n *\n * Matching can be performed in 2 modes: projection mode (when we project nodes) and regular\n * directive matching mode:\n * - in the \"directive matching\" mode we do _not_ take TContainer's tagName into account if it is\n * different from NG_TEMPLATE_SELECTOR (value different from NG_TEMPLATE_SELECTOR indicates that a\n * tag name was extracted from * syntax so we would match the same directive twice);\n * - in the \"projection\" mode, we use a tag name potentially extracted from the * syntax processing\n * (applicable to TNodeType.Container only).\n */\nfunction hasTagAndTypeMatch(tNode, currentSelector, isProjectionMode) {\n const tagNameToCompare = tNode.type === 4 /* TNodeType.Container */ && !isProjectionMode ? NG_TEMPLATE_SELECTOR : tNode.value;\n return currentSelector === tagNameToCompare;\n}\n/**\n * A utility function to match an Ivy node static data against a simple CSS selector\n *\n * @param tNode static data of the node to match\n * @param selector The selector to try matching against the node.\n * @param isProjectionMode if `true` we are matching for content projection, otherwise we are doing\n * directive matching.\n * @returns true if node matches the selector.\n */\nfunction isNodeMatchingSelector(tNode, selector, isProjectionMode) {\n ngDevMode && assertDefined(selector[0], 'Selector should have a tag name');\n let mode = 4 /* SelectorFlags.ELEMENT */;\n const nodeAttrs = tNode.attrs;\n // Find the index of first attribute that has no value, only a name.\n const nameOnlyMarkerIdx = nodeAttrs !== null ? getNameOnlyMarkerIndex(nodeAttrs) : 0;\n // When processing \":not\" selectors, we skip to the next \":not\" if the\n // current one doesn't match\n let skipToNextSelector = false;\n for (let i = 0; i < selector.length; i++) {\n const current = selector[i];\n if (typeof current === 'number') {\n // If we finish processing a :not selector and it hasn't failed, return false\n if (!skipToNextSelector && !isPositive(mode) && !isPositive(current)) {\n return false;\n }\n // If we are skipping to the next :not() and this mode flag is positive,\n // it's a part of the current :not() selector, and we should keep skipping\n if (skipToNextSelector && isPositive(current)) continue;\n skipToNextSelector = false;\n mode = current | mode & 1 /* SelectorFlags.NOT */;\n continue;\n }\n if (skipToNextSelector) continue;\n if (mode & 4 /* SelectorFlags.ELEMENT */) {\n mode = 2 /* SelectorFlags.ATTRIBUTE */ | mode & 1 /* SelectorFlags.NOT */;\n if (current !== '' && !hasTagAndTypeMatch(tNode, current, isProjectionMode) || current === '' && selector.length === 1) {\n if (isPositive(mode)) return false;\n skipToNextSelector = true;\n }\n } else if (mode & 8 /* SelectorFlags.CLASS */) {\n if (nodeAttrs === null || !isCssClassMatching(tNode, nodeAttrs, current, isProjectionMode)) {\n if (isPositive(mode)) return false;\n skipToNextSelector = true;\n }\n } else {\n const selectorAttrValue = selector[++i];\n const attrIndexInNode = findAttrIndexInNode(current, nodeAttrs, isInlineTemplate(tNode), isProjectionMode);\n if (attrIndexInNode === -1) {\n if (isPositive(mode)) return false;\n skipToNextSelector = true;\n continue;\n }\n if (selectorAttrValue !== '') {\n let nodeAttrValue;\n if (attrIndexInNode > nameOnlyMarkerIdx) {\n nodeAttrValue = '';\n } else {\n ngDevMode && assertNotEqual(nodeAttrs[attrIndexInNode], 0 /* AttributeMarker.NamespaceURI */, 'We do not match directives on namespaced attributes');\n // we lowercase the attribute value to be able to match\n // selectors without case-sensitivity\n // (selectors are already in lowercase when generated)\n nodeAttrValue = nodeAttrs[attrIndexInNode + 1].toLowerCase();\n }\n if (mode & 2 /* SelectorFlags.ATTRIBUTE */ && selectorAttrValue !== nodeAttrValue) {\n if (isPositive(mode)) return false;\n skipToNextSelector = true;\n }\n }\n }\n }\n return isPositive(mode) || skipToNextSelector;\n}\nfunction isPositive(mode) {\n return (mode & 1 /* SelectorFlags.NOT */) === 0;\n}\n/**\n * Examines the attribute's definition array for a node to find the index of the\n * attribute that matches the given `name`.\n *\n * NOTE: This will not match namespaced attributes.\n *\n * Attribute matching depends upon `isInlineTemplate` and `isProjectionMode`.\n * The following table summarizes which types of attributes we attempt to match:\n *\n * ===========================================================================================================\n * Modes | Normal Attributes | Bindings Attributes | Template Attributes | I18n\n * Attributes\n * ===========================================================================================================\n * Inline + Projection | YES | YES | NO | YES\n * -----------------------------------------------------------------------------------------------------------\n * Inline + Directive | NO | NO | YES | NO\n * -----------------------------------------------------------------------------------------------------------\n * Non-inline + Projection | YES | YES | NO | YES\n * -----------------------------------------------------------------------------------------------------------\n * Non-inline + Directive | YES | YES | NO | YES\n * ===========================================================================================================\n *\n * @param name the name of the attribute to find\n * @param attrs the attribute array to examine\n * @param isInlineTemplate true if the node being matched is an inline template (e.g. `*ngFor`)\n * rather than a manually expanded template node (e.g `<ng-template>`).\n * @param isProjectionMode true if we are matching against content projection otherwise we are\n * matching against directives.\n */\nfunction findAttrIndexInNode(name, attrs, isInlineTemplate, isProjectionMode) {\n if (attrs === null) return -1;\n let i = 0;\n if (isProjectionMode || !isInlineTemplate) {\n let bindingsMode = false;\n while (i < attrs.length) {\n const maybeAttrName = attrs[i];\n if (maybeAttrName === name) {\n return i;\n } else if (maybeAttrName === 3 /* AttributeMarker.Bindings */ || maybeAttrName === 6 /* AttributeMarker.I18n */) {\n bindingsMode = true;\n } else if (maybeAttrName === 1 /* AttributeMarker.Classes */ || maybeAttrName === 2 /* AttributeMarker.Styles */) {\n let value = attrs[++i];\n // We should skip classes here because we have a separate mechanism for\n // matching classes in projection mode.\n while (typeof value === 'string') {\n value = attrs[++i];\n }\n continue;\n } else if (maybeAttrName === 4 /* AttributeMarker.Template */) {\n // We do not care about Template attributes in this scenario.\n break;\n } else if (maybeAttrName === 0 /* AttributeMarker.NamespaceURI */) {\n // Skip the whole namespaced attribute and value. This is by design.\n i += 4;\n continue;\n }\n // In binding mode there are only names, rather than name-value pairs.\n i += bindingsMode ? 1 : 2;\n }\n // We did not match the attribute\n return -1;\n } else {\n return matchTemplateAttribute(attrs, name);\n }\n}\nfunction isNodeMatchingSelectorList(tNode, selector, isProjectionMode = false) {\n for (let i = 0; i < selector.length; i++) {\n if (isNodeMatchingSelector(tNode, selector[i], isProjectionMode)) {\n return true;\n }\n }\n return false;\n}\nfunction getProjectAsAttrValue(tNode) {\n const nodeAttrs = tNode.attrs;\n if (nodeAttrs != null) {\n const ngProjectAsAttrIdx = nodeAttrs.indexOf(5 /* AttributeMarker.ProjectAs */);\n // only check for ngProjectAs in attribute names, don't accidentally match attribute's value\n // (attribute names are stored at even indexes)\n if ((ngProjectAsAttrIdx & 1) === 0) {\n return nodeAttrs[ngProjectAsAttrIdx + 1];\n }\n }\n return null;\n}\nfunction getNameOnlyMarkerIndex(nodeAttrs) {\n for (let i = 0; i < nodeAttrs.length; i++) {\n const nodeAttr = nodeAttrs[i];\n if (isNameOnlyAttributeMarker(nodeAttr)) {\n return i;\n }\n }\n return nodeAttrs.length;\n}\nfunction matchTemplateAttribute(attrs, name) {\n let i = attrs.indexOf(4 /* AttributeMarker.Template */);\n if (i > -1) {\n i++;\n while (i < attrs.length) {\n const attr = attrs[i];\n // Return in case we checked all template attrs and are switching to the next section in the\n // attrs array (that starts with a number that represents an attribute marker).\n if (typeof attr === 'number') return -1;\n if (attr === name) return i;\n i++;\n }\n }\n return -1;\n}\n/**\n * Checks whether a selector is inside a CssSelectorList\n * @param selector Selector to be checked.\n * @param list List in which to look for the selector.\n */\nfunction isSelectorInSelectorList(selector, list) {\n selectorListLoop: for (let i = 0; i < list.length; i++) {\n const currentSelectorInList = list[i];\n if (selector.length !== currentSelectorInList.length) {\n continue;\n }\n for (let j = 0; j < selector.length; j++) {\n if (selector[j] !== currentSelectorInList[j]) {\n continue selectorListLoop;\n }\n }\n return true;\n }\n return false;\n}\nfunction maybeWrapInNotSelector(isNegativeMode, chunk) {\n return isNegativeMode ? ':not(' + chunk.trim() + ')' : chunk;\n}\nfunction stringifyCSSSelector(selector) {\n let result = selector[0];\n let i = 1;\n let mode = 2 /* SelectorFlags.ATTRIBUTE */;\n let currentChunk = '';\n let isNegativeMode = false;\n while (i < selector.length) {\n let valueOrMarker = selector[i];\n if (typeof valueOrMarker === 'string') {\n if (mode & 2 /* SelectorFlags.ATTRIBUTE */) {\n const attrValue = selector[++i];\n currentChunk += '[' + valueOrMarker + (attrValue.length > 0 ? '=\"' + attrValue + '\"' : '') + ']';\n } else if (mode & 8 /* SelectorFlags.CLASS */) {\n currentChunk += '.' + valueOrMarker;\n } else if (mode & 4 /* SelectorFlags.ELEMENT */) {\n currentChunk += ' ' + valueOrMarker;\n }\n } else {\n //\n // Append current chunk to the final result in case we come across SelectorFlag, which\n // indicates that the previous section of a selector is over. We need to accumulate content\n // between flags to make sure we wrap the chunk later in :not() selector if needed, e.g.\n // ```\n // ['', Flags.CLASS, '.classA', Flags.CLASS | Flags.NOT, '.classB', '.classC']\n // ```\n // should be transformed to `.classA :not(.classB .classC)`.\n //\n // Note: for negative selector part, we accumulate content between flags until we find the\n // next negative flag. This is needed to support a case where `:not()` rule contains more than\n // one chunk, e.g. the following selector:\n // ```\n // ['', Flags.ELEMENT | Flags.NOT, 'p', Flags.CLASS, 'foo', Flags.CLASS | Flags.NOT, 'bar']\n // ```\n // should be stringified to `:not(p.foo) :not(.bar)`\n //\n if (currentChunk !== '' && !isPositive(valueOrMarker)) {\n result += maybeWrapInNotSelector(isNegativeMode, currentChunk);\n currentChunk = '';\n }\n mode = valueOrMarker;\n // According to CssSelector spec, once we come across `SelectorFlags.NOT` flag, the negative\n // mode is maintained for remaining chunks of a selector.\n isNegativeMode = isNegativeMode || !isPositive(mode);\n }\n i++;\n }\n if (currentChunk !== '') {\n result += maybeWrapInNotSelector(isNegativeMode, currentChunk);\n }\n return result;\n}\n/**\n * Generates string representation of CSS selector in parsed form.\n *\n * ComponentDef and DirectiveDef are generated with the selector in parsed form to avoid doing\n * additional parsing at runtime (for example, for directive matching). However in some cases (for\n * example, while bootstrapping a component), a string version of the selector is required to query\n * for the host element on the page. This function takes the parsed form of a selector and returns\n * its string representation.\n *\n * @param selectorList selector in parsed form\n * @returns string representation of a given selector\n */\nfunction stringifyCSSSelectorList(selectorList) {\n return selectorList.map(stringifyCSSSelector).join(',');\n}\n/**\n * Extracts attributes and classes information from a given CSS selector.\n *\n * This function is used while creating a component dynamically. In this case, the host element\n * (that is created dynamically) should contain attributes and classes specified in component's CSS\n * selector.\n *\n * @param selector CSS selector in parsed form (in a form of array)\n * @returns object with `attrs` and `classes` fields that contain extracted information\n */\nfunction extractAttrsAndClassesFromSelector(selector) {\n const attrs = [];\n const classes = [];\n let i = 1;\n let mode = 2 /* SelectorFlags.ATTRIBUTE */;\n while (i < selector.length) {\n let valueOrMarker = selector[i];\n if (typeof valueOrMarker === 'string') {\n if (mode === 2 /* SelectorFlags.ATTRIBUTE */) {\n if (valueOrMarker !== '') {\n attrs.push(valueOrMarker, selector[++i]);\n }\n } else if (mode === 8 /* SelectorFlags.CLASS */) {\n classes.push(valueOrMarker);\n }\n } else {\n // According to CssSelector spec, once we come across `SelectorFlags.NOT` flag, the negative\n // mode is maintained for remaining chunks of a selector. Since attributes and classes are\n // extracted only for \"positive\" part of the selector, we can stop here.\n if (!isPositive(mode)) break;\n mode = valueOrMarker;\n }\n i++;\n }\n if (classes.length) {\n attrs.push(1 /* AttributeMarker.Classes */, ...classes);\n }\n return attrs;\n}\n\n/** A special value which designates that a value has not changed. */\nconst NO_CHANGE = typeof ngDevMode === 'undefined' || ngDevMode ? {\n __brand__: 'NO_CHANGE'\n} : {};\nfunction createTextNode(renderer, value) {\n ngDevMode && ngDevMode.rendererCreateTextNode++;\n ngDevMode && ngDevMode.rendererSetText++;\n return renderer.createText(value);\n}\nfunction updateTextNode(renderer, rNode, value) {\n ngDevMode && ngDevMode.rendererSetText++;\n renderer.setValue(rNode, value);\n}\nfunction createCommentNode(renderer, value) {\n ngDevMode && ngDevMode.rendererCreateComment++;\n return renderer.createComment(escapeCommentText(value));\n}\n/**\n * Creates a native element from a tag name, using a renderer.\n * @param renderer A renderer to use\n * @param name the tag name\n * @param namespace Optional namespace for element.\n * @returns the element created\n */\nfunction createElementNode(renderer, name, namespace) {\n ngDevMode && ngDevMode.rendererCreateElement++;\n return renderer.createElement(name, namespace);\n}\n/**\n * Inserts a native node before another native node for a given parent.\n * This is a utility function that can be used when native nodes were determined.\n */\nfunction nativeInsertBefore(renderer, parent, child, beforeNode, isMove) {\n ngDevMode && ngDevMode.rendererInsertBefore++;\n renderer.insertBefore(parent, child, beforeNode, isMove);\n}\nfunction nativeAppendChild(renderer, parent, child) {\n ngDevMode && ngDevMode.rendererAppendChild++;\n ngDevMode && assertDefined(parent, 'parent node must be defined');\n renderer.appendChild(parent, child);\n}\nfunction nativeAppendOrInsertBefore(renderer, parent, child, beforeNode, isMove) {\n if (beforeNode !== null) {\n nativeInsertBefore(renderer, parent, child, beforeNode, isMove);\n } else {\n nativeAppendChild(renderer, parent, child);\n }\n}\n/**\n * Removes a native node itself using a given renderer. To remove the node we are looking up its\n * parent from the native tree as not all platforms / browsers support the equivalent of\n * node.remove().\n *\n * @param renderer A renderer to be used\n * @param rNode The native node that should be removed\n * @param isHostElement A flag indicating if a node to be removed is a host of a component.\n */\nfunction nativeRemoveNode(renderer, rNode, isHostElement) {\n ngDevMode && ngDevMode.rendererRemoveNode++;\n renderer.removeChild(null, rNode, isHostElement);\n}\n/**\n * Clears the contents of a given RElement.\n *\n * @param rElement the native RElement to be cleared\n */\nfunction clearElementContents(rElement) {\n rElement.textContent = '';\n}\n/**\n * Write `cssText` to `RElement`.\n *\n * This function does direct write without any reconciliation. Used for writing initial values, so\n * that static styling values do not pull in the style parser.\n *\n * @param renderer Renderer to use\n * @param element The element which needs to be updated.\n * @param newValue The new class list to write.\n */\nfunction writeDirectStyle(renderer, element, newValue) {\n ngDevMode && assertString(newValue, \"'newValue' should be a string\");\n renderer.setAttribute(element, 'style', newValue);\n ngDevMode && ngDevMode.rendererSetStyle++;\n}\n/**\n * Write `className` to `RElement`.\n *\n * This function does direct write without any reconciliation. Used for writing initial values, so\n * that static styling values do not pull in the style parser.\n *\n * @param renderer Renderer to use\n * @param element The element which needs to be updated.\n * @param newValue The new class list to write.\n */\nfunction writeDirectClass(renderer, element, newValue) {\n ngDevMode && assertString(newValue, \"'newValue' should be a string\");\n if (newValue === '') {\n // There are tests in `google3` which expect `element.getAttribute('class')` to be `null`.\n renderer.removeAttribute(element, 'class');\n } else {\n renderer.setAttribute(element, 'class', newValue);\n }\n ngDevMode && ngDevMode.rendererSetClassName++;\n}\n/** Sets up the static DOM attributes on an `RNode`. */\nfunction setupStaticAttributes(renderer, element, tNode) {\n const {\n mergedAttrs,\n classes,\n styles\n } = tNode;\n if (mergedAttrs !== null) {\n setUpAttributes(renderer, element, mergedAttrs);\n }\n if (classes !== null) {\n writeDirectClass(renderer, element, classes);\n }\n if (styles !== null) {\n writeDirectStyle(renderer, element, styles);\n }\n}\n\n/**\n * Creates a TView instance\n *\n * @param type Type of `TView`.\n * @param declTNode Declaration location of this `TView`.\n * @param templateFn Template function\n * @param decls The number of nodes, local refs, and pipes in this template\n * @param directives Registry of directives for this view\n * @param pipes Registry of pipes for this view\n * @param viewQuery View queries for this view\n * @param schemas Schemas for this view\n * @param consts Constants for this view\n */\nfunction createTView(type, declTNode, templateFn, decls, vars, directives, pipes, viewQuery, schemas, constsOrFactory, ssrId) {\n ngDevMode && ngDevMode.tView++;\n const bindingStartIndex = HEADER_OFFSET + decls;\n // This length does not yet contain host bindings from child directives because at this point,\n // we don't know which directives are active on this template. As soon as a directive is matched\n // that has a host binding, we will update the blueprint with that def's hostVars count.\n const initialViewLength = bindingStartIndex + vars;\n const blueprint = createViewBlueprint(bindingStartIndex, initialViewLength);\n const consts = typeof constsOrFactory === 'function' ? constsOrFactory() : constsOrFactory;\n const tView = blueprint[TVIEW] = {\n type: type,\n blueprint: blueprint,\n template: templateFn,\n queries: null,\n viewQuery: viewQuery,\n declTNode: declTNode,\n data: blueprint.slice().fill(null, bindingStartIndex),\n bindingStartIndex: bindingStartIndex,\n expandoStartIndex: initialViewLength,\n hostBindingOpCodes: null,\n firstCreatePass: true,\n firstUpdatePass: true,\n staticViewQueries: false,\n staticContentQueries: false,\n preOrderHooks: null,\n preOrderCheckHooks: null,\n contentHooks: null,\n contentCheckHooks: null,\n viewHooks: null,\n viewCheckHooks: null,\n destroyHooks: null,\n cleanup: null,\n contentQueries: null,\n components: null,\n directiveRegistry: typeof directives === 'function' ? directives() : directives,\n pipeRegistry: typeof pipes === 'function' ? pipes() : pipes,\n firstChild: null,\n schemas: schemas,\n consts: consts,\n incompleteFirstPass: false,\n ssrId\n };\n if (ngDevMode) {\n // For performance reasons it is important that the tView retains the same shape during runtime.\n // (To make sure that all of the code is monomorphic.) For this reason we seal the object to\n // prevent class transitions.\n Object.seal(tView);\n }\n return tView;\n}\nfunction createViewBlueprint(bindingStartIndex, initialViewLength) {\n const blueprint = [];\n for (let i = 0; i < initialViewLength; i++) {\n blueprint.push(i < bindingStartIndex ? null : NO_CHANGE);\n }\n return blueprint;\n}\n/**\n * Gets TView from a template function or creates a new TView\n * if it doesn't already exist.\n *\n * @param def ComponentDef\n * @returns TView\n */\nfunction getOrCreateComponentTView(def) {\n const tView = def.tView;\n // Create a TView if there isn't one, or recreate it if the first create pass didn't\n // complete successfully since we can't know for sure whether it's in a usable shape.\n if (tView === null || tView.incompleteFirstPass) {\n // Declaration node here is null since this function is called when we dynamically create a\n // component and hence there is no declaration.\n const declTNode = null;\n return def.tView = createTView(1 /* TViewType.Component */, declTNode, def.template, def.decls, def.vars, def.directiveDefs, def.pipeDefs, def.viewQuery, def.schemas, def.consts, def.id);\n }\n return tView;\n}\nfunction createLView(parentLView, tView, context, flags, host, tHostNode, environment, renderer, injector, embeddedViewInjector, hydrationInfo) {\n const lView = tView.blueprint.slice();\n lView[HOST] = host;\n lView[FLAGS] = flags | 4 /* LViewFlags.CreationMode */ | 128 /* LViewFlags.Attached */ | 8 /* LViewFlags.FirstLViewPass */ | 64 /* LViewFlags.Dirty */ | 1024 /* LViewFlags.RefreshView */;\n if (embeddedViewInjector !== null || parentLView && parentLView[FLAGS] & 2048 /* LViewFlags.HasEmbeddedViewInjector */) {\n lView[FLAGS] |= 2048 /* LViewFlags.HasEmbeddedViewInjector */;\n }\n resetPreOrderHookFlags(lView);\n ngDevMode && tView.declTNode && parentLView && assertTNodeForLView(tView.declTNode, parentLView);\n lView[PARENT] = lView[DECLARATION_VIEW] = parentLView;\n lView[CONTEXT] = context;\n lView[ENVIRONMENT] = environment || parentLView && parentLView[ENVIRONMENT];\n ngDevMode && assertDefined(lView[ENVIRONMENT], 'LViewEnvironment is required');\n lView[RENDERER] = renderer || parentLView && parentLView[RENDERER];\n ngDevMode && assertDefined(lView[RENDERER], 'Renderer is required');\n lView[INJECTOR] = injector || parentLView && parentLView[INJECTOR] || null;\n lView[T_HOST] = tHostNode;\n lView[ID] = getUniqueLViewId();\n lView[HYDRATION] = hydrationInfo;\n lView[EMBEDDED_VIEW_INJECTOR] = embeddedViewInjector;\n ngDevMode && assertEqual(tView.type == 2 /* TViewType.Embedded */ ? parentLView !== null : true, true, 'Embedded views must have parentLView');\n lView[DECLARATION_COMPONENT_VIEW] = tView.type == 2 /* TViewType.Embedded */ ? parentLView[DECLARATION_COMPONENT_VIEW] : lView;\n return lView;\n}\nfunction createComponentLView(lView, hostTNode, def) {\n const native = getNativeByTNode(hostTNode, lView);\n const tView = getOrCreateComponentTView(def);\n // Only component views should be added to the view tree directly. Embedded views are\n // accessed through their containers because they may be removed / re-added later.\n const rendererFactory = lView[ENVIRONMENT].rendererFactory;\n const componentView = addToEndOfViewTree(lView, createLView(lView, tView, null, getInitialLViewFlagsFromDef(def), native, hostTNode, null, rendererFactory.createRenderer(native, def), null, null, null));\n // Component view will always be created before any injected LContainers,\n // so this is a regular element, wrap it with the component view\n return lView[hostTNode.index] = componentView;\n}\n/**\n * Gets the initial set of LView flags based on the component definition that the LView represents.\n * @param def Component definition from which to determine the flags.\n */\nfunction getInitialLViewFlagsFromDef(def) {\n let flags = 16 /* LViewFlags.CheckAlways */;\n if (def.signals) {\n flags = 4096 /* LViewFlags.SignalView */;\n } else if (def.onPush) {\n flags = 64 /* LViewFlags.Dirty */;\n }\n return flags;\n}\n/**\n * When elements are created dynamically after a view blueprint is created (e.g. through\n * i18nApply()), we need to adjust the blueprint for future template passes.\n *\n * @param tView `TView` associated with `LView`\n * @param lView The `LView` containing the blueprint to adjust\n * @param numSlotsToAlloc The number of slots to alloc in the LView, should be >0\n * @param initialValue Initial value to store in blueprint\n */\nfunction allocExpando(tView, lView, numSlotsToAlloc, initialValue) {\n if (numSlotsToAlloc === 0) return -1;\n if (ngDevMode) {\n assertFirstCreatePass(tView);\n assertSame(tView, lView[TVIEW], '`LView` must be associated with `TView`!');\n assertEqual(tView.data.length, lView.length, 'Expecting LView to be same size as TView');\n assertEqual(tView.data.length, tView.blueprint.length, 'Expecting Blueprint to be same size as TView');\n assertFirstUpdatePass(tView);\n }\n const allocIdx = lView.length;\n for (let i = 0; i < numSlotsToAlloc; i++) {\n lView.push(initialValue);\n tView.blueprint.push(initialValue);\n tView.data.push(null);\n }\n return allocIdx;\n}\n/**\n * Adds LView or LContainer to the end of the current view tree.\n *\n * This structure will be used to traverse through nested views to remove listeners\n * and call onDestroy callbacks.\n *\n * @param lView The view where LView or LContainer should be added\n * @param adjustedHostIndex Index of the view's host node in LView[], adjusted for header\n * @param lViewOrLContainer The LView or LContainer to add to the view tree\n * @returns The state passed in\n */\nfunction addToEndOfViewTree(lView, lViewOrLContainer) {\n // TODO(benlesh/misko): This implementation is incorrect, because it always adds the LContainer\n // to the end of the queue, which means if the developer retrieves the LContainers from RNodes out\n // of order, the change detection will run out of order, as the act of retrieving the the\n // LContainer from the RNode is what adds it to the queue.\n if (lView[CHILD_HEAD]) {\n lView[CHILD_TAIL][NEXT] = lViewOrLContainer;\n } else {\n lView[CHILD_HEAD] = lViewOrLContainer;\n }\n lView[CHILD_TAIL] = lViewOrLContainer;\n return lViewOrLContainer;\n}\n\n/**\n * Advances to an element for later binding instructions.\n *\n * Used in conjunction with instructions like {@link property} to act on elements with specified\n * indices, for example those created with {@link element} or {@link elementStart}.\n *\n * ```ts\n * (rf: RenderFlags, ctx: any) => {\n * if (rf & 1) {\n * text(0, 'Hello');\n * text(1, 'Goodbye')\n * element(2, 'div');\n * }\n * if (rf & 2) {\n * advance(2); // Advance twice to the <div>.\n * property('title', 'test');\n * }\n * }\n * ```\n * @param delta Number of elements to advance forwards by.\n *\n * @codeGenApi\n */\nfunction ɵɵadvance(delta = 1) {\n ngDevMode && assertGreaterThan(delta, 0, 'Can only advance forward');\n selectIndexInternal(getTView(), getLView(), getSelectedIndex() + delta, !!ngDevMode && isInCheckNoChangesMode());\n}\nfunction selectIndexInternal(tView, lView, index, checkNoChangesMode) {\n ngDevMode && assertIndexInDeclRange(lView[TVIEW], index);\n // Flush the initial hooks for elements in the view that have been added up to this point.\n // PERF WARNING: do NOT extract this to a separate function without running benchmarks\n if (!checkNoChangesMode) {\n const hooksInitPhaseCompleted = (lView[FLAGS] & 3 /* LViewFlags.InitPhaseStateMask */) === 3 /* InitPhaseState.InitPhaseCompleted */;\n if (hooksInitPhaseCompleted) {\n const preOrderCheckHooks = tView.preOrderCheckHooks;\n if (preOrderCheckHooks !== null) {\n executeCheckHooks(lView, preOrderCheckHooks, index);\n }\n } else {\n const preOrderHooks = tView.preOrderHooks;\n if (preOrderHooks !== null) {\n executeInitAndCheckHooks(lView, preOrderHooks, 0 /* InitPhaseState.OnInitHooksToBeRun */, index);\n }\n }\n }\n // We must set the selected index *after* running the hooks, because hooks may have side-effects\n // that cause other template functions to run, thus updating the selected index, which is global\n // state. If we run `setSelectedIndex` *before* we run the hooks, in some cases the selected index\n // will be altered by the time we leave the `ɵɵadvance` instruction.\n setSelectedIndex(index);\n}\n\n/** Flags describing an input for a directive. */\nvar InputFlags;\n(function (InputFlags) {\n InputFlags[InputFlags[\"None\"] = 0] = \"None\";\n InputFlags[InputFlags[\"SignalBased\"] = 1] = \"SignalBased\";\n InputFlags[InputFlags[\"HasDecoratorInputTransform\"] = 2] = \"HasDecoratorInputTransform\";\n})(InputFlags || (InputFlags = {}));\nfunction writeToDirectiveInput(def, instance, publicName, value) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n if (ngDevMode) {\n if (!def.inputs.hasOwnProperty(publicName)) {\n throw new Error(`ASSERTION ERROR: Directive ${def.type.name} does not have an input with a public name of \"${publicName}\"`);\n }\n // Usually we resolve the directive instance using `LView[someIndex]` before writing to an\n // input, however if the read happens to early, the `LView[someIndex]` might actually be a\n // `NodeInjectorFactory`. Check for this specific case here since it can break in subtle ways.\n if (instance instanceof NodeInjectorFactory) {\n throw new Error(`ASSERTION ERROR: Cannot write input to factory for type ${def.type.name}. Directive has not been created yet.`);\n }\n }\n const [privateName, flags, transform] = def.inputs[publicName];\n // If we know we are dealing with a signal input, we cache its reference\n // in a tree-shakable way. The input signal node can then be used for\n // value transform execution or actual value updates without introducing\n // additional megamorphic accesses for accessing the instance field.\n let inputSignalNode = null;\n if ((flags & InputFlags.SignalBased) !== 0) {\n const field = instance[privateName];\n inputSignalNode = field[SIGNAL$1];\n }\n // If there is a signal node and a transform, run it before potentially\n // delegating to features like `NgOnChanges`.\n if (inputSignalNode !== null && inputSignalNode.transformFn !== undefined) {\n value = inputSignalNode.transformFn(value);\n } else if (transform !== null) {\n // If there is a decorator input transform, run it.\n value = transform.call(instance, value);\n }\n if (def.setInput !== null) {\n def.setInput(instance, inputSignalNode, value, publicName, privateName);\n } else {\n applyValueToInputField(instance, inputSignalNode, privateName, value);\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n}\nfunction executeTemplate(tView, lView, templateFn, rf, context) {\n const prevSelectedIndex = getSelectedIndex();\n const isUpdatePhase = rf & 2 /* RenderFlags.Update */;\n try {\n setSelectedIndex(-1);\n if (isUpdatePhase && lView.length > HEADER_OFFSET) {\n // When we're updating, inherently select 0 so we don't\n // have to generate that instruction for most update blocks.\n selectIndexInternal(tView, lView, HEADER_OFFSET, !!ngDevMode && isInCheckNoChangesMode());\n }\n const preHookType = isUpdatePhase ? 2 /* ProfilerEvent.TemplateUpdateStart */ : 0 /* ProfilerEvent.TemplateCreateStart */;\n profiler(preHookType, context);\n templateFn(rf, context);\n } finally {\n setSelectedIndex(prevSelectedIndex);\n const postHookType = isUpdatePhase ? 3 /* ProfilerEvent.TemplateUpdateEnd */ : 1 /* ProfilerEvent.TemplateCreateEnd */;\n profiler(postHookType, context);\n }\n}\n/**\n * Creates directive instances.\n */\nfunction createDirectivesInstances(tView, lView, tNode) {\n instantiateAllDirectives(tView, lView, tNode);\n if ((tNode.flags & 64 /* TNodeFlags.hasHostBindings */) === 64 /* TNodeFlags.hasHostBindings */) {\n invokeDirectivesHostBindings(tView, lView, tNode);\n }\n}\n/**\n * Takes a list of local names and indices and pushes the resolved local variable values\n * to LView in the same order as they are loaded in the template with load().\n */\nfunction saveResolvedLocalsInData(viewData, tNode, localRefExtractor = getNativeByTNode) {\n const localNames = tNode.localNames;\n if (localNames !== null) {\n let localIndex = tNode.index + 1;\n for (let i = 0; i < localNames.length; i += 2) {\n const index = localNames[i + 1];\n const value = index === -1 ? localRefExtractor(tNode, viewData) : viewData[index];\n viewData[localIndex++] = value;\n }\n }\n}\n/**\n * Locates the host native element, used for bootstrapping existing nodes into rendering pipeline.\n *\n * @param renderer the renderer used to locate the element.\n * @param elementOrSelector Render element or CSS selector to locate the element.\n * @param encapsulation View Encapsulation defined for component that requests host element.\n * @param injector Root view injector instance.\n */\nfunction locateHostElement(renderer, elementOrSelector, encapsulation, injector) {\n // Note: we use default value for the `PRESERVE_HOST_CONTENT` here even though it's a\n // tree-shakable one (providedIn:'root'). This code path can be triggered during dynamic\n // component creation (after calling ViewContainerRef.createComponent) when an injector\n // instance can be provided. The injector instance might be disconnected from the main DI\n // tree, thus the `PRESERVE_HOST_CONTENT` would not be able to instantiate. In this case, the\n // default value will be used.\n const preserveHostContent = injector.get(PRESERVE_HOST_CONTENT, PRESERVE_HOST_CONTENT_DEFAULT);\n // When using native Shadow DOM, do not clear host element to allow native slot\n // projection.\n const preserveContent = preserveHostContent || encapsulation === ViewEncapsulation.ShadowDom;\n const rootElement = renderer.selectRootElement(elementOrSelector, preserveContent);\n applyRootElementTransform(rootElement);\n return rootElement;\n}\n/**\n * Applies any root element transformations that are needed. If hydration is enabled,\n * this will process corrupted text nodes.\n *\n * @param rootElement the app root HTML Element\n */\nfunction applyRootElementTransform(rootElement) {\n _applyRootElementTransformImpl(rootElement);\n}\n/**\n * Reference to a function that applies transformations to the root HTML element\n * of an app. When hydration is enabled, this processes any corrupt text nodes\n * so they are properly hydratable on the client.\n *\n * @param rootElement the app root HTML Element\n */\nlet _applyRootElementTransformImpl = () => null;\n/**\n * Processes text node markers before hydration begins. This replaces any special comment\n * nodes that were added prior to serialization are swapped out to restore proper text\n * nodes before hydration.\n *\n * @param rootElement the app root HTML Element\n */\nfunction applyRootElementTransformImpl(rootElement) {\n if (hasSkipHydrationAttrOnRElement(rootElement)) {\n // Handle a situation when the `ngSkipHydration` attribute is applied\n // to the root node of an application. In this case, we should clear\n // the contents and render everything from scratch.\n clearElementContents(rootElement);\n } else {\n processTextNodeMarkersBeforeHydration(rootElement);\n }\n}\n/**\n * Sets the implementation for the `applyRootElementTransform` function.\n */\nfunction enableApplyRootElementTransformImpl() {\n _applyRootElementTransformImpl = applyRootElementTransformImpl;\n}\n/**\n * Mapping between attributes names that don't correspond to their element property names.\n *\n * Performance note: this function is written as a series of if checks (instead of, say, a property\n * object lookup) for performance reasons - the series of `if` checks seems to be the fastest way of\n * mapping property names. Do NOT change without benchmarking.\n *\n * Note: this mapping has to be kept in sync with the equally named mapping in the template\n * type-checking machinery of ngtsc.\n */\nfunction mapPropName(name) {\n if (name === 'class') return 'className';\n if (name === 'for') return 'htmlFor';\n if (name === 'formaction') return 'formAction';\n if (name === 'innerHtml') return 'innerHTML';\n if (name === 'readonly') return 'readOnly';\n if (name === 'tabindex') return 'tabIndex';\n return name;\n}\nfunction elementPropertyInternal(tView, tNode, lView, propName, value, renderer, sanitizer, nativeOnly) {\n ngDevMode && assertNotSame(value, NO_CHANGE, 'Incoming value should never be NO_CHANGE.');\n if (!nativeOnly) {\n const hasSetInput = setAllInputsForProperty(tNode, tView, lView, propName, value);\n if (hasSetInput) {\n isComponentHost(tNode) && markDirtyIfOnPush(lView, tNode.index);\n ngDevMode && setNgReflectProperties(lView, tView, tNode, propName, value);\n return; // Stop propcessing if we've matched at least one input.\n }\n }\n if (tNode.type & 3 /* TNodeType.AnyRNode */) {\n const element = getNativeByTNode(tNode, lView);\n propName = mapPropName(propName);\n if (ngDevMode) {\n validateAgainstEventProperties(propName);\n if (!isPropertyValid(element, propName, tNode.value, tView.schemas)) {\n handleUnknownPropertyError(propName, tNode.value, tNode.type, lView);\n }\n ngDevMode.rendererSetProperty++;\n }\n // It is assumed that the sanitizer is only added when the compiler determines that the\n // property is risky, so sanitization can be done without further checks.\n value = sanitizer != null ? sanitizer(value, tNode.value || '', propName) : value;\n renderer.setProperty(element, propName, value);\n } else if (tNode.type & 12 /* TNodeType.AnyContainer */) {\n // If the node is a container and the property didn't\n // match any of the inputs or schemas we should throw.\n if (ngDevMode && !matchingSchemas(tView.schemas, tNode.value)) {\n handleUnknownPropertyError(propName, tNode.value, tNode.type, lView);\n }\n }\n}\n/** If node is an OnPush component, marks its LView dirty. */\nfunction markDirtyIfOnPush(lView, viewIndex) {\n ngDevMode && assertLView(lView);\n const childComponentLView = getComponentLViewByIndex(viewIndex, lView);\n if (!(childComponentLView[FLAGS] & 16 /* LViewFlags.CheckAlways */)) {\n childComponentLView[FLAGS] |= 64 /* LViewFlags.Dirty */;\n }\n}\nfunction setNgReflectProperty(lView, tNode, attrName, value) {\n const element = getNativeByTNode(tNode, lView);\n const renderer = lView[RENDERER];\n attrName = normalizeDebugBindingName(attrName);\n const debugValue = normalizeDebugBindingValue(value);\n if (tNode.type & 3 /* TNodeType.AnyRNode */) {\n if (value == null) {\n renderer.removeAttribute(element, attrName);\n } else {\n renderer.setAttribute(element, attrName, debugValue);\n }\n } else {\n const textContent = escapeCommentText(`bindings=${JSON.stringify({\n [attrName]: debugValue\n }, null, 2)}`);\n renderer.setValue(element, textContent);\n }\n}\nfunction setNgReflectProperties(lView, tView, tNode, publicName, value) {\n if (!(tNode.type & (3 /* TNodeType.AnyRNode */ | 4 /* TNodeType.Container */))) {\n return;\n }\n const inputConfig = tNode.inputs?.[publicName];\n const hostInputConfig = tNode.hostDirectiveInputs?.[publicName];\n if (hostInputConfig) {\n for (let i = 0; i < hostInputConfig.length; i += 2) {\n const index = hostInputConfig[i];\n const publicName = hostInputConfig[i + 1];\n const def = tView.data[index];\n setNgReflectProperty(lView, tNode, def.inputs[publicName][0], value);\n }\n }\n // Note: we set the private name of the input as the reflected property, not the public one.\n if (inputConfig) {\n for (const index of inputConfig) {\n const def = tView.data[index];\n setNgReflectProperty(lView, tNode, def.inputs[publicName][0], value);\n }\n }\n}\n/**\n * Instantiate all the directives that were previously resolved on the current node.\n */\nfunction instantiateAllDirectives(tView, lView, tNode) {\n const start = tNode.directiveStart;\n const end = tNode.directiveEnd;\n // The component view needs to be created before creating the node injector\n // since it is used to inject some special symbols like `ChangeDetectorRef`.\n if (isComponentHost(tNode)) {\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */);\n createComponentLView(lView, tNode, tView.data[start + tNode.componentOffset]);\n }\n if (!tView.firstCreatePass) {\n getOrCreateNodeInjectorForNode(tNode, lView);\n }\n const initialInputs = tNode.initialInputs;\n for (let i = start; i < end; i++) {\n const def = tView.data[i];\n const directive = getNodeInjectable(lView, tView, i, tNode);\n attachPatchData(directive, lView);\n if (initialInputs !== null) {\n setInputsFromAttrs(lView, i - start, directive, def, tNode, initialInputs);\n }\n if (isComponentDef(def)) {\n const componentView = getComponentLViewByIndex(tNode.index, lView);\n componentView[CONTEXT] = getNodeInjectable(lView, tView, i, tNode);\n }\n }\n}\nfunction invokeDirectivesHostBindings(tView, lView, tNode) {\n const start = tNode.directiveStart;\n const end = tNode.directiveEnd;\n const elementIndex = tNode.index;\n const currentDirectiveIndex = getCurrentDirectiveIndex();\n try {\n setSelectedIndex(elementIndex);\n for (let dirIndex = start; dirIndex < end; dirIndex++) {\n const def = tView.data[dirIndex];\n const directive = lView[dirIndex];\n setCurrentDirectiveIndex(dirIndex);\n if (def.hostBindings !== null || def.hostVars !== 0 || def.hostAttrs !== null) {\n invokeHostBindingsInCreationMode(def, directive);\n }\n }\n } finally {\n setSelectedIndex(-1);\n setCurrentDirectiveIndex(currentDirectiveIndex);\n }\n}\n/**\n * Invoke the host bindings in creation mode.\n *\n * @param def `DirectiveDef` which may contain the `hostBindings` function.\n * @param directive Instance of directive.\n */\nfunction invokeHostBindingsInCreationMode(def, directive) {\n if (def.hostBindings !== null) {\n def.hostBindings(1 /* RenderFlags.Create */, directive);\n }\n}\n/**\n * Matches the current node against all available selectors.\n * If a component is matched (at most one), it is returned in first position in the array.\n */\nfunction findDirectiveDefMatches(tView, tNode) {\n ngDevMode && assertFirstCreatePass(tView);\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */ | 12 /* TNodeType.AnyContainer */);\n const registry = tView.directiveRegistry;\n let matches = null;\n if (registry) {\n for (let i = 0; i < registry.length; i++) {\n const def = registry[i];\n if (isNodeMatchingSelectorList(tNode, def.selectors, /* isProjectionMode */false)) {\n matches ??= [];\n if (isComponentDef(def)) {\n if (ngDevMode) {\n assertTNodeType(tNode, 2 /* TNodeType.Element */, `\"${tNode.value}\" tags cannot be used as component hosts. ` + `Please use a different tag to activate the ${stringify(def.type)} component.`);\n if (matches.length && isComponentDef(matches[0])) {\n throwMultipleComponentError(tNode, matches.find(isComponentDef).type, def.type);\n }\n }\n matches.unshift(def);\n } else {\n matches.push(def);\n }\n }\n }\n }\n return matches;\n}\nfunction elementAttributeInternal(tNode, lView, name, value, sanitizer, namespace) {\n if (ngDevMode) {\n assertNotSame(value, NO_CHANGE, 'Incoming value should never be NO_CHANGE.');\n validateAgainstEventAttributes(name);\n assertTNodeType(tNode, 2 /* TNodeType.Element */, `Attempted to set attribute \\`${name}\\` on a container node. ` + `Host bindings are not valid on ng-container or ng-template.`);\n }\n const element = getNativeByTNode(tNode, lView);\n setElementAttribute(lView[RENDERER], element, namespace, tNode.value, name, value, sanitizer);\n}\nfunction setElementAttribute(renderer, element, namespace, tagName, name, value, sanitizer) {\n if (value == null) {\n ngDevMode && ngDevMode.rendererRemoveAttribute++;\n renderer.removeAttribute(element, name, namespace);\n } else {\n ngDevMode && ngDevMode.rendererSetAttribute++;\n const strValue = sanitizer == null ? renderStringify(value) : sanitizer(value, tagName || '', name);\n renderer.setAttribute(element, name, strValue, namespace);\n }\n}\n/**\n * Sets initial input properties on directive instances from attribute data\n *\n * @param lView Current LView that is being processed.\n * @param directiveIndex Index of the directive in directives array\n * @param instance Instance of the directive on which to set the initial inputs\n * @param def The directive def that contains the list of inputs\n * @param tNode The static data for this node\n */\nfunction setInputsFromAttrs(lView, directiveIndex, instance, def, tNode, initialInputData) {\n const initialInputs = initialInputData[directiveIndex];\n if (initialInputs !== null) {\n for (let i = 0; i < initialInputs.length; i += 2) {\n const lookupName = initialInputs[i];\n const value = initialInputs[i + 1];\n writeToDirectiveInput(def, instance, lookupName, value);\n if (ngDevMode) {\n setNgReflectProperty(lView, tNode, def.inputs[lookupName][0], value);\n }\n }\n }\n}\n///////////////////////////////\n//// Bindings & interpolations\n///////////////////////////////\n/**\n * Stores meta-data for a property binding to be used by TestBed's `DebugElement.properties`.\n *\n * In order to support TestBed's `DebugElement.properties` we need to save, for each binding:\n * - a bound property name;\n * - a static parts of interpolated strings;\n *\n * A given property metadata is saved at the binding's index in the `TView.data` (in other words, a\n * property binding metadata will be stored in `TView.data` at the same index as a bound value in\n * `LView`). Metadata are represented as `INTERPOLATION_DELIMITER`-delimited string with the\n * following format:\n * - `propertyName` for bound properties;\n * - `propertyName�prefix�interpolation_static_part1�..interpolation_static_partN�suffix` for\n * interpolated properties.\n *\n * @param tData `TData` where meta-data will be saved;\n * @param tNode `TNode` that is a target of the binding;\n * @param propertyName bound property name;\n * @param bindingIndex binding index in `LView`\n * @param interpolationParts static interpolation parts (for property interpolations)\n */\nfunction storePropertyBindingMetadata(tData, tNode, propertyName, bindingIndex, ...interpolationParts) {\n // Binding meta-data are stored only the first time a given property instruction is processed.\n // Since we don't have a concept of the \"first update pass\" we need to check for presence of the\n // binding meta-data to decide if one should be stored (or if was stored already).\n if (tData[bindingIndex] === null) {\n if (!tNode.inputs?.[propertyName] && !tNode.hostDirectiveInputs?.[propertyName]) {\n const propBindingIdxs = tNode.propertyBindings || (tNode.propertyBindings = []);\n propBindingIdxs.push(bindingIndex);\n let bindingMetadata = propertyName;\n if (interpolationParts.length > 0) {\n bindingMetadata += INTERPOLATION_DELIMITER + interpolationParts.join(INTERPOLATION_DELIMITER);\n }\n tData[bindingIndex] = bindingMetadata;\n }\n }\n}\n/**\n * There are cases where the sub component's renderer needs to be included\n * instead of the current renderer (see the componentSyntheticHost* instructions).\n */\nfunction loadComponentRenderer(currentDef, tNode, lView) {\n // TODO(FW-2043): the `currentDef` is null when host bindings are invoked while creating root\n // component (see packages/core/src/render3/component.ts). This is not consistent with the process\n // of creating inner components, when current directive index is available in the state. In order\n // to avoid relying on current def being `null` (thus special-casing root component creation), the\n // process of creating root component should be unified with the process of creating inner\n // components.\n if (currentDef === null || isComponentDef(currentDef)) {\n lView = unwrapLView(lView[tNode.index]);\n }\n return lView[RENDERER];\n}\n/** Handles an error thrown in an LView. */\nfunction handleError(lView, error) {\n const injector = lView[INJECTOR];\n const errorHandler = injector ? injector.get(ErrorHandler, null) : null;\n errorHandler && errorHandler.handleError(error);\n}\n/**\n * Set all directive inputs with the specific public name on the node.\n *\n * @param tNode TNode on which the input is being set.\n * @param tView Current TView\n * @param lView `LView` which contains the directives.\n * @param publicName Public name of the input being set.\n * @param value Value to set.\n */\nfunction setAllInputsForProperty(tNode, tView, lView, publicName, value) {\n const inputs = tNode.inputs?.[publicName];\n const hostDirectiveInputs = tNode.hostDirectiveInputs?.[publicName];\n let hasMatch = false;\n if (hostDirectiveInputs) {\n for (let i = 0; i < hostDirectiveInputs.length; i += 2) {\n const index = hostDirectiveInputs[i];\n ngDevMode && assertIndexInRange(lView, index);\n const publicName = hostDirectiveInputs[i + 1];\n const def = tView.data[index];\n writeToDirectiveInput(def, lView[index], publicName, value);\n hasMatch = true;\n }\n }\n if (inputs) {\n for (const index of inputs) {\n ngDevMode && assertIndexInRange(lView, index);\n const instance = lView[index];\n const def = tView.data[index];\n writeToDirectiveInput(def, instance, publicName, value);\n hasMatch = true;\n }\n }\n return hasMatch;\n}\n/**\n * Sets an input value only on a specific directive and its host directives.\n * @param tNode TNode on which the input is being set.\n * @param tView Current TView\n * @param lView `LView` which contains the directives.\n * @param target Directive on which to set the input.\n * @param publicName Public name of the input being set.\n * @param value Value to set.\n */\nfunction setDirectiveInput(tNode, tView, lView, target, publicName, value) {\n let hostIndex = null;\n let hostDirectivesStart = null;\n let hostDirectivesEnd = null;\n let hasSet = false;\n if (ngDevMode && !tNode.directiveToIndex?.has(target.type)) {\n throw new Error(`Node does not have a directive with type ${target.type.name}`);\n }\n const data = tNode.directiveToIndex.get(target.type);\n if (typeof data === 'number') {\n hostIndex = data;\n } else {\n [hostIndex, hostDirectivesStart, hostDirectivesEnd] = data;\n }\n if (hostDirectivesStart !== null && hostDirectivesEnd !== null && tNode.hostDirectiveInputs?.hasOwnProperty(publicName)) {\n const hostDirectiveInputs = tNode.hostDirectiveInputs[publicName];\n for (let i = 0; i < hostDirectiveInputs.length; i += 2) {\n const index = hostDirectiveInputs[i];\n if (index >= hostDirectivesStart && index <= hostDirectivesEnd) {\n ngDevMode && assertIndexInRange(lView, index);\n const def = tView.data[index];\n const hostDirectivePublicName = hostDirectiveInputs[i + 1];\n writeToDirectiveInput(def, lView[index], hostDirectivePublicName, value);\n hasSet = true;\n } else if (index > hostDirectivesEnd) {\n // Directives here are in ascending order so we can stop looking once we're past the range.\n break;\n }\n }\n }\n if (hostIndex !== null) {\n ngDevMode && assertIndexInRange(lView, hostIndex);\n writeToDirectiveInput(target, lView[hostIndex], publicName, value);\n hasSet = true;\n }\n return hasSet;\n}\nfunction renderComponent(hostLView, componentHostIdx) {\n ngDevMode && assertEqual(isCreationMode(hostLView), true, 'Should be run in creation mode');\n const componentView = getComponentLViewByIndex(componentHostIdx, hostLView);\n const componentTView = componentView[TVIEW];\n syncViewWithBlueprint(componentTView, componentView);\n const hostRNode = componentView[HOST];\n // Populate an LView with hydration info retrieved from the DOM via TransferState.\n if (hostRNode !== null && componentView[HYDRATION] === null) {\n componentView[HYDRATION] = retrieveHydrationInfo(hostRNode, componentView[INJECTOR]);\n }\n profiler(18 /* ProfilerEvent.ComponentStart */);\n renderView(componentTView, componentView, componentView[CONTEXT]);\n profiler(19 /* ProfilerEvent.ComponentEnd */, componentView[CONTEXT]);\n}\n/**\n * Syncs an LView instance with its blueprint if they have gotten out of sync.\n *\n * Typically, blueprints and their view instances should always be in sync, so the loop here\n * will be skipped. However, consider this case of two components side-by-side:\n *\n * App template:\n * ```html\n * <comp></comp>\n * <comp></comp>\n * ```\n *\n * The following will happen:\n * 1. App template begins processing.\n * 2. First <comp> is matched as a component and its LView is created.\n * 3. Second <comp> is matched as a component and its LView is created.\n * 4. App template completes processing, so it's time to check child templates.\n * 5. First <comp> template is checked. It has a directive, so its def is pushed to blueprint.\n * 6. Second <comp> template is checked. Its blueprint has been updated by the first\n * <comp> template, but its LView was created before this update, so it is out of sync.\n *\n * Note that embedded views inside ngFor loops will never be out of sync because these views\n * are processed as soon as they are created.\n *\n * @param tView The `TView` that contains the blueprint for syncing\n * @param lView The view to sync\n */\nfunction syncViewWithBlueprint(tView, lView) {\n for (let i = lView.length; i < tView.blueprint.length; i++) {\n lView.push(tView.blueprint[i]);\n }\n}\n/**\n * Processes a view in the creation mode. This includes a number of steps in a specific order:\n * - creating view query functions (if any);\n * - executing a template function in the creation mode;\n * - updating static queries (if any);\n * - creating child components defined in a given view.\n */\nfunction renderView(tView, lView, context) {\n ngDevMode && assertEqual(isCreationMode(lView), true, 'Should be run in creation mode');\n ngDevMode && assertNotReactive(renderView.name);\n enterView(lView);\n try {\n const viewQuery = tView.viewQuery;\n if (viewQuery !== null) {\n executeViewQueryFn(1 /* RenderFlags.Create */, viewQuery, context);\n }\n // Execute a template associated with this view, if it exists. A template function might not be\n // defined for the root component views.\n const templateFn = tView.template;\n if (templateFn !== null) {\n executeTemplate(tView, lView, templateFn, 1 /* RenderFlags.Create */, context);\n }\n // This needs to be set before children are processed to support recursive components.\n // This must be set to false immediately after the first creation run because in an\n // ngFor loop, all the views will be created together before update mode runs and turns\n // off firstCreatePass. If we don't set it here, instances will perform directive\n // matching, etc again and again.\n if (tView.firstCreatePass) {\n tView.firstCreatePass = false;\n }\n // Mark all queries active in this view as dirty. This is necessary for signal-based queries to\n // have a clear marking point where we can read query results atomically (for a given view).\n lView[QUERIES]?.finishViewCreation(tView);\n // We resolve content queries specifically marked as `static` in creation mode. Dynamic\n // content queries are resolved during change detection (i.e. update mode), after embedded\n // views are refreshed (see block above).\n if (tView.staticContentQueries) {\n refreshContentQueries(tView, lView);\n }\n // We must materialize query results before child components are processed\n // in case a child component has projected a container. The LContainer needs\n // to exist so the embedded views are properly attached by the container.\n if (tView.staticViewQueries) {\n executeViewQueryFn(2 /* RenderFlags.Update */, tView.viewQuery, context);\n }\n // Render child component views.\n const components = tView.components;\n if (components !== null) {\n renderChildComponents(lView, components);\n }\n } catch (error) {\n // If we didn't manage to get past the first template pass due to\n // an error, mark the view as corrupted so we can try to recover.\n if (tView.firstCreatePass) {\n tView.incompleteFirstPass = true;\n tView.firstCreatePass = false;\n }\n throw error;\n } finally {\n lView[FLAGS] &= ~4 /* LViewFlags.CreationMode */;\n leaveView();\n }\n}\n/** Renders child components in the current view (creation mode). */\nfunction renderChildComponents(hostLView, components) {\n for (let i = 0; i < components.length; i++) {\n renderComponent(hostLView, components[i]);\n }\n}\nfunction createAndRenderEmbeddedLView(declarationLView, templateTNode, context, options) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n const embeddedTView = templateTNode.tView;\n ngDevMode && assertDefined(embeddedTView, 'TView must be defined for a template node.');\n ngDevMode && assertTNodeForLView(templateTNode, declarationLView);\n // Embedded views follow the change detection strategy of the view they're declared in.\n const isSignalView = declarationLView[FLAGS] & 4096 /* LViewFlags.SignalView */;\n const viewFlags = isSignalView ? 4096 /* LViewFlags.SignalView */ : 16 /* LViewFlags.CheckAlways */;\n const embeddedLView = createLView(declarationLView, embeddedTView, context, viewFlags, null, templateTNode, null, null, options?.injector ?? null, options?.embeddedViewInjector ?? null, options?.dehydratedView ?? null);\n const declarationLContainer = declarationLView[templateTNode.index];\n ngDevMode && assertLContainer(declarationLContainer);\n embeddedLView[DECLARATION_LCONTAINER] = declarationLContainer;\n const declarationViewLQueries = declarationLView[QUERIES];\n if (declarationViewLQueries !== null) {\n embeddedLView[QUERIES] = declarationViewLQueries.createEmbeddedView(embeddedTView);\n }\n // execute creation mode of a view\n renderView(embeddedTView, embeddedLView, context);\n return embeddedLView;\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n}\n/**\n * Returns whether an elements that belong to a view should be\n * inserted into the DOM. For client-only cases, DOM elements are\n * always inserted. For hydration cases, we check whether serialized\n * info is available for a view and the view is not in a \"skip hydration\"\n * block (in which case view contents was re-created, thus needing insertion).\n */\nfunction shouldAddViewToDom(tNode, dehydratedView) {\n return !dehydratedView || dehydratedView.firstChild === null || hasInSkipHydrationBlockFlag(tNode);\n}\nlet _icuContainerIterate;\n/**\n * Iterator which provides ability to visit all of the `TIcuContainerNode` root `RNode`s.\n */\nfunction icuContainerIterate(tIcuContainerNode, lView) {\n return _icuContainerIterate(tIcuContainerNode, lView);\n}\n/**\n * Ensures that `IcuContainerVisitor`'s implementation is present.\n *\n * This function is invoked when i18n instruction comes across an ICU. The purpose is to allow the\n * bundler to tree shake ICU logic and only load it if ICU instruction is executed.\n */\nfunction ensureIcuContainerVisitorLoaded(loader) {\n if (_icuContainerIterate === undefined) {\n // Do not inline this function. We want to keep `ensureIcuContainerVisitorLoaded` light, so it\n // can be inlined into call-site.\n _icuContainerIterate = loader();\n }\n}\n\n/**\n * Flags for renderer-specific style modifiers.\n * @publicApi\n */\nvar RendererStyleFlags2;\n(function (RendererStyleFlags2) {\n // TODO(misko): This needs to be refactored into a separate file so that it can be imported from\n // `node_manipulation.ts` Currently doing the import cause resolution order to change and fails\n // the tests. The work around is to have hard coded value in `node_manipulation.ts` for now.\n /**\n * Marks a style as important.\n */\n RendererStyleFlags2[RendererStyleFlags2[\"Important\"] = 1] = \"Important\";\n /**\n * Marks a style as using dash case naming (this-is-dash-case).\n */\n RendererStyleFlags2[RendererStyleFlags2[\"DashCase\"] = 2] = \"DashCase\";\n})(RendererStyleFlags2 || (RendererStyleFlags2 = {}));\n\n/**\n * Checks whether a TNode is considered detached, i.e. not present in the\n * translated i18n template. We should not attempt hydration for such nodes\n * and instead, use a regular \"creation mode\".\n */\nfunction isDetachedByI18n(tNode) {\n return (tNode.flags & 32 /* TNodeFlags.isDetached */) === 32 /* TNodeFlags.isDetached */;\n}\n\n/**\n * NOTE: for performance reasons, the possible actions are inlined within the function instead of\n * being passed as an argument.\n */\nfunction applyToElementOrContainer(action, renderer, parent, lNodeToHandle, beforeNode) {\n // If this slot was allocated for a text node dynamically created by i18n, the text node itself\n // won't be created until i18nApply() in the update block, so this node should be skipped.\n // For more info, see \"ICU expressions should work inside an ngTemplateOutlet inside an ngFor\"\n // in `i18n_spec.ts`.\n if (lNodeToHandle != null) {\n let lContainer;\n let isComponent = false;\n // We are expecting an RNode, but in the case of a component or LContainer the `RNode` is\n // wrapped in an array which needs to be unwrapped. We need to know if it is a component and if\n // it has LContainer so that we can process all of those cases appropriately.\n if (isLContainer(lNodeToHandle)) {\n lContainer = lNodeToHandle;\n } else if (isLView(lNodeToHandle)) {\n isComponent = true;\n ngDevMode && assertDefined(lNodeToHandle[HOST], 'HOST must be defined for a component LView');\n lNodeToHandle = lNodeToHandle[HOST];\n }\n const rNode = unwrapRNode(lNodeToHandle);\n if (action === 0 /* WalkTNodeTreeAction.Create */ && parent !== null) {\n if (beforeNode == null) {\n nativeAppendChild(renderer, parent, rNode);\n } else {\n nativeInsertBefore(renderer, parent, rNode, beforeNode || null, true);\n }\n } else if (action === 1 /* WalkTNodeTreeAction.Insert */ && parent !== null) {\n nativeInsertBefore(renderer, parent, rNode, beforeNode || null, true);\n } else if (action === 2 /* WalkTNodeTreeAction.Detach */) {\n nativeRemoveNode(renderer, rNode, isComponent);\n } else if (action === 3 /* WalkTNodeTreeAction.Destroy */) {\n ngDevMode && ngDevMode.rendererDestroyNode++;\n renderer.destroyNode(rNode);\n }\n if (lContainer != null) {\n applyContainer(renderer, action, lContainer, parent, beforeNode);\n }\n }\n}\n/**\n * Removes all DOM elements associated with a view.\n *\n * Because some root nodes of the view may be containers, we sometimes need\n * to propagate deeply into the nested containers to remove all elements in the\n * views beneath it.\n *\n * @param tView The `TView' of the `LView` from which elements should be added or removed\n * @param lView The view from which elements should be added or removed\n */\nfunction removeViewFromDOM(tView, lView) {\n detachViewFromDOM(tView, lView);\n lView[HOST] = null;\n lView[T_HOST] = null;\n}\n/**\n * Adds all DOM elements associated with a view.\n *\n * Because some root nodes of the view may be containers, we sometimes need\n * to propagate deeply into the nested containers to add all elements in the\n * views beneath it.\n *\n * @param tView The `TView' of the `LView` from which elements should be added or removed\n * @param parentTNode The `TNode` where the `LView` should be attached to.\n * @param renderer Current renderer to use for DOM manipulations.\n * @param lView The view from which elements should be added or removed\n * @param parentNativeNode The parent `RElement` where it should be inserted into.\n * @param beforeNode The node before which elements should be added, if insert mode\n */\nfunction addViewToDOM(tView, parentTNode, renderer, lView, parentNativeNode, beforeNode) {\n lView[HOST] = parentNativeNode;\n lView[T_HOST] = parentTNode;\n applyView(tView, lView, renderer, 1 /* WalkTNodeTreeAction.Insert */, parentNativeNode, beforeNode);\n}\n/**\n * Detach a `LView` from the DOM by detaching its nodes.\n *\n * @param tView The `TView' of the `LView` to be detached\n * @param lView the `LView` to be detached.\n */\nfunction detachViewFromDOM(tView, lView) {\n // When we remove a view from the DOM, we need to rerun afterRender hooks\n // We don't necessarily needs to run change detection. DOM removal only requires\n // change detection if animations are enabled (this notification is handled by animations).\n lView[ENVIRONMENT].changeDetectionScheduler?.notify(9 /* NotificationSource.ViewDetachedFromDOM */);\n applyView(tView, lView, lView[RENDERER], 2 /* WalkTNodeTreeAction.Detach */, null, null);\n}\n/**\n * Traverses down and up the tree of views and containers to remove listeners and\n * call onDestroy callbacks.\n *\n * Notes:\n * - Because it's used for onDestroy calls, it needs to be bottom-up.\n * - Must process containers instead of their views to avoid splicing\n * when views are destroyed and re-added.\n * - Using a while loop because it's faster than recursion\n * - Destroy only called on movement to sibling or movement to parent (laterally or up)\n *\n * @param rootView The view to destroy\n */\nfunction destroyViewTree(rootView) {\n // If the view has no children, we can clean it up and return early.\n let lViewOrLContainer = rootView[CHILD_HEAD];\n if (!lViewOrLContainer) {\n return cleanUpView(rootView[TVIEW], rootView);\n }\n while (lViewOrLContainer) {\n let next = null;\n if (isLView(lViewOrLContainer)) {\n // If LView, traverse down to child.\n next = lViewOrLContainer[CHILD_HEAD];\n } else {\n ngDevMode && assertLContainer(lViewOrLContainer);\n // If container, traverse down to its first LView.\n const firstView = lViewOrLContainer[CONTAINER_HEADER_OFFSET];\n if (firstView) next = firstView;\n }\n if (!next) {\n // Only clean up view when moving to the side or up, as destroy hooks\n // should be called in order from the bottom up.\n while (lViewOrLContainer && !lViewOrLContainer[NEXT] && lViewOrLContainer !== rootView) {\n if (isLView(lViewOrLContainer)) {\n cleanUpView(lViewOrLContainer[TVIEW], lViewOrLContainer);\n }\n lViewOrLContainer = lViewOrLContainer[PARENT];\n }\n if (lViewOrLContainer === null) lViewOrLContainer = rootView;\n if (isLView(lViewOrLContainer)) {\n cleanUpView(lViewOrLContainer[TVIEW], lViewOrLContainer);\n }\n next = lViewOrLContainer && lViewOrLContainer[NEXT];\n }\n lViewOrLContainer = next;\n }\n}\nfunction detachMovedView(declarationContainer, lView) {\n ngDevMode && assertLContainer(declarationContainer);\n ngDevMode && assertDefined(declarationContainer[MOVED_VIEWS], 'A projected view should belong to a non-empty projected views collection');\n const movedViews = declarationContainer[MOVED_VIEWS];\n const declarationViewIndex = movedViews.indexOf(lView);\n movedViews.splice(declarationViewIndex, 1);\n}\n/**\n * A standalone function which destroys an LView,\n * conducting clean up (e.g. removing listeners, calling onDestroys).\n *\n * @param tView The `TView' of the `LView` to be destroyed\n * @param lView The view to be destroyed.\n */\nfunction destroyLView(tView, lView) {\n if (isDestroyed(lView)) {\n return;\n }\n const renderer = lView[RENDERER];\n if (renderer.destroyNode) {\n applyView(tView, lView, renderer, 3 /* WalkTNodeTreeAction.Destroy */, null, null);\n }\n destroyViewTree(lView);\n}\n/**\n * Calls onDestroys hooks for all directives and pipes in a given view and then removes all\n * listeners. Listeners are removed as the last step so events delivered in the onDestroys hooks\n * can be propagated to @Output listeners.\n *\n * @param tView `TView` for the `LView` to clean up.\n * @param lView The LView to clean up\n */\nfunction cleanUpView(tView, lView) {\n if (isDestroyed(lView)) {\n return;\n }\n const prevConsumer = setActiveConsumer$1(null);\n try {\n // Usually the Attached flag is removed when the view is detached from its parent, however\n // if it's a root view, the flag won't be unset hence why we're also removing on destroy.\n lView[FLAGS] &= ~128 /* LViewFlags.Attached */;\n // Mark the LView as destroyed *before* executing the onDestroy hooks. An onDestroy hook\n // runs arbitrary user code, which could include its own `viewRef.destroy()` (or similar). If\n // We don't flag the view as destroyed before the hooks, this could lead to an infinite loop.\n // This also aligns with the ViewEngine behavior. It also means that the onDestroy hook is\n // really more of an \"afterDestroy\" hook if you think about it.\n lView[FLAGS] |= 256 /* LViewFlags.Destroyed */;\n lView[REACTIVE_TEMPLATE_CONSUMER] && consumerDestroy$1(lView[REACTIVE_TEMPLATE_CONSUMER]);\n executeOnDestroys(tView, lView);\n processCleanups(tView, lView);\n // For component views only, the local renderer is destroyed at clean up time.\n if (lView[TVIEW].type === 1 /* TViewType.Component */) {\n ngDevMode && ngDevMode.rendererDestroy++;\n lView[RENDERER].destroy();\n }\n const declarationContainer = lView[DECLARATION_LCONTAINER];\n // we are dealing with an embedded view that is still inserted into a container\n if (declarationContainer !== null && isLContainer(lView[PARENT])) {\n // and this is a projected view\n if (declarationContainer !== lView[PARENT]) {\n detachMovedView(declarationContainer, lView);\n }\n // For embedded views still attached to a container: remove query result from this view.\n const lQueries = lView[QUERIES];\n if (lQueries !== null) {\n lQueries.detachView(tView);\n }\n }\n // Unregister the view once everything else has been cleaned up.\n unregisterLView(lView);\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n}\n/** Removes listeners and unsubscribes from output subscriptions */\nfunction processCleanups(tView, lView) {\n ngDevMode && assertNotReactive(processCleanups.name);\n const tCleanup = tView.cleanup;\n const lCleanup = lView[CLEANUP];\n if (tCleanup !== null) {\n for (let i = 0; i < tCleanup.length - 1; i += 2) {\n if (typeof tCleanup[i] === 'string') {\n // This is a native DOM listener. It will occupy 4 entries in the TCleanup array (hence i +=\n // 2 at the end of this block).\n const targetIdx = tCleanup[i + 3];\n ngDevMode && assertNumber(targetIdx, 'cleanup target must be a number');\n if (targetIdx >= 0) {\n // Destroy anything whose teardown is a function call (e.g. QueryList, ModelSignal).\n lCleanup[targetIdx]();\n } else {\n // Subscription\n lCleanup[-targetIdx].unsubscribe();\n }\n i += 2;\n } else {\n // This is a cleanup function that is grouped with the index of its context\n const context = lCleanup[tCleanup[i + 1]];\n tCleanup[i].call(context);\n }\n }\n }\n if (lCleanup !== null) {\n lView[CLEANUP] = null;\n }\n const destroyHooks = lView[ON_DESTROY_HOOKS];\n if (destroyHooks !== null) {\n // Reset the ON_DESTROY_HOOKS array before iterating over it to prevent hooks that unregister\n // themselves from mutating the array during iteration.\n lView[ON_DESTROY_HOOKS] = null;\n for (let i = 0; i < destroyHooks.length; i++) {\n const destroyHooksFn = destroyHooks[i];\n ngDevMode && assertFunction(destroyHooksFn, 'Expecting destroy hook to be a function.');\n destroyHooksFn();\n }\n }\n // Destroy effects registered to the view. Many of these will have been processed above.\n const effects = lView[EFFECTS];\n if (effects !== null) {\n lView[EFFECTS] = null;\n for (const effect of effects) {\n effect.destroy();\n }\n }\n}\n/** Calls onDestroy hooks for this view */\nfunction executeOnDestroys(tView, lView) {\n ngDevMode && assertNotReactive(executeOnDestroys.name);\n let destroyHooks;\n if (tView != null && (destroyHooks = tView.destroyHooks) != null) {\n for (let i = 0; i < destroyHooks.length; i += 2) {\n const context = lView[destroyHooks[i]];\n // Only call the destroy hook if the context has been requested.\n if (!(context instanceof NodeInjectorFactory)) {\n const toCall = destroyHooks[i + 1];\n if (Array.isArray(toCall)) {\n for (let j = 0; j < toCall.length; j += 2) {\n const callContext = context[toCall[j]];\n const hook = toCall[j + 1];\n profiler(4 /* ProfilerEvent.LifecycleHookStart */, callContext, hook);\n try {\n hook.call(callContext);\n } finally {\n profiler(5 /* ProfilerEvent.LifecycleHookEnd */, callContext, hook);\n }\n }\n } else {\n profiler(4 /* ProfilerEvent.LifecycleHookStart */, context, toCall);\n try {\n toCall.call(context);\n } finally {\n profiler(5 /* ProfilerEvent.LifecycleHookEnd */, context, toCall);\n }\n }\n }\n }\n }\n}\n/**\n * Returns a native element if a node can be inserted into the given parent.\n *\n * There are two reasons why we may not be able to insert a element immediately.\n * - Projection: When creating a child content element of a component, we have to skip the\n * insertion because the content of a component will be projected.\n * `<component><content>delayed due to projection</content></component>`\n * - Parent container is disconnected: This can happen when we are inserting a view into\n * parent container, which itself is disconnected. For example the parent container is part\n * of a View which has not be inserted or is made for projection but has not been inserted\n * into destination.\n *\n * @param tView: Current `TView`.\n * @param tNode: `TNode` for which we wish to retrieve render parent.\n * @param lView: Current `LView`.\n */\nfunction getParentRElement(tView, tNode, lView) {\n return getClosestRElement(tView, tNode.parent, lView);\n}\n/**\n * Get closest `RElement` or `null` if it can't be found.\n *\n * If `TNode` is `TNodeType.Element` => return `RElement` at `LView[tNode.index]` location.\n * If `TNode` is `TNodeType.ElementContainer|IcuContain` => return the parent (recursively).\n * If `TNode` is `null` then return host `RElement`:\n * - return `null` if projection\n * - return `null` if parent container is disconnected (we have no parent.)\n *\n * @param tView: Current `TView`.\n * @param tNode: `TNode` for which we wish to retrieve `RElement` (or `null` if host element is\n * needed).\n * @param lView: Current `LView`.\n * @returns `null` if the `RElement` can't be determined at this time (no parent / projection)\n */\nfunction getClosestRElement(tView, tNode, lView) {\n let parentTNode = tNode;\n // Skip over element and ICU containers as those are represented by a comment node and\n // can't be used as a render parent. Also skip let declarations since they don't have a\n // corresponding DOM node at all.\n while (parentTNode !== null && parentTNode.type & (8 /* TNodeType.ElementContainer */ | 32 /* TNodeType.Icu */ | 128 /* TNodeType.LetDeclaration */)) {\n tNode = parentTNode;\n parentTNode = tNode.parent;\n }\n // If the parent tNode is null, then we are inserting across views: either into an embedded view\n // or a component view.\n if (parentTNode === null) {\n // We are inserting a root element of the component view into the component host element and\n // it should always be eager.\n return lView[HOST];\n } else {\n ngDevMode && assertTNodeType(parentTNode, 3 /* TNodeType.AnyRNode */ | 4 /* TNodeType.Container */);\n if (isComponentHost(parentTNode)) {\n ngDevMode && assertTNodeForLView(parentTNode, lView);\n const {\n encapsulation\n } = tView.data[parentTNode.directiveStart + parentTNode.componentOffset];\n // We've got a parent which is an element in the current view. We just need to verify if the\n // parent element is not a component. Component's content nodes are not inserted immediately\n // because they will be projected, and so doing insert at this point would be wasteful.\n // Since the projection would then move it to its final destination. Note that we can't\n // make this assumption when using the Shadow DOM, because the native projection placeholders\n // (<content> or <slot>) have to be in place as elements are being inserted.\n if (encapsulation === ViewEncapsulation.None || encapsulation === ViewEncapsulation.Emulated) {\n return null;\n }\n }\n return getNativeByTNode(parentTNode, lView);\n }\n}\n/**\n * Find a node in front of which `currentTNode` should be inserted.\n *\n * This method determines the `RNode` in front of which we should insert the `currentRNode`. This\n * takes `TNode.insertBeforeIndex` into account if i18n code has been invoked.\n *\n * @param parentTNode parent `TNode`\n * @param currentTNode current `TNode` (The node which we would like to insert into the DOM)\n * @param lView current `LView`\n */\nfunction getInsertInFrontOfRNode(parentTNode, currentTNode, lView) {\n return _getInsertInFrontOfRNodeWithI18n(parentTNode, currentTNode, lView);\n}\n/**\n * Find a node in front of which `currentTNode` should be inserted. (Does not take i18n into\n * account)\n *\n * This method determines the `RNode` in front of which we should insert the `currentRNode`. This\n * does not take `TNode.insertBeforeIndex` into account.\n *\n * @param parentTNode parent `TNode`\n * @param currentTNode current `TNode` (The node which we would like to insert into the DOM)\n * @param lView current `LView`\n */\nfunction getInsertInFrontOfRNodeWithNoI18n(parentTNode, currentTNode, lView) {\n if (parentTNode.type & (8 /* TNodeType.ElementContainer */ | 32 /* TNodeType.Icu */)) {\n return getNativeByTNode(parentTNode, lView);\n }\n return null;\n}\n/**\n * Tree shakable boundary for `getInsertInFrontOfRNodeWithI18n` function.\n *\n * This function will only be set if i18n code runs.\n */\nlet _getInsertInFrontOfRNodeWithI18n = getInsertInFrontOfRNodeWithNoI18n;\n/**\n * Tree shakable boundary for `processI18nInsertBefore` function.\n *\n * This function will only be set if i18n code runs.\n */\nlet _processI18nInsertBefore;\nfunction setI18nHandling(getInsertInFrontOfRNodeWithI18n, processI18nInsertBefore) {\n _getInsertInFrontOfRNodeWithI18n = getInsertInFrontOfRNodeWithI18n;\n _processI18nInsertBefore = processI18nInsertBefore;\n}\n/**\n * Appends the `child` native node (or a collection of nodes) to the `parent`.\n *\n * @param tView The `TView' to be appended\n * @param lView The current LView\n * @param childRNode The native child (or children) that should be appended\n * @param childTNode The TNode of the child element\n */\nfunction appendChild(tView, lView, childRNode, childTNode) {\n const parentRNode = getParentRElement(tView, childTNode, lView);\n const renderer = lView[RENDERER];\n const parentTNode = childTNode.parent || lView[T_HOST];\n const anchorNode = getInsertInFrontOfRNode(parentTNode, childTNode, lView);\n if (parentRNode != null) {\n if (Array.isArray(childRNode)) {\n for (let i = 0; i < childRNode.length; i++) {\n nativeAppendOrInsertBefore(renderer, parentRNode, childRNode[i], anchorNode, false);\n }\n } else {\n nativeAppendOrInsertBefore(renderer, parentRNode, childRNode, anchorNode, false);\n }\n }\n _processI18nInsertBefore !== undefined && _processI18nInsertBefore(renderer, childTNode, lView, childRNode, parentRNode);\n}\n/**\n * Returns the first native node for a given LView, starting from the provided TNode.\n *\n * Native nodes are returned in the order in which those appear in the native tree (DOM).\n */\nfunction getFirstNativeNode(lView, tNode) {\n if (tNode !== null) {\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */ | 12 /* TNodeType.AnyContainer */ | 32 /* TNodeType.Icu */ | 16 /* TNodeType.Projection */ | 128 /* TNodeType.LetDeclaration */);\n const tNodeType = tNode.type;\n if (tNodeType & 3 /* TNodeType.AnyRNode */) {\n return getNativeByTNode(tNode, lView);\n } else if (tNodeType & 4 /* TNodeType.Container */) {\n return getBeforeNodeForView(-1, lView[tNode.index]);\n } else if (tNodeType & 8 /* TNodeType.ElementContainer */) {\n const elIcuContainerChild = tNode.child;\n if (elIcuContainerChild !== null) {\n return getFirstNativeNode(lView, elIcuContainerChild);\n } else {\n const rNodeOrLContainer = lView[tNode.index];\n if (isLContainer(rNodeOrLContainer)) {\n return getBeforeNodeForView(-1, rNodeOrLContainer);\n } else {\n return unwrapRNode(rNodeOrLContainer);\n }\n }\n } else if (tNodeType & 128 /* TNodeType.LetDeclaration */) {\n return getFirstNativeNode(lView, tNode.next);\n } else if (tNodeType & 32 /* TNodeType.Icu */) {\n let nextRNode = icuContainerIterate(tNode, lView);\n let rNode = nextRNode();\n // If the ICU container has no nodes, than we use the ICU anchor as the node.\n return rNode || unwrapRNode(lView[tNode.index]);\n } else {\n const projectionNodes = getProjectionNodes(lView, tNode);\n if (projectionNodes !== null) {\n if (Array.isArray(projectionNodes)) {\n return projectionNodes[0];\n }\n const parentView = getLViewParent(lView[DECLARATION_COMPONENT_VIEW]);\n ngDevMode && assertParentView(parentView);\n return getFirstNativeNode(parentView, projectionNodes);\n } else {\n return getFirstNativeNode(lView, tNode.next);\n }\n }\n }\n return null;\n}\nfunction getProjectionNodes(lView, tNode) {\n if (tNode !== null) {\n const componentView = lView[DECLARATION_COMPONENT_VIEW];\n const componentHost = componentView[T_HOST];\n const slotIdx = tNode.projection;\n ngDevMode && assertProjectionSlots(lView);\n return componentHost.projection[slotIdx];\n }\n return null;\n}\nfunction getBeforeNodeForView(viewIndexInContainer, lContainer) {\n const nextViewIndex = CONTAINER_HEADER_OFFSET + viewIndexInContainer + 1;\n if (nextViewIndex < lContainer.length) {\n const lView = lContainer[nextViewIndex];\n const firstTNodeOfView = lView[TVIEW].firstChild;\n if (firstTNodeOfView !== null) {\n return getFirstNativeNode(lView, firstTNodeOfView);\n }\n }\n return lContainer[NATIVE];\n}\n/**\n * Performs the operation of `action` on the node. Typically this involves inserting or removing\n * nodes on the LView or projection boundary.\n */\nfunction applyNodes(renderer, action, tNode, lView, parentRElement, beforeNode, isProjection) {\n while (tNode != null) {\n ngDevMode && assertTNodeForLView(tNode, lView);\n // Let declarations don't have corresponding DOM nodes so we skip over them.\n if (tNode.type === 128 /* TNodeType.LetDeclaration */) {\n tNode = tNode.next;\n continue;\n }\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */ | 12 /* TNodeType.AnyContainer */ | 16 /* TNodeType.Projection */ | 32 /* TNodeType.Icu */);\n const rawSlotValue = lView[tNode.index];\n const tNodeType = tNode.type;\n if (isProjection) {\n if (action === 0 /* WalkTNodeTreeAction.Create */) {\n rawSlotValue && attachPatchData(unwrapRNode(rawSlotValue), lView);\n tNode.flags |= 2 /* TNodeFlags.isProjected */;\n }\n }\n if (!isDetachedByI18n(tNode)) {\n if (tNodeType & 8 /* TNodeType.ElementContainer */) {\n applyNodes(renderer, action, tNode.child, lView, parentRElement, beforeNode, false);\n applyToElementOrContainer(action, renderer, parentRElement, rawSlotValue, beforeNode);\n } else if (tNodeType & 32 /* TNodeType.Icu */) {\n const nextRNode = icuContainerIterate(tNode, lView);\n let rNode;\n while (rNode = nextRNode()) {\n applyToElementOrContainer(action, renderer, parentRElement, rNode, beforeNode);\n }\n applyToElementOrContainer(action, renderer, parentRElement, rawSlotValue, beforeNode);\n } else if (tNodeType & 16 /* TNodeType.Projection */) {\n applyProjectionRecursive(renderer, action, lView, tNode, parentRElement, beforeNode);\n } else {\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */ | 4 /* TNodeType.Container */);\n applyToElementOrContainer(action, renderer, parentRElement, rawSlotValue, beforeNode);\n }\n }\n tNode = isProjection ? tNode.projectionNext : tNode.next;\n }\n}\nfunction applyView(tView, lView, renderer, action, parentRElement, beforeNode) {\n applyNodes(renderer, action, tView.firstChild, lView, parentRElement, beforeNode, false);\n}\n/**\n * `applyProjection` performs operation on the projection.\n *\n * Inserting a projection requires us to locate the projected nodes from the parent component. The\n * complication is that those nodes themselves could be re-projected from their parent component.\n *\n * @param tView The `TView` of `LView` which needs to be inserted, detached, destroyed\n * @param lView The `LView` which needs to be inserted, detached, destroyed.\n * @param tProjectionNode node to project\n */\nfunction applyProjection(tView, lView, tProjectionNode) {\n const renderer = lView[RENDERER];\n const parentRNode = getParentRElement(tView, tProjectionNode, lView);\n const parentTNode = tProjectionNode.parent || lView[T_HOST];\n let beforeNode = getInsertInFrontOfRNode(parentTNode, tProjectionNode, lView);\n applyProjectionRecursive(renderer, 0 /* WalkTNodeTreeAction.Create */, lView, tProjectionNode, parentRNode, beforeNode);\n}\n/**\n * `applyProjectionRecursive` performs operation on the projection specified by `action` (insert,\n * detach, destroy)\n *\n * Inserting a projection requires us to locate the projected nodes from the parent component. The\n * complication is that those nodes themselves could be re-projected from their parent component.\n *\n * @param renderer Render to use\n * @param action action to perform (insert, detach, destroy)\n * @param lView The LView which needs to be inserted, detached, destroyed.\n * @param tProjectionNode node to project\n * @param parentRElement parent DOM element for insertion/removal.\n * @param beforeNode Before which node the insertions should happen.\n */\nfunction applyProjectionRecursive(renderer, action, lView, tProjectionNode, parentRElement, beforeNode) {\n const componentLView = lView[DECLARATION_COMPONENT_VIEW];\n const componentNode = componentLView[T_HOST];\n ngDevMode && assertEqual(typeof tProjectionNode.projection, 'number', 'expecting projection index');\n const nodeToProjectOrRNodes = componentNode.projection[tProjectionNode.projection];\n if (Array.isArray(nodeToProjectOrRNodes)) {\n // This should not exist, it is a bit of a hack. When we bootstrap a top level node and we\n // need to support passing projectable nodes, so we cheat and put them in the TNode\n // of the Host TView. (Yes we put instance info at the T Level). We can get away with it\n // because we know that TView is not shared and therefore it will not be a problem.\n // This should be refactored and cleaned up.\n for (let i = 0; i < nodeToProjectOrRNodes.length; i++) {\n const rNode = nodeToProjectOrRNodes[i];\n applyToElementOrContainer(action, renderer, parentRElement, rNode, beforeNode);\n }\n } else {\n let nodeToProject = nodeToProjectOrRNodes;\n const projectedComponentLView = componentLView[PARENT];\n // If a parent <ng-content> is located within a skip hydration block,\n // annotate an actual node that is being projected with the same flag too.\n if (hasInSkipHydrationBlockFlag(tProjectionNode)) {\n nodeToProject.flags |= 128 /* TNodeFlags.inSkipHydrationBlock */;\n }\n applyNodes(renderer, action, nodeToProject, projectedComponentLView, parentRElement, beforeNode, true);\n }\n}\n/**\n * `applyContainer` performs an operation on the container and its views as specified by\n * `action` (insert, detach, destroy)\n *\n * Inserting a Container is complicated by the fact that the container may have Views which\n * themselves have containers or projections.\n *\n * @param renderer Renderer to use\n * @param action action to perform (insert, detach, destroy)\n * @param lContainer The LContainer which needs to be inserted, detached, destroyed.\n * @param parentRElement parent DOM element for insertion/removal.\n * @param beforeNode Before which node the insertions should happen.\n */\nfunction applyContainer(renderer, action, lContainer, parentRElement, beforeNode) {\n ngDevMode && assertLContainer(lContainer);\n const anchor = lContainer[NATIVE]; // LContainer has its own before node.\n const native = unwrapRNode(lContainer);\n // An LContainer can be created dynamically on any node by injecting ViewContainerRef.\n // Asking for a ViewContainerRef on an element will result in a creation of a separate anchor\n // node (comment in the DOM) that will be different from the LContainer's host node. In this\n // particular case we need to execute action on 2 nodes:\n // - container's host node (this is done in the executeActionOnElementOrContainer)\n // - container's host node (this is done here)\n if (anchor !== native) {\n // This is very strange to me (Misko). I would expect that the native is same as anchor. I\n // don't see a reason why they should be different, but they are.\n //\n // If they are we need to process the second anchor as well.\n applyToElementOrContainer(action, renderer, parentRElement, anchor, beforeNode);\n }\n for (let i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {\n const lView = lContainer[i];\n applyView(lView[TVIEW], lView, renderer, action, parentRElement, anchor);\n }\n}\n/**\n * Writes class/style to element.\n *\n * @param renderer Renderer to use.\n * @param isClassBased `true` if it should be written to `class` (`false` to write to `style`)\n * @param rNode The Node to write to.\n * @param prop Property to write to. This would be the class/style name.\n * @param value Value to write. If `null`/`undefined`/`false` this is considered a remove (set/add\n * otherwise).\n */\nfunction applyStyling(renderer, isClassBased, rNode, prop, value) {\n if (isClassBased) {\n // We actually want JS true/false here because any truthy value should add the class\n if (!value) {\n ngDevMode && ngDevMode.rendererRemoveClass++;\n renderer.removeClass(rNode, prop);\n } else {\n ngDevMode && ngDevMode.rendererAddClass++;\n renderer.addClass(rNode, prop);\n }\n } else {\n let flags = prop.indexOf('-') === -1 ? undefined : RendererStyleFlags2.DashCase;\n if (value == null /** || value === undefined */) {\n ngDevMode && ngDevMode.rendererRemoveStyle++;\n renderer.removeStyle(rNode, prop, flags);\n } else {\n // A value is important if it ends with `!important`. The style\n // parser strips any semicolons at the end of the value.\n const isImportant = typeof value === 'string' ? value.endsWith('!important') : false;\n if (isImportant) {\n // !important has to be stripped from the value for it to be valid.\n value = value.slice(0, -10);\n flags |= RendererStyleFlags2.Important;\n }\n ngDevMode && ngDevMode.rendererSetStyle++;\n renderer.setStyle(rNode, prop, value, flags);\n }\n }\n}\nfunction collectNativeNodes(tView, lView, tNode, result, isProjection = false) {\n while (tNode !== null) {\n // Let declarations don't have corresponding DOM nodes so we skip over them.\n if (tNode.type === 128 /* TNodeType.LetDeclaration */) {\n tNode = isProjection ? tNode.projectionNext : tNode.next;\n continue;\n }\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */ | 12 /* TNodeType.AnyContainer */ | 16 /* TNodeType.Projection */ | 32 /* TNodeType.Icu */);\n const lNode = lView[tNode.index];\n if (lNode !== null) {\n result.push(unwrapRNode(lNode));\n }\n // A given lNode can represent either a native node or a LContainer (when it is a host of a\n // ViewContainerRef). When we find a LContainer we need to descend into it to collect root nodes\n // from the views in this container.\n if (isLContainer(lNode)) {\n collectNativeNodesInLContainer(lNode, result);\n }\n const tNodeType = tNode.type;\n if (tNodeType & 8 /* TNodeType.ElementContainer */) {\n collectNativeNodes(tView, lView, tNode.child, result);\n } else if (tNodeType & 32 /* TNodeType.Icu */) {\n const nextRNode = icuContainerIterate(tNode, lView);\n let rNode;\n while (rNode = nextRNode()) {\n result.push(rNode);\n }\n } else if (tNodeType & 16 /* TNodeType.Projection */) {\n const nodesInSlot = getProjectionNodes(lView, tNode);\n if (Array.isArray(nodesInSlot)) {\n result.push(...nodesInSlot);\n } else {\n const parentView = getLViewParent(lView[DECLARATION_COMPONENT_VIEW]);\n ngDevMode && assertParentView(parentView);\n collectNativeNodes(parentView[TVIEW], parentView, nodesInSlot, result, true);\n }\n }\n tNode = isProjection ? tNode.projectionNext : tNode.next;\n }\n return result;\n}\n/**\n * Collects all root nodes in all views in a given LContainer.\n */\nfunction collectNativeNodesInLContainer(lContainer, result) {\n for (let i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {\n const lViewInAContainer = lContainer[i];\n const lViewFirstChildTNode = lViewInAContainer[TVIEW].firstChild;\n if (lViewFirstChildTNode !== null) {\n collectNativeNodes(lViewInAContainer[TVIEW], lViewInAContainer, lViewFirstChildTNode, result);\n }\n }\n // When an LContainer is created, the anchor (comment) node is:\n // - (1) either reused in case of an ElementContainer (<ng-container>)\n // - (2) or a new comment node is created\n // In the first case, the anchor comment node would be added to the final\n // list by the code in the `collectNativeNodes` function\n // (see the `result.push(unwrapRNode(lNode))` line), but the second\n // case requires extra handling: the anchor node needs to be added to the\n // final list manually. See additional information in the `createAnchorNode`\n // function in the `view_container_ref.ts`.\n //\n // In the first case, the same reference would be stored in the `NATIVE`\n // and `HOST` slots in an LContainer. Otherwise, this is the second case and\n // we should add an element to the final list.\n if (lContainer[NATIVE] !== lContainer[HOST]) {\n result.push(lContainer[NATIVE]);\n }\n}\nfunction addAfterRenderSequencesForView(lView) {\n if (lView[AFTER_RENDER_SEQUENCES_TO_ADD] !== null) {\n for (const sequence of lView[AFTER_RENDER_SEQUENCES_TO_ADD]) {\n sequence.impl.addSequence(sequence);\n }\n lView[AFTER_RENDER_SEQUENCES_TO_ADD].length = 0;\n }\n}\nlet freeConsumers = [];\n/**\n * Create a new template consumer pointing at the specified LView.\n * Sometimes, a previously created consumer may be reused, in order to save on allocations. In that\n * case, the LView will be updated.\n */\nfunction getOrBorrowReactiveLViewConsumer(lView) {\n return lView[REACTIVE_TEMPLATE_CONSUMER] ?? borrowReactiveLViewConsumer(lView);\n}\nfunction borrowReactiveLViewConsumer(lView) {\n const consumer = freeConsumers.pop() ?? Object.create(REACTIVE_LVIEW_CONSUMER_NODE);\n consumer.lView = lView;\n return consumer;\n}\nfunction maybeReturnReactiveLViewConsumer(consumer) {\n if (consumer.lView[REACTIVE_TEMPLATE_CONSUMER] === consumer) {\n // The consumer got committed.\n return;\n }\n consumer.lView = null;\n freeConsumers.push(consumer);\n}\nconst REACTIVE_LVIEW_CONSUMER_NODE = {\n ...REACTIVE_NODE$1,\n consumerIsAlwaysLive: true,\n kind: 'template',\n consumerMarkedDirty: node => {\n markAncestorsForTraversal(node.lView);\n },\n consumerOnSignalRead() {\n this.lView[REACTIVE_TEMPLATE_CONSUMER] = this;\n }\n};\n/**\n * Creates a temporary consumer for use with `LView`s that should not have consumers.\n * If the LView already has a consumer, returns the existing one instead.\n *\n * This is necessary because some APIs may cause change detection directly on an LView\n * that we do not want to have a consumer (Embedded views today). As a result, there\n * would be no active consumer from running change detection on its host component\n * and any signals in the LView template would be untracked. Instead, we create\n * this temporary consumer that marks the first parent that _should_ have a consumer\n * for refresh. Once change detection runs as part of that refresh, we throw away\n * this consumer because its signals will then be tracked by the parent's consumer.\n */\nfunction getOrCreateTemporaryConsumer(lView) {\n const consumer = lView[REACTIVE_TEMPLATE_CONSUMER] ?? Object.create(TEMPORARY_CONSUMER_NODE);\n consumer.lView = lView;\n return consumer;\n}\nconst TEMPORARY_CONSUMER_NODE = {\n ...REACTIVE_NODE$1,\n consumerIsAlwaysLive: true,\n kind: 'template',\n consumerMarkedDirty: node => {\n let parent = getLViewParent(node.lView);\n while (parent && !viewShouldHaveReactiveConsumer(parent[TVIEW])) {\n parent = getLViewParent(parent);\n }\n if (!parent) {\n // If we can't find an appropriate parent that should have a consumer, we\n // don't have a way of appropriately refreshing this LView as part of application synchronization.\n return;\n }\n markViewForRefresh(parent);\n },\n consumerOnSignalRead() {\n this.lView[REACTIVE_TEMPLATE_CONSUMER] = this;\n }\n};\n/**\n * Indicates if the view should get its own reactive consumer node.\n *\n * In the current design, all embedded views share a consumer with the component view. This allows\n * us to refresh at the component level rather than at a per-view level. In addition, root views get\n * their own reactive node because root component will have a host view that executes the\n * component's host bindings. This needs to be tracked in a consumer as well.\n *\n * To get a more granular change detection than per-component, all we would just need to update the\n * condition here so that a given view gets a reactive consumer which can become dirty independently\n * from its parent component. For example embedded views for signal components could be created with\n * a new type \"SignalEmbeddedView\" and the condition here wouldn't even need updating in order to\n * get granular per-view change detection for signal components.\n */\nfunction viewShouldHaveReactiveConsumer(tView) {\n return tView.type !== 2 /* TViewType.Embedded */;\n}\nfunction runEffectsInView(view) {\n if (view[EFFECTS] === null) {\n return;\n }\n // Since effects can make other effects dirty, we flush them in a loop until there are no more to\n // flush.\n let tryFlushEffects = true;\n while (tryFlushEffects) {\n let foundDirtyEffect = false;\n for (const effect of view[EFFECTS]) {\n if (!effect.dirty) {\n continue;\n }\n foundDirtyEffect = true;\n // `runEffectsInView` is called during change detection, and therefore runs\n // in the Angular zone if it's available.\n if (effect.zone === null || Zone.current === effect.zone) {\n effect.run();\n } else {\n effect.zone.run(() => effect.run());\n }\n }\n // Check if we need to continue flushing. If we didn't find any dirty effects, then there's\n // no need to loop back. Otherwise, check the view to see if it was marked for traversal\n // again. If so, there's a chance that one of the effects we ran caused another effect to\n // become dirty.\n tryFlushEffects = foundDirtyEffect && !!(view[FLAGS] & 8192 /* LViewFlags.HasChildViewsToRefresh */);\n }\n}\n\n/**\n * The maximum number of times the change detection traversal will rerun before throwing an error.\n */\nconst MAXIMUM_REFRESH_RERUNS$1 = 100;\nfunction detectChangesInternal(lView, notifyErrorHandler = true, mode = 0 /* ChangeDetectionMode.Global */) {\n const environment = lView[ENVIRONMENT];\n const rendererFactory = environment.rendererFactory;\n // Check no changes mode is a dev only mode used to verify that bindings have not changed\n // since they were assigned. We do not want to invoke renderer factory functions in that mode\n // to avoid any possible side-effects.\n const checkNoChangesMode = !!ngDevMode && isInCheckNoChangesMode();\n if (!checkNoChangesMode) {\n rendererFactory.begin?.();\n }\n try {\n detectChangesInViewWhileDirty(lView, mode);\n } catch (error) {\n if (notifyErrorHandler) {\n handleError(lView, error);\n }\n throw error;\n } finally {\n if (!checkNoChangesMode) {\n rendererFactory.end?.();\n }\n }\n}\nfunction detectChangesInViewWhileDirty(lView, mode) {\n const lastIsRefreshingViewsValue = isRefreshingViews();\n try {\n setIsRefreshingViews(true);\n detectChangesInView(lView, mode);\n // We don't need or want to do any looping when in exhaustive checkNoChanges because we\n // already traverse all the views and nothing should change so we shouldn't have to do\n // another pass to pick up new changes.\n if (ngDevMode && isExhaustiveCheckNoChanges()) {\n return;\n }\n let retries = 0;\n // If after running change detection, this view still needs to be refreshed or there are\n // descendants views that need to be refreshed due to re-dirtying during the change detection\n // run, detect changes on the view again. We run change detection in `Targeted` mode to only\n // refresh views with the `RefreshView` flag.\n while (requiresRefreshOrTraversal(lView)) {\n if (retries === MAXIMUM_REFRESH_RERUNS$1) {\n throw new RuntimeError(103 /* RuntimeErrorCode.INFINITE_CHANGE_DETECTION */, ngDevMode && 'Infinite change detection while trying to refresh views. ' + 'There may be components which each cause the other to require a refresh, ' + 'causing an infinite loop.');\n }\n retries++;\n // Even if this view is detached, we still detect changes in targeted mode because this was\n // the root of the change detection run.\n detectChangesInView(lView, 1 /* ChangeDetectionMode.Targeted */);\n }\n } finally {\n // restore state to what it was before entering this change detection loop\n setIsRefreshingViews(lastIsRefreshingViewsValue);\n }\n}\nfunction checkNoChangesInternal(lView, mode, notifyErrorHandler = true) {\n setIsInCheckNoChangesMode(mode);\n try {\n detectChangesInternal(lView, notifyErrorHandler);\n } finally {\n setIsInCheckNoChangesMode(CheckNoChangesMode.Off);\n }\n}\n/**\n * Processes a view in update mode. This includes a number of steps in a specific order:\n * - executing a template function in update mode;\n * - executing hooks;\n * - refreshing queries;\n * - setting host bindings;\n * - refreshing child (embedded and component) views.\n */\nfunction refreshView(tView, lView, templateFn, context) {\n ngDevMode && assertEqual(isCreationMode(lView), false, 'Should be run in update mode');\n if (isDestroyed(lView)) return;\n const flags = lView[FLAGS];\n // Check no changes mode is a dev only mode used to verify that bindings have not changed\n // since they were assigned. We do not want to execute lifecycle hooks in that mode.\n const isInCheckNoChangesPass = ngDevMode && isInCheckNoChangesMode();\n const isInExhaustiveCheckNoChangesPass = ngDevMode && isExhaustiveCheckNoChanges();\n // Start component reactive context\n // - We might already be in a reactive context if this is an embedded view of the host.\n // - We might be descending into a view that needs a consumer.\n enterView(lView);\n let returnConsumerToPool = true;\n let prevConsumer = null;\n let currentConsumer = null;\n if (!isInCheckNoChangesPass) {\n if (viewShouldHaveReactiveConsumer(tView)) {\n currentConsumer = getOrBorrowReactiveLViewConsumer(lView);\n prevConsumer = consumerBeforeComputation$1(currentConsumer);\n } else if (getActiveConsumer$1() === null) {\n // If the current view should not have a reactive consumer but we don't have an active consumer,\n // we still need to create a temporary consumer to track any signal reads in this template.\n // This is a rare case that can happen with `viewContainerRef.createEmbeddedView(...).detectChanges()`.\n // This temporary consumer marks the first parent that _should_ have a consumer for refresh.\n // Once that refresh happens, the signals will be tracked in the parent consumer and we can destroy\n // the temporary one.\n returnConsumerToPool = false;\n currentConsumer = getOrCreateTemporaryConsumer(lView);\n prevConsumer = consumerBeforeComputation$1(currentConsumer);\n } else if (lView[REACTIVE_TEMPLATE_CONSUMER]) {\n consumerDestroy$1(lView[REACTIVE_TEMPLATE_CONSUMER]);\n lView[REACTIVE_TEMPLATE_CONSUMER] = null;\n }\n }\n try {\n resetPreOrderHookFlags(lView);\n setBindingIndex(tView.bindingStartIndex);\n if (templateFn !== null) {\n executeTemplate(tView, lView, templateFn, 2 /* RenderFlags.Update */, context);\n }\n const hooksInitPhaseCompleted = (flags & 3 /* LViewFlags.InitPhaseStateMask */) === 3 /* InitPhaseState.InitPhaseCompleted */;\n // execute pre-order hooks (OnInit, OnChanges, DoCheck)\n // PERF WARNING: do NOT extract this to a separate function without running benchmarks\n if (!isInCheckNoChangesPass) {\n if (hooksInitPhaseCompleted) {\n const preOrderCheckHooks = tView.preOrderCheckHooks;\n if (preOrderCheckHooks !== null) {\n executeCheckHooks(lView, preOrderCheckHooks, null);\n }\n } else {\n const preOrderHooks = tView.preOrderHooks;\n if (preOrderHooks !== null) {\n executeInitAndCheckHooks(lView, preOrderHooks, 0 /* InitPhaseState.OnInitHooksToBeRun */, null);\n }\n incrementInitPhaseFlags(lView, 0 /* InitPhaseState.OnInitHooksToBeRun */);\n }\n }\n // We do not need to mark transplanted views for refresh when doing exhaustive checks\n // because all views will be reached anyways during the traversal.\n if (!isInExhaustiveCheckNoChangesPass) {\n // First mark transplanted views that are declared in this lView as needing a refresh at their\n // insertion points. This is needed to avoid the situation where the template is defined in this\n // `LView` but its declaration appears after the insertion component.\n markTransplantedViewsForRefresh(lView);\n }\n runEffectsInView(lView);\n detectChangesInEmbeddedViews(lView, 0 /* ChangeDetectionMode.Global */);\n // Content query results must be refreshed before content hooks are called.\n if (tView.contentQueries !== null) {\n refreshContentQueries(tView, lView);\n }\n // execute content hooks (AfterContentInit, AfterContentChecked)\n // PERF WARNING: do NOT extract this to a separate function without running benchmarks\n if (!isInCheckNoChangesPass) {\n if (hooksInitPhaseCompleted) {\n const contentCheckHooks = tView.contentCheckHooks;\n if (contentCheckHooks !== null) {\n executeCheckHooks(lView, contentCheckHooks);\n }\n } else {\n const contentHooks = tView.contentHooks;\n if (contentHooks !== null) {\n executeInitAndCheckHooks(lView, contentHooks, 1 /* InitPhaseState.AfterContentInitHooksToBeRun */);\n }\n incrementInitPhaseFlags(lView, 1 /* InitPhaseState.AfterContentInitHooksToBeRun */);\n }\n }\n processHostBindingOpCodes(tView, lView);\n // Refresh child component views.\n const components = tView.components;\n if (components !== null) {\n detectChangesInChildComponents(lView, components, 0 /* ChangeDetectionMode.Global */);\n }\n // View queries must execute after refreshing child components because a template in this view\n // could be inserted in a child component. If the view query executes before child component\n // refresh, the template might not yet be inserted.\n const viewQuery = tView.viewQuery;\n if (viewQuery !== null) {\n executeViewQueryFn(2 /* RenderFlags.Update */, viewQuery, context);\n }\n // execute view hooks (AfterViewInit, AfterViewChecked)\n // PERF WARNING: do NOT extract this to a separate function without running benchmarks\n if (!isInCheckNoChangesPass) {\n if (hooksInitPhaseCompleted) {\n const viewCheckHooks = tView.viewCheckHooks;\n if (viewCheckHooks !== null) {\n executeCheckHooks(lView, viewCheckHooks);\n }\n } else {\n const viewHooks = tView.viewHooks;\n if (viewHooks !== null) {\n executeInitAndCheckHooks(lView, viewHooks, 2 /* InitPhaseState.AfterViewInitHooksToBeRun */);\n }\n incrementInitPhaseFlags(lView, 2 /* InitPhaseState.AfterViewInitHooksToBeRun */);\n }\n }\n if (tView.firstUpdatePass === true) {\n // We need to make sure that we only flip the flag on successful `refreshView` only\n // Don't do this in `finally` block.\n // If we did this in `finally` block then an exception could block the execution of styling\n // instructions which in turn would be unable to insert themselves into the styling linked\n // list. The result of this would be that if the exception would not be throw on subsequent CD\n // the styling would be unable to process it data and reflect to the DOM.\n tView.firstUpdatePass = false;\n }\n // Schedule any effects that are waiting on the update pass of this view.\n if (lView[EFFECTS_TO_SCHEDULE]) {\n for (const notifyEffect of lView[EFFECTS_TO_SCHEDULE]) {\n notifyEffect();\n }\n // Once they've been run, we can drop the array.\n lView[EFFECTS_TO_SCHEDULE] = null;\n }\n // Do not reset the dirty state when running in check no changes mode. We don't want components\n // to behave differently depending on whether check no changes is enabled or not. For example:\n // Marking an OnPush component as dirty from within the `ngAfterViewInit` hook in order to\n // refresh a `NgClass` binding should work. If we would reset the dirty state in the check\n // no changes cycle, the component would be not be dirty for the next update pass. This would\n // be different in production mode where the component dirty state is not reset.\n if (!isInCheckNoChangesPass) {\n addAfterRenderSequencesForView(lView);\n lView[FLAGS] &= ~(64 /* LViewFlags.Dirty */ | 8 /* LViewFlags.FirstLViewPass */);\n }\n } catch (e) {\n if (!isInCheckNoChangesPass) {\n // If refreshing a view causes an error, we need to remark the ancestors as needing traversal\n // because the error might have caused a situation where views below the current location are\n // dirty but will be unreachable because the \"has dirty children\" flag in the ancestors has been\n // cleared during change detection and we failed to run to completion.\n markAncestorsForTraversal(lView);\n }\n throw e;\n } finally {\n if (currentConsumer !== null) {\n consumerAfterComputation$1(currentConsumer, prevConsumer);\n if (returnConsumerToPool) {\n maybeReturnReactiveLViewConsumer(currentConsumer);\n }\n }\n leaveView();\n }\n}\n/**\n * Goes over embedded views (ones created through ViewContainerRef APIs) and refreshes\n * them by executing an associated template function.\n */\nfunction detectChangesInEmbeddedViews(lView, mode) {\n for (let lContainer = getFirstLContainer(lView); lContainer !== null; lContainer = getNextLContainer(lContainer)) {\n for (let i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {\n const embeddedLView = lContainer[i];\n detectChangesInViewIfAttached(embeddedLView, mode);\n }\n }\n}\n/**\n * Mark transplanted views as needing to be refreshed at their attachment points.\n *\n * @param lView The `LView` that may have transplanted views.\n */\nfunction markTransplantedViewsForRefresh(lView) {\n for (let lContainer = getFirstLContainer(lView); lContainer !== null; lContainer = getNextLContainer(lContainer)) {\n if (!(lContainer[FLAGS] & 2 /* LContainerFlags.HasTransplantedViews */)) continue;\n const movedViews = lContainer[MOVED_VIEWS];\n ngDevMode && assertDefined(movedViews, 'Transplanted View flags set but missing MOVED_VIEWS');\n for (let i = 0; i < movedViews.length; i++) {\n const movedLView = movedViews[i];\n markViewForRefresh(movedLView);\n }\n }\n}\n/**\n * Detects changes in a component by entering the component view and processing its bindings,\n * queries, etc. if it is CheckAlways, OnPush and Dirty, etc.\n *\n * @param componentHostIdx Element index in LView[] (adjusted for HEADER_OFFSET)\n */\nfunction detectChangesInComponent(hostLView, componentHostIdx, mode) {\n ngDevMode && assertEqual(isCreationMode(hostLView), false, 'Should be run in update mode');\n profiler(18 /* ProfilerEvent.ComponentStart */);\n const componentView = getComponentLViewByIndex(componentHostIdx, hostLView);\n detectChangesInViewIfAttached(componentView, mode);\n profiler(19 /* ProfilerEvent.ComponentEnd */, componentView[CONTEXT]);\n}\n/**\n * Visits a view as part of change detection traversal.\n *\n * If the view is detached, no additional traversal happens.\n */\nfunction detectChangesInViewIfAttached(lView, mode) {\n if (!viewAttachedToChangeDetector(lView)) {\n return;\n }\n detectChangesInView(lView, mode);\n}\n/**\n * Visits a view as part of change detection traversal.\n *\n * The view is refreshed if:\n * - If the view is CheckAlways or Dirty and ChangeDetectionMode is `Global`\n * - If the view has the `RefreshView` flag\n *\n * The view is not refreshed, but descendants are traversed in `ChangeDetectionMode.Targeted` if the\n * view HasChildViewsToRefresh flag is set.\n */\nfunction detectChangesInView(lView, mode) {\n const isInCheckNoChangesPass = ngDevMode && isInCheckNoChangesMode();\n const tView = lView[TVIEW];\n const flags = lView[FLAGS];\n const consumer = lView[REACTIVE_TEMPLATE_CONSUMER];\n // Refresh CheckAlways views in Global mode.\n let shouldRefreshView = !!(mode === 0 /* ChangeDetectionMode.Global */ && flags & 16 /* LViewFlags.CheckAlways */);\n // Refresh Dirty views in Global mode, as long as we're not in checkNoChanges.\n // CheckNoChanges never worked with `OnPush` components because the `Dirty` flag was\n // cleared before checkNoChanges ran. Because there is now a loop for to check for\n // backwards views, it gives an opportunity for `OnPush` components to be marked `Dirty`\n // before the CheckNoChanges pass. We don't want existing errors that are hidden by the\n // current CheckNoChanges bug to surface when making unrelated changes.\n shouldRefreshView ||= !!(flags & 64 /* LViewFlags.Dirty */ && mode === 0 /* ChangeDetectionMode.Global */ && !isInCheckNoChangesPass);\n // Always refresh views marked for refresh, regardless of mode.\n shouldRefreshView ||= !!(flags & 1024 /* LViewFlags.RefreshView */);\n // Refresh views when they have a dirty reactive consumer, regardless of mode.\n shouldRefreshView ||= !!(consumer?.dirty && consumerPollProducersForChange$1(consumer));\n shouldRefreshView ||= !!(ngDevMode && isExhaustiveCheckNoChanges());\n // Mark the Flags and `ReactiveNode` as not dirty before refreshing the component, so that they\n // can be re-dirtied during the refresh process.\n if (consumer) {\n consumer.dirty = false;\n }\n lView[FLAGS] &= ~(8192 /* LViewFlags.HasChildViewsToRefresh */ | 1024 /* LViewFlags.RefreshView */);\n if (shouldRefreshView) {\n refreshView(tView, lView, tView.template, lView[CONTEXT]);\n } else if (flags & 8192 /* LViewFlags.HasChildViewsToRefresh */) {\n if (!isInCheckNoChangesPass) {\n runEffectsInView(lView);\n }\n detectChangesInEmbeddedViews(lView, 1 /* ChangeDetectionMode.Targeted */);\n const components = tView.components;\n if (components !== null) {\n detectChangesInChildComponents(lView, components, 1 /* ChangeDetectionMode.Targeted */);\n }\n if (!isInCheckNoChangesPass) {\n addAfterRenderSequencesForView(lView);\n }\n }\n}\n/** Refreshes child components in the current view (update mode). */\nfunction detectChangesInChildComponents(hostLView, components, mode) {\n for (let i = 0; i < components.length; i++) {\n detectChangesInComponent(hostLView, components[i], mode);\n }\n}\n/**\n * Invoke `HostBindingsFunction`s for view.\n *\n * This methods executes `TView.hostBindingOpCodes`. It is used to execute the\n * `HostBindingsFunction`s associated with the current `LView`.\n *\n * @param tView Current `TView`.\n * @param lView Current `LView`.\n */\nfunction processHostBindingOpCodes(tView, lView) {\n const hostBindingOpCodes = tView.hostBindingOpCodes;\n if (hostBindingOpCodes === null) return;\n try {\n for (let i = 0; i < hostBindingOpCodes.length; i++) {\n const opCode = hostBindingOpCodes[i];\n if (opCode < 0) {\n // Negative numbers are element indexes.\n setSelectedIndex(~opCode);\n } else {\n // Positive numbers are NumberTuple which store bindingRootIndex and directiveIndex.\n const directiveIdx = opCode;\n const bindingRootIndx = hostBindingOpCodes[++i];\n const hostBindingFn = hostBindingOpCodes[++i];\n setBindingRootForHostBindings(bindingRootIndx, directiveIdx);\n const context = lView[directiveIdx];\n profiler(24 /* ProfilerEvent.HostBindingsUpdateStart */, context);\n hostBindingFn(2 /* RenderFlags.Update */, context);\n profiler(25 /* ProfilerEvent.HostBindingsUpdateEnd */, context);\n }\n }\n } finally {\n setSelectedIndex(-1);\n }\n}\n\n/**\n * Marks current view and all ancestors dirty.\n *\n * Returns the root view because it is found as a byproduct of marking the view tree\n * dirty, and can be used by methods that consume markViewDirty() to easily schedule\n * change detection. Otherwise, such methods would need to traverse up the view tree\n * an additional time to get the root view and schedule a tick on it.\n *\n * @param lView The starting LView to mark dirty\n * @returns the root LView\n */\nfunction markViewDirty(lView, source) {\n const dirtyBitsToUse = isRefreshingViews() ?\n // When we are actively refreshing views, we only use the `Dirty` bit to mark a view\n 64 /* LViewFlags.Dirty */ :\n // When we are not actively refreshing a view tree, it is absolutely\n // valid to update state and mark views dirty. We use the `RefreshView` flag in this\n // case to allow synchronously rerunning change detection. This applies today to\n // afterRender hooks as well as animation listeners which execute after detecting\n // changes in a view when the render factory flushes.\n 1024 /* LViewFlags.RefreshView */ | 64 /* LViewFlags.Dirty */;\n lView[ENVIRONMENT].changeDetectionScheduler?.notify(source);\n while (lView) {\n lView[FLAGS] |= dirtyBitsToUse;\n const parent = getLViewParent(lView);\n // Stop traversing up as soon as you find a root view that wasn't attached to any container\n if (isRootView(lView) && !parent) {\n return lView;\n }\n // continue otherwise\n lView = parent;\n }\n return null;\n}\n\n/**\n * Creates a LContainer, either from a container instruction, or for a ViewContainerRef.\n *\n * @param hostNative The host element for the LContainer\n * @param hostTNode The host TNode for the LContainer\n * @param currentView The parent view of the LContainer\n * @param native The native comment element\n * @param isForViewContainerRef Optional a flag indicating the ViewContainerRef case\n * @returns LContainer\n */\nfunction createLContainer(hostNative, currentView, native, tNode) {\n ngDevMode && assertLView(currentView);\n const lContainer = [hostNative,\n // host native\n true,\n // Boolean `true` in this position signifies that this is an `LContainer`\n 0,\n // flags\n currentView,\n // parent\n null,\n // next\n tNode,\n // t_host\n null,\n // dehydrated views\n native,\n // native,\n null,\n // view refs\n null // moved views\n ];\n ngDevMode && assertEqual(lContainer.length, CONTAINER_HEADER_OFFSET, 'Should allocate correct number of slots for LContainer header.');\n return lContainer;\n}\nfunction getLViewFromLContainer(lContainer, index) {\n const adjustedIndex = CONTAINER_HEADER_OFFSET + index;\n // avoid reading past the array boundaries\n if (adjustedIndex < lContainer.length) {\n const lView = lContainer[adjustedIndex];\n ngDevMode && assertLView(lView);\n return lView;\n }\n return undefined;\n}\nfunction addLViewToLContainer(lContainer, lView, index, addToDOM = true) {\n const tView = lView[TVIEW];\n // Insert into the view tree so the new view can be change-detected\n insertView(tView, lView, lContainer, index);\n // Insert elements that belong to this view into the DOM tree\n if (addToDOM) {\n const beforeNode = getBeforeNodeForView(index, lContainer);\n const renderer = lView[RENDERER];\n const parentRNode = renderer.parentNode(lContainer[NATIVE]);\n if (parentRNode !== null) {\n addViewToDOM(tView, lContainer[T_HOST], renderer, lView, parentRNode, beforeNode);\n }\n }\n // When in hydration mode, reset the pointer to the first child in\n // the dehydrated view. This indicates that the view was hydrated and\n // further attaching/detaching should work with this view as normal.\n const hydrationInfo = lView[HYDRATION];\n if (hydrationInfo !== null && hydrationInfo.firstChild !== null) {\n hydrationInfo.firstChild = null;\n }\n}\nfunction removeLViewFromLContainer(lContainer, index) {\n const lView = detachView(lContainer, index);\n if (lView !== undefined) {\n destroyLView(lView[TVIEW], lView);\n }\n return lView;\n}\n/**\n * Detaches a view from a container.\n *\n * This method removes the view from the container's array of active views. It also\n * removes the view's elements from the DOM.\n *\n * @param lContainer The container from which to detach a view\n * @param removeIndex The index of the view to detach\n * @returns Detached LView instance.\n */\nfunction detachView(lContainer, removeIndex) {\n if (lContainer.length <= CONTAINER_HEADER_OFFSET) return;\n const indexInContainer = CONTAINER_HEADER_OFFSET + removeIndex;\n const viewToDetach = lContainer[indexInContainer];\n if (viewToDetach) {\n const declarationLContainer = viewToDetach[DECLARATION_LCONTAINER];\n if (declarationLContainer !== null && declarationLContainer !== lContainer) {\n detachMovedView(declarationLContainer, viewToDetach);\n }\n if (removeIndex > 0) {\n lContainer[indexInContainer - 1][NEXT] = viewToDetach[NEXT];\n }\n const removedLView = removeFromArray(lContainer, CONTAINER_HEADER_OFFSET + removeIndex);\n removeViewFromDOM(viewToDetach[TVIEW], viewToDetach);\n // notify query that a view has been removed\n const lQueries = removedLView[QUERIES];\n if (lQueries !== null) {\n lQueries.detachView(removedLView[TVIEW]);\n }\n viewToDetach[PARENT] = null;\n viewToDetach[NEXT] = null;\n // Unsets the attached flag\n viewToDetach[FLAGS] &= ~128 /* LViewFlags.Attached */;\n }\n return viewToDetach;\n}\n/**\n * Inserts a view into a container.\n *\n * This adds the view to the container's array of active views in the correct\n * position. It also adds the view's elements to the DOM if the container isn't a\n * root node of another view (in that case, the view's elements will be added when\n * the container's parent view is added later).\n *\n * @param tView The `TView' of the `LView` to insert\n * @param lView The view to insert\n * @param lContainer The container into which the view should be inserted\n * @param index Which index in the container to insert the child view into\n */\nfunction insertView(tView, lView, lContainer, index) {\n ngDevMode && assertLView(lView);\n ngDevMode && assertLContainer(lContainer);\n const indexInContainer = CONTAINER_HEADER_OFFSET + index;\n const containerLength = lContainer.length;\n if (index > 0) {\n // This is a new view, we need to add it to the children.\n lContainer[indexInContainer - 1][NEXT] = lView;\n }\n if (index < containerLength - CONTAINER_HEADER_OFFSET) {\n lView[NEXT] = lContainer[indexInContainer];\n addToArray(lContainer, CONTAINER_HEADER_OFFSET + index, lView);\n } else {\n lContainer.push(lView);\n lView[NEXT] = null;\n }\n lView[PARENT] = lContainer;\n // track views where declaration and insertion points are different\n const declarationLContainer = lView[DECLARATION_LCONTAINER];\n if (declarationLContainer !== null && lContainer !== declarationLContainer) {\n trackMovedView(declarationLContainer, lView);\n }\n // notify query that a new view has been added\n const lQueries = lView[QUERIES];\n if (lQueries !== null) {\n lQueries.insertView(tView);\n }\n updateAncestorTraversalFlagsOnAttach(lView);\n // Sets the attached flag\n lView[FLAGS] |= 128 /* LViewFlags.Attached */;\n}\n/**\n * Track views created from the declaration container (TemplateRef) and inserted into a\n * different LContainer or attached directly to ApplicationRef.\n */\nfunction trackMovedView(declarationContainer, lView) {\n ngDevMode && assertDefined(lView, 'LView required');\n ngDevMode && assertLContainer(declarationContainer);\n const movedViews = declarationContainer[MOVED_VIEWS];\n const parent = lView[PARENT];\n ngDevMode && assertDefined(parent, 'missing parent');\n if (isLView(parent)) {\n declarationContainer[FLAGS] |= 2 /* LContainerFlags.HasTransplantedViews */;\n } else {\n const insertedComponentLView = parent[PARENT][DECLARATION_COMPONENT_VIEW];\n ngDevMode && assertDefined(insertedComponentLView, 'Missing insertedComponentLView');\n const declaredComponentLView = lView[DECLARATION_COMPONENT_VIEW];\n ngDevMode && assertDefined(declaredComponentLView, 'Missing declaredComponentLView');\n if (declaredComponentLView !== insertedComponentLView) {\n // At this point the declaration-component is not same as insertion-component; this means that\n // this is a transplanted view. Mark the declared lView as having transplanted views so that\n // those views can participate in CD.\n declarationContainer[FLAGS] |= 2 /* LContainerFlags.HasTransplantedViews */;\n }\n }\n if (movedViews === null) {\n declarationContainer[MOVED_VIEWS] = [lView];\n } else {\n movedViews.push(lView);\n }\n}\nclass ViewRef$1 {\n _lView;\n _cdRefInjectingView;\n notifyErrorHandler;\n _appRef = null;\n _attachedToViewContainer = false;\n get rootNodes() {\n const lView = this._lView;\n const tView = lView[TVIEW];\n return collectNativeNodes(tView, lView, tView.firstChild, []);\n }\n constructor(\n /**\n * This represents `LView` associated with the component when ViewRef is a ChangeDetectorRef.\n *\n * When ViewRef is created for a dynamic component, this also represents the `LView` for the\n * component.\n *\n * For a \"regular\" ViewRef created for an embedded view, this is the `LView` for the embedded\n * view.\n *\n * @internal\n */\n _lView,\n /**\n * This represents the `LView` associated with the point where `ChangeDetectorRef` was\n * requested.\n *\n * This may be different from `_lView` if the `_cdRefInjectingView` is an embedded view.\n */\n _cdRefInjectingView, notifyErrorHandler = true) {\n this._lView = _lView;\n this._cdRefInjectingView = _cdRefInjectingView;\n this.notifyErrorHandler = notifyErrorHandler;\n }\n get context() {\n return this._lView[CONTEXT];\n }\n /**\n * @deprecated Replacing the full context object is not supported. Modify the context\n * directly, or consider using a `Proxy` if you need to replace the full object.\n * // TODO(devversion): Remove this.\n */\n set context(value) {\n if (ngDevMode) {\n // Note: We have a warning message here because the `@deprecated` JSDoc will not be picked\n // up for assignments on the setter. We want to let users know about the deprecated usage.\n console.warn('Angular: Replacing the `context` object of an `EmbeddedViewRef` is deprecated.');\n }\n this._lView[CONTEXT] = value;\n }\n get destroyed() {\n return isDestroyed(this._lView);\n }\n destroy() {\n if (this._appRef) {\n this._appRef.detachView(this);\n } else if (this._attachedToViewContainer) {\n const parent = this._lView[PARENT];\n if (isLContainer(parent)) {\n const viewRefs = parent[VIEW_REFS];\n const index = viewRefs ? viewRefs.indexOf(this) : -1;\n if (index > -1) {\n ngDevMode && assertEqual(index, parent.indexOf(this._lView) - CONTAINER_HEADER_OFFSET, 'An attached view should be in the same position within its container as its ViewRef in the VIEW_REFS array.');\n detachView(parent, index);\n removeFromArray(viewRefs, index);\n }\n }\n this._attachedToViewContainer = false;\n }\n destroyLView(this._lView[TVIEW], this._lView);\n }\n onDestroy(callback) {\n storeLViewOnDestroy(this._lView, callback);\n }\n /**\n * Marks a view and all of its ancestors dirty.\n *\n * This can be used to ensure an {@link ChangeDetectionStrategy#OnPush} component is\n * checked when it needs to be re-rendered but the two normal triggers haven't marked it\n * dirty (i.e. inputs haven't changed and events haven't fired in the view).\n *\n * <!-- TODO: Add a link to a chapter on OnPush components -->\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * @Component({\n * selector: 'app-root',\n * template: `Number of ticks: {{numberOfTicks}}`\n * changeDetection: ChangeDetectionStrategy.OnPush,\n * })\n * class AppComponent {\n * numberOfTicks = 0;\n *\n * constructor(private ref: ChangeDetectorRef) {\n * setInterval(() => {\n * this.numberOfTicks++;\n * // the following is required, otherwise the view will not be updated\n * this.ref.markForCheck();\n * }, 1000);\n * }\n * }\n * ```\n */\n markForCheck() {\n markViewDirty(this._cdRefInjectingView || this._lView, 4 /* NotificationSource.MarkForCheck */);\n }\n /**\n * Detaches the view from the change detection tree.\n *\n * Detached views will not be checked during change detection runs until they are\n * re-attached, even if they are dirty. `detach` can be used in combination with\n * {@link ChangeDetectorRef#detectChanges} to implement local change\n * detection checks.\n *\n * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->\n * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->\n *\n * @usageNotes\n * ### Example\n *\n * The following example defines a component with a large list of readonly data.\n * Imagine the data changes constantly, many times per second. For performance reasons,\n * we want to check and update the list every five seconds. We can do that by detaching\n * the component's change detector and doing a local check every five seconds.\n *\n * ```ts\n * class DataProvider {\n * // in a real application the returned data will be different every time\n * get data() {\n * return [1,2,3,4,5];\n * }\n * }\n *\n * @Component({\n * selector: 'giant-list',\n * template: `\n * <li *ngFor=\"let d of dataProvider.data\">Data {{d}}</li>\n * `,\n * })\n * class GiantList {\n * constructor(private ref: ChangeDetectorRef, private dataProvider: DataProvider) {\n * ref.detach();\n * setInterval(() => {\n * this.ref.detectChanges();\n * }, 5000);\n * }\n * }\n *\n * @Component({\n * selector: 'app',\n * providers: [DataProvider],\n * template: `\n * <giant-list><giant-list>\n * `,\n * })\n * class App {\n * }\n * ```\n */\n detach() {\n this._lView[FLAGS] &= ~128 /* LViewFlags.Attached */;\n }\n /**\n * Re-attaches a view to the change detection tree.\n *\n * This can be used to re-attach views that were previously detached from the tree\n * using {@link ChangeDetectorRef#detach}. Views are attached to the tree by default.\n *\n * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->\n *\n * @usageNotes\n * ### Example\n *\n * The following example creates a component displaying `live` data. The component will detach\n * its change detector from the main change detector tree when the component's live property\n * is set to false.\n *\n * ```ts\n * class DataProvider {\n * data = 1;\n *\n * constructor() {\n * setInterval(() => {\n * this.data = this.data * 2;\n * }, 500);\n * }\n * }\n *\n * @Component({\n * selector: 'live-data',\n * inputs: ['live'],\n * template: 'Data: {{dataProvider.data}}'\n * })\n * class LiveData {\n * constructor(private ref: ChangeDetectorRef, private dataProvider: DataProvider) {}\n *\n * set live(value) {\n * if (value) {\n * this.ref.reattach();\n * } else {\n * this.ref.detach();\n * }\n * }\n * }\n *\n * @Component({\n * selector: 'app-root',\n * providers: [DataProvider],\n * template: `\n * Live Update: <input type=\"checkbox\" [(ngModel)]=\"live\">\n * <live-data [live]=\"live\"><live-data>\n * `,\n * })\n * class AppComponent {\n * live = true;\n * }\n * ```\n */\n reattach() {\n updateAncestorTraversalFlagsOnAttach(this._lView);\n this._lView[FLAGS] |= 128 /* LViewFlags.Attached */;\n }\n /**\n * Checks the view and its children.\n *\n * This can also be used in combination with {@link ChangeDetectorRef#detach} to implement\n * local change detection checks.\n *\n * <!-- TODO: Add a link to a chapter on detach/reattach/local digest -->\n * <!-- TODO: Add a live demo once ref.detectChanges is merged into master -->\n *\n * @usageNotes\n * ### Example\n *\n * The following example defines a component with a large list of readonly data.\n * Imagine, the data changes constantly, many times per second. For performance reasons,\n * we want to check and update the list every five seconds.\n *\n * We can do that by detaching the component's change detector and doing a local change detection\n * check every five seconds.\n *\n * See {@link ChangeDetectorRef#detach} for more information.\n */\n detectChanges() {\n // Add `RefreshView` flag to ensure this view is refreshed if not already dirty.\n // `RefreshView` flag is used intentionally over `Dirty` because it gets cleared before\n // executing any of the actual refresh code while the `Dirty` flag doesn't get cleared\n // until the end of the refresh. Using `RefreshView` prevents creating a potential difference\n // in the state of the LViewFlags during template execution.\n this._lView[FLAGS] |= 1024 /* LViewFlags.RefreshView */;\n detectChangesInternal(this._lView, this.notifyErrorHandler);\n }\n /**\n * Checks the change detector and its children, and throws if any changes are detected.\n *\n * This is used in development mode to verify that running change detection doesn't\n * introduce other changes.\n */\n checkNoChanges() {\n if (ngDevMode) {\n checkNoChangesInternal(this._lView, CheckNoChangesMode.OnlyDirtyViews, this.notifyErrorHandler);\n }\n }\n attachToViewContainerRef() {\n if (this._appRef) {\n throw new RuntimeError(902 /* RuntimeErrorCode.VIEW_ALREADY_ATTACHED */, ngDevMode && 'This view is already attached directly to the ApplicationRef!');\n }\n this._attachedToViewContainer = true;\n }\n detachFromAppRef() {\n this._appRef = null;\n const isRoot = isRootView(this._lView);\n const declarationContainer = this._lView[DECLARATION_LCONTAINER];\n if (declarationContainer !== null && !isRoot) {\n detachMovedView(declarationContainer, this._lView);\n }\n detachViewFromDOM(this._lView[TVIEW], this._lView);\n }\n attachToAppRef(appRef) {\n if (this._attachedToViewContainer) {\n throw new RuntimeError(902 /* RuntimeErrorCode.VIEW_ALREADY_ATTACHED */, ngDevMode && 'This view is already attached to a ViewContainer!');\n }\n this._appRef = appRef;\n const isRoot = isRootView(this._lView);\n const declarationContainer = this._lView[DECLARATION_LCONTAINER];\n if (declarationContainer !== null && !isRoot) {\n trackMovedView(declarationContainer, this._lView);\n }\n updateAncestorTraversalFlagsOnAttach(this._lView);\n }\n}\n/**\n * Reports whether the given view is considered dirty according to the different marking mechanisms.\n */\nfunction isViewDirty(view) {\n return requiresRefreshOrTraversal(view._lView) || !!(view._lView[FLAGS] & 64 /* LViewFlags.Dirty */);\n}\nfunction markForRefresh(view) {\n markViewForRefresh(view['_cdRefInjectingView'] || view._lView);\n}\n\n/**\n * Represents an embedded template that can be used to instantiate embedded views.\n * To instantiate embedded views based on a template, use the `ViewContainerRef`\n * method `createEmbeddedView()`.\n *\n * Access a `TemplateRef` instance by placing a directive on an `<ng-template>`\n * element (or directive prefixed with `*`). The `TemplateRef` for the embedded view\n * is injected into the constructor of the directive,\n * using the `TemplateRef` token.\n *\n * You can also use a `Query` to find a `TemplateRef` associated with\n * a component or a directive.\n *\n * @see {@link ViewContainerRef}\n *\n * @publicApi\n */\nclass TemplateRef {\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = injectTemplateRef;\n}\nconst ViewEngineTemplateRef = TemplateRef;\n// TODO(alxhub): combine interface and implementation. Currently this is challenging since something\n// in g3 depends on them being separate.\nconst R3TemplateRef = class TemplateRef extends ViewEngineTemplateRef {\n _declarationLView;\n _declarationTContainer;\n elementRef;\n constructor(_declarationLView, _declarationTContainer, elementRef) {\n super();\n this._declarationLView = _declarationLView;\n this._declarationTContainer = _declarationTContainer;\n this.elementRef = elementRef;\n }\n /**\n * Returns an `ssrId` associated with a TView, which was used to\n * create this instance of the `TemplateRef`.\n *\n * @internal\n */\n get ssrId() {\n return this._declarationTContainer.tView?.ssrId || null;\n }\n createEmbeddedView(context, injector) {\n return this.createEmbeddedViewImpl(context, injector);\n }\n /**\n * @internal\n */\n createEmbeddedViewImpl(context, injector, dehydratedView) {\n const embeddedLView = createAndRenderEmbeddedLView(this._declarationLView, this._declarationTContainer, context, {\n embeddedViewInjector: injector,\n dehydratedView\n });\n return new ViewRef$1(embeddedLView);\n }\n};\n/**\n * Creates a TemplateRef given a node.\n *\n * @returns The TemplateRef instance to use\n */\nfunction injectTemplateRef() {\n return createTemplateRef(getCurrentTNode(), getLView());\n}\n/**\n * Creates a TemplateRef and stores it on the injector.\n *\n * @param hostTNode The node on which a TemplateRef is requested\n * @param hostLView The `LView` to which the node belongs\n * @returns The TemplateRef instance or null if we can't create a TemplateRef on a given node type\n */\nfunction createTemplateRef(hostTNode, hostLView) {\n if (hostTNode.type & 4 /* TNodeType.Container */) {\n ngDevMode && assertDefined(hostTNode.tView, 'TView must be allocated');\n return new R3TemplateRef(hostLView, hostTNode, createElementRef(hostTNode, hostLView));\n }\n return null;\n}\nconst AT_THIS_LOCATION = '<-- AT THIS LOCATION';\n/**\n * Retrieves a user friendly string for a given TNodeType for use in\n * friendly error messages\n *\n * @param tNodeType\n * @returns\n */\nfunction getFriendlyStringFromTNodeType(tNodeType) {\n switch (tNodeType) {\n case 4 /* TNodeType.Container */:\n return 'view container';\n case 2 /* TNodeType.Element */:\n return 'element';\n case 8 /* TNodeType.ElementContainer */:\n return 'ng-container';\n case 32 /* TNodeType.Icu */:\n return 'icu';\n case 64 /* TNodeType.Placeholder */:\n return 'i18n';\n case 16 /* TNodeType.Projection */:\n return 'projection';\n case 1 /* TNodeType.Text */:\n return 'text';\n case 128 /* TNodeType.LetDeclaration */:\n return '@let';\n default:\n // This should not happen as we cover all possible TNode types above.\n return '<unknown>';\n }\n}\n/**\n * Validates that provided nodes match during the hydration process.\n */\nfunction validateMatchingNode(node, nodeType, tagName, lView, tNode, isViewContainerAnchor = false) {\n if (!node || node.nodeType !== nodeType || node.nodeType === Node.ELEMENT_NODE && node.tagName.toLowerCase() !== tagName?.toLowerCase()) {\n const expectedNode = shortRNodeDescription(nodeType, tagName, null);\n let header = `During hydration Angular expected ${expectedNode} but `;\n const hostComponentDef = getDeclarationComponentDef(lView);\n const componentClassName = hostComponentDef?.type?.name;\n const expectedDom = describeExpectedDom(lView, tNode, isViewContainerAnchor);\n const expected = `Angular expected this DOM:\\n\\n${expectedDom}\\n\\n`;\n let actual = '';\n const componentHostElement = unwrapRNode(lView[HOST]);\n if (!node) {\n // No node found during hydration.\n header += `the node was not found.\\n\\n`;\n // Since the node is missing, we use the closest node to attach the error to\n markRNodeAsHavingHydrationMismatch(componentHostElement, expectedDom);\n } else {\n const actualNode = shortRNodeDescription(node.nodeType, node.tagName ?? null, node.textContent ?? null);\n header += `found ${actualNode}.\\n\\n`;\n const actualDom = describeDomFromNode(node);\n actual = `Actual DOM is:\\n\\n${actualDom}\\n\\n`;\n // DevTools only report hydration issues on the component level, so we attach extra debug\n // info to a component host element to make it available to DevTools.\n markRNodeAsHavingHydrationMismatch(componentHostElement, expectedDom, actualDom);\n }\n const footer = getHydrationErrorFooter(componentClassName);\n const message = header + expected + actual + getHydrationAttributeNote() + footer;\n throw new RuntimeError(-500 /* RuntimeErrorCode.HYDRATION_NODE_MISMATCH */, message);\n }\n}\n/**\n * Validates that a given node has sibling nodes\n */\nfunction validateSiblingNodeExists(node) {\n validateNodeExists(node);\n if (!node.nextSibling) {\n const header = 'During hydration Angular expected more sibling nodes to be present.\\n\\n';\n const actual = `Actual DOM is:\\n\\n${describeDomFromNode(node)}\\n\\n`;\n const footer = getHydrationErrorFooter();\n const message = header + actual + footer;\n markRNodeAsHavingHydrationMismatch(node, '', actual);\n throw new RuntimeError(-501 /* RuntimeErrorCode.HYDRATION_MISSING_SIBLINGS */, message);\n }\n}\n/**\n * Validates that a node exists or throws\n */\nfunction validateNodeExists(node, lView = null, tNode = null) {\n if (!node) {\n const header = 'During hydration, Angular expected an element to be present at this location.\\n\\n';\n let expected = '';\n let footer = '';\n if (lView !== null && tNode !== null) {\n expected = describeExpectedDom(lView, tNode, false);\n footer = getHydrationErrorFooter();\n // Since the node is missing, we use the closest node to attach the error to\n markRNodeAsHavingHydrationMismatch(unwrapRNode(lView[HOST]), expected, '');\n }\n throw new RuntimeError(-502 /* RuntimeErrorCode.HYDRATION_MISSING_NODE */, `${header}${expected}\\n\\n${footer}`);\n }\n}\n/**\n * Builds the hydration error message when a node is not found\n *\n * @param lView the LView where the node exists\n * @param tNode the TNode\n */\nfunction nodeNotFoundError(lView, tNode) {\n const header = 'During serialization, Angular was unable to find an element in the DOM:\\n\\n';\n const expected = `${describeExpectedDom(lView, tNode, false)}\\n\\n`;\n const footer = getHydrationErrorFooter();\n throw new RuntimeError(-502 /* RuntimeErrorCode.HYDRATION_MISSING_NODE */, header + expected + footer);\n}\n/**\n * Builds a hydration error message when a node is not found at a path location\n *\n * @param host the Host Node\n * @param path the path to the node\n */\nfunction nodeNotFoundAtPathError(host, path) {\n const header = `During hydration Angular was unable to locate a node ` + `using the \"${path}\" path, starting from the ${describeRNode(host)} node.\\n\\n`;\n const footer = getHydrationErrorFooter();\n markRNodeAsHavingHydrationMismatch(host);\n throw new RuntimeError(-502 /* RuntimeErrorCode.HYDRATION_MISSING_NODE */, header + footer);\n}\n/**\n * Builds the hydration error message in the case that dom nodes are created outside of\n * the Angular context and are being used as projected nodes\n *\n * @param lView the LView\n * @param tNode the TNode\n * @returns an error\n */\nfunction unsupportedProjectionOfDomNodes(rNode) {\n const header = 'During serialization, Angular detected DOM nodes ' + 'that were created outside of Angular context and provided as projectable nodes ' + '(likely via `ViewContainerRef.createComponent` or `createComponent` APIs). ' + 'Hydration is not supported for such cases, consider refactoring the code to avoid ' + 'this pattern or using `ngSkipHydration` on the host element of the component.\\n\\n';\n const actual = `${describeDomFromNode(rNode)}\\n\\n`;\n const message = header + actual + getHydrationAttributeNote();\n return new RuntimeError(-503 /* RuntimeErrorCode.UNSUPPORTED_PROJECTION_DOM_NODES */, message);\n}\n/**\n * Builds the hydration error message in the case that ngSkipHydration was used on a\n * node that is not a component host element or host binding\n *\n * @param rNode the HTML Element\n * @returns an error\n */\nfunction invalidSkipHydrationHost(rNode) {\n const header = 'The `ngSkipHydration` flag is applied on a node ' + \"that doesn't act as a component host. Hydration can be \" + 'skipped only on per-component basis.\\n\\n';\n const actual = `${describeDomFromNode(rNode)}\\n\\n`;\n const footer = 'Please move the `ngSkipHydration` attribute to the component host element.\\n\\n';\n const message = header + actual + footer;\n return new RuntimeError(-504 /* RuntimeErrorCode.INVALID_SKIP_HYDRATION_HOST */, message);\n}\n// Stringification methods\n/**\n * Stringifies a given TNode's attributes\n *\n * @param tNode a provided TNode\n * @returns string\n */\nfunction stringifyTNodeAttrs(tNode) {\n const results = [];\n if (tNode.attrs) {\n for (let i = 0; i < tNode.attrs.length;) {\n const attrName = tNode.attrs[i++];\n // Once we reach the first flag, we know that the list of\n // attributes is over.\n if (typeof attrName == 'number') {\n break;\n }\n const attrValue = tNode.attrs[i++];\n results.push(`${attrName}=\"${shorten(attrValue)}\"`);\n }\n }\n return results.join(' ');\n}\n/**\n * The list of internal attributes that should be filtered out while\n * producing an error message.\n */\nconst internalAttrs = new Set(['ngh', 'ng-version', 'ng-server-context']);\n/**\n * Stringifies an HTML Element's attributes\n *\n * @param rNode an HTML Element\n * @returns string\n */\nfunction stringifyRNodeAttrs(rNode) {\n const results = [];\n for (let i = 0; i < rNode.attributes.length; i++) {\n const attr = rNode.attributes[i];\n if (internalAttrs.has(attr.name)) continue;\n results.push(`${attr.name}=\"${shorten(attr.value)}\"`);\n }\n return results.join(' ');\n}\n// Methods for Describing the DOM\n/**\n * Converts a tNode to a helpful readable string value for use in error messages\n *\n * @param tNode a given TNode\n * @param innerContent the content of the node\n * @returns string\n */\nfunction describeTNode(tNode, innerContent = '…') {\n switch (tNode.type) {\n case 1 /* TNodeType.Text */:\n const content = tNode.value ? `(${tNode.value})` : '';\n return `#text${content}`;\n case 2 /* TNodeType.Element */:\n const attrs = stringifyTNodeAttrs(tNode);\n const tag = tNode.value.toLowerCase();\n return `<${tag}${attrs ? ' ' + attrs : ''}>${innerContent}</${tag}>`;\n case 8 /* TNodeType.ElementContainer */:\n return '<!-- ng-container -->';\n case 4 /* TNodeType.Container */:\n return '<!-- container -->';\n default:\n const typeAsString = getFriendlyStringFromTNodeType(tNode.type);\n return `#node(${typeAsString})`;\n }\n}\n/**\n * Converts an RNode to a helpful readable string value for use in error messages\n *\n * @param rNode a given RNode\n * @param innerContent the content of the node\n * @returns string\n */\nfunction describeRNode(rNode, innerContent = '…') {\n const node = rNode;\n switch (node.nodeType) {\n case Node.ELEMENT_NODE:\n const tag = node.tagName.toLowerCase();\n const attrs = stringifyRNodeAttrs(node);\n return `<${tag}${attrs ? ' ' + attrs : ''}>${innerContent}</${tag}>`;\n case Node.TEXT_NODE:\n const content = node.textContent ? shorten(node.textContent) : '';\n return `#text${content ? `(${content})` : ''}`;\n case Node.COMMENT_NODE:\n return `<!-- ${shorten(node.textContent ?? '')} -->`;\n default:\n return `#node(${node.nodeType})`;\n }\n}\n/**\n * Builds the string containing the expected DOM present given the LView and TNode\n * values for a readable error message\n *\n * @param lView the lView containing the DOM\n * @param tNode the tNode\n * @param isViewContainerAnchor boolean\n * @returns string\n */\nfunction describeExpectedDom(lView, tNode, isViewContainerAnchor) {\n const spacer = ' ';\n let content = '';\n if (tNode.prev) {\n content += spacer + '…\\n';\n content += spacer + describeTNode(tNode.prev) + '\\n';\n } else if (tNode.type && tNode.type & 12 /* TNodeType.AnyContainer */) {\n content += spacer + '…\\n';\n }\n if (isViewContainerAnchor) {\n content += spacer + describeTNode(tNode) + '\\n';\n content += spacer + `<!-- container --> ${AT_THIS_LOCATION}\\n`;\n } else {\n content += spacer + describeTNode(tNode) + ` ${AT_THIS_LOCATION}\\n`;\n }\n content += spacer + '…\\n';\n const parentRNode = tNode.type ? getParentRElement(lView[TVIEW], tNode, lView) : null;\n if (parentRNode) {\n content = describeRNode(parentRNode, '\\n' + content);\n }\n return content;\n}\n/**\n * Builds the string containing the DOM present around a given RNode for a\n * readable error message\n *\n * @param node the RNode\n * @returns string\n */\nfunction describeDomFromNode(node) {\n const spacer = ' ';\n let content = '';\n const currentNode = node;\n if (currentNode.previousSibling) {\n content += spacer + '…\\n';\n content += spacer + describeRNode(currentNode.previousSibling) + '\\n';\n }\n content += spacer + describeRNode(currentNode) + ` ${AT_THIS_LOCATION}\\n`;\n if (node.nextSibling) {\n content += spacer + '…\\n';\n }\n if (node.parentNode) {\n content = describeRNode(currentNode.parentNode, '\\n' + content);\n }\n return content;\n}\n/**\n * Shortens the description of a given RNode by its type for readability\n *\n * @param nodeType the type of node\n * @param tagName the node tag name\n * @param textContent the text content in the node\n * @returns string\n */\nfunction shortRNodeDescription(nodeType, tagName, textContent) {\n switch (nodeType) {\n case Node.ELEMENT_NODE:\n return `<${tagName.toLowerCase()}>`;\n case Node.TEXT_NODE:\n const content = textContent ? ` (with the \"${shorten(textContent)}\" content)` : '';\n return `a text node${content}`;\n case Node.COMMENT_NODE:\n return 'a comment node';\n default:\n return `#node(nodeType=${nodeType})`;\n }\n}\n/**\n * Builds the footer hydration error message\n *\n * @param componentClassName the name of the component class\n * @returns string\n */\nfunction getHydrationErrorFooter(componentClassName) {\n const componentInfo = componentClassName ? `the \"${componentClassName}\"` : 'corresponding';\n return `To fix this problem:\\n` + ` * check ${componentInfo} component for hydration-related issues\\n` + ` * check to see if your template has valid HTML structure\\n` + ` * or skip hydration by adding the \\`ngSkipHydration\\` attribute ` + `to its host node in a template\\n\\n`;\n}\n/**\n * An attribute related note for hydration errors\n */\nfunction getHydrationAttributeNote() {\n return 'Note: attributes are only displayed to better represent the DOM' + ' but have no effect on hydration mismatches.\\n\\n';\n}\n// Node string utility functions\n/**\n * Strips all newlines out of a given string\n *\n * @param input a string to be cleared of new line characters\n * @returns\n */\nfunction stripNewlines(input) {\n return input.replace(/\\s+/gm, '');\n}\n/**\n * Reduces a string down to a maximum length of characters with ellipsis for readability\n *\n * @param input a string input\n * @param maxLength a maximum length in characters\n * @returns string\n */\nfunction shorten(input, maxLength = 50) {\n if (!input) {\n return '';\n }\n input = stripNewlines(input);\n return input.length > maxLength ? `${input.substring(0, maxLength - 1)}…` : input;\n}\n\n/**\n * Find a node in front of which `currentTNode` should be inserted (takes i18n into account).\n *\n * This method determines the `RNode` in front of which we should insert the `currentRNode`. This\n * takes `TNode.insertBeforeIndex` into account.\n *\n * @param parentTNode parent `TNode`\n * @param currentTNode current `TNode` (The node which we would like to insert into the DOM)\n * @param lView current `LView`\n */\nfunction getInsertInFrontOfRNodeWithI18n(parentTNode, currentTNode, lView) {\n const tNodeInsertBeforeIndex = currentTNode.insertBeforeIndex;\n const insertBeforeIndex = Array.isArray(tNodeInsertBeforeIndex) ? tNodeInsertBeforeIndex[0] : tNodeInsertBeforeIndex;\n if (insertBeforeIndex === null) {\n return getInsertInFrontOfRNodeWithNoI18n(parentTNode, currentTNode, lView);\n } else {\n ngDevMode && assertIndexInRange(lView, insertBeforeIndex);\n return unwrapRNode(lView[insertBeforeIndex]);\n }\n}\n/**\n * Process `TNode.insertBeforeIndex` by adding i18n text nodes.\n *\n * See `TNode.insertBeforeIndex`\n */\nfunction processI18nInsertBefore(renderer, childTNode, lView, childRNode, parentRElement) {\n const tNodeInsertBeforeIndex = childTNode.insertBeforeIndex;\n if (Array.isArray(tNodeInsertBeforeIndex)) {\n // An array indicates that there are i18n nodes that need to be added as children of this\n // `childRNode`. These i18n nodes were created before this `childRNode` was available and so\n // only now can be added. The first element of the array is the normal index where we should\n // insert the `childRNode`. Additional elements are the extra nodes to be added as children of\n // `childRNode`.\n ngDevMode && assertDomNode(childRNode);\n let i18nParent = childRNode;\n let anchorRNode = null;\n if (!(childTNode.type & 3 /* TNodeType.AnyRNode */)) {\n anchorRNode = i18nParent;\n i18nParent = parentRElement;\n }\n if (i18nParent !== null && childTNode.componentOffset === -1) {\n for (let i = 1; i < tNodeInsertBeforeIndex.length; i++) {\n // No need to `unwrapRNode` because all of the indexes point to i18n text nodes.\n // see `assertDomNode` below.\n const i18nChild = lView[tNodeInsertBeforeIndex[i]];\n nativeInsertBefore(renderer, i18nParent, i18nChild, anchorRNode, false);\n }\n }\n }\n}\nfunction getOrCreateTNode(tView, index, type, name, attrs) {\n ngDevMode && index !== 0 &&\n // 0 are bogus nodes and they are OK. See `createContainerRef` in\n // `view_engine_compatibility` for additional context.\n assertGreaterThanOrEqual(index, HEADER_OFFSET, \"TNodes can't be in the LView header.\");\n // Keep this function short, so that the VM will inline it.\n ngDevMode && assertPureTNodeType(type);\n let tNode = tView.data[index];\n if (tNode === null) {\n tNode = createTNodeAtIndex(tView, index, type, name, attrs);\n if (isInI18nBlock()) {\n // If we are in i18n block then all elements should be pre declared through `Placeholder`\n // See `TNodeType.Placeholder` and `LFrame.inI18n` for more context.\n // If the `TNode` was not pre-declared than it means it was not mentioned which means it was\n // removed, so we mark it as detached.\n tNode.flags |= 32 /* TNodeFlags.isDetached */;\n }\n } else if (tNode.type & 64 /* TNodeType.Placeholder */) {\n tNode.type = type;\n tNode.value = name;\n tNode.attrs = attrs;\n const parent = getCurrentParentTNode();\n tNode.injectorIndex = parent === null ? -1 : parent.injectorIndex;\n ngDevMode && assertTNodeForTView(tNode, tView);\n ngDevMode && assertEqual(index, tNode.index, 'Expecting same index');\n }\n setCurrentTNode(tNode, true);\n return tNode;\n}\nfunction createTNodeAtIndex(tView, index, type, name, attrs) {\n const currentTNode = getCurrentTNodePlaceholderOk();\n const isParent = isCurrentTNodeParent();\n const parent = isParent ? currentTNode : currentTNode && currentTNode.parent;\n // Parents cannot cross component boundaries because components will be used in multiple places.\n const tNode = tView.data[index] = createTNode(tView, parent, type, index, name, attrs);\n // Assign a pointer to the first child node of a given view. The first node is not always the one\n // at index 0, in case of i18n, index 0 can be the instruction `i18nStart` and the first node has\n // the index 1 or more, so we can't just check node index.\n linkTNodeInTView(tView, tNode, currentTNode, isParent);\n return tNode;\n}\nfunction linkTNodeInTView(tView, tNode, currentTNode, isParent) {\n if (tView.firstChild === null) {\n tView.firstChild = tNode;\n }\n if (currentTNode !== null) {\n if (isParent) {\n // FIXME(misko): This logic looks unnecessarily complicated. Could we simplify?\n if (currentTNode.child == null && tNode.parent !== null) {\n // We are in the same view, which means we are adding content node to the parent view.\n currentTNode.child = tNode;\n }\n } else {\n if (currentTNode.next === null) {\n // In the case of i18n the `currentTNode` may already be linked, in which case we don't want\n // to break the links which i18n created.\n currentTNode.next = tNode;\n tNode.prev = currentTNode;\n }\n }\n }\n}\nfunction createTNode(tView, tParent, type, index, value, attrs) {\n ngDevMode && index !== 0 &&\n // 0 are bogus nodes and they are OK. See `createContainerRef` in\n // `view_engine_compatibility` for additional context.\n assertGreaterThanOrEqual(index, HEADER_OFFSET, \"TNodes can't be in the LView header.\");\n ngDevMode && assertNotSame(attrs, undefined, \"'undefined' is not valid value for 'attrs'\");\n ngDevMode && ngDevMode.tNode++;\n ngDevMode && tParent && assertTNodeForTView(tParent, tView);\n let injectorIndex = tParent ? tParent.injectorIndex : -1;\n let flags = 0;\n if (isInSkipHydrationBlock$1()) {\n flags |= 128 /* TNodeFlags.inSkipHydrationBlock */;\n }\n // TODO: would it be helpful to use a prototypal inheritance here, similar to the way we do so with signals?\n const tNode = {\n type,\n index,\n insertBeforeIndex: null,\n injectorIndex,\n directiveStart: -1,\n directiveEnd: -1,\n directiveStylingLast: -1,\n componentOffset: -1,\n propertyBindings: null,\n flags,\n providerIndexes: 0,\n value: value,\n attrs: attrs,\n mergedAttrs: null,\n localNames: null,\n initialInputs: null,\n inputs: null,\n hostDirectiveInputs: null,\n outputs: null,\n hostDirectiveOutputs: null,\n directiveToIndex: null,\n tView: null,\n next: null,\n prev: null,\n projectionNext: null,\n child: null,\n parent: tParent,\n projection: null,\n styles: null,\n stylesWithoutHost: null,\n residualStyles: undefined,\n classes: null,\n classesWithoutHost: null,\n residualClasses: undefined,\n classBindings: 0,\n styleBindings: 0\n };\n if (ngDevMode) {\n // For performance reasons it is important that the tNode retains the same shape during runtime.\n // (To make sure that all of the code is monomorphic.) For this reason we seal the object to\n // prevent class transitions.\n Object.seal(tNode);\n }\n return tNode;\n}\n\n/**\n * Add `tNode` to `previousTNodes` list and update relevant `TNode`s in `previousTNodes` list\n * `tNode.insertBeforeIndex`.\n *\n * Things to keep in mind:\n * 1. All i18n text nodes are encoded as `TNodeType.Element` and are created eagerly by the\n * `ɵɵi18nStart` instruction.\n * 2. All `TNodeType.Placeholder` `TNodes` are elements which will be created later by\n * `ɵɵelementStart` instruction.\n * 3. `ɵɵelementStart` instruction will create `TNode`s in the ascending `TNode.index` order. (So a\n * smaller index `TNode` is guaranteed to be created before a larger one)\n *\n * We use the above three invariants to determine `TNode.insertBeforeIndex`.\n *\n * In an ideal world `TNode.insertBeforeIndex` would always be `TNode.next.index`. However,\n * this will not work because `TNode.next.index` may be larger than `TNode.index` which means that\n * the next node is not yet created and therefore we can't insert in front of it.\n *\n * Rule1: `TNode.insertBeforeIndex = null` if `TNode.next === null` (Initial condition, as we don't\n * know if there will be further `TNode`s inserted after.)\n * Rule2: If `previousTNode` is created after the `tNode` being inserted, then\n * `previousTNode.insertBeforeNode = tNode.index` (So when a new `tNode` is added we check\n * previous to see if we can update its `insertBeforeTNode`)\n *\n * See `TNode.insertBeforeIndex` for more context.\n *\n * @param previousTNodes A list of previous TNodes so that we can easily traverse `TNode`s in\n * reverse order. (If `TNode` would have `previous` this would not be necessary.)\n * @param newTNode A TNode to add to the `previousTNodes` list.\n */\nfunction addTNodeAndUpdateInsertBeforeIndex(previousTNodes, newTNode) {\n // Start with Rule1\n ngDevMode && assertEqual(newTNode.insertBeforeIndex, null, 'We expect that insertBeforeIndex is not set');\n previousTNodes.push(newTNode);\n if (previousTNodes.length > 1) {\n for (let i = previousTNodes.length - 2; i >= 0; i--) {\n const existingTNode = previousTNodes[i];\n // Text nodes are created eagerly and so they don't need their `indexBeforeIndex` updated.\n // It is safe to ignore them.\n if (!isI18nText(existingTNode)) {\n if (isNewTNodeCreatedBefore(existingTNode, newTNode) && getInsertBeforeIndex(existingTNode) === null) {\n // If it was created before us in time, (and it does not yet have `insertBeforeIndex`)\n // then add the `insertBeforeIndex`.\n setInsertBeforeIndex(existingTNode, newTNode.index);\n }\n }\n }\n }\n}\nfunction isI18nText(tNode) {\n return !(tNode.type & 64 /* TNodeType.Placeholder */);\n}\nfunction isNewTNodeCreatedBefore(existingTNode, newTNode) {\n return isI18nText(newTNode) || existingTNode.index > newTNode.index;\n}\nfunction getInsertBeforeIndex(tNode) {\n const index = tNode.insertBeforeIndex;\n return Array.isArray(index) ? index[0] : index;\n}\nfunction setInsertBeforeIndex(tNode, value) {\n const index = tNode.insertBeforeIndex;\n if (Array.isArray(index)) {\n // Array is stored if we have to insert child nodes. See `TNode.insertBeforeIndex`\n index[0] = value;\n } else {\n setI18nHandling(getInsertInFrontOfRNodeWithI18n, processI18nInsertBefore);\n tNode.insertBeforeIndex = value;\n }\n}\n\n/**\n * Retrieve `TIcu` at a given `index`.\n *\n * The `TIcu` can be stored either directly (if it is nested ICU) OR\n * it is stored inside tho `TIcuContainer` if it is top level ICU.\n *\n * The reason for this is that the top level ICU need a `TNode` so that they are part of the render\n * tree, but nested ICU's have no TNode, because we don't know ahead of time if the nested ICU is\n * expressed (parent ICU may have selected a case which does not contain it.)\n *\n * @param tView Current `TView`.\n * @param index Index where the value should be read from.\n */\nfunction getTIcu(tView, index) {\n const value = tView.data[index];\n if (value === null || typeof value === 'string') return null;\n if (ngDevMode && !(value.hasOwnProperty('tView') || value.hasOwnProperty('currentCaseLViewIndex'))) {\n throwError(\"We expect to get 'null'|'TIcu'|'TIcuContainer', but got: \" + value);\n }\n // Here the `value.hasOwnProperty('currentCaseLViewIndex')` is a polymorphic read as it can be\n // either TIcu or TIcuContainerNode. This is not ideal, but we still think it is OK because it\n // will be just two cases which fits into the browser inline cache (inline cache can take up to\n // 4)\n const tIcu = value.hasOwnProperty('currentCaseLViewIndex') ? value : value.value;\n ngDevMode && assertTIcu(tIcu);\n return tIcu;\n}\n/**\n * Store `TIcu` at a give `index`.\n *\n * The `TIcu` can be stored either directly (if it is nested ICU) OR\n * it is stored inside tho `TIcuContainer` if it is top level ICU.\n *\n * The reason for this is that the top level ICU need a `TNode` so that they are part of the render\n * tree, but nested ICU's have no TNode, because we don't know ahead of time if the nested ICU is\n * expressed (parent ICU may have selected a case which does not contain it.)\n *\n * @param tView Current `TView`.\n * @param index Index where the value should be stored at in `Tview.data`\n * @param tIcu The TIcu to store.\n */\nfunction setTIcu(tView, index, tIcu) {\n const tNode = tView.data[index];\n ngDevMode && assertEqual(tNode === null || tNode.hasOwnProperty('tView'), true, \"We expect to get 'null'|'TIcuContainer'\");\n if (tNode === null) {\n tView.data[index] = tIcu;\n } else {\n ngDevMode && assertTNodeType(tNode, 32 /* TNodeType.Icu */);\n tNode.value = tIcu;\n }\n}\n/**\n * Set `TNode.insertBeforeIndex` taking the `Array` into account.\n *\n * See `TNode.insertBeforeIndex`\n */\nfunction setTNodeInsertBeforeIndex(tNode, index) {\n ngDevMode && assertTNode(tNode);\n let insertBeforeIndex = tNode.insertBeforeIndex;\n if (insertBeforeIndex === null) {\n setI18nHandling(getInsertInFrontOfRNodeWithI18n, processI18nInsertBefore);\n insertBeforeIndex = tNode.insertBeforeIndex = [null /* may be updated to number later */, index];\n } else {\n assertEqual(Array.isArray(insertBeforeIndex), true, 'Expecting array here');\n insertBeforeIndex.push(index);\n }\n}\n/**\n * Create `TNode.type=TNodeType.Placeholder` node.\n *\n * See `TNodeType.Placeholder` for more information.\n */\nfunction createTNodePlaceholder(tView, previousTNodes, index) {\n const tNode = createTNodeAtIndex(tView, index, 64 /* TNodeType.Placeholder */, null, null);\n addTNodeAndUpdateInsertBeforeIndex(previousTNodes, tNode);\n return tNode;\n}\n/**\n * Returns current ICU case.\n *\n * ICU cases are stored as index into the `TIcu.cases`.\n * At times it is necessary to communicate that the ICU case just switched and that next ICU update\n * should update all bindings regardless of the mask. In such a case the we store negative numbers\n * for cases which have just been switched. This function removes the negative flag.\n */\nfunction getCurrentICUCaseIndex(tIcu, lView) {\n const currentCase = lView[tIcu.currentCaseLViewIndex];\n return currentCase === null ? currentCase : currentCase < 0 ? ~currentCase : currentCase;\n}\nfunction getParentFromIcuCreateOpCode(mergedCode) {\n return mergedCode >>> 17 /* IcuCreateOpCode.SHIFT_PARENT */;\n}\nfunction getRefFromIcuCreateOpCode(mergedCode) {\n return (mergedCode & 131070 /* IcuCreateOpCode.MASK_REF */) >>> 1 /* IcuCreateOpCode.SHIFT_REF */;\n}\nfunction getInstructionFromIcuCreateOpCode(mergedCode) {\n return mergedCode & 1 /* IcuCreateOpCode.MASK_INSTRUCTION */;\n}\nfunction icuCreateOpCode(opCode, parentIdx, refIdx) {\n ngDevMode && assertGreaterThanOrEqual(parentIdx, 0, 'Missing parent index');\n ngDevMode && assertGreaterThan(refIdx, 0, 'Missing ref index');\n return opCode | parentIdx << 17 /* IcuCreateOpCode.SHIFT_PARENT */ | refIdx << 1 /* IcuCreateOpCode.SHIFT_REF */;\n}\n// Returns whether the given value corresponds to a root template message,\n// or a sub-template.\nfunction isRootTemplateMessage(subTemplateIndex) {\n return subTemplateIndex === -1;\n}\nfunction enterIcu(state, tIcu, lView) {\n state.index = 0;\n const currentCase = getCurrentICUCaseIndex(tIcu, lView);\n if (currentCase !== null) {\n ngDevMode && assertNumberInRange(currentCase, 0, tIcu.cases.length - 1);\n state.removes = tIcu.remove[currentCase];\n } else {\n state.removes = EMPTY_ARRAY;\n }\n}\nfunction icuContainerIteratorNext(state) {\n if (state.index < state.removes.length) {\n const removeOpCode = state.removes[state.index++];\n ngDevMode && assertNumber(removeOpCode, 'Expecting OpCode number');\n if (removeOpCode > 0) {\n const rNode = state.lView[removeOpCode];\n ngDevMode && assertDomNode(rNode);\n return rNode;\n } else {\n state.stack.push(state.index, state.removes);\n // ICUs are represented by negative indices\n const tIcuIndex = ~removeOpCode;\n const tIcu = state.lView[TVIEW].data[tIcuIndex];\n ngDevMode && assertTIcu(tIcu);\n enterIcu(state, tIcu, state.lView);\n return icuContainerIteratorNext(state);\n }\n } else {\n if (state.stack.length === 0) {\n return null;\n } else {\n state.removes = state.stack.pop();\n state.index = state.stack.pop();\n return icuContainerIteratorNext(state);\n }\n }\n}\nfunction loadIcuContainerVisitor() {\n const _state = {\n stack: [],\n index: -1\n };\n /**\n * Retrieves a set of root nodes from `TIcu.remove`. Used by `TNodeType.ICUContainer`\n * to determine which root belong to the ICU.\n *\n * Example of usage.\n * ```ts\n * const nextRNode = icuContainerIteratorStart(tIcuContainerNode, lView);\n * let rNode: RNode|null;\n * while(rNode = nextRNode()) {\n * console.log(rNode);\n * }\n * ```\n *\n * @param tIcuContainerNode Current `TIcuContainerNode`\n * @param lView `LView` where the `RNode`s should be looked up.\n */\n function icuContainerIteratorStart(tIcuContainerNode, lView) {\n _state.lView = lView;\n while (_state.stack.length) _state.stack.pop();\n ngDevMode && assertTNodeForLView(tIcuContainerNode, lView);\n enterIcu(_state, tIcuContainerNode.value, lView);\n return icuContainerIteratorNext.bind(null, _state);\n }\n return icuContainerIteratorStart;\n}\nfunction createIcuIterator(tIcu, lView) {\n const state = {\n stack: [],\n index: -1,\n lView\n };\n ngDevMode && assertTIcu(tIcu);\n enterIcu(state, tIcu, lView);\n return icuContainerIteratorNext.bind(null, state);\n}\n\n/**\n * Regexp that extracts a reference node information from the compressed node location.\n * The reference node is represented as either:\n * - a number which points to an LView slot\n * - the `b` char which indicates that the lookup should start from the `document.body`\n * - the `h` char to start lookup from the component host node (`lView[HOST]`)\n */\nconst REF_EXTRACTOR_REGEXP = /* @__PURE__ */new RegExp(`^(\\\\d+)*(${REFERENCE_NODE_BODY}|${REFERENCE_NODE_HOST})*(.*)`);\n/**\n * Helper function that takes a reference node location and a set of navigation steps\n * (from the reference node) to a target node and outputs a string that represents\n * a location.\n *\n * For example, given: referenceNode = 'b' (body) and path = ['firstChild', 'firstChild',\n * 'nextSibling'], the function returns: `bf2n`.\n */\nfunction compressNodeLocation(referenceNode, path) {\n const result = [referenceNode];\n for (const segment of path) {\n const lastIdx = result.length - 1;\n if (lastIdx > 0 && result[lastIdx - 1] === segment) {\n // An empty string in a count slot represents 1 occurrence of an instruction.\n const value = result[lastIdx] || 1;\n result[lastIdx] = value + 1;\n } else {\n // Adding a new segment to the path.\n // Using an empty string in a counter field to avoid encoding `1`s\n // into the path, since they are implicit (e.g. `f1n1` vs `fn`), so\n // it's enough to have a single char in this case.\n result.push(segment, '');\n }\n }\n return result.join('');\n}\n/**\n * Helper function that reverts the `compressNodeLocation` and transforms a given\n * string into an array where at 0th position there is a reference node info and\n * after that it contains information (in pairs) about a navigation step and the\n * number of repetitions.\n *\n * For example, the path like 'bf2n' will be transformed to:\n * ['b', 'firstChild', 2, 'nextSibling', 1].\n *\n * This information is later consumed by the code that navigates the DOM to find\n * a given node by its location.\n */\nfunction decompressNodeLocation(path) {\n const matches = path.match(REF_EXTRACTOR_REGEXP);\n const [_, refNodeId, refNodeName, rest] = matches;\n // If a reference node is represented by an index, transform it to a number.\n const ref = refNodeId ? parseInt(refNodeId, 10) : refNodeName;\n const steps = [];\n // Match all segments in a path.\n for (const [_, step, count] of rest.matchAll(/(f|n)(\\d*)/g)) {\n const repeat = parseInt(count, 10) || 1;\n steps.push(step, repeat);\n }\n return [ref, ...steps];\n}\n\n/** Whether current TNode is a first node in an <ng-container>. */\nfunction isFirstElementInNgContainer(tNode) {\n return !tNode.prev && tNode.parent?.type === 8 /* TNodeType.ElementContainer */;\n}\n/** Returns an instruction index (subtracting HEADER_OFFSET). */\nfunction getNoOffsetIndex(tNode) {\n return tNode.index - HEADER_OFFSET;\n}\n/**\n * Check whether a given node exists, but is disconnected from the DOM.\n */\nfunction isDisconnectedNode(tNode, lView) {\n return !(tNode.type & (16 /* TNodeType.Projection */ | 128 /* TNodeType.LetDeclaration */)) && !!lView[tNode.index] && isDisconnectedRNode(unwrapRNode(lView[tNode.index]));\n}\n/**\n * Check whether the given node exists, but is disconnected from the DOM.\n *\n * Note: we leverage the fact that we have this information available in the DOM emulation\n * layer (in Domino) for now. Longer-term solution should not rely on the DOM emulation and\n * only use internal data structures and state to compute this information.\n */\nfunction isDisconnectedRNode(rNode) {\n return !!rNode && !rNode.isConnected;\n}\n/**\n * Locate a node in an i18n tree that corresponds to a given instruction index.\n *\n * @param hydrationInfo The hydration annotation data\n * @param noOffsetIndex the instruction index\n * @returns an RNode that corresponds to the instruction index\n */\nfunction locateI18nRNodeByIndex(hydrationInfo, noOffsetIndex) {\n const i18nNodes = hydrationInfo.i18nNodes;\n if (i18nNodes) {\n return i18nNodes.get(noOffsetIndex);\n }\n return undefined;\n}\n/**\n * Attempt to locate an RNode by a path, if it exists.\n *\n * @param hydrationInfo The hydration annotation data\n * @param lView the current lView\n * @param noOffsetIndex the instruction index\n * @returns an RNode that corresponds to the instruction index or null if no path exists\n */\nfunction tryLocateRNodeByPath(hydrationInfo, lView, noOffsetIndex) {\n const nodes = hydrationInfo.data[NODES];\n const path = nodes?.[noOffsetIndex];\n return path ? locateRNodeByPath(path, lView) : null;\n}\n/**\n * Locate a node in DOM tree that corresponds to a given TNode.\n *\n * @param hydrationInfo The hydration annotation data\n * @param tView the current tView\n * @param lView the current lView\n * @param tNode the current tNode\n * @returns an RNode that represents a given tNode\n */\nfunction locateNextRNode(hydrationInfo, tView, lView, tNode) {\n const noOffsetIndex = getNoOffsetIndex(tNode);\n let native = locateI18nRNodeByIndex(hydrationInfo, noOffsetIndex);\n if (native === undefined) {\n const nodes = hydrationInfo.data[NODES];\n if (nodes?.[noOffsetIndex]) {\n // We know the exact location of the node.\n native = locateRNodeByPath(nodes[noOffsetIndex], lView);\n } else if (tView.firstChild === tNode) {\n // We create a first node in this view, so we use a reference\n // to the first child in this DOM segment.\n native = hydrationInfo.firstChild;\n } else {\n // Locate a node based on a previous sibling or a parent node.\n const previousTNodeParent = tNode.prev === null;\n const previousTNode = tNode.prev ?? tNode.parent;\n ngDevMode && assertDefined(previousTNode, 'Unexpected state: current TNode does not have a connection ' + 'to the previous node or a parent node.');\n if (isFirstElementInNgContainer(tNode)) {\n const noOffsetParentIndex = getNoOffsetIndex(tNode.parent);\n native = getSegmentHead(hydrationInfo, noOffsetParentIndex);\n } else {\n let previousRElement = getNativeByTNode(previousTNode, lView);\n if (previousTNodeParent) {\n native = previousRElement.firstChild;\n } else {\n // If the previous node is an element, but it also has container info,\n // this means that we are processing a node like `<div #vcrTarget>`, which is\n // represented in the DOM as `<div></div>...<!--container-->`.\n // In this case, there are nodes *after* this element and we need to skip\n // all of them to reach an element that we are looking for.\n const noOffsetPrevSiblingIndex = getNoOffsetIndex(previousTNode);\n const segmentHead = getSegmentHead(hydrationInfo, noOffsetPrevSiblingIndex);\n if (previousTNode.type === 2 /* TNodeType.Element */ && segmentHead) {\n const numRootNodesToSkip = calcSerializedContainerSize(hydrationInfo, noOffsetPrevSiblingIndex);\n // `+1` stands for an anchor comment node after all the views in this container.\n const nodesToSkip = numRootNodesToSkip + 1;\n // First node after this segment.\n native = siblingAfter(nodesToSkip, segmentHead);\n } else {\n native = previousRElement.nextSibling;\n }\n }\n }\n }\n }\n return native;\n}\n/**\n * Skips over a specified number of nodes and returns the next sibling node after that.\n */\nfunction siblingAfter(skip, from) {\n let currentNode = from;\n for (let i = 0; i < skip; i++) {\n ngDevMode && validateSiblingNodeExists(currentNode);\n currentNode = currentNode.nextSibling;\n }\n return currentNode;\n}\n/**\n * Helper function to produce a string representation of the navigation steps\n * (in terms of `nextSibling` and `firstChild` navigations). Used in error\n * messages in dev mode.\n */\nfunction stringifyNavigationInstructions(instructions) {\n const container = [];\n for (let i = 0; i < instructions.length; i += 2) {\n const step = instructions[i];\n const repeat = instructions[i + 1];\n for (let r = 0; r < repeat; r++) {\n container.push(step === NODE_NAVIGATION_STEP_FIRST_CHILD ? 'firstChild' : 'nextSibling');\n }\n }\n return container.join('.');\n}\n/**\n * Helper function that navigates from a starting point node (the `from` node)\n * using provided set of navigation instructions (within `path` argument).\n */\nfunction navigateToNode(from, instructions) {\n let node = from;\n for (let i = 0; i < instructions.length; i += 2) {\n const step = instructions[i];\n const repeat = instructions[i + 1];\n for (let r = 0; r < repeat; r++) {\n if (ngDevMode && !node) {\n throw nodeNotFoundAtPathError(from, stringifyNavigationInstructions(instructions));\n }\n switch (step) {\n case NODE_NAVIGATION_STEP_FIRST_CHILD:\n node = node.firstChild;\n break;\n case NODE_NAVIGATION_STEP_NEXT_SIBLING:\n node = node.nextSibling;\n break;\n }\n }\n }\n if (ngDevMode && !node) {\n throw nodeNotFoundAtPathError(from, stringifyNavigationInstructions(instructions));\n }\n return node;\n}\n/**\n * Locates an RNode given a set of navigation instructions (which also contains\n * a starting point node info).\n */\nfunction locateRNodeByPath(path, lView) {\n const [referenceNode, ...navigationInstructions] = decompressNodeLocation(path);\n let ref;\n if (referenceNode === REFERENCE_NODE_HOST) {\n ref = lView[DECLARATION_COMPONENT_VIEW][HOST];\n } else if (referenceNode === REFERENCE_NODE_BODY) {\n ref = ɵɵresolveBody(lView[DECLARATION_COMPONENT_VIEW][HOST]);\n } else {\n const parentElementId = Number(referenceNode);\n ref = unwrapRNode(lView[parentElementId + HEADER_OFFSET]);\n }\n return navigateToNode(ref, navigationInstructions);\n}\n/**\n * Generate a list of DOM navigation operations to get from node `start` to node `finish`.\n *\n * Note: assumes that node `start` occurs before node `finish` in an in-order traversal of the DOM\n * tree. That is, we should be able to get from `start` to `finish` purely by using `.firstChild`\n * and `.nextSibling` operations.\n */\nfunction navigateBetween(start, finish) {\n if (start === finish) {\n return [];\n } else if (start.parentElement == null || finish.parentElement == null) {\n return null;\n } else if (start.parentElement === finish.parentElement) {\n return navigateBetweenSiblings(start, finish);\n } else {\n // `finish` is a child of its parent, so the parent will always have a child.\n const parent = finish.parentElement;\n const parentPath = navigateBetween(start, parent);\n const childPath = navigateBetween(parent.firstChild, finish);\n if (!parentPath || !childPath) return null;\n return [\n // First navigate to `finish`'s parent\n ...parentPath,\n // Then to its first child.\n NODE_NAVIGATION_STEP_FIRST_CHILD,\n // And finally from that node to `finish` (maybe a no-op if we're already there).\n ...childPath];\n }\n}\n/**\n * Calculates a path between 2 sibling nodes (generates a number of `NextSibling` navigations).\n * Returns `null` if no such path exists between the given nodes.\n */\nfunction navigateBetweenSiblings(start, finish) {\n const nav = [];\n let node = null;\n for (node = start; node != null && node !== finish; node = node.nextSibling) {\n nav.push(NODE_NAVIGATION_STEP_NEXT_SIBLING);\n }\n // If the `node` becomes `null` or `undefined` at the end, that means that we\n // didn't find the `end` node, thus return `null` (which would trigger serialization\n // error to be produced).\n return node == null ? null : nav;\n}\n/**\n * Calculates a path between 2 nodes in terms of `nextSibling` and `firstChild`\n * navigations:\n * - the `from` node is a known node, used as an starting point for the lookup\n * (the `fromNodeName` argument is a string representation of the node).\n * - the `to` node is a node that the runtime logic would be looking up,\n * using the path generated by this function.\n */\nfunction calcPathBetween(from, to, fromNodeName) {\n const path = navigateBetween(from, to);\n return path === null ? null : compressNodeLocation(fromNodeName, path);\n}\n/**\n * Invoked at serialization time (on the server) when a set of navigation\n * instructions needs to be generated for a TNode.\n */\nfunction calcPathForNode(tNode, lView, excludedParentNodes) {\n let parentTNode = tNode.parent;\n let parentIndex;\n let parentRNode;\n let referenceNodeName;\n // Skip over all parent nodes that are disconnected from the DOM, such nodes\n // can not be used as anchors.\n //\n // This might happen in certain content projection-based use-cases, where\n // a content of an element is projected and used, when a parent element\n // itself remains detached from DOM. In this scenario we try to find a parent\n // element that is attached to DOM and can act as an anchor instead.\n //\n // It can also happen that the parent node should be excluded, for example,\n // because it belongs to an i18n block, which requires paths which aren't\n // relative to other views in an i18n block.\n while (parentTNode !== null && (isDisconnectedNode(parentTNode, lView) || excludedParentNodes?.has(parentTNode.index))) {\n parentTNode = parentTNode.parent;\n }\n if (parentTNode === null || !(parentTNode.type & 3 /* TNodeType.AnyRNode */)) {\n // If there is no parent TNode or a parent TNode does not represent an RNode\n // (i.e. not a DOM node), use component host element as a reference node.\n parentIndex = referenceNodeName = REFERENCE_NODE_HOST;\n parentRNode = lView[DECLARATION_COMPONENT_VIEW][HOST];\n } else {\n // Use parent TNode as a reference node.\n parentIndex = parentTNode.index;\n parentRNode = unwrapRNode(lView[parentIndex]);\n referenceNodeName = renderStringify(parentIndex - HEADER_OFFSET);\n }\n let rNode = unwrapRNode(lView[tNode.index]);\n if (tNode.type & (12 /* TNodeType.AnyContainer */ | 32 /* TNodeType.Icu */)) {\n // For <ng-container> nodes, instead of serializing a reference\n // to the anchor comment node, serialize a location of the first\n // DOM element. Paired with the container size (serialized as a part\n // of `ngh.containers`), it should give enough information for runtime\n // to hydrate nodes in this container.\n const firstRNode = getFirstNativeNode(lView, tNode);\n // If container is not empty, use a reference to the first element,\n // otherwise, rNode would point to an anchor comment node.\n if (firstRNode) {\n rNode = firstRNode;\n }\n }\n let path = calcPathBetween(parentRNode, rNode, referenceNodeName);\n if (path === null && parentRNode !== rNode) {\n // Searching for a path between elements within a host node failed.\n // Trying to find a path to an element starting from the `document.body` instead.\n //\n // Important note: this type of reference is relatively unstable, since Angular\n // may not be able to control parts of the page that the runtime logic navigates\n // through. This is mostly needed to cover \"portals\" use-case (like menus, dialog boxes,\n // etc), where nodes are content-projected (including direct DOM manipulations) outside\n // of the host node. The better solution is to provide APIs to work with \"portals\",\n // at which point this code path would not be needed.\n const body = parentRNode.ownerDocument.body;\n path = calcPathBetween(body, rNode, REFERENCE_NODE_BODY);\n if (path === null) {\n // If the path is still empty, it's likely that this node is detached and\n // won't be found during hydration.\n throw nodeNotFoundError(lView, tNode);\n }\n }\n return path;\n}\n/**\n * Retrieves all comments nodes that contain ngh comments referring to a defer block\n */\nfunction gatherDeferBlocksCommentNodes(doc, node) {\n const commentNodesIterator = doc.createNodeIterator(node, NodeFilter.SHOW_COMMENT, {\n acceptNode\n });\n let currentNode;\n const nodesByBlockId = new Map();\n while (currentNode = commentNodesIterator.nextNode()) {\n const nghPattern = 'ngh=';\n const content = currentNode?.textContent;\n const nghIdx = content?.indexOf(nghPattern) ?? -1;\n if (nghIdx > -1) {\n const nghValue = content.substring(nghIdx + nghPattern.length).trim();\n // Make sure the value has an expected format.\n ngDevMode && assertEqual(nghValue.startsWith('d'), true, 'Invalid defer block id found in a comment node.');\n nodesByBlockId.set(nghValue, currentNode);\n }\n }\n return nodesByBlockId;\n}\nfunction acceptNode(node) {\n return node.textContent?.trimStart().startsWith('ngh=') ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_REJECT;\n}\nlet _isI18nHydrationSupportEnabled = false;\nlet _prepareI18nBlockForHydrationImpl = () => {\n // noop unless `enablePrepareI18nBlockForHydrationImpl` is invoked.\n};\nfunction setIsI18nHydrationSupportEnabled(enabled) {\n _isI18nHydrationSupportEnabled = enabled;\n}\nfunction isI18nHydrationSupportEnabled() {\n return _isI18nHydrationSupportEnabled;\n}\n/**\n * Prepares an i18n block and its children, located at the given\n * view and instruction index, for hydration.\n *\n * @param lView lView with the i18n block\n * @param index index of the i18n block in the lView\n * @param parentTNode TNode of the parent of the i18n block\n * @param subTemplateIndex sub-template index, or -1 for the main template\n */\nfunction prepareI18nBlockForHydration(lView, index, parentTNode, subTemplateIndex) {\n _prepareI18nBlockForHydrationImpl(lView, index, parentTNode, subTemplateIndex);\n}\nfunction enablePrepareI18nBlockForHydrationImpl() {\n _prepareI18nBlockForHydrationImpl = prepareI18nBlockForHydrationImpl;\n}\nfunction isI18nHydrationEnabled(injector) {\n injector = injector ?? inject(Injector);\n return injector.get(IS_I18N_HYDRATION_ENABLED, false);\n}\n/**\n * Collects, if not already cached, all of the indices in the\n * given TView which are children of an i18n block.\n *\n * Since i18n blocks don't introduce a parent TNode, this is necessary\n * in order to determine which indices in a LView are translated.\n */\nfunction getOrComputeI18nChildren(tView, context) {\n let i18nChildren = context.i18nChildren.get(tView);\n if (i18nChildren === undefined) {\n i18nChildren = collectI18nChildren(tView);\n context.i18nChildren.set(tView, i18nChildren);\n }\n return i18nChildren;\n}\nfunction collectI18nChildren(tView) {\n const children = new Set();\n function collectI18nViews(node) {\n children.add(node.index);\n switch (node.kind) {\n case 1 /* I18nNodeKind.ELEMENT */:\n case 2 /* I18nNodeKind.PLACEHOLDER */:\n {\n for (const childNode of node.children) {\n collectI18nViews(childNode);\n }\n break;\n }\n case 3 /* I18nNodeKind.ICU */:\n {\n for (const caseNodes of node.cases) {\n for (const caseNode of caseNodes) {\n collectI18nViews(caseNode);\n }\n }\n break;\n }\n }\n }\n // Traverse through the AST of each i18n block in the LView,\n // and collect every instruction index.\n for (let i = HEADER_OFFSET; i < tView.bindingStartIndex; i++) {\n const tI18n = tView.data[i];\n if (!tI18n || !tI18n.ast) {\n continue;\n }\n for (const node of tI18n.ast) {\n collectI18nViews(node);\n }\n }\n return children.size === 0 ? null : children;\n}\n/**\n * Attempts to serialize i18n data for an i18n block, located at\n * the given view and instruction index.\n *\n * @param lView lView with the i18n block\n * @param index index of the i18n block in the lView\n * @param context the hydration context\n * @returns the i18n data, or null if there is no relevant data\n */\nfunction trySerializeI18nBlock(lView, index, context) {\n if (!context.isI18nHydrationEnabled) {\n return null;\n }\n const tView = lView[TVIEW];\n const tI18n = tView.data[index];\n if (!tI18n || !tI18n.ast) {\n return null;\n }\n const parentTNode = tView.data[tI18n.parentTNodeIndex];\n if (parentTNode && isI18nInSkipHydrationBlock(parentTNode)) {\n return null;\n }\n const serializedI18nBlock = {\n caseQueue: [],\n disconnectedNodes: new Set(),\n disjointNodes: new Set()\n };\n serializeI18nBlock(lView, serializedI18nBlock, context, tI18n.ast);\n return serializedI18nBlock.caseQueue.length === 0 && serializedI18nBlock.disconnectedNodes.size === 0 && serializedI18nBlock.disjointNodes.size === 0 ? null : serializedI18nBlock;\n}\nfunction serializeI18nBlock(lView, serializedI18nBlock, context, nodes) {\n let prevRNode = null;\n for (const node of nodes) {\n const nextRNode = serializeI18nNode(lView, serializedI18nBlock, context, node);\n if (nextRNode) {\n if (isDisjointNode(prevRNode, nextRNode)) {\n serializedI18nBlock.disjointNodes.add(node.index - HEADER_OFFSET);\n }\n prevRNode = nextRNode;\n }\n }\n return prevRNode;\n}\n/**\n * Helper to determine whether the given nodes are \"disjoint\".\n *\n * The i18n hydration process walks through the DOM and i18n nodes\n * at the same time. It expects the sibling DOM node of the previous\n * i18n node to be the first node of the next i18n node.\n *\n * In cases of content projection, this won't always be the case. So\n * when we detect that, we mark the node as \"disjoint\", ensuring that\n * we will serialize the path to the node. This way, when we hydrate the\n * i18n node, we will be able to find the correct place to start.\n */\nfunction isDisjointNode(prevNode, nextNode) {\n return prevNode && prevNode.nextSibling !== nextNode;\n}\n/**\n * Process the given i18n node for serialization.\n * Returns the first RNode for the i18n node to begin hydration.\n */\nfunction serializeI18nNode(lView, serializedI18nBlock, context, node) {\n const maybeRNode = unwrapRNode(lView[node.index]);\n if (!maybeRNode || isDisconnectedRNode(maybeRNode)) {\n serializedI18nBlock.disconnectedNodes.add(node.index - HEADER_OFFSET);\n return null;\n }\n const rNode = maybeRNode;\n switch (node.kind) {\n case 0 /* I18nNodeKind.TEXT */:\n {\n processTextNodeBeforeSerialization(context, rNode);\n break;\n }\n case 1 /* I18nNodeKind.ELEMENT */:\n case 2 /* I18nNodeKind.PLACEHOLDER */:\n {\n serializeI18nBlock(lView, serializedI18nBlock, context, node.children);\n break;\n }\n case 3 /* I18nNodeKind.ICU */:\n {\n const currentCase = lView[node.currentCaseLViewIndex];\n if (currentCase != null) {\n // i18n uses a negative value to signal a change to a new case, so we\n // need to invert it to get the proper value.\n const caseIdx = currentCase < 0 ? ~currentCase : currentCase;\n serializedI18nBlock.caseQueue.push(caseIdx);\n serializeI18nBlock(lView, serializedI18nBlock, context, node.cases[caseIdx]);\n }\n break;\n }\n }\n return getFirstNativeNodeForI18nNode(lView, node);\n}\n/**\n * Helper function to get the first native node to begin hydrating\n * the given i18n node.\n */\nfunction getFirstNativeNodeForI18nNode(lView, node) {\n const tView = lView[TVIEW];\n const maybeTNode = tView.data[node.index];\n if (isTNodeShape(maybeTNode)) {\n // If the node is backed by an actual TNode, we can simply delegate.\n return getFirstNativeNode(lView, maybeTNode);\n } else if (node.kind === 3 /* I18nNodeKind.ICU */) {\n // A nested ICU container won't have an actual TNode. In that case, we can use\n // an iterator to find the first child.\n const icuIterator = createIcuIterator(maybeTNode, lView);\n let rNode = icuIterator();\n // If the ICU container has no nodes, then we use the ICU anchor as the node.\n return rNode ?? unwrapRNode(lView[node.index]);\n } else {\n // Otherwise, the node is a text or trivial element in an ICU container,\n // and we can just use the RNode directly.\n return unwrapRNode(lView[node.index]) ?? null;\n }\n}\nfunction setCurrentNode(state, node) {\n state.currentNode = node;\n}\n/**\n * Marks the current RNode as the hydration root for the given\n * AST node.\n */\nfunction appendI18nNodeToCollection(context, state, astNode) {\n const noOffsetIndex = astNode.index - HEADER_OFFSET;\n const {\n disconnectedNodes\n } = context;\n const currentNode = state.currentNode;\n if (state.isConnected) {\n context.i18nNodes.set(noOffsetIndex, currentNode);\n // We expect the node to be connected, so ensure that it\n // is not in the set, regardless of whether we found it,\n // so that the downstream error handling can provide the\n // proper context.\n disconnectedNodes.delete(noOffsetIndex);\n } else {\n disconnectedNodes.add(noOffsetIndex);\n }\n return currentNode;\n}\n/**\n * Skip over some sibling nodes during hydration.\n *\n * Note: we use this instead of `siblingAfter` as it's expected that\n * sometimes we might encounter null nodes. In those cases, we want to\n * defer to downstream error handling to provide proper context.\n */\nfunction skipSiblingNodes(state, skip) {\n let currentNode = state.currentNode;\n for (let i = 0; i < skip; i++) {\n if (!currentNode) {\n break;\n }\n currentNode = currentNode?.nextSibling ?? null;\n }\n return currentNode;\n}\n/**\n * Fork the given state into a new state for hydrating children.\n */\nfunction forkHydrationState(state, nextNode) {\n return {\n currentNode: nextNode,\n isConnected: state.isConnected\n };\n}\nfunction prepareI18nBlockForHydrationImpl(lView, index, parentTNode, subTemplateIndex) {\n const hydrationInfo = lView[HYDRATION];\n if (!hydrationInfo) {\n return;\n }\n if (!isI18nHydrationSupportEnabled() || parentTNode && (isI18nInSkipHydrationBlock(parentTNode) || isDisconnectedNode$1(hydrationInfo, parentTNode.index - HEADER_OFFSET))) {\n return;\n }\n const tView = lView[TVIEW];\n const tI18n = tView.data[index];\n ngDevMode && assertDefined(tI18n, 'Expected i18n data to be present in a given TView slot during hydration');\n function findHydrationRoot() {\n if (isRootTemplateMessage(subTemplateIndex)) {\n // This is the root of an i18n block. In this case, our hydration root will\n // depend on where our parent TNode (i.e. the block with i18n applied) is\n // in the DOM.\n ngDevMode && assertDefined(parentTNode, 'Expected parent TNode while hydrating i18n root');\n const rootNode = locateNextRNode(hydrationInfo, tView, lView, parentTNode);\n // If this i18n block is attached to an <ng-container>, then we want to begin\n // hydrating directly with the RNode. Otherwise, for a TNode with a physical DOM\n // element, we want to recurse into the first child and begin there.\n return parentTNode.type & 8 /* TNodeType.ElementContainer */ ? rootNode : rootNode.firstChild;\n }\n // This is a nested template in an i18n block. In this case, the entire view\n // is translated, and part of a dehydrated view in a container. This means that\n // we can simply begin hydration with the first dehydrated child.\n return hydrationInfo?.firstChild;\n }\n const currentNode = findHydrationRoot();\n ngDevMode && assertDefined(currentNode, 'Expected root i18n node during hydration');\n const disconnectedNodes = initDisconnectedNodes(hydrationInfo) ?? new Set();\n const i18nNodes = hydrationInfo.i18nNodes ??= new Map();\n const caseQueue = hydrationInfo.data[I18N_DATA]?.[index - HEADER_OFFSET] ?? [];\n const dehydratedIcuData = hydrationInfo.dehydratedIcuData ??= new Map();\n collectI18nNodesFromDom({\n hydrationInfo,\n lView,\n i18nNodes,\n disconnectedNodes,\n caseQueue,\n dehydratedIcuData\n }, {\n currentNode,\n isConnected: true\n }, tI18n.ast);\n // Nodes from inactive ICU cases should be considered disconnected. We track them above\n // because they aren't (and shouldn't be) serialized. Since we may mutate or create a\n // new set, we need to be sure to write the expected value back to the DehydratedView.\n hydrationInfo.disconnectedNodes = disconnectedNodes.size === 0 ? null : disconnectedNodes;\n}\nfunction collectI18nNodesFromDom(context, state, nodeOrNodes) {\n if (Array.isArray(nodeOrNodes)) {\n let nextState = state;\n for (const node of nodeOrNodes) {\n // Whenever a node doesn't directly follow the previous RNode, it\n // is given a path. We need to resume collecting nodes from that location\n // until and unless we find another disjoint node.\n const targetNode = tryLocateRNodeByPath(context.hydrationInfo, context.lView, node.index - HEADER_OFFSET);\n if (targetNode) {\n nextState = forkHydrationState(state, targetNode);\n }\n collectI18nNodesFromDom(context, nextState, node);\n }\n } else {\n if (context.disconnectedNodes.has(nodeOrNodes.index - HEADER_OFFSET)) {\n // i18n nodes can be considered disconnected if e.g. they were projected.\n // In that case, we have to make sure to skip over them.\n return;\n }\n switch (nodeOrNodes.kind) {\n case 0 /* I18nNodeKind.TEXT */:\n {\n // Claim a text node for hydration\n const currentNode = appendI18nNodeToCollection(context, state, nodeOrNodes);\n setCurrentNode(state, currentNode?.nextSibling ?? null);\n break;\n }\n case 1 /* I18nNodeKind.ELEMENT */:\n {\n // Recurse into the current element's children...\n collectI18nNodesFromDom(context, forkHydrationState(state, state.currentNode?.firstChild ?? null), nodeOrNodes.children);\n // And claim the parent element itself.\n const currentNode = appendI18nNodeToCollection(context, state, nodeOrNodes);\n setCurrentNode(state, currentNode?.nextSibling ?? null);\n break;\n }\n case 2 /* I18nNodeKind.PLACEHOLDER */:\n {\n const noOffsetIndex = nodeOrNodes.index - HEADER_OFFSET;\n const {\n hydrationInfo\n } = context;\n const containerSize = getNgContainerSize(hydrationInfo, noOffsetIndex);\n switch (nodeOrNodes.type) {\n case 0 /* I18nPlaceholderType.ELEMENT */:\n {\n // Hydration expects to find the head of the element.\n const currentNode = appendI18nNodeToCollection(context, state, nodeOrNodes);\n // A TNode for the node may not yet if we're hydrating during the first pass,\n // so use the serialized data to determine if this is an <ng-container>.\n if (isSerializedElementContainer(hydrationInfo, noOffsetIndex)) {\n // An <ng-container> doesn't have a physical DOM node, so we need to\n // continue hydrating from siblings.\n collectI18nNodesFromDom(context, state, nodeOrNodes.children);\n // Skip over the anchor element. It will be claimed by the\n // downstream container hydration.\n const nextNode = skipSiblingNodes(state, 1);\n setCurrentNode(state, nextNode);\n } else {\n // Non-container elements represent an actual node in the DOM, so we\n // need to continue hydration with the children, and claim the node.\n collectI18nNodesFromDom(context, forkHydrationState(state, state.currentNode?.firstChild ?? null), nodeOrNodes.children);\n setCurrentNode(state, currentNode?.nextSibling ?? null);\n // Elements can also be the anchor of a view container, so there may\n // be elements after this node that we need to skip.\n if (containerSize !== null) {\n // `+1` stands for an anchor node after all of the views in the container.\n const nextNode = skipSiblingNodes(state, containerSize + 1);\n setCurrentNode(state, nextNode);\n }\n }\n break;\n }\n case 1 /* I18nPlaceholderType.SUBTEMPLATE */:\n {\n ngDevMode && assertNotEqual(containerSize, null, 'Expected a container size while hydrating i18n subtemplate');\n // Hydration expects to find the head of the template.\n appendI18nNodeToCollection(context, state, nodeOrNodes);\n // Skip over all of the template children, as well as the anchor\n // node, since the template itself will handle them instead.\n const nextNode = skipSiblingNodes(state, containerSize + 1);\n setCurrentNode(state, nextNode);\n break;\n }\n }\n break;\n }\n case 3 /* I18nNodeKind.ICU */:\n {\n // If the current node is connected, we need to pop the next case from the\n // queue, so that the active case is also considered connected.\n const selectedCase = state.isConnected ? context.caseQueue.shift() : null;\n const childState = {\n currentNode: null,\n isConnected: false\n };\n // We traverse through each case, even if it's not active,\n // so that we correctly populate disconnected nodes.\n for (let i = 0; i < nodeOrNodes.cases.length; i++) {\n collectI18nNodesFromDom(context, i === selectedCase ? state : childState, nodeOrNodes.cases[i]);\n }\n if (selectedCase !== null) {\n // ICUs represent a branching state, and the selected case could be different\n // than what it was on the server. In that case, we need to be able to clean\n // up the nodes from the original case. To do that, we store the selected case.\n context.dehydratedIcuData.set(nodeOrNodes.index, {\n case: selectedCase,\n node: nodeOrNodes\n });\n }\n // Hydration expects to find the ICU anchor element.\n const currentNode = appendI18nNodeToCollection(context, state, nodeOrNodes);\n setCurrentNode(state, currentNode?.nextSibling ?? null);\n break;\n }\n }\n }\n}\nlet _claimDehydratedIcuCaseImpl = () => {\n // noop unless `enableClaimDehydratedIcuCaseImpl` is invoked\n};\n/**\n * Mark the case for the ICU node at the given index in the view as claimed,\n * allowing its nodes to be hydrated and not cleaned up.\n */\nfunction claimDehydratedIcuCase(lView, icuIndex, caseIndex) {\n _claimDehydratedIcuCaseImpl(lView, icuIndex, caseIndex);\n}\nfunction enableClaimDehydratedIcuCaseImpl() {\n _claimDehydratedIcuCaseImpl = claimDehydratedIcuCaseImpl;\n}\nfunction claimDehydratedIcuCaseImpl(lView, icuIndex, caseIndex) {\n const dehydratedIcuDataMap = lView[HYDRATION]?.dehydratedIcuData;\n if (dehydratedIcuDataMap) {\n const dehydratedIcuData = dehydratedIcuDataMap.get(icuIndex);\n if (dehydratedIcuData?.case === caseIndex) {\n // If the case we're attempting to claim matches the dehydrated one,\n // we remove it from the map to mark it as \"claimed.\"\n dehydratedIcuDataMap.delete(icuIndex);\n }\n }\n}\n/**\n * Clean up all i18n hydration data associated with the given view.\n */\nfunction cleanupI18nHydrationData(lView) {\n const hydrationInfo = lView[HYDRATION];\n if (hydrationInfo) {\n const {\n i18nNodes,\n dehydratedIcuData: dehydratedIcuDataMap\n } = hydrationInfo;\n if (i18nNodes && dehydratedIcuDataMap) {\n const renderer = lView[RENDERER];\n for (const dehydratedIcuData of dehydratedIcuDataMap.values()) {\n cleanupDehydratedIcuData(renderer, i18nNodes, dehydratedIcuData);\n }\n }\n hydrationInfo.i18nNodes = undefined;\n hydrationInfo.dehydratedIcuData = undefined;\n }\n}\nfunction cleanupDehydratedIcuData(renderer, i18nNodes, dehydratedIcuData) {\n for (const node of dehydratedIcuData.node.cases[dehydratedIcuData.case]) {\n const rNode = i18nNodes.get(node.index - HEADER_OFFSET);\n if (rNode) {\n nativeRemoveNode(renderer, rNode, false);\n }\n }\n}\n\n/**\n * Removes all dehydrated views from a given LContainer:\n * both in internal data structure, as well as removing\n * corresponding DOM nodes that belong to that dehydrated view.\n */\nfunction removeDehydratedViews(lContainer) {\n const views = lContainer[DEHYDRATED_VIEWS] ?? [];\n const parentLView = lContainer[PARENT];\n const renderer = parentLView[RENDERER];\n const retainedViews = [];\n for (const view of views) {\n // Do not clean up contents of `@defer` blocks.\n // The cleanup for this content would happen once a given block\n // is triggered and hydrated.\n if (view.data[DEFER_BLOCK_ID] !== undefined) {\n retainedViews.push(view);\n } else {\n removeDehydratedView(view, renderer);\n ngDevMode && ngDevMode.dehydratedViewsRemoved++;\n }\n }\n // Reset the value to an array to indicate that no\n // further processing of dehydrated views is needed for\n // this view container (i.e. do not trigger the lookup process\n // once again in case a `ViewContainerRef` is created later).\n lContainer[DEHYDRATED_VIEWS] = retainedViews;\n}\nfunction removeDehydratedViewList(deferBlock) {\n const {\n lContainer\n } = deferBlock;\n const dehydratedViews = lContainer[DEHYDRATED_VIEWS];\n if (dehydratedViews === null) return;\n const parentLView = lContainer[PARENT];\n const renderer = parentLView[RENDERER];\n for (const view of dehydratedViews) {\n removeDehydratedView(view, renderer);\n ngDevMode && ngDevMode.dehydratedViewsRemoved++;\n }\n}\n/**\n * Helper function to remove all nodes from a dehydrated view.\n */\nfunction removeDehydratedView(dehydratedView, renderer) {\n let nodesRemoved = 0;\n let currentRNode = dehydratedView.firstChild;\n if (currentRNode) {\n const numNodes = dehydratedView.data[NUM_ROOT_NODES];\n while (nodesRemoved < numNodes) {\n ngDevMode && validateSiblingNodeExists(currentRNode);\n const nextSibling = currentRNode.nextSibling;\n nativeRemoveNode(renderer, currentRNode, false);\n currentRNode = nextSibling;\n nodesRemoved++;\n }\n }\n}\n/**\n * Walks over all views within this LContainer invokes dehydrated views\n * cleanup function for each one.\n */\nfunction cleanupLContainer(lContainer) {\n removeDehydratedViews(lContainer);\n // The host could be an LView if this container is on a component node.\n // In this case, descend into host LView for further cleanup. See also\n // LContainer[HOST] docs for additional information.\n const hostLView = lContainer[HOST];\n if (isLView(hostLView)) {\n cleanupLView(hostLView);\n }\n for (let i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {\n cleanupLView(lContainer[i]);\n }\n}\n/**\n * Walks over `LContainer`s and components registered within\n * this LView and invokes dehydrated views cleanup function for each one.\n */\nfunction cleanupLView(lView) {\n cleanupI18nHydrationData(lView);\n const tView = lView[TVIEW];\n for (let i = HEADER_OFFSET; i < tView.bindingStartIndex; i++) {\n if (isLContainer(lView[i])) {\n const lContainer = lView[i];\n cleanupLContainer(lContainer);\n } else if (isLView(lView[i])) {\n // This is a component, enter the `cleanupLView` recursively.\n cleanupLView(lView[i]);\n }\n }\n}\n/**\n * Walks over all views registered within the ApplicationRef and removes\n * all dehydrated views from all `LContainer`s along the way.\n */\nfunction cleanupDehydratedViews(appRef) {\n const viewRefs = appRef._views;\n for (const viewRef of viewRefs) {\n const lNode = getLNodeForHydration(viewRef);\n // An `lView` might be `null` if a `ViewRef` represents\n // an embedded view (not a component view).\n if (lNode !== null && lNode[HOST] !== null) {\n if (isLView(lNode)) {\n cleanupLView(lNode);\n } else {\n // Cleanup in all views within this view container\n cleanupLContainer(lNode);\n }\n ngDevMode && ngDevMode.dehydratedViewsCleanupRuns++;\n }\n }\n}\n/**\n * post hydration cleanup handling for defer blocks that were incrementally\n * hydrated. This removes all the jsaction attributes, timers, observers,\n * dehydrated views and containers\n */\nfunction cleanupHydratedDeferBlocks(deferBlock, hydratedBlocks, registry, appRef) {\n if (deferBlock !== null) {\n registry.cleanup(hydratedBlocks);\n cleanupLContainer(deferBlock.lContainer);\n cleanupDehydratedViews(appRef);\n }\n}\n\n/**\n * Given a current DOM node and a serialized information about the views\n * in a container, walks over the DOM structure, collecting the list of\n * dehydrated views.\n */\nfunction locateDehydratedViewsInContainer(currentRNode, serializedViews) {\n const dehydratedViews = [];\n for (const serializedView of serializedViews) {\n // Repeats a view multiple times as needed, based on the serialized information\n // (for example, for *ngFor-produced views).\n for (let i = 0; i < (serializedView[MULTIPLIER] ?? 1); i++) {\n const view = {\n data: serializedView,\n firstChild: null\n };\n if (serializedView[NUM_ROOT_NODES] > 0) {\n // Keep reference to the first node in this view,\n // so it can be accessed while invoking template instructions.\n view.firstChild = currentRNode;\n // Move over to the next node after this view, which can\n // either be a first node of the next view or an anchor comment\n // node after the last view in a container.\n currentRNode = siblingAfter(serializedView[NUM_ROOT_NODES], currentRNode);\n }\n dehydratedViews.push(view);\n }\n }\n return [currentRNode, dehydratedViews];\n}\n/**\n * Reference to a function that searches for a matching dehydrated views\n * stored on a given lContainer.\n * Returns `null` by default, when hydration is not enabled.\n */\nlet _findMatchingDehydratedViewImpl = () => null;\n/**\n * Retrieves the next dehydrated view from the LContainer and verifies that\n * it matches a given template id (from the TView that was used to create this\n * instance of a view). If the id doesn't match, that means that we are in an\n * unexpected state and can not complete the reconciliation process. Thus,\n * all dehydrated views from this LContainer are removed (including corresponding\n * DOM nodes) and the rendering is performed as if there were no dehydrated views\n * in this container.\n */\nfunction findMatchingDehydratedViewImpl(lContainer, template) {\n const views = lContainer[DEHYDRATED_VIEWS];\n if (!template || views === null || views.length === 0) {\n return null;\n }\n const view = views[0];\n // Verify whether the first dehydrated view in the container matches\n // the template id passed to this function (that originated from a TView\n // that was used to create an instance of an embedded or component views.\n if (view.data[TEMPLATE_ID] === template) {\n // If the template id matches - extract the first view and return it.\n return views.shift();\n } else {\n // Otherwise, we are at the state when reconciliation can not be completed,\n // thus we remove all dehydrated views within this container (remove them\n // from internal data structures as well as delete associated elements from\n // the DOM tree).\n removeDehydratedViews(lContainer);\n return null;\n }\n}\nfunction enableFindMatchingDehydratedViewImpl() {\n _findMatchingDehydratedViewImpl = findMatchingDehydratedViewImpl;\n}\nfunction findMatchingDehydratedView(lContainer, template) {\n return _findMatchingDehydratedViewImpl(lContainer, template);\n}\n\n/**\n * Represents a component created by a `ComponentFactory`.\n * Provides access to the component instance and related objects,\n * and provides the means of destroying the instance.\n *\n * @publicApi\n */\nclass ComponentRef$1 {}\n/**\n * Base class for a factory that can create a component dynamically.\n * Instantiate a factory for a given type of component with `resolveComponentFactory()`.\n * Use the resulting `ComponentFactory.create()` method to create a component of that type.\n *\n * @publicApi\n *\n * @deprecated Angular no longer requires Component factories. Please use other APIs where\n * Component class can be used directly.\n */\nclass ComponentFactory$1 {}\nclass _NullComponentFactoryResolver {\n resolveComponentFactory(component) {\n throw Error(`No component factory found for ${stringify(component)}.`);\n }\n}\n/**\n * A simple registry that maps `Components` to generated `ComponentFactory` classes\n * that can be used to create instances of components.\n * Use to obtain the factory for a given component type,\n * then use the factory's `create()` method to create a component of that type.\n *\n * Note: since v13, dynamic component creation via\n * [`ViewContainerRef.createComponent`](api/core/ViewContainerRef#createComponent)\n * does **not** require resolving component factory: component class can be used directly.\n *\n * @publicApi\n *\n * @deprecated Angular no longer requires Component factories. Please use other APIs where\n * Component class can be used directly.\n */\nclass ComponentFactoryResolver$1 {\n static NULL = new _NullComponentFactoryResolver();\n}\n\n/**\n * Creates and initializes a custom renderer that implements the `Renderer2` base class.\n *\n * @publicApi\n */\nclass RendererFactory2 {}\n/**\n * Extend this base class to implement custom rendering. By default, Angular\n * renders a template into DOM. You can use custom rendering to intercept\n * rendering calls, or to render to something other than DOM.\n *\n * Create your custom renderer using `RendererFactory2`.\n *\n * Use a custom renderer to bypass Angular's templating and\n * make custom UI changes that can't be expressed declaratively.\n * For example if you need to set a property or an attribute whose name is\n * not statically known, use the `setProperty()` or\n * `setAttribute()` method.\n *\n * @publicApi\n */\nclass Renderer2 {\n /**\n * If null or undefined, the view engine won't call it.\n * This is used as a performance optimization for production mode.\n */\n destroyNode = null;\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = () => injectRenderer2();\n}\n/** Injects a Renderer2 for the current component. */\nfunction injectRenderer2() {\n // We need the Renderer to be based on the component that it's being injected into, however since\n // DI happens before we've entered its view, `getLView` will return the parent view instead.\n const lView = getLView();\n const tNode = getCurrentTNode();\n const nodeAtIndex = getComponentLViewByIndex(tNode.index, lView);\n return (isLView(nodeAtIndex) ? nodeAtIndex : lView)[RENDERER];\n}\n\n/**\n * Sanitizer is used by the views to sanitize potentially dangerous values.\n *\n * @publicApi\n */\nclass Sanitizer {\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: Sanitizer,\n providedIn: 'root',\n factory: () => null\n });\n}\nfunction isModuleWithProviders(value) {\n return value.ngModule !== undefined;\n}\nfunction isNgModule(value) {\n return !!getNgModuleDef(value);\n}\nfunction isPipe(value) {\n return !!getPipeDef$1(value);\n}\nfunction isDirective(value) {\n return !!getDirectiveDef(value);\n}\nfunction isComponent(value) {\n return !!getComponentDef(value);\n}\nfunction getDependencyTypeForError(type) {\n if (getComponentDef(type)) return 'component';\n if (getDirectiveDef(type)) return 'directive';\n if (getPipeDef$1(type)) return 'pipe';\n return 'type';\n}\nfunction verifyStandaloneImport(depType, importingType) {\n if (isForwardRef(depType)) {\n depType = resolveForwardRef(depType);\n if (!depType) {\n throw new Error(`Expected forwardRef function, imported from \"${stringifyForError(importingType)}\", to return a standalone entity or NgModule but got \"${stringifyForError(depType) || depType}\".`);\n }\n }\n if (getNgModuleDef(depType) == null) {\n const def = getComponentDef(depType) || getDirectiveDef(depType) || getPipeDef$1(depType);\n if (def != null) {\n // if a component, directive or pipe is imported make sure that it is standalone\n if (!def.standalone) {\n throw new Error(`The \"${stringifyForError(depType)}\" ${getDependencyTypeForError(depType)}, imported from \"${stringifyForError(importingType)}\", is not standalone. Did you forget to add the standalone: true flag?`);\n }\n } else {\n // it can be either a module with provider or an unknown (not annotated) type\n if (isModuleWithProviders(depType)) {\n throw new Error(`A module with providers was imported from \"${stringifyForError(importingType)}\". Modules with providers are not supported in standalone components imports.`);\n } else {\n throw new Error(`The \"${stringifyForError(depType)}\" type, imported from \"${stringifyForError(importingType)}\", must be a standalone component / directive / pipe or an NgModule. Did you forget to add the required @Component / @Directive / @Pipe or @NgModule annotation?`);\n }\n }\n }\n}\n\n/**\n * Indicates whether to use the runtime dependency tracker for scope calculation in JIT compilation.\n * The value \"false\" means the old code path based on patching scope info into the types will be\n * used.\n *\n * @deprecated For migration purposes only, to be removed soon.\n */\nconst USE_RUNTIME_DEPS_TRACKER_FOR_JIT = true;\n/**\n * An implementation of DepsTrackerApi which will be used for JIT and local compilation.\n */\nclass DepsTracker {\n ownerNgModule = new Map();\n ngModulesWithSomeUnresolvedDecls = new Set();\n ngModulesScopeCache = new Map();\n standaloneComponentsScopeCache = new Map();\n /**\n * Attempts to resolve ng module's forward ref declarations as much as possible and add them to\n * the `ownerNgModule` map. This method normally should be called after the initial parsing when\n * all the forward refs are resolved (e.g., when trying to render a component)\n */\n resolveNgModulesDecls() {\n if (this.ngModulesWithSomeUnresolvedDecls.size === 0) {\n return;\n }\n for (const moduleType of this.ngModulesWithSomeUnresolvedDecls) {\n const def = getNgModuleDef(moduleType);\n if (def?.declarations) {\n for (const decl of maybeUnwrapFn(def.declarations)) {\n if (isComponent(decl)) {\n this.ownerNgModule.set(decl, moduleType);\n }\n }\n }\n }\n this.ngModulesWithSomeUnresolvedDecls.clear();\n }\n /** @override */\n getComponentDependencies(type, rawImports) {\n this.resolveNgModulesDecls();\n const def = getComponentDef(type);\n if (def === null) {\n throw new Error(`Attempting to get component dependencies for a type that is not a component: ${type}`);\n }\n if (def.standalone) {\n const scope = this.getStandaloneComponentScope(type, rawImports);\n if (scope.compilation.isPoisoned) {\n return {\n dependencies: []\n };\n }\n return {\n dependencies: [...scope.compilation.directives, ...scope.compilation.pipes, ...scope.compilation.ngModules]\n };\n } else {\n if (!this.ownerNgModule.has(type)) {\n // This component is orphan! No need to handle the error since the component rendering\n // pipeline (e.g., view_container_ref) will check for this error based on configs.\n return {\n dependencies: []\n };\n }\n const scope = this.getNgModuleScope(this.ownerNgModule.get(type));\n if (scope.compilation.isPoisoned) {\n return {\n dependencies: []\n };\n }\n return {\n dependencies: [...scope.compilation.directives, ...scope.compilation.pipes]\n };\n }\n }\n /**\n * @override\n * This implementation does not make use of param scopeInfo since it assumes the scope info is\n * already added to the type itself through methods like {@link ɵɵsetNgModuleScope}\n */\n registerNgModule(type, scopeInfo) {\n if (!isNgModule(type)) {\n throw new Error(`Attempting to register a Type which is not NgModule as NgModule: ${type}`);\n }\n // Lazily process the NgModules later when needed.\n this.ngModulesWithSomeUnresolvedDecls.add(type);\n }\n /** @override */\n clearScopeCacheFor(type) {\n this.ngModulesScopeCache.delete(type);\n this.standaloneComponentsScopeCache.delete(type);\n }\n /** @override */\n getNgModuleScope(type) {\n if (this.ngModulesScopeCache.has(type)) {\n return this.ngModulesScopeCache.get(type);\n }\n const scope = this.computeNgModuleScope(type);\n this.ngModulesScopeCache.set(type, scope);\n return scope;\n }\n /** Compute NgModule scope afresh. */\n computeNgModuleScope(type) {\n const def = getNgModuleDef(type, true);\n const scope = {\n exported: {\n directives: new Set(),\n pipes: new Set()\n },\n compilation: {\n directives: new Set(),\n pipes: new Set()\n }\n };\n // Analyzing imports\n for (const imported of maybeUnwrapFn(def.imports)) {\n if (isNgModule(imported)) {\n const importedScope = this.getNgModuleScope(imported);\n // When this module imports another, the imported module's exported directives and pipes\n // are added to the compilation scope of this module.\n addSet(importedScope.exported.directives, scope.compilation.directives);\n addSet(importedScope.exported.pipes, scope.compilation.pipes);\n } else if (isStandalone(imported)) {\n if (isDirective(imported) || isComponent(imported)) {\n scope.compilation.directives.add(imported);\n } else if (isPipe(imported)) {\n scope.compilation.pipes.add(imported);\n } else {\n // The standalone thing is neither a component nor a directive nor a pipe ... (what?)\n throw new RuntimeError(980 /* RuntimeErrorCode.RUNTIME_DEPS_INVALID_IMPORTED_TYPE */, 'The standalone imported type is neither a component nor a directive nor a pipe');\n }\n } else {\n // The import is neither a module nor a module-with-providers nor a standalone thing. This\n // is going to be an error. So we short circuit.\n scope.compilation.isPoisoned = true;\n break;\n }\n }\n // Analyzing declarations\n if (!scope.compilation.isPoisoned) {\n for (const decl of maybeUnwrapFn(def.declarations)) {\n // Cannot declare another NgModule or a standalone thing\n if (isNgModule(decl) || isStandalone(decl)) {\n scope.compilation.isPoisoned = true;\n break;\n }\n if (isPipe(decl)) {\n scope.compilation.pipes.add(decl);\n } else {\n // decl is either a directive or a component. The component may not yet have the ɵcmp due\n // to async compilation.\n scope.compilation.directives.add(decl);\n }\n }\n }\n // Analyzing exports\n for (const exported of maybeUnwrapFn(def.exports)) {\n if (isNgModule(exported)) {\n // When this module exports another, the exported module's exported directives and pipes\n // are added to both the compilation and exported scopes of this module.\n const exportedScope = this.getNgModuleScope(exported);\n // Based on the current logic there is no way to have poisoned exported scope. So no need to\n // check for it.\n addSet(exportedScope.exported.directives, scope.exported.directives);\n addSet(exportedScope.exported.pipes, scope.exported.pipes);\n // Some test toolings which run in JIT mode depend on this behavior that the exported scope\n // should also be present in the compilation scope, even though AoT does not support this\n // and it is also in odds with NgModule metadata definitions. Without this some tests in\n // Google will fail.\n addSet(exportedScope.exported.directives, scope.compilation.directives);\n addSet(exportedScope.exported.pipes, scope.compilation.pipes);\n } else if (isPipe(exported)) {\n scope.exported.pipes.add(exported);\n } else {\n scope.exported.directives.add(exported);\n }\n }\n return scope;\n }\n /** @override */\n getStandaloneComponentScope(type, rawImports) {\n if (this.standaloneComponentsScopeCache.has(type)) {\n return this.standaloneComponentsScopeCache.get(type);\n }\n const ans = this.computeStandaloneComponentScope(type, rawImports);\n this.standaloneComponentsScopeCache.set(type, ans);\n return ans;\n }\n computeStandaloneComponentScope(type, rawImports) {\n const ans = {\n compilation: {\n // Standalone components are always able to self-reference.\n directives: new Set([type]),\n pipes: new Set(),\n ngModules: new Set()\n }\n };\n for (const rawImport of flatten(rawImports ?? [])) {\n const imported = resolveForwardRef(rawImport);\n try {\n verifyStandaloneImport(imported, type);\n } catch (e) {\n // Short-circuit if an import is not valid\n ans.compilation.isPoisoned = true;\n return ans;\n }\n if (isNgModule(imported)) {\n ans.compilation.ngModules.add(imported);\n const importedScope = this.getNgModuleScope(imported);\n // Short-circuit if an imported NgModule has corrupted exported scope.\n if (importedScope.exported.isPoisoned) {\n ans.compilation.isPoisoned = true;\n return ans;\n }\n addSet(importedScope.exported.directives, ans.compilation.directives);\n addSet(importedScope.exported.pipes, ans.compilation.pipes);\n } else if (isPipe(imported)) {\n ans.compilation.pipes.add(imported);\n } else if (isDirective(imported) || isComponent(imported)) {\n ans.compilation.directives.add(imported);\n } else {\n // The imported thing is not module/pipe/directive/component, so we error and short-circuit\n // here\n ans.compilation.isPoisoned = true;\n return ans;\n }\n }\n return ans;\n }\n /** @override */\n isOrphanComponent(cmp) {\n const def = getComponentDef(cmp);\n if (!def || def.standalone) {\n return false;\n }\n this.resolveNgModulesDecls();\n return !this.ownerNgModule.has(cmp);\n }\n}\nfunction addSet(sourceSet, targetSet) {\n for (const m of sourceSet) {\n targetSet.add(m);\n }\n}\n/** The deps tracker to be used in the current Angular app in dev mode. */\nconst depsTracker = new DepsTracker();\nconst TEST_ONLY = {\n DepsTracker\n};\n\n/**\n * Compute the static styling (class/style) from `TAttributes`.\n *\n * This function should be called during `firstCreatePass` only.\n *\n * @param tNode The `TNode` into which the styling information should be loaded.\n * @param attrs `TAttributes` containing the styling information.\n * @param writeToHost Where should the resulting static styles be written?\n * - `false` Write to `TNode.stylesWithoutHost` / `TNode.classesWithoutHost`\n * - `true` Write to `TNode.styles` / `TNode.classes`\n */\nfunction computeStaticStyling(tNode, attrs, writeToHost) {\n ngDevMode && assertFirstCreatePass(getTView(), 'Expecting to be called in first template pass only');\n let styles = writeToHost ? tNode.styles : null;\n let classes = writeToHost ? tNode.classes : null;\n let mode = 0;\n if (attrs !== null) {\n for (let i = 0; i < attrs.length; i++) {\n const value = attrs[i];\n if (typeof value === 'number') {\n mode = value;\n } else if (mode == 1 /* AttributeMarker.Classes */) {\n classes = concatStringsWithSpace(classes, value);\n } else if (mode == 2 /* AttributeMarker.Styles */) {\n const style = value;\n const styleValue = attrs[++i];\n styles = concatStringsWithSpace(styles, style + ': ' + styleValue + ';');\n }\n }\n }\n writeToHost ? tNode.styles = styles : tNode.stylesWithoutHost = styles;\n writeToHost ? tNode.classes = classes : tNode.classesWithoutHost = classes;\n}\nfunction ɵɵdirectiveInject(token, flags = InjectFlags.Default) {\n const lView = getLView();\n // Fall back to inject() if view hasn't been created. This situation can happen in tests\n // if inject utilities are used before bootstrapping.\n if (lView === null) {\n // Verify that we will not get into infinite loop.\n ngDevMode && assertInjectImplementationNotEqual(ɵɵdirectiveInject);\n return ɵɵinject(token, flags);\n }\n const tNode = getCurrentTNode();\n const value = getOrCreateInjectable(tNode, lView, resolveForwardRef(token), flags);\n ngDevMode && emitInjectEvent(token, value, flags);\n return value;\n}\n/**\n * Throws an error indicating that a factory function could not be generated by the compiler for a\n * particular class.\n *\n * This instruction allows the actual error message to be optimized away when ngDevMode is turned\n * off, saving bytes of generated code while still providing a good experience in dev mode.\n *\n * The name of the class is not mentioned here, but will be in the generated factory function name\n * and thus in the stack trace.\n *\n * @codeGenApi\n */\nfunction ɵɵinvalidFactory() {\n const msg = ngDevMode ? `This constructor was not compatible with Dependency Injection.` : 'invalid';\n throw new Error(msg);\n}\n\n/**\n * Resolve the matched directives on a node.\n */\nfunction resolveDirectives(tView, lView, tNode, localRefs, directiveMatcher) {\n // Please make sure to have explicit type for `exportsMap`. Inferred type triggers bug in tsickle.\n ngDevMode && assertFirstCreatePass(tView);\n const exportsMap = localRefs === null ? null : {\n '': -1\n };\n const matchedDirectiveDefs = directiveMatcher(tView, tNode);\n if (matchedDirectiveDefs !== null) {\n let directiveDefs;\n let hostDirectiveDefs = null;\n let hostDirectiveRanges = null;\n const hostDirectiveResolution = resolveHostDirectives(matchedDirectiveDefs);\n if (hostDirectiveResolution === null) {\n directiveDefs = matchedDirectiveDefs;\n } else {\n [directiveDefs, hostDirectiveDefs, hostDirectiveRanges] = hostDirectiveResolution;\n }\n initializeDirectives(tView, lView, tNode, directiveDefs, exportsMap, hostDirectiveDefs, hostDirectiveRanges);\n }\n if (exportsMap !== null && localRefs !== null) {\n cacheMatchingLocalNames(tNode, localRefs, exportsMap);\n }\n}\n/** Caches local names and their matching directive indices for query and template lookups. */\nfunction cacheMatchingLocalNames(tNode, localRefs, exportsMap) {\n const localNames = tNode.localNames = [];\n // Local names must be stored in tNode in the same order that localRefs are defined\n // in the template to ensure the data is loaded in the same slots as their refs\n // in the template (for template queries).\n for (let i = 0; i < localRefs.length; i += 2) {\n const index = exportsMap[localRefs[i + 1]];\n if (index == null) throw new RuntimeError(-301 /* RuntimeErrorCode.EXPORT_NOT_FOUND */, ngDevMode && `Export of name '${localRefs[i + 1]}' not found!`);\n localNames.push(localRefs[i], index);\n }\n}\nfunction resolveHostDirectives(matches) {\n let componentDef = null;\n let hasHostDirectives = false;\n for (let i = 0; i < matches.length; i++) {\n const def = matches[i];\n if (i === 0 && isComponentDef(def)) {\n componentDef = def;\n }\n if (def.findHostDirectiveDefs !== null) {\n hasHostDirectives = true;\n break;\n }\n }\n if (!hasHostDirectives) {\n return null;\n }\n let allDirectiveDefs = null;\n let hostDirectiveDefs = null;\n let hostDirectiveRanges = null;\n // Components are inserted at the front of the matches array so that their lifecycle\n // hooks run before any directive lifecycle hooks. This appears to be for ViewEngine\n // compatibility. This logic doesn't make sense with host directives, because it\n // would allow the host directives to undo any overrides the host may have made.\n // To handle this case, the host directives of components are inserted at the beginning\n // of the array, followed by the component. As such, the insertion order is as follows:\n // 1. Host directives belonging to the selector-matched component.\n // 2. Selector-matched component.\n // 3. Host directives belonging to selector-matched directives.\n // 4. Selector-matched dir\n for (const def of matches) {\n if (def.findHostDirectiveDefs !== null) {\n allDirectiveDefs ??= [];\n hostDirectiveDefs ??= new Map();\n hostDirectiveRanges ??= new Map();\n resolveHostDirectivesForDef(def, allDirectiveDefs, hostDirectiveRanges, hostDirectiveDefs);\n }\n // Component definition needs to be pushed early to maintain the correct ordering.\n if (def === componentDef) {\n allDirectiveDefs ??= [];\n allDirectiveDefs.push(def);\n }\n }\n if (allDirectiveDefs !== null) {\n allDirectiveDefs.push(...(componentDef === null ? matches : matches.slice(1)));\n ngDevMode && assertNoDuplicateDirectives(allDirectiveDefs);\n return [allDirectiveDefs, hostDirectiveDefs, hostDirectiveRanges];\n }\n return null;\n}\nfunction resolveHostDirectivesForDef(def, allDirectiveDefs, hostDirectiveRanges, hostDirectiveDefs) {\n ngDevMode && assertDefined(def.findHostDirectiveDefs, 'Expected host directive resolve function');\n const start = allDirectiveDefs.length;\n // TODO(pk): probably could return matches instead of taking in an array to fill in?\n def.findHostDirectiveDefs(def, allDirectiveDefs, hostDirectiveDefs);\n // Note that these indexes are within the offset by `directiveStart`. We can't do the\n // offsetting here, because `directiveStart` hasn't been initialized on the TNode yet.\n hostDirectiveRanges.set(def, [start, allDirectiveDefs.length - 1]);\n}\n/**\n * Marks a given TNode as a component's host. This consists of:\n * - setting the component offset on the TNode.\n * - storing index of component's host element so it will be queued for view refresh during CD.\n */\nfunction markAsComponentHost(tView, hostTNode, componentOffset) {\n ngDevMode && assertFirstCreatePass(tView);\n ngDevMode && assertGreaterThan(componentOffset, -1, 'componentOffset must be great than -1');\n hostTNode.componentOffset = componentOffset;\n (tView.components ??= []).push(hostTNode.index);\n}\n/** Initializes the data structures necessary for a list of directives to be instantiated. */\nfunction initializeDirectives(tView, lView, tNode, directives, exportsMap, hostDirectiveDefs, hostDirectiveRanges) {\n ngDevMode && assertFirstCreatePass(tView);\n const directivesLength = directives.length;\n let hasSeenComponent = false;\n // Publishes the directive types to DI so they can be injected. Needs to\n // happen in a separate pass before the TNode flags have been initialized.\n for (let i = 0; i < directivesLength; i++) {\n const def = directives[i];\n if (!hasSeenComponent && isComponentDef(def)) {\n hasSeenComponent = true;\n markAsComponentHost(tView, tNode, i);\n }\n diPublicInInjector(getOrCreateNodeInjectorForNode(tNode, lView), tView, def.type);\n }\n initTNodeFlags(tNode, tView.data.length, directivesLength);\n // When the same token is provided by several directives on the same node, some rules apply in\n // the viewEngine:\n // - viewProviders have priority over providers\n // - the last directive in NgModule.declarations has priority over the previous one\n // So to match these rules, the order in which providers are added in the arrays is very\n // important.\n for (let i = 0; i < directivesLength; i++) {\n const def = directives[i];\n if (def.providersResolver) def.providersResolver(def);\n }\n let preOrderHooksFound = false;\n let preOrderCheckHooksFound = false;\n let directiveIdx = allocExpando(tView, lView, directivesLength, null);\n ngDevMode && assertSame(directiveIdx, tNode.directiveStart, 'TNode.directiveStart should point to just allocated space');\n // If there's at least one directive, we'll have to track it so initialize the map.\n if (directivesLength > 0) {\n tNode.directiveToIndex = new Map();\n }\n for (let i = 0; i < directivesLength; i++) {\n const def = directives[i];\n // Merge the attrs in the order of matches. This assumes that the first directive is the\n // component itself, so that the component has the least priority.\n tNode.mergedAttrs = mergeHostAttrs(tNode.mergedAttrs, def.hostAttrs);\n configureViewWithDirective(tView, tNode, lView, directiveIdx, def);\n saveNameToExportMap(directiveIdx, def, exportsMap);\n // If a directive has host directives, we need to track both its index and the range within\n // the host directives are declared. Host directives are not tracked, but should be resolved\n // by looking up the host and getting its indexes from there.\n if (hostDirectiveRanges !== null && hostDirectiveRanges.has(def)) {\n const [start, end] = hostDirectiveRanges.get(def);\n tNode.directiveToIndex.set(def.type, [directiveIdx, start + tNode.directiveStart, end + tNode.directiveStart]);\n } else if (hostDirectiveDefs === null || !hostDirectiveDefs.has(def)) {\n tNode.directiveToIndex.set(def.type, directiveIdx);\n }\n if (def.contentQueries !== null) tNode.flags |= 4 /* TNodeFlags.hasContentQuery */;\n if (def.hostBindings !== null || def.hostAttrs !== null || def.hostVars !== 0) tNode.flags |= 64 /* TNodeFlags.hasHostBindings */;\n const lifeCycleHooks = def.type.prototype;\n // Only push a node index into the preOrderHooks array if this is the first\n // pre-order hook found on this node.\n if (!preOrderHooksFound && (lifeCycleHooks.ngOnChanges || lifeCycleHooks.ngOnInit || lifeCycleHooks.ngDoCheck)) {\n // We will push the actual hook function into this array later during dir instantiation.\n // We cannot do it now because we must ensure hooks are registered in the same\n // order that directives are created (i.e. injection order).\n (tView.preOrderHooks ??= []).push(tNode.index);\n preOrderHooksFound = true;\n }\n if (!preOrderCheckHooksFound && (lifeCycleHooks.ngOnChanges || lifeCycleHooks.ngDoCheck)) {\n (tView.preOrderCheckHooks ??= []).push(tNode.index);\n preOrderCheckHooksFound = true;\n }\n directiveIdx++;\n }\n initializeInputAndOutputAliases(tView, tNode, hostDirectiveDefs);\n}\n/**\n * Initializes data structures required to work with directive inputs and outputs.\n * Initialization is done for all directives matched on a given TNode.\n */\nfunction initializeInputAndOutputAliases(tView, tNode, hostDirectiveDefs) {\n ngDevMode && assertFirstCreatePass(tView);\n for (let index = tNode.directiveStart; index < tNode.directiveEnd; index++) {\n const directiveDef = tView.data[index];\n if (hostDirectiveDefs === null || !hostDirectiveDefs.has(directiveDef)) {\n setupSelectorMatchedInputsOrOutputs(0 /* BindingType.Inputs */, tNode, directiveDef, index);\n setupSelectorMatchedInputsOrOutputs(1 /* BindingType.Outputs */, tNode, directiveDef, index);\n setupInitialInputs(tNode, index, false);\n } else {\n const hostDirectiveDef = hostDirectiveDefs.get(directiveDef);\n setupHostDirectiveInputsOrOutputs(0 /* BindingType.Inputs */, tNode, hostDirectiveDef, index);\n setupHostDirectiveInputsOrOutputs(1 /* BindingType.Outputs */, tNode, hostDirectiveDef, index);\n setupInitialInputs(tNode, index, true);\n }\n }\n}\n/**\n * Sets up the input/output bindings for a directive that was matched in the template through its\n * selector. This method is called repeatedly to build up all of the available inputs on a node.\n *\n * @param mode Whether inputs or outputs are being contructed.\n * @param tNode Node on which the bindings are being set up.\n * @param def Directive definition for which the bindings are being set up.\n * @param directiveIndex Index at which the directive instance will be stored in the LView.\n */\nfunction setupSelectorMatchedInputsOrOutputs(mode, tNode, def, directiveIndex) {\n const aliasMap = mode === 0 /* BindingType.Inputs */ ? def.inputs : def.outputs;\n for (const publicName in aliasMap) {\n if (aliasMap.hasOwnProperty(publicName)) {\n let bindings;\n if (mode === 0 /* BindingType.Inputs */) {\n bindings = tNode.inputs ??= {};\n } else {\n bindings = tNode.outputs ??= {};\n }\n bindings[publicName] ??= [];\n bindings[publicName].push(directiveIndex);\n setShadowStylingInputFlags(tNode, publicName);\n }\n }\n}\n/**\n * Sets up input/output bindings that were defined through host directives on a specific node.\n * @param mode Whether inputs or outputs are being contructed.\n * @param tNode Node on which the bindings are being set up.\n * @param config Host directive definition that is being set up.\n * @param directiveIndex Index at which the directive instance will be stored in the LView.\n */\nfunction setupHostDirectiveInputsOrOutputs(mode, tNode, config, directiveIndex) {\n const aliasMap = mode === 0 /* BindingType.Inputs */ ? config.inputs : config.outputs;\n for (const initialName in aliasMap) {\n if (aliasMap.hasOwnProperty(initialName)) {\n const publicName = aliasMap[initialName];\n let bindings;\n if (mode === 0 /* BindingType.Inputs */) {\n bindings = tNode.hostDirectiveInputs ??= {};\n } else {\n bindings = tNode.hostDirectiveOutputs ??= {};\n }\n bindings[publicName] ??= [];\n bindings[publicName].push(directiveIndex, initialName);\n setShadowStylingInputFlags(tNode, publicName);\n }\n }\n}\nfunction setShadowStylingInputFlags(tNode, publicName) {\n if (publicName === 'class') {\n tNode.flags |= 8 /* TNodeFlags.hasClassInput */;\n } else if (publicName === 'style') {\n tNode.flags |= 16 /* TNodeFlags.hasStyleInput */;\n }\n}\n/**\n * Sets up the initialInputData for a node and stores it in the template's static storage\n * so subsequent template invocations don't have to recalculate it.\n *\n * initialInputData is an array containing values that need to be set as input properties\n * for directives on this node, but only once on creation. We need this array to support\n * the case where you set an @Input property of a directive using attribute-like syntax.\n * e.g. if you have a `name` @Input, you can set it once like this:\n *\n * <my-component name=\"Bess\"></my-component>\n *\n * @param tNode TNode on which to set up the initial inputs.\n * @param directiveIndex Index of the directive that is currently being processed.\n */\nfunction setupInitialInputs(tNode, directiveIndex, isHostDirective) {\n const {\n attrs,\n inputs,\n hostDirectiveInputs\n } = tNode;\n if (attrs === null || !isHostDirective && inputs === null || isHostDirective && hostDirectiveInputs === null ||\n // Do not use unbound attributes as inputs to structural directives, since structural\n // directive inputs can only be set using microsyntax (e.g. `<div *dir=\"exp\">`).\n isInlineTemplate(tNode)) {\n tNode.initialInputs ??= [];\n tNode.initialInputs.push(null);\n return;\n }\n let inputsToStore = null;\n let i = 0;\n while (i < attrs.length) {\n const attrName = attrs[i];\n if (attrName === 0 /* AttributeMarker.NamespaceURI */) {\n // We do not allow inputs on namespaced attributes.\n i += 4;\n continue;\n } else if (attrName === 5 /* AttributeMarker.ProjectAs */) {\n // Skip over the `ngProjectAs` value.\n i += 2;\n continue;\n } else if (typeof attrName === 'number') {\n // If we hit any other attribute markers, we're done anyway. None of those are valid inputs.\n break;\n }\n if (!isHostDirective && inputs.hasOwnProperty(attrName)) {\n // Find the input's public name from the input store. Note that we can be found easier\n // through the directive def, but we want to do it using the inputs store so that it can\n // account for host directive aliases.\n const inputConfig = inputs[attrName];\n for (const index of inputConfig) {\n if (index === directiveIndex) {\n inputsToStore ??= [];\n inputsToStore.push(attrName, attrs[i + 1]);\n // A directive can't have multiple inputs with the same name so we can break here.\n break;\n }\n }\n } else if (isHostDirective && hostDirectiveInputs.hasOwnProperty(attrName)) {\n const config = hostDirectiveInputs[attrName];\n for (let j = 0; j < config.length; j += 2) {\n if (config[j] === directiveIndex) {\n inputsToStore ??= [];\n inputsToStore.push(config[j + 1], attrs[i + 1]);\n break;\n }\n }\n }\n i += 2;\n }\n tNode.initialInputs ??= [];\n tNode.initialInputs.push(inputsToStore);\n}\n/**\n * Setup directive for instantiation.\n *\n * We need to create a `NodeInjectorFactory` which is then inserted in both the `Blueprint` as well\n * as `LView`. `TView` gets the `DirectiveDef`.\n *\n * @param tView `TView`\n * @param tNode `TNode`\n * @param lView `LView`\n * @param directiveIndex Index where the directive will be stored in the Expando.\n * @param def `DirectiveDef`\n */\nfunction configureViewWithDirective(tView, tNode, lView, directiveIndex, def) {\n ngDevMode && assertGreaterThanOrEqual(directiveIndex, HEADER_OFFSET, 'Must be in Expando section');\n tView.data[directiveIndex] = def;\n const directiveFactory = def.factory || (def.factory = getFactoryDef(def.type, true));\n // Even though `directiveFactory` will already be using `ɵɵdirectiveInject` in its generated code,\n // we also want to support `inject()` directly from the directive constructor context so we set\n // `ɵɵdirectiveInject` as the inject implementation here too.\n const nodeInjectorFactory = new NodeInjectorFactory(directiveFactory, isComponentDef(def), ɵɵdirectiveInject);\n tView.blueprint[directiveIndex] = nodeInjectorFactory;\n lView[directiveIndex] = nodeInjectorFactory;\n registerHostBindingOpCodes(tView, tNode, directiveIndex, allocExpando(tView, lView, def.hostVars, NO_CHANGE), def);\n}\n/**\n * Add `hostBindings` to the `TView.hostBindingOpCodes`.\n *\n * @param tView `TView` to which the `hostBindings` should be added.\n * @param tNode `TNode` the element which contains the directive\n * @param directiveIdx Directive index in view.\n * @param directiveVarsIdx Where will the directive's vars be stored\n * @param def `ComponentDef`/`DirectiveDef`, which contains the `hostVars`/`hostBindings` to add.\n */\nfunction registerHostBindingOpCodes(tView, tNode, directiveIdx, directiveVarsIdx, def) {\n ngDevMode && assertFirstCreatePass(tView);\n const hostBindings = def.hostBindings;\n if (hostBindings) {\n let hostBindingOpCodes = tView.hostBindingOpCodes;\n if (hostBindingOpCodes === null) {\n hostBindingOpCodes = tView.hostBindingOpCodes = [];\n }\n const elementIndx = ~tNode.index;\n if (lastSelectedElementIdx(hostBindingOpCodes) != elementIndx) {\n // Conditionally add select element so that we are more efficient in execution.\n // NOTE: this is strictly not necessary and it trades code size for runtime perf.\n // (We could just always add it.)\n hostBindingOpCodes.push(elementIndx);\n }\n hostBindingOpCodes.push(directiveIdx, directiveVarsIdx, hostBindings);\n }\n}\n/**\n * Returns the last selected element index in the `HostBindingOpCodes`\n *\n * For perf reasons we don't need to update the selected element index in `HostBindingOpCodes` only\n * if it changes. This method returns the last index (or '0' if not found.)\n *\n * Selected element index are only the ones which are negative.\n */\nfunction lastSelectedElementIdx(hostBindingOpCodes) {\n let i = hostBindingOpCodes.length;\n while (i > 0) {\n const value = hostBindingOpCodes[--i];\n if (typeof value === 'number' && value < 0) {\n return value;\n }\n }\n return 0;\n}\n/**\n * Builds up an export map as directives are created, so local refs can be quickly mapped\n * to their directive instances.\n */\nfunction saveNameToExportMap(directiveIdx, def, exportsMap) {\n if (exportsMap) {\n if (def.exportAs) {\n for (let i = 0; i < def.exportAs.length; i++) {\n exportsMap[def.exportAs[i]] = directiveIdx;\n }\n }\n if (isComponentDef(def)) exportsMap[''] = directiveIdx;\n }\n}\n/**\n * Initializes the flags on the current node, setting all indices to the initial index,\n * the directive count to 0, and adding the isComponent flag.\n * @param index the initial index\n */\nfunction initTNodeFlags(tNode, index, numberOfDirectives) {\n ngDevMode && assertNotEqual(numberOfDirectives, tNode.directiveEnd - tNode.directiveStart, 'Reached the max number of directives');\n tNode.flags |= 1 /* TNodeFlags.isDirectiveHost */;\n // When the first directive is created on a node, save the index\n tNode.directiveStart = index;\n tNode.directiveEnd = index + numberOfDirectives;\n tNode.providerIndexes = index;\n}\nfunction assertNoDuplicateDirectives(directives) {\n // The array needs at least two elements in order to have duplicates.\n if (directives.length < 2) {\n return;\n }\n const seenDirectives = new Set();\n for (const current of directives) {\n if (seenDirectives.has(current)) {\n throw new RuntimeError(309 /* RuntimeErrorCode.DUPLICATE_DIRECTIVE */, `Directive ${current.type.name} matches multiple times on the same element. ` + `Directives can only match an element once.`);\n }\n seenDirectives.add(current);\n }\n}\nfunction elementStartFirstCreatePass(index, tView, lView, name, directiveMatcher, bindingsEnabled, attrsIndex, localRefsIndex) {\n ngDevMode && assertFirstCreatePass(tView);\n ngDevMode && ngDevMode.firstCreatePass++;\n const tViewConsts = tView.consts;\n const attrs = getConstant(tViewConsts, attrsIndex);\n const tNode = getOrCreateTNode(tView, index, 2 /* TNodeType.Element */, name, attrs);\n if (bindingsEnabled) {\n resolveDirectives(tView, lView, tNode, getConstant(tViewConsts, localRefsIndex), directiveMatcher);\n }\n // Merge the template attrs last so that they have the highest priority.\n tNode.mergedAttrs = mergeHostAttrs(tNode.mergedAttrs, tNode.attrs);\n if (tNode.attrs !== null) {\n computeStaticStyling(tNode, tNode.attrs, false);\n }\n if (tNode.mergedAttrs !== null) {\n computeStaticStyling(tNode, tNode.mergedAttrs, true);\n }\n if (tView.queries !== null) {\n tView.queries.elementStart(tView, tNode);\n }\n return tNode;\n}\nfunction elementEndFirstCreatePass(tView, tNode) {\n ngDevMode && assertFirstCreatePass(tView);\n registerPostOrderHooks(tView, tNode);\n if (isContentQueryHost(tNode)) {\n tView.queries.elementEnd(tNode);\n }\n}\nclass ComponentFactoryResolver extends ComponentFactoryResolver$1 {\n ngModule;\n /**\n * @param ngModule The NgModuleRef to which all resolved factories are bound.\n */\n constructor(ngModule) {\n super();\n this.ngModule = ngModule;\n }\n resolveComponentFactory(component) {\n ngDevMode && assertComponentType(component);\n const componentDef = getComponentDef(component);\n return new ComponentFactory(componentDef, this.ngModule);\n }\n}\nfunction toInputRefArray(map) {\n return Object.keys(map).map(name => {\n const [propName, flags, transform] = map[name];\n const inputData = {\n propName: propName,\n templateName: name,\n isSignal: (flags & InputFlags.SignalBased) !== 0\n };\n if (transform) {\n inputData.transform = transform;\n }\n return inputData;\n });\n}\nfunction toOutputRefArray(map) {\n return Object.keys(map).map(name => ({\n propName: map[name],\n templateName: name\n }));\n}\nfunction verifyNotAnOrphanComponent(componentDef) {\n // TODO(pk): create assert that verifies ngDevMode\n if ((typeof ngJitMode === 'undefined' || ngJitMode) && componentDef.debugInfo?.forbidOrphanRendering) {\n if (depsTracker.isOrphanComponent(componentDef.type)) {\n throw new RuntimeError(981 /* RuntimeErrorCode.RUNTIME_DEPS_ORPHAN_COMPONENT */, `Orphan component found! Trying to render the component ${debugStringifyTypeForError(componentDef.type)} without first loading the NgModule that declares it. It is recommended to make this component standalone in order to avoid this error. If this is not possible now, import the component's NgModule in the appropriate NgModule, or the standalone component in which you are trying to render this component. If this is a lazy import, load the NgModule lazily as well and use its module injector.`);\n }\n }\n}\nfunction createRootViewInjector(componentDef, environmentInjector, injector) {\n let realEnvironmentInjector = environmentInjector instanceof EnvironmentInjector ? environmentInjector : environmentInjector?.injector;\n if (realEnvironmentInjector && componentDef.getStandaloneInjector !== null) {\n realEnvironmentInjector = componentDef.getStandaloneInjector(realEnvironmentInjector) || realEnvironmentInjector;\n }\n const rootViewInjector = realEnvironmentInjector ? new ChainedInjector(injector, realEnvironmentInjector) : injector;\n return rootViewInjector;\n}\nfunction createRootLViewEnvironment(rootLViewInjector) {\n const rendererFactory = rootLViewInjector.get(RendererFactory2, null);\n if (rendererFactory === null) {\n throw new RuntimeError(407 /* RuntimeErrorCode.RENDERER_NOT_FOUND */, ngDevMode && 'Angular was not able to inject a renderer (RendererFactory2). ' + 'Likely this is due to a broken DI hierarchy. ' + 'Make sure that any injector used to create this component has a correct parent.');\n }\n const sanitizer = rootLViewInjector.get(Sanitizer, null);\n const changeDetectionScheduler = rootLViewInjector.get(ChangeDetectionScheduler, null);\n return {\n rendererFactory,\n sanitizer,\n changeDetectionScheduler\n };\n}\nfunction createHostElement(componentDef, render) {\n // Determine a tag name used for creating host elements when this component is created\n // dynamically. Default to 'div' if this component did not specify any tag name in its\n // selector.\n const tagName = (componentDef.selectors[0][0] || 'div').toLowerCase();\n const namespace = tagName === 'svg' ? SVG_NAMESPACE : tagName === 'math' ? MATH_ML_NAMESPACE : null;\n return createElementNode(render, tagName, namespace);\n}\n/**\n * ComponentFactory interface implementation.\n */\nclass ComponentFactory extends ComponentFactory$1 {\n componentDef;\n ngModule;\n selector;\n componentType;\n ngContentSelectors;\n isBoundToModule;\n cachedInputs = null;\n cachedOutputs = null;\n get inputs() {\n this.cachedInputs ??= toInputRefArray(this.componentDef.inputs);\n return this.cachedInputs;\n }\n get outputs() {\n this.cachedOutputs ??= toOutputRefArray(this.componentDef.outputs);\n return this.cachedOutputs;\n }\n /**\n * @param componentDef The component definition.\n * @param ngModule The NgModuleRef to which the factory is bound.\n */\n constructor(componentDef, ngModule) {\n super();\n this.componentDef = componentDef;\n this.ngModule = ngModule;\n this.componentType = componentDef.type;\n this.selector = stringifyCSSSelectorList(componentDef.selectors);\n this.ngContentSelectors = componentDef.ngContentSelectors ?? [];\n this.isBoundToModule = !!ngModule;\n }\n create(injector, projectableNodes, rootSelectorOrNode, environmentInjector) {\n profiler(22 /* ProfilerEvent.DynamicComponentStart */);\n const prevConsumer = setActiveConsumer$1(null);\n try {\n const cmpDef = this.componentDef;\n ngDevMode && verifyNotAnOrphanComponent(cmpDef);\n const tAttributes = rootSelectorOrNode ? ['ng-version', '19.2.1'] :\n // Extract attributes and classes from the first selector only to match VE behavior.\n extractAttrsAndClassesFromSelector(this.componentDef.selectors[0]);\n // Create the root view. Uses empty TView and ContentTemplate.\n const rootTView = createTView(0 /* TViewType.Root */, null, null, 1, 0, null, null, null, null, [tAttributes], null);\n const rootViewInjector = createRootViewInjector(cmpDef, environmentInjector || this.ngModule, injector);\n const environment = createRootLViewEnvironment(rootViewInjector);\n const hostRenderer = environment.rendererFactory.createRenderer(null, cmpDef);\n const hostElement = rootSelectorOrNode ? locateHostElement(hostRenderer, rootSelectorOrNode, cmpDef.encapsulation, rootViewInjector) : createHostElement(cmpDef, hostRenderer);\n const rootLView = createLView(null, rootTView, null, 512 /* LViewFlags.IsRoot */ | getInitialLViewFlagsFromDef(cmpDef), null, null, environment, hostRenderer, rootViewInjector, null, retrieveHydrationInfo(hostElement, rootViewInjector, true /* isRootView */));\n rootLView[HEADER_OFFSET] = hostElement;\n // rootView is the parent when bootstrapping\n // TODO(misko): it looks like we are entering view here but we don't really need to as\n // `renderView` does that. However as the code is written it is needed because\n // `createRootComponentView` and `createRootComponent` both read global state. Fixing those\n // issues would allow us to drop this.\n enterView(rootLView);\n let componentView = null;\n try {\n const hostTNode = elementStartFirstCreatePass(HEADER_OFFSET, rootTView, rootLView, '#host', () => [this.componentDef], true, 0);\n // ---- element instruction\n // TODO(crisbeto): in practice `hostRNode` should always be defined, but there are some\n // tests where the renderer is mocked out and `undefined` is returned. We should update the\n // tests so that this check can be removed.\n if (hostElement) {\n setupStaticAttributes(hostRenderer, hostElement, hostTNode);\n attachPatchData(hostElement, rootLView);\n }\n // TODO(pk): this logic is similar to the instruction code where a node can have directives\n createDirectivesInstances(rootTView, rootLView, hostTNode);\n executeContentQueries(rootTView, hostTNode, rootLView);\n elementEndFirstCreatePass(rootTView, hostTNode);\n if (projectableNodes !== undefined) {\n projectNodes(hostTNode, this.ngContentSelectors, projectableNodes);\n }\n componentView = getComponentLViewByIndex(hostTNode.index, rootLView);\n // TODO(pk): why do we need this logic?\n rootLView[CONTEXT] = componentView[CONTEXT];\n renderView(rootTView, rootLView, null);\n } catch (e) {\n // Stop tracking the views if creation failed since\n // the consumer won't have a way to dereference them.\n if (componentView !== null) {\n unregisterLView(componentView);\n }\n unregisterLView(rootLView);\n throw e;\n } finally {\n profiler(23 /* ProfilerEvent.DynamicComponentEnd */);\n leaveView();\n }\n return new ComponentRef(this.componentType, rootLView);\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n}\n/**\n * Represents an instance of a Component created via a {@link ComponentFactory}.\n *\n * `ComponentRef` provides access to the Component Instance as well other objects related to this\n * Component Instance and allows you to destroy the Component Instance via the {@link #destroy}\n * method.\n *\n */\nclass ComponentRef extends ComponentRef$1 {\n _rootLView;\n instance;\n hostView;\n changeDetectorRef;\n componentType;\n location;\n previousInputValues = null;\n _tNode;\n constructor(componentType, _rootLView) {\n super();\n this._rootLView = _rootLView;\n this._tNode = getTNode(_rootLView[TVIEW], HEADER_OFFSET);\n this.location = createElementRef(this._tNode, _rootLView);\n this.instance = getComponentLViewByIndex(this._tNode.index, _rootLView)[CONTEXT];\n this.hostView = this.changeDetectorRef = new ViewRef$1(_rootLView, undefined /* _cdRefInjectingView */, false /* notifyErrorHandler */);\n this.componentType = componentType;\n }\n setInput(name, value) {\n const tNode = this._tNode;\n this.previousInputValues ??= new Map();\n // Do not set the input if it is the same as the last value\n // This behavior matches `bindingUpdated` when binding inputs in templates.\n if (this.previousInputValues.has(name) && Object.is(this.previousInputValues.get(name), value)) {\n return;\n }\n const lView = this._rootLView;\n const hasSetInput = setAllInputsForProperty(tNode, lView[TVIEW], lView, name, value);\n this.previousInputValues.set(name, value);\n const childComponentLView = getComponentLViewByIndex(tNode.index, lView);\n markViewDirty(childComponentLView, 1 /* NotificationSource.SetInput */);\n if (ngDevMode && !hasSetInput) {\n const cmpNameForError = stringifyForError(this.componentType);\n let message = `Can't set value of the '${name}' input on the '${cmpNameForError}' component. `;\n message += `Make sure that the '${name}' property is annotated with @Input() or a mapped @Input('${name}') exists.`;\n reportUnknownPropertyError(message);\n }\n }\n get injector() {\n return new NodeInjector(this._tNode, this._rootLView);\n }\n destroy() {\n this.hostView.destroy();\n }\n onDestroy(callback) {\n this.hostView.onDestroy(callback);\n }\n}\n/** Projects the `projectableNodes` that were specified when creating a root component. */\nfunction projectNodes(tNode, ngContentSelectors, projectableNodes) {\n const projection = tNode.projection = [];\n for (let i = 0; i < ngContentSelectors.length; i++) {\n const nodesforSlot = projectableNodes[i];\n // Projectable nodes can be passed as array of arrays or an array of iterables (ngUpgrade\n // case). Here we do normalize passed data structure to be an array of arrays to avoid\n // complex checks down the line.\n // We also normalize the length of the passed in projectable nodes (to match the number of\n // <ng-container> slots defined by a component).\n projection.push(nodesforSlot != null && nodesforSlot.length ? Array.from(nodesforSlot) : null);\n }\n}\n\n/**\n * Represents a container where one or more views can be attached to a component.\n *\n * Can contain *host views* (created by instantiating a\n * component with the `createComponent()` method), and *embedded views*\n * (created by instantiating a `TemplateRef` with the `createEmbeddedView()` method).\n *\n * A view container instance can contain other view containers,\n * creating a view hierarchy.\n *\n * @usageNotes\n *\n * The example below demonstrates how the `createComponent` function can be used\n * to create an instance of a ComponentRef dynamically and attach it to an ApplicationRef,\n * so that it gets included into change detection cycles.\n *\n * Note: the example uses standalone components, but the function can also be used for\n * non-standalone components (declared in an NgModule) as well.\n *\n * ```angular-ts\n * @Component({\n * standalone: true,\n * selector: 'dynamic',\n * template: `<span>This is a content of a dynamic component.</span>`,\n * })\n * class DynamicComponent {\n * vcr = inject(ViewContainerRef);\n * }\n *\n * @Component({\n * standalone: true,\n * selector: 'app',\n * template: `<main>Hi! This is the main content.</main>`,\n * })\n * class AppComponent {\n * vcr = inject(ViewContainerRef);\n *\n * ngAfterViewInit() {\n * const compRef = this.vcr.createComponent(DynamicComponent);\n * compRef.changeDetectorRef.detectChanges();\n * }\n * }\n * ```\n *\n * @see {@link ComponentRef}\n * @see {@link EmbeddedViewRef}\n *\n * @publicApi\n */\nclass ViewContainerRef {\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = injectViewContainerRef;\n}\n/**\n * Creates a ViewContainerRef and stores it on the injector. Or, if the ViewContainerRef\n * already exists, retrieves the existing ViewContainerRef.\n *\n * @returns The ViewContainerRef instance to use\n */\nfunction injectViewContainerRef() {\n const previousTNode = getCurrentTNode();\n return createContainerRef(previousTNode, getLView());\n}\nconst VE_ViewContainerRef = ViewContainerRef;\n// TODO(alxhub): cleaning up this indirection triggers a subtle bug in Closure in g3. Once the fix\n// for that lands, this can be cleaned up.\nconst R3ViewContainerRef = class ViewContainerRef extends VE_ViewContainerRef {\n _lContainer;\n _hostTNode;\n _hostLView;\n constructor(_lContainer, _hostTNode, _hostLView) {\n super();\n this._lContainer = _lContainer;\n this._hostTNode = _hostTNode;\n this._hostLView = _hostLView;\n }\n get element() {\n return createElementRef(this._hostTNode, this._hostLView);\n }\n get injector() {\n return new NodeInjector(this._hostTNode, this._hostLView);\n }\n /** @deprecated No replacement */\n get parentInjector() {\n const parentLocation = getParentInjectorLocation(this._hostTNode, this._hostLView);\n if (hasParentInjector(parentLocation)) {\n const parentView = getParentInjectorView(parentLocation, this._hostLView);\n const injectorIndex = getParentInjectorIndex(parentLocation);\n ngDevMode && assertNodeInjector(parentView, injectorIndex);\n const parentTNode = parentView[TVIEW].data[injectorIndex + 8 /* NodeInjectorOffset.TNODE */];\n return new NodeInjector(parentTNode, parentView);\n } else {\n return new NodeInjector(null, this._hostLView);\n }\n }\n clear() {\n while (this.length > 0) {\n this.remove(this.length - 1);\n }\n }\n get(index) {\n const viewRefs = getViewRefs(this._lContainer);\n return viewRefs !== null && viewRefs[index] || null;\n }\n get length() {\n return this._lContainer.length - CONTAINER_HEADER_OFFSET;\n }\n createEmbeddedView(templateRef, context, indexOrOptions) {\n let index;\n let injector;\n if (typeof indexOrOptions === 'number') {\n index = indexOrOptions;\n } else if (indexOrOptions != null) {\n index = indexOrOptions.index;\n injector = indexOrOptions.injector;\n }\n const dehydratedView = findMatchingDehydratedView(this._lContainer, templateRef.ssrId);\n const viewRef = templateRef.createEmbeddedViewImpl(context || {}, injector, dehydratedView);\n this.insertImpl(viewRef, index, shouldAddViewToDom(this._hostTNode, dehydratedView));\n return viewRef;\n }\n createComponent(componentFactoryOrType, indexOrOptions, injector, projectableNodes, environmentInjector) {\n const isComponentFactory = componentFactoryOrType && !isType(componentFactoryOrType);\n let index;\n // This function supports 2 signatures and we need to handle options correctly for both:\n // 1. When first argument is a Component type. This signature also requires extra\n // options to be provided as object (more ergonomic option).\n // 2. First argument is a Component factory. In this case extra options are represented as\n // positional arguments. This signature is less ergonomic and will be deprecated.\n if (isComponentFactory) {\n if (ngDevMode) {\n assertEqual(typeof indexOrOptions !== 'object', true, 'It looks like Component factory was provided as the first argument ' + 'and an options object as the second argument. This combination of arguments ' + 'is incompatible. You can either change the first argument to provide Component ' + 'type or change the second argument to be a number (representing an index at ' + \"which to insert the new component's host view into this container)\");\n }\n index = indexOrOptions;\n } else {\n if (ngDevMode) {\n assertDefined(getComponentDef(componentFactoryOrType), `Provided Component class doesn't contain Component definition. ` + `Please check whether provided class has @Component decorator.`);\n assertEqual(typeof indexOrOptions !== 'number', true, 'It looks like Component type was provided as the first argument ' + \"and a number (representing an index at which to insert the new component's \" + 'host view into this container as the second argument. This combination of arguments ' + 'is incompatible. Please use an object as the second argument instead.');\n }\n const options = indexOrOptions || {};\n if (ngDevMode && options.environmentInjector && options.ngModuleRef) {\n throwError(`Cannot pass both environmentInjector and ngModuleRef options to createComponent().`);\n }\n index = options.index;\n injector = options.injector;\n projectableNodes = options.projectableNodes;\n environmentInjector = options.environmentInjector || options.ngModuleRef;\n }\n const componentFactory = isComponentFactory ? componentFactoryOrType : new ComponentFactory(getComponentDef(componentFactoryOrType));\n const contextInjector = injector || this.parentInjector;\n // If an `NgModuleRef` is not provided explicitly, try retrieving it from the DI tree.\n if (!environmentInjector && componentFactory.ngModule == null) {\n // For the `ComponentFactory` case, entering this logic is very unlikely, since we expect that\n // an instance of a `ComponentFactory`, resolved via `ComponentFactoryResolver` would have an\n // `ngModule` field. This is possible in some test scenarios and potentially in some JIT-based\n // use-cases. For the `ComponentFactory` case we preserve backwards-compatibility and try\n // using a provided injector first, then fall back to the parent injector of this\n // `ViewContainerRef` instance.\n //\n // For the factory-less case, it's critical to establish a connection with the module\n // injector tree (by retrieving an instance of an `NgModuleRef` and accessing its injector),\n // so that a component can use DI tokens provided in MgModules. For this reason, we can not\n // rely on the provided injector, since it might be detached from the DI tree (for example, if\n // it was created via `Injector.create` without specifying a parent injector, or if an\n // injector is retrieved from an `NgModuleRef` created via `createNgModule` using an\n // NgModule outside of a module tree). Instead, we always use `ViewContainerRef`'s parent\n // injector, which is normally connected to the DI tree, which includes module injector\n // subtree.\n const _injector = isComponentFactory ? contextInjector : this.parentInjector;\n // DO NOT REFACTOR. The code here used to have a `injector.get(NgModuleRef, null) ||\n // undefined` expression which seems to cause internal google apps to fail. This is documented\n // in the following internal bug issue: go/b/142967802\n const result = _injector.get(EnvironmentInjector, null);\n if (result) {\n environmentInjector = result;\n }\n }\n const componentDef = getComponentDef(componentFactory.componentType ?? {});\n const dehydratedView = findMatchingDehydratedView(this._lContainer, componentDef?.id ?? null);\n const rNode = dehydratedView?.firstChild ?? null;\n const componentRef = componentFactory.create(contextInjector, projectableNodes, rNode, environmentInjector);\n this.insertImpl(componentRef.hostView, index, shouldAddViewToDom(this._hostTNode, dehydratedView));\n return componentRef;\n }\n insert(viewRef, index) {\n return this.insertImpl(viewRef, index, true);\n }\n insertImpl(viewRef, index, addToDOM) {\n const lView = viewRef._lView;\n if (ngDevMode && viewRef.destroyed) {\n throw new Error('Cannot insert a destroyed View in a ViewContainer!');\n }\n if (viewAttachedToContainer(lView)) {\n // If view is already attached, detach it first so we clean up references appropriately.\n const prevIdx = this.indexOf(viewRef);\n // A view might be attached either to this or a different container. The `prevIdx` for\n // those cases will be:\n // equal to -1 for views attached to this ViewContainerRef\n // >= 0 for views attached to a different ViewContainerRef\n if (prevIdx !== -1) {\n this.detach(prevIdx);\n } else {\n const prevLContainer = lView[PARENT];\n ngDevMode && assertEqual(isLContainer(prevLContainer), true, 'An attached view should have its PARENT point to a container.');\n // We need to re-create a R3ViewContainerRef instance since those are not stored on\n // LView (nor anywhere else).\n const prevVCRef = new R3ViewContainerRef(prevLContainer, prevLContainer[T_HOST], prevLContainer[PARENT]);\n prevVCRef.detach(prevVCRef.indexOf(viewRef));\n }\n }\n // Logical operation of adding `LView` to `LContainer`\n const adjustedIdx = this._adjustIndex(index);\n const lContainer = this._lContainer;\n addLViewToLContainer(lContainer, lView, adjustedIdx, addToDOM);\n viewRef.attachToViewContainerRef();\n addToArray(getOrCreateViewRefs(lContainer), adjustedIdx, viewRef);\n return viewRef;\n }\n move(viewRef, newIndex) {\n if (ngDevMode && viewRef.destroyed) {\n throw new Error('Cannot move a destroyed View in a ViewContainer!');\n }\n return this.insert(viewRef, newIndex);\n }\n indexOf(viewRef) {\n const viewRefsArr = getViewRefs(this._lContainer);\n return viewRefsArr !== null ? viewRefsArr.indexOf(viewRef) : -1;\n }\n remove(index) {\n const adjustedIdx = this._adjustIndex(index, -1);\n const detachedView = detachView(this._lContainer, adjustedIdx);\n if (detachedView) {\n // Before destroying the view, remove it from the container's array of `ViewRef`s.\n // This ensures the view container length is updated before calling\n // `destroyLView`, which could recursively call view container methods that\n // rely on an accurate container length.\n // (e.g. a method on this view container being called by a child directive's OnDestroy\n // lifecycle hook)\n removeFromArray(getOrCreateViewRefs(this._lContainer), adjustedIdx);\n destroyLView(detachedView[TVIEW], detachedView);\n }\n }\n detach(index) {\n const adjustedIdx = this._adjustIndex(index, -1);\n const view = detachView(this._lContainer, adjustedIdx);\n const wasDetached = view && removeFromArray(getOrCreateViewRefs(this._lContainer), adjustedIdx) != null;\n return wasDetached ? new ViewRef$1(view) : null;\n }\n _adjustIndex(index, shift = 0) {\n if (index == null) {\n return this.length + shift;\n }\n if (ngDevMode) {\n assertGreaterThan(index, -1, `ViewRef index must be positive, got ${index}`);\n // +1 because it's legal to insert at the end.\n assertLessThan(index, this.length + 1 + shift, 'index');\n }\n return index;\n }\n};\nfunction getViewRefs(lContainer) {\n return lContainer[VIEW_REFS];\n}\nfunction getOrCreateViewRefs(lContainer) {\n return lContainer[VIEW_REFS] || (lContainer[VIEW_REFS] = []);\n}\n/**\n * Creates a ViewContainerRef and stores it on the injector.\n *\n * @param hostTNode The node that is requesting a ViewContainerRef\n * @param hostLView The view to which the node belongs\n * @returns The ViewContainerRef instance to use\n */\nfunction createContainerRef(hostTNode, hostLView) {\n ngDevMode && assertTNodeType(hostTNode, 12 /* TNodeType.AnyContainer */ | 3 /* TNodeType.AnyRNode */);\n let lContainer;\n const slotValue = hostLView[hostTNode.index];\n if (isLContainer(slotValue)) {\n // If the host is a container, we don't need to create a new LContainer\n lContainer = slotValue;\n } else {\n // An LContainer anchor can not be `null`, but we set it here temporarily\n // and update to the actual value later in this function (see\n // `_locateOrCreateAnchorNode`).\n lContainer = createLContainer(slotValue, hostLView, null, hostTNode);\n hostLView[hostTNode.index] = lContainer;\n addToEndOfViewTree(hostLView, lContainer);\n }\n _locateOrCreateAnchorNode(lContainer, hostLView, hostTNode, slotValue);\n return new R3ViewContainerRef(lContainer, hostTNode, hostLView);\n}\n/**\n * Creates and inserts a comment node that acts as an anchor for a view container.\n *\n * If the host is a regular element, we have to insert a comment node manually which will\n * be used as an anchor when inserting elements. In this specific case we use low-level DOM\n * manipulation to insert it.\n */\nfunction insertAnchorNode(hostLView, hostTNode) {\n const renderer = hostLView[RENDERER];\n ngDevMode && ngDevMode.rendererCreateComment++;\n const commentNode = renderer.createComment(ngDevMode ? 'container' : '');\n const hostNative = getNativeByTNode(hostTNode, hostLView);\n const parentOfHostNative = renderer.parentNode(hostNative);\n nativeInsertBefore(renderer, parentOfHostNative, commentNode, renderer.nextSibling(hostNative), false);\n return commentNode;\n}\nlet _locateOrCreateAnchorNode = createAnchorNode;\nlet _populateDehydratedViewsInLContainer = () => false; // noop by default\n/**\n * Looks up dehydrated views that belong to a given LContainer and populates\n * this information into the `LContainer[DEHYDRATED_VIEWS]` slot. When running\n * in client-only mode, this function is a noop.\n *\n * @param lContainer LContainer that should be populated.\n * @param tNode Corresponding TNode.\n * @param hostLView LView that hosts LContainer.\n * @returns a boolean flag that indicates whether a populating operation\n * was successful. The operation might be unsuccessful in case is has completed\n * previously, we are rendering in client-only mode or this content is located\n * in a skip hydration section.\n */\nfunction populateDehydratedViewsInLContainer(lContainer, tNode, hostLView) {\n return _populateDehydratedViewsInLContainer(lContainer, tNode, hostLView);\n}\n/**\n * Regular creation mode: an anchor is created and\n * assigned to the `lContainer[NATIVE]` slot.\n */\nfunction createAnchorNode(lContainer, hostLView, hostTNode, slotValue) {\n // We already have a native element (anchor) set, return.\n if (lContainer[NATIVE]) return;\n let commentNode;\n // If the host is an element container, the native host element is guaranteed to be a\n // comment and we can reuse that comment as anchor element for the new LContainer.\n // The comment node in question is already part of the DOM structure so we don't need to append\n // it again.\n if (hostTNode.type & 8 /* TNodeType.ElementContainer */) {\n commentNode = unwrapRNode(slotValue);\n } else {\n commentNode = insertAnchorNode(hostLView, hostTNode);\n }\n lContainer[NATIVE] = commentNode;\n}\n/**\n * Hydration logic that looks up all dehydrated views in this container\n * and puts them into `lContainer[DEHYDRATED_VIEWS]` slot.\n *\n * @returns a boolean flag that indicates whether a populating operation\n * was successful. The operation might be unsuccessful in case is has completed\n * previously, we are rendering in client-only mode or this content is located\n * in a skip hydration section.\n */\nfunction populateDehydratedViewsInLContainerImpl(lContainer, tNode, hostLView) {\n // We already have a native element (anchor) set and the process\n // of finding dehydrated views happened (so the `lContainer[DEHYDRATED_VIEWS]`\n // is not null), exit early.\n if (lContainer[NATIVE] && lContainer[DEHYDRATED_VIEWS]) {\n return true;\n }\n const hydrationInfo = hostLView[HYDRATION];\n const noOffsetIndex = tNode.index - HEADER_OFFSET;\n const isNodeCreationMode = !hydrationInfo || isInSkipHydrationBlock(tNode) || isDisconnectedNode$1(hydrationInfo, noOffsetIndex);\n // Regular creation mode.\n if (isNodeCreationMode) {\n return false;\n }\n // Hydration mode, looking up an anchor node and dehydrated views in DOM.\n const currentRNode = getSegmentHead(hydrationInfo, noOffsetIndex);\n const serializedViews = hydrationInfo.data[CONTAINERS]?.[noOffsetIndex];\n ngDevMode && assertDefined(serializedViews, 'Unexpected state: no hydration info available for a given TNode, ' + 'which represents a view container.');\n const [commentNode, dehydratedViews] = locateDehydratedViewsInContainer(currentRNode, serializedViews);\n if (ngDevMode) {\n validateMatchingNode(commentNode, Node.COMMENT_NODE, null, hostLView, tNode, true);\n // Do not throw in case this node is already claimed (thus `false` as a second\n // argument). If this container is created based on an `<ng-template>`, the comment\n // node would be already claimed from the `template` instruction. If an element acts\n // as an anchor (e.g. <div #vcRef>), a separate comment node would be created/located,\n // so we need to claim it here.\n markRNodeAsClaimedByHydration(commentNode, false);\n }\n lContainer[NATIVE] = commentNode;\n lContainer[DEHYDRATED_VIEWS] = dehydratedViews;\n return true;\n}\nfunction locateOrCreateAnchorNode(lContainer, hostLView, hostTNode, slotValue) {\n if (!_populateDehydratedViewsInLContainer(lContainer, hostTNode, hostLView)) {\n // Populating dehydrated views operation returned `false`, which indicates\n // that the logic was running in client-only mode, this an anchor comment\n // node should be created for this container.\n createAnchorNode(lContainer, hostLView, hostTNode, slotValue);\n }\n}\nfunction enableLocateOrCreateContainerRefImpl() {\n _locateOrCreateAnchorNode = locateOrCreateAnchorNode;\n _populateDehydratedViewsInLContainer = populateDehydratedViewsInLContainerImpl;\n}\nclass LQuery_ {\n queryList;\n matches = null;\n constructor(queryList) {\n this.queryList = queryList;\n }\n clone() {\n return new LQuery_(this.queryList);\n }\n setDirty() {\n this.queryList.setDirty();\n }\n}\nclass LQueries_ {\n queries;\n constructor(queries = []) {\n this.queries = queries;\n }\n createEmbeddedView(tView) {\n const tQueries = tView.queries;\n if (tQueries !== null) {\n const noOfInheritedQueries = tView.contentQueries !== null ? tView.contentQueries[0] : tQueries.length;\n const viewLQueries = [];\n // An embedded view has queries propagated from a declaration view at the beginning of the\n // TQueries collection and up until a first content query declared in the embedded view. Only\n // propagated LQueries are created at this point (LQuery corresponding to declared content\n // queries will be instantiated from the content query instructions for each directive).\n for (let i = 0; i < noOfInheritedQueries; i++) {\n const tQuery = tQueries.getByIndex(i);\n const parentLQuery = this.queries[tQuery.indexInDeclarationView];\n viewLQueries.push(parentLQuery.clone());\n }\n return new LQueries_(viewLQueries);\n }\n return null;\n }\n insertView(tView) {\n this.dirtyQueriesWithMatches(tView);\n }\n detachView(tView) {\n this.dirtyQueriesWithMatches(tView);\n }\n finishViewCreation(tView) {\n this.dirtyQueriesWithMatches(tView);\n }\n dirtyQueriesWithMatches(tView) {\n for (let i = 0; i < this.queries.length; i++) {\n if (getTQuery(tView, i).matches !== null) {\n this.queries[i].setDirty();\n }\n }\n }\n}\nclass TQueryMetadata_ {\n flags;\n read;\n predicate;\n constructor(predicate, flags, read = null) {\n this.flags = flags;\n this.read = read;\n // Compiler might not be able to pre-optimize and split multiple selectors.\n if (typeof predicate === 'string') {\n this.predicate = splitQueryMultiSelectors(predicate);\n } else {\n this.predicate = predicate;\n }\n }\n}\nclass TQueries_ {\n queries;\n constructor(queries = []) {\n this.queries = queries;\n }\n elementStart(tView, tNode) {\n ngDevMode && assertFirstCreatePass(tView, 'Queries should collect results on the first template pass only');\n for (let i = 0; i < this.queries.length; i++) {\n this.queries[i].elementStart(tView, tNode);\n }\n }\n elementEnd(tNode) {\n for (let i = 0; i < this.queries.length; i++) {\n this.queries[i].elementEnd(tNode);\n }\n }\n embeddedTView(tNode) {\n let queriesForTemplateRef = null;\n for (let i = 0; i < this.length; i++) {\n const childQueryIndex = queriesForTemplateRef !== null ? queriesForTemplateRef.length : 0;\n const tqueryClone = this.getByIndex(i).embeddedTView(tNode, childQueryIndex);\n if (tqueryClone) {\n tqueryClone.indexInDeclarationView = i;\n if (queriesForTemplateRef !== null) {\n queriesForTemplateRef.push(tqueryClone);\n } else {\n queriesForTemplateRef = [tqueryClone];\n }\n }\n }\n return queriesForTemplateRef !== null ? new TQueries_(queriesForTemplateRef) : null;\n }\n template(tView, tNode) {\n ngDevMode && assertFirstCreatePass(tView, 'Queries should collect results on the first template pass only');\n for (let i = 0; i < this.queries.length; i++) {\n this.queries[i].template(tView, tNode);\n }\n }\n getByIndex(index) {\n ngDevMode && assertIndexInRange(this.queries, index);\n return this.queries[index];\n }\n get length() {\n return this.queries.length;\n }\n track(tquery) {\n this.queries.push(tquery);\n }\n}\nclass TQuery_ {\n metadata;\n matches = null;\n indexInDeclarationView = -1;\n crossesNgTemplate = false;\n /**\n * A node index on which a query was declared (-1 for view queries and ones inherited from the\n * declaration template). We use this index (alongside with _appliesToNextNode flag) to know\n * when to apply content queries to elements in a template.\n */\n _declarationNodeIndex;\n /**\n * A flag indicating if a given query still applies to nodes it is crossing. We use this flag\n * (alongside with _declarationNodeIndex) to know when to stop applying content queries to\n * elements in a template.\n */\n _appliesToNextNode = true;\n constructor(metadata, nodeIndex = -1) {\n this.metadata = metadata;\n this._declarationNodeIndex = nodeIndex;\n }\n elementStart(tView, tNode) {\n if (this.isApplyingToNode(tNode)) {\n this.matchTNode(tView, tNode);\n }\n }\n elementEnd(tNode) {\n if (this._declarationNodeIndex === tNode.index) {\n this._appliesToNextNode = false;\n }\n }\n template(tView, tNode) {\n this.elementStart(tView, tNode);\n }\n embeddedTView(tNode, childQueryIndex) {\n if (this.isApplyingToNode(tNode)) {\n this.crossesNgTemplate = true;\n // A marker indicating a `<ng-template>` element (a placeholder for query results from\n // embedded views created based on this `<ng-template>`).\n this.addMatch(-tNode.index, childQueryIndex);\n return new TQuery_(this.metadata);\n }\n return null;\n }\n isApplyingToNode(tNode) {\n if (this._appliesToNextNode && (this.metadata.flags & 1 /* QueryFlags.descendants */) !== 1 /* QueryFlags.descendants */) {\n const declarationNodeIdx = this._declarationNodeIndex;\n let parent = tNode.parent;\n // Determine if a given TNode is a \"direct\" child of a node on which a content query was\n // declared (only direct children of query's host node can match with the descendants: false\n // option). There are 3 main use-case / conditions to consider here:\n // - <needs-target><i #target></i></needs-target>: here <i #target> parent node is a query\n // host node;\n // - <needs-target><ng-template [ngIf]=\"true\"><i #target></i></ng-template></needs-target>:\n // here <i #target> parent node is null;\n // - <needs-target><ng-container><i #target></i></ng-container></needs-target>: here we need\n // to go past `<ng-container>` to determine <i #target> parent node (but we shouldn't traverse\n // up past the query's host node!).\n while (parent !== null && parent.type & 8 /* TNodeType.ElementContainer */ && parent.index !== declarationNodeIdx) {\n parent = parent.parent;\n }\n return declarationNodeIdx === (parent !== null ? parent.index : -1);\n }\n return this._appliesToNextNode;\n }\n matchTNode(tView, tNode) {\n const predicate = this.metadata.predicate;\n if (Array.isArray(predicate)) {\n for (let i = 0; i < predicate.length; i++) {\n const name = predicate[i];\n this.matchTNodeWithReadOption(tView, tNode, getIdxOfMatchingSelector(tNode, name));\n // Also try matching the name to a provider since strings can be used as DI tokens too.\n this.matchTNodeWithReadOption(tView, tNode, locateDirectiveOrProvider(tNode, tView, name, false, false));\n }\n } else {\n if (predicate === TemplateRef) {\n if (tNode.type & 4 /* TNodeType.Container */) {\n this.matchTNodeWithReadOption(tView, tNode, -1);\n }\n } else {\n this.matchTNodeWithReadOption(tView, tNode, locateDirectiveOrProvider(tNode, tView, predicate, false, false));\n }\n }\n }\n matchTNodeWithReadOption(tView, tNode, nodeMatchIdx) {\n if (nodeMatchIdx !== null) {\n const read = this.metadata.read;\n if (read !== null) {\n if (read === ElementRef || read === ViewContainerRef || read === TemplateRef && tNode.type & 4 /* TNodeType.Container */) {\n this.addMatch(tNode.index, -2);\n } else {\n const directiveOrProviderIdx = locateDirectiveOrProvider(tNode, tView, read, false, false);\n if (directiveOrProviderIdx !== null) {\n this.addMatch(tNode.index, directiveOrProviderIdx);\n }\n }\n } else {\n this.addMatch(tNode.index, nodeMatchIdx);\n }\n }\n }\n addMatch(tNodeIdx, matchIdx) {\n if (this.matches === null) {\n this.matches = [tNodeIdx, matchIdx];\n } else {\n this.matches.push(tNodeIdx, matchIdx);\n }\n }\n}\n/**\n * Iterates over local names for a given node and returns directive index\n * (or -1 if a local name points to an element).\n *\n * @param tNode static data of a node to check\n * @param selector selector to match\n * @returns directive index, -1 or null if a selector didn't match any of the local names\n */\nfunction getIdxOfMatchingSelector(tNode, selector) {\n const localNames = tNode.localNames;\n if (localNames !== null) {\n for (let i = 0; i < localNames.length; i += 2) {\n if (localNames[i] === selector) {\n return localNames[i + 1];\n }\n }\n }\n return null;\n}\nfunction createResultByTNodeType(tNode, currentView) {\n if (tNode.type & (3 /* TNodeType.AnyRNode */ | 8 /* TNodeType.ElementContainer */)) {\n return createElementRef(tNode, currentView);\n } else if (tNode.type & 4 /* TNodeType.Container */) {\n return createTemplateRef(tNode, currentView);\n }\n return null;\n}\nfunction createResultForNode(lView, tNode, matchingIdx, read) {\n if (matchingIdx === -1) {\n // if read token and / or strategy is not specified, detect it using appropriate tNode type\n return createResultByTNodeType(tNode, lView);\n } else if (matchingIdx === -2) {\n // read a special token from a node injector\n return createSpecialToken(lView, tNode, read);\n } else {\n // read a token\n return getNodeInjectable(lView, lView[TVIEW], matchingIdx, tNode);\n }\n}\nfunction createSpecialToken(lView, tNode, read) {\n if (read === ElementRef) {\n return createElementRef(tNode, lView);\n } else if (read === TemplateRef) {\n return createTemplateRef(tNode, lView);\n } else if (read === ViewContainerRef) {\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */ | 12 /* TNodeType.AnyContainer */);\n return createContainerRef(tNode, lView);\n } else {\n ngDevMode && throwError(`Special token to read should be one of ElementRef, TemplateRef or ViewContainerRef but got ${stringify(read)}.`);\n }\n}\n/**\n * A helper function that creates query results for a given view. This function is meant to do the\n * processing once and only once for a given view instance (a set of results for a given view\n * doesn't change).\n */\nfunction materializeViewResults(tView, lView, tQuery, queryIndex) {\n const lQuery = lView[QUERIES].queries[queryIndex];\n if (lQuery.matches === null) {\n const tViewData = tView.data;\n const tQueryMatches = tQuery.matches;\n const result = [];\n for (let i = 0; tQueryMatches !== null && i < tQueryMatches.length; i += 2) {\n const matchedNodeIdx = tQueryMatches[i];\n if (matchedNodeIdx < 0) {\n // we at the <ng-template> marker which might have results in views created based on this\n // <ng-template> - those results will be in separate views though, so here we just leave\n // null as a placeholder\n result.push(null);\n } else {\n ngDevMode && assertIndexInRange(tViewData, matchedNodeIdx);\n const tNode = tViewData[matchedNodeIdx];\n result.push(createResultForNode(lView, tNode, tQueryMatches[i + 1], tQuery.metadata.read));\n }\n }\n lQuery.matches = result;\n }\n return lQuery.matches;\n}\n/**\n * A helper function that collects (already materialized) query results from a tree of views,\n * starting with a provided LView.\n */\nfunction collectQueryResults(tView, lView, queryIndex, result) {\n const tQuery = tView.queries.getByIndex(queryIndex);\n const tQueryMatches = tQuery.matches;\n if (tQueryMatches !== null) {\n const lViewResults = materializeViewResults(tView, lView, tQuery, queryIndex);\n for (let i = 0; i < tQueryMatches.length; i += 2) {\n const tNodeIdx = tQueryMatches[i];\n if (tNodeIdx > 0) {\n result.push(lViewResults[i / 2]);\n } else {\n const childQueryIndex = tQueryMatches[i + 1];\n const declarationLContainer = lView[-tNodeIdx];\n ngDevMode && assertLContainer(declarationLContainer);\n // collect matches for views inserted in this container\n for (let i = CONTAINER_HEADER_OFFSET; i < declarationLContainer.length; i++) {\n const embeddedLView = declarationLContainer[i];\n if (embeddedLView[DECLARATION_LCONTAINER] === embeddedLView[PARENT]) {\n collectQueryResults(embeddedLView[TVIEW], embeddedLView, childQueryIndex, result);\n }\n }\n // collect matches for views created from this declaration container and inserted into\n // different containers\n if (declarationLContainer[MOVED_VIEWS] !== null) {\n const embeddedLViews = declarationLContainer[MOVED_VIEWS];\n for (let i = 0; i < embeddedLViews.length; i++) {\n const embeddedLView = embeddedLViews[i];\n collectQueryResults(embeddedLView[TVIEW], embeddedLView, childQueryIndex, result);\n }\n }\n }\n }\n }\n return result;\n}\nfunction loadQueryInternal(lView, queryIndex) {\n ngDevMode && assertDefined(lView[QUERIES], 'LQueries should be defined when trying to load a query');\n ngDevMode && assertIndexInRange(lView[QUERIES].queries, queryIndex);\n return lView[QUERIES].queries[queryIndex].queryList;\n}\n/**\n * Creates a new instance of LQuery and returns its index in the collection of LQuery objects.\n *\n * @returns index in the collection of LQuery objects\n */\nfunction createLQuery(tView, lView, flags) {\n const queryList = new QueryList((flags & 4 /* QueryFlags.emitDistinctChangesOnly */) === 4 /* QueryFlags.emitDistinctChangesOnly */);\n storeCleanupWithContext(tView, lView, queryList, queryList.destroy);\n const lQueries = (lView[QUERIES] ??= new LQueries_()).queries;\n return lQueries.push(new LQuery_(queryList)) - 1;\n}\nfunction createViewQuery(predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n const tView = getTView();\n if (tView.firstCreatePass) {\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), -1);\n if ((flags & 2 /* QueryFlags.isStatic */) === 2 /* QueryFlags.isStatic */) {\n tView.staticViewQueries = true;\n }\n }\n return createLQuery(tView, getLView(), flags);\n}\nfunction createContentQuery(directiveIndex, predicate, flags, read) {\n ngDevMode && assertNumber(flags, 'Expecting flags');\n const tView = getTView();\n if (tView.firstCreatePass) {\n const tNode = getCurrentTNode();\n createTQuery(tView, new TQueryMetadata_(predicate, flags, read), tNode.index);\n saveContentQueryAndDirectiveIndex(tView, directiveIndex);\n if ((flags & 2 /* QueryFlags.isStatic */) === 2 /* QueryFlags.isStatic */) {\n tView.staticContentQueries = true;\n }\n }\n return createLQuery(tView, getLView(), flags);\n}\n/** Splits multiple selectors in the locator. */\nfunction splitQueryMultiSelectors(locator) {\n return locator.split(',').map(s => s.trim());\n}\nfunction createTQuery(tView, metadata, nodeIndex) {\n if (tView.queries === null) tView.queries = new TQueries_();\n tView.queries.track(new TQuery_(metadata, nodeIndex));\n}\nfunction saveContentQueryAndDirectiveIndex(tView, directiveIndex) {\n const tViewContentQueries = tView.contentQueries || (tView.contentQueries = []);\n const lastSavedDirectiveIndex = tViewContentQueries.length ? tViewContentQueries[tViewContentQueries.length - 1] : -1;\n if (directiveIndex !== lastSavedDirectiveIndex) {\n tViewContentQueries.push(tView.queries.length - 1, directiveIndex);\n }\n}\nfunction getTQuery(tView, index) {\n ngDevMode && assertDefined(tView.queries, 'TQueries must be defined to retrieve a TQuery');\n return tView.queries.getByIndex(index);\n}\n/**\n * A helper function collecting results from all the views where a given query was active.\n * @param lView\n * @param queryIndex\n */\nfunction getQueryResults(lView, queryIndex) {\n const tView = lView[TVIEW];\n const tQuery = getTQuery(tView, queryIndex);\n return tQuery.crossesNgTemplate ? collectQueryResults(tView, lView, queryIndex, []) : materializeViewResults(tView, lView, tQuery, queryIndex);\n}\n\n/**\n * A signal factory function in charge of creating a new computed signal capturing query\n * results. This centralized creation function is used by all types of queries (child / children,\n * required / optional).\n *\n * @param firstOnly indicates if all or only the first result should be returned\n * @param required indicates if at least one result is required\n * @returns a read-only signal with query results\n */\nfunction createQuerySignalFn(firstOnly, required, opts) {\n let node;\n const signalFn = createComputed$1(() => {\n // A dedicated signal that increments its value every time a query changes its dirty status. By\n // using this signal we can implement a query as computed and avoid creation of a specialized\n // reactive node type. Please note that a query gets marked dirty under the following\n // circumstances:\n // - a view (where a query is active) finished its first creation pass;\n // - a new view is inserted / deleted and it impacts query results.\n node._dirtyCounter();\n const value = refreshSignalQuery(node, firstOnly);\n if (required && value === undefined) {\n throw new RuntimeError(-951 /* RuntimeErrorCode.REQUIRED_QUERY_NO_VALUE */, ngDevMode && 'Child query result is required but no value is available.');\n }\n return value;\n });\n node = signalFn[SIGNAL$1];\n node._dirtyCounter = signal(0);\n node._flatValue = undefined;\n if (ngDevMode) {\n signalFn.toString = () => `[Query Signal]`;\n node.debugName = opts?.debugName;\n }\n return signalFn;\n}\nfunction createSingleResultOptionalQuerySignalFn(opts) {\n return createQuerySignalFn(/* firstOnly */true, /* required */false, opts);\n}\nfunction createSingleResultRequiredQuerySignalFn(opts) {\n return createQuerySignalFn(/* firstOnly */true, /* required */true, opts);\n}\nfunction createMultiResultQuerySignalFn(opts) {\n return createQuerySignalFn(/* firstOnly */false, /* required */false, opts);\n}\nfunction bindQueryToSignal(target, queryIndex) {\n const node = target[SIGNAL$1];\n node._lView = getLView();\n node._queryIndex = queryIndex;\n node._queryList = loadQueryInternal(node._lView, queryIndex);\n node._queryList.onDirty(() => node._dirtyCounter.update(v => v + 1));\n}\nfunction refreshSignalQuery(node, firstOnly) {\n const lView = node._lView;\n const queryIndex = node._queryIndex;\n // There are 2 conditions under which we want to return \"empty\" results instead of the ones\n // collected by a query:\n //\n // 1) a given query wasn't created yet (this is a period of time between the directive creation\n // and execution of the query creation function) - in this case a query doesn't exist yet and we\n // don't have any results to return.\n //\n // 2) we are in the process of constructing a view (the first\n // creation pass didn't finish) and a query might have partial results, but we don't want to\n // return those - instead we do delay results collection until all nodes had a chance of matching\n // and we can present consistent, \"atomic\" (on a view level) results.\n if (lView === undefined || queryIndex === undefined || lView[FLAGS] & 4 /* LViewFlags.CreationMode */) {\n return firstOnly ? undefined : EMPTY_ARRAY;\n }\n const queryList = loadQueryInternal(lView, queryIndex);\n const results = getQueryResults(lView, queryIndex);\n queryList.reset(results, unwrapElementRef);\n if (firstOnly) {\n return queryList.first;\n } else {\n // TODO: remove access to the private _changesDetected field by abstracting / removing usage of\n // QueryList in the signal-based queries (perf follow-up)\n const resultChanged = queryList._changesDetected;\n if (resultChanged || node._flatValue === undefined) {\n return node._flatValue = queryList.toArray();\n }\n return node._flatValue;\n }\n}\nfunction viewChildFn(locator, opts) {\n ngDevMode && assertInInjectionContext(viewChild);\n return createSingleResultOptionalQuerySignalFn(opts);\n}\nfunction viewChildRequiredFn(locator, opts) {\n ngDevMode && assertInInjectionContext(viewChild);\n return createSingleResultRequiredQuerySignalFn(opts);\n}\n/**\n * Initializes a view child query.\n *\n * Consider using `viewChild.required` for queries that should always match.\n *\n * @usageNotes\n * Create a child query in your component by declaring a\n * class field and initializing it with the `viewChild()` function.\n *\n * ```angular-ts\n * @Component({template: '<div #el></div><my-component #cmp />'})\n * export class TestComponent {\n * divEl = viewChild<ElementRef>('el'); // Signal<ElementRef|undefined>\n * divElRequired = viewChild.required<ElementRef>('el'); // Signal<ElementRef>\n * cmp = viewChild(MyComponent); // Signal<MyComponent|undefined>\n * cmpRequired = viewChild.required(MyComponent); // Signal<MyComponent>\n * }\n * ```\n *\n * @publicAPI\n * @initializerApiFunction\n */\nconst viewChild = (() => {\n // Note: This may be considered a side-effect, but nothing will depend on\n // this assignment, unless this `viewChild` constant export is accessed. It's a\n // self-contained side effect that is local to the user facing `viewChild` export.\n viewChildFn.required = viewChildRequiredFn;\n return viewChildFn;\n})();\n/**\n * Initializes a view children query.\n *\n * Query results are represented as a signal of a read-only collection containing all matched\n * elements.\n *\n * @usageNotes\n * Create a children query in your component by declaring a\n * class field and initializing it with the `viewChildren()` function.\n *\n * ```ts\n * @Component({...})\n * export class TestComponent {\n * divEls = viewChildren<ElementRef>('el'); // Signal<ReadonlyArray<ElementRef>>\n * }\n * ```\n *\n * @initializerApiFunction\n * @publicAPI\n */\nfunction viewChildren(locator, opts) {\n ngDevMode && assertInInjectionContext(viewChildren);\n return createMultiResultQuerySignalFn(opts);\n}\nfunction contentChildFn(locator, opts) {\n ngDevMode && assertInInjectionContext(contentChild);\n return createSingleResultOptionalQuerySignalFn(opts);\n}\nfunction contentChildRequiredFn(locator, opts) {\n ngDevMode && assertInInjectionContext(contentChildren);\n return createSingleResultRequiredQuerySignalFn(opts);\n}\n/**\n * Initializes a content child query. Consider using `contentChild.required` for queries that should\n * always match.\n *\n * @usageNotes\n * Create a child query in your component by declaring a\n * class field and initializing it with the `contentChild()` function.\n *\n * ```ts\n * @Component({...})\n * export class TestComponent {\n * headerEl = contentChild<ElementRef>('h'); // Signal<ElementRef|undefined>\n * headerElElRequired = contentChild.required<ElementRef>('h'); // Signal<ElementRef>\n * header = contentChild(MyHeader); // Signal<MyHeader|undefined>\n * headerRequired = contentChild.required(MyHeader); // Signal<MyHeader>\n * }\n * ```\n *\n * @initializerApiFunction\n * @publicAPI\n */\nconst contentChild = (() => {\n // Note: This may be considered a side-effect, but nothing will depend on\n // this assignment, unless this `viewChild` constant export is accessed. It's a\n // self-contained side effect that is local to the user facing `viewChild` export.\n contentChildFn.required = contentChildRequiredFn;\n return contentChildFn;\n})();\n/**\n * Initializes a content children query.\n *\n * Query results are represented as a signal of a read-only collection containing all matched\n * elements.\n *\n * @usageNotes\n * Create a children query in your component by declaring a\n * class field and initializing it with the `contentChildren()` function.\n *\n * ```ts\n * @Component({...})\n * export class TestComponent {\n * headerEl = contentChildren<ElementRef>('h'); // Signal<ReadonlyArray<ElementRef>>\n * }\n * ```\n *\n * @initializerApiFunction\n * @publicAPI\n */\nfunction contentChildren(locator, opts) {\n return createMultiResultQuerySignalFn(opts);\n}\n\n/**\n * Creates a model signal.\n *\n * @param initialValue The initial value.\n * Can be set to {@link REQUIRED_UNSET_VALUE} for required model signals.\n * @param options Additional options for the model.\n */\nfunction createModelSignal(initialValue, opts) {\n const node = Object.create(INPUT_SIGNAL_NODE);\n const emitterRef = new OutputEmitterRef();\n node.value = initialValue;\n function getter() {\n producerAccessed$1(node);\n assertModelSet(node.value);\n return node.value;\n }\n getter[SIGNAL$1] = node;\n getter.asReadonly = signalAsReadonlyFn.bind(getter);\n // TODO: Should we throw an error when updating a destroyed model?\n getter.set = newValue => {\n if (!node.equal(node.value, newValue)) {\n signalSetFn$1(node, newValue);\n emitterRef.emit(newValue);\n }\n };\n getter.update = updateFn => {\n assertModelSet(node.value);\n getter.set(updateFn(node.value));\n };\n getter.subscribe = emitterRef.subscribe.bind(emitterRef);\n getter.destroyRef = emitterRef.destroyRef;\n if (ngDevMode) {\n getter.toString = () => `[Model Signal: ${getter()}]`;\n node.debugName = opts?.debugName;\n }\n return getter;\n}\n/** Asserts that a model's value is set. */\nfunction assertModelSet(value) {\n if (value === REQUIRED_UNSET_VALUE) {\n throw new RuntimeError(952 /* RuntimeErrorCode.REQUIRED_MODEL_NO_VALUE */, ngDevMode && 'Model is required but no value is available yet.');\n }\n}\nfunction modelFunction(initialValue, opts) {\n ngDevMode && assertInInjectionContext(model);\n return createModelSignal(initialValue, opts);\n}\nfunction modelRequiredFunction(opts) {\n ngDevMode && assertInInjectionContext(model);\n return createModelSignal(REQUIRED_UNSET_VALUE, opts);\n}\n/**\n * `model` declares a writeable signal that is exposed as an input/output\n * pair on the containing directive.\n *\n * The input name is taken either from the class member or from the `alias` option.\n * The output name is generated by taking the input name and appending `Change`.\n *\n * @usageNotes\n *\n * To use `model()`, import the function from `@angular/core`.\n *\n * ```ts\n * import {model} from '@angular/core`;\n * ```\n *\n * Inside your component, introduce a new class member and initialize\n * it with a call to `model` or `model.required`.\n *\n * ```ts\n * @Directive({\n * ...\n * })\n * export class MyDir {\n * firstName = model<string>(); // ModelSignal<string|undefined>\n * lastName = model.required<string>(); // ModelSignal<string>\n * age = model(0); // ModelSignal<number>\n * }\n * ```\n *\n * Inside your component template, you can display the value of a `model`\n * by calling the signal.\n *\n * ```html\n * <span>{{firstName()}}</span>\n * ```\n *\n * Updating the `model` is equivalent to updating a writable signal.\n *\n * ```ts\n * updateName(newFirstName: string): void {\n * this.firstName.set(newFirstName);\n * }\n * ```\n *\n * @publicAPI\n * @initializerApiFunction\n */\nconst model = (() => {\n // Note: This may be considered a side-effect, but nothing will depend on\n // this assignment, unless this `model` constant export is accessed. It's a\n // self-contained side effect that is local to the user facing `model` export.\n modelFunction.required = modelRequiredFunction;\n return modelFunction;\n})();\n\n// Stores the default value of `emitDistinctChangesOnly` when the `emitDistinctChangesOnly` is not\n// explicitly set.\nconst emitDistinctChangesOnlyDefaultValue = true;\n/**\n * Base class for query metadata.\n *\n * @see {@link ContentChildren}\n * @see {@link ContentChild}\n * @see {@link ViewChildren}\n * @see {@link ViewChild}\n *\n * @publicApi\n */\nclass Query {}\n/**\n * ContentChildren decorator and metadata.\n *\n *\n * @Annotation\n * @publicApi\n */\nconst ContentChildren = makePropDecorator('ContentChildren', (selector, opts = {}) => ({\n selector,\n first: false,\n isViewQuery: false,\n descendants: false,\n emitDistinctChangesOnly: emitDistinctChangesOnlyDefaultValue,\n ...opts\n}), Query);\n/**\n * ContentChild decorator and metadata.\n *\n *\n * @Annotation\n *\n * @publicApi\n */\nconst ContentChild = makePropDecorator('ContentChild', (selector, opts = {}) => ({\n selector,\n first: true,\n isViewQuery: false,\n descendants: true,\n ...opts\n}), Query);\n/**\n * ViewChildren decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst ViewChildren = makePropDecorator('ViewChildren', (selector, opts = {}) => ({\n selector,\n first: false,\n isViewQuery: true,\n descendants: true,\n emitDistinctChangesOnly: emitDistinctChangesOnlyDefaultValue,\n ...opts\n}), Query);\n/**\n * ViewChild decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst ViewChild = makePropDecorator('ViewChild', (selector, opts) => ({\n selector,\n first: true,\n isViewQuery: true,\n descendants: true,\n ...opts\n}), Query);\n\n/**\n * Used to resolve resource URLs on `@Component` when used with JIT compilation.\n *\n * Example:\n * ```ts\n * @Component({\n * selector: 'my-comp',\n * templateUrl: 'my-comp.html', // This requires asynchronous resolution\n * })\n * class MyComponent{\n * }\n *\n * // Calling `renderComponent` will fail because `renderComponent` is a synchronous process\n * // and `MyComponent`'s `@Component.templateUrl` needs to be resolved asynchronously.\n *\n * // Calling `resolveComponentResources()` will resolve `@Component.templateUrl` into\n * // `@Component.template`, which allows `renderComponent` to proceed in a synchronous manner.\n *\n * // Use browser's `fetch()` function as the default resource resolution strategy.\n * resolveComponentResources(fetch).then(() => {\n * // After resolution all URLs have been converted into `template` strings.\n * renderComponent(MyComponent);\n * });\n *\n * ```\n *\n * NOTE: In AOT the resolution happens during compilation, and so there should be no need\n * to call this method outside JIT mode.\n *\n * @param resourceResolver a function which is responsible for returning a `Promise` to the\n * contents of the resolved URL. Browser's `fetch()` method is a good default implementation.\n */\nfunction resolveComponentResources(resourceResolver) {\n // Store all promises which are fetching the resources.\n const componentResolved = [];\n // Cache so that we don't fetch the same resource more than once.\n const urlMap = new Map();\n function cachedResourceResolve(url) {\n let promise = urlMap.get(url);\n if (!promise) {\n const resp = resourceResolver(url);\n urlMap.set(url, promise = resp.then(unwrapResponse));\n }\n return promise;\n }\n componentResourceResolutionQueue.forEach((component, type) => {\n const promises = [];\n if (component.templateUrl) {\n promises.push(cachedResourceResolve(component.templateUrl).then(template => {\n component.template = template;\n }));\n }\n const styles = typeof component.styles === 'string' ? [component.styles] : component.styles || [];\n component.styles = styles;\n if (component.styleUrl && component.styleUrls?.length) {\n throw new Error('@Component cannot define both `styleUrl` and `styleUrls`. ' + 'Use `styleUrl` if the component has one stylesheet, or `styleUrls` if it has multiple');\n } else if (component.styleUrls?.length) {\n const styleOffset = component.styles.length;\n const styleUrls = component.styleUrls;\n component.styleUrls.forEach((styleUrl, index) => {\n styles.push(''); // pre-allocate array.\n promises.push(cachedResourceResolve(styleUrl).then(style => {\n styles[styleOffset + index] = style;\n styleUrls.splice(styleUrls.indexOf(styleUrl), 1);\n if (styleUrls.length == 0) {\n component.styleUrls = undefined;\n }\n }));\n });\n } else if (component.styleUrl) {\n promises.push(cachedResourceResolve(component.styleUrl).then(style => {\n styles.push(style);\n component.styleUrl = undefined;\n }));\n }\n const fullyResolved = Promise.all(promises).then(() => componentDefResolved(type));\n componentResolved.push(fullyResolved);\n });\n clearResolutionOfComponentResourcesQueue();\n return Promise.all(componentResolved).then(() => undefined);\n}\nlet componentResourceResolutionQueue = new Map();\n// Track when existing ɵcmp for a Type is waiting on resources.\nconst componentDefPendingResolution = new Set();\nfunction maybeQueueResolutionOfComponentResources(type, metadata) {\n if (componentNeedsResolution(metadata)) {\n componentResourceResolutionQueue.set(type, metadata);\n componentDefPendingResolution.add(type);\n }\n}\nfunction isComponentDefPendingResolution(type) {\n return componentDefPendingResolution.has(type);\n}\nfunction componentNeedsResolution(component) {\n return !!(component.templateUrl && !component.hasOwnProperty('template') || component.styleUrls && component.styleUrls.length || component.styleUrl);\n}\nfunction clearResolutionOfComponentResourcesQueue() {\n const old = componentResourceResolutionQueue;\n componentResourceResolutionQueue = new Map();\n return old;\n}\nfunction restoreComponentResolutionQueue(queue) {\n componentDefPendingResolution.clear();\n queue.forEach((_, type) => componentDefPendingResolution.add(type));\n componentResourceResolutionQueue = queue;\n}\nfunction isComponentResourceResolutionQueueEmpty() {\n return componentResourceResolutionQueue.size === 0;\n}\nfunction unwrapResponse(response) {\n return typeof response == 'string' ? response : response.text();\n}\nfunction componentDefResolved(type) {\n componentDefPendingResolution.delete(type);\n}\n\n/**\n * Map of module-id to the corresponding NgModule.\n */\nconst modules = new Map();\n/**\n * Whether to check for duplicate NgModule registrations.\n *\n * This can be disabled for testing.\n */\nlet checkForDuplicateNgModules = true;\nfunction assertSameOrNotExisting(id, type, incoming) {\n if (type && type !== incoming && checkForDuplicateNgModules) {\n throw new Error(`Duplicate module registered for ${id} - ${stringify(type)} vs ${stringify(type.name)}`);\n }\n}\n/**\n * Adds the given NgModule type to Angular's NgModule registry.\n *\n * This is generated as a side-effect of NgModule compilation. Note that the `id` is passed in\n * explicitly and not read from the NgModule definition. This is for two reasons: it avoids a\n * megamorphic read, and in JIT there's a chicken-and-egg problem where the NgModule may not be\n * fully resolved when it's registered.\n *\n * @codeGenApi\n */\nfunction registerNgModuleType(ngModuleType, id) {\n const existing = modules.get(id) || null;\n assertSameOrNotExisting(id, existing, ngModuleType);\n modules.set(id, ngModuleType);\n}\nfunction clearModulesForTest() {\n modules.clear();\n}\nfunction getRegisteredNgModuleType(id) {\n return modules.get(id);\n}\n/**\n * Control whether the NgModule registration system enforces that each NgModule type registered has\n * a unique id.\n *\n * This is useful for testing as the NgModule registry cannot be properly reset between tests with\n * Angular's current API.\n */\nfunction setAllowDuplicateNgModuleIdsForTest(allowDuplicates) {\n checkForDuplicateNgModules = !allowDuplicates;\n}\n\n/**\n * Validation function invoked at runtime for each binding that might potentially\n * represent a security-sensitive attribute of an <iframe>.\n * See `IFRAME_SECURITY_SENSITIVE_ATTRS` in the\n * `packages/compiler/src/schema/dom_security_schema.ts` script for the full list\n * of such attributes.\n *\n * @codeGenApi\n */\nfunction ɵɵvalidateIframeAttribute(attrValue, tagName, attrName) {\n const lView = getLView();\n const tNode = getSelectedTNode();\n const element = getNativeByTNode(tNode, lView);\n // Restrict any dynamic bindings of security-sensitive attributes/properties\n // on an <iframe> for security reasons.\n if (tNode.type === 2 /* TNodeType.Element */ && tagName.toLowerCase() === 'iframe') {\n const iframe = element;\n // Unset previously applied `src` and `srcdoc` if we come across a situation when\n // a security-sensitive attribute is set later via an attribute/property binding.\n iframe.src = '';\n iframe.srcdoc = trustedHTMLFromString('');\n // Also remove the <iframe> from the document.\n nativeRemoveNode(lView[RENDERER], iframe);\n const errorMessage = ngDevMode && `Angular has detected that the \\`${attrName}\\` was applied ` + `as a binding to an <iframe>${getTemplateLocationDetails(lView)}. ` + `For security reasons, the \\`${attrName}\\` can be set on an <iframe> ` + `as a static attribute only. \\n` + `To fix this, switch the \\`${attrName}\\` binding to a static attribute ` + `in a template or in host bindings section.`;\n throw new RuntimeError(-910 /* RuntimeErrorCode.UNSAFE_IFRAME_ATTRS */, errorMessage);\n }\n return attrValue;\n}\n\n/**\n * Represents an instance of an `NgModule` created by an `NgModuleFactory`.\n * Provides access to the `NgModule` instance and related objects.\n *\n * @publicApi\n */\nclass NgModuleRef$1 {}\n/**\n * @publicApi\n *\n * @deprecated\n * This class was mostly used as a part of ViewEngine-based JIT API and is no longer needed in Ivy\n * JIT mode. Angular provides APIs that accept NgModule classes directly (such as\n * [PlatformRef.bootstrapModule](api/core/PlatformRef#bootstrapModule) and\n * [createNgModule](api/core/createNgModule)), consider switching to those APIs instead of\n * using factory-based ones.\n */\nclass NgModuleFactory$1 {}\n\n/**\n * Returns a new NgModuleRef instance based on the NgModule class and parent injector provided.\n *\n * @param ngModule NgModule class.\n * @param parentInjector Optional injector instance to use as a parent for the module injector. If\n * not provided, `NullInjector` will be used instead.\n * @returns NgModuleRef that represents an NgModule instance.\n *\n * @publicApi\n */\nfunction createNgModule(ngModule, parentInjector) {\n return new NgModuleRef(ngModule, parentInjector ?? null, []);\n}\n/**\n * The `createNgModule` function alias for backwards-compatibility.\n * Please avoid using it directly and use `createNgModule` instead.\n *\n * @deprecated Use `createNgModule` instead.\n */\nconst createNgModuleRef = createNgModule;\nclass NgModuleRef extends NgModuleRef$1 {\n ngModuleType;\n _parent;\n // tslint:disable-next-line:require-internal-with-underscore\n _bootstrapComponents = [];\n _r3Injector;\n instance;\n destroyCbs = [];\n // When bootstrapping a module we have a dependency graph that looks like this:\n // ApplicationRef -> ComponentFactoryResolver -> NgModuleRef. The problem is that if the\n // module being resolved tries to inject the ComponentFactoryResolver, it'll create a\n // circular dependency which will result in a runtime error, because the injector doesn't\n // exist yet. We work around the issue by creating the ComponentFactoryResolver ourselves\n // and providing it, rather than letting the injector resolve it.\n componentFactoryResolver = new ComponentFactoryResolver(this);\n constructor(ngModuleType, _parent, additionalProviders, runInjectorInitializers = true) {\n super();\n this.ngModuleType = ngModuleType;\n this._parent = _parent;\n const ngModuleDef = getNgModuleDef(ngModuleType);\n ngDevMode && assertDefined(ngModuleDef, `NgModule '${stringify(ngModuleType)}' is not a subtype of 'NgModuleType'.`);\n this._bootstrapComponents = maybeUnwrapFn(ngModuleDef.bootstrap);\n this._r3Injector = createInjectorWithoutInjectorInstances(ngModuleType, _parent, [{\n provide: NgModuleRef$1,\n useValue: this\n }, {\n provide: ComponentFactoryResolver$1,\n useValue: this.componentFactoryResolver\n }, ...additionalProviders], stringify(ngModuleType), new Set(['environment']));\n // We need to resolve the injector types separately from the injector creation, because\n // the module might be trying to use this ref in its constructor for DI which will cause a\n // circular error that will eventually error out, because the injector isn't created yet.\n if (runInjectorInitializers) {\n this.resolveInjectorInitializers();\n }\n }\n resolveInjectorInitializers() {\n this._r3Injector.resolveInjectorInitializers();\n this.instance = this._r3Injector.get(this.ngModuleType);\n }\n get injector() {\n return this._r3Injector;\n }\n destroy() {\n ngDevMode && assertDefined(this.destroyCbs, 'NgModule already destroyed');\n const injector = this._r3Injector;\n !injector.destroyed && injector.destroy();\n this.destroyCbs.forEach(fn => fn());\n this.destroyCbs = null;\n }\n onDestroy(callback) {\n ngDevMode && assertDefined(this.destroyCbs, 'NgModule already destroyed');\n this.destroyCbs.push(callback);\n }\n}\nclass NgModuleFactory extends NgModuleFactory$1 {\n moduleType;\n constructor(moduleType) {\n super();\n this.moduleType = moduleType;\n }\n create(parentInjector) {\n return new NgModuleRef(this.moduleType, parentInjector, []);\n }\n}\nfunction createNgModuleRefWithProviders(moduleType, parentInjector, additionalProviders) {\n return new NgModuleRef(moduleType, parentInjector, additionalProviders, false);\n}\nclass EnvironmentNgModuleRefAdapter extends NgModuleRef$1 {\n injector;\n componentFactoryResolver = new ComponentFactoryResolver(this);\n instance = null;\n constructor(config) {\n super();\n const injector = new R3Injector([...config.providers, {\n provide: NgModuleRef$1,\n useValue: this\n }, {\n provide: ComponentFactoryResolver$1,\n useValue: this.componentFactoryResolver\n }], config.parent || getNullInjector(), config.debugName, new Set(['environment']));\n this.injector = injector;\n if (config.runEnvironmentInitializers) {\n injector.resolveInjectorInitializers();\n }\n }\n destroy() {\n this.injector.destroy();\n }\n onDestroy(callback) {\n this.injector.onDestroy(callback);\n }\n}\n/**\n * Create a new environment injector.\n *\n * @param providers An array of providers.\n * @param parent A parent environment injector.\n * @param debugName An optional name for this injector instance, which will be used in error\n * messages.\n *\n * @publicApi\n */\nfunction createEnvironmentInjector(providers, parent, debugName = null) {\n const adapter = new EnvironmentNgModuleRefAdapter({\n providers,\n parent,\n debugName,\n runEnvironmentInitializers: true\n });\n return adapter.injector;\n}\n\n/**\n * A service used by the framework to create instances of standalone injectors. Those injectors are\n * created on demand in case of dynamic component instantiation and contain ambient providers\n * collected from the imports graph rooted at a given standalone component.\n */\nclass StandaloneService {\n _injector;\n cachedInjectors = new Map();\n constructor(_injector) {\n this._injector = _injector;\n }\n getOrCreateStandaloneInjector(componentDef) {\n if (!componentDef.standalone) {\n return null;\n }\n if (!this.cachedInjectors.has(componentDef)) {\n const providers = internalImportProvidersFrom(false, componentDef.type);\n const standaloneInjector = providers.length > 0 ? createEnvironmentInjector([providers], this._injector, `Standalone[${componentDef.type.name}]`) : null;\n this.cachedInjectors.set(componentDef, standaloneInjector);\n }\n return this.cachedInjectors.get(componentDef);\n }\n ngOnDestroy() {\n try {\n for (const injector of this.cachedInjectors.values()) {\n if (injector !== null) {\n injector.destroy();\n }\n }\n } finally {\n this.cachedInjectors.clear();\n }\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: StandaloneService,\n providedIn: 'environment',\n factory: () => new StandaloneService(ɵɵinject(EnvironmentInjector))\n });\n}\n\n/**\n * Create a component definition object.\n *\n *\n * # Example\n * ```ts\n * class MyComponent {\n * // Generated by Angular Template Compiler\n * // [Symbol] syntax will not be supported by TypeScript until v2.7\n * static ɵcmp = defineComponent({\n * ...\n * });\n * }\n * ```\n * @codeGenApi\n */\nfunction ɵɵdefineComponent(componentDefinition) {\n return noSideEffects(() => {\n // Initialize ngDevMode. This must be the first statement in ɵɵdefineComponent.\n // See the `initNgDevMode` docstring for more information.\n (typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode();\n const baseDef = getNgDirectiveDef(componentDefinition);\n const def = {\n ...baseDef,\n decls: componentDefinition.decls,\n vars: componentDefinition.vars,\n template: componentDefinition.template,\n consts: componentDefinition.consts || null,\n ngContentSelectors: componentDefinition.ngContentSelectors,\n onPush: componentDefinition.changeDetection === ChangeDetectionStrategy.OnPush,\n directiveDefs: null,\n // assigned in noSideEffects\n pipeDefs: null,\n // assigned in noSideEffects\n dependencies: baseDef.standalone && componentDefinition.dependencies || null,\n getStandaloneInjector: baseDef.standalone ? parentInjector => {\n return parentInjector.get(StandaloneService).getOrCreateStandaloneInjector(def);\n } : null,\n getExternalStyles: null,\n signals: componentDefinition.signals ?? false,\n data: componentDefinition.data || {},\n encapsulation: componentDefinition.encapsulation || ViewEncapsulation.Emulated,\n styles: componentDefinition.styles || EMPTY_ARRAY,\n _: null,\n schemas: componentDefinition.schemas || null,\n tView: null,\n id: ''\n };\n // TODO: Do we still need/want this ?\n if (baseDef.standalone) {\n performanceMarkFeature('NgStandalone');\n }\n initFeatures(def);\n const dependencies = componentDefinition.dependencies;\n def.directiveDefs = extractDefListOrFactory(dependencies, /* pipeDef */false);\n def.pipeDefs = extractDefListOrFactory(dependencies, /* pipeDef */true);\n def.id = getComponentId(def);\n return def;\n });\n}\nfunction extractDirectiveDef(type) {\n return getComponentDef(type) || getDirectiveDef(type);\n}\nfunction nonNull(value) {\n return value !== null;\n}\n/**\n * @codeGenApi\n */\nfunction ɵɵdefineNgModule(def) {\n return noSideEffects(() => {\n const res = {\n type: def.type,\n bootstrap: def.bootstrap || EMPTY_ARRAY,\n declarations: def.declarations || EMPTY_ARRAY,\n imports: def.imports || EMPTY_ARRAY,\n exports: def.exports || EMPTY_ARRAY,\n transitiveCompileScopes: null,\n schemas: def.schemas || null,\n id: def.id || null\n };\n return res;\n });\n}\n/**\n * Converts binding objects from the `DirectiveDefinition` into more efficient\n * lookup dictionaries that are optimized for the framework runtime.\n *\n * This function converts inputs or output directive information into new objects\n * where the public name conveniently maps to the minified internal field name.\n *\n * For inputs, the input flags are additionally persisted into the new data structure,\n * so that those can be quickly retrieved when needed.\n *\n * e.g. for\n *\n * ```ts\n * class Comp {\n * @Input()\n * propName1: string;\n *\n * @Input('publicName2')\n * declaredPropName2: number;\n *\n * inputSignal = input(3);\n * }\n * ```\n *\n * will be serialized as\n *\n * ```ts\n * {\n * propName1: 'propName1',\n * declaredPropName2: ['publicName2', 'declaredPropName2'],\n * inputSignal: [InputFlags.SignalBased, 'inputSignal'],\n * }\n * ```\n *\n * which is than translated by the minifier as:\n *\n * ```ts\n * {\n * minifiedPropName1: 'propName1',\n * minifiedPropName2: ['publicName2', 'declaredPropName2'],\n * minifiedInputSignal: [InputFlags.SignalBased, 'inputSignal'],\n * }\n * ```\n *\n * becomes: (public name => minifiedName + isSignal if needed)\n *\n * ```ts\n * {\n * 'propName1': 'minifiedPropName1',\n * 'publicName2': 'minifiedPropName2',\n * 'inputSignal': ['minifiedInputSignal', InputFlags.SignalBased],\n * }\n * ```\n *\n * Optionally the function can take `declaredInputs` which will result\n * in: (public name => declared name)\n *\n * ```ts\n * {\n * 'propName1': 'propName1',\n * 'publicName2': 'declaredPropName2',\n * 'inputSignal': 'inputSignal',\n * }\n * ```\n *\n\n */\nfunction parseAndConvertInputsForDefinition(obj, declaredInputs) {\n if (obj == null) return EMPTY_OBJ;\n const newLookup = {};\n for (const minifiedKey in obj) {\n if (obj.hasOwnProperty(minifiedKey)) {\n const value = obj[minifiedKey];\n let publicName;\n let declaredName;\n let inputFlags;\n let transform;\n if (Array.isArray(value)) {\n inputFlags = value[0];\n publicName = value[1];\n declaredName = value[2] ?? publicName; // declared name might not be set to save bytes.\n transform = value[3] || null;\n } else {\n publicName = value;\n declaredName = value;\n inputFlags = InputFlags.None;\n transform = null;\n }\n newLookup[publicName] = [minifiedKey, inputFlags, transform];\n declaredInputs[publicName] = declaredName;\n }\n }\n return newLookup;\n}\nfunction parseAndConvertOutputsForDefinition(obj) {\n if (obj == null) return EMPTY_OBJ;\n const newLookup = {};\n for (const minifiedKey in obj) {\n if (obj.hasOwnProperty(minifiedKey)) {\n newLookup[obj[minifiedKey]] = minifiedKey;\n }\n }\n return newLookup;\n}\n/**\n * Create a directive definition object.\n *\n * # Example\n * ```ts\n * class MyDirective {\n * // Generated by Angular Template Compiler\n * // [Symbol] syntax will not be supported by TypeScript until v2.7\n * static ɵdir = ɵɵdefineDirective({\n * ...\n * });\n * }\n * ```\n *\n * @codeGenApi\n */\nfunction ɵɵdefineDirective(directiveDefinition) {\n return noSideEffects(() => {\n const def = getNgDirectiveDef(directiveDefinition);\n initFeatures(def);\n return def;\n });\n}\n/**\n * Create a pipe definition object.\n *\n * # Example\n * ```ts\n * class MyPipe implements PipeTransform {\n * // Generated by Angular Template Compiler\n * static ɵpipe = definePipe({\n * ...\n * });\n * }\n * ```\n * @param pipeDef Pipe definition generated by the compiler\n *\n * @codeGenApi\n */\nfunction ɵɵdefinePipe(pipeDef) {\n return {\n type: pipeDef.type,\n name: pipeDef.name,\n factory: null,\n pure: pipeDef.pure !== false,\n standalone: pipeDef.standalone ?? true,\n onDestroy: pipeDef.type.prototype.ngOnDestroy || null\n };\n}\nfunction getNgDirectiveDef(directiveDefinition) {\n const declaredInputs = {};\n return {\n type: directiveDefinition.type,\n providersResolver: null,\n factory: null,\n hostBindings: directiveDefinition.hostBindings || null,\n hostVars: directiveDefinition.hostVars || 0,\n hostAttrs: directiveDefinition.hostAttrs || null,\n contentQueries: directiveDefinition.contentQueries || null,\n declaredInputs: declaredInputs,\n inputConfig: directiveDefinition.inputs || EMPTY_OBJ,\n exportAs: directiveDefinition.exportAs || null,\n standalone: directiveDefinition.standalone ?? true,\n signals: directiveDefinition.signals === true,\n selectors: directiveDefinition.selectors || EMPTY_ARRAY,\n viewQuery: directiveDefinition.viewQuery || null,\n features: directiveDefinition.features || null,\n setInput: null,\n findHostDirectiveDefs: null,\n hostDirectives: null,\n inputs: parseAndConvertInputsForDefinition(directiveDefinition.inputs, declaredInputs),\n outputs: parseAndConvertOutputsForDefinition(directiveDefinition.outputs),\n debugInfo: null\n };\n}\nfunction initFeatures(definition) {\n definition.features?.forEach(fn => fn(definition));\n}\nfunction extractDefListOrFactory(dependencies, pipeDef) {\n if (!dependencies) {\n return null;\n }\n const defExtractor = pipeDef ? getPipeDef$1 : extractDirectiveDef;\n return () => (typeof dependencies === 'function' ? dependencies() : dependencies).map(dep => defExtractor(dep)).filter(nonNull);\n}\n/**\n * A map that contains the generated component IDs and type.\n */\nconst GENERATED_COMP_IDS = new Map();\n/**\n * A method can returns a component ID from the component definition using a variant of DJB2 hash\n * algorithm.\n */\nfunction getComponentId(componentDef) {\n let hash = 0;\n // For components with i18n in templates, the `consts` array is generated by the compiler\n // as a function. If client and server bundles were produced with different minification\n // configurations, the serializable contents of the function body would be different on\n // the client and on the server. This might result in different ids generated. To avoid this\n // issue, we do not take the `consts` contents into account if it's a function.\n // See https://github.com/angular/angular/issues/58713.\n const componentDefConsts = typeof componentDef.consts === 'function' ? '' : componentDef.consts;\n // We cannot rely solely on the component selector as the same selector can be used in different\n // modules.\n //\n // `componentDef.style` is not used, due to it causing inconsistencies. Ex: when server\n // component styles has no sourcemaps and browsers do.\n //\n // Example:\n // https://github.com/angular/components/blob/d9f82c8f95309e77a6d82fd574c65871e91354c2/src/material/core/option/option.ts#L248\n // https://github.com/angular/components/blob/285f46dc2b4c5b127d356cb7c4714b221f03ce50/src/material/legacy-core/option/option.ts#L32\n const hashSelectors = [componentDef.selectors, componentDef.ngContentSelectors, componentDef.hostVars, componentDef.hostAttrs, componentDefConsts, componentDef.vars, componentDef.decls, componentDef.encapsulation, componentDef.standalone, componentDef.signals, componentDef.exportAs, JSON.stringify(componentDef.inputs), JSON.stringify(componentDef.outputs),\n // We cannot use 'componentDef.type.name' as the name of the symbol will change and will not\n // match in the server and browser bundles.\n Object.getOwnPropertyNames(componentDef.type.prototype), !!componentDef.contentQueries, !!componentDef.viewQuery];\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n // If client and server bundles were produced with different minification configurations,\n // the serializable contents of the function body would be different on the client and on\n // the server. Ensure that we do not accidentally use functions in component id computation.\n for (const item of hashSelectors) {\n assertNotEqual(typeof item, 'function', 'Internal error: attempting to use a function in component id computation logic.');\n }\n }\n for (const char of hashSelectors.join('|')) {\n hash = Math.imul(31, hash) + char.charCodeAt(0) << 0;\n }\n // Force positive number hash.\n // 2147483647 = equivalent of Integer.MAX_VALUE.\n hash += 2147483647 + 1;\n const compId = 'c' + hash;\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && (\n // Skip the check on the server since we can't guarantee the same component instance between\n // requests. Note that we can't use DI to check if we're on the server, because the component\n // hasn't been instantiated yet.\n typeof ngServerMode === 'undefined' || !ngServerMode)) {\n if (GENERATED_COMP_IDS.has(compId)) {\n const previousCompDefType = GENERATED_COMP_IDS.get(compId);\n if (previousCompDefType !== componentDef.type) {\n console.warn(formatRuntimeError(-912 /* RuntimeErrorCode.COMPONENT_ID_COLLISION */, `Component ID generation collision detected. Components '${previousCompDefType.name}' and '${componentDef.type.name}' with selector '${stringifyCSSSelectorList(componentDef.selectors)}' generated the same component ID. To fix this, you can change the selector of one of those components or add an extra host attribute to force a different ID.`));\n }\n } else {\n GENERATED_COMP_IDS.set(compId, componentDef.type);\n }\n }\n return compId;\n}\nfunction getSuperType(type) {\n return Object.getPrototypeOf(type.prototype).constructor;\n}\n/**\n * Merges the definition from a super class to a sub class.\n * @param definition The definition that is a SubClass of another directive of component\n *\n * @codeGenApi\n */\nfunction ɵɵInheritDefinitionFeature(definition) {\n let superType = getSuperType(definition.type);\n let shouldInheritFields = true;\n const inheritanceChain = [definition];\n while (superType) {\n let superDef = undefined;\n if (isComponentDef(definition)) {\n // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.\n superDef = superType.ɵcmp || superType.ɵdir;\n } else {\n if (superType.ɵcmp) {\n throw new RuntimeError(903 /* RuntimeErrorCode.INVALID_INHERITANCE */, ngDevMode && `Directives cannot inherit Components. Directive ${stringifyForError(definition.type)} is attempting to extend component ${stringifyForError(superType)}`);\n }\n // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.\n superDef = superType.ɵdir;\n }\n if (superDef) {\n if (shouldInheritFields) {\n inheritanceChain.push(superDef);\n // Some fields in the definition may be empty, if there were no values to put in them that\n // would've justified object creation. Unwrap them if necessary.\n const writeableDef = definition;\n writeableDef.inputs = maybeUnwrapEmpty(definition.inputs);\n writeableDef.declaredInputs = maybeUnwrapEmpty(definition.declaredInputs);\n writeableDef.outputs = maybeUnwrapEmpty(definition.outputs);\n // Merge hostBindings\n const superHostBindings = superDef.hostBindings;\n superHostBindings && inheritHostBindings(definition, superHostBindings);\n // Merge queries\n const superViewQuery = superDef.viewQuery;\n const superContentQueries = superDef.contentQueries;\n superViewQuery && inheritViewQuery(definition, superViewQuery);\n superContentQueries && inheritContentQueries(definition, superContentQueries);\n // Merge inputs and outputs\n mergeInputsWithTransforms(definition, superDef);\n fillProperties(definition.outputs, superDef.outputs);\n // Merge animations metadata.\n // If `superDef` is a Component, the `data` field is present (defaults to an empty object).\n if (isComponentDef(superDef) && superDef.data.animation) {\n // If super def is a Component, the `definition` is also a Component, since Directives can\n // not inherit Components (we throw an error above and cannot reach this code).\n const defData = definition.data;\n defData.animation = (defData.animation || []).concat(superDef.data.animation);\n }\n }\n // Run parent features\n const features = superDef.features;\n if (features) {\n for (let i = 0; i < features.length; i++) {\n const feature = features[i];\n if (feature && feature.ngInherit) {\n feature(definition);\n }\n // If `InheritDefinitionFeature` is a part of the current `superDef`, it means that this\n // def already has all the necessary information inherited from its super class(es), so we\n // can stop merging fields from super classes. However we need to iterate through the\n // prototype chain to look for classes that might contain other \"features\" (like\n // NgOnChanges), which we should invoke for the original `definition`. We set the\n // `shouldInheritFields` flag to indicate that, essentially skipping fields inheritance\n // logic and only invoking functions from the \"features\" list.\n if (feature === ɵɵInheritDefinitionFeature) {\n shouldInheritFields = false;\n }\n }\n }\n }\n superType = Object.getPrototypeOf(superType);\n }\n mergeHostAttrsAcrossInheritance(inheritanceChain);\n}\nfunction mergeInputsWithTransforms(target, source) {\n for (const key in source.inputs) {\n if (!source.inputs.hasOwnProperty(key)) {\n continue;\n }\n if (target.inputs.hasOwnProperty(key)) {\n continue;\n }\n const value = source.inputs[key];\n if (value !== undefined) {\n target.inputs[key] = value;\n target.declaredInputs[key] = source.declaredInputs[key];\n }\n }\n}\n/**\n * Merge the `hostAttrs` and `hostVars` from the inherited parent to the base class.\n *\n * @param inheritanceChain A list of `WritableDefs` starting at the top most type and listing\n * sub-types in order. For each type take the `hostAttrs` and `hostVars` and merge it with the child\n * type.\n */\nfunction mergeHostAttrsAcrossInheritance(inheritanceChain) {\n let hostVars = 0;\n let hostAttrs = null;\n // We process the inheritance order from the base to the leaves here.\n for (let i = inheritanceChain.length - 1; i >= 0; i--) {\n const def = inheritanceChain[i];\n // For each `hostVars`, we need to add the superclass amount.\n def.hostVars = hostVars += def.hostVars;\n // for each `hostAttrs` we need to merge it with superclass.\n def.hostAttrs = mergeHostAttrs(def.hostAttrs, hostAttrs = mergeHostAttrs(hostAttrs, def.hostAttrs));\n }\n}\nfunction maybeUnwrapEmpty(value) {\n if (value === EMPTY_OBJ) {\n return {};\n } else if (value === EMPTY_ARRAY) {\n return [];\n } else {\n return value;\n }\n}\nfunction inheritViewQuery(definition, superViewQuery) {\n const prevViewQuery = definition.viewQuery;\n if (prevViewQuery) {\n definition.viewQuery = (rf, ctx) => {\n superViewQuery(rf, ctx);\n prevViewQuery(rf, ctx);\n };\n } else {\n definition.viewQuery = superViewQuery;\n }\n}\nfunction inheritContentQueries(definition, superContentQueries) {\n const prevContentQueries = definition.contentQueries;\n if (prevContentQueries) {\n definition.contentQueries = (rf, ctx, directiveIndex) => {\n superContentQueries(rf, ctx, directiveIndex);\n prevContentQueries(rf, ctx, directiveIndex);\n };\n } else {\n definition.contentQueries = superContentQueries;\n }\n}\nfunction inheritHostBindings(definition, superHostBindings) {\n const prevHostBindings = definition.hostBindings;\n if (prevHostBindings) {\n definition.hostBindings = (rf, ctx) => {\n superHostBindings(rf, ctx);\n prevHostBindings(rf, ctx);\n };\n } else {\n definition.hostBindings = superHostBindings;\n }\n}\n\n/**\n * Fields which exist on either directive or component definitions, and need to be copied from\n * parent to child classes by the `ɵɵCopyDefinitionFeature`.\n */\nconst COPY_DIRECTIVE_FIELDS = [\n// The child class should use the providers of its parent.\n'providersResolver'\n// Not listed here are any fields which are handled by the `ɵɵInheritDefinitionFeature`, such\n// as inputs, outputs, and host binding functions.\n];\n/**\n * Fields which exist only on component definitions, and need to be copied from parent to child\n * classes by the `ɵɵCopyDefinitionFeature`.\n *\n * The type here allows any field of `ComponentDef` which is not also a property of `DirectiveDef`,\n * since those should go in `COPY_DIRECTIVE_FIELDS` above.\n */\nconst COPY_COMPONENT_FIELDS = [\n// The child class should use the template function of its parent, including all template\n// semantics.\n'template', 'decls', 'consts', 'vars', 'onPush', 'ngContentSelectors',\n// The child class should use the CSS styles of its parent, including all styling semantics.\n'styles', 'encapsulation',\n// The child class should be checked by the runtime in the same way as its parent.\n'schemas'];\n/**\n * Copies the fields not handled by the `ɵɵInheritDefinitionFeature` from the supertype of a\n * definition.\n *\n * This exists primarily to support ngcc migration of an existing View Engine pattern, where an\n * entire decorator is inherited from a parent to a child class. When ngcc detects this case, it\n * generates a skeleton definition on the child class, and applies this feature.\n *\n * The `ɵɵCopyDefinitionFeature` then copies any needed fields from the parent class' definition,\n * including things like the component template function.\n *\n * @param definition The definition of a child class which inherits from a parent class with its\n * own definition.\n *\n * @codeGenApi\n */\nfunction ɵɵCopyDefinitionFeature(definition) {\n let superType = getSuperType(definition.type);\n let superDef = undefined;\n if (isComponentDef(definition)) {\n // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.\n superDef = superType.ɵcmp;\n } else {\n // Don't use getComponentDef/getDirectiveDef. This logic relies on inheritance.\n superDef = superType.ɵdir;\n }\n // Needed because `definition` fields are readonly.\n const defAny = definition;\n // Copy over any fields that apply to either directives or components.\n for (const field of COPY_DIRECTIVE_FIELDS) {\n defAny[field] = superDef[field];\n }\n if (isComponentDef(superDef)) {\n // Copy over any component-specific fields.\n for (const field of COPY_COMPONENT_FIELDS) {\n defAny[field] = superDef[field];\n }\n }\n}\n\n/**\n * This feature adds the host directives behavior to a directive definition by patching a\n * function onto it. The expectation is that the runtime will invoke the function during\n * directive matching.\n *\n * For example:\n * ```ts\n * class ComponentWithHostDirective {\n * static ɵcmp = defineComponent({\n * type: ComponentWithHostDirective,\n * features: [ɵɵHostDirectivesFeature([\n * SimpleHostDirective,\n * {directive: AdvancedHostDirective, inputs: ['foo: alias'], outputs: ['bar']},\n * ])]\n * });\n * }\n * ```\n *\n * @codeGenApi\n */\nfunction ɵɵHostDirectivesFeature(rawHostDirectives) {\n const feature = definition => {\n const isEager = Array.isArray(rawHostDirectives);\n if (definition.hostDirectives === null) {\n definition.findHostDirectiveDefs = findHostDirectiveDefs;\n definition.hostDirectives = isEager ? rawHostDirectives.map(createHostDirectiveDef) : [rawHostDirectives];\n } else if (isEager) {\n definition.hostDirectives.unshift(...rawHostDirectives.map(createHostDirectiveDef));\n } else {\n definition.hostDirectives.unshift(rawHostDirectives);\n }\n };\n feature.ngInherit = true;\n return feature;\n}\nfunction findHostDirectiveDefs(currentDef, matchedDefs, hostDirectiveDefs) {\n if (currentDef.hostDirectives !== null) {\n for (const configOrFn of currentDef.hostDirectives) {\n if (typeof configOrFn === 'function') {\n const resolved = configOrFn();\n for (const config of resolved) {\n trackHostDirectiveDef(createHostDirectiveDef(config), matchedDefs, hostDirectiveDefs);\n }\n } else {\n trackHostDirectiveDef(configOrFn, matchedDefs, hostDirectiveDefs);\n }\n }\n }\n}\n/** Tracks a single host directive during directive matching. */\nfunction trackHostDirectiveDef(def, matchedDefs, hostDirectiveDefs) {\n const hostDirectiveDef = getDirectiveDef(def.directive);\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n validateHostDirective(def, hostDirectiveDef);\n }\n // We need to patch the `declaredInputs` so that\n // `ngOnChanges` can map the properties correctly.\n patchDeclaredInputs(hostDirectiveDef.declaredInputs, def.inputs);\n // Host directives execute before the host so that its host bindings can be overwritten.\n findHostDirectiveDefs(hostDirectiveDef, matchedDefs, hostDirectiveDefs);\n hostDirectiveDefs.set(hostDirectiveDef, def);\n matchedDefs.push(hostDirectiveDef);\n}\n/** Creates a `HostDirectiveDef` from a used-defined host directive configuration. */\nfunction createHostDirectiveDef(config) {\n return typeof config === 'function' ? {\n directive: resolveForwardRef(config),\n inputs: EMPTY_OBJ,\n outputs: EMPTY_OBJ\n } : {\n directive: resolveForwardRef(config.directive),\n inputs: bindingArrayToMap(config.inputs),\n outputs: bindingArrayToMap(config.outputs)\n };\n}\n/**\n * Converts an array in the form of `['publicName', 'alias', 'otherPublicName', 'otherAlias']` into\n * a map in the form of `{publicName: 'alias', otherPublicName: 'otherAlias'}`.\n */\nfunction bindingArrayToMap(bindings) {\n if (bindings === undefined || bindings.length === 0) {\n return EMPTY_OBJ;\n }\n const result = {};\n for (let i = 0; i < bindings.length; i += 2) {\n result[bindings[i]] = bindings[i + 1];\n }\n return result;\n}\n/**\n * `ngOnChanges` has some leftover legacy ViewEngine behavior where the keys inside the\n * `SimpleChanges` event refer to the *declared* name of the input, not its public name or its\n * minified name. E.g. in `@Input('alias') foo: string`, the name in the `SimpleChanges` object\n * will always be `foo`, and not `alias` or the minified name of `foo` in apps using property\n * minification.\n *\n * This is achieved through the `DirectiveDef.declaredInputs` map that is constructed when the\n * definition is declared. When a property is written to the directive instance, the\n * `NgOnChangesFeature` will try to remap the property name being written to using the\n * `declaredInputs`.\n *\n * Since the host directive input remapping happens during directive matching, `declaredInputs`\n * won't contain the new alias that the input is available under. This function addresses the\n * issue by patching the host directive aliases to the `declaredInputs`. There is *not* a risk of\n * this patching accidentally introducing new inputs to the host directive, because `declaredInputs`\n * is used *only* by the `NgOnChangesFeature` when determining what name is used in the\n * `SimpleChanges` object which won't be reached if an input doesn't exist.\n */\nfunction patchDeclaredInputs(declaredInputs, exposedInputs) {\n for (const publicName in exposedInputs) {\n if (exposedInputs.hasOwnProperty(publicName)) {\n const remappedPublicName = exposedInputs[publicName];\n const privateName = declaredInputs[publicName];\n // We *technically* shouldn't be able to hit this case because we can't have multiple\n // inputs on the same property and we have validations against conflicting aliases in\n // `validateMappings`. If we somehow did, it would lead to `ngOnChanges` being invoked\n // with the wrong name so we have a non-user-friendly assertion here just in case.\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && declaredInputs.hasOwnProperty(remappedPublicName)) {\n assertEqual(declaredInputs[remappedPublicName], declaredInputs[publicName], `Conflicting host directive input alias ${publicName}.`);\n }\n declaredInputs[remappedPublicName] = privateName;\n }\n }\n}\n/**\n * Verifies that the host directive has been configured correctly.\n * @param hostDirectiveConfig Host directive configuration object.\n * @param directiveDef Directive definition of the host directive.\n */\nfunction validateHostDirective(hostDirectiveConfig, directiveDef) {\n const type = hostDirectiveConfig.directive;\n if (directiveDef === null) {\n if (getComponentDef(type) !== null) {\n throw new RuntimeError(310 /* RuntimeErrorCode.HOST_DIRECTIVE_COMPONENT */, `Host directive ${type.name} cannot be a component.`);\n }\n throw new RuntimeError(307 /* RuntimeErrorCode.HOST_DIRECTIVE_UNRESOLVABLE */, `Could not resolve metadata for host directive ${type.name}. ` + `Make sure that the ${type.name} class is annotated with an @Directive decorator.`);\n }\n if (!directiveDef.standalone) {\n throw new RuntimeError(308 /* RuntimeErrorCode.HOST_DIRECTIVE_NOT_STANDALONE */, `Host directive ${directiveDef.type.name} must be standalone.`);\n }\n validateMappings('input', directiveDef, hostDirectiveConfig.inputs);\n validateMappings('output', directiveDef, hostDirectiveConfig.outputs);\n}\n/**\n * Checks that the host directive inputs/outputs configuration is valid.\n * @param bindingType Kind of binding that is being validated. Used in the error message.\n * @param def Definition of the host directive that is being validated against.\n * @param hostDirectiveBindings Host directive mapping object that shold be validated.\n */\nfunction validateMappings(bindingType, def, hostDirectiveBindings) {\n const className = def.type.name;\n const bindings = bindingType === 'input' ? def.inputs : def.outputs;\n for (const publicName in hostDirectiveBindings) {\n if (hostDirectiveBindings.hasOwnProperty(publicName)) {\n if (!bindings.hasOwnProperty(publicName)) {\n throw new RuntimeError(311 /* RuntimeErrorCode.HOST_DIRECTIVE_UNDEFINED_BINDING */, `Directive ${className} does not have an ${bindingType} with a public name of ${publicName}.`);\n }\n const remappedPublicName = hostDirectiveBindings[publicName];\n if (bindings.hasOwnProperty(remappedPublicName) && remappedPublicName !== publicName) {\n throw new RuntimeError(312 /* RuntimeErrorCode.HOST_DIRECTIVE_CONFLICTING_ALIAS */, `Cannot alias ${bindingType} ${publicName} of host directive ${className} to ${remappedPublicName}, because it already has a different ${bindingType} with the same public name.`);\n }\n }\n }\n}\nfunction isIterable(obj) {\n return obj !== null && typeof obj === 'object' && obj[Symbol.iterator] !== undefined;\n}\nfunction isListLikeIterable(obj) {\n if (!isJsObject(obj)) return false;\n return Array.isArray(obj) || !(obj instanceof Map) &&\n // JS Map are iterables but return entries as [k, v]\n Symbol.iterator in obj; // JS Iterable have a Symbol.iterator prop\n}\nfunction areIterablesEqual(a, b, comparator) {\n const iterator1 = a[Symbol.iterator]();\n const iterator2 = b[Symbol.iterator]();\n while (true) {\n const item1 = iterator1.next();\n const item2 = iterator2.next();\n if (item1.done && item2.done) return true;\n if (item1.done || item2.done) return false;\n if (!comparator(item1.value, item2.value)) return false;\n }\n}\nfunction iterateListLike(obj, fn) {\n if (Array.isArray(obj)) {\n for (let i = 0; i < obj.length; i++) {\n fn(obj[i]);\n }\n } else {\n const iterator = obj[Symbol.iterator]();\n let item;\n while (!(item = iterator.next()).done) {\n fn(item.value);\n }\n }\n}\nfunction isJsObject(o) {\n return o !== null && (typeof o === 'function' || typeof o === 'object');\n}\nfunction devModeEqual(a, b) {\n const isListLikeIterableA = isListLikeIterable(a);\n const isListLikeIterableB = isListLikeIterable(b);\n if (isListLikeIterableA && isListLikeIterableB) {\n return areIterablesEqual(a, b, devModeEqual);\n } else {\n const isAObject = a && (typeof a === 'object' || typeof a === 'function');\n const isBObject = b && (typeof b === 'object' || typeof b === 'function');\n if (!isListLikeIterableA && isAObject && !isListLikeIterableB && isBObject) {\n return true;\n } else {\n return Object.is(a, b);\n }\n }\n}\n\n// TODO(misko): consider inlining\n/** Updates binding and returns the value. */\nfunction updateBinding(lView, bindingIndex, value) {\n return lView[bindingIndex] = value;\n}\n/** Gets the current binding value. */\nfunction getBinding(lView, bindingIndex) {\n ngDevMode && assertIndexInRange(lView, bindingIndex);\n ngDevMode && assertNotSame(lView[bindingIndex], NO_CHANGE, 'Stored value should never be NO_CHANGE.');\n return lView[bindingIndex];\n}\n/**\n * Updates binding if changed, then returns whether it was updated.\n *\n * This function also checks the `CheckNoChangesMode` and throws if changes are made.\n * Some changes (Objects/iterables) during `CheckNoChangesMode` are exempt to comply with VE\n * behavior.\n *\n * @param lView current `LView`\n * @param bindingIndex The binding in the `LView` to check\n * @param value New value to check against `lView[bindingIndex]`\n * @returns `true` if the bindings has changed. (Throws if binding has changed during\n * `CheckNoChangesMode`)\n */\nfunction bindingUpdated(lView, bindingIndex, value) {\n ngDevMode && assertNotSame(value, NO_CHANGE, 'Incoming value should never be NO_CHANGE.');\n ngDevMode && assertLessThan(bindingIndex, lView.length, `Slot should have been initialized to NO_CHANGE`);\n const oldValue = lView[bindingIndex];\n if (Object.is(oldValue, value)) {\n return false;\n } else {\n if (ngDevMode && isInCheckNoChangesMode()) {\n // View engine didn't report undefined values as changed on the first checkNoChanges pass\n // (before the change detection was run).\n const oldValueToCompare = oldValue !== NO_CHANGE ? oldValue : undefined;\n if (!devModeEqual(oldValueToCompare, value)) {\n const details = getExpressionChangedErrorDetails(lView, bindingIndex, oldValueToCompare, value);\n throwErrorIfNoChangesMode(oldValue === NO_CHANGE, details.oldValue, details.newValue, details.propName, lView);\n }\n // There was a change, but the `devModeEqual` decided that the change is exempt from an error.\n // For this reason we exit as if no change. The early exit is needed to prevent the changed\n // value to be written into `LView` (If we would write the new value that we would not see it\n // as change on next CD.)\n return false;\n }\n lView[bindingIndex] = value;\n return true;\n }\n}\n/** Updates 2 bindings if changed, then returns whether either was updated. */\nfunction bindingUpdated2(lView, bindingIndex, exp1, exp2) {\n const different = bindingUpdated(lView, bindingIndex, exp1);\n return bindingUpdated(lView, bindingIndex + 1, exp2) || different;\n}\n/** Updates 3 bindings if changed, then returns whether any was updated. */\nfunction bindingUpdated3(lView, bindingIndex, exp1, exp2, exp3) {\n const different = bindingUpdated2(lView, bindingIndex, exp1, exp2);\n return bindingUpdated(lView, bindingIndex + 2, exp3) || different;\n}\n/** Updates 4 bindings if changed, then returns whether any was updated. */\nfunction bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4) {\n const different = bindingUpdated2(lView, bindingIndex, exp1, exp2);\n return bindingUpdated2(lView, bindingIndex + 2, exp3, exp4) || different;\n}\nfunction templateFirstCreatePass(index, tView, lView, templateFn, decls, vars, tagName, attrs, localRefsIndex) {\n ngDevMode && assertFirstCreatePass(tView);\n ngDevMode && ngDevMode.firstCreatePass++;\n const tViewConsts = tView.consts;\n // TODO(pk): refactor getOrCreateTNode to have the \"create\" only version\n const tNode = getOrCreateTNode(tView, index, 4 /* TNodeType.Container */, tagName || null, attrs || null);\n if (getBindingsEnabled()) {\n resolveDirectives(tView, lView, tNode, getConstant(tViewConsts, localRefsIndex), findDirectiveDefMatches);\n }\n // Merge the template attrs last so that they have the highest priority.\n tNode.mergedAttrs = mergeHostAttrs(tNode.mergedAttrs, tNode.attrs);\n registerPostOrderHooks(tView, tNode);\n const embeddedTView = tNode.tView = createTView(2 /* TViewType.Embedded */, tNode, templateFn, decls, vars, tView.directiveRegistry, tView.pipeRegistry, null, tView.schemas, tViewConsts, null /* ssrId */);\n if (tView.queries !== null) {\n tView.queries.template(tView, tNode);\n embeddedTView.queries = tView.queries.embeddedTView(tNode);\n }\n return tNode;\n}\n/**\n * Creates an LContainer for an embedded view.\n *\n * @param declarationLView LView in which the template was declared.\n * @param declarationTView TView in which the template wa declared.\n * @param index The index of the container in the data array\n * @param templateFn Inline template\n * @param decls The number of nodes, local refs, and pipes for this template\n * @param vars The number of bindings for this template\n * @param tagName The name of the container element, if applicable\n * @param attrsIndex Index of template attributes in the `consts` array.\n * @param localRefs Index of the local references in the `consts` array.\n * @param localRefExtractor A function which extracts local-refs values from the template.\n * Defaults to the current element associated with the local-ref.\n */\nfunction declareTemplate(declarationLView, declarationTView, index, templateFn, decls, vars, tagName, attrs, localRefsIndex, localRefExtractor) {\n const adjustedIndex = index + HEADER_OFFSET;\n const tNode = declarationTView.firstCreatePass ? templateFirstCreatePass(adjustedIndex, declarationTView, declarationLView, templateFn, decls, vars, tagName, attrs, localRefsIndex) : declarationTView.data[adjustedIndex];\n setCurrentTNode(tNode, false);\n const comment = _locateOrCreateContainerAnchor(declarationTView, declarationLView, tNode, index);\n if (wasLastNodeCreated()) {\n appendChild(declarationTView, declarationLView, comment, tNode);\n }\n attachPatchData(comment, declarationLView);\n const lContainer = createLContainer(comment, declarationLView, comment, tNode);\n declarationLView[adjustedIndex] = lContainer;\n addToEndOfViewTree(declarationLView, lContainer);\n // If hydration is enabled, looks up dehydrated views in the DOM\n // using hydration annotation info and stores those views on LContainer.\n // In client-only mode, this function is a noop.\n populateDehydratedViewsInLContainer(lContainer, tNode, declarationLView);\n if (isDirectiveHost(tNode)) {\n createDirectivesInstances(declarationTView, declarationLView, tNode);\n }\n if (localRefsIndex != null) {\n saveResolvedLocalsInData(declarationLView, tNode, localRefExtractor);\n }\n return tNode;\n}\n/**\n * Creates an LContainer for an ng-template (dynamically-inserted view), e.g.\n *\n * <ng-template #foo>\n * <div></div>\n * </ng-template>\n *\n * @param index The index of the container in the data array\n * @param templateFn Inline template\n * @param decls The number of nodes, local refs, and pipes for this template\n * @param vars The number of bindings for this template\n * @param tagName The name of the container element, if applicable\n * @param attrsIndex Index of template attributes in the `consts` array.\n * @param localRefs Index of the local references in the `consts` array.\n * @param localRefExtractor A function which extracts local-refs values from the template.\n * Defaults to the current element associated with the local-ref.\n *\n * @codeGenApi\n */\nfunction ɵɵtemplate(index, templateFn, decls, vars, tagName, attrsIndex, localRefsIndex, localRefExtractor) {\n const lView = getLView();\n const tView = getTView();\n const attrs = getConstant(tView.consts, attrsIndex);\n declareTemplate(lView, tView, index, templateFn, decls, vars, tagName, attrs, localRefsIndex, localRefExtractor);\n return ɵɵtemplate;\n}\nlet _locateOrCreateContainerAnchor = createContainerAnchorImpl;\n/**\n * Regular creation mode for LContainers and their anchor (comment) nodes.\n */\nfunction createContainerAnchorImpl(tView, lView, tNode, index) {\n lastNodeWasCreated(true);\n return lView[RENDERER].createComment(ngDevMode ? 'container' : '');\n}\n/**\n * Enables hydration code path (to lookup existing elements in DOM)\n * in addition to the regular creation mode for LContainers and their\n * anchor (comment) nodes.\n */\nfunction locateOrCreateContainerAnchorImpl(tView, lView, tNode, index) {\n const hydrationInfo = lView[HYDRATION];\n const isNodeCreationMode = !hydrationInfo || isInSkipHydrationBlock$1() || isDetachedByI18n(tNode) || isDisconnectedNode$1(hydrationInfo, index);\n lastNodeWasCreated(isNodeCreationMode);\n // Regular creation mode.\n if (isNodeCreationMode) {\n return createContainerAnchorImpl(tView, lView, tNode, index);\n }\n const ssrId = hydrationInfo.data[TEMPLATES]?.[index] ?? null;\n // Apply `ssrId` value to the underlying TView if it was not previously set.\n //\n // There might be situations when the same component is present in a template\n // multiple times and some instances are opted-out of using hydration via\n // `ngSkipHydration` attribute. In this scenario, at the time a TView is created,\n // the `ssrId` might be `null` (if the first component is opted-out of hydration).\n // The code below makes sure that the `ssrId` is applied to the TView if it's still\n // `null` and verifies we never try to override it with a different value.\n if (ssrId !== null && tNode.tView !== null) {\n if (tNode.tView.ssrId === null) {\n tNode.tView.ssrId = ssrId;\n } else {\n ngDevMode && assertEqual(tNode.tView.ssrId, ssrId, 'Unexpected value of the `ssrId` for this TView');\n }\n }\n // Hydration mode, looking up existing elements in DOM.\n const currentRNode = locateNextRNode(hydrationInfo, tView, lView, tNode);\n ngDevMode && validateNodeExists(currentRNode, lView, tNode);\n setSegmentHead(hydrationInfo, index, currentRNode);\n const viewContainerSize = calcSerializedContainerSize(hydrationInfo, index);\n const comment = siblingAfter(viewContainerSize, currentRNode);\n if (ngDevMode) {\n validateMatchingNode(comment, Node.COMMENT_NODE, null, lView, tNode);\n markRNodeAsClaimedByHydration(comment);\n }\n return comment;\n}\nfunction enableLocateOrCreateContainerAnchorImpl() {\n _locateOrCreateContainerAnchor = locateOrCreateContainerAnchorImpl;\n}\n\n/**\n * Helper function to schedule a callback to be invoked when a browser becomes idle.\n *\n * @param callback A function to be invoked when a browser becomes idle.\n * @param injector injector for the app\n */\nfunction onIdle(callback, injector) {\n const scheduler = injector.get(IdleScheduler);\n const cleanupFn = () => scheduler.remove(callback);\n scheduler.add(callback);\n return cleanupFn;\n}\n/**\n * Use shims for the `requestIdleCallback` and `cancelIdleCallback` functions for\n * environments where those functions are not available (e.g. Node.js and Safari).\n *\n * Note: we wrap the `requestIdleCallback` call into a function, so that it can be\n * overridden/mocked in test environment and picked up by the runtime code.\n */\nconst _requestIdleCallback = () => typeof requestIdleCallback !== 'undefined' ? requestIdleCallback : setTimeout;\nconst _cancelIdleCallback = () => typeof requestIdleCallback !== 'undefined' ? cancelIdleCallback : clearTimeout;\n/**\n * Helper service to schedule `requestIdleCallback`s for batches of defer blocks,\n * to avoid calling `requestIdleCallback` for each defer block (e.g. if\n * defer blocks are defined inside a for loop).\n */\nclass IdleScheduler {\n // Indicates whether current callbacks are being invoked.\n executingCallbacks = false;\n // Currently scheduled idle callback id.\n idleId = null;\n // Set of callbacks to be invoked next.\n current = new Set();\n // Set of callbacks collected while invoking current set of callbacks.\n // Those callbacks are scheduled for the next idle period.\n deferred = new Set();\n ngZone = inject(NgZone);\n requestIdleCallbackFn = _requestIdleCallback().bind(globalThis);\n cancelIdleCallbackFn = _cancelIdleCallback().bind(globalThis);\n add(callback) {\n const target = this.executingCallbacks ? this.deferred : this.current;\n target.add(callback);\n if (this.idleId === null) {\n this.scheduleIdleCallback();\n }\n }\n remove(callback) {\n const {\n current,\n deferred\n } = this;\n current.delete(callback);\n deferred.delete(callback);\n // If the last callback was removed and there is a pending\n // idle callback - cancel it.\n if (current.size === 0 && deferred.size === 0) {\n this.cancelIdleCallback();\n }\n }\n scheduleIdleCallback() {\n const callback = () => {\n this.cancelIdleCallback();\n this.executingCallbacks = true;\n for (const callback of this.current) {\n callback();\n }\n this.current.clear();\n this.executingCallbacks = false;\n // If there are any callbacks added during an invocation\n // of the current ones - make them \"current\" and schedule\n // a new idle callback.\n if (this.deferred.size > 0) {\n for (const callback of this.deferred) {\n this.current.add(callback);\n }\n this.deferred.clear();\n this.scheduleIdleCallback();\n }\n };\n // Ensure that the callback runs in the NgZone since\n // the `requestIdleCallback` is not currently patched by Zone.js.\n this.idleId = this.requestIdleCallbackFn(() => this.ngZone.run(callback));\n }\n cancelIdleCallback() {\n if (this.idleId !== null) {\n this.cancelIdleCallbackFn(this.idleId);\n this.idleId = null;\n }\n }\n ngOnDestroy() {\n this.cancelIdleCallback();\n this.current.clear();\n this.deferred.clear();\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: IdleScheduler,\n providedIn: 'root',\n factory: () => new IdleScheduler()\n });\n}\n\n/**\n * Returns a function that captures a provided delay.\n * Invoking the returned function schedules a trigger.\n */\nfunction onTimer(delay) {\n return (callback, injector) => scheduleTimerTrigger(delay, callback, injector);\n}\n/**\n * Schedules a callback to be invoked after a given timeout.\n *\n * @param delay A number of ms to wait until firing a callback.\n * @param callback A function to be invoked after a timeout.\n * @param injector injector for the app.\n */\nfunction scheduleTimerTrigger(delay, callback, injector) {\n const scheduler = injector.get(TimerScheduler);\n const cleanupFn = () => scheduler.remove(callback);\n scheduler.add(delay, callback);\n return cleanupFn;\n}\n/**\n * Helper service to schedule `setTimeout`s for batches of defer blocks,\n * to avoid calling `setTimeout` for each defer block (e.g. if defer blocks\n * are created inside a for loop).\n */\nclass TimerScheduler {\n // Indicates whether current callbacks are being invoked.\n executingCallbacks = false;\n // Currently scheduled `setTimeout` id.\n timeoutId = null;\n // When currently scheduled timer would fire.\n invokeTimerAt = null;\n // List of callbacks to be invoked.\n // For each callback we also store a timestamp on when the callback\n // should be invoked. We store timestamps and callback functions\n // in a flat array to avoid creating new objects for each entry.\n // [timestamp1, callback1, timestamp2, callback2, ...]\n current = [];\n // List of callbacks collected while invoking current set of callbacks.\n // Those callbacks are added to the \"current\" queue at the end of\n // the current callback invocation. The shape of this list is the same\n // as the shape of the `current` list.\n deferred = [];\n add(delay, callback) {\n const target = this.executingCallbacks ? this.deferred : this.current;\n this.addToQueue(target, Date.now() + delay, callback);\n this.scheduleTimer();\n }\n remove(callback) {\n const {\n current,\n deferred\n } = this;\n const callbackIndex = this.removeFromQueue(current, callback);\n if (callbackIndex === -1) {\n // Try cleaning up deferred queue only in case\n // we didn't find a callback in the \"current\" queue.\n this.removeFromQueue(deferred, callback);\n }\n // If the last callback was removed and there is a pending timeout - cancel it.\n if (current.length === 0 && deferred.length === 0) {\n this.clearTimeout();\n }\n }\n addToQueue(target, invokeAt, callback) {\n let insertAtIndex = target.length;\n for (let i = 0; i < target.length; i += 2) {\n const invokeQueuedCallbackAt = target[i];\n if (invokeQueuedCallbackAt > invokeAt) {\n // We've reached a first timer that is scheduled\n // for a later time than what we are trying to insert.\n // This is the location at which we need to insert,\n // no need to iterate further.\n insertAtIndex = i;\n break;\n }\n }\n arrayInsert2(target, insertAtIndex, invokeAt, callback);\n }\n removeFromQueue(target, callback) {\n let index = -1;\n for (let i = 0; i < target.length; i += 2) {\n const queuedCallback = target[i + 1];\n if (queuedCallback === callback) {\n index = i;\n break;\n }\n }\n if (index > -1) {\n // Remove 2 elements: a timestamp slot and\n // the following slot with a callback function.\n arraySplice(target, index, 2);\n }\n return index;\n }\n scheduleTimer() {\n const callback = () => {\n this.clearTimeout();\n this.executingCallbacks = true;\n // Clone the current state of the queue, since it might be altered\n // as we invoke callbacks.\n const current = [...this.current];\n // Invoke callbacks that were scheduled to run before the current time.\n const now = Date.now();\n for (let i = 0; i < current.length; i += 2) {\n const invokeAt = current[i];\n const callback = current[i + 1];\n if (invokeAt <= now) {\n callback();\n } else {\n // We've reached a timer that should not be invoked yet.\n break;\n }\n }\n // The state of the queue might've changed after callbacks invocation,\n // run the cleanup logic based on the *current* state of the queue.\n let lastCallbackIndex = -1;\n for (let i = 0; i < this.current.length; i += 2) {\n const invokeAt = this.current[i];\n if (invokeAt <= now) {\n // Add +1 to account for a callback function that\n // goes after the timestamp in events array.\n lastCallbackIndex = i + 1;\n } else {\n // We've reached a timer that should not be invoked yet.\n break;\n }\n }\n if (lastCallbackIndex >= 0) {\n arraySplice(this.current, 0, lastCallbackIndex + 1);\n }\n this.executingCallbacks = false;\n // If there are any callbacks added during an invocation\n // of the current ones - move them over to the \"current\"\n // queue.\n if (this.deferred.length > 0) {\n for (let i = 0; i < this.deferred.length; i += 2) {\n const invokeAt = this.deferred[i];\n const callback = this.deferred[i + 1];\n this.addToQueue(this.current, invokeAt, callback);\n }\n this.deferred.length = 0;\n }\n this.scheduleTimer();\n };\n // Avoid running timer callbacks more than once per\n // average frame duration. This is needed for better\n // batching and to avoid kicking off excessive change\n // detection cycles.\n const FRAME_DURATION_MS = 16; // 1000ms / 60fps\n if (this.current.length > 0) {\n const now = Date.now();\n // First element in the queue points at the timestamp\n // of the first (earliest) event.\n const invokeAt = this.current[0];\n if (this.timeoutId === null ||\n // Reschedule a timer in case a queue contains an item with\n // an earlier timestamp and the delta is more than an average\n // frame duration.\n this.invokeTimerAt && this.invokeTimerAt - invokeAt > FRAME_DURATION_MS) {\n // There was a timeout already, but an earlier event was added\n // into the queue. In this case we drop an old timer and setup\n // a new one with an updated (smaller) timeout.\n this.clearTimeout();\n const timeout = Math.max(invokeAt - now, FRAME_DURATION_MS);\n this.invokeTimerAt = invokeAt;\n this.timeoutId = setTimeout(callback, timeout);\n }\n }\n }\n clearTimeout() {\n if (this.timeoutId !== null) {\n clearTimeout(this.timeoutId);\n this.timeoutId = null;\n }\n }\n ngOnDestroy() {\n this.clearTimeout();\n this.current.length = 0;\n this.deferred.length = 0;\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: TimerScheduler,\n providedIn: 'root',\n factory: () => new TimerScheduler()\n });\n}\n\n/**\n * A service used by the framework to create and cache injector instances.\n *\n * This service is used to create a single injector instance for each defer\n * block definition, to avoid creating an injector for each defer block instance\n * of a certain type.\n */\nclass CachedInjectorService {\n cachedInjectors = new Map();\n getOrCreateInjector(key, parentInjector, providers, debugName) {\n if (!this.cachedInjectors.has(key)) {\n const injector = providers.length > 0 ? createEnvironmentInjector(providers, parentInjector, debugName) : null;\n this.cachedInjectors.set(key, injector);\n }\n return this.cachedInjectors.get(key);\n }\n ngOnDestroy() {\n try {\n for (const injector of this.cachedInjectors.values()) {\n if (injector !== null) {\n injector.destroy();\n }\n }\n } finally {\n this.cachedInjectors.clear();\n }\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: CachedInjectorService,\n providedIn: 'environment',\n factory: () => new CachedInjectorService()\n });\n}\n\n/**\n * **INTERNAL**, avoid referencing it in application code.\n * *\n * Injector token that allows to provide `DeferBlockDependencyInterceptor` class\n * implementation.\n *\n * This token is only injected in devMode\n */\nconst DEFER_BLOCK_DEPENDENCY_INTERCEPTOR = /* @__PURE__ */new InjectionToken('DEFER_BLOCK_DEPENDENCY_INTERCEPTOR');\n/**\n * **INTERNAL**, token used for configuring defer block behavior.\n */\nconst DEFER_BLOCK_CONFIG = new InjectionToken(ngDevMode ? 'DEFER_BLOCK_CONFIG' : '');\n/**\n * Checks whether there is a cached injector associated with a given defer block\n * declaration and returns if it exists. If there is no cached injector present -\n * creates a new injector and stores in the cache.\n */\nfunction getOrCreateEnvironmentInjector(parentInjector, tDetails, providers) {\n return parentInjector.get(CachedInjectorService).getOrCreateInjector(tDetails, parentInjector, providers, ngDevMode ? 'DeferBlock Injector' : '');\n}\n/** Injector Helpers */\n/**\n * Creates a new injector, which contains providers collected from dependencies (NgModules) of\n * defer-loaded components. This function detects different types of parent injectors and creates\n * a new injector based on that.\n */\nfunction createDeferBlockInjector(parentInjector, tDetails, providers) {\n // Check if the parent injector is an instance of a `ChainedInjector`.\n //\n // In this case, we retain the shape of the injector and use a newly created\n // `EnvironmentInjector` as a parent in the `ChainedInjector`. That is needed to\n // make sure that the primary injector gets consulted first (since it's typically\n // a NodeInjector) and `EnvironmentInjector` tree is consulted after that.\n if (parentInjector instanceof ChainedInjector) {\n const origInjector = parentInjector.injector;\n // Guaranteed to be an environment injector\n const parentEnvInjector = parentInjector.parentInjector;\n const envInjector = getOrCreateEnvironmentInjector(parentEnvInjector, tDetails, providers);\n return new ChainedInjector(origInjector, envInjector);\n }\n const parentEnvInjector = parentInjector.get(EnvironmentInjector);\n // If the `parentInjector` is *not* an `EnvironmentInjector` - we need to create\n // a new `ChainedInjector` with the following setup:\n //\n // - the provided `parentInjector` becomes a primary injector\n // - an existing (real) `EnvironmentInjector` becomes a parent injector for\n // a newly-created one, which contains extra providers\n //\n // So the final order in which injectors would be consulted in this case would look like this:\n //\n // 1. Provided `parentInjector`\n // 2. Newly-created `EnvironmentInjector` with extra providers\n // 3. `EnvironmentInjector` from the `parentInjector`\n if (parentEnvInjector !== parentInjector) {\n const envInjector = getOrCreateEnvironmentInjector(parentEnvInjector, tDetails, providers);\n return new ChainedInjector(parentInjector, envInjector);\n }\n // The `parentInjector` is an instance of an `EnvironmentInjector`.\n // No need for special handling, we can use `parentInjector` as a\n // parent injector directly.\n return getOrCreateEnvironmentInjector(parentInjector, tDetails, providers);\n}\n/** Rendering Helpers */\n/**\n * Transitions a defer block to the new state. Updates the necessary\n * data structures and renders corresponding block.\n *\n * @param newState New state that should be applied to the defer block.\n * @param tNode TNode that represents a defer block.\n * @param lContainer Represents an instance of a defer block.\n * @param skipTimerScheduling Indicates that `@loading` and `@placeholder` block\n * should be rendered immediately, even if they have `after` or `minimum` config\n * options setup. This flag to needed for testing APIs to transition defer block\n * between states via `DeferFixture.render` method.\n */\nfunction renderDeferBlockState(newState, tNode, lContainer, skipTimerScheduling = false) {\n const hostLView = lContainer[PARENT];\n const hostTView = hostLView[TVIEW];\n // Check if this view is not destroyed. Since the loading process was async,\n // the view might end up being destroyed by the time rendering happens.\n if (isDestroyed(hostLView)) return;\n // Make sure this TNode belongs to TView that represents host LView.\n ngDevMode && assertTNodeForLView(tNode, hostLView);\n const lDetails = getLDeferBlockDetails(hostLView, tNode);\n ngDevMode && assertDefined(lDetails, 'Expected a defer block state defined');\n const currentState = lDetails[DEFER_BLOCK_STATE];\n const ssrState = lDetails[SSR_BLOCK_STATE];\n if (ssrState !== null && newState < ssrState) {\n return; // trying to render a previous state, exit\n }\n if (isValidStateChange(currentState, newState) && isValidStateChange(lDetails[NEXT_DEFER_BLOCK_STATE] ?? -1, newState)) {\n const tDetails = getTDeferBlockDetails(hostTView, tNode);\n // Skips scheduling on the server since it can delay the server response.\n const needsScheduling = !skipTimerScheduling && (typeof ngServerMode === 'undefined' || !ngServerMode) && (getLoadingBlockAfter(tDetails) !== null || getMinimumDurationForState(tDetails, DeferBlockState.Loading) !== null || getMinimumDurationForState(tDetails, DeferBlockState.Placeholder));\n if (ngDevMode && needsScheduling) {\n assertDefined(applyDeferBlockStateWithSchedulingImpl, 'Expected scheduling function to be defined');\n }\n const applyStateFn = needsScheduling ? applyDeferBlockStateWithSchedulingImpl : applyDeferBlockState;\n try {\n applyStateFn(newState, lDetails, lContainer, tNode, hostLView);\n } catch (error) {\n handleError(hostLView, error);\n }\n }\n}\nfunction findMatchingDehydratedViewForDeferBlock(lContainer, lDetails) {\n const dehydratedViewIx = lContainer[DEHYDRATED_VIEWS]?.findIndex(view => view.data[DEFER_BLOCK_STATE$1] === lDetails[DEFER_BLOCK_STATE]) ?? -1;\n const dehydratedView = dehydratedViewIx > -1 ? lContainer[DEHYDRATED_VIEWS][dehydratedViewIx] : null;\n return {\n dehydratedView,\n dehydratedViewIx\n };\n}\n/**\n * Applies changes to the DOM to reflect a given state.\n */\nfunction applyDeferBlockState(newState, lDetails, lContainer, tNode, hostLView) {\n profiler(20 /* ProfilerEvent.DeferBlockStateStart */);\n const stateTmplIndex = getTemplateIndexForState(newState, hostLView, tNode);\n if (stateTmplIndex !== null) {\n lDetails[DEFER_BLOCK_STATE] = newState;\n const hostTView = hostLView[TVIEW];\n const adjustedIndex = stateTmplIndex + HEADER_OFFSET;\n // The TNode that represents a template that will activated in the defer block\n const activeBlockTNode = getTNode(hostTView, adjustedIndex);\n // There is only 1 view that can be present in an LContainer that\n // represents a defer block, so always refer to the first one.\n const viewIndex = 0;\n removeLViewFromLContainer(lContainer, viewIndex);\n let injector;\n if (newState === DeferBlockState.Complete) {\n // When we render a defer block in completed state, there might be\n // newly loaded standalone components used within the block, which may\n // import NgModules with providers. In order to make those providers\n // available for components declared in that NgModule, we create an instance\n // of an environment injector to host those providers and pass this injector\n // to the logic that creates a view.\n const tDetails = getTDeferBlockDetails(hostTView, tNode);\n const providers = tDetails.providers;\n if (providers && providers.length > 0) {\n injector = createDeferBlockInjector(hostLView[INJECTOR], tDetails, providers);\n }\n }\n const {\n dehydratedView,\n dehydratedViewIx\n } = findMatchingDehydratedViewForDeferBlock(lContainer, lDetails);\n const embeddedLView = createAndRenderEmbeddedLView(hostLView, activeBlockTNode, null, {\n injector,\n dehydratedView\n });\n addLViewToLContainer(lContainer, embeddedLView, viewIndex, shouldAddViewToDom(activeBlockTNode, dehydratedView));\n markViewDirty(embeddedLView, 2 /* NotificationSource.DeferBlockStateUpdate */);\n if (dehydratedViewIx > -1) {\n // Erase dehydrated view info in a given LContainer, so that the view is not\n // removed later by post-hydration cleanup process (which iterates over all\n // dehydrated views in component tree). This clears only the dehydrated view\n // that was found for this render, which in most cases will be the only view.\n // In the case that there was control flow that changed, there may be either\n // more than one or the views would not match up due to the server rendered\n // content being a different branch of the control flow.\n lContainer[DEHYDRATED_VIEWS]?.splice(dehydratedViewIx, 1);\n }\n if ((newState === DeferBlockState.Complete || newState === DeferBlockState.Error) && Array.isArray(lDetails[ON_COMPLETE_FNS])) {\n for (const callback of lDetails[ON_COMPLETE_FNS]) {\n callback();\n }\n lDetails[ON_COMPLETE_FNS] = null;\n }\n }\n profiler(21 /* ProfilerEvent.DeferBlockStateEnd */);\n}\n/**\n * Extends the `applyDeferBlockState` with timer-based scheduling.\n * This function becomes available on a page if there are defer blocks\n * that use `after` or `minimum` parameters in the `@loading` or\n * `@placeholder` blocks.\n */\nfunction applyDeferBlockStateWithScheduling(newState, lDetails, lContainer, tNode, hostLView) {\n const now = Date.now();\n const hostTView = hostLView[TVIEW];\n const tDetails = getTDeferBlockDetails(hostTView, tNode);\n if (lDetails[STATE_IS_FROZEN_UNTIL] === null || lDetails[STATE_IS_FROZEN_UNTIL] <= now) {\n lDetails[STATE_IS_FROZEN_UNTIL] = null;\n const loadingAfter = getLoadingBlockAfter(tDetails);\n const inLoadingAfterPhase = lDetails[LOADING_AFTER_CLEANUP_FN] !== null;\n if (newState === DeferBlockState.Loading && loadingAfter !== null && !inLoadingAfterPhase) {\n // Trying to render loading, but it has an `after` config,\n // so schedule an update action after a timeout.\n lDetails[NEXT_DEFER_BLOCK_STATE] = newState;\n const cleanupFn = scheduleDeferBlockUpdate(loadingAfter, lDetails, tNode, lContainer, hostLView);\n lDetails[LOADING_AFTER_CLEANUP_FN] = cleanupFn;\n } else {\n // If we transition to a complete or an error state and there is a pending\n // operation to render loading after a timeout - invoke a cleanup operation,\n // which stops the timer.\n if (newState > DeferBlockState.Loading && inLoadingAfterPhase) {\n lDetails[LOADING_AFTER_CLEANUP_FN]();\n lDetails[LOADING_AFTER_CLEANUP_FN] = null;\n lDetails[NEXT_DEFER_BLOCK_STATE] = null;\n }\n applyDeferBlockState(newState, lDetails, lContainer, tNode, hostLView);\n const duration = getMinimumDurationForState(tDetails, newState);\n if (duration !== null) {\n lDetails[STATE_IS_FROZEN_UNTIL] = now + duration;\n scheduleDeferBlockUpdate(duration, lDetails, tNode, lContainer, hostLView);\n }\n }\n } else {\n // We are still rendering the previous state.\n // Update the `NEXT_DEFER_BLOCK_STATE`, which would be\n // picked up once it's time to transition to the next state.\n lDetails[NEXT_DEFER_BLOCK_STATE] = newState;\n }\n}\n/**\n * Schedules an update operation after a specified timeout.\n */\nfunction scheduleDeferBlockUpdate(timeout, lDetails, tNode, lContainer, hostLView) {\n const callback = () => {\n const nextState = lDetails[NEXT_DEFER_BLOCK_STATE];\n lDetails[STATE_IS_FROZEN_UNTIL] = null;\n lDetails[NEXT_DEFER_BLOCK_STATE] = null;\n if (nextState !== null) {\n renderDeferBlockState(nextState, tNode, lContainer);\n }\n };\n return scheduleTimerTrigger(timeout, callback, hostLView[INJECTOR]);\n}\n/**\n * Checks whether we can transition to the next state.\n *\n * We transition to the next state if the previous state was represented\n * with a number that is less than the next state. For example, if the current\n * state is \"loading\" (represented as `1`), we should not show a placeholder\n * (represented as `0`), but we can show a completed state (represented as `2`)\n * or an error state (represented as `3`).\n */\nfunction isValidStateChange(currentState, newState) {\n return currentState < newState;\n}\n/** Utility function to render placeholder content (if present) */\nfunction renderPlaceholder(lView, tNode) {\n const lContainer = lView[tNode.index];\n ngDevMode && assertLContainer(lContainer);\n renderDeferBlockState(DeferBlockState.Placeholder, tNode, lContainer);\n}\n/**\n * Subscribes to the \"loading\" Promise and renders corresponding defer sub-block,\n * based on the loading results.\n *\n * @param lContainer Represents an instance of a defer block.\n * @param tNode Represents defer block info shared across all instances.\n */\nfunction renderDeferStateAfterResourceLoading(tDetails, tNode, lContainer) {\n ngDevMode && assertDefined(tDetails.loadingPromise, 'Expected loading Promise to exist on this defer block');\n tDetails.loadingPromise.then(() => {\n if (tDetails.loadingState === DeferDependenciesLoadingState.COMPLETE) {\n ngDevMode && assertDeferredDependenciesLoaded(tDetails);\n // Everything is loaded, show the primary block content\n renderDeferBlockState(DeferBlockState.Complete, tNode, lContainer);\n } else if (tDetails.loadingState === DeferDependenciesLoadingState.FAILED) {\n renderDeferBlockState(DeferBlockState.Error, tNode, lContainer);\n }\n });\n}\n/**\n * Reference to the timer-based scheduler implementation of defer block state\n * rendering method. It's used to make timer-based scheduling tree-shakable.\n * If `minimum` or `after` parameters are used, compiler generates an extra\n * argument for the `ɵɵdefer` instruction, which references a timer-based\n * implementation.\n */\nlet applyDeferBlockStateWithSchedulingImpl = null;\n/**\n * Enables timer-related scheduling if `after` or `minimum` parameters are setup\n * on the `@loading` or `@placeholder` blocks.\n */\nfunction ɵɵdeferEnableTimerScheduling(tView, tDetails, placeholderConfigIndex, loadingConfigIndex) {\n const tViewConsts = tView.consts;\n if (placeholderConfigIndex != null) {\n tDetails.placeholderBlockConfig = getConstant(tViewConsts, placeholderConfigIndex);\n }\n if (loadingConfigIndex != null) {\n tDetails.loadingBlockConfig = getConstant(tViewConsts, loadingConfigIndex);\n }\n // Enable implementation that supports timer-based scheduling.\n if (applyDeferBlockStateWithSchedulingImpl === null) {\n applyDeferBlockStateWithSchedulingImpl = applyDeferBlockStateWithScheduling;\n }\n}\n\n/**\n * The name of a field that Angular monkey-patches onto a component\n * class to store a function that loads defer-loadable dependencies\n * and applies metadata to a class.\n */\nconst ASYNC_COMPONENT_METADATA_FN = '__ngAsyncComponentMetadataFn__';\n/**\n * If a given component has unresolved async metadata - returns a reference\n * to a function that applies component metadata after resolving defer-loadable\n * dependencies. Otherwise - this function returns `null`.\n */\nfunction getAsyncClassMetadataFn(type) {\n const componentClass = type; // cast to `any`, so that we can read a monkey-patched field\n return componentClass[ASYNC_COMPONENT_METADATA_FN] ?? null;\n}\n/**\n * Handles the process of applying metadata info to a component class in case\n * component template has defer blocks (thus some dependencies became deferrable).\n *\n * @param type Component class where metadata should be added\n * @param dependencyLoaderFn Function that loads dependencies\n * @param metadataSetterFn Function that forms a scope in which the `setClassMetadata` is invoked\n */\nfunction setClassMetadataAsync(type, dependencyLoaderFn, metadataSetterFn) {\n const componentClass = type; // cast to `any`, so that we can monkey-patch it\n componentClass[ASYNC_COMPONENT_METADATA_FN] = () => Promise.all(dependencyLoaderFn()).then(dependencies => {\n metadataSetterFn(...dependencies);\n // Metadata is now set, reset field value to indicate that this component\n // can by used/compiled synchronously.\n componentClass[ASYNC_COMPONENT_METADATA_FN] = null;\n return dependencies;\n });\n return componentClass[ASYNC_COMPONENT_METADATA_FN];\n}\n/**\n * Adds decorator, constructor, and property metadata to a given type via static metadata fields\n * on the type.\n *\n * These metadata fields can later be read with Angular's `ReflectionCapabilities` API.\n *\n * Calls to `setClassMetadata` can be guarded by ngDevMode, resulting in the metadata assignments\n * being tree-shaken away during production builds.\n */\nfunction setClassMetadata(type, decorators, ctorParameters, propDecorators) {\n return noSideEffects(() => {\n const clazz = type;\n if (decorators !== null) {\n if (clazz.hasOwnProperty('decorators') && clazz.decorators !== undefined) {\n clazz.decorators.push(...decorators);\n } else {\n clazz.decorators = decorators;\n }\n }\n if (ctorParameters !== null) {\n // Rather than merging, clobber the existing parameters. If other projects exist which\n // use tsickle-style annotations and reflect over them in the same way, this could\n // cause issues, but that is vanishingly unlikely.\n clazz.ctorParameters = ctorParameters;\n }\n if (propDecorators !== null) {\n // The property decorator objects are merged as it is possible different fields have\n // different decorator types. Decorators on individual fields are not merged, as it's\n // also incredibly unlikely that a field will be decorated both with an Angular\n // decorator and a non-Angular decorator that's also been downleveled.\n if (clazz.hasOwnProperty('propDecorators') && clazz.propDecorators !== undefined) {\n clazz.propDecorators = {\n ...clazz.propDecorators,\n ...propDecorators\n };\n } else {\n clazz.propDecorators = propDecorators;\n }\n }\n });\n}\n\n/*\n * This file exists to support compilation of @angular/core in Ivy mode.\n *\n * When the Angular compiler processes a compilation unit, it normally writes imports to\n * @angular/core. When compiling the core package itself this strategy isn't usable. Instead, the\n * compiler writes imports to this file.\n *\n * Only a subset of such imports are supported - core is not allowed to declare components or pipes.\n * A check in ngtsc's `R3SymbolsImportRewriter` validates this condition. The rewriter is only used\n * when compiling @angular/core and is responsible for translating an external name (prefixed with\n * ɵ) to the internal symbol name as exported below.\n *\n * The below symbols are used for @Injectable and @NgModule compilation.\n */\n/**\n * The existence of this constant (in this particular file) informs the Angular compiler that the\n * current program is actually @angular/core, which needs to be compiled specially.\n */\nconst ITS_JUST_ANGULAR = true;\nclass Console {\n log(message) {\n // tslint:disable-next-line:no-console\n console.log(message);\n }\n // Note: for reporting errors use `DOM.logError()` as it is platform specific\n warn(message) {\n console.warn(message);\n }\n static ɵfac = function Console_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || Console)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: Console,\n factory: Console.ɵfac,\n providedIn: 'platform'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(Console, [{\n type: Injectable,\n args: [{\n providedIn: 'platform'\n }]\n }], null, null);\n})();\n\n/**\n * These are the data structures that our framework injector profiler will fill with data in order\n * to support DI debugging APIs.\n *\n * resolverToTokenToDependencies: Maps an injector to a Map of tokens to an Array of\n * dependencies. Injector -> Token -> Dependencies This is used to support the\n * getDependenciesFromInjectable API, which takes in an injector and a token and returns it's\n * dependencies.\n *\n * resolverToProviders: Maps a DI resolver (an Injector or a TNode) to the providers configured\n * within it This is used to support the getInjectorProviders API, which takes in an injector and\n * returns the providers that it was configured with. Note that for the element injector case we\n * use the TNode instead of the LView as the DI resolver. This is because the registration of\n * providers happens only once per type of TNode. If an injector is created with an identical TNode,\n * the providers for that injector will not be reconfigured.\n *\n * standaloneInjectorToComponent: Maps the injector of a standalone component to the standalone\n * component that it is associated with. Used in the getInjectorProviders API, specificially in the\n * discovery of import paths for each provider. This is necessary because the imports array of a\n * standalone component is processed and configured in its standalone injector, but exists within\n * the component's definition. Because getInjectorProviders takes in an injector, if that injector\n * is the injector of a standalone component, we need to be able to discover the place where the\n * imports array is located (the component) in order to flatten the imports array within it to\n * discover all of it's providers.\n *\n *\n * All of these data structures are instantiated with WeakMaps. This will ensure that the presence\n * of any object in the keys of these maps does not prevent the garbage collector from collecting\n * those objects. Because of this property of WeakMaps, these data structures will never be the\n * source of a memory leak.\n *\n * An example of this advantage: When components are destroyed, we don't need to do\n * any additional work to remove that component from our mappings.\n *\n */\nclass DIDebugData {\n resolverToTokenToDependencies = new WeakMap();\n resolverToProviders = new WeakMap();\n resolverToEffects = new WeakMap();\n standaloneInjectorToComponent = new WeakMap();\n reset() {\n this.resolverToTokenToDependencies = new WeakMap();\n this.resolverToProviders = new WeakMap();\n this.standaloneInjectorToComponent = new WeakMap();\n }\n}\nlet frameworkDIDebugData = new DIDebugData();\nfunction getFrameworkDIDebugData() {\n return frameworkDIDebugData;\n}\n/**\n * Initalize default handling of injector events. This handling parses events\n * as they are emitted and constructs the data structures necessary to support\n * some of debug APIs.\n *\n * See handleInjectEvent, handleCreateEvent and handleProviderConfiguredEvent\n * for descriptions of each handler\n *\n * Supported APIs:\n * - getDependenciesFromInjectable\n * - getInjectorProviders\n */\nfunction setupFrameworkInjectorProfiler() {\n frameworkDIDebugData.reset();\n setInjectorProfiler(injectorProfilerEvent => handleInjectorProfilerEvent(injectorProfilerEvent));\n}\nfunction handleInjectorProfilerEvent(injectorProfilerEvent) {\n const {\n context,\n type\n } = injectorProfilerEvent;\n if (type === 0 /* InjectorProfilerEventType.Inject */) {\n handleInjectEvent(context, injectorProfilerEvent.service);\n } else if (type === 1 /* InjectorProfilerEventType.InstanceCreatedByInjector */) {\n handleInstanceCreatedByInjectorEvent(context, injectorProfilerEvent.instance);\n } else if (type === 2 /* InjectorProfilerEventType.ProviderConfigured */) {\n handleProviderConfiguredEvent(context, injectorProfilerEvent.providerRecord);\n } else if (type === 3 /* InjectorProfilerEventType.EffectCreated */) {\n handleEffectCreatedEvent(context, injectorProfilerEvent.effect);\n }\n}\nfunction handleEffectCreatedEvent(context, effect) {\n const diResolver = getDIResolver(context.injector);\n if (diResolver === null) {\n throwError('An EffectCreated event must be run within an injection context.');\n }\n const {\n resolverToEffects\n } = frameworkDIDebugData;\n if (!resolverToEffects.has(diResolver)) {\n resolverToEffects.set(diResolver, []);\n }\n resolverToEffects.get(diResolver).push(effect);\n}\n/**\n *\n * Stores the injected service in frameworkDIDebugData.resolverToTokenToDependencies\n * based on it's injector and token.\n *\n * @param context InjectorProfilerContext the injection context that this event occurred in.\n * @param data InjectedService the service associated with this inject event.\n *\n */\nfunction handleInjectEvent(context, data) {\n const diResolver = getDIResolver(context.injector);\n if (diResolver === null) {\n throwError('An Inject event must be run within an injection context.');\n }\n const diResolverToInstantiatedToken = frameworkDIDebugData.resolverToTokenToDependencies;\n if (!diResolverToInstantiatedToken.has(diResolver)) {\n diResolverToInstantiatedToken.set(diResolver, new WeakMap());\n }\n // if token is a primitive type, ignore this event. We do this because we cannot keep track of\n // non-primitive tokens in WeakMaps since they are not garbage collectable.\n if (!canBeHeldWeakly(context.token)) {\n return;\n }\n const instantiatedTokenToDependencies = diResolverToInstantiatedToken.get(diResolver);\n if (!instantiatedTokenToDependencies.has(context.token)) {\n instantiatedTokenToDependencies.set(context.token, []);\n }\n const {\n token,\n value,\n flags\n } = data;\n assertDefined(context.token, 'Injector profiler context token is undefined.');\n const dependencies = instantiatedTokenToDependencies.get(context.token);\n assertDefined(dependencies, 'Could not resolve dependencies for token.');\n if (context.injector instanceof NodeInjector) {\n dependencies.push({\n token,\n value,\n flags,\n injectedIn: getNodeInjectorContext(context.injector)\n });\n } else {\n dependencies.push({\n token,\n value,\n flags\n });\n }\n}\n/**\n *\n * Returns the LView and TNode associated with a NodeInjector. Returns undefined if the injector\n * is not a NodeInjector.\n *\n * @param injector\n * @returns {lView: LView, tNode: TNode}|undefined\n */\nfunction getNodeInjectorContext(injector) {\n if (!(injector instanceof NodeInjector)) {\n throwError('getNodeInjectorContext must be called with a NodeInjector');\n }\n const lView = getNodeInjectorLView(injector);\n const tNode = getNodeInjectorTNode(injector);\n if (tNode === null) {\n return;\n }\n assertTNodeForLView(tNode, lView);\n return {\n lView,\n tNode\n };\n}\n/**\n *\n * If the created instance is an instance of a standalone component, maps the injector to that\n * standalone component in frameworkDIDebugData.standaloneInjectorToComponent\n *\n * @param context InjectorProfilerContext the injection context that this event occurred in.\n * @param data InjectorCreatedInstance an object containing the instance that was just created\n *\n */\nfunction handleInstanceCreatedByInjectorEvent(context, data) {\n const {\n value\n } = data;\n if (getDIResolver(context.injector) === null) {\n throwError('An InjectorCreatedInstance event must be run within an injection context.');\n }\n // if our value is an instance of a standalone component, map the injector of that standalone\n // component to the component class. Otherwise, this event is a noop.\n let standaloneComponent = undefined;\n if (typeof value === 'object') {\n standaloneComponent = value?.constructor;\n }\n // We want to also cover if `standaloneComponent === null` in addition to `undefined`\n if (standaloneComponent == undefined || !isStandaloneComponent(standaloneComponent)) {\n return;\n }\n const environmentInjector = context.injector.get(EnvironmentInjector, null, {\n optional: true\n });\n // Standalone components should have an environment injector. If one cannot be\n // found we may be in a test case for low level functionality that did not explicitly\n // setup this injector. In those cases, we simply ignore this event.\n if (environmentInjector === null) {\n return;\n }\n const {\n standaloneInjectorToComponent\n } = frameworkDIDebugData;\n // If our injector has already been mapped, as is the case\n // when a standalone component imports another standalone component,\n // we consider the original component (the component doing the importing)\n // as the component connected to our injector.\n if (standaloneInjectorToComponent.has(environmentInjector)) {\n return;\n }\n // If our injector hasn't been mapped, then we map it to the standalone component\n standaloneInjectorToComponent.set(environmentInjector, standaloneComponent);\n}\nfunction isStandaloneComponent(value) {\n const def = getComponentDef(value);\n return !!def?.standalone;\n}\n/**\n *\n * Stores the emitted ProviderRecords from the InjectorProfilerEventType.ProviderConfigured\n * event in frameworkDIDebugData.resolverToProviders\n *\n * @param context InjectorProfilerContext the injection context that this event occurred in.\n * @param data ProviderRecord an object containing the instance that was just created\n *\n */\nfunction handleProviderConfiguredEvent(context, data) {\n const {\n resolverToProviders\n } = frameworkDIDebugData;\n let diResolver;\n if (context?.injector instanceof NodeInjector) {\n diResolver = getNodeInjectorTNode(context.injector);\n } else {\n diResolver = context.injector;\n }\n if (diResolver === null) {\n throwError('A ProviderConfigured event must be run within an injection context.');\n }\n if (!resolverToProviders.has(diResolver)) {\n resolverToProviders.set(diResolver, []);\n }\n resolverToProviders.get(diResolver).push(data);\n}\nfunction getDIResolver(injector) {\n let diResolver = null;\n if (injector === undefined) {\n return diResolver;\n }\n // We use the LView as the diResolver for NodeInjectors because they\n // do not persist anywhere in the framework. They are simply wrappers around an LView and a TNode\n // that do persist. Because of this, we rely on the LView of the NodeInjector in order to use\n // as a concrete key to represent this injector. If we get the same LView back later, we know\n // we're looking at the same injector.\n if (injector instanceof NodeInjector) {\n diResolver = getNodeInjectorLView(injector);\n }\n // Other injectors can be used a keys for a map because their instances\n // persist\n else {\n diResolver = injector;\n }\n return diResolver;\n}\n// inspired by\n// https://tc39.es/ecma262/multipage/executable-code-and-execution-contexts.html#sec-canbeheldweakly\nfunction canBeHeldWeakly(value) {\n // we check for value !== null here because typeof null === 'object\n return value !== null && (typeof value === 'object' || typeof value === 'function' || typeof value === 'symbol');\n}\n\n/**\n * Marks a component for check (in case of OnPush components) and synchronously\n * performs change detection on the application this component belongs to.\n *\n * @param component Component to {@link /api/core/ChangeDetectorRef#markForCheck mark for check}\n *\n * @publicApi\n */\nfunction applyChanges(component) {\n ngDevMode && assertDefined(component, 'component');\n markViewDirty(getComponentViewByInstance(component), 3 /* NotificationSource.DebugApplyChanges */);\n getRootComponents(component).forEach(rootComponent => detectChanges(rootComponent));\n}\n/**\n * Synchronously perform change detection on a component (and possibly its sub-components).\n *\n * This function triggers change detection in a synchronous way on a component.\n *\n * @param component The component which the change detection should be performed on.\n */\nfunction detectChanges(component) {\n const view = getComponentViewByInstance(component);\n view[FLAGS] |= 1024 /* LViewFlags.RefreshView */;\n detectChangesInternal(view);\n}\n\n/**\n * Retrieves all defer blocks in a given LView.\n *\n * @param lView lView with defer blocks\n * @param deferBlocks defer block aggregator array\n */\nfunction getDeferBlocks$1(lView, deferBlocks) {\n const tView = lView[TVIEW];\n for (let i = HEADER_OFFSET; i < tView.bindingStartIndex; i++) {\n if (isLContainer(lView[i])) {\n const lContainer = lView[i];\n // An LContainer may represent an instance of a defer block, in which case\n // we store it as a result. Otherwise, keep iterating over LContainer views and\n // look for defer blocks.\n const isLast = i === tView.bindingStartIndex - 1;\n if (!isLast) {\n const tNode = tView.data[i];\n const tDetails = getTDeferBlockDetails(tView, tNode);\n if (isTDeferBlockDetails(tDetails)) {\n deferBlocks.push({\n lContainer,\n lView,\n tNode,\n tDetails\n });\n // This LContainer represents a defer block, so we exit\n // this iteration and don't inspect views in this LContainer.\n continue;\n }\n }\n for (let i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {\n getDeferBlocks$1(lContainer[i], deferBlocks);\n }\n } else if (isLView(lView[i])) {\n // This is a component, enter the `getDeferBlocks` recursively.\n getDeferBlocks$1(lView[i], deferBlocks);\n }\n }\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Gets all of the `@defer` blocks that are present inside the specified DOM node.\n * @param node Node in which to look for `@defer` blocks.\n *\n * @publicApi\n */\nfunction getDeferBlocks(node) {\n const results = [];\n const lView = getLContext(node)?.lView;\n if (lView) {\n findDeferBlocks(node, lView, results);\n }\n return results;\n}\n/**\n * Finds all the `@defer` blocks inside a specific node and view.\n * @param node Node in which to search for blocks.\n * @param lView View within the node in which to search for blocks.\n * @param results Array to which to add blocks once they're found.\n */\nfunction findDeferBlocks(node, lView, results) {\n const registry = lView[INJECTOR].get(DEHYDRATED_BLOCK_REGISTRY, null, {\n optional: true\n });\n const blocks = [];\n getDeferBlocks$1(lView, blocks);\n for (const details of blocks) {\n const native = getNativeByTNode(details.tNode, details.lView);\n const lDetails = getLDeferBlockDetails(details.lView, details.tNode);\n // The LView from `getLContext` might be the view the element is placed in.\n // Filter out defer blocks that aren't inside the specified root node.\n if (!node.contains(native)) {\n continue;\n }\n const tDetails = details.tDetails;\n const renderedLView = getRendererLView(details);\n const rootNodes = [];\n if (renderedLView !== null) {\n collectNativeNodes(renderedLView[TVIEW], renderedLView, renderedLView[TVIEW].firstChild, rootNodes);\n }\n const data = {\n state: stringifyState(lDetails[DEFER_BLOCK_STATE]),\n incrementalHydrationState: inferHydrationState(tDetails, lDetails, registry),\n hasErrorBlock: tDetails.errorTmplIndex !== null,\n loadingBlock: {\n exists: tDetails.loadingTmplIndex !== null,\n minimumTime: tDetails.loadingBlockConfig?.[MINIMUM_SLOT] ?? null,\n afterTime: tDetails.loadingBlockConfig?.[LOADING_AFTER_SLOT] ?? null\n },\n placeholderBlock: {\n exists: tDetails.placeholderTmplIndex !== null,\n minimumTime: tDetails.placeholderBlockConfig?.[MINIMUM_SLOT] ?? null\n },\n triggers: tDetails.debug?.triggers ? Array.from(tDetails.debug.triggers).sort() : [],\n rootNodes\n };\n results.push(data);\n // `getDeferBlocks` does not resolve nested defer blocks so we have to recurse manually.\n if (renderedLView !== null) {\n findDeferBlocks(node, renderedLView, results);\n }\n }\n}\n/**\n * Turns the `DeferBlockState` into a string which is more readable than the enum form.\n *\n * @param lDetails Information about the\n * @returns\n */\nfunction stringifyState(state) {\n switch (state) {\n case DeferBlockState.Complete:\n return 'complete';\n case DeferBlockState.Loading:\n return 'loading';\n case DeferBlockState.Placeholder:\n return 'placeholder';\n case DeferBlockState.Error:\n return 'error';\n case DeferBlockInternalState.Initial:\n return 'initial';\n default:\n throw new Error(`Unrecognized state ${state}`);\n }\n}\n/**\n * Infers the hydration state of a specific defer block.\n * @param tDetails Static defer block information.\n * @param lDetails Instance defer block information.\n * @param registry Registry coordinating the hydration of defer blocks.\n */\nfunction inferHydrationState(tDetails, lDetails, registry) {\n if (registry === null || lDetails[SSR_UNIQUE_ID] === null || tDetails.hydrateTriggers === null || tDetails.hydrateTriggers.has(7 /* DeferBlockTrigger.Never */)) {\n return 'not-configured';\n }\n return registry.has(lDetails[SSR_UNIQUE_ID]) ? 'dehydrated' : 'hydrated';\n}\n/**\n * Gets the current LView that is rendered out in a defer block.\n * @param details Instance information about the block.\n */\nfunction getRendererLView(details) {\n // Defer block containers can only ever contain one view.\n // If they're empty, it means that nothing is rendered.\n if (details.lContainer.length <= CONTAINER_HEADER_OFFSET) {\n return null;\n }\n const lView = details.lContainer[CONTAINER_HEADER_OFFSET];\n ngDevMode && assertLView(lView);\n return lView;\n}\n\n/**\n * Discovers the dependencies of an injectable instance. Provides DI information about each\n * dependency that the injectable was instantiated with, including where they were provided from.\n *\n * @param injector An injector instance\n * @param token a DI token that was constructed by the given injector instance\n * @returns an object that contains the created instance of token as well as all of the dependencies\n * that it was instantiated with OR undefined if the token was not created within the given\n * injector.\n */\nfunction getDependenciesFromInjectable(injector, token) {\n // First we check to see if the token given maps to an actual instance in the injector given.\n // We use `self: true` because we only want to look at the injector we were given.\n // We use `optional: true` because it's possible that the token we were given was never\n // constructed by the injector we were given.\n const instance = injector.get(token, null, {\n self: true,\n optional: true\n });\n if (instance === null) {\n throw new Error(`Unable to determine instance of ${token} in given injector`);\n }\n const unformattedDependencies = getDependenciesForTokenInInjector(token, injector);\n const resolutionPath = getInjectorResolutionPath(injector);\n const dependencies = unformattedDependencies.map(dep => {\n // injectedIn contains private fields, so we omit it from the response\n const formattedDependency = {\n value: dep.value\n };\n // convert injection flags to booleans\n const flags = dep.flags;\n formattedDependency.flags = {\n optional: (8 /* InternalInjectFlags.Optional */ & flags) === 8 /* InternalInjectFlags.Optional */,\n host: (1 /* InternalInjectFlags.Host */ & flags) === 1 /* InternalInjectFlags.Host */,\n self: (2 /* InternalInjectFlags.Self */ & flags) === 2 /* InternalInjectFlags.Self */,\n skipSelf: (4 /* InternalInjectFlags.SkipSelf */ & flags) === 4 /* InternalInjectFlags.SkipSelf */\n };\n // find the injector that provided the dependency\n for (let i = 0; i < resolutionPath.length; i++) {\n const injectorToCheck = resolutionPath[i];\n // if skipSelf is true we skip the first injector\n if (i === 0 && formattedDependency.flags.skipSelf) {\n continue;\n }\n // host only applies to NodeInjectors\n if (formattedDependency.flags.host && injectorToCheck instanceof EnvironmentInjector) {\n break;\n }\n const instance = injectorToCheck.get(dep.token, null, {\n self: true,\n optional: true\n });\n if (instance !== null) {\n // if host flag is true we double check that we can get the service from the first element\n // in the resolution path by using the host flag. This is done to make sure that we've found\n // the correct providing injector, and not a node injector that is connected to our path via\n // a router outlet.\n if (formattedDependency.flags.host) {\n const firstInjector = resolutionPath[0];\n const lookupFromFirstInjector = firstInjector.get(dep.token, null, {\n ...formattedDependency.flags,\n optional: true\n });\n if (lookupFromFirstInjector !== null) {\n formattedDependency.providedIn = injectorToCheck;\n }\n break;\n }\n formattedDependency.providedIn = injectorToCheck;\n break;\n }\n // if self is true we stop after the first injector\n if (i === 0 && formattedDependency.flags.self) {\n break;\n }\n }\n if (dep.token) formattedDependency.token = dep.token;\n return formattedDependency;\n });\n return {\n instance,\n dependencies\n };\n}\nfunction getDependenciesForTokenInInjector(token, injector) {\n const {\n resolverToTokenToDependencies\n } = getFrameworkDIDebugData();\n if (!(injector instanceof NodeInjector)) {\n return resolverToTokenToDependencies.get(injector)?.get?.(token) ?? [];\n }\n const lView = getNodeInjectorLView(injector);\n const tokenDependencyMap = resolverToTokenToDependencies.get(lView);\n const dependencies = tokenDependencyMap?.get(token) ?? [];\n // In the NodeInjector case, all injections for every node are stored in the same lView.\n // We use the injectedIn field of the dependency to filter out the dependencies that\n // do not come from the same node as the instance we're looking at.\n return dependencies.filter(dependency => {\n const dependencyNode = dependency.injectedIn?.tNode;\n if (dependencyNode === undefined) {\n return false;\n }\n const instanceNode = getNodeInjectorTNode(injector);\n assertTNode(dependencyNode);\n assertTNode(instanceNode);\n return dependencyNode === instanceNode;\n });\n}\n/**\n * Gets the class associated with an injector that contains a provider `imports` array in it's\n * definition\n *\n * For Module Injectors this returns the NgModule constructor.\n *\n * For Standalone injectors this returns the standalone component constructor.\n *\n * @param injector Injector an injector instance\n * @returns the constructor where the `imports` array that configures this injector is located\n */\nfunction getProviderImportsContainer(injector) {\n const {\n standaloneInjectorToComponent\n } = getFrameworkDIDebugData();\n // standalone components configure providers through a component def, so we have to\n // use the standalone component associated with this injector if Injector represents\n // a standalone components EnvironmentInjector\n if (standaloneInjectorToComponent.has(injector)) {\n return standaloneInjectorToComponent.get(injector);\n }\n // Module injectors configure providers through their NgModule def, so we use the\n // injector to lookup its NgModuleRef and through that grab its instance\n const defTypeRef = injector.get(NgModuleRef$1, null, {\n self: true,\n optional: true\n });\n // If we can't find an associated imports container, return null.\n // This could be the case if this function is called with an R3Injector that does not represent\n // a standalone component or NgModule.\n if (defTypeRef === null) {\n return null;\n }\n // In standalone applications, the root environment injector created by bootstrapApplication\n // may have no associated \"instance\".\n if (defTypeRef.instance === null) {\n return null;\n }\n return defTypeRef.instance.constructor;\n}\n/**\n * Gets the providers configured on a NodeInjector\n *\n * @param injector A NodeInjector instance\n * @returns ProviderRecord[] an array of objects representing the providers configured on this\n * injector\n */\nfunction getNodeInjectorProviders(injector) {\n const diResolver = getNodeInjectorTNode(injector);\n const {\n resolverToProviders\n } = getFrameworkDIDebugData();\n return resolverToProviders.get(diResolver) ?? [];\n}\n/**\n * Gets a mapping of providers configured on an injector to their import paths\n *\n * ModuleA -> imports ModuleB\n * ModuleB -> imports ModuleC\n * ModuleB -> provides MyServiceA\n * ModuleC -> provides MyServiceB\n *\n * getProviderImportPaths(ModuleA)\n * > Map(2) {\n * MyServiceA => [ModuleA, ModuleB]\n * MyServiceB => [ModuleA, ModuleB, ModuleC]\n * }\n *\n * @param providerImportsContainer constructor of class that contains an `imports` array in it's\n * definition\n * @returns A Map object that maps providers to an array of constructors representing it's import\n * path\n *\n */\nfunction getProviderImportPaths(providerImportsContainer) {\n const providerToPath = new Map();\n const visitedContainers = new Set();\n const visitor = walkProviderTreeToDiscoverImportPaths(providerToPath, visitedContainers);\n walkProviderTree(providerImportsContainer, visitor, [], new Set());\n return providerToPath;\n}\n/**\n *\n * Higher order function that returns a visitor for WalkProviderTree\n *\n * Takes in a Map and Set to keep track of the providers and containers\n * visited, so that we can discover the import paths of these providers\n * during the traversal.\n *\n * This visitor takes advantage of the fact that walkProviderTree performs a\n * postorder traversal of the provider tree for the passed in container. Because postorder\n * traversal recursively processes subtrees from leaf nodes until the traversal reaches the root,\n * we write a visitor that constructs provider import paths in reverse.\n *\n *\n * We use the visitedContainers set defined outside this visitor\n * because we want to run some logic only once for\n * each container in the tree. That logic can be described as:\n *\n *\n * 1. for each discovered_provider and discovered_path in the incomplete provider paths we've\n * already discovered\n * 2. get the first container in discovered_path\n * 3. if that first container is in the imports array of the container we're visiting\n * Then the container we're visiting is also in the import path of discovered_provider, so we\n * unshift discovered_path with the container we're currently visiting\n *\n *\n * Example Run:\n * ```\n * ┌──────────â”\n * │containerA│\n * ┌─imports-─┤ ├──imports─â”\n * │ │ provA │ │\n * │ │ provB │ │\n * │ └──────────┘ │\n * │ │\n * ┌▼─────────┠┌────────▼─â”\n * │containerB│ │containerC│\n * │ │ │ │\n * │ provD │ │ provF │\n * │ provE │ │ provG │\n * └──────────┘ └──────────┘\n * ```\n *\n * Each step of the traversal,\n *\n * ```\n * visitor(provD, containerB)\n * providerToPath === Map { provD => [containerB] }\n * visitedContainers === Set { containerB }\n *\n * visitor(provE, containerB)\n * providerToPath === Map { provD => [containerB], provE => [containerB] }\n * visitedContainers === Set { containerB }\n *\n * visitor(provF, containerC)\n * providerToPath === Map { provD => [containerB], provE => [containerB], provF => [containerC] }\n * visitedContainers === Set { containerB, containerC }\n *\n * visitor(provG, containerC)\n * providerToPath === Map {\n * provD => [containerB], provE => [containerB], provF => [containerC], provG => [containerC]\n * }\n * visitedContainers === Set { containerB, containerC }\n *\n * visitor(provA, containerA)\n * providerToPath === Map {\n * provD => [containerA, containerB],\n * provE => [containerA, containerB],\n * provF => [containerA, containerC],\n * provG => [containerA, containerC],\n * provA => [containerA]\n * }\n * visitedContainers === Set { containerB, containerC, containerA }\n *\n * visitor(provB, containerA)\n * providerToPath === Map {\n * provD => [containerA, containerB],\n * provE => [containerA, containerB],\n * provF => [containerA, containerC],\n * provG => [containerA, containerC],\n * provA => [containerA]\n * provB => [containerA]\n * }\n * visitedContainers === Set { containerB, containerC, containerA }\n * ```\n *\n * @param providerToPath Map map of providers to paths that this function fills\n * @param visitedContainers Set a set to keep track of the containers we've already visited\n * @return function(provider SingleProvider, container: Type<unknown> | InjectorType<unknown>) =>\n * void\n */\nfunction walkProviderTreeToDiscoverImportPaths(providerToPath, visitedContainers) {\n return (provider, container) => {\n // If the provider is not already in the providerToPath map,\n // add an entry with the provider as the key and an array containing the current container as\n // the value\n if (!providerToPath.has(provider)) {\n providerToPath.set(provider, [container]);\n }\n // This block will run exactly once for each container in the import tree.\n // This is where we run the logic to check the imports array of the current\n // container to see if it's the next container in the path for our currently\n // discovered providers.\n if (!visitedContainers.has(container)) {\n // Iterate through the providers we've already seen\n for (const prov of providerToPath.keys()) {\n const existingImportPath = providerToPath.get(prov);\n let containerDef = getInjectorDef(container);\n if (!containerDef) {\n const ngModule = container.ngModule;\n containerDef = getInjectorDef(ngModule);\n }\n if (!containerDef) {\n return;\n }\n const lastContainerAddedToPath = existingImportPath[0];\n let isNextStepInPath = false;\n deepForEach(containerDef.imports, moduleImport => {\n if (isNextStepInPath) {\n return;\n }\n isNextStepInPath = moduleImport.ngModule === lastContainerAddedToPath || moduleImport === lastContainerAddedToPath;\n if (isNextStepInPath) {\n providerToPath.get(prov)?.unshift(container);\n }\n });\n }\n }\n visitedContainers.add(container);\n };\n}\n/**\n * Gets the providers configured on an EnvironmentInjector\n *\n * @param injector EnvironmentInjector\n * @returns an array of objects representing the providers of the given injector\n */\nfunction getEnvironmentInjectorProviders(injector) {\n const providerRecordsWithoutImportPaths = getFrameworkDIDebugData().resolverToProviders.get(injector) ?? [];\n // platform injector has no provider imports container so can we skip trying to\n // find import paths\n if (isPlatformInjector(injector)) {\n return providerRecordsWithoutImportPaths;\n }\n const providerImportsContainer = getProviderImportsContainer(injector);\n if (providerImportsContainer === null) {\n // We assume that if an environment injector exists without an associated provider imports\n // container, it was created without such a container. Some examples cases where this could\n // happen:\n // - The root injector of a standalone application\n // - A router injector created by using the providers array in a lazy loaded route\n // - A manually created injector that is attached to the injector tree\n // Since each of these cases has no provider container, there is no concept of import paths,\n // so we can simply return the provider records.\n return providerRecordsWithoutImportPaths;\n }\n const providerToPath = getProviderImportPaths(providerImportsContainer);\n const providerRecords = [];\n for (const providerRecord of providerRecordsWithoutImportPaths) {\n const provider = providerRecord.provider;\n // Ignore these special providers for now until we have a cleaner way of\n // determing when they are provided by the framework vs provided by the user.\n const token = provider.provide;\n if (token === ENVIRONMENT_INITIALIZER || token === INJECTOR_DEF_TYPES) {\n continue;\n }\n let importPath = providerToPath.get(provider) ?? [];\n const def = getComponentDef(providerImportsContainer);\n const isStandaloneComponent = !!def?.standalone;\n // We prepend the component constructor in the standalone case\n // because walkProviderTree does not visit this constructor during it's traversal\n if (isStandaloneComponent) {\n importPath = [providerImportsContainer, ...importPath];\n }\n providerRecords.push({\n ...providerRecord,\n importPath\n });\n }\n return providerRecords;\n}\nfunction isPlatformInjector(injector) {\n return injector instanceof R3Injector && injector.scopes.has('platform');\n}\n/**\n * Gets the providers configured on an injector.\n *\n * @param injector the injector to lookup the providers of\n * @returns ProviderRecord[] an array of objects representing the providers of the given injector\n */\nfunction getInjectorProviders(injector) {\n if (injector instanceof NodeInjector) {\n return getNodeInjectorProviders(injector);\n } else if (injector instanceof EnvironmentInjector) {\n return getEnvironmentInjectorProviders(injector);\n }\n throwError('getInjectorProviders only supports NodeInjector and EnvironmentInjector');\n}\n/**\n *\n * Given an injector, this function will return\n * an object containing the type and source of the injector.\n *\n * | | type | source |\n * |--------------|-------------|-------------------------------------------------------------|\n * | NodeInjector | element | DOM element that created this injector |\n * | R3Injector | environment | `injector.source` |\n * | NullInjector | null | null |\n *\n * @param injector the Injector to get metadata for\n * @returns an object containing the type and source of the given injector. If the injector metadata\n * cannot be determined, returns null.\n */\nfunction getInjectorMetadata(injector) {\n if (injector instanceof NodeInjector) {\n const lView = getNodeInjectorLView(injector);\n const tNode = getNodeInjectorTNode(injector);\n assertTNodeForLView(tNode, lView);\n return {\n type: 'element',\n source: getNativeByTNode(tNode, lView)\n };\n }\n if (injector instanceof R3Injector) {\n return {\n type: 'environment',\n source: injector.source ?? null\n };\n }\n if (injector instanceof NullInjector) {\n return {\n type: 'null',\n source: null\n };\n }\n return null;\n}\nfunction getInjectorResolutionPath(injector) {\n const resolutionPath = [injector];\n getInjectorResolutionPathHelper(injector, resolutionPath);\n return resolutionPath;\n}\nfunction getInjectorResolutionPathHelper(injector, resolutionPath) {\n const parent = getInjectorParent(injector);\n // if getInjectorParent can't find a parent, then we've either reached the end\n // of the path, or we need to move from the Element Injector tree to the\n // module injector tree using the first injector in our path as the connection point.\n if (parent === null) {\n if (injector instanceof NodeInjector) {\n const firstInjector = resolutionPath[0];\n if (firstInjector instanceof NodeInjector) {\n const moduleInjector = getModuleInjectorOfNodeInjector(firstInjector);\n if (moduleInjector === null) {\n throwError('NodeInjector must have some connection to the module injector tree');\n }\n resolutionPath.push(moduleInjector);\n getInjectorResolutionPathHelper(moduleInjector, resolutionPath);\n }\n return resolutionPath;\n }\n } else {\n resolutionPath.push(parent);\n getInjectorResolutionPathHelper(parent, resolutionPath);\n }\n return resolutionPath;\n}\n/**\n * Gets the parent of an injector.\n *\n * This function is not able to make the jump from the Element Injector Tree to the Module\n * injector tree. This is because the \"parent\" (the next step in the reoslution path)\n * of a root NodeInjector is dependent on which NodeInjector ancestor initiated\n * the DI lookup. See getInjectorResolutionPath for a function that can make this jump.\n *\n * In the below diagram:\n * ```ts\n * getInjectorParent(NodeInjectorB)\n * > NodeInjectorA\n * getInjectorParent(NodeInjectorA) // or getInjectorParent(getInjectorParent(NodeInjectorB))\n * > null // cannot jump to ModuleInjector tree\n * ```\n *\n * ```\n * ┌───────┠┌───────────────────â”\n * ┌───────────┤ModuleA├───Injector────►│EnvironmentInjector│\n * │ └───┬───┘ └───────────────────┘\n * │ │\n * │ bootstraps\n * │ │\n * │ │\n * │ ┌────▼─────┠┌─────────────â”\n * declares │ComponentA├────Injector────►│NodeInjectorA│\n * │ └────┬─────┘ └─────▲───────┘\n * │ │ │\n * │ renders parent\n * │ │ │\n * │ ┌────▼─────┠┌─────┴───────â”\n * └─────────►│ComponentB├────Injector────►│NodeInjectorB│\n * └──────────┘ └─────────────┘\n *```\n *\n * @param injector an Injector to get the parent of\n * @returns Injector the parent of the given injector\n */\nfunction getInjectorParent(injector) {\n if (injector instanceof R3Injector) {\n const parent = injector.parent;\n if (isRouterOutletInjector(parent)) {\n // This is a special case for a `ChainedInjector` instance, which represents\n // a combination of a Router's `OutletInjector` and an EnvironmentInjector,\n // which represents a `@defer` block. Since the `OutletInjector` doesn't store\n // any tokens itself, we point to the parent injector instead. See the\n // `OutletInjector.__ngOutletInjector` field for additional information.\n return parent.parentInjector;\n }\n return parent;\n }\n let tNode;\n let lView;\n if (injector instanceof NodeInjector) {\n tNode = getNodeInjectorTNode(injector);\n lView = getNodeInjectorLView(injector);\n } else if (injector instanceof NullInjector) {\n return null;\n } else if (injector instanceof ChainedInjector) {\n return injector.parentInjector;\n } else {\n throwError('getInjectorParent only support injectors of type R3Injector, NodeInjector, NullInjector');\n }\n const parentLocation = getParentInjectorLocation(tNode, lView);\n if (hasParentInjector(parentLocation)) {\n const parentInjectorIndex = getParentInjectorIndex(parentLocation);\n const parentLView = getParentInjectorView(parentLocation, lView);\n const parentTView = parentLView[TVIEW];\n const parentTNode = parentTView.data[parentInjectorIndex + 8 /* NodeInjectorOffset.TNODE */];\n return new NodeInjector(parentTNode, parentLView);\n } else {\n const chainedInjector = lView[INJECTOR];\n // Case where chainedInjector.injector is an OutletInjector and chainedInjector.injector.parent\n // is a NodeInjector.\n // todo(aleksanderbodurri): ideally nothing in packages/core should deal\n // directly with router concerns. Refactor this so that we can make the jump from\n // NodeInjector -> OutletInjector -> NodeInjector\n // without explicitly relying on types contracts from packages/router\n const injectorParent = chainedInjector.injector?.parent;\n if (injectorParent instanceof NodeInjector) {\n return injectorParent;\n }\n }\n return null;\n}\n/**\n * Gets the module injector of a NodeInjector.\n *\n * @param injector NodeInjector to get module injector of\n * @returns Injector representing module injector of the given NodeInjector\n */\nfunction getModuleInjectorOfNodeInjector(injector) {\n let lView;\n if (injector instanceof NodeInjector) {\n lView = getNodeInjectorLView(injector);\n } else {\n throwError('getModuleInjectorOfNodeInjector must be called with a NodeInjector');\n }\n const inj = lView[INJECTOR];\n const moduleInjector = inj instanceof ChainedInjector ? inj.parentInjector : inj.parent;\n if (!moduleInjector) {\n throwError('NodeInjector must have some connection to the module injector tree');\n }\n return moduleInjector;\n}\nfunction isComputedNode(node) {\n return node.kind === 'computed';\n}\nfunction isTemplateEffectNode(node) {\n return node.kind === 'template';\n}\nfunction isEffectNode(node) {\n return node.kind === 'effect';\n}\nfunction isSignalNode(node) {\n return node.kind === 'signal';\n}\n/**\n *\n * @param injector\n * @returns Template consumer of given NodeInjector\n */\nfunction getTemplateConsumer(injector) {\n const tNode = getNodeInjectorTNode(injector);\n assertTNode(tNode);\n const lView = getNodeInjectorLView(injector);\n assertLView(lView);\n const templateLView = lView[tNode.index];\n assertLView(templateLView);\n return templateLView[REACTIVE_TEMPLATE_CONSUMER];\n}\nfunction getNodesAndEdgesFromSignalMap(signalMap) {\n const nodes = Array.from(signalMap.keys());\n const debugSignalGraphNodes = [];\n const edges = [];\n for (const [consumer, producers] of signalMap.entries()) {\n const consumerIndex = nodes.indexOf(consumer);\n // collect node\n if (isComputedNode(consumer) || isSignalNode(consumer)) {\n debugSignalGraphNodes.push({\n label: consumer.debugName,\n value: consumer.value,\n kind: consumer.kind\n });\n } else if (isTemplateEffectNode(consumer)) {\n debugSignalGraphNodes.push({\n label: consumer.debugName ?? consumer.lView?.[HOST]?.tagName?.toLowerCase?.(),\n kind: consumer.kind\n });\n } else if (isEffectNode(consumer)) {\n debugSignalGraphNodes.push({\n label: consumer.debugName,\n kind: consumer.kind\n });\n } else {\n debugSignalGraphNodes.push({\n label: consumer.debugName,\n kind: consumer.kind\n });\n }\n // collect edges for node\n for (const producer of producers) {\n edges.push({\n consumer: consumerIndex,\n producer: nodes.indexOf(producer)\n });\n }\n }\n return {\n nodes: debugSignalGraphNodes,\n edges\n };\n}\nfunction extractEffectsFromInjector(injector) {\n let diResolver = injector;\n if (injector instanceof NodeInjector) {\n const lView = getNodeInjectorLView(injector);\n diResolver = lView;\n }\n const resolverToEffects = getFrameworkDIDebugData().resolverToEffects;\n const effects = resolverToEffects.get(diResolver) ?? [];\n return effects.map(effect => effect[SIGNAL$1]);\n}\nfunction extractSignalNodesAndEdgesFromRoots(nodes, signalDependenciesMap = new Map()) {\n for (const node of nodes) {\n if (signalDependenciesMap.has(node)) {\n continue;\n }\n const producerNodes = node.producerNode ?? [];\n signalDependenciesMap.set(node, producerNodes);\n extractSignalNodesAndEdgesFromRoots(producerNodes, signalDependenciesMap);\n }\n return signalDependenciesMap;\n}\n/**\n * Returns a debug representation of the signal graph for the given injector.\n *\n * Currently only supports element injectors. Starts by discovering the consumer nodes\n * and then traverses their producer nodes to build the signal graph.\n *\n * @param injector The injector to get the signal graph for.\n * @returns A debug representation of the signal graph.\n * @throws If the injector is an environment injector.\n */\nfunction getSignalGraph(injector) {\n let templateConsumer = null;\n if (!(injector instanceof NodeInjector) && !(injector instanceof R3Injector)) {\n return throwError('getSignalGraph must be called with a NodeInjector or R3Injector');\n }\n if (injector instanceof NodeInjector) {\n templateConsumer = getTemplateConsumer(injector);\n }\n const nonTemplateEffectNodes = extractEffectsFromInjector(injector);\n const signalNodes = templateConsumer ? [templateConsumer, ...nonTemplateEffectNodes] : nonTemplateEffectNodes;\n const signalDependenciesMap = extractSignalNodesAndEdgesFromRoots(signalNodes);\n return getNodesAndEdgesFromSignalMap(signalDependenciesMap);\n}\n\n/**\n * This file introduces series of globally accessible debug tools\n * to allow for the Angular debugging story to function.\n *\n * To see this in action run the following command:\n *\n * bazel run //packages/core/test/bundling/todo:devserver\n *\n * Then load `localhost:5432` and start using the console tools.\n */\n/**\n * This value reflects the property on the window where the dev\n * tools are patched (window.ng).\n * */\nconst GLOBAL_PUBLISH_EXPANDO_KEY = 'ng';\nconst globalUtilsFunctions = {\n /**\n * Warning: functions that start with `ɵ` are considered *INTERNAL* and should not be relied upon\n * in application's code. The contract of those functions might be changed in any release and/or a\n * function can be removed completely.\n */\n 'ɵgetDependenciesFromInjectable': getDependenciesFromInjectable,\n 'ɵgetInjectorProviders': getInjectorProviders,\n 'ɵgetInjectorResolutionPath': getInjectorResolutionPath,\n 'ɵgetInjectorMetadata': getInjectorMetadata,\n 'ɵsetProfiler': setProfiler,\n 'ɵgetSignalGraph': getSignalGraph,\n 'ɵgetDeferBlocks': getDeferBlocks,\n 'getDirectiveMetadata': getDirectiveMetadata$1,\n 'getComponent': getComponent,\n 'getContext': getContext,\n 'getListeners': getListeners,\n 'getOwningComponent': getOwningComponent,\n 'getHostElement': getHostElement,\n 'getInjector': getInjector,\n 'getRootComponents': getRootComponents,\n 'getDirectives': getDirectives,\n 'applyChanges': applyChanges,\n 'isSignal': isSignal\n};\nlet _published = false;\n/**\n * Publishes a collection of default debug tools onto`window.ng`.\n *\n * These functions are available globally when Angular is in development\n * mode and are automatically stripped away from prod mode is on.\n */\nfunction publishDefaultGlobalUtils$1() {\n if (!_published) {\n _published = true;\n if (typeof window !== 'undefined') {\n // Only configure the injector profiler when running in the browser.\n setupFrameworkInjectorProfiler();\n }\n for (const [methodName, method] of Object.entries(globalUtilsFunctions)) {\n publishGlobalUtil(methodName, method);\n }\n }\n}\n/**\n * Publishes the given function to `window.ng` so that it can be\n * used from the browser console when an application is not in production.\n */\nfunction publishGlobalUtil(name, fn) {\n publishUtil(name, fn);\n}\n/**\n * Publishes the given function to `window.ng` from package other than @angular/core\n * So that it can be used from the browser console when an application is not in production.\n */\nfunction publishExternalGlobalUtil(name, fn) {\n publishUtil(name, fn);\n}\nfunction publishUtil(name, fn) {\n if (typeof COMPILED === 'undefined' || !COMPILED) {\n // Note: we can't export `ng` when using closure enhanced optimization as:\n // - closure declares globals itself for minified names, which sometimes clobber our `ng` global\n // - we can't declare a closure extern as the namespace `ng` is already used within Google\n // for typings for AngularJS (via `goog.provide('ng....')`).\n const w = _global;\n ngDevMode && assertDefined(fn, 'function not defined');\n w[GLOBAL_PUBLISH_EXPANDO_KEY] ??= {};\n w[GLOBAL_PUBLISH_EXPANDO_KEY][name] = fn;\n }\n}\n\n/**\n * Internal injection token that can used to access an instance of a Testability class.\n *\n * This token acts as a bridge between the core bootstrap code and the `Testability` class. This is\n * needed to ensure that there are no direct references to the `Testability` class, so it can be\n * tree-shaken away (if not referenced). For the environments/setups when the `Testability` class\n * should be available, this token is used to add a provider that references the `Testability`\n * class. Otherwise, only this token is retained in a bundle, but the `Testability` class is not.\n */\nconst TESTABILITY = new InjectionToken('');\n/**\n * Internal injection token to retrieve Testability getter class instance.\n */\nconst TESTABILITY_GETTER = new InjectionToken('');\n/**\n * The Testability service provides testing hooks that can be accessed from\n * the browser.\n *\n * Angular applications bootstrapped using an NgModule (via `@NgModule.bootstrap` field) will also\n * instantiate Testability by default (in both development and production modes).\n *\n * For applications bootstrapped using the `bootstrapApplication` function, Testability is not\n * included by default. You can include it into your applications by getting the list of necessary\n * providers using the `provideProtractorTestingSupport()` function and adding them into the\n * `options.providers` array. Example:\n *\n * ```ts\n * import {provideProtractorTestingSupport} from '@angular/platform-browser';\n *\n * await bootstrapApplication(RootComponent, providers: [provideProtractorTestingSupport()]);\n * ```\n *\n * @publicApi\n */\nclass Testability {\n _ngZone;\n registry;\n _isZoneStable = true;\n _callbacks = [];\n taskTrackingZone = null;\n constructor(_ngZone, registry, testabilityGetter) {\n this._ngZone = _ngZone;\n this.registry = registry;\n // If there was no Testability logic registered in the global scope\n // before, register the current testability getter as a global one.\n if (!_testabilityGetter) {\n setTestabilityGetter(testabilityGetter);\n testabilityGetter.addToWindow(registry);\n }\n this._watchAngularEvents();\n _ngZone.run(() => {\n this.taskTrackingZone = typeof Zone == 'undefined' ? null : Zone.current.get('TaskTrackingZone');\n });\n }\n _watchAngularEvents() {\n this._ngZone.onUnstable.subscribe({\n next: () => {\n this._isZoneStable = false;\n }\n });\n this._ngZone.runOutsideAngular(() => {\n this._ngZone.onStable.subscribe({\n next: () => {\n NgZone.assertNotInAngularZone();\n queueMicrotask(() => {\n this._isZoneStable = true;\n this._runCallbacksIfReady();\n });\n }\n });\n });\n }\n /**\n * Whether an associated application is stable\n */\n isStable() {\n return this._isZoneStable && !this._ngZone.hasPendingMacrotasks;\n }\n _runCallbacksIfReady() {\n if (this.isStable()) {\n // Schedules the call backs in a new frame so that it is always async.\n queueMicrotask(() => {\n while (this._callbacks.length !== 0) {\n let cb = this._callbacks.pop();\n clearTimeout(cb.timeoutId);\n cb.doneCb();\n }\n });\n } else {\n // Still not stable, send updates.\n let pending = this.getPendingTasks();\n this._callbacks = this._callbacks.filter(cb => {\n if (cb.updateCb && cb.updateCb(pending)) {\n clearTimeout(cb.timeoutId);\n return false;\n }\n return true;\n });\n }\n }\n getPendingTasks() {\n if (!this.taskTrackingZone) {\n return [];\n }\n // Copy the tasks data so that we don't leak tasks.\n return this.taskTrackingZone.macroTasks.map(t => {\n return {\n source: t.source,\n // From TaskTrackingZone:\n // https://github.com/angular/zone.js/blob/master/lib/zone-spec/task-tracking.ts#L40\n creationLocation: t.creationLocation,\n data: t.data\n };\n });\n }\n addCallback(cb, timeout, updateCb) {\n let timeoutId = -1;\n if (timeout && timeout > 0) {\n timeoutId = setTimeout(() => {\n this._callbacks = this._callbacks.filter(cb => cb.timeoutId !== timeoutId);\n cb();\n }, timeout);\n }\n this._callbacks.push({\n doneCb: cb,\n timeoutId: timeoutId,\n updateCb: updateCb\n });\n }\n /**\n * Wait for the application to be stable with a timeout. If the timeout is reached before that\n * happens, the callback receives a list of the macro tasks that were pending, otherwise null.\n *\n * @param doneCb The callback to invoke when Angular is stable or the timeout expires\n * whichever comes first.\n * @param timeout Optional. The maximum time to wait for Angular to become stable. If not\n * specified, whenStable() will wait forever.\n * @param updateCb Optional. If specified, this callback will be invoked whenever the set of\n * pending macrotasks changes. If this callback returns true doneCb will not be invoked\n * and no further updates will be issued.\n */\n whenStable(doneCb, timeout, updateCb) {\n if (updateCb && !this.taskTrackingZone) {\n throw new Error('Task tracking zone is required when passing an update callback to ' + 'whenStable(). Is \"zone.js/plugins/task-tracking\" loaded?');\n }\n this.addCallback(doneCb, timeout, updateCb);\n this._runCallbacksIfReady();\n }\n /**\n * Registers an application with a testability hook so that it can be tracked.\n * @param token token of application, root element\n *\n * @internal\n */\n registerApplication(token) {\n this.registry.registerApplication(token, this);\n }\n /**\n * Unregisters an application.\n * @param token token of application, root element\n *\n * @internal\n */\n unregisterApplication(token) {\n this.registry.unregisterApplication(token);\n }\n /**\n * Find providers by name\n * @param using The root element to search from\n * @param provider The name of binding variable\n * @param exactMatch Whether using exactMatch\n */\n findProviders(using, provider, exactMatch) {\n // TODO(juliemr): implement.\n return [];\n }\n static ɵfac = function Testability_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || Testability)(ɵɵinject(NgZone), ɵɵinject(TestabilityRegistry), ɵɵinject(TESTABILITY_GETTER));\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: Testability,\n factory: Testability.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(Testability, [{\n type: Injectable\n }], () => [{\n type: NgZone\n }, {\n type: TestabilityRegistry\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [TESTABILITY_GETTER]\n }]\n }], null);\n})();\n/**\n * A global registry of {@link Testability} instances for specific elements.\n * @publicApi\n */\nclass TestabilityRegistry {\n /** @internal */\n _applications = new Map();\n /**\n * Registers an application with a testability hook so that it can be tracked\n * @param token token of application, root element\n * @param testability Testability hook\n */\n registerApplication(token, testability) {\n this._applications.set(token, testability);\n }\n /**\n * Unregisters an application.\n * @param token token of application, root element\n */\n unregisterApplication(token) {\n this._applications.delete(token);\n }\n /**\n * Unregisters all applications\n */\n unregisterAllApplications() {\n this._applications.clear();\n }\n /**\n * Get a testability hook associated with the application\n * @param elem root element\n */\n getTestability(elem) {\n return this._applications.get(elem) || null;\n }\n /**\n * Get all registered testabilities\n */\n getAllTestabilities() {\n return Array.from(this._applications.values());\n }\n /**\n * Get all registered applications(root elements)\n */\n getAllRootElements() {\n return Array.from(this._applications.keys());\n }\n /**\n * Find testability of a node in the Tree\n * @param elem node\n * @param findInAncestors whether finding testability in ancestors if testability was not found in\n * current node\n */\n findTestabilityInTree(elem, findInAncestors = true) {\n return _testabilityGetter?.findTestabilityInTree(this, elem, findInAncestors) ?? null;\n }\n static ɵfac = function TestabilityRegistry_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || TestabilityRegistry)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: TestabilityRegistry,\n factory: TestabilityRegistry.ɵfac,\n providedIn: 'platform'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(TestabilityRegistry, [{\n type: Injectable,\n args: [{\n providedIn: 'platform'\n }]\n }], null, null);\n})();\n/**\n * Set the {@link GetTestability} implementation used by the Angular testing framework.\n * @publicApi\n */\nfunction setTestabilityGetter(getter) {\n _testabilityGetter = getter;\n}\nlet _testabilityGetter;\n\n/**\n * A scheduler which manages the execution of effects.\n */\nclass EffectScheduler {\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: EffectScheduler,\n providedIn: 'root',\n factory: () => new ZoneAwareEffectScheduler()\n });\n}\n/**\n * A wrapper around `ZoneAwareQueueingScheduler` that schedules flushing via the microtask queue\n * when.\n */\nclass ZoneAwareEffectScheduler {\n queuedEffectCount = 0;\n queues = new Map();\n schedule(handle) {\n this.enqueue(handle);\n }\n remove(handle) {\n const zone = handle.zone;\n const queue = this.queues.get(zone);\n if (!queue.has(handle)) {\n return;\n }\n queue.delete(handle);\n this.queuedEffectCount--;\n }\n enqueue(handle) {\n const zone = handle.zone;\n if (!this.queues.has(zone)) {\n this.queues.set(zone, new Set());\n }\n const queue = this.queues.get(zone);\n if (queue.has(handle)) {\n return;\n }\n this.queuedEffectCount++;\n queue.add(handle);\n }\n /**\n * Run all scheduled effects.\n *\n * Execution order of effects within the same zone is guaranteed to be FIFO, but there is no\n * ordering guarantee between effects scheduled in different zones.\n */\n flush() {\n while (this.queuedEffectCount > 0) {\n for (const [zone, queue] of this.queues) {\n // `zone` here must be defined.\n if (zone === null) {\n this.flushQueue(queue);\n } else {\n zone.run(() => this.flushQueue(queue));\n }\n }\n }\n }\n flushQueue(queue) {\n for (const handle of queue) {\n queue.delete(handle);\n this.queuedEffectCount--;\n // TODO: what happens if this throws an error?\n handle.run();\n }\n }\n}\n\n/**\n * Determine if the argument is shaped like a Promise\n */\nfunction isPromise(obj) {\n // allow any Promise/A+ compliant thenable.\n // It's up to the caller to ensure that obj.then conforms to the spec\n return !!obj && typeof obj.then === 'function';\n}\n/**\n * Determine if the argument is a Subscribable\n */\nfunction isSubscribable(obj) {\n return !!obj && typeof obj.subscribe === 'function';\n}\n\n/**\n * A DI token that you can use to provide\n * one or more initialization functions.\n *\n * The provided functions are injected at application startup and executed during\n * app initialization. If any of these functions returns a Promise or an Observable, initialization\n * does not complete until the Promise is resolved or the Observable is completed.\n *\n * You can, for example, create a factory function that loads language data\n * or an external configuration, and provide that function to the `APP_INITIALIZER` token.\n * The function is executed during the application bootstrap process,\n * and the needed data is available on startup.\n *\n * Note that the provided initializer is run in the injection context.\n *\n * @deprecated from v19.0.0, use provideAppInitializer instead\n *\n * @see {@link ApplicationInitStatus}\n * @see {@link provideAppInitializer}\n *\n * @usageNotes\n *\n * The following example illustrates how to configure a multi-provider using `APP_INITIALIZER` token\n * and a function returning a promise.\n * ### Example with NgModule-based application\n * ```ts\n * function initializeApp(): Promise<any> {\n * const http = inject(HttpClient);\n * return firstValueFrom(\n * http\n * .get(\"https://someUrl.com/api/user\")\n * .pipe(tap(user => { ... }))\n * );\n * }\n *\n * @NgModule({\n * imports: [BrowserModule],\n * declarations: [AppComponent],\n * bootstrap: [AppComponent],\n * providers: [{\n * provide: APP_INITIALIZER,\n * useValue: initializeApp,\n * multi: true,\n * }]\n * })\n * export class AppModule {}\n * ```\n *\n * ### Example with standalone application\n * ```ts\n * function initializeApp() {\n * const http = inject(HttpClient);\n * return firstValueFrom(\n * http\n * .get(\"https://someUrl.com/api/user\")\n * .pipe(tap(user => { ... }))\n * );\n * }\n *\n * bootstrapApplication(App, {\n * providers: [\n * provideHttpClient(),\n * {\n * provide: APP_INITIALIZER,\n * useValue: initializeApp,\n * multi: true,\n * },\n * ],\n * });\n\n * ```\n *\n *\n * It's also possible to configure a multi-provider using `APP_INITIALIZER` token and a function\n * returning an observable, see an example below. Note: the `HttpClient` in this example is used for\n * demo purposes to illustrate how the factory function can work with other providers available\n * through DI.\n *\n * ### Example with NgModule-based application\n * ```ts\n * function initializeApp() {\n * const http = inject(HttpClient);\n * return firstValueFrom(\n * http\n * .get(\"https://someUrl.com/api/user\")\n * .pipe(tap(user => { ... }))\n * );\n * }\n *\n * @NgModule({\n * imports: [BrowserModule, HttpClientModule],\n * declarations: [AppComponent],\n * bootstrap: [AppComponent],\n * providers: [{\n * provide: APP_INITIALIZER,\n * useValue: initializeApp,\n * multi: true,\n * }]\n * })\n * export class AppModule {}\n * ```\n *\n * ### Example with standalone application\n * ```ts\n * function initializeApp() {\n * const http = inject(HttpClient);\n * return firstValueFrom(\n * http\n * .get(\"https://someUrl.com/api/user\")\n * .pipe(tap(user => { ... }))\n * );\n * }\n *\n * bootstrapApplication(App, {\n * providers: [\n * provideHttpClient(),\n * {\n * provide: APP_INITIALIZER,\n * useValue: initializeApp,\n * multi: true,\n * },\n * ],\n * });\n * ```\n *\n * @publicApi\n */\nconst APP_INITIALIZER = new InjectionToken(ngDevMode ? 'Application Initializer' : '');\n/**\n * @description\n * The provided function is injected at application startup and executed during\n * app initialization. If the function returns a Promise or an Observable, initialization\n * does not complete until the Promise is resolved or the Observable is completed.\n *\n * You can, for example, create a function that loads language data\n * or an external configuration, and provide that function using `provideAppInitializer()`.\n * The function is executed during the application bootstrap process,\n * and the needed data is available on startup.\n *\n * Note that the provided initializer is run in the injection context.\n *\n * Previously, this was achieved using the `APP_INITIALIZER` token which is now deprecated.\n *\n * @see {@link APP_INITIALIZER}\n *\n * @usageNotes\n * The following example illustrates how to configure an initialization function using\n * `provideAppInitializer()`\n * ```ts\n * bootstrapApplication(App, {\n * providers: [\n * provideAppInitializer(() => {\n * const http = inject(HttpClient);\n * return firstValueFrom(\n * http\n * .get(\"https://someUrl.com/api/user\")\n * .pipe(tap(user => { ... }))\n * );\n * }),\n * provideHttpClient(),\n * ],\n * });\n * ```\n *\n * @publicApi\n */\nfunction provideAppInitializer(initializerFn) {\n return makeEnvironmentProviders([{\n provide: APP_INITIALIZER,\n multi: true,\n useValue: initializerFn\n }]);\n}\n/**\n * A class that reflects the state of running {@link APP_INITIALIZER} functions.\n *\n * @publicApi\n */\nclass ApplicationInitStatus {\n // Using non null assertion, these fields are defined below\n // within the `new Promise` callback (synchronously).\n resolve;\n reject;\n initialized = false;\n done = false;\n donePromise = new Promise((res, rej) => {\n this.resolve = res;\n this.reject = rej;\n });\n appInits = inject(APP_INITIALIZER, {\n optional: true\n }) ?? [];\n injector = inject(Injector);\n constructor() {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !Array.isArray(this.appInits)) {\n throw new RuntimeError(-209 /* RuntimeErrorCode.INVALID_MULTI_PROVIDER */, 'Unexpected type of the `APP_INITIALIZER` token value ' + `(expected an array, but got ${typeof this.appInits}). ` + 'Please check that the `APP_INITIALIZER` token is configured as a ' + '`multi: true` provider.');\n }\n }\n /** @internal */\n runInitializers() {\n if (this.initialized) {\n return;\n }\n const asyncInitPromises = [];\n for (const appInits of this.appInits) {\n const initResult = runInInjectionContext(this.injector, appInits);\n if (isPromise(initResult)) {\n asyncInitPromises.push(initResult);\n } else if (isSubscribable(initResult)) {\n const observableAsPromise = new Promise((resolve, reject) => {\n initResult.subscribe({\n complete: resolve,\n error: reject\n });\n });\n asyncInitPromises.push(observableAsPromise);\n }\n }\n const complete = () => {\n // @ts-expect-error overwriting a readonly\n this.done = true;\n this.resolve();\n };\n Promise.all(asyncInitPromises).then(() => {\n complete();\n }).catch(e => {\n this.reject(e);\n });\n if (asyncInitPromises.length === 0) {\n complete();\n }\n this.initialized = true;\n }\n static ɵfac = function ApplicationInitStatus_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ApplicationInitStatus)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: ApplicationInitStatus,\n factory: ApplicationInitStatus.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(ApplicationInitStatus, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [], null);\n})();\n\n/**\n * A DI token that provides a set of callbacks to\n * be called for every component that is bootstrapped.\n *\n * Each callback must take a `ComponentRef` instance and return nothing.\n *\n * `(componentRef: ComponentRef) => void`\n *\n * @publicApi\n */\nconst APP_BOOTSTRAP_LISTENER = new InjectionToken(ngDevMode ? 'appBootstrapListener' : '');\nfunction publishDefaultGlobalUtils() {\n ngDevMode && publishDefaultGlobalUtils$1();\n}\n/**\n * Sets the error for an invalid write to a signal to be an Angular `RuntimeError`.\n */\nfunction publishSignalConfiguration() {\n setThrowInvalidWriteToSignalError$1(() => {\n throw new RuntimeError(600 /* RuntimeErrorCode.SIGNAL_WRITE_FROM_ILLEGAL_CONTEXT */, ngDevMode && 'Writing to signals is not allowed in a `computed`.');\n });\n}\nfunction isBoundToModule(cf) {\n return cf.isBoundToModule;\n}\n/**\n * A token for third-party components that can register themselves with NgProbe.\n *\n * @deprecated\n * @publicApi\n */\nclass NgProbeToken {\n name;\n token;\n constructor(name, token) {\n this.name = name;\n this.token = token;\n }\n}\n/** Maximum number of times ApplicationRef will refresh all attached views in a single tick. */\nconst MAXIMUM_REFRESH_RERUNS = 10;\nfunction optionsReducer(dst, objs) {\n if (Array.isArray(objs)) {\n return objs.reduce(optionsReducer, dst);\n }\n return {\n ...dst,\n ...objs\n };\n}\n/**\n * A reference to an Angular application running on a page.\n *\n * @usageNotes\n * ### isStable examples and caveats\n *\n * Note two important points about `isStable`, demonstrated in the examples below:\n * - the application will never be stable if you start any kind\n * of recurrent asynchronous task when the application starts\n * (for example for a polling process, started with a `setInterval`, a `setTimeout`\n * or using RxJS operators like `interval`);\n * - the `isStable` Observable runs outside of the Angular zone.\n *\n * Let's imagine that you start a recurrent task\n * (here incrementing a counter, using RxJS `interval`),\n * and at the same time subscribe to `isStable`.\n *\n * ```ts\n * constructor(appRef: ApplicationRef) {\n * appRef.isStable.pipe(\n * filter(stable => stable)\n * ).subscribe(() => console.log('App is stable now');\n * interval(1000).subscribe(counter => console.log(counter));\n * }\n * ```\n * In this example, `isStable` will never emit `true`,\n * and the trace \"App is stable now\" will never get logged.\n *\n * If you want to execute something when the app is stable,\n * you have to wait for the application to be stable\n * before starting your polling process.\n *\n * ```ts\n * constructor(appRef: ApplicationRef) {\n * appRef.isStable.pipe(\n * first(stable => stable),\n * tap(stable => console.log('App is stable now')),\n * switchMap(() => interval(1000))\n * ).subscribe(counter => console.log(counter));\n * }\n * ```\n * In this example, the trace \"App is stable now\" will be logged\n * and then the counter starts incrementing every second.\n *\n * Note also that this Observable runs outside of the Angular zone,\n * which means that the code in the subscription\n * to this Observable will not trigger the change detection.\n *\n * Let's imagine that instead of logging the counter value,\n * you update a field of your component\n * and display it in its template.\n *\n * ```ts\n * constructor(appRef: ApplicationRef) {\n * appRef.isStable.pipe(\n * first(stable => stable),\n * switchMap(() => interval(1000))\n * ).subscribe(counter => this.value = counter);\n * }\n * ```\n * As the `isStable` Observable runs outside the zone,\n * the `value` field will be updated properly,\n * but the template will not be refreshed!\n *\n * You'll have to manually trigger the change detection to update the template.\n *\n * ```ts\n * constructor(appRef: ApplicationRef, cd: ChangeDetectorRef) {\n * appRef.isStable.pipe(\n * first(stable => stable),\n * switchMap(() => interval(1000))\n * ).subscribe(counter => {\n * this.value = counter;\n * cd.detectChanges();\n * });\n * }\n * ```\n *\n * Or make the subscription callback run inside the zone.\n *\n * ```ts\n * constructor(appRef: ApplicationRef, zone: NgZone) {\n * appRef.isStable.pipe(\n * first(stable => stable),\n * switchMap(() => interval(1000))\n * ).subscribe(counter => zone.run(() => this.value = counter));\n * }\n * ```\n *\n * @publicApi\n */\nclass ApplicationRef {\n /** @internal */\n _runningTick = false;\n _destroyed = false;\n _destroyListeners = [];\n /** @internal */\n _views = [];\n internalErrorHandler = inject(INTERNAL_APPLICATION_ERROR_HANDLER);\n afterRenderManager = inject(AfterRenderManager);\n zonelessEnabled = inject(ZONELESS_ENABLED);\n rootEffectScheduler = inject(EffectScheduler);\n /**\n * Current dirty state of the application across a number of dimensions (views, afterRender hooks,\n * etc).\n *\n * A flag set here means that `tick()` will attempt to resolve the dirtiness when executed.\n *\n * @internal\n */\n dirtyFlags = 0 /* ApplicationRefDirtyFlags.None */;\n /**\n * Most recent snapshot from the `TracingService`, if any.\n *\n * This snapshot attempts to capture the context when `tick()` was first\n * scheduled. It then runs wrapped in this context.\n *\n * @internal\n */\n tracingSnapshot = null;\n // Needed for ComponentFixture temporarily during migration of autoDetect behavior\n // Eventually the hostView of the fixture should just attach to ApplicationRef.\n externalTestViews = new Set();\n /** @internal */\n afterTick = new Subject();\n /** @internal */\n get allViews() {\n return [...this.externalTestViews.keys(), ...this._views];\n }\n /**\n * Indicates whether this instance was destroyed.\n */\n get destroyed() {\n return this._destroyed;\n }\n /**\n * Get a list of component types registered to this application.\n * This list is populated even before the component is created.\n */\n componentTypes = [];\n /**\n * Get a list of components registered to this application.\n */\n components = [];\n /**\n * Returns an Observable that indicates when the application is stable or unstable.\n */\n isStable = inject(PendingTasksInternal).hasPendingTasks.pipe(map(pending => !pending));\n constructor() {\n // Inject the tracing service to initialize it.\n inject(TracingService, {\n optional: true\n });\n }\n /**\n * @returns A promise that resolves when the application becomes stable\n */\n whenStable() {\n let subscription;\n return new Promise(resolve => {\n subscription = this.isStable.subscribe({\n next: stable => {\n if (stable) {\n resolve();\n }\n }\n });\n }).finally(() => {\n subscription.unsubscribe();\n });\n }\n _injector = inject(EnvironmentInjector);\n _rendererFactory = null;\n /**\n * The `EnvironmentInjector` used to create this application.\n */\n get injector() {\n return this._injector;\n }\n /**\n * Bootstrap a component onto the element identified by its selector or, optionally, to a\n * specified element.\n *\n * @usageNotes\n * ### Bootstrap process\n *\n * When bootstrapping a component, Angular mounts it onto a target DOM element\n * and kicks off automatic change detection. The target DOM element can be\n * provided using the `rootSelectorOrNode` argument.\n *\n * If the target DOM element is not provided, Angular tries to find one on a page\n * using the `selector` of the component that is being bootstrapped\n * (first matched element is used).\n *\n * ### Example\n *\n * Generally, we define the component to bootstrap in the `bootstrap` array of `NgModule`,\n * but it requires us to know the component while writing the application code.\n *\n * Imagine a situation where we have to wait for an API call to decide about the component to\n * bootstrap. We can use the `ngDoBootstrap` hook of the `NgModule` and call this method to\n * dynamically bootstrap a component.\n *\n * {@example core/ts/platform/platform.ts region='componentSelector'}\n *\n * Optionally, a component can be mounted onto a DOM element that does not match the\n * selector of the bootstrapped component.\n *\n * In the following example, we are providing a CSS selector to match the target element.\n *\n * {@example core/ts/platform/platform.ts region='cssSelector'}\n *\n * While in this example, we are providing reference to a DOM node.\n *\n * {@example core/ts/platform/platform.ts region='domNode'}\n */\n bootstrap(componentOrFactory, rootSelectorOrNode) {\n profiler(10 /* ProfilerEvent.BootstrapComponentStart */);\n (typeof ngDevMode === 'undefined' || ngDevMode) && warnIfDestroyed(this._destroyed);\n const isComponentFactory = componentOrFactory instanceof ComponentFactory$1;\n const initStatus = this._injector.get(ApplicationInitStatus);\n if (!initStatus.done) {\n const standalone = !isComponentFactory && isStandalone(componentOrFactory);\n const errorMessage = (typeof ngDevMode === 'undefined' || ngDevMode) && 'Cannot bootstrap as there are still asynchronous initializers running.' + (standalone ? '' : ' Bootstrap components in the `ngDoBootstrap` method of the root module.');\n throw new RuntimeError(405 /* RuntimeErrorCode.ASYNC_INITIALIZERS_STILL_RUNNING */, errorMessage);\n }\n let componentFactory;\n if (isComponentFactory) {\n componentFactory = componentOrFactory;\n } else {\n const resolver = this._injector.get(ComponentFactoryResolver$1);\n componentFactory = resolver.resolveComponentFactory(componentOrFactory);\n }\n this.componentTypes.push(componentFactory.componentType);\n // Create a factory associated with the current module if it's not bound to some other\n const ngModule = isBoundToModule(componentFactory) ? undefined : this._injector.get(NgModuleRef$1);\n const selectorOrNode = rootSelectorOrNode || componentFactory.selector;\n const compRef = componentFactory.create(Injector.NULL, [], selectorOrNode, ngModule);\n const nativeElement = compRef.location.nativeElement;\n const testability = compRef.injector.get(TESTABILITY, null);\n testability?.registerApplication(nativeElement);\n compRef.onDestroy(() => {\n this.detachView(compRef.hostView);\n remove(this.components, compRef);\n testability?.unregisterApplication(nativeElement);\n });\n this._loadComponent(compRef);\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const _console = this._injector.get(Console);\n _console.log(`Angular is running in development mode.`);\n }\n profiler(11 /* ProfilerEvent.BootstrapComponentEnd */, compRef);\n return compRef;\n }\n /**\n * Invoke this method to explicitly process change detection and its side-effects.\n *\n * In development mode, `tick()` also performs a second change detection cycle to ensure that no\n * further changes are detected. If additional changes are picked up during this second cycle,\n * bindings in the app have side-effects that cannot be resolved in a single change detection\n * pass.\n * In this case, Angular throws an error, since an Angular application can only have one change\n * detection pass during which all change detection must complete.\n */\n tick() {\n if (!this.zonelessEnabled) {\n this.dirtyFlags |= 1 /* ApplicationRefDirtyFlags.ViewTreeGlobal */;\n }\n this._tick();\n }\n /** @internal */\n _tick() {\n profiler(12 /* ProfilerEvent.ChangeDetectionStart */);\n if (this.tracingSnapshot !== null) {\n // Ensure we always run `tickImpl()` in the context of the most recent snapshot,\n // if one exists. Snapshots may be reference counted by the implementation so\n // we want to ensure that if we request a snapshot that we use it.\n this.tracingSnapshot.run(TracingAction.CHANGE_DETECTION, this.tickImpl);\n } else {\n this.tickImpl();\n }\n }\n tickImpl = () => {\n (typeof ngDevMode === 'undefined' || ngDevMode) && warnIfDestroyed(this._destroyed);\n if (this._runningTick) {\n throw new RuntimeError(101 /* RuntimeErrorCode.RECURSIVE_APPLICATION_REF_TICK */, ngDevMode && 'ApplicationRef.tick is called recursively');\n }\n const prevConsumer = setActiveConsumer$1(null);\n try {\n this._runningTick = true;\n this.synchronize();\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n for (let view of this.allViews) {\n view.checkNoChanges();\n }\n }\n } catch (e) {\n // Attention: Don't rethrow as it could cancel subscriptions to Observables!\n this.internalErrorHandler(e);\n } finally {\n this._runningTick = false;\n this.tracingSnapshot?.dispose();\n this.tracingSnapshot = null;\n setActiveConsumer$1(prevConsumer);\n this.afterTick.next();\n profiler(13 /* ProfilerEvent.ChangeDetectionEnd */);\n }\n };\n /**\n * Performs the core work of synchronizing the application state with the UI, resolving any\n * pending dirtiness (potentially in a loop).\n */\n synchronize() {\n if (this._rendererFactory === null && !this._injector.destroyed) {\n this._rendererFactory = this._injector.get(RendererFactory2, null, {\n optional: true\n });\n }\n let runs = 0;\n while (this.dirtyFlags !== 0 /* ApplicationRefDirtyFlags.None */ && runs++ < MAXIMUM_REFRESH_RERUNS) {\n profiler(14 /* ProfilerEvent.ChangeDetectionSyncStart */);\n this.synchronizeOnce();\n profiler(15 /* ProfilerEvent.ChangeDetectionSyncEnd */);\n }\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && runs >= MAXIMUM_REFRESH_RERUNS) {\n throw new RuntimeError(103 /* RuntimeErrorCode.INFINITE_CHANGE_DETECTION */, ngDevMode && 'Infinite change detection while refreshing application views. ' + 'Ensure views are not calling `markForCheck` on every template execution or ' + 'that afterRender hooks always mark views for check.');\n }\n }\n /**\n * Perform a single synchronization pass.\n */\n synchronizeOnce() {\n // First, process any dirty root effects.\n if (this.dirtyFlags & 16 /* ApplicationRefDirtyFlags.RootEffects */) {\n this.dirtyFlags &= ~16 /* ApplicationRefDirtyFlags.RootEffects */;\n this.rootEffectScheduler.flush();\n }\n // First check dirty views, if there are any.\n if (this.dirtyFlags & 7 /* ApplicationRefDirtyFlags.ViewTreeAny */) {\n // Change detection on views starts in targeted mode (only check components if they're\n // marked as dirty) unless global checking is specifically requested via APIs like\n // `ApplicationRef.tick()` and the `NgZone` integration.\n const useGlobalCheck = Boolean(this.dirtyFlags & 1 /* ApplicationRefDirtyFlags.ViewTreeGlobal */);\n // Clear the view-related dirty flags.\n this.dirtyFlags &= ~7 /* ApplicationRefDirtyFlags.ViewTreeAny */;\n // Set the AfterRender bit, as we're checking views and will need to run afterRender hooks.\n this.dirtyFlags |= 8 /* ApplicationRefDirtyFlags.AfterRender */;\n // Check all potentially dirty views.\n for (let {\n _lView,\n notifyErrorHandler\n } of this.allViews) {\n detectChangesInViewIfRequired(_lView, notifyErrorHandler, useGlobalCheck, this.zonelessEnabled);\n }\n // If `markForCheck()` was called during view checking, it will have set the `ViewTreeCheck`\n // flag. We clear the flag here because, for backwards compatibility, `markForCheck()`\n // during view checking doesn't cause the view to be re-checked.\n this.dirtyFlags &= ~4 /* ApplicationRefDirtyFlags.ViewTreeCheck */;\n // Check if any views are still dirty after checking and we need to loop back.\n this.syncDirtyFlagsWithViews();\n if (this.dirtyFlags & (7 /* ApplicationRefDirtyFlags.ViewTreeAny */ | 16 /* ApplicationRefDirtyFlags.RootEffects */)) {\n // If any views or effects are still dirty after checking, loop back before running render\n // hooks.\n return;\n }\n } else {\n // If we skipped refreshing views above, there might still be unflushed animations\n // because we never called `detectChangesInternal` on the views.\n this._rendererFactory?.begin?.();\n this._rendererFactory?.end?.();\n }\n // Even if there were no dirty views, afterRender hooks might still be dirty.\n if (this.dirtyFlags & 8 /* ApplicationRefDirtyFlags.AfterRender */) {\n this.dirtyFlags &= ~8 /* ApplicationRefDirtyFlags.AfterRender */;\n this.afterRenderManager.execute();\n // afterRender hooks might influence dirty flags.\n }\n this.syncDirtyFlagsWithViews();\n }\n /**\n * Checks `allViews` for views which require refresh/traversal, and updates `dirtyFlags`\n * accordingly, with two potential behaviors:\n *\n * 1. If any of our views require updating, then this adds the `ViewTreeTraversal` dirty flag.\n * This _should_ be a no-op, since the scheduler should've added the flag at the same time the\n * view was marked as needing updating.\n *\n * TODO(alxhub): figure out if this behavior is still needed for edge cases.\n *\n * 2. If none of our views require updating, then clear the view-related `dirtyFlag`s. This\n * happens when the scheduler is notified of a view becoming dirty, but the view itself isn't\n * reachable through traversal from our roots (e.g. it's detached from the CD tree).\n */\n syncDirtyFlagsWithViews() {\n if (this.allViews.some(({\n _lView\n }) => requiresRefreshOrTraversal(_lView))) {\n // If after running all afterRender callbacks new views are dirty, ensure we loop back.\n this.dirtyFlags |= 2 /* ApplicationRefDirtyFlags.ViewTreeTraversal */;\n return;\n } else {\n // Even though this flag may be set, none of _our_ views require traversal, and so the\n // `ApplicationRef` doesn't require any repeated checking.\n this.dirtyFlags &= ~7 /* ApplicationRefDirtyFlags.ViewTreeAny */;\n }\n }\n /**\n * Attaches a view so that it will be dirty checked.\n * The view will be automatically detached when it is destroyed.\n * This will throw if the view is already attached to a ViewContainer.\n */\n attachView(viewRef) {\n (typeof ngDevMode === 'undefined' || ngDevMode) && warnIfDestroyed(this._destroyed);\n const view = viewRef;\n this._views.push(view);\n view.attachToAppRef(this);\n }\n /**\n * Detaches a view from dirty checking again.\n */\n detachView(viewRef) {\n (typeof ngDevMode === 'undefined' || ngDevMode) && warnIfDestroyed(this._destroyed);\n const view = viewRef;\n remove(this._views, view);\n view.detachFromAppRef();\n }\n _loadComponent(componentRef) {\n this.attachView(componentRef.hostView);\n this.tick();\n this.components.push(componentRef);\n // Get the listeners lazily to prevent DI cycles.\n const listeners = this._injector.get(APP_BOOTSTRAP_LISTENER, []);\n if (ngDevMode && !Array.isArray(listeners)) {\n throw new RuntimeError(-209 /* RuntimeErrorCode.INVALID_MULTI_PROVIDER */, 'Unexpected type of the `APP_BOOTSTRAP_LISTENER` token value ' + `(expected an array, but got ${typeof listeners}). ` + 'Please check that the `APP_BOOTSTRAP_LISTENER` token is configured as a ' + '`multi: true` provider.');\n }\n listeners.forEach(listener => listener(componentRef));\n }\n /** @internal */\n ngOnDestroy() {\n if (this._destroyed) return;\n try {\n // Call all the lifecycle hooks.\n this._destroyListeners.forEach(listener => listener());\n // Destroy all registered views.\n this._views.slice().forEach(view => view.destroy());\n } finally {\n // Indicate that this instance is destroyed.\n this._destroyed = true;\n // Release all references.\n this._views = [];\n this._destroyListeners = [];\n }\n }\n /**\n * Registers a listener to be called when an instance is destroyed.\n *\n * @param callback A callback function to add as a listener.\n * @returns A function which unregisters a listener.\n */\n onDestroy(callback) {\n (typeof ngDevMode === 'undefined' || ngDevMode) && warnIfDestroyed(this._destroyed);\n this._destroyListeners.push(callback);\n return () => remove(this._destroyListeners, callback);\n }\n /**\n * Destroys an Angular application represented by this `ApplicationRef`. Calling this function\n * will destroy the associated environment injectors as well as all the bootstrapped components\n * with their views.\n */\n destroy() {\n if (this._destroyed) {\n throw new RuntimeError(406 /* RuntimeErrorCode.APPLICATION_REF_ALREADY_DESTROYED */, ngDevMode && 'This instance of the `ApplicationRef` has already been destroyed.');\n }\n const injector = this._injector;\n // Check that this injector instance supports destroy operation.\n if (injector.destroy && !injector.destroyed) {\n // Destroying an underlying injector will trigger the `ngOnDestroy` lifecycle\n // hook, which invokes the remaining cleanup actions.\n injector.destroy();\n }\n }\n /**\n * Returns the number of attached views.\n */\n get viewCount() {\n return this._views.length;\n }\n static ɵfac = function ApplicationRef_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ApplicationRef)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: ApplicationRef,\n factory: ApplicationRef.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(ApplicationRef, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [], null);\n})();\nfunction warnIfDestroyed(destroyed) {\n if (destroyed) {\n console.warn(formatRuntimeError(406 /* RuntimeErrorCode.APPLICATION_REF_ALREADY_DESTROYED */, 'This instance of the `ApplicationRef` has already been destroyed.'));\n }\n}\nfunction remove(list, el) {\n const index = list.indexOf(el);\n if (index > -1) {\n list.splice(index, 1);\n }\n}\nfunction detectChangesInViewIfRequired(lView, notifyErrorHandler, isFirstPass, zonelessEnabled) {\n // When re-checking, only check views which actually need it.\n if (!isFirstPass && !requiresRefreshOrTraversal(lView)) {\n return;\n }\n const mode = isFirstPass && !zonelessEnabled ?\n // The first pass is always in Global mode, which includes `CheckAlways` views.\n 0 /* ChangeDetectionMode.Global */ :\n // Only refresh views with the `RefreshView` flag or views is a changed signal\n 1 /* ChangeDetectionMode.Targeted */;\n detectChangesInternal(lView, notifyErrorHandler, mode);\n}\n\n/**\n * Schedules triggering of a defer block for `on idle` and `on timer` conditions.\n */\nfunction scheduleDelayedTrigger(scheduleFn) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n renderPlaceholder(lView, tNode);\n // Exit early to avoid invoking `scheduleFn`, which would\n // add `setTimeout` call and potentially delay serialization\n // on the server unnecessarily.\n if (!shouldTriggerDeferBlock(0 /* TriggerType.Regular */, lView)) return;\n const injector = lView[INJECTOR];\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const cleanupFn = scheduleFn(() => triggerDeferBlock(0 /* TriggerType.Regular */, lView, tNode), injector);\n storeTriggerCleanupFn(0 /* TriggerType.Regular */, lDetails, cleanupFn);\n}\n/**\n * Schedules prefetching for `on idle` and `on timer` triggers.\n *\n * @param scheduleFn A function that does the scheduling.\n */\nfunction scheduleDelayedPrefetching(scheduleFn, trigger) {\n if (typeof ngServerMode !== 'undefined' && ngServerMode) return;\n const lView = getLView();\n const injector = lView[INJECTOR];\n // Only trigger the scheduled trigger on the browser\n // since we don't want to delay the server response.\n const tNode = getCurrentTNode();\n const tView = lView[TVIEW];\n const tDetails = getTDeferBlockDetails(tView, tNode);\n if (tDetails.loadingState === DeferDependenciesLoadingState.NOT_STARTED) {\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const prefetch = () => triggerPrefetching(tDetails, lView, tNode);\n const cleanupFn = scheduleFn(prefetch, injector);\n storeTriggerCleanupFn(1 /* TriggerType.Prefetch */, lDetails, cleanupFn);\n }\n}\n/**\n * Schedules hydration triggering of a defer block for `on idle` and `on timer` conditions.\n */\nfunction scheduleDelayedHydrating(scheduleFn, lView, tNode) {\n if (typeof ngServerMode !== 'undefined' && ngServerMode) return;\n // Only trigger the scheduled trigger on the browser\n // since we don't want to delay the server response.\n const injector = lView[INJECTOR];\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const ssrUniqueId = lDetails[SSR_UNIQUE_ID];\n ngDevMode && assertSsrIdDefined(ssrUniqueId);\n const cleanupFn = scheduleFn(() => triggerHydrationFromBlockName(injector, ssrUniqueId), injector);\n storeTriggerCleanupFn(2 /* TriggerType.Hydrate */, lDetails, cleanupFn);\n}\n/**\n * Trigger prefetching of dependencies for a defer block.\n *\n * @param tDetails Static information about this defer block.\n * @param lView LView of a host view.\n * @param tNode TNode that represents a defer block.\n */\nfunction triggerPrefetching(tDetails, lView, tNode) {\n triggerResourceLoading(tDetails, lView, tNode);\n}\n/**\n * Trigger loading of defer block dependencies if the process hasn't started yet.\n *\n * @param tDetails Static information about this defer block.\n * @param lView LView of a host view.\n */\nfunction triggerResourceLoading(tDetails, lView, tNode) {\n const injector = lView[INJECTOR];\n const tView = lView[TVIEW];\n if (tDetails.loadingState !== DeferDependenciesLoadingState.NOT_STARTED) {\n // If the loading status is different from initial one, it means that\n // the loading of dependencies is in progress and there is nothing to do\n // in this function. All details can be obtained from the `tDetails` object.\n return tDetails.loadingPromise ?? Promise.resolve();\n }\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const primaryBlockTNode = getPrimaryBlockTNode(tView, tDetails);\n // Switch from NOT_STARTED -> IN_PROGRESS state.\n tDetails.loadingState = DeferDependenciesLoadingState.IN_PROGRESS;\n // Prefetching is triggered, cleanup all registered prefetch triggers.\n invokeTriggerCleanupFns(1 /* TriggerType.Prefetch */, lDetails);\n let dependenciesFn = tDetails.dependencyResolverFn;\n if (ngDevMode) {\n // Check if dependency function interceptor is configured.\n const deferDependencyInterceptor = injector.get(DEFER_BLOCK_DEPENDENCY_INTERCEPTOR, null, {\n optional: true\n });\n if (deferDependencyInterceptor) {\n dependenciesFn = deferDependencyInterceptor.intercept(dependenciesFn);\n }\n }\n // Indicate that an application is not stable and has a pending task.\n const pendingTasks = injector.get(PendingTasksInternal);\n const taskId = pendingTasks.add();\n // The `dependenciesFn` might be `null` when all dependencies within\n // a given defer block were eagerly referenced elsewhere in a file,\n // thus no dynamic `import()`s were produced.\n if (!dependenciesFn) {\n tDetails.loadingPromise = Promise.resolve().then(() => {\n tDetails.loadingPromise = null;\n tDetails.loadingState = DeferDependenciesLoadingState.COMPLETE;\n pendingTasks.remove(taskId);\n });\n return tDetails.loadingPromise;\n }\n // Start downloading of defer block dependencies.\n tDetails.loadingPromise = Promise.allSettled(dependenciesFn()).then(results => {\n let failed = false;\n const directiveDefs = [];\n const pipeDefs = [];\n for (const result of results) {\n if (result.status === 'fulfilled') {\n const dependency = result.value;\n const directiveDef = getComponentDef(dependency) || getDirectiveDef(dependency);\n if (directiveDef) {\n directiveDefs.push(directiveDef);\n } else {\n const pipeDef = getPipeDef$1(dependency);\n if (pipeDef) {\n pipeDefs.push(pipeDef);\n }\n }\n } else {\n failed = true;\n break;\n }\n }\n // Loading is completed, we no longer need the loading Promise\n // and a pending task should also be removed.\n tDetails.loadingPromise = null;\n pendingTasks.remove(taskId);\n if (failed) {\n tDetails.loadingState = DeferDependenciesLoadingState.FAILED;\n if (tDetails.errorTmplIndex === null) {\n const templateLocation = ngDevMode ? getTemplateLocationDetails(lView) : '';\n const error = new RuntimeError(-750 /* RuntimeErrorCode.DEFER_LOADING_FAILED */, ngDevMode && 'Loading dependencies for `@defer` block failed, ' + `but no \\`@error\\` block was configured${templateLocation}. ` + 'Consider using the `@error` block to render an error state.');\n handleError(lView, error);\n }\n } else {\n tDetails.loadingState = DeferDependenciesLoadingState.COMPLETE;\n // Update directive and pipe registries to add newly downloaded dependencies.\n const primaryBlockTView = primaryBlockTNode.tView;\n if (directiveDefs.length > 0) {\n primaryBlockTView.directiveRegistry = addDepsToRegistry(primaryBlockTView.directiveRegistry, directiveDefs);\n // Extract providers from all NgModules imported by standalone components\n // used within this defer block.\n const directiveTypes = directiveDefs.map(def => def.type);\n const providers = internalImportProvidersFrom(false, ...directiveTypes);\n tDetails.providers = providers;\n }\n if (pipeDefs.length > 0) {\n primaryBlockTView.pipeRegistry = addDepsToRegistry(primaryBlockTView.pipeRegistry, pipeDefs);\n }\n }\n });\n return tDetails.loadingPromise;\n}\n/**\n * Defines whether we should proceed with triggering a given defer block.\n */\nfunction shouldTriggerDeferBlock(triggerType, lView) {\n // prevents triggering regular triggers when on the server.\n if (triggerType === 0 /* TriggerType.Regular */ && typeof ngServerMode !== 'undefined' && ngServerMode) {\n return false;\n }\n // prevents triggering in the case of a test run with manual defer block configuration.\n const injector = lView[INJECTOR];\n const config = injector.get(DEFER_BLOCK_CONFIG, null, {\n optional: true\n });\n if (config?.behavior === DeferBlockBehavior.Manual) {\n return false;\n }\n return true;\n}\n/**\n * Attempts to trigger loading of defer block dependencies.\n * If the block is already in a loading, completed or an error state -\n * no additional actions are taken.\n */\nfunction triggerDeferBlock(triggerType, lView, tNode) {\n const tView = lView[TVIEW];\n const lContainer = lView[tNode.index];\n ngDevMode && assertLContainer(lContainer);\n if (!shouldTriggerDeferBlock(triggerType, lView)) return;\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const tDetails = getTDeferBlockDetails(tView, tNode);\n // Defer block is triggered, cleanup all registered trigger functions.\n invokeAllTriggerCleanupFns(lDetails);\n switch (tDetails.loadingState) {\n case DeferDependenciesLoadingState.NOT_STARTED:\n renderDeferBlockState(DeferBlockState.Loading, tNode, lContainer);\n triggerResourceLoading(tDetails, lView, tNode);\n // The `loadingState` might have changed to \"loading\".\n if (tDetails.loadingState === DeferDependenciesLoadingState.IN_PROGRESS) {\n renderDeferStateAfterResourceLoading(tDetails, tNode, lContainer);\n }\n break;\n case DeferDependenciesLoadingState.IN_PROGRESS:\n renderDeferBlockState(DeferBlockState.Loading, tNode, lContainer);\n renderDeferStateAfterResourceLoading(tDetails, tNode, lContainer);\n break;\n case DeferDependenciesLoadingState.COMPLETE:\n ngDevMode && assertDeferredDependenciesLoaded(tDetails);\n renderDeferBlockState(DeferBlockState.Complete, tNode, lContainer);\n break;\n case DeferDependenciesLoadingState.FAILED:\n renderDeferBlockState(DeferBlockState.Error, tNode, lContainer);\n break;\n default:\n if (ngDevMode) {\n throwError('Unknown defer block state');\n }\n }\n}\n/**\n * The core mechanism for incremental hydration. This triggers\n * hydration for all the blocks in the tree that need to be hydrated\n * and keeps track of all those blocks that were hydrated along the way.\n *\n * Note: the `replayQueuedEventsFn` is only provided when hydration is invoked\n * as a result of an event replay (via JsAction). When hydration is invoked from\n * an instruction set (e.g. `deferOnImmediate`) - there is no need to replay any\n * events.\n */\nasync function triggerHydrationFromBlockName(injector, blockName, replayQueuedEventsFn) {\n const dehydratedBlockRegistry = injector.get(DEHYDRATED_BLOCK_REGISTRY);\n const blocksBeingHydrated = dehydratedBlockRegistry.hydrating;\n // Make sure we don't hydrate/trigger the same thing multiple times\n if (blocksBeingHydrated.has(blockName)) {\n return;\n }\n // The parent promise is the possible case of a list of defer blocks already being queued\n // If it is queued, it'll exist; otherwise it'll be null. The hydration queue will contain all\n // elements that need to be hydrated, sans any that have promises already\n const {\n parentBlockPromise,\n hydrationQueue\n } = getParentBlockHydrationQueue(blockName, injector);\n // The hydrating map in the registry prevents re-triggering hydration for a block that's already in\n // the hydration queue. Here we generate promises for each of the blocks about to be hydrated\n populateHydratingStateForQueue(dehydratedBlockRegistry, hydrationQueue);\n // Trigger resource loading and hydration for the blocks in the queue in the order of highest block\n // to lowest block. Once a block has finished resource loading, after next render fires after hydration\n // finishes. The new block will have its defer instruction called and will be in the registry.\n // Due to timing related to potential nested control flow, this has to be scheduled after the next render.\n // Indicate that we have some pending async work.\n const pendingTasks = injector.get(PendingTasksInternal);\n const taskId = pendingTasks.add();\n // If the parent block was being hydrated, but the process has\n // not yet complete, wait until parent block promise settles before\n // going over dehydrated blocks from the queue.\n if (parentBlockPromise !== null) {\n await parentBlockPromise;\n }\n // Actually do the triggering and hydration of the queue of blocks\n for (let blockQueueIdx = 0; blockQueueIdx < hydrationQueue.length; blockQueueIdx++) {\n const dehydratedBlockId = hydrationQueue[blockQueueIdx];\n const dehydratedDeferBlock = dehydratedBlockRegistry.get(dehydratedBlockId);\n if (dehydratedDeferBlock != null) {\n // trigger the block resources and await next render for hydration. This should result\n // in the next block ɵɵdefer instruction being called and that block being added to the dehydrated registry.\n await triggerResourceLoadingForHydration(dehydratedDeferBlock);\n await nextRender(injector);\n // if the content has changed since server rendering, we need to check for the expected block\n // being in the registry or if errors occurred. In that case, we need to clean up the remaining expected\n // content that won't be rendered or fetched.\n if (deferBlockHasErrored(dehydratedDeferBlock)) {\n // Either the expected block has not yet had its ɵɵdefer instruction called or the block errored out when fetching\n // resources. In the former case, either we're hydrating too soon or the client and server differ. In both cases,\n // we need to clean up child content and promises.\n removeDehydratedViewList(dehydratedDeferBlock);\n cleanupRemainingHydrationQueue(hydrationQueue.slice(blockQueueIdx), dehydratedBlockRegistry);\n break;\n }\n // The defer block has not errored and we've finished fetching resources and rendering.\n // At this point it is safe to resolve the hydration promise.\n blocksBeingHydrated.get(dehydratedBlockId).resolve();\n } else {\n // The expected block has not yet had its ɵɵdefer instruction called. This is likely due to content changing between\n // client and server. We need to clean up the dehydrated DOM in the container since it no longer is valid.\n cleanupParentContainer(blockQueueIdx, hydrationQueue, dehydratedBlockRegistry);\n cleanupRemainingHydrationQueue(hydrationQueue.slice(blockQueueIdx), dehydratedBlockRegistry);\n break;\n }\n }\n // Await hydration completion for the requested block.\n await blocksBeingHydrated.get(blockName)?.promise;\n // All async work is done, remove the taskId from the registry.\n pendingTasks.remove(taskId);\n // Replay any queued events, if any exist and the replay operation was requested.\n if (replayQueuedEventsFn) {\n replayQueuedEventsFn(hydrationQueue);\n }\n // Cleanup after hydration of all affected defer blocks.\n cleanupHydratedDeferBlocks(dehydratedBlockRegistry.get(blockName), hydrationQueue, dehydratedBlockRegistry, injector.get(ApplicationRef));\n}\nfunction deferBlockHasErrored(deferBlock) {\n return getLDeferBlockDetails(deferBlock.lView, deferBlock.tNode)[DEFER_BLOCK_STATE] === DeferBlockState.Error;\n}\n/**\n * Clean up the parent container of a block where content changed between server and client.\n * The parent of a block going through `triggerHydrationFromBlockName` will contain the\n * dehydrated content that needs to be cleaned up. So we have to do the clean up from that location\n * in the tree.\n */\nfunction cleanupParentContainer(currentBlockIdx, hydrationQueue, dehydratedBlockRegistry) {\n // If a parent block exists, it's in the hydration queue in front of the current block.\n const parentDeferBlockIdx = currentBlockIdx - 1;\n const parentDeferBlock = parentDeferBlockIdx > -1 ? dehydratedBlockRegistry.get(hydrationQueue[parentDeferBlockIdx]) : null;\n if (parentDeferBlock) {\n cleanupLContainer(parentDeferBlock.lContainer);\n }\n}\nfunction cleanupRemainingHydrationQueue(hydrationQueue, dehydratedBlockRegistry) {\n const blocksBeingHydrated = dehydratedBlockRegistry.hydrating;\n for (const dehydratedBlockId in hydrationQueue) {\n blocksBeingHydrated.get(dehydratedBlockId)?.reject();\n }\n dehydratedBlockRegistry.cleanup(hydrationQueue);\n}\n/**\n * Generates a new promise for every defer block in the hydrating queue\n */\nfunction populateHydratingStateForQueue(registry, queue) {\n for (let blockId of queue) {\n registry.hydrating.set(blockId, Promise.withResolvers());\n }\n}\n// Waits for the next render cycle to complete\nfunction nextRender(injector) {\n return new Promise(resolveFn => afterNextRender(resolveFn, {\n injector\n }));\n}\nasync function triggerResourceLoadingForHydration(dehydratedBlock) {\n const {\n tNode,\n lView\n } = dehydratedBlock;\n const lDetails = getLDeferBlockDetails(lView, tNode);\n return new Promise(resolve => {\n onDeferBlockCompletion(lDetails, resolve);\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n });\n}\n/**\n * Registers cleanup functions for a defer block when the block has finished\n * fetching and rendering\n */\nfunction onDeferBlockCompletion(lDetails, callback) {\n if (!Array.isArray(lDetails[ON_COMPLETE_FNS])) {\n lDetails[ON_COMPLETE_FNS] = [];\n }\n lDetails[ON_COMPLETE_FNS].push(callback);\n}\n/**\n * Determines whether specific trigger types should be attached during an instruction firing\n * to ensure the proper triggers for a given type are used.\n */\nfunction shouldAttachTrigger(triggerType, lView, tNode) {\n if (triggerType === 0 /* TriggerType.Regular */) {\n return shouldAttachRegularTrigger(lView, tNode);\n } else if (triggerType === 2 /* TriggerType.Hydrate */) {\n return !shouldAttachRegularTrigger(lView, tNode);\n }\n // TriggerType.Prefetch is active only on the client\n return !(typeof ngServerMode !== 'undefined' && ngServerMode);\n}\n/**\n * Defines whether a regular trigger logic (e.g. \"on viewport\") should be attached\n * to a defer block. This function defines a condition, which mutually excludes\n * `deferOn*` and `deferHydrateOn*` triggers, to make sure only one of the trigger\n * types is active for a block with the current state.\n */\nfunction shouldAttachRegularTrigger(lView, tNode) {\n const injector = lView[INJECTOR];\n const tDetails = getTDeferBlockDetails(lView[TVIEW], tNode);\n const incrementalHydrationEnabled = isIncrementalHydrationEnabled(injector);\n const hasHydrateTriggers = tDetails.flags !== null && (tDetails.flags & 1 /* TDeferDetailsFlags.HasHydrateTriggers */) === 1 /* TDeferDetailsFlags.HasHydrateTriggers */;\n // On the server:\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // Regular triggers are activated on the server when:\n // - Either Incremental Hydration is *not* enabled\n // - Or Incremental Hydration is enabled, but a given block doesn't have \"hydrate\" triggers\n return !incrementalHydrationEnabled || !hasHydrateTriggers;\n }\n // On the client:\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const wasServerSideRendered = lDetails[SSR_UNIQUE_ID] !== null;\n if (hasHydrateTriggers && wasServerSideRendered && incrementalHydrationEnabled) {\n return false;\n }\n return true;\n}\n/**\n * Retrives a Defer Block's list of hydration triggers\n */\nfunction getHydrateTriggers(tView, tNode) {\n const tDetails = getTDeferBlockDetails(tView, tNode);\n return tDetails.hydrateTriggers ??= new Map();\n}\n/**\n * Loops through all defer block summaries and ensures all the blocks triggers are\n * properly initialized\n */\nfunction processAndInitTriggers(injector, blockData, nodes) {\n const idleElements = [];\n const timerElements = [];\n const viewportElements = [];\n const immediateElements = [];\n for (let [blockId, blockSummary] of blockData) {\n const commentNode = nodes.get(blockId);\n if (commentNode !== undefined) {\n const numRootNodes = blockSummary.data[NUM_ROOT_NODES];\n let currentNode = commentNode;\n for (let i = 0; i < numRootNodes; i++) {\n currentNode = currentNode.previousSibling;\n if (currentNode.nodeType !== Node.ELEMENT_NODE) {\n continue;\n }\n const elementTrigger = {\n el: currentNode,\n blockName: blockId\n };\n // hydrate\n if (blockSummary.hydrate.idle) {\n idleElements.push(elementTrigger);\n }\n if (blockSummary.hydrate.immediate) {\n immediateElements.push(elementTrigger);\n }\n if (blockSummary.hydrate.timer !== null) {\n elementTrigger.delay = blockSummary.hydrate.timer;\n timerElements.push(elementTrigger);\n }\n if (blockSummary.hydrate.viewport) {\n viewportElements.push(elementTrigger);\n }\n }\n }\n }\n setIdleTriggers(injector, idleElements);\n setImmediateTriggers(injector, immediateElements);\n setViewportTriggers(injector, viewportElements);\n setTimerTriggers(injector, timerElements);\n}\nfunction setIdleTriggers(injector, elementTriggers) {\n for (const elementTrigger of elementTriggers) {\n const registry = injector.get(DEHYDRATED_BLOCK_REGISTRY);\n const onInvoke = () => triggerHydrationFromBlockName(injector, elementTrigger.blockName);\n const cleanupFn = onIdle(onInvoke, injector);\n registry.addCleanupFn(elementTrigger.blockName, cleanupFn);\n }\n}\nfunction setViewportTriggers(injector, elementTriggers) {\n if (elementTriggers.length > 0) {\n const registry = injector.get(DEHYDRATED_BLOCK_REGISTRY);\n for (let elementTrigger of elementTriggers) {\n const cleanupFn = onViewport(elementTrigger.el, () => triggerHydrationFromBlockName(injector, elementTrigger.blockName), injector);\n registry.addCleanupFn(elementTrigger.blockName, cleanupFn);\n }\n }\n}\nfunction setTimerTriggers(injector, elementTriggers) {\n for (const elementTrigger of elementTriggers) {\n const registry = injector.get(DEHYDRATED_BLOCK_REGISTRY);\n const onInvoke = () => triggerHydrationFromBlockName(injector, elementTrigger.blockName);\n const timerFn = onTimer(elementTrigger.delay);\n const cleanupFn = timerFn(onInvoke, injector);\n registry.addCleanupFn(elementTrigger.blockName, cleanupFn);\n }\n}\nfunction setImmediateTriggers(injector, elementTriggers) {\n for (const elementTrigger of elementTriggers) {\n // Note: we intentionally avoid awaiting each call and instead kick off\n // th hydration process simultaneously for all defer blocks with this trigger;\n triggerHydrationFromBlockName(injector, elementTrigger.blockName);\n }\n}\n\n/**\n * Creates runtime data structures for defer blocks.\n *\n * @param index Index of the `defer` instruction.\n * @param primaryTmplIndex Index of the template with the primary block content.\n * @param dependencyResolverFn Function that contains dependencies for this defer block.\n * @param loadingTmplIndex Index of the template with the loading block content.\n * @param placeholderTmplIndex Index of the template with the placeholder block content.\n * @param errorTmplIndex Index of the template with the error block content.\n * @param loadingConfigIndex Index in the constants array of the configuration of the loading.\n * block.\n * @param placeholderConfigIndex Index in the constants array of the configuration of the\n * placeholder block.\n * @param enableTimerScheduling Function that enables timer-related scheduling if `after`\n * or `minimum` parameters are setup on the `@loading` or `@placeholder` blocks.\n * @param flags A set of flags to define a particular behavior (e.g. to indicate that\n * hydrate triggers are present and regular triggers should be deactivated\n * in certain scenarios).\n *\n * @codeGenApi\n */\nfunction ɵɵdefer(index, primaryTmplIndex, dependencyResolverFn, loadingTmplIndex, placeholderTmplIndex, errorTmplIndex, loadingConfigIndex, placeholderConfigIndex, enableTimerScheduling, flags) {\n const lView = getLView();\n const tView = getTView();\n const adjustedIndex = index + HEADER_OFFSET;\n const tNode = declareTemplate(lView, tView, index, null, 0, 0);\n const injector = lView[INJECTOR];\n if (tView.firstCreatePass) {\n performanceMarkFeature('NgDefer');\n const tDetails = {\n primaryTmplIndex,\n loadingTmplIndex: loadingTmplIndex ?? null,\n placeholderTmplIndex: placeholderTmplIndex ?? null,\n errorTmplIndex: errorTmplIndex ?? null,\n placeholderBlockConfig: null,\n loadingBlockConfig: null,\n dependencyResolverFn: dependencyResolverFn ?? null,\n loadingState: DeferDependenciesLoadingState.NOT_STARTED,\n loadingPromise: null,\n providers: null,\n hydrateTriggers: null,\n debug: null,\n flags: flags ?? 0 /* TDeferDetailsFlags.Default */\n };\n enableTimerScheduling?.(tView, tDetails, placeholderConfigIndex, loadingConfigIndex);\n setTDeferBlockDetails(tView, adjustedIndex, tDetails);\n }\n const lContainer = lView[adjustedIndex];\n // If hydration is enabled, looks up dehydrated views in the DOM\n // using hydration annotation info and stores those views on LContainer.\n // In client-only mode, this function is a noop.\n populateDehydratedViewsInLContainer(lContainer, tNode, lView);\n let ssrBlockState = null;\n let ssrUniqueId = null;\n if (lContainer[DEHYDRATED_VIEWS]?.length > 0) {\n const info = lContainer[DEHYDRATED_VIEWS][0].data;\n ssrUniqueId = info[DEFER_BLOCK_ID] ?? null;\n ssrBlockState = info[DEFER_BLOCK_STATE$1];\n }\n // Init instance-specific defer details and store it.\n const lDetails = [null,\n // NEXT_DEFER_BLOCK_STATE\n DeferBlockInternalState.Initial,\n // DEFER_BLOCK_STATE\n null,\n // STATE_IS_FROZEN_UNTIL\n null,\n // LOADING_AFTER_CLEANUP_FN\n null,\n // TRIGGER_CLEANUP_FNS\n null,\n // PREFETCH_TRIGGER_CLEANUP_FNS\n ssrUniqueId,\n // SSR_UNIQUE_ID\n ssrBlockState,\n // SSR_BLOCK_STATE\n null,\n // ON_COMPLETE_FNS\n null // HYDRATE_TRIGGER_CLEANUP_FNS\n ];\n setLDeferBlockDetails(lView, adjustedIndex, lDetails);\n let registry = null;\n if (ssrUniqueId !== null) {\n ngDevMode && assertIncrementalHydrationIsConfigured(injector);\n // Store this defer block in the registry, to have an access to\n // internal data structures from hydration runtime code.\n registry = injector.get(DEHYDRATED_BLOCK_REGISTRY);\n registry.add(ssrUniqueId, {\n lView,\n tNode,\n lContainer\n });\n }\n const onLViewDestroy = () => {\n invokeAllTriggerCleanupFns(lDetails);\n if (ssrUniqueId !== null) {\n registry?.cleanup([ssrUniqueId]);\n }\n };\n // When defer block is triggered - unsubscribe from LView destroy cleanup.\n storeTriggerCleanupFn(0 /* TriggerType.Regular */, lDetails, () => removeLViewOnDestroy(lView, onLViewDestroy));\n storeLViewOnDestroy(lView, onLViewDestroy);\n}\n/**\n * Loads defer block dependencies when a trigger value becomes truthy.\n * @codeGenApi\n */\nfunction ɵɵdeferWhen(rawValue) {\n const lView = getLView();\n const tNode = getSelectedTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'when <expression>');\n }\n if (!shouldAttachTrigger(0 /* TriggerType.Regular */, lView, tNode)) return;\n const bindingIndex = nextBindingIndex();\n if (bindingUpdated(lView, bindingIndex, rawValue)) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n const value = Boolean(rawValue); // handle truthy or falsy values\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const renderedState = lDetails[DEFER_BLOCK_STATE];\n if (value === false && renderedState === DeferBlockInternalState.Initial) {\n // If nothing is rendered yet, render a placeholder (if defined).\n renderPlaceholder(lView, tNode);\n } else if (value === true && (renderedState === DeferBlockInternalState.Initial || renderedState === DeferBlockState.Placeholder)) {\n triggerDeferBlock(0 /* TriggerType.Regular */, lView, tNode);\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n}\n/**\n * Prefetches the deferred content when a value becomes truthy.\n * @codeGenApi\n */\nfunction ɵɵdeferPrefetchWhen(rawValue) {\n const lView = getLView();\n const tNode = getSelectedTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'prefetch when <expression>');\n }\n if (!shouldAttachTrigger(1 /* TriggerType.Prefetch */, lView, tNode)) return;\n const bindingIndex = nextBindingIndex();\n if (bindingUpdated(lView, bindingIndex, rawValue)) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n const value = Boolean(rawValue); // handle truthy or falsy values\n const tView = lView[TVIEW];\n const tNode = getSelectedTNode();\n const tDetails = getTDeferBlockDetails(tView, tNode);\n if (value === true && tDetails.loadingState === DeferDependenciesLoadingState.NOT_STARTED) {\n // If loading has not been started yet, trigger it now.\n triggerPrefetching(tDetails, lView, tNode);\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n}\n/**\n * Hydrates the deferred content when a value becomes truthy.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateWhen(rawValue) {\n const lView = getLView();\n const tNode = getSelectedTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'hydrate when <expression>');\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n // TODO(incremental-hydration): audit all defer instructions to reduce unnecessary work by\n // moving function calls inside their relevant control flow blocks\n const bindingIndex = nextBindingIndex();\n const tView = getTView();\n const hydrateTriggers = getHydrateTriggers(tView, tNode);\n hydrateTriggers.set(6 /* DeferBlockTrigger.When */, null);\n if (bindingUpdated(lView, bindingIndex, rawValue)) {\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // We are on the server and SSR for defer blocks is enabled.\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n } else {\n const injector = lView[INJECTOR];\n const prevConsumer = setActiveConsumer$1(null);\n try {\n const value = Boolean(rawValue); // handle truthy or falsy values\n if (value === true) {\n // The `when` condition has changed to `true`, trigger defer block loading\n // if the block is either in initial (nothing is rendered) or a placeholder\n // state.\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const ssrUniqueId = lDetails[SSR_UNIQUE_ID];\n ngDevMode && assertSsrIdDefined(ssrUniqueId);\n triggerHydrationFromBlockName(injector, ssrUniqueId);\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n }\n }\n}\n/**\n * Specifies that hydration never occurs.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateNever() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'hydrate never');\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n const hydrateTriggers = getHydrateTriggers(getTView(), tNode);\n hydrateTriggers.set(7 /* DeferBlockTrigger.Never */, null);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // We are on the server and SSR for defer blocks is enabled.\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n }\n}\n/**\n * Sets up logic to handle the `on idle` deferred trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferOnIdle() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'on idle');\n }\n if (!shouldAttachTrigger(0 /* TriggerType.Regular */, lView, tNode)) return;\n scheduleDelayedTrigger(onIdle);\n}\n/**\n * Sets up logic to handle the `prefetch on idle` deferred trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferPrefetchOnIdle() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'prefetch on idle');\n }\n if (!shouldAttachTrigger(1 /* TriggerType.Prefetch */, lView, tNode)) return;\n scheduleDelayedPrefetching(onIdle, 0 /* DeferBlockTrigger.Idle */);\n}\n/**\n * Sets up logic to handle the `on idle` deferred trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateOnIdle() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'hydrate on idle');\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n const hydrateTriggers = getHydrateTriggers(getTView(), tNode);\n hydrateTriggers.set(0 /* DeferBlockTrigger.Idle */, null);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // We are on the server and SSR for defer blocks is enabled.\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n } else {\n scheduleDelayedHydrating(onIdle, lView, tNode);\n }\n}\n/**\n * Sets up logic to handle the `on immediate` deferred trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferOnImmediate() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'on immediate');\n }\n if (!shouldAttachTrigger(0 /* TriggerType.Regular */, lView, tNode)) return;\n // Render placeholder block only if loading template is not present and we're on\n // the client to avoid content flickering, since it would be immediately replaced\n // by the loading block.\n const tDetails = getTDeferBlockDetails(lView[TVIEW], tNode);\n if (tDetails.loadingTmplIndex === null) {\n renderPlaceholder(lView, tNode);\n }\n triggerDeferBlock(0 /* TriggerType.Regular */, lView, tNode);\n}\n/**\n * Sets up logic to handle the `prefetch on immediate` deferred trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferPrefetchOnImmediate() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'prefetch on immediate');\n }\n if (!shouldAttachTrigger(1 /* TriggerType.Prefetch */, lView, tNode)) return;\n const tView = lView[TVIEW];\n const tDetails = getTDeferBlockDetails(tView, tNode);\n if (tDetails.loadingState === DeferDependenciesLoadingState.NOT_STARTED) {\n triggerResourceLoading(tDetails, lView, tNode);\n }\n}\n/**\n * Sets up logic to handle the `on immediate` hydrate trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateOnImmediate() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'hydrate on immediate');\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n const hydrateTriggers = getHydrateTriggers(getTView(), tNode);\n hydrateTriggers.set(1 /* DeferBlockTrigger.Immediate */, null);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n } else {\n const injector = lView[INJECTOR];\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const ssrUniqueId = lDetails[SSR_UNIQUE_ID];\n ngDevMode && assertSsrIdDefined(ssrUniqueId);\n triggerHydrationFromBlockName(injector, ssrUniqueId);\n }\n}\n/**\n * Creates runtime data structures for the `on timer` deferred trigger.\n * @param delay Amount of time to wait before loading the content.\n * @codeGenApi\n */\nfunction ɵɵdeferOnTimer(delay) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `on timer(${delay}ms)`);\n }\n if (!shouldAttachTrigger(0 /* TriggerType.Regular */, lView, tNode)) return;\n scheduleDelayedTrigger(onTimer(delay));\n}\n/**\n * Creates runtime data structures for the `prefetch on timer` deferred trigger.\n * @param delay Amount of time to wait before prefetching the content.\n * @codeGenApi\n */\nfunction ɵɵdeferPrefetchOnTimer(delay) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `prefetch on timer(${delay}ms)`);\n }\n if (!shouldAttachTrigger(1 /* TriggerType.Prefetch */, lView, tNode)) return;\n scheduleDelayedPrefetching(onTimer(delay), 5 /* DeferBlockTrigger.Timer */);\n}\n/**\n * Creates runtime data structures for the `on timer` hydrate trigger.\n * @param delay Amount of time to wait before loading the content.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateOnTimer(delay) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `hydrate on timer(${delay}ms)`);\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n const hydrateTriggers = getHydrateTriggers(getTView(), tNode);\n hydrateTriggers.set(5 /* DeferBlockTrigger.Timer */, {\n delay\n });\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // We are on the server and SSR for defer blocks is enabled.\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n } else {\n scheduleDelayedHydrating(onTimer(delay), lView, tNode);\n }\n}\n/**\n * Creates runtime data structures for the `on hover` deferred trigger.\n * @param triggerIndex Index at which to find the trigger element.\n * @param walkUpTimes Number of times to walk up/down the tree hierarchy to find the trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferOnHover(triggerIndex, walkUpTimes) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `on hover${walkUpTimes === -1 ? '' : '(<target>)'}`);\n }\n if (!shouldAttachTrigger(0 /* TriggerType.Regular */, lView, tNode)) return;\n renderPlaceholder(lView, tNode);\n // Avoid adding event listeners when this instruction is invoked on the server.\n if (!(typeof ngServerMode !== 'undefined' && ngServerMode)) {\n registerDomTrigger(lView, tNode, triggerIndex, walkUpTimes, onHover, () => triggerDeferBlock(0 /* TriggerType.Regular */, lView, tNode), 0 /* TriggerType.Regular */);\n }\n}\n/**\n * Creates runtime data structures for the `prefetch on hover` deferred trigger.\n * @param triggerIndex Index at which to find the trigger element.\n * @param walkUpTimes Number of times to walk up/down the tree hierarchy to find the trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferPrefetchOnHover(triggerIndex, walkUpTimes) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `prefetch on hover${walkUpTimes === -1 ? '' : '(<target>)'}`);\n }\n if (!shouldAttachTrigger(1 /* TriggerType.Prefetch */, lView, tNode)) return;\n const tView = lView[TVIEW];\n const tDetails = getTDeferBlockDetails(tView, tNode);\n if (tDetails.loadingState === DeferDependenciesLoadingState.NOT_STARTED) {\n registerDomTrigger(lView, tNode, triggerIndex, walkUpTimes, onHover, () => triggerPrefetching(tDetails, lView, tNode), 1 /* TriggerType.Prefetch */);\n }\n}\n/**\n * Creates runtime data structures for the `on hover` hydrate trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateOnHover() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'hydrate on hover');\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n const hydrateTriggers = getHydrateTriggers(getTView(), tNode);\n hydrateTriggers.set(4 /* DeferBlockTrigger.Hover */, null);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // We are on the server and SSR for defer blocks is enabled.\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n }\n // The actual triggering of hydration on hover is handled by JSAction in\n // event_replay.ts.\n}\n/**\n * Creates runtime data structures for the `on interaction` deferred trigger.\n * @param triggerIndex Index at which to find the trigger element.\n * @param walkUpTimes Number of times to walk up/down the tree hierarchy to find the trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferOnInteraction(triggerIndex, walkUpTimes) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `on interaction${walkUpTimes === -1 ? '' : '(<target>)'}`);\n }\n if (!shouldAttachTrigger(0 /* TriggerType.Regular */, lView, tNode)) return;\n renderPlaceholder(lView, tNode);\n // Avoid adding event listeners when this instruction is invoked on the server.\n if (!(typeof ngServerMode !== 'undefined' && ngServerMode)) {\n registerDomTrigger(lView, tNode, triggerIndex, walkUpTimes, onInteraction, () => triggerDeferBlock(0 /* TriggerType.Regular */, lView, tNode), 0 /* TriggerType.Regular */);\n }\n}\n/**\n * Creates runtime data structures for the `prefetch on interaction` deferred trigger.\n * @param triggerIndex Index at which to find the trigger element.\n * @param walkUpTimes Number of times to walk up/down the tree hierarchy to find the trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferPrefetchOnInteraction(triggerIndex, walkUpTimes) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `prefetch on interaction${walkUpTimes === -1 ? '' : '(<target>)'}`);\n }\n if (!shouldAttachTrigger(1 /* TriggerType.Prefetch */, lView, tNode)) return;\n const tView = lView[TVIEW];\n const tDetails = getTDeferBlockDetails(tView, tNode);\n if (tDetails.loadingState === DeferDependenciesLoadingState.NOT_STARTED) {\n registerDomTrigger(lView, tNode, triggerIndex, walkUpTimes, onInteraction, () => triggerPrefetching(tDetails, lView, tNode), 1 /* TriggerType.Prefetch */);\n }\n}\n/**\n * Creates runtime data structures for the `on interaction` hydrate trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateOnInteraction() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'hydrate on interaction');\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n const hydrateTriggers = getHydrateTriggers(getTView(), tNode);\n hydrateTriggers.set(3 /* DeferBlockTrigger.Interaction */, null);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // We are on the server and SSR for defer blocks is enabled.\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n }\n // The actual triggering of hydration on interaction is handled by JSAction in\n // event_replay.ts.\n}\n/**\n * Creates runtime data structures for the `on viewport` deferred trigger.\n * @param triggerIndex Index at which to find the trigger element.\n * @param walkUpTimes Number of times to walk up/down the tree hierarchy to find the trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferOnViewport(triggerIndex, walkUpTimes) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `on viewport${walkUpTimes === -1 ? '' : '(<target>)'}`);\n }\n if (!shouldAttachTrigger(0 /* TriggerType.Regular */, lView, tNode)) return;\n renderPlaceholder(lView, tNode);\n // Avoid adding event listeners when this instruction is invoked on the server.\n if (!(typeof ngServerMode !== 'undefined' && ngServerMode)) {\n registerDomTrigger(lView, tNode, triggerIndex, walkUpTimes, onViewport, () => triggerDeferBlock(0 /* TriggerType.Regular */, lView, tNode), 0 /* TriggerType.Regular */);\n }\n}\n/**\n * Creates runtime data structures for the `prefetch on viewport` deferred trigger.\n * @param triggerIndex Index at which to find the trigger element.\n * @param walkUpTimes Number of times to walk up/down the tree hierarchy to find the trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferPrefetchOnViewport(triggerIndex, walkUpTimes) {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, `prefetch on viewport${walkUpTimes === -1 ? '' : '(<target>)'}`);\n }\n if (!shouldAttachTrigger(1 /* TriggerType.Prefetch */, lView, tNode)) return;\n const tView = lView[TVIEW];\n const tDetails = getTDeferBlockDetails(tView, tNode);\n if (tDetails.loadingState === DeferDependenciesLoadingState.NOT_STARTED) {\n registerDomTrigger(lView, tNode, triggerIndex, walkUpTimes, onViewport, () => triggerPrefetching(tDetails, lView, tNode), 1 /* TriggerType.Prefetch */);\n }\n}\n/**\n * Creates runtime data structures for the `on viewport` hydrate trigger.\n * @codeGenApi\n */\nfunction ɵɵdeferHydrateOnViewport() {\n const lView = getLView();\n const tNode = getCurrentTNode();\n if (ngDevMode) {\n trackTriggerForDebugging(lView[TVIEW], tNode, 'hydrate on viewport');\n }\n if (!shouldAttachTrigger(2 /* TriggerType.Hydrate */, lView, tNode)) return;\n const hydrateTriggers = getHydrateTriggers(getTView(), tNode);\n hydrateTriggers.set(2 /* DeferBlockTrigger.Viewport */, null);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // We are on the server and SSR for defer blocks is enabled.\n triggerDeferBlock(2 /* TriggerType.Hydrate */, lView, tNode);\n }\n // The actual triggering of hydration on viewport happens in triggering.ts,\n // since these instructions won't exist for dehydrated content.\n}\n\n/**\n * Updates the value of or removes a bound attribute on an Element.\n *\n * Used in the case of `[attr.title]=\"value\"`\n *\n * @param name name The name of the attribute.\n * @param value value The attribute is removed when value is `null` or `undefined`.\n * Otherwise the attribute value is set to the stringified value.\n * @param sanitizer An optional function used to sanitize the value.\n * @param namespace Optional namespace to use when setting the attribute.\n *\n * @codeGenApi\n */\nfunction ɵɵattribute(name, value, sanitizer, namespace) {\n const lView = getLView();\n const bindingIndex = nextBindingIndex();\n if (bindingUpdated(lView, bindingIndex, value)) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, name, value, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, 'attr.' + name, bindingIndex);\n }\n return ɵɵattribute;\n}\n\n/**\n * Create interpolation bindings with a variable number of expressions.\n *\n * If there are 1 to 8 expressions `interpolation1()` to `interpolation8()` should be used instead.\n * Those are faster because there is no need to create an array of expressions and iterate over it.\n *\n * `values`:\n * - has static text at even indexes,\n * - has evaluated expressions at odd indexes.\n *\n * Returns the concatenated string when any of the arguments changes, `NO_CHANGE` otherwise.\n */\nfunction interpolationV(lView, values) {\n ngDevMode && assertLessThan(2, values.length, 'should have at least 3 values');\n ngDevMode && assertEqual(values.length % 2, 1, 'should have an odd number of values');\n let isBindingUpdated = false;\n let bindingIndex = getBindingIndex();\n for (let i = 1; i < values.length; i += 2) {\n // Check if bindings (odd indexes) have changed\n isBindingUpdated = bindingUpdated(lView, bindingIndex++, values[i]) || isBindingUpdated;\n }\n setBindingIndex(bindingIndex);\n if (!isBindingUpdated) {\n return NO_CHANGE;\n }\n // Build the updated content\n let content = values[0];\n for (let i = 1; i < values.length; i += 2) {\n content += renderStringify(values[i]) + values[i + 1];\n }\n return content;\n}\n/**\n * Creates an interpolation binding with 1 expression.\n *\n * @param prefix static value used for concatenation only.\n * @param v0 value checked for change.\n * @param suffix static value used for concatenation only.\n */\nfunction interpolation1(lView, prefix, v0, suffix) {\n const different = bindingUpdated(lView, nextBindingIndex(), v0);\n return different ? prefix + renderStringify(v0) + suffix : NO_CHANGE;\n}\n/**\n * Creates an interpolation binding with 2 expressions.\n */\nfunction interpolation2(lView, prefix, v0, i0, v1, suffix) {\n const bindingIndex = getBindingIndex();\n const different = bindingUpdated2(lView, bindingIndex, v0, v1);\n incrementBindingIndex(2);\n return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + suffix : NO_CHANGE;\n}\n/**\n * Creates an interpolation binding with 3 expressions.\n */\nfunction interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix) {\n const bindingIndex = getBindingIndex();\n const different = bindingUpdated3(lView, bindingIndex, v0, v1, v2);\n incrementBindingIndex(3);\n return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + suffix : NO_CHANGE;\n}\n/**\n * Create an interpolation binding with 4 expressions.\n */\nfunction interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {\n const bindingIndex = getBindingIndex();\n const different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);\n incrementBindingIndex(4);\n return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + suffix : NO_CHANGE;\n}\n/**\n * Creates an interpolation binding with 5 expressions.\n */\nfunction interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {\n const bindingIndex = getBindingIndex();\n let different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);\n different = bindingUpdated(lView, bindingIndex + 4, v4) || different;\n incrementBindingIndex(5);\n return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + suffix : NO_CHANGE;\n}\n/**\n * Creates an interpolation binding with 6 expressions.\n */\nfunction interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {\n const bindingIndex = getBindingIndex();\n let different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);\n different = bindingUpdated2(lView, bindingIndex + 4, v4, v5) || different;\n incrementBindingIndex(6);\n return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + i4 + renderStringify(v5) + suffix : NO_CHANGE;\n}\n/**\n * Creates an interpolation binding with 7 expressions.\n */\nfunction interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {\n const bindingIndex = getBindingIndex();\n let different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);\n different = bindingUpdated3(lView, bindingIndex + 4, v4, v5, v6) || different;\n incrementBindingIndex(7);\n return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + i4 + renderStringify(v5) + i5 + renderStringify(v6) + suffix : NO_CHANGE;\n}\n/**\n * Creates an interpolation binding with 8 expressions.\n */\nfunction interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {\n const bindingIndex = getBindingIndex();\n let different = bindingUpdated4(lView, bindingIndex, v0, v1, v2, v3);\n different = bindingUpdated4(lView, bindingIndex + 4, v4, v5, v6, v7) || different;\n incrementBindingIndex(8);\n return different ? prefix + renderStringify(v0) + i0 + renderStringify(v1) + i1 + renderStringify(v2) + i2 + renderStringify(v3) + i3 + renderStringify(v4) + i4 + renderStringify(v5) + i5 + renderStringify(v6) + i6 + renderStringify(v7) + suffix : NO_CHANGE;\n}\n\n/**\n *\n * Update an interpolated attribute on an element with single bound value surrounded by text.\n *\n * Used when the value passed to a property has 1 interpolated value in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate1('title', 'prefix', v0, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate1(attrName, prefix, v0, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation1(lView, prefix, v0, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 1, prefix, suffix);\n }\n return ɵɵattributeInterpolate1;\n}\n/**\n *\n * Update an interpolated attribute on an element with 2 bound values surrounded by text.\n *\n * Used when the value passed to a property has 2 interpolated values in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}-{{v1}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate2(attrName, prefix, v0, i0, v1, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 2, prefix, i0, suffix);\n }\n return ɵɵattributeInterpolate2;\n}\n/**\n *\n * Update an interpolated attribute on an element with 3 bound values surrounded by text.\n *\n * Used when the value passed to a property has 3 interpolated values in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}-{{v1}}-{{v2}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate3(\n * 'title', 'prefix', v0, '-', v1, '-', v2, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate3(attrName, prefix, v0, i0, v1, i1, v2, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 3, prefix, i0, i1, suffix);\n }\n return ɵɵattributeInterpolate3;\n}\n/**\n *\n * Update an interpolated attribute on an element with 4 bound values surrounded by text.\n *\n * Used when the value passed to a property has 4 interpolated values in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate4(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate4(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 4, prefix, i0, i1, i2, suffix);\n }\n return ɵɵattributeInterpolate4;\n}\n/**\n *\n * Update an interpolated attribute on an element with 5 bound values surrounded by text.\n *\n * Used when the value passed to a property has 5 interpolated values in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate5(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate5(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 5, prefix, i0, i1, i2, i3, suffix);\n }\n return ɵɵattributeInterpolate5;\n}\n/**\n *\n * Update an interpolated attribute on an element with 6 bound values surrounded by text.\n *\n * Used when the value passed to a property has 6 interpolated values in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate6(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate6(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 6, prefix, i0, i1, i2, i3, i4, suffix);\n }\n return ɵɵattributeInterpolate6;\n}\n/**\n *\n * Update an interpolated attribute on an element with 7 bound values surrounded by text.\n *\n * Used when the value passed to a property has 7 interpolated values in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate7(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate7(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 7, prefix, i0, i1, i2, i3, i4, i5, suffix);\n }\n return ɵɵattributeInterpolate7;\n}\n/**\n *\n * Update an interpolated attribute on an element with 8 bound values surrounded by text.\n *\n * Used when the value passed to a property has 8 interpolated values in it:\n *\n * ```html\n * <div attr.title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolate8(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');\n * ```\n *\n * @param attrName The name of the attribute to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param i6 Static value used for concatenation only.\n * @param v7 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolate8(attrName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix, sanitizer, namespace) {\n const lView = getLView();\n const interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolatedValue, sanitizer, namespace);\n ngDevMode && storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - 8, prefix, i0, i1, i2, i3, i4, i5, i6, suffix);\n }\n return ɵɵattributeInterpolate8;\n}\n/**\n * Update an interpolated attribute on an element with 9 or more bound values surrounded by text.\n *\n * Used when the number of interpolated values exceeds 8.\n *\n * ```html\n * <div\n * title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵattributeInterpolateV(\n * 'title', ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,\n * 'suffix']);\n * ```\n *\n * @param attrName The name of the attribute to update.\n * @param values The collection of values and the strings in-between those values, beginning with\n * a string prefix and ending with a string suffix.\n * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵattributeInterpolateV(attrName, values, sanitizer, namespace) {\n const lView = getLView();\n const interpolated = interpolationV(lView, values);\n if (interpolated !== NO_CHANGE) {\n const tNode = getSelectedTNode();\n elementAttributeInternal(tNode, lView, attrName, interpolated, sanitizer, namespace);\n if (ngDevMode) {\n const interpolationInBetween = [values[0]]; // prefix\n for (let i = 2; i < values.length; i += 2) {\n interpolationInBetween.push(values[i]);\n }\n storePropertyBindingMetadata(getTView().data, tNode, 'attr.' + attrName, getBindingIndex() - interpolationInBetween.length + 1, ...interpolationInBetween);\n }\n }\n return ɵɵattributeInterpolateV;\n}\nfunction toTStylingRange(prev, next) {\n ngDevMode && assertNumberInRange(prev, 0, 32767 /* StylingRange.UNSIGNED_MASK */);\n ngDevMode && assertNumberInRange(next, 0, 32767 /* StylingRange.UNSIGNED_MASK */);\n return prev << 17 /* StylingRange.PREV_SHIFT */ | next << 2 /* StylingRange.NEXT_SHIFT */;\n}\nfunction getTStylingRangePrev(tStylingRange) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n return tStylingRange >> 17 /* StylingRange.PREV_SHIFT */ & 32767 /* StylingRange.UNSIGNED_MASK */;\n}\nfunction getTStylingRangePrevDuplicate(tStylingRange) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n return (tStylingRange & 2 /* StylingRange.PREV_DUPLICATE */) == 2 /* StylingRange.PREV_DUPLICATE */;\n}\nfunction setTStylingRangePrev(tStylingRange, previous) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n ngDevMode && assertNumberInRange(previous, 0, 32767 /* StylingRange.UNSIGNED_MASK */);\n return tStylingRange & ~4294836224 /* StylingRange.PREV_MASK */ | previous << 17 /* StylingRange.PREV_SHIFT */;\n}\nfunction setTStylingRangePrevDuplicate(tStylingRange) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n return tStylingRange | 2 /* StylingRange.PREV_DUPLICATE */;\n}\nfunction getTStylingRangeNext(tStylingRange) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n return (tStylingRange & 131068 /* StylingRange.NEXT_MASK */) >> 2 /* StylingRange.NEXT_SHIFT */;\n}\nfunction setTStylingRangeNext(tStylingRange, next) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n ngDevMode && assertNumberInRange(next, 0, 32767 /* StylingRange.UNSIGNED_MASK */);\n return tStylingRange & ~131068 /* StylingRange.NEXT_MASK */ |\n //\n next << 2 /* StylingRange.NEXT_SHIFT */;\n}\nfunction getTStylingRangeNextDuplicate(tStylingRange) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n return (tStylingRange & 1 /* StylingRange.NEXT_DUPLICATE */) === 1 /* StylingRange.NEXT_DUPLICATE */;\n}\nfunction setTStylingRangeNextDuplicate(tStylingRange) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n return tStylingRange | 1 /* StylingRange.NEXT_DUPLICATE */;\n}\nfunction getTStylingRangeTail(tStylingRange) {\n ngDevMode && assertNumber(tStylingRange, 'expected number');\n const next = getTStylingRangeNext(tStylingRange);\n return next === 0 ? getTStylingRangePrev(tStylingRange) : next;\n}\n\n/**\n * NOTE: The word `styling` is used interchangeably as style or class styling.\n *\n * This file contains code to link styling instructions together so that they can be replayed in\n * priority order. The file exists because Ivy styling instruction execution order does not match\n * that of the priority order. The purpose of this code is to create a linked list so that the\n * instructions can be traversed in priority order when computing the styles.\n *\n * Assume we are dealing with the following code:\n * ```angular-ts\n * @Component({\n * template: `\n * <my-cmp [style]=\" {color: '#001'} \"\n * [style.color]=\" #002 \"\n * dir-style-color-1\n * dir-style-color-2> `\n * })\n * class ExampleComponent {\n * static ngComp = ... {\n * ...\n * // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`\n * ɵɵstyleMap({color: '#001'});\n * ɵɵstyleProp('color', '#002');\n * ...\n * }\n * }\n *\n * @Directive({\n * selector: `[dir-style-color-1]',\n * })\n * class Style1Directive {\n * @HostBinding('style') style = {color: '#005'};\n * @HostBinding('style.color') color = '#006';\n *\n * static ngDir = ... {\n * ...\n * // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`\n * ɵɵstyleMap({color: '#005'});\n * ɵɵstyleProp('color', '#006');\n * ...\n * }\n * }\n *\n * @Directive({\n * selector: `[dir-style-color-2]',\n * })\n * class Style2Directive {\n * @HostBinding('style') style = {color: '#007'};\n * @HostBinding('style.color') color = '#008';\n *\n * static ngDir = ... {\n * ...\n * // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`\n * ɵɵstyleMap({color: '#007'});\n * ɵɵstyleProp('color', '#008');\n * ...\n * }\n * }\n *\n * @Directive({\n * selector: `my-cmp',\n * })\n * class MyComponent {\n * @HostBinding('style') style = {color: '#003'};\n * @HostBinding('style.color') color = '#004';\n *\n * static ngComp = ... {\n * ...\n * // Compiler ensures that `ɵɵstyleProp` is after `ɵɵstyleMap`\n * ɵɵstyleMap({color: '#003'});\n * ɵɵstyleProp('color', '#004');\n * ...\n * }\n * }\n * ```\n *\n * The Order of instruction execution is:\n *\n * NOTE: the comment binding location is for illustrative purposes only.\n *\n * ```ts\n * // Template: (ExampleComponent)\n * ɵɵstyleMap({color: '#001'}); // Binding index: 10\n * ɵɵstyleProp('color', '#002'); // Binding index: 12\n * // MyComponent\n * ɵɵstyleMap({color: '#003'}); // Binding index: 20\n * ɵɵstyleProp('color', '#004'); // Binding index: 22\n * // Style1Directive\n * ɵɵstyleMap({color: '#005'}); // Binding index: 24\n * ɵɵstyleProp('color', '#006'); // Binding index: 26\n * // Style2Directive\n * ɵɵstyleMap({color: '#007'}); // Binding index: 28\n * ɵɵstyleProp('color', '#008'); // Binding index: 30\n * ```\n *\n * The correct priority order of concatenation is:\n *\n * ```ts\n * // MyComponent\n * ɵɵstyleMap({color: '#003'}); // Binding index: 20\n * ɵɵstyleProp('color', '#004'); // Binding index: 22\n * // Style1Directive\n * ɵɵstyleMap({color: '#005'}); // Binding index: 24\n * ɵɵstyleProp('color', '#006'); // Binding index: 26\n * // Style2Directive\n * ɵɵstyleMap({color: '#007'}); // Binding index: 28\n * ɵɵstyleProp('color', '#008'); // Binding index: 30\n * // Template: (ExampleComponent)\n * ɵɵstyleMap({color: '#001'}); // Binding index: 10\n * ɵɵstyleProp('color', '#002'); // Binding index: 12\n * ```\n *\n * What color should be rendered?\n *\n * Once the items are correctly sorted in the list, the answer is simply the last item in the\n * concatenation list which is `#002`.\n *\n * To do so we keep a linked list of all of the bindings which pertain to this element.\n * Notice that the bindings are inserted in the order of execution, but the `TView.data` allows\n * us to traverse them in the order of priority.\n *\n * |Idx|`TView.data`|`LView` | Notes\n * |---|------------|-----------------|--------------\n * |...| | |\n * |10 |`null` |`{color: '#001'}`| `ɵɵstyleMap('color', {color: '#001'})`\n * |11 |`30 | 12` | ... |\n * |12 |`color` |`'#002'` | `ɵɵstyleProp('color', '#002')`\n * |13 |`10 | 0` | ... |\n * |...| | |\n * |20 |`null` |`{color: '#003'}`| `ɵɵstyleMap('color', {color: '#003'})`\n * |21 |`0 | 22` | ... |\n * |22 |`color` |`'#004'` | `ɵɵstyleProp('color', '#004')`\n * |23 |`20 | 24` | ... |\n * |24 |`null` |`{color: '#005'}`| `ɵɵstyleMap('color', {color: '#005'})`\n * |25 |`22 | 26` | ... |\n * |26 |`color` |`'#006'` | `ɵɵstyleProp('color', '#006')`\n * |27 |`24 | 28` | ... |\n * |28 |`null` |`{color: '#007'}`| `ɵɵstyleMap('color', {color: '#007'})`\n * |29 |`26 | 30` | ... |\n * |30 |`color` |`'#008'` | `ɵɵstyleProp('color', '#008')`\n * |31 |`28 | 10` | ... |\n *\n * The above data structure allows us to re-concatenate the styling no matter which data binding\n * changes.\n *\n * NOTE: in addition to keeping track of next/previous index the `TView.data` also stores prev/next\n * duplicate bit. The duplicate bit if true says there either is a binding with the same name or\n * there is a map (which may contain the name). This information is useful in knowing if other\n * styles with higher priority need to be searched for overwrites.\n *\n * NOTE: See `should support example in 'tnode_linked_list.ts' documentation` in\n * `tnode_linked_list_spec.ts` for working example.\n */\nlet __unused_const_as_closure_does_not_like_standalone_comment_blocks__;\n/**\n * Insert new `tStyleValue` at `TData` and link existing style bindings such that we maintain linked\n * list of styles and compute the duplicate flag.\n *\n * Note: this function is executed during `firstUpdatePass` only to populate the `TView.data`.\n *\n * The function works by keeping track of `tStylingRange` which contains two pointers pointing to\n * the head/tail of the template portion of the styles.\n * - if `isHost === false` (we are template) then insertion is at tail of `TStylingRange`\n * - if `isHost === true` (we are host binding) then insertion is at head of `TStylingRange`\n *\n * @param tData The `TData` to insert into.\n * @param tNode `TNode` associated with the styling element.\n * @param tStylingKey See `TStylingKey`.\n * @param index location of where `tStyleValue` should be stored (and linked into list.)\n * @param isHostBinding `true` if the insertion is for a `hostBinding`. (insertion is in front of\n * template.)\n * @param isClassBinding True if the associated `tStylingKey` as a `class` styling.\n * `tNode.classBindings` should be used (or `tNode.styleBindings` otherwise.)\n */\nfunction insertTStylingBinding(tData, tNode, tStylingKeyWithStatic, index, isHostBinding, isClassBinding) {\n ngDevMode && assertFirstUpdatePass(getTView());\n let tBindings = isClassBinding ? tNode.classBindings : tNode.styleBindings;\n let tmplHead = getTStylingRangePrev(tBindings);\n let tmplTail = getTStylingRangeNext(tBindings);\n tData[index] = tStylingKeyWithStatic;\n let isKeyDuplicateOfStatic = false;\n let tStylingKey;\n if (Array.isArray(tStylingKeyWithStatic)) {\n // We are case when the `TStylingKey` contains static fields as well.\n const staticKeyValueArray = tStylingKeyWithStatic;\n tStylingKey = staticKeyValueArray[1]; // unwrap.\n // We need to check if our key is present in the static so that we can mark it as duplicate.\n if (tStylingKey === null || keyValueArrayIndexOf(staticKeyValueArray, tStylingKey) > 0) {\n // tStylingKey is present in the statics, need to mark it as duplicate.\n isKeyDuplicateOfStatic = true;\n }\n } else {\n tStylingKey = tStylingKeyWithStatic;\n }\n if (isHostBinding) {\n // We are inserting host bindings\n // If we don't have template bindings then `tail` is 0.\n const hasTemplateBindings = tmplTail !== 0;\n // This is important to know because that means that the `head` can't point to the first\n // template bindings (there are none.) Instead the head points to the tail of the template.\n if (hasTemplateBindings) {\n // template head's \"prev\" will point to last host binding or to 0 if no host bindings yet\n const previousNode = getTStylingRangePrev(tData[tmplHead + 1]);\n tData[index + 1] = toTStylingRange(previousNode, tmplHead);\n // if a host binding has already been registered, we need to update the next of that host\n // binding to point to this one\n if (previousNode !== 0) {\n // We need to update the template-tail value to point to us.\n tData[previousNode + 1] = setTStylingRangeNext(tData[previousNode + 1], index);\n }\n // The \"previous\" of the template binding head should point to this host binding\n tData[tmplHead + 1] = setTStylingRangePrev(tData[tmplHead + 1], index);\n } else {\n tData[index + 1] = toTStylingRange(tmplHead, 0);\n // if a host binding has already been registered, we need to update the next of that host\n // binding to point to this one\n if (tmplHead !== 0) {\n // We need to update the template-tail value to point to us.\n tData[tmplHead + 1] = setTStylingRangeNext(tData[tmplHead + 1], index);\n }\n // if we don't have template, the head points to template-tail, and needs to be advanced.\n tmplHead = index;\n }\n } else {\n // We are inserting in template section.\n // We need to set this binding's \"previous\" to the current template tail\n tData[index + 1] = toTStylingRange(tmplTail, 0);\n ngDevMode && assertEqual(tmplHead !== 0 && tmplTail === 0, false, 'Adding template bindings after hostBindings is not allowed.');\n if (tmplHead === 0) {\n tmplHead = index;\n } else {\n // We need to update the previous value \"next\" to point to this binding\n tData[tmplTail + 1] = setTStylingRangeNext(tData[tmplTail + 1], index);\n }\n tmplTail = index;\n }\n // Now we need to update / compute the duplicates.\n // Starting with our location search towards head (least priority)\n if (isKeyDuplicateOfStatic) {\n tData[index + 1] = setTStylingRangePrevDuplicate(tData[index + 1]);\n }\n markDuplicates(tData, tStylingKey, index, true);\n markDuplicates(tData, tStylingKey, index, false);\n markDuplicateOfResidualStyling(tNode, tStylingKey, tData, index, isClassBinding);\n tBindings = toTStylingRange(tmplHead, tmplTail);\n if (isClassBinding) {\n tNode.classBindings = tBindings;\n } else {\n tNode.styleBindings = tBindings;\n }\n}\n/**\n * Look into the residual styling to see if the current `tStylingKey` is duplicate of residual.\n *\n * @param tNode `TNode` where the residual is stored.\n * @param tStylingKey `TStylingKey` to store.\n * @param tData `TData` associated with the current `LView`.\n * @param index location of where `tStyleValue` should be stored (and linked into list.)\n * @param isClassBinding True if the associated `tStylingKey` as a `class` styling.\n * `tNode.classBindings` should be used (or `tNode.styleBindings` otherwise.)\n */\nfunction markDuplicateOfResidualStyling(tNode, tStylingKey, tData, index, isClassBinding) {\n const residual = isClassBinding ? tNode.residualClasses : tNode.residualStyles;\n if (residual != null /* or undefined */ && typeof tStylingKey == 'string' && keyValueArrayIndexOf(residual, tStylingKey) >= 0) {\n // We have duplicate in the residual so mark ourselves as duplicate.\n tData[index + 1] = setTStylingRangeNextDuplicate(tData[index + 1]);\n }\n}\n/**\n * Marks `TStyleValue`s as duplicates if another style binding in the list has the same\n * `TStyleValue`.\n *\n * NOTE: this function is intended to be called twice once with `isPrevDir` set to `true` and once\n * with it set to `false` to search both the previous as well as next items in the list.\n *\n * No duplicate case\n * ```\n * [style.color]\n * [style.width.px] <<- index\n * [style.height.px]\n * ```\n *\n * In the above case adding `[style.width.px]` to the existing `[style.color]` produces no\n * duplicates because `width` is not found in any other part of the linked list.\n *\n * Duplicate case\n * ```\n * [style.color]\n * [style.width.em]\n * [style.width.px] <<- index\n * ```\n * In the above case adding `[style.width.px]` will produce a duplicate with `[style.width.em]`\n * because `width` is found in the chain.\n *\n * Map case 1\n * ```\n * [style.width.px]\n * [style.color]\n * [style] <<- index\n * ```\n * In the above case adding `[style]` will produce a duplicate with any other bindings because\n * `[style]` is a Map and as such is fully dynamic and could produce `color` or `width`.\n *\n * Map case 2\n * ```\n * [style]\n * [style.width.px]\n * [style.color] <<- index\n * ```\n * In the above case adding `[style.color]` will produce a duplicate because there is already a\n * `[style]` binding which is a Map and as such is fully dynamic and could produce `color` or\n * `width`.\n *\n * NOTE: Once `[style]` (Map) is added into the system all things are mapped as duplicates.\n * NOTE: We use `style` as example, but same logic is applied to `class`es as well.\n *\n * @param tData `TData` where the linked list is stored.\n * @param tStylingKey `TStylingKeyPrimitive` which contains the value to compare to other keys in\n * the linked list.\n * @param index Starting location in the linked list to search from\n * @param isPrevDir Direction.\n * - `true` for previous (lower priority);\n * - `false` for next (higher priority).\n */\nfunction markDuplicates(tData, tStylingKey, index, isPrevDir) {\n const tStylingAtIndex = tData[index + 1];\n const isMap = tStylingKey === null;\n let cursor = isPrevDir ? getTStylingRangePrev(tStylingAtIndex) : getTStylingRangeNext(tStylingAtIndex);\n let foundDuplicate = false;\n // We keep iterating as long as we have a cursor\n // AND either:\n // - we found what we are looking for, OR\n // - we are a map in which case we have to continue searching even after we find what we were\n // looking for since we are a wild card and everything needs to be flipped to duplicate.\n while (cursor !== 0 && (foundDuplicate === false || isMap)) {\n ngDevMode && assertIndexInRange(tData, cursor);\n const tStylingValueAtCursor = tData[cursor];\n const tStyleRangeAtCursor = tData[cursor + 1];\n if (isStylingMatch(tStylingValueAtCursor, tStylingKey)) {\n foundDuplicate = true;\n tData[cursor + 1] = isPrevDir ? setTStylingRangeNextDuplicate(tStyleRangeAtCursor) : setTStylingRangePrevDuplicate(tStyleRangeAtCursor);\n }\n cursor = isPrevDir ? getTStylingRangePrev(tStyleRangeAtCursor) : getTStylingRangeNext(tStyleRangeAtCursor);\n }\n if (foundDuplicate) {\n // if we found a duplicate, than mark ourselves.\n tData[index + 1] = isPrevDir ? setTStylingRangePrevDuplicate(tStylingAtIndex) : setTStylingRangeNextDuplicate(tStylingAtIndex);\n }\n}\n/**\n * Determines if two `TStylingKey`s are a match.\n *\n * When computing whether a binding contains a duplicate, we need to compare if the instruction\n * `TStylingKey` has a match.\n *\n * Here are examples of `TStylingKey`s which match given `tStylingKeyCursor` is:\n * - `color`\n * - `color` // Match another color\n * - `null` // That means that `tStylingKey` is a `classMap`/`styleMap` instruction\n * - `['', 'color', 'other', true]` // wrapped `color` so match\n * - `['', null, 'other', true]` // wrapped `null` so match\n * - `['', 'width', 'color', 'value']` // wrapped static value contains a match on `'color'`\n * - `null` // `tStylingKeyCursor` always match as it is `classMap`/`styleMap` instruction\n *\n * @param tStylingKeyCursor\n * @param tStylingKey\n */\nfunction isStylingMatch(tStylingKeyCursor, tStylingKey) {\n ngDevMode && assertNotEqual(Array.isArray(tStylingKey), true, \"Expected that 'tStylingKey' has been unwrapped\");\n if (tStylingKeyCursor === null ||\n // If the cursor is `null` it means that we have map at that\n // location so we must assume that we have a match.\n tStylingKey == null ||\n // If `tStylingKey` is `null` then it is a map therefor assume that it\n // contains a match.\n (Array.isArray(tStylingKeyCursor) ? tStylingKeyCursor[1] : tStylingKeyCursor) === tStylingKey // If the keys match explicitly than we are a match.\n ) {\n return true;\n } else if (Array.isArray(tStylingKeyCursor) && typeof tStylingKey === 'string') {\n // if we did not find a match, but `tStylingKeyCursor` is `KeyValueArray` that means cursor has\n // statics and we need to check those as well.\n return keyValueArrayIndexOf(tStylingKeyCursor, tStylingKey) >= 0; // see if we are matching the key\n }\n return false;\n}\n\n// Global state of the parser. (This makes parser non-reentrant, but that is not an issue)\nconst parserState = {\n textEnd: 0,\n key: 0,\n keyEnd: 0,\n value: 0,\n valueEnd: 0\n};\n/**\n * Retrieves the last parsed `key` of style.\n * @param text the text to substring the key from.\n */\nfunction getLastParsedKey(text) {\n return text.substring(parserState.key, parserState.keyEnd);\n}\n/**\n * Retrieves the last parsed `value` of style.\n * @param text the text to substring the key from.\n */\nfunction getLastParsedValue(text) {\n return text.substring(parserState.value, parserState.valueEnd);\n}\n/**\n * Initializes `className` string for parsing and parses the first token.\n *\n * This function is intended to be used in this format:\n * ```ts\n * for (let i = parseClassName(text); i >= 0; i = parseClassNameNext(text, i)) {\n * const key = getLastParsedKey();\n * ...\n * }\n * ```\n * @param text `className` to parse\n * @returns index where the next invocation of `parseClassNameNext` should resume.\n */\nfunction parseClassName(text) {\n resetParserState(text);\n return parseClassNameNext(text, consumeWhitespace(text, 0, parserState.textEnd));\n}\n/**\n * Parses next `className` token.\n *\n * This function is intended to be used in this format:\n * ```ts\n * for (let i = parseClassName(text); i >= 0; i = parseClassNameNext(text, i)) {\n * const key = getLastParsedKey();\n * ...\n * }\n * ```\n *\n * @param text `className` to parse\n * @param index where the parsing should resume.\n * @returns index where the next invocation of `parseClassNameNext` should resume.\n */\nfunction parseClassNameNext(text, index) {\n const end = parserState.textEnd;\n if (end === index) {\n return -1;\n }\n index = parserState.keyEnd = consumeClassToken(text, parserState.key = index, end);\n return consumeWhitespace(text, index, end);\n}\n/**\n * Initializes `cssText` string for parsing and parses the first key/values.\n *\n * This function is intended to be used in this format:\n * ```ts\n * for (let i = parseStyle(text); i >= 0; i = parseStyleNext(text, i))) {\n * const key = getLastParsedKey();\n * const value = getLastParsedValue();\n * ...\n * }\n * ```\n * @param text `cssText` to parse\n * @returns index where the next invocation of `parseStyleNext` should resume.\n */\nfunction parseStyle(text) {\n resetParserState(text);\n return parseStyleNext(text, consumeWhitespace(text, 0, parserState.textEnd));\n}\n/**\n * Parses the next `cssText` key/values.\n *\n * This function is intended to be used in this format:\n * ```ts\n * for (let i = parseStyle(text); i >= 0; i = parseStyleNext(text, i))) {\n * const key = getLastParsedKey();\n * const value = getLastParsedValue();\n * ...\n * }\n *\n * @param text `cssText` to parse\n * @param index where the parsing should resume.\n * @returns index where the next invocation of `parseStyleNext` should resume.\n */\nfunction parseStyleNext(text, startIndex) {\n const end = parserState.textEnd;\n let index = parserState.key = consumeWhitespace(text, startIndex, end);\n if (end === index) {\n // we reached an end so just quit\n return -1;\n }\n index = parserState.keyEnd = consumeStyleKey(text, index, end);\n index = consumeSeparator(text, index, end, 58 /* CharCode.COLON */);\n index = parserState.value = consumeWhitespace(text, index, end);\n index = parserState.valueEnd = consumeStyleValue(text, index, end);\n return consumeSeparator(text, index, end, 59 /* CharCode.SEMI_COLON */);\n}\n/**\n * Reset the global state of the styling parser.\n * @param text The styling text to parse.\n */\nfunction resetParserState(text) {\n parserState.key = 0;\n parserState.keyEnd = 0;\n parserState.value = 0;\n parserState.valueEnd = 0;\n parserState.textEnd = text.length;\n}\n/**\n * Returns index of next non-whitespace character.\n *\n * @param text Text to scan\n * @param startIndex Starting index of character where the scan should start.\n * @param endIndex Ending index of character where the scan should end.\n * @returns Index of next non-whitespace character (May be the same as `start` if no whitespace at\n * that location.)\n */\nfunction consumeWhitespace(text, startIndex, endIndex) {\n while (startIndex < endIndex && text.charCodeAt(startIndex) <= 32 /* CharCode.SPACE */) {\n startIndex++;\n }\n return startIndex;\n}\n/**\n * Returns index of last char in class token.\n *\n * @param text Text to scan\n * @param startIndex Starting index of character where the scan should start.\n * @param endIndex Ending index of character where the scan should end.\n * @returns Index after last char in class token.\n */\nfunction consumeClassToken(text, startIndex, endIndex) {\n while (startIndex < endIndex && text.charCodeAt(startIndex) > 32 /* CharCode.SPACE */) {\n startIndex++;\n }\n return startIndex;\n}\n/**\n * Consumes all of the characters belonging to style key and token.\n *\n * @param text Text to scan\n * @param startIndex Starting index of character where the scan should start.\n * @param endIndex Ending index of character where the scan should end.\n * @returns Index after last style key character.\n */\nfunction consumeStyleKey(text, startIndex, endIndex) {\n let ch;\n while (startIndex < endIndex && ((ch = text.charCodeAt(startIndex)) === 45 /* CharCode.DASH */ || ch === 95 /* CharCode.UNDERSCORE */ || (ch & -33 /* CharCode.UPPER_CASE */) >= 65 /* CharCode.A */ && (ch & -33 /* CharCode.UPPER_CASE */) <= 90 /* CharCode.Z */ || ch >= 48 /* CharCode.ZERO */ && ch <= 57 /* CharCode.NINE */)) {\n startIndex++;\n }\n return startIndex;\n}\n/**\n * Consumes all whitespace and the separator `:` after the style key.\n *\n * @param text Text to scan\n * @param startIndex Starting index of character where the scan should start.\n * @param endIndex Ending index of character where the scan should end.\n * @returns Index after separator and surrounding whitespace.\n */\nfunction consumeSeparator(text, startIndex, endIndex, separator) {\n startIndex = consumeWhitespace(text, startIndex, endIndex);\n if (startIndex < endIndex) {\n if (ngDevMode && text.charCodeAt(startIndex) !== separator) {\n malformedStyleError(text, String.fromCharCode(separator), startIndex);\n }\n startIndex++;\n }\n return startIndex;\n}\n/**\n * Consumes style value honoring `url()` and `\"\"` text.\n *\n * @param text Text to scan\n * @param startIndex Starting index of character where the scan should start.\n * @param endIndex Ending index of character where the scan should end.\n * @returns Index after last style value character.\n */\nfunction consumeStyleValue(text, startIndex, endIndex) {\n let ch1 = -1; // 1st previous character\n let ch2 = -1; // 2nd previous character\n let ch3 = -1; // 3rd previous character\n let i = startIndex;\n let lastChIndex = i;\n while (i < endIndex) {\n const ch = text.charCodeAt(i++);\n if (ch === 59 /* CharCode.SEMI_COLON */) {\n return lastChIndex;\n } else if (ch === 34 /* CharCode.DOUBLE_QUOTE */ || ch === 39 /* CharCode.SINGLE_QUOTE */) {\n lastChIndex = i = consumeQuotedText(text, ch, i, endIndex);\n } else if (startIndex === i - 4 &&\n // We have seen only 4 characters so far \"URL(\" (Ignore \"foo_URL()\")\n ch3 === 85 /* CharCode.U */ && ch2 === 82 /* CharCode.R */ && ch1 === 76 /* CharCode.L */ && ch === 40 /* CharCode.OPEN_PAREN */) {\n lastChIndex = i = consumeQuotedText(text, 41 /* CharCode.CLOSE_PAREN */, i, endIndex);\n } else if (ch > 32 /* CharCode.SPACE */) {\n // if we have a non-whitespace character then capture its location\n lastChIndex = i;\n }\n ch3 = ch2;\n ch2 = ch1;\n ch1 = ch & -33 /* CharCode.UPPER_CASE */;\n }\n return lastChIndex;\n}\n/**\n * Consumes all of the quoted characters.\n *\n * @param text Text to scan\n * @param quoteCharCode CharCode of either `\"` or `'` quote or `)` for `url(...)`.\n * @param startIndex Starting index of character where the scan should start.\n * @param endIndex Ending index of character where the scan should end.\n * @returns Index after quoted characters.\n */\nfunction consumeQuotedText(text, quoteCharCode, startIndex, endIndex) {\n let ch1 = -1; // 1st previous character\n let index = startIndex;\n while (index < endIndex) {\n const ch = text.charCodeAt(index++);\n if (ch == quoteCharCode && ch1 !== 92 /* CharCode.BACK_SLASH */) {\n return index;\n }\n if (ch == 92 /* CharCode.BACK_SLASH */ && ch1 === 92 /* CharCode.BACK_SLASH */) {\n // two back slashes cancel each other out. For example `\"\\\\\"` should properly end the\n // quotation. (It should not assume that the last `\"` is escaped.)\n ch1 = 0;\n } else {\n ch1 = ch;\n }\n }\n throw ngDevMode ? malformedStyleError(text, String.fromCharCode(quoteCharCode), endIndex) : new Error();\n}\nfunction malformedStyleError(text, expecting, index) {\n ngDevMode && assertEqual(typeof text === 'string', true, 'String expected here');\n throw throwError(`Malformed style at location ${index} in string '` + text.substring(0, index) + '[>>' + text.substring(index, index + 1) + '<<]' + text.slice(index + 1) + `'. Expecting '${expecting}'.`);\n}\n\n/**\n * Update a property on a selected element.\n *\n * Operates on the element selected by index via the {@link select} instruction.\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled\n *\n * @param propName Name of property. Because it is going to DOM, this is not subject to\n * renaming as part of minification.\n * @param value New value to write.\n * @param sanitizer An optional function used to sanitize the value.\n * @returns This function returns itself so that it may be chained\n * (e.g. `property('name', ctx.name)('title', ctx.title)`)\n *\n * @codeGenApi\n */\nfunction ɵɵproperty(propName, value, sanitizer) {\n const lView = getLView();\n const bindingIndex = nextBindingIndex();\n if (bindingUpdated(lView, bindingIndex, value)) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, value, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);\n }\n return ɵɵproperty;\n}\n/**\n * Given `<div style=\"...\" my-dir>` and `MyDir` with `@Input('style')` we need to write to\n * directive input.\n */\nfunction setDirectiveInputsWhichShadowsStyling(tView, tNode, lView, value, isClassBased) {\n // We support both 'class' and `className` hence the fallback.\n setAllInputsForProperty(tNode, tView, lView, isClassBased ? 'class' : 'style', value);\n}\n\n/**\n * Update a style binding on an element with the provided value.\n *\n * If the style value is falsy then it will be removed from the element\n * (or assigned a different value depending if there are any styles placed\n * on the element with `styleMap` or any static styles that are\n * present from when the element was created with `styling`).\n *\n * Note that the styling element is updated as part of `stylingApply`.\n *\n * @param prop A valid CSS property.\n * @param value New value to write (`null` or an empty string to remove).\n * @param suffix Optional suffix. Used with scalar values to add unit such as `px`.\n *\n * Note that this will apply the provided style value to the host element if this function is called\n * within a host binding function.\n *\n * @codeGenApi\n */\nfunction ɵɵstyleProp(prop, value, suffix) {\n checkStylingProperty(prop, value, suffix, false);\n return ɵɵstyleProp;\n}\n/**\n * Update a class binding on an element with the provided value.\n *\n * This instruction is meant to handle the `[class.foo]=\"exp\"` case and,\n * therefore, the class binding itself must already be allocated using\n * `styling` within the creation block.\n *\n * @param prop A valid CSS class (only one).\n * @param value A true/false value which will turn the class on or off.\n *\n * Note that this will apply the provided class value to the host element if this function\n * is called within a host binding function.\n *\n * @codeGenApi\n */\nfunction ɵɵclassProp(className, value) {\n checkStylingProperty(className, value, null, true);\n return ɵɵclassProp;\n}\n/**\n * Update style bindings using an object literal on an element.\n *\n * This instruction is meant to apply styling via the `[style]=\"exp\"` template bindings.\n * When styles are applied to the element they will then be updated with respect to\n * any styles/classes set via `styleProp`. If any styles are set to falsy\n * then they will be removed from the element.\n *\n * Note that the styling instruction will not be applied until `stylingApply` is called.\n *\n * @param styles A key/value style map of the styles that will be applied to the given element.\n * Any missing styles (that have already been applied to the element beforehand) will be\n * removed (unset) from the element's styling.\n *\n * Note that this will apply the provided styleMap value to the host element if this function\n * is called within a host binding.\n *\n * @codeGenApi\n */\nfunction ɵɵstyleMap(styles) {\n checkStylingMap(styleKeyValueArraySet, styleStringParser, styles, false);\n}\n/**\n * Parse text as style and add values to KeyValueArray.\n *\n * This code is pulled out to a separate function so that it can be tree shaken away if it is not\n * needed. It is only referenced from `ɵɵstyleMap`.\n *\n * @param keyValueArray KeyValueArray to add parsed values to.\n * @param text text to parse.\n */\nfunction styleStringParser(keyValueArray, text) {\n for (let i = parseStyle(text); i >= 0; i = parseStyleNext(text, i)) {\n styleKeyValueArraySet(keyValueArray, getLastParsedKey(text), getLastParsedValue(text));\n }\n}\n/**\n * Update class bindings using an object literal or class-string on an element.\n *\n * This instruction is meant to apply styling via the `[class]=\"exp\"` template bindings.\n * When classes are applied to the element they will then be updated with\n * respect to any styles/classes set via `classProp`. If any\n * classes are set to falsy then they will be removed from the element.\n *\n * Note that the styling instruction will not be applied until `stylingApply` is called.\n * Note that this will the provided classMap value to the host element if this function is called\n * within a host binding.\n *\n * @param classes A key/value map or string of CSS classes that will be added to the\n * given element. Any missing classes (that have already been applied to the element\n * beforehand) will be removed (unset) from the element's list of CSS classes.\n *\n * @codeGenApi\n */\nfunction ɵɵclassMap(classes) {\n checkStylingMap(classKeyValueArraySet, classStringParser, classes, true);\n}\n/**\n * Parse text as class and add values to KeyValueArray.\n *\n * This code is pulled out to a separate function so that it can be tree shaken away if it is not\n * needed. It is only referenced from `ɵɵclassMap`.\n *\n * @param keyValueArray KeyValueArray to add parsed values to.\n * @param text text to parse.\n */\nfunction classStringParser(keyValueArray, text) {\n for (let i = parseClassName(text); i >= 0; i = parseClassNameNext(text, i)) {\n keyValueArraySet(keyValueArray, getLastParsedKey(text), true);\n }\n}\n/**\n * Common code between `ɵɵclassProp` and `ɵɵstyleProp`.\n *\n * @param prop property name.\n * @param value binding value.\n * @param suffix suffix for the property (e.g. `em` or `px`)\n * @param isClassBased `true` if `class` change (`false` if `style`)\n */\nfunction checkStylingProperty(prop, value, suffix, isClassBased) {\n const lView = getLView();\n const tView = getTView();\n // Styling instructions use 2 slots per binding.\n // 1. one for the value / TStylingKey\n // 2. one for the intermittent-value / TStylingRange\n const bindingIndex = incrementBindingIndex(2);\n if (tView.firstUpdatePass) {\n stylingFirstUpdatePass(tView, prop, bindingIndex, isClassBased);\n }\n if (value !== NO_CHANGE && bindingUpdated(lView, bindingIndex, value)) {\n const tNode = tView.data[getSelectedIndex()];\n updateStyling(tView, tNode, lView, lView[RENDERER], prop, lView[bindingIndex + 1] = normalizeSuffix(value, suffix), isClassBased, bindingIndex);\n }\n}\n/**\n * Common code between `ɵɵclassMap` and `ɵɵstyleMap`.\n *\n * @param keyValueArraySet (See `keyValueArraySet` in \"util/array_utils\") Gets passed in as a\n * function so that `style` can be processed. This is done for tree shaking purposes.\n * @param stringParser Parser used to parse `value` if `string`. (Passed in as `style` and `class`\n * have different parsers.)\n * @param value bound value from application\n * @param isClassBased `true` if `class` change (`false` if `style`)\n */\nfunction checkStylingMap(keyValueArraySet, stringParser, value, isClassBased) {\n const tView = getTView();\n const bindingIndex = incrementBindingIndex(2);\n if (tView.firstUpdatePass) {\n stylingFirstUpdatePass(tView, null, bindingIndex, isClassBased);\n }\n const lView = getLView();\n if (value !== NO_CHANGE && bindingUpdated(lView, bindingIndex, value)) {\n // `getSelectedIndex()` should be here (rather than in instruction) so that it is guarded by the\n // if so as not to read unnecessarily.\n const tNode = tView.data[getSelectedIndex()];\n if (hasStylingInputShadow(tNode, isClassBased) && !isInHostBindings(tView, bindingIndex)) {\n if (ngDevMode) {\n // verify that if we are shadowing then `TData` is appropriately marked so that we skip\n // processing this binding in styling resolution.\n const tStylingKey = tView.data[bindingIndex];\n assertEqual(Array.isArray(tStylingKey) ? tStylingKey[1] : tStylingKey, false, \"Styling linked list shadow input should be marked as 'false'\");\n }\n // VE does not concatenate the static portion like we are doing here.\n // Instead VE just ignores the static completely if dynamic binding is present.\n // Because of locality we have already set the static portion because we don't know if there\n // is a dynamic portion until later. If we would ignore the static portion it would look like\n // the binding has removed it. This would confuse `[ngStyle]`/`[ngClass]` to do the wrong\n // thing as it would think that the static portion was removed. For this reason we\n // concatenate it so that `[ngStyle]`/`[ngClass]` can continue to work on changed.\n let staticPrefix = isClassBased ? tNode.classesWithoutHost : tNode.stylesWithoutHost;\n ngDevMode && isClassBased === false && staticPrefix !== null && assertEqual(staticPrefix.endsWith(';'), true, \"Expecting static portion to end with ';'\");\n if (staticPrefix !== null) {\n // We want to make sure that falsy values of `value` become empty strings.\n value = concatStringsWithSpace(staticPrefix, value ? value : '');\n }\n // Given `<div [style] my-dir>` such that `my-dir` has `@Input('style')`.\n // This takes over the `[style]` binding. (Same for `[class]`)\n setDirectiveInputsWhichShadowsStyling(tView, tNode, lView, value, isClassBased);\n } else {\n updateStylingMap(tView, tNode, lView, lView[RENDERER], lView[bindingIndex + 1], lView[bindingIndex + 1] = toStylingKeyValueArray(keyValueArraySet, stringParser, value), isClassBased, bindingIndex);\n }\n }\n}\n/**\n * Determines when the binding is in `hostBindings` section\n *\n * @param tView Current `TView`\n * @param bindingIndex index of binding which we would like if it is in `hostBindings`\n */\nfunction isInHostBindings(tView, bindingIndex) {\n // All host bindings are placed after the expando section.\n return bindingIndex >= tView.expandoStartIndex;\n}\n/**\n * Collects the necessary information to insert the binding into a linked list of style bindings\n * using `insertTStylingBinding`.\n *\n * @param tView `TView` where the binding linked list will be stored.\n * @param tStylingKey Property/key of the binding.\n * @param bindingIndex Index of binding associated with the `prop`\n * @param isClassBased `true` if `class` change (`false` if `style`)\n */\nfunction stylingFirstUpdatePass(tView, tStylingKey, bindingIndex, isClassBased) {\n ngDevMode && assertFirstUpdatePass(tView);\n const tData = tView.data;\n if (tData[bindingIndex + 1] === null) {\n // The above check is necessary because we don't clear first update pass until first successful\n // (no exception) template execution. This prevents the styling instruction from double adding\n // itself to the list.\n // `getSelectedIndex()` should be here (rather than in instruction) so that it is guarded by the\n // if so as not to read unnecessarily.\n const tNode = tData[getSelectedIndex()];\n ngDevMode && assertDefined(tNode, 'TNode expected');\n const isHostBindings = isInHostBindings(tView, bindingIndex);\n if (hasStylingInputShadow(tNode, isClassBased) && tStylingKey === null && !isHostBindings) {\n // `tStylingKey === null` implies that we are either `[style]` or `[class]` binding.\n // If there is a directive which uses `@Input('style')` or `@Input('class')` than\n // we need to neutralize this binding since that directive is shadowing it.\n // We turn this into a noop by setting the key to `false`\n tStylingKey = false;\n }\n tStylingKey = wrapInStaticStylingKey(tData, tNode, tStylingKey, isClassBased);\n insertTStylingBinding(tData, tNode, tStylingKey, bindingIndex, isHostBindings, isClassBased);\n }\n}\n/**\n * Adds static styling information to the binding if applicable.\n *\n * The linked list of styles not only stores the list and keys, but also stores static styling\n * information on some of the keys. This function determines if the key should contain the styling\n * information and computes it.\n *\n * See `TStylingStatic` for more details.\n *\n * @param tData `TData` where the linked list is stored.\n * @param tNode `TNode` for which the styling is being computed.\n * @param stylingKey `TStylingKeyPrimitive` which may need to be wrapped into `TStylingKey`\n * @param isClassBased `true` if `class` (`false` if `style`)\n */\nfunction wrapInStaticStylingKey(tData, tNode, stylingKey, isClassBased) {\n const hostDirectiveDef = getCurrentDirectiveDef(tData);\n let residual = isClassBased ? tNode.residualClasses : tNode.residualStyles;\n if (hostDirectiveDef === null) {\n // We are in template node.\n // If template node already had styling instruction then it has already collected the static\n // styling and there is no need to collect them again. We know that we are the first styling\n // instruction because the `TNode.*Bindings` points to 0 (nothing has been inserted yet).\n const isFirstStylingInstructionInTemplate = (isClassBased ? tNode.classBindings : tNode.styleBindings) === 0;\n if (isFirstStylingInstructionInTemplate) {\n // It would be nice to be able to get the statics from `mergeAttrs`, however, at this point\n // they are already merged and it would not be possible to figure which property belongs where\n // in the priority.\n stylingKey = collectStylingFromDirectives(null, tData, tNode, stylingKey, isClassBased);\n stylingKey = collectStylingFromTAttrs(stylingKey, tNode.attrs, isClassBased);\n // We know that if we have styling binding in template we can't have residual.\n residual = null;\n }\n } else {\n // We are in host binding node and there was no binding instruction in template node.\n // This means that we need to compute the residual.\n const directiveStylingLast = tNode.directiveStylingLast;\n const isFirstStylingInstructionInHostBinding = directiveStylingLast === -1 || tData[directiveStylingLast] !== hostDirectiveDef;\n if (isFirstStylingInstructionInHostBinding) {\n stylingKey = collectStylingFromDirectives(hostDirectiveDef, tData, tNode, stylingKey, isClassBased);\n if (residual === null) {\n // - If `null` than either:\n // - Template styling instruction already ran and it has consumed the static\n // styling into its `TStylingKey` and so there is no need to update residual. Instead\n // we need to update the `TStylingKey` associated with the first template node\n // instruction. OR\n // - Some other styling instruction ran and determined that there are no residuals\n let templateStylingKey = getTemplateHeadTStylingKey(tData, tNode, isClassBased);\n if (templateStylingKey !== undefined && Array.isArray(templateStylingKey)) {\n // Only recompute if `templateStylingKey` had static values. (If no static value found\n // then there is nothing to do since this operation can only produce less static keys, not\n // more.)\n templateStylingKey = collectStylingFromDirectives(null, tData, tNode, templateStylingKey[1] /* unwrap previous statics */, isClassBased);\n templateStylingKey = collectStylingFromTAttrs(templateStylingKey, tNode.attrs, isClassBased);\n setTemplateHeadTStylingKey(tData, tNode, isClassBased, templateStylingKey);\n }\n } else {\n // We only need to recompute residual if it is not `null`.\n // - If existing residual (implies there was no template styling). This means that some of\n // the statics may have moved from the residual to the `stylingKey` and so we have to\n // recompute.\n // - If `undefined` this is the first time we are running.\n residual = collectResidual(tData, tNode, isClassBased);\n }\n }\n }\n if (residual !== undefined) {\n isClassBased ? tNode.residualClasses = residual : tNode.residualStyles = residual;\n }\n return stylingKey;\n}\n/**\n * Retrieve the `TStylingKey` for the template styling instruction.\n *\n * This is needed since `hostBinding` styling instructions are inserted after the template\n * instruction. While the template instruction needs to update the residual in `TNode` the\n * `hostBinding` instructions need to update the `TStylingKey` of the template instruction because\n * the template instruction is downstream from the `hostBindings` instructions.\n *\n * @param tData `TData` where the linked list is stored.\n * @param tNode `TNode` for which the styling is being computed.\n * @param isClassBased `true` if `class` (`false` if `style`)\n * @return `TStylingKey` if found or `undefined` if not found.\n */\nfunction getTemplateHeadTStylingKey(tData, tNode, isClassBased) {\n const bindings = isClassBased ? tNode.classBindings : tNode.styleBindings;\n if (getTStylingRangeNext(bindings) === 0) {\n // There does not seem to be a styling instruction in the `template`.\n return undefined;\n }\n return tData[getTStylingRangePrev(bindings)];\n}\n/**\n * Update the `TStylingKey` of the first template instruction in `TNode`.\n *\n * Logically `hostBindings` styling instructions are of lower priority than that of the template.\n * However, they execute after the template styling instructions. This means that they get inserted\n * in front of the template styling instructions.\n *\n * If we have a template styling instruction and a new `hostBindings` styling instruction is\n * executed it means that it may need to steal static fields from the template instruction. This\n * method allows us to update the first template instruction `TStylingKey` with a new value.\n *\n * Assume:\n * ```angular-ts\n * <div my-dir style=\"color: red\" [style.color]=\"tmplExp\"></div>\n *\n * @Directive({\n * host: {\n * 'style': 'width: 100px',\n * '[style.color]': 'dirExp',\n * }\n * })\n * class MyDir {}\n * ```\n *\n * when `[style.color]=\"tmplExp\"` executes it creates this data structure.\n * ```ts\n * ['', 'color', 'color', 'red', 'width', '100px'],\n * ```\n *\n * The reason for this is that the template instruction does not know if there are styling\n * instructions and must assume that there are none and must collect all of the static styling.\n * (both\n * `color' and 'width`)\n *\n * When `'[style.color]': 'dirExp',` executes we need to insert a new data into the linked list.\n * ```ts\n * ['', 'color', 'width', '100px'], // newly inserted\n * ['', 'color', 'color', 'red', 'width', '100px'], // this is wrong\n * ```\n *\n * Notice that the template statics is now wrong as it incorrectly contains `width` so we need to\n * update it like so:\n * ```ts\n * ['', 'color', 'width', '100px'],\n * ['', 'color', 'color', 'red'], // UPDATE\n * ```\n *\n * @param tData `TData` where the linked list is stored.\n * @param tNode `TNode` for which the styling is being computed.\n * @param isClassBased `true` if `class` (`false` if `style`)\n * @param tStylingKey New `TStylingKey` which is replacing the old one.\n */\nfunction setTemplateHeadTStylingKey(tData, tNode, isClassBased, tStylingKey) {\n const bindings = isClassBased ? tNode.classBindings : tNode.styleBindings;\n ngDevMode && assertNotEqual(getTStylingRangeNext(bindings), 0, 'Expecting to have at least one template styling binding.');\n tData[getTStylingRangePrev(bindings)] = tStylingKey;\n}\n/**\n * Collect all static values after the current `TNode.directiveStylingLast` index.\n *\n * Collect the remaining styling information which has not yet been collected by an existing\n * styling instruction.\n *\n * @param tData `TData` where the `DirectiveDefs` are stored.\n * @param tNode `TNode` which contains the directive range.\n * @param isClassBased `true` if `class` (`false` if `style`)\n */\nfunction collectResidual(tData, tNode, isClassBased) {\n let residual = undefined;\n const directiveEnd = tNode.directiveEnd;\n ngDevMode && assertNotEqual(tNode.directiveStylingLast, -1, 'By the time this function gets called at least one hostBindings-node styling instruction must have executed.');\n // We add `1 + tNode.directiveStart` because we need to skip the current directive (as we are\n // collecting things after the last `hostBindings` directive which had a styling instruction.)\n for (let i = 1 + tNode.directiveStylingLast; i < directiveEnd; i++) {\n const attrs = tData[i].hostAttrs;\n residual = collectStylingFromTAttrs(residual, attrs, isClassBased);\n }\n return collectStylingFromTAttrs(residual, tNode.attrs, isClassBased);\n}\n/**\n * Collect the static styling information with lower priority than `hostDirectiveDef`.\n *\n * (This is opposite of residual styling.)\n *\n * @param hostDirectiveDef `DirectiveDef` for which we want to collect lower priority static\n * styling. (Or `null` if template styling)\n * @param tData `TData` where the linked list is stored.\n * @param tNode `TNode` for which the styling is being computed.\n * @param stylingKey Existing `TStylingKey` to update or wrap.\n * @param isClassBased `true` if `class` (`false` if `style`)\n */\nfunction collectStylingFromDirectives(hostDirectiveDef, tData, tNode, stylingKey, isClassBased) {\n // We need to loop because there can be directives which have `hostAttrs` but don't have\n // `hostBindings` so this loop catches up to the current directive..\n let currentDirective = null;\n const directiveEnd = tNode.directiveEnd;\n let directiveStylingLast = tNode.directiveStylingLast;\n if (directiveStylingLast === -1) {\n directiveStylingLast = tNode.directiveStart;\n } else {\n directiveStylingLast++;\n }\n while (directiveStylingLast < directiveEnd) {\n currentDirective = tData[directiveStylingLast];\n ngDevMode && assertDefined(currentDirective, 'expected to be defined');\n stylingKey = collectStylingFromTAttrs(stylingKey, currentDirective.hostAttrs, isClassBased);\n if (currentDirective === hostDirectiveDef) break;\n directiveStylingLast++;\n }\n if (hostDirectiveDef !== null) {\n // we only advance the styling cursor if we are collecting data from host bindings.\n // Template executes before host bindings and so if we would update the index,\n // host bindings would not get their statics.\n tNode.directiveStylingLast = directiveStylingLast;\n }\n return stylingKey;\n}\n/**\n * Convert `TAttrs` into `TStylingStatic`.\n *\n * @param stylingKey existing `TStylingKey` to update or wrap.\n * @param attrs `TAttributes` to process.\n * @param isClassBased `true` if `class` (`false` if `style`)\n */\nfunction collectStylingFromTAttrs(stylingKey, attrs, isClassBased) {\n const desiredMarker = isClassBased ? 1 /* AttributeMarker.Classes */ : 2 /* AttributeMarker.Styles */;\n let currentMarker = -1 /* AttributeMarker.ImplicitAttributes */;\n if (attrs !== null) {\n for (let i = 0; i < attrs.length; i++) {\n const item = attrs[i];\n if (typeof item === 'number') {\n currentMarker = item;\n } else {\n if (currentMarker === desiredMarker) {\n if (!Array.isArray(stylingKey)) {\n stylingKey = stylingKey === undefined ? [] : ['', stylingKey];\n }\n keyValueArraySet(stylingKey, item, isClassBased ? true : attrs[++i]);\n }\n }\n }\n }\n return stylingKey === undefined ? null : stylingKey;\n}\n/**\n * Convert user input to `KeyValueArray`.\n *\n * This function takes user input which could be `string`, Object literal, or iterable and converts\n * it into a consistent representation. The output of this is `KeyValueArray` (which is an array\n * where\n * even indexes contain keys and odd indexes contain values for those keys).\n *\n * The advantage of converting to `KeyValueArray` is that we can perform diff in an input\n * independent\n * way.\n * (ie we can compare `foo bar` to `['bar', 'baz'] and determine a set of changes which need to be\n * applied)\n *\n * The fact that `KeyValueArray` is sorted is very important because it allows us to compute the\n * difference in linear fashion without the need to allocate any additional data.\n *\n * For example if we kept this as a `Map` we would have to iterate over previous `Map` to determine\n * which values need to be deleted, over the new `Map` to determine additions, and we would have to\n * keep additional `Map` to keep track of duplicates or items which have not yet been visited.\n *\n * @param keyValueArraySet (See `keyValueArraySet` in \"util/array_utils\") Gets passed in as a\n * function so that `style` can be processed. This is done\n * for tree shaking purposes.\n * @param stringParser The parser is passed in so that it will be tree shakable. See\n * `styleStringParser` and `classStringParser`\n * @param value The value to parse/convert to `KeyValueArray`\n */\nfunction toStylingKeyValueArray(keyValueArraySet, stringParser, value) {\n if (value == null /*|| value === undefined */ || value === '') return EMPTY_ARRAY;\n const styleKeyValueArray = [];\n const unwrappedValue = unwrapSafeValue(value);\n if (Array.isArray(unwrappedValue)) {\n for (let i = 0; i < unwrappedValue.length; i++) {\n keyValueArraySet(styleKeyValueArray, unwrappedValue[i], true);\n }\n } else if (typeof unwrappedValue === 'object') {\n for (const key in unwrappedValue) {\n if (unwrappedValue.hasOwnProperty(key)) {\n keyValueArraySet(styleKeyValueArray, key, unwrappedValue[key]);\n }\n }\n } else if (typeof unwrappedValue === 'string') {\n stringParser(styleKeyValueArray, unwrappedValue);\n } else {\n ngDevMode && throwError('Unsupported styling type ' + typeof unwrappedValue + ': ' + unwrappedValue);\n }\n return styleKeyValueArray;\n}\n/**\n * Set a `value` for a `key`.\n *\n * See: `keyValueArraySet` for details\n *\n * @param keyValueArray KeyValueArray to add to.\n * @param key Style key to add.\n * @param value The value to set.\n */\nfunction styleKeyValueArraySet(keyValueArray, key, value) {\n keyValueArraySet(keyValueArray, key, unwrapSafeValue(value));\n}\n/**\n * Class-binding-specific function for setting the `value` for a `key`.\n *\n * See: `keyValueArraySet` for details\n *\n * @param keyValueArray KeyValueArray to add to.\n * @param key Style key to add.\n * @param value The value to set.\n */\nfunction classKeyValueArraySet(keyValueArray, key, value) {\n // We use `classList.add` to eventually add the CSS classes to the DOM node. Any value passed into\n // `add` is stringified and added to the `class` attribute, e.g. even null, undefined or numbers\n // will be added. Stringify the key here so that our internal data structure matches the value in\n // the DOM. The only exceptions are empty strings and strings that contain spaces for which\n // the browser throws an error. We ignore such values, because the error is somewhat cryptic.\n const stringKey = String(key);\n if (stringKey !== '' && !stringKey.includes(' ')) {\n keyValueArraySet(keyValueArray, stringKey, value);\n }\n}\n/**\n * Update map based styling.\n *\n * Map based styling could be anything which contains more than one binding. For example `string`,\n * or object literal. Dealing with all of these types would complicate the logic so\n * instead this function expects that the complex input is first converted into normalized\n * `KeyValueArray`. The advantage of normalization is that we get the values sorted, which makes it\n * very cheap to compute deltas between the previous and current value.\n *\n * @param tView Associated `TView.data` contains the linked list of binding priorities.\n * @param tNode `TNode` where the binding is located.\n * @param lView `LView` contains the values associated with other styling binding at this `TNode`.\n * @param renderer Renderer to use if any updates.\n * @param oldKeyValueArray Previous value represented as `KeyValueArray`\n * @param newKeyValueArray Current value represented as `KeyValueArray`\n * @param isClassBased `true` if `class` (`false` if `style`)\n * @param bindingIndex Binding index of the binding.\n */\nfunction updateStylingMap(tView, tNode, lView, renderer, oldKeyValueArray, newKeyValueArray, isClassBased, bindingIndex) {\n if (oldKeyValueArray === NO_CHANGE) {\n // On first execution the oldKeyValueArray is NO_CHANGE => treat it as empty KeyValueArray.\n oldKeyValueArray = EMPTY_ARRAY;\n }\n let oldIndex = 0;\n let newIndex = 0;\n let oldKey = 0 < oldKeyValueArray.length ? oldKeyValueArray[0] : null;\n let newKey = 0 < newKeyValueArray.length ? newKeyValueArray[0] : null;\n while (oldKey !== null || newKey !== null) {\n ngDevMode && assertLessThan(oldIndex, 999, 'Are we stuck in infinite loop?');\n ngDevMode && assertLessThan(newIndex, 999, 'Are we stuck in infinite loop?');\n const oldValue = oldIndex < oldKeyValueArray.length ? oldKeyValueArray[oldIndex + 1] : undefined;\n const newValue = newIndex < newKeyValueArray.length ? newKeyValueArray[newIndex + 1] : undefined;\n let setKey = null;\n let setValue = undefined;\n if (oldKey === newKey) {\n // UPDATE: Keys are equal => new value is overwriting old value.\n oldIndex += 2;\n newIndex += 2;\n if (oldValue !== newValue) {\n setKey = newKey;\n setValue = newValue;\n }\n } else if (newKey === null || oldKey !== null && oldKey < newKey) {\n // DELETE: oldKey key is missing or we did not find the oldKey in the newValue\n // (because the keyValueArray is sorted and `newKey` is found later alphabetically).\n // `\"background\" < \"color\"` so we need to delete `\"background\"` because it is not found in the\n // new array.\n oldIndex += 2;\n setKey = oldKey;\n } else {\n // CREATE: newKey's is earlier alphabetically than oldKey's (or no oldKey) => we have new key.\n // `\"color\" > \"background\"` so we need to add `color` because it is in new array but not in\n // old array.\n ngDevMode && assertDefined(newKey, 'Expecting to have a valid key');\n newIndex += 2;\n setKey = newKey;\n setValue = newValue;\n }\n if (setKey !== null) {\n updateStyling(tView, tNode, lView, renderer, setKey, setValue, isClassBased, bindingIndex);\n }\n oldKey = oldIndex < oldKeyValueArray.length ? oldKeyValueArray[oldIndex] : null;\n newKey = newIndex < newKeyValueArray.length ? newKeyValueArray[newIndex] : null;\n }\n}\n/**\n * Update a simple (property name) styling.\n *\n * This function takes `prop` and updates the DOM to that value. The function takes the binding\n * value as well as binding priority into consideration to determine which value should be written\n * to DOM. (For example it may be determined that there is a higher priority overwrite which blocks\n * the DOM write, or if the value goes to `undefined` a lower priority overwrite may be consulted.)\n *\n * @param tView Associated `TView.data` contains the linked list of binding priorities.\n * @param tNode `TNode` where the binding is located.\n * @param lView `LView` contains the values associated with other styling binding at this `TNode`.\n * @param renderer Renderer to use if any updates.\n * @param prop Either style property name or a class name.\n * @param value Either style value for `prop` or `true`/`false` if `prop` is class.\n * @param isClassBased `true` if `class` (`false` if `style`)\n * @param bindingIndex Binding index of the binding.\n */\nfunction updateStyling(tView, tNode, lView, renderer, prop, value, isClassBased, bindingIndex) {\n if (!(tNode.type & 3 /* TNodeType.AnyRNode */)) {\n // It is possible to have styling on non-elements (such as ng-container).\n // This is rare, but it does happen. In such a case, just ignore the binding.\n return;\n }\n const tData = tView.data;\n const tRange = tData[bindingIndex + 1];\n const higherPriorityValue = getTStylingRangeNextDuplicate(tRange) ? findStylingValue(tData, tNode, lView, prop, getTStylingRangeNext(tRange), isClassBased) : undefined;\n if (!isStylingValuePresent(higherPriorityValue)) {\n // We don't have a next duplicate, or we did not find a duplicate value.\n if (!isStylingValuePresent(value)) {\n // We should delete current value or restore to lower priority value.\n if (getTStylingRangePrevDuplicate(tRange)) {\n // We have a possible prev duplicate, let's retrieve it.\n value = findStylingValue(tData, null, lView, prop, bindingIndex, isClassBased);\n }\n }\n const rNode = getNativeByIndex(getSelectedIndex(), lView);\n applyStyling(renderer, isClassBased, rNode, prop, value);\n }\n}\n/**\n * Search for styling value with higher priority which is overwriting current value, or a\n * value of lower priority to which we should fall back if the value is `undefined`.\n *\n * When value is being applied at a location, related values need to be consulted.\n * - If there is a higher priority binding, we should be using that one instead.\n * For example `<div [style]=\"{color:exp1}\" [style.color]=\"exp2\">` change to `exp1`\n * requires that we check `exp2` to see if it is set to value other than `undefined`.\n * - If there is a lower priority binding and we are changing to `undefined`\n * For example `<div [style]=\"{color:exp1}\" [style.color]=\"exp2\">` change to `exp2` to\n * `undefined` requires that we check `exp1` (and static values) and use that as new value.\n *\n * NOTE: The styling stores two values.\n * 1. The raw value which came from the application is stored at `index + 0` location. (This value\n * is used for dirty checking).\n * 2. The normalized value is stored at `index + 1`.\n *\n * @param tData `TData` used for traversing the priority.\n * @param tNode `TNode` to use for resolving static styling. Also controls search direction.\n * - `TNode` search next and quit as soon as `isStylingValuePresent(value)` is true.\n * If no value found consult `tNode.residualStyle`/`tNode.residualClass` for default value.\n * - `null` search prev and go all the way to end. Return last value where\n * `isStylingValuePresent(value)` is true.\n * @param lView `LView` used for retrieving the actual values.\n * @param prop Property which we are interested in.\n * @param index Starting index in the linked list of styling bindings where the search should start.\n * @param isClassBased `true` if `class` (`false` if `style`)\n */\nfunction findStylingValue(tData, tNode, lView, prop, index, isClassBased) {\n // `TNode` to use for resolving static styling. Also controls search direction.\n // - `TNode` search next and quit as soon as `isStylingValuePresent(value)` is true.\n // If no value found consult `tNode.residualStyle`/`tNode.residualClass` for default value.\n // - `null` search prev and go all the way to end. Return last value where\n // `isStylingValuePresent(value)` is true.\n const isPrevDirection = tNode === null;\n let value = undefined;\n while (index > 0) {\n const rawKey = tData[index];\n const containsStatics = Array.isArray(rawKey);\n // Unwrap the key if we contain static values.\n const key = containsStatics ? rawKey[1] : rawKey;\n const isStylingMap = key === null;\n let valueAtLViewIndex = lView[index + 1];\n if (valueAtLViewIndex === NO_CHANGE) {\n // In firstUpdatePass the styling instructions create a linked list of styling.\n // On subsequent passes it is possible for a styling instruction to try to read a binding\n // which\n // has not yet executed. In that case we will find `NO_CHANGE` and we should assume that\n // we have `undefined` (or empty array in case of styling-map instruction) instead. This\n // allows the resolution to apply the value (which may later be overwritten when the\n // binding actually executes.)\n valueAtLViewIndex = isStylingMap ? EMPTY_ARRAY : undefined;\n }\n let currentValue = isStylingMap ? keyValueArrayGet(valueAtLViewIndex, prop) : key === prop ? valueAtLViewIndex : undefined;\n if (containsStatics && !isStylingValuePresent(currentValue)) {\n currentValue = keyValueArrayGet(rawKey, prop);\n }\n if (isStylingValuePresent(currentValue)) {\n value = currentValue;\n if (isPrevDirection) {\n return value;\n }\n }\n const tRange = tData[index + 1];\n index = isPrevDirection ? getTStylingRangePrev(tRange) : getTStylingRangeNext(tRange);\n }\n if (tNode !== null) {\n // in case where we are going in next direction AND we did not find anything, we need to\n // consult residual styling\n let residual = isClassBased ? tNode.residualClasses : tNode.residualStyles;\n if (residual != null /** OR residual !=== undefined */) {\n value = keyValueArrayGet(residual, prop);\n }\n }\n return value;\n}\n/**\n * Determines if the binding value should be used (or if the value is 'undefined' and hence priority\n * resolution should be used.)\n *\n * @param value Binding style value.\n */\nfunction isStylingValuePresent(value) {\n // Currently only `undefined` value is considered non-binding. That is `undefined` says I don't\n // have an opinion as to what this binding should be and you should consult other bindings by\n // priority to determine the valid value.\n // This is extracted into a single function so that we have a single place to control this.\n return value !== undefined;\n}\n/**\n * Normalizes and/or adds a suffix to the value.\n *\n * If value is `null`/`undefined` no suffix is added\n * @param value\n * @param suffix\n */\nfunction normalizeSuffix(value, suffix) {\n if (value == null || value === '') {\n // do nothing\n // Do not add the suffix if the value is going to be empty.\n // As it produce invalid CSS, which the browsers will automatically omit but Domino will not.\n // Example: `\"left\": \"px;\"` instead of `\"left\": \"\"`.\n } else if (typeof suffix === 'string') {\n value = value + suffix;\n } else if (typeof value === 'object') {\n value = stringify(unwrapSafeValue(value));\n }\n return value;\n}\n/**\n * Tests if the `TNode` has input shadow.\n *\n * An input shadow is when a directive steals (shadows) the input by using `@Input('style')` or\n * `@Input('class')` as input.\n *\n * @param tNode `TNode` which we would like to see if it has shadow.\n * @param isClassBased `true` if `class` (`false` if `style`)\n */\nfunction hasStylingInputShadow(tNode, isClassBased) {\n return (tNode.flags & (isClassBased ? 8 /* TNodeFlags.hasClassInput */ : 16 /* TNodeFlags.hasStyleInput */)) !== 0;\n}\n\n/**\n *\n * Update an interpolated class on an element with single bound value surrounded by text.\n *\n * Used when the value passed to a property has 1 interpolated value in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate1('prefix', v0, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate1(prefix, v0, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation1(lView, prefix, v0, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n *\n * Update an interpolated class on an element with 2 bound values surrounded by text.\n *\n * Used when the value passed to a property has 2 interpolated values in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}-{{v1}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate2('prefix', v0, '-', v1, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate2(prefix, v0, i0, v1, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n *\n * Update an interpolated class on an element with 3 bound values surrounded by text.\n *\n * Used when the value passed to a property has 3 interpolated values in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}-{{v1}}-{{v2}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate3(\n * 'prefix', v0, '-', v1, '-', v2, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate3(prefix, v0, i0, v1, i1, v2, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n *\n * Update an interpolated class on an element with 4 bound values surrounded by text.\n *\n * Used when the value passed to a property has 4 interpolated values in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate4(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n *\n * Update an interpolated class on an element with 5 bound values surrounded by text.\n *\n * Used when the value passed to a property has 5 interpolated values in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate5(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n *\n * Update an interpolated class on an element with 6 bound values surrounded by text.\n *\n * Used when the value passed to a property has 6 interpolated values in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate6(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n *\n * Update an interpolated class on an element with 7 bound values surrounded by text.\n *\n * Used when the value passed to a property has 7 interpolated values in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate7(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n *\n * Update an interpolated class on an element with 8 bound values surrounded by text.\n *\n * Used when the value passed to a property has 8 interpolated values in it:\n *\n * ```html\n * <div class=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolate8(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param i6 Static value used for concatenation only.\n * @param v7 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolate8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n/**\n * Update an interpolated class on an element with 9 or more bound values surrounded by text.\n *\n * Used when the number of interpolated values exceeds 8.\n *\n * ```html\n * <div\n * class=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵclassMapInterpolateV(\n * ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,\n * 'suffix']);\n * ```\n *.\n * @param values The collection of values and the strings in-between those values, beginning with\n * a string prefix and ending with a string suffix.\n * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)\n * @codeGenApi\n */\nfunction ɵɵclassMapInterpolateV(values) {\n const lView = getLView();\n const interpolatedValue = interpolationV(lView, values);\n checkStylingMap(keyValueArraySet, classStringParser, interpolatedValue, true);\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Instruction that returns the component instance in which the current instruction is executing.\n * This is a constant-time version of `nextContent` for the case where we know that we need the\n * component instance specifically, rather than the context of a particular template.\n *\n * @codeGenApi\n */\nfunction ɵɵcomponentInstance() {\n const instance = getLView()[DECLARATION_COMPONENT_VIEW][CONTEXT];\n ngDevMode && assertDefined(instance, 'Expected component instance to be defined');\n return instance;\n}\n\n/**\n * A type representing the live collection to be reconciled with any new (incoming) collection. This\n * is an adapter class that makes it possible to work with different internal data structures,\n * regardless of the actual values of the incoming collection.\n */\nclass LiveCollection {\n destroy(item) {\n // noop by default\n }\n updateValue(index, value) {\n // noop by default\n }\n // operations below could be implemented on top of the operations defined so far, but having\n // them explicitly allow clear expression of intent and potentially more performant\n // implementations\n swap(index1, index2) {\n const startIdx = Math.min(index1, index2);\n const endIdx = Math.max(index1, index2);\n const endItem = this.detach(endIdx);\n if (endIdx - startIdx > 1) {\n const startItem = this.detach(startIdx);\n this.attach(startIdx, endItem);\n this.attach(endIdx, startItem);\n } else {\n this.attach(startIdx, endItem);\n }\n }\n move(prevIndex, newIdx) {\n this.attach(newIdx, this.detach(prevIndex));\n }\n}\nfunction valuesMatching(liveIdx, liveValue, newIdx, newValue, trackBy) {\n if (liveIdx === newIdx && Object.is(liveValue, newValue)) {\n // matching and no value identity to update\n return 1;\n } else if (Object.is(trackBy(liveIdx, liveValue), trackBy(newIdx, newValue))) {\n // matching but requires value identity update\n return -1;\n }\n return 0;\n}\nfunction recordDuplicateKeys(keyToIdx, key, idx) {\n const idxSoFar = keyToIdx.get(key);\n if (idxSoFar !== undefined) {\n idxSoFar.add(idx);\n } else {\n keyToIdx.set(key, new Set([idx]));\n }\n}\n/**\n * The live collection reconciliation algorithm that perform various in-place operations, so it\n * reflects the content of the new (incoming) collection.\n *\n * The reconciliation algorithm has 2 code paths:\n * - \"fast\" path that don't require any memory allocation;\n * - \"slow\" path that requires additional memory allocation for intermediate data structures used to\n * collect additional information about the live collection.\n * It might happen that the algorithm switches between the two modes in question in a single\n * reconciliation path - generally it tries to stay on the \"fast\" path as much as possible.\n *\n * The overall complexity of the algorithm is O(n + m) for speed and O(n) for memory (where n is the\n * length of the live collection and m is the length of the incoming collection). Given the problem\n * at hand the complexity / performance constraints makes it impossible to perform the absolute\n * minimum of operation to reconcile the 2 collections. The algorithm makes different tradeoffs to\n * stay within reasonable performance bounds and may apply sub-optimal number of operations in\n * certain situations.\n *\n * @param liveCollection the current, live collection;\n * @param newCollection the new, incoming collection;\n * @param trackByFn key generation function that determines equality between items in the life and\n * incoming collection;\n */\nfunction reconcile(liveCollection, newCollection, trackByFn) {\n let detachedItems = undefined;\n let liveKeysInTheFuture = undefined;\n let liveStartIdx = 0;\n let liveEndIdx = liveCollection.length - 1;\n const duplicateKeys = ngDevMode ? new Map() : undefined;\n if (Array.isArray(newCollection)) {\n let newEndIdx = newCollection.length - 1;\n while (liveStartIdx <= liveEndIdx && liveStartIdx <= newEndIdx) {\n // compare from the beginning\n const liveStartValue = liveCollection.at(liveStartIdx);\n const newStartValue = newCollection[liveStartIdx];\n if (ngDevMode) {\n recordDuplicateKeys(duplicateKeys, trackByFn(liveStartIdx, newStartValue), liveStartIdx);\n }\n const isStartMatching = valuesMatching(liveStartIdx, liveStartValue, liveStartIdx, newStartValue, trackByFn);\n if (isStartMatching !== 0) {\n if (isStartMatching < 0) {\n liveCollection.updateValue(liveStartIdx, newStartValue);\n }\n liveStartIdx++;\n continue;\n }\n // compare from the end\n // TODO(perf): do _all_ the matching from the end\n const liveEndValue = liveCollection.at(liveEndIdx);\n const newEndValue = newCollection[newEndIdx];\n if (ngDevMode) {\n recordDuplicateKeys(duplicateKeys, trackByFn(newEndIdx, newEndValue), newEndIdx);\n }\n const isEndMatching = valuesMatching(liveEndIdx, liveEndValue, newEndIdx, newEndValue, trackByFn);\n if (isEndMatching !== 0) {\n if (isEndMatching < 0) {\n liveCollection.updateValue(liveEndIdx, newEndValue);\n }\n liveEndIdx--;\n newEndIdx--;\n continue;\n }\n // Detect swap and moves:\n const liveStartKey = trackByFn(liveStartIdx, liveStartValue);\n const liveEndKey = trackByFn(liveEndIdx, liveEndValue);\n const newStartKey = trackByFn(liveStartIdx, newStartValue);\n if (Object.is(newStartKey, liveEndKey)) {\n const newEndKey = trackByFn(newEndIdx, newEndValue);\n // detect swap on both ends;\n if (Object.is(newEndKey, liveStartKey)) {\n liveCollection.swap(liveStartIdx, liveEndIdx);\n liveCollection.updateValue(liveEndIdx, newEndValue);\n newEndIdx--;\n liveEndIdx--;\n } else {\n // the new item is the same as the live item with the end pointer - this is a move forward\n // to an earlier index;\n liveCollection.move(liveEndIdx, liveStartIdx);\n }\n liveCollection.updateValue(liveStartIdx, newStartValue);\n liveStartIdx++;\n continue;\n }\n // Fallback to the slow path: we need to learn more about the content of the live and new\n // collections.\n detachedItems ??= new UniqueValueMultiKeyMap();\n liveKeysInTheFuture ??= initLiveItemsInTheFuture(liveCollection, liveStartIdx, liveEndIdx, trackByFn);\n // Check if I'm inserting a previously detached item: if so, attach it here\n if (attachPreviouslyDetached(liveCollection, detachedItems, liveStartIdx, newStartKey)) {\n liveCollection.updateValue(liveStartIdx, newStartValue);\n liveStartIdx++;\n liveEndIdx++;\n } else if (!liveKeysInTheFuture.has(newStartKey)) {\n // Check if we seen a new item that doesn't exist in the old collection and must be INSERTED\n const newItem = liveCollection.create(liveStartIdx, newCollection[liveStartIdx]);\n liveCollection.attach(liveStartIdx, newItem);\n liveStartIdx++;\n liveEndIdx++;\n } else {\n // We know that the new item exists later on in old collection but we don't know its index\n // and as the consequence can't move it (don't know where to find it). Detach the old item,\n // hoping that it unlocks the fast path again.\n detachedItems.set(liveStartKey, liveCollection.detach(liveStartIdx));\n liveEndIdx--;\n }\n }\n // Final cleanup steps:\n // - more items in the new collection => insert\n while (liveStartIdx <= newEndIdx) {\n createOrAttach(liveCollection, detachedItems, trackByFn, liveStartIdx, newCollection[liveStartIdx]);\n liveStartIdx++;\n }\n } else if (newCollection != null) {\n // iterable - immediately fallback to the slow path\n const newCollectionIterator = newCollection[Symbol.iterator]();\n let newIterationResult = newCollectionIterator.next();\n while (!newIterationResult.done && liveStartIdx <= liveEndIdx) {\n const liveValue = liveCollection.at(liveStartIdx);\n const newValue = newIterationResult.value;\n if (ngDevMode) {\n recordDuplicateKeys(duplicateKeys, trackByFn(liveStartIdx, newValue), liveStartIdx);\n }\n const isStartMatching = valuesMatching(liveStartIdx, liveValue, liveStartIdx, newValue, trackByFn);\n if (isStartMatching !== 0) {\n // found a match - move on, but update value\n if (isStartMatching < 0) {\n liveCollection.updateValue(liveStartIdx, newValue);\n }\n liveStartIdx++;\n newIterationResult = newCollectionIterator.next();\n } else {\n detachedItems ??= new UniqueValueMultiKeyMap();\n liveKeysInTheFuture ??= initLiveItemsInTheFuture(liveCollection, liveStartIdx, liveEndIdx, trackByFn);\n // Check if I'm inserting a previously detached item: if so, attach it here\n const newKey = trackByFn(liveStartIdx, newValue);\n if (attachPreviouslyDetached(liveCollection, detachedItems, liveStartIdx, newKey)) {\n liveCollection.updateValue(liveStartIdx, newValue);\n liveStartIdx++;\n liveEndIdx++;\n newIterationResult = newCollectionIterator.next();\n } else if (!liveKeysInTheFuture.has(newKey)) {\n liveCollection.attach(liveStartIdx, liveCollection.create(liveStartIdx, newValue));\n liveStartIdx++;\n liveEndIdx++;\n newIterationResult = newCollectionIterator.next();\n } else {\n // it is a move forward - detach the current item without advancing in collections\n const liveKey = trackByFn(liveStartIdx, liveValue);\n detachedItems.set(liveKey, liveCollection.detach(liveStartIdx));\n liveEndIdx--;\n }\n }\n }\n // this is a new item as we run out of the items in the old collection - create or attach a\n // previously detached one\n while (!newIterationResult.done) {\n createOrAttach(liveCollection, detachedItems, trackByFn, liveCollection.length, newIterationResult.value);\n newIterationResult = newCollectionIterator.next();\n }\n }\n // Cleanups common to the array and iterable:\n // - more items in the live collection => delete starting from the end;\n while (liveStartIdx <= liveEndIdx) {\n liveCollection.destroy(liveCollection.detach(liveEndIdx--));\n }\n // - destroy items that were detached but never attached again.\n detachedItems?.forEach(item => {\n liveCollection.destroy(item);\n });\n // report duplicate keys (dev mode only)\n if (ngDevMode) {\n let duplicatedKeysMsg = [];\n for (const [key, idxSet] of duplicateKeys) {\n if (idxSet.size > 1) {\n const idx = [...idxSet].sort((a, b) => a - b);\n for (let i = 1; i < idx.length; i++) {\n duplicatedKeysMsg.push(`key \"${stringifyForError(key)}\" at index \"${idx[i - 1]}\" and \"${idx[i]}\"`);\n }\n }\n }\n if (duplicatedKeysMsg.length > 0) {\n const message = formatRuntimeError(-955 /* RuntimeErrorCode.LOOP_TRACK_DUPLICATE_KEYS */, 'The provided track expression resulted in duplicated keys for a given collection. ' + 'Adjust the tracking expression such that it uniquely identifies all the items in the collection. ' + 'Duplicated keys were: \\n' + duplicatedKeysMsg.join(', \\n') + '.');\n console.warn(message);\n }\n }\n}\nfunction attachPreviouslyDetached(prevCollection, detachedItems, index, key) {\n if (detachedItems !== undefined && detachedItems.has(key)) {\n prevCollection.attach(index, detachedItems.get(key));\n detachedItems.delete(key);\n return true;\n }\n return false;\n}\nfunction createOrAttach(liveCollection, detachedItems, trackByFn, index, value) {\n if (!attachPreviouslyDetached(liveCollection, detachedItems, index, trackByFn(index, value))) {\n const newItem = liveCollection.create(index, value);\n liveCollection.attach(index, newItem);\n } else {\n liveCollection.updateValue(index, value);\n }\n}\nfunction initLiveItemsInTheFuture(liveCollection, start, end, trackByFn) {\n const keys = new Set();\n for (let i = start; i <= end; i++) {\n keys.add(trackByFn(i, liveCollection.at(i)));\n }\n return keys;\n}\n/**\n * A specific, partial implementation of the Map interface with the following characteristics:\n * - allows multiple values for a given key;\n * - maintain FIFO order for multiple values corresponding to a given key;\n * - assumes that all values are unique.\n *\n * The implementation aims at having the minimal overhead for cases where keys are _not_ duplicated\n * (the most common case in the list reconciliation algorithm). To achieve this, the first value for\n * a given key is stored in a regular map. Then, when more values are set for a given key, we\n * maintain a form of linked list in a separate map. To maintain this linked list we assume that all\n * values (in the entire collection) are unique.\n */\nclass UniqueValueMultiKeyMap {\n // A map from a key to the first value corresponding to this key.\n kvMap = new Map();\n // A map that acts as a linked list of values - each value maps to the next value in this \"linked\n // list\" (this only works if values are unique). Allocated lazily to avoid memory consumption when\n // there are no duplicated values.\n _vMap = undefined;\n has(key) {\n return this.kvMap.has(key);\n }\n delete(key) {\n if (!this.has(key)) return false;\n const value = this.kvMap.get(key);\n if (this._vMap !== undefined && this._vMap.has(value)) {\n this.kvMap.set(key, this._vMap.get(value));\n this._vMap.delete(value);\n } else {\n this.kvMap.delete(key);\n }\n return true;\n }\n get(key) {\n return this.kvMap.get(key);\n }\n set(key, value) {\n if (this.kvMap.has(key)) {\n let prevValue = this.kvMap.get(key);\n // Note: we don't use `assertNotSame`, because the value needs to be stringified even if\n // there is no error which can freeze the browser for large values (see #58509).\n if (ngDevMode && prevValue === value) {\n throw new Error(`Detected a duplicated value ${value} for the key ${key}`);\n }\n if (this._vMap === undefined) {\n this._vMap = new Map();\n }\n const vMap = this._vMap;\n while (vMap.has(prevValue)) {\n prevValue = vMap.get(prevValue);\n }\n vMap.set(prevValue, value);\n } else {\n this.kvMap.set(key, value);\n }\n }\n forEach(cb) {\n for (let [key, value] of this.kvMap) {\n cb(value, key);\n if (this._vMap !== undefined) {\n const vMap = this._vMap;\n while (vMap.has(value)) {\n value = vMap.get(value);\n cb(value, key);\n }\n }\n }\n }\n}\n\n/**\n * The conditional instruction represents the basic building block on the runtime side to support\n * built-in \"if\" and \"switch\". On the high level this instruction is responsible for adding and\n * removing views selected by a conditional expression.\n *\n * @param matchingTemplateIndex Index of a template TNode representing a conditional view to be\n * inserted; -1 represents a special case when there is no view to insert.\n * @param contextValue Value that should be exposed as the context of the conditional.\n * @codeGenApi\n */\nfunction ɵɵconditional(matchingTemplateIndex, contextValue) {\n performanceMarkFeature('NgControlFlow');\n const hostLView = getLView();\n const bindingIndex = nextBindingIndex();\n const prevMatchingTemplateIndex = hostLView[bindingIndex] !== NO_CHANGE ? hostLView[bindingIndex] : -1;\n const prevContainer = prevMatchingTemplateIndex !== -1 ? getLContainer(hostLView, HEADER_OFFSET + prevMatchingTemplateIndex) : undefined;\n const viewInContainerIdx = 0;\n if (bindingUpdated(hostLView, bindingIndex, matchingTemplateIndex)) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n // The index of the view to show changed - remove the previously displayed one\n // (it is a noop if there are no active views in a container).\n if (prevContainer !== undefined) {\n removeLViewFromLContainer(prevContainer, viewInContainerIdx);\n }\n // Index -1 is a special case where none of the conditions evaluates to\n // a truthy value and as the consequence we've got no view to show.\n if (matchingTemplateIndex !== -1) {\n const nextLContainerIndex = HEADER_OFFSET + matchingTemplateIndex;\n const nextContainer = getLContainer(hostLView, nextLContainerIndex);\n const templateTNode = getExistingTNode(hostLView[TVIEW], nextLContainerIndex);\n const dehydratedView = findMatchingDehydratedView(nextContainer, templateTNode.tView.ssrId);\n const embeddedLView = createAndRenderEmbeddedLView(hostLView, templateTNode, contextValue, {\n dehydratedView\n });\n addLViewToLContainer(nextContainer, embeddedLView, viewInContainerIdx, shouldAddViewToDom(templateTNode, dehydratedView));\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n } else if (prevContainer !== undefined) {\n // We might keep displaying the same template but the actual value of the expression could have\n // changed - re-bind in context.\n const lView = getLViewFromLContainer(prevContainer, viewInContainerIdx);\n if (lView !== undefined) {\n lView[CONTEXT] = contextValue;\n }\n }\n}\nclass RepeaterContext {\n lContainer;\n $implicit;\n $index;\n constructor(lContainer, $implicit, $index) {\n this.lContainer = lContainer;\n this.$implicit = $implicit;\n this.$index = $index;\n }\n get $count() {\n return this.lContainer.length - CONTAINER_HEADER_OFFSET;\n }\n}\n/**\n * A built-in trackBy function used for situations where users specified collection index as a\n * tracking expression. Having this function body in the runtime avoids unnecessary code generation.\n *\n * @param index\n * @returns\n */\nfunction ɵɵrepeaterTrackByIndex(index) {\n return index;\n}\n/**\n * A built-in trackBy function used for situations where users specified collection item reference\n * as a tracking expression. Having this function body in the runtime avoids unnecessary code\n * generation.\n *\n * @param index\n * @returns\n */\nfunction ɵɵrepeaterTrackByIdentity(_, value) {\n return value;\n}\nclass RepeaterMetadata {\n hasEmptyBlock;\n trackByFn;\n liveCollection;\n constructor(hasEmptyBlock, trackByFn, liveCollection) {\n this.hasEmptyBlock = hasEmptyBlock;\n this.trackByFn = trackByFn;\n this.liveCollection = liveCollection;\n }\n}\n/**\n * The repeaterCreate instruction runs in the creation part of the template pass and initializes\n * internal data structures required by the update pass of the built-in repeater logic. Repeater\n * metadata are allocated in the data part of LView with the following layout:\n * - LView[HEADER_OFFSET + index] - metadata\n * - LView[HEADER_OFFSET + index + 1] - reference to a template function rendering an item\n * - LView[HEADER_OFFSET + index + 2] - optional reference to a template function rendering an empty\n * block\n *\n * @param index Index at which to store the metadata of the repeater.\n * @param templateFn Reference to the template of the main repeater block.\n * @param decls The number of nodes, local refs, and pipes for the main block.\n * @param vars The number of bindings for the main block.\n * @param tagName The name of the container element, if applicable\n * @param attrsIndex Index of template attributes in the `consts` array.\n * @param trackByFn Reference to the tracking function.\n * @param trackByUsesComponentInstance Whether the tracking function has any references to the\n * component instance. If it doesn't, we can avoid rebinding it.\n * @param emptyTemplateFn Reference to the template function of the empty block.\n * @param emptyDecls The number of nodes, local refs, and pipes for the empty block.\n * @param emptyVars The number of bindings for the empty block.\n * @param emptyTagName The name of the empty block container element, if applicable\n * @param emptyAttrsIndex Index of the empty block template attributes in the `consts` array.\n *\n * @codeGenApi\n */\nfunction ɵɵrepeaterCreate(index, templateFn, decls, vars, tagName, attrsIndex, trackByFn, trackByUsesComponentInstance, emptyTemplateFn, emptyDecls, emptyVars, emptyTagName, emptyAttrsIndex) {\n performanceMarkFeature('NgControlFlow');\n ngDevMode && assertFunction(trackByFn, `A track expression must be a function, was ${typeof trackByFn} instead.`);\n const lView = getLView();\n const tView = getTView();\n const hasEmptyBlock = emptyTemplateFn !== undefined;\n const hostLView = getLView();\n const boundTrackBy = trackByUsesComponentInstance ?\n // We only want to bind when necessary, because it produces a\n // new function. For pure functions it's not necessary.\n trackByFn.bind(hostLView[DECLARATION_COMPONENT_VIEW][CONTEXT]) : trackByFn;\n const metadata = new RepeaterMetadata(hasEmptyBlock, boundTrackBy);\n hostLView[HEADER_OFFSET + index] = metadata;\n declareTemplate(lView, tView, index + 1, templateFn, decls, vars, tagName, getConstant(tView.consts, attrsIndex));\n if (hasEmptyBlock) {\n ngDevMode && assertDefined(emptyDecls, 'Missing number of declarations for the empty repeater block.');\n ngDevMode && assertDefined(emptyVars, 'Missing number of bindings for the empty repeater block.');\n declareTemplate(lView, tView, index + 2, emptyTemplateFn, emptyDecls, emptyVars, emptyTagName, getConstant(tView.consts, emptyAttrsIndex));\n }\n}\nfunction isViewExpensiveToRecreate(lView) {\n // assumption: anything more than a text node with a binding is considered \"expensive\"\n return lView.length - HEADER_OFFSET > 2;\n}\nclass OperationsCounter {\n created = 0;\n destroyed = 0;\n reset() {\n this.created = 0;\n this.destroyed = 0;\n }\n recordCreate() {\n this.created++;\n }\n recordDestroy() {\n this.destroyed++;\n }\n /**\n * A method indicating if the entire collection was re-created as part of the reconciliation pass.\n * Used to warn developers about the usage of a tracking function that might result in excessive\n * amount of view creation / destroy operations.\n *\n * @returns boolean value indicating if a live collection was re-created\n */\n wasReCreated(collectionLen) {\n return collectionLen > 0 && this.created === this.destroyed && this.created === collectionLen;\n }\n}\nclass LiveCollectionLContainerImpl extends LiveCollection {\n lContainer;\n hostLView;\n templateTNode;\n operationsCounter = ngDevMode ? new OperationsCounter() : undefined;\n /**\n Property indicating if indexes in the repeater context need to be updated following the live\n collection changes. Index updates are necessary if and only if views are inserted / removed in\n the middle of LContainer. Adds and removals at the end don't require index updates.\n */\n needsIndexUpdate = false;\n constructor(lContainer, hostLView, templateTNode) {\n super();\n this.lContainer = lContainer;\n this.hostLView = hostLView;\n this.templateTNode = templateTNode;\n }\n get length() {\n return this.lContainer.length - CONTAINER_HEADER_OFFSET;\n }\n at(index) {\n return this.getLView(index)[CONTEXT].$implicit;\n }\n attach(index, lView) {\n const dehydratedView = lView[HYDRATION];\n this.needsIndexUpdate ||= index !== this.length;\n addLViewToLContainer(this.lContainer, lView, index, shouldAddViewToDom(this.templateTNode, dehydratedView));\n }\n detach(index) {\n this.needsIndexUpdate ||= index !== this.length - 1;\n return detachExistingView(this.lContainer, index);\n }\n create(index, value) {\n const dehydratedView = findMatchingDehydratedView(this.lContainer, this.templateTNode.tView.ssrId);\n const embeddedLView = createAndRenderEmbeddedLView(this.hostLView, this.templateTNode, new RepeaterContext(this.lContainer, value, index), {\n dehydratedView\n });\n this.operationsCounter?.recordCreate();\n return embeddedLView;\n }\n destroy(lView) {\n destroyLView(lView[TVIEW], lView);\n this.operationsCounter?.recordDestroy();\n }\n updateValue(index, value) {\n this.getLView(index)[CONTEXT].$implicit = value;\n }\n reset() {\n this.needsIndexUpdate = false;\n this.operationsCounter?.reset();\n }\n updateIndexes() {\n if (this.needsIndexUpdate) {\n for (let i = 0; i < this.length; i++) {\n this.getLView(i)[CONTEXT].$index = i;\n }\n }\n }\n getLView(index) {\n return getExistingLViewFromLContainer(this.lContainer, index);\n }\n}\n/**\n * The repeater instruction does update-time diffing of a provided collection (against the\n * collection seen previously) and maps changes in the collection to views structure (by adding,\n * removing or moving views as needed).\n * @param collection - the collection instance to be checked for changes\n * @codeGenApi\n */\nfunction ɵɵrepeater(collection) {\n const prevConsumer = setActiveConsumer$1(null);\n const metadataSlotIdx = getSelectedIndex();\n try {\n const hostLView = getLView();\n const hostTView = hostLView[TVIEW];\n const metadata = hostLView[metadataSlotIdx];\n const containerIndex = metadataSlotIdx + 1;\n const lContainer = getLContainer(hostLView, containerIndex);\n if (metadata.liveCollection === undefined) {\n const itemTemplateTNode = getExistingTNode(hostTView, containerIndex);\n metadata.liveCollection = new LiveCollectionLContainerImpl(lContainer, hostLView, itemTemplateTNode);\n } else {\n metadata.liveCollection.reset();\n }\n const liveCollection = metadata.liveCollection;\n reconcile(liveCollection, collection, metadata.trackByFn);\n // Warn developers about situations where the entire collection was re-created as part of the\n // reconciliation pass. Note that this warning might be \"overreacting\" and report cases where\n // the collection re-creation is the intended behavior. Still, the assumption is that most of\n // the time it is undesired.\n if (ngDevMode && metadata.trackByFn === ɵɵrepeaterTrackByIdentity && liveCollection.operationsCounter?.wasReCreated(liveCollection.length) && isViewExpensiveToRecreate(getExistingLViewFromLContainer(lContainer, 0))) {\n const message = formatRuntimeError(-956 /* RuntimeErrorCode.LOOP_TRACK_RECREATE */, `The configured tracking expression (track by identity) caused re-creation of the entire collection of size ${liveCollection.length}. ` + 'This is an expensive operation requiring destruction and subsequent creation of DOM nodes, directives, components etc. ' + 'Please review the \"track expression\" and make sure that it uniquely identifies items in a collection.');\n console.warn(message);\n }\n // moves in the container might caused context's index to get out of order, re-adjust if needed\n liveCollection.updateIndexes();\n // handle empty blocks\n if (metadata.hasEmptyBlock) {\n const bindingIndex = nextBindingIndex();\n const isCollectionEmpty = liveCollection.length === 0;\n if (bindingUpdated(hostLView, bindingIndex, isCollectionEmpty)) {\n const emptyTemplateIndex = metadataSlotIdx + 2;\n const lContainerForEmpty = getLContainer(hostLView, emptyTemplateIndex);\n if (isCollectionEmpty) {\n const emptyTemplateTNode = getExistingTNode(hostTView, emptyTemplateIndex);\n const dehydratedView = findMatchingDehydratedView(lContainerForEmpty, emptyTemplateTNode.tView.ssrId);\n const embeddedLView = createAndRenderEmbeddedLView(hostLView, emptyTemplateTNode, undefined, {\n dehydratedView\n });\n addLViewToLContainer(lContainerForEmpty, embeddedLView, 0, shouldAddViewToDom(emptyTemplateTNode, dehydratedView));\n } else {\n removeLViewFromLContainer(lContainerForEmpty, 0);\n }\n }\n }\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n}\nfunction getLContainer(lView, index) {\n const lContainer = lView[index];\n ngDevMode && assertLContainer(lContainer);\n return lContainer;\n}\nfunction detachExistingView(lContainer, index) {\n const existingLView = detachView(lContainer, index);\n ngDevMode && assertLView(existingLView);\n return existingLView;\n}\nfunction getExistingLViewFromLContainer(lContainer, index) {\n const existingLView = getLViewFromLContainer(lContainer, index);\n ngDevMode && assertLView(existingLView);\n return existingLView;\n}\nfunction getExistingTNode(tView, index) {\n const tNode = getTNode(tView, index);\n ngDevMode && assertTNode(tNode);\n return tNode;\n}\n\n/**\n * Create DOM element. The instruction must later be followed by `elementEnd()` call.\n *\n * @param index Index of the element in the LView array\n * @param name Name of the DOM Node\n * @param attrsIndex Index of the element's attributes in the `consts` array.\n * @param localRefsIndex Index of the element's local references in the `consts` array.\n * @returns This function returns itself so that it may be chained.\n *\n * Attributes and localRefs are passed as an array of strings where elements with an even index\n * hold an attribute name and elements with an odd index hold an attribute value, ex.:\n * ['id', 'warning5', 'class', 'alert']\n *\n * @codeGenApi\n */\nfunction ɵɵelementStart(index, name, attrsIndex, localRefsIndex) {\n const lView = getLView();\n const tView = getTView();\n const adjustedIndex = HEADER_OFFSET + index;\n ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'elements should be created before any bindings');\n ngDevMode && assertIndexInRange(lView, adjustedIndex);\n const renderer = lView[RENDERER];\n const tNode = tView.firstCreatePass ? elementStartFirstCreatePass(adjustedIndex, tView, lView, name, findDirectiveDefMatches, getBindingsEnabled(), attrsIndex, localRefsIndex) : tView.data[adjustedIndex];\n const native = _locateOrCreateElementNode(tView, lView, tNode, renderer, name, index);\n lView[adjustedIndex] = native;\n const hasDirectives = isDirectiveHost(tNode);\n if (ngDevMode && tView.firstCreatePass) {\n validateElementIsKnown(native, lView, tNode.value, tView.schemas, hasDirectives);\n }\n setCurrentTNode(tNode, true);\n setupStaticAttributes(renderer, native, tNode);\n if (!isDetachedByI18n(tNode) && wasLastNodeCreated()) {\n // In the i18n case, the translation may have removed this element, so only add it if it is not\n // detached. See `TNodeType.Placeholder` and `LFrame.inI18n` for more context.\n appendChild(tView, lView, native, tNode);\n }\n // any immediate children of a component or template container must be pre-emptively\n // monkey-patched with the component view data so that the element can be inspected\n // later on using any element discovery utility methods (see `element_discovery.ts`)\n if (getElementDepthCount() === 0 || hasDirectives) {\n attachPatchData(native, lView);\n }\n increaseElementDepthCount();\n if (hasDirectives) {\n createDirectivesInstances(tView, lView, tNode);\n executeContentQueries(tView, tNode, lView);\n }\n if (localRefsIndex !== null) {\n saveResolvedLocalsInData(lView, tNode);\n }\n return ɵɵelementStart;\n}\n/**\n * Mark the end of the element.\n * @returns This function returns itself so that it may be chained.\n *\n * @codeGenApi\n */\nfunction ɵɵelementEnd() {\n let currentTNode = getCurrentTNode();\n ngDevMode && assertDefined(currentTNode, 'No parent node to close.');\n if (isCurrentTNodeParent()) {\n setCurrentTNodeAsNotParent();\n } else {\n ngDevMode && assertHasParent(getCurrentTNode());\n currentTNode = currentTNode.parent;\n setCurrentTNode(currentTNode, false);\n }\n const tNode = currentTNode;\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */);\n if (isSkipHydrationRootTNode(tNode)) {\n leaveSkipHydrationBlock();\n }\n decreaseElementDepthCount();\n const tView = getTView();\n if (tView.firstCreatePass) {\n elementEndFirstCreatePass(tView, tNode);\n }\n if (tNode.classesWithoutHost != null && hasClassInput(tNode)) {\n setDirectiveInputsWhichShadowsStyling(tView, tNode, getLView(), tNode.classesWithoutHost, true);\n }\n if (tNode.stylesWithoutHost != null && hasStyleInput(tNode)) {\n setDirectiveInputsWhichShadowsStyling(tView, tNode, getLView(), tNode.stylesWithoutHost, false);\n }\n return ɵɵelementEnd;\n}\n/**\n * Creates an empty element using {@link elementStart} and {@link elementEnd}\n *\n * @param index Index of the element in the data array\n * @param name Name of the DOM Node\n * @param attrsIndex Index of the element's attributes in the `consts` array.\n * @param localRefsIndex Index of the element's local references in the `consts` array.\n * @returns This function returns itself so that it may be chained.\n *\n * @codeGenApi\n */\nfunction ɵɵelement(index, name, attrsIndex, localRefsIndex) {\n ɵɵelementStart(index, name, attrsIndex, localRefsIndex);\n ɵɵelementEnd();\n return ɵɵelement;\n}\nlet _locateOrCreateElementNode = (tView, lView, tNode, renderer, name, index) => {\n lastNodeWasCreated(true);\n return createElementNode(renderer, name, getNamespace());\n};\n/**\n * Enables hydration code path (to lookup existing elements in DOM)\n * in addition to the regular creation mode of element nodes.\n */\nfunction locateOrCreateElementNodeImpl(tView, lView, tNode, renderer, name, index) {\n const hydrationInfo = lView[HYDRATION];\n const isNodeCreationMode = !hydrationInfo || isInSkipHydrationBlock$1() || isDetachedByI18n(tNode) || isDisconnectedNode$1(hydrationInfo, index);\n lastNodeWasCreated(isNodeCreationMode);\n // Regular creation mode.\n if (isNodeCreationMode) {\n return createElementNode(renderer, name, getNamespace());\n }\n // Hydration mode, looking up an existing element in DOM.\n const native = locateNextRNode(hydrationInfo, tView, lView, tNode);\n ngDevMode && validateMatchingNode(native, Node.ELEMENT_NODE, name, lView, tNode);\n ngDevMode && markRNodeAsClaimedByHydration(native);\n // This element might also be an anchor of a view container.\n if (getSerializedContainerViews(hydrationInfo, index)) {\n // Important note: this element acts as an anchor, but it's **not** a part\n // of the embedded view, so we start the segment **after** this element, taking\n // a reference to the next sibling. For example, the following template:\n // `<div #vcrTarget>` is represented in the DOM as `<div></div>...<!--container-->`,\n // so while processing a `<div>` instruction, point to the next sibling as a\n // start of a segment.\n ngDevMode && validateNodeExists(native.nextSibling, lView, tNode);\n setSegmentHead(hydrationInfo, index, native.nextSibling);\n }\n // Checks if the skip hydration attribute is present during hydration so we know to\n // skip attempting to hydrate this block. We check both TNode and RElement for an\n // attribute: the RElement case is needed for i18n cases, when we add it to host\n // elements during the annotation phase (after all internal data structures are setup).\n if (hydrationInfo && (hasSkipHydrationAttrOnTNode(tNode) || hasSkipHydrationAttrOnRElement(native))) {\n if (isComponentHost(tNode)) {\n enterSkipHydrationBlock(tNode);\n // Since this isn't hydratable, we need to empty the node\n // so there's no duplicate content after render\n clearElementContents(native);\n ngDevMode && markRNodeAsSkippedByHydration(native);\n } else if (ngDevMode) {\n // If this is not a component host, throw an error.\n // Hydration can be skipped on per-component basis only.\n throw invalidSkipHydrationHost(native);\n }\n }\n return native;\n}\nfunction enableLocateOrCreateElementNodeImpl() {\n _locateOrCreateElementNode = locateOrCreateElementNodeImpl;\n}\nfunction elementContainerStartFirstCreatePass(index, tView, lView, attrsIndex, localRefsIndex) {\n ngDevMode && ngDevMode.firstCreatePass++;\n const tViewConsts = tView.consts;\n const attrs = getConstant(tViewConsts, attrsIndex);\n const tNode = getOrCreateTNode(tView, index, 8 /* TNodeType.ElementContainer */, 'ng-container', attrs);\n // While ng-container doesn't necessarily support styling, we use the style context to identify\n // and execute directives on the ng-container.\n if (attrs !== null) {\n computeStaticStyling(tNode, attrs, true);\n }\n const localRefs = getConstant(tViewConsts, localRefsIndex);\n if (getBindingsEnabled()) {\n resolveDirectives(tView, lView, tNode, localRefs, findDirectiveDefMatches);\n }\n // Merge the template attrs last so that they have the highest priority.\n tNode.mergedAttrs = mergeHostAttrs(tNode.mergedAttrs, tNode.attrs);\n if (tView.queries !== null) {\n tView.queries.elementStart(tView, tNode);\n }\n return tNode;\n}\n/**\n * Creates a logical container for other nodes (<ng-container>) backed by a comment node in the DOM.\n * The instruction must later be followed by `elementContainerEnd()` call.\n *\n * @param index Index of the element in the LView array\n * @param attrsIndex Index of the container attributes in the `consts` array.\n * @param localRefsIndex Index of the container's local references in the `consts` array.\n * @returns This function returns itself so that it may be chained.\n *\n * Even if this instruction accepts a set of attributes no actual attribute values are propagated to\n * the DOM (as a comment node can't have attributes). Attributes are here only for directive\n * matching purposes and setting initial inputs of directives.\n *\n * @codeGenApi\n */\nfunction ɵɵelementContainerStart(index, attrsIndex, localRefsIndex) {\n const lView = getLView();\n const tView = getTView();\n const adjustedIndex = index + HEADER_OFFSET;\n ngDevMode && assertIndexInRange(lView, adjustedIndex);\n ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'element containers should be created before any bindings');\n const tNode = tView.firstCreatePass ? elementContainerStartFirstCreatePass(adjustedIndex, tView, lView, attrsIndex, localRefsIndex) : tView.data[adjustedIndex];\n setCurrentTNode(tNode, true);\n const comment = _locateOrCreateElementContainerNode(tView, lView, tNode, index);\n lView[adjustedIndex] = comment;\n if (wasLastNodeCreated()) {\n appendChild(tView, lView, comment, tNode);\n }\n attachPatchData(comment, lView);\n if (isDirectiveHost(tNode)) {\n createDirectivesInstances(tView, lView, tNode);\n executeContentQueries(tView, tNode, lView);\n }\n if (localRefsIndex != null) {\n saveResolvedLocalsInData(lView, tNode);\n }\n return ɵɵelementContainerStart;\n}\n/**\n * Mark the end of the <ng-container>.\n * @returns This function returns itself so that it may be chained.\n *\n * @codeGenApi\n */\nfunction ɵɵelementContainerEnd() {\n let currentTNode = getCurrentTNode();\n const tView = getTView();\n if (isCurrentTNodeParent()) {\n setCurrentTNodeAsNotParent();\n } else {\n ngDevMode && assertHasParent(currentTNode);\n currentTNode = currentTNode.parent;\n setCurrentTNode(currentTNode, false);\n }\n ngDevMode && assertTNodeType(currentTNode, 8 /* TNodeType.ElementContainer */);\n if (tView.firstCreatePass) {\n registerPostOrderHooks(tView, currentTNode);\n if (isContentQueryHost(currentTNode)) {\n tView.queries.elementEnd(currentTNode);\n }\n }\n return ɵɵelementContainerEnd;\n}\n/**\n * Creates an empty logical container using {@link elementContainerStart}\n * and {@link elementContainerEnd}\n *\n * @param index Index of the element in the LView array\n * @param attrsIndex Index of the container attributes in the `consts` array.\n * @param localRefsIndex Index of the container's local references in the `consts` array.\n * @returns This function returns itself so that it may be chained.\n *\n * @codeGenApi\n */\nfunction ɵɵelementContainer(index, attrsIndex, localRefsIndex) {\n ɵɵelementContainerStart(index, attrsIndex, localRefsIndex);\n ɵɵelementContainerEnd();\n return ɵɵelementContainer;\n}\nlet _locateOrCreateElementContainerNode = (tView, lView, tNode, index) => {\n lastNodeWasCreated(true);\n return createCommentNode(lView[RENDERER], ngDevMode ? 'ng-container' : '');\n};\n/**\n * Enables hydration code path (to lookup existing elements in DOM)\n * in addition to the regular creation mode of comment nodes that\n * represent <ng-container>'s anchor.\n */\nfunction locateOrCreateElementContainerNode(tView, lView, tNode, index) {\n let comment;\n const hydrationInfo = lView[HYDRATION];\n const isNodeCreationMode = !hydrationInfo || isInSkipHydrationBlock$1() || isDisconnectedNode$1(hydrationInfo, index) || isDetachedByI18n(tNode);\n lastNodeWasCreated(isNodeCreationMode);\n // Regular creation mode.\n if (isNodeCreationMode) {\n return createCommentNode(lView[RENDERER], ngDevMode ? 'ng-container' : '');\n }\n // Hydration mode, looking up existing elements in DOM.\n const currentRNode = locateNextRNode(hydrationInfo, tView, lView, tNode);\n ngDevMode && validateNodeExists(currentRNode, lView, tNode);\n const ngContainerSize = getNgContainerSize(hydrationInfo, index);\n ngDevMode && assertNumber(ngContainerSize, 'Unexpected state: hydrating an <ng-container>, ' + 'but no hydration info is available.');\n setSegmentHead(hydrationInfo, index, currentRNode);\n comment = siblingAfter(ngContainerSize, currentRNode);\n if (ngDevMode) {\n validateMatchingNode(comment, Node.COMMENT_NODE, null, lView, tNode);\n markRNodeAsClaimedByHydration(comment);\n }\n return comment;\n}\nfunction enableLocateOrCreateElementContainerNodeImpl() {\n _locateOrCreateElementContainerNode = locateOrCreateElementContainerNode;\n}\n\n/**\n * Returns the current OpaqueViewState instance.\n *\n * Used in conjunction with the restoreView() instruction to save a snapshot\n * of the current view and restore it when listeners are invoked. This allows\n * walking the declaration view tree in listeners to get vars from parent views.\n *\n * @codeGenApi\n */\nfunction ɵɵgetCurrentView() {\n return getLView();\n}\n\n/**\n * Update a property on a host element. Only applies to native node properties, not inputs.\n *\n * Operates on the element selected by index via the {@link select} instruction.\n *\n * @param propName Name of property. Because it is going to DOM, this is not subject to\n * renaming as part of minification.\n * @param value New value to write.\n * @param sanitizer An optional function used to sanitize the value.\n * @returns This function returns itself so that it may be chained\n * (e.g. `property('name', ctx.name)('title', ctx.title)`)\n *\n * @codeGenApi\n */\nfunction ɵɵhostProperty(propName, value, sanitizer) {\n const lView = getLView();\n const bindingIndex = nextBindingIndex();\n if (bindingUpdated(lView, bindingIndex, value)) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, value, lView[RENDERER], sanitizer, true);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);\n }\n return ɵɵhostProperty;\n}\n/**\n * Updates a synthetic host binding (e.g. `[@foo]`) on a component or directive.\n *\n * This instruction is for compatibility purposes and is designed to ensure that a\n * synthetic host binding (e.g. `@HostBinding('@foo')`) properly gets rendered in\n * the component's renderer. Normally all host bindings are evaluated with the parent\n * component's renderer, but, in the case of animation @triggers, they need to be\n * evaluated with the sub component's renderer (because that's where the animation\n * triggers are defined).\n *\n * Do not use this instruction as a replacement for `elementProperty`. This instruction\n * only exists to ensure compatibility with the ViewEngine's host binding behavior.\n *\n * @param index The index of the element to update in the data array\n * @param propName Name of property. Because it is going to DOM, this is not subject to\n * renaming as part of minification.\n * @param value New value to write.\n * @param sanitizer An optional function used to sanitize the value.\n *\n * @codeGenApi\n */\nfunction ɵɵsyntheticHostProperty(propName, value, sanitizer) {\n const lView = getLView();\n const bindingIndex = nextBindingIndex();\n if (bindingUpdated(lView, bindingIndex, value)) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n const currentDef = getCurrentDirectiveDef(tView.data);\n const renderer = loadComponentRenderer(currentDef, tNode, lView);\n elementPropertyInternal(tView, tNode, lView, propName, value, renderer, sanitizer, true);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);\n }\n return ɵɵsyntheticHostProperty;\n}\n\n/**\n * NOTE: changes to the `ngI18nClosureMode` name must be synced with `compiler-cli/src/tooling.ts`.\n */\nif (typeof ngI18nClosureMode === 'undefined') {\n // These property accesses can be ignored because ngI18nClosureMode will be set to false\n // when optimizing code and the whole if statement will be dropped.\n // Make sure to refer to ngI18nClosureMode as ['ngI18nClosureMode'] for closure.\n // NOTE: we need to have it in IIFE so that the tree-shaker is happy.\n (function () {\n _global['ngI18nClosureMode'] =\n // TODO(FW-1250): validate that this actually, you know, works.\n typeof goog !== 'undefined' && typeof goog.getMsg === 'function';\n })();\n}\n\n// THIS CODE IS GENERATED - DO NOT MODIFY.\nconst u = undefined;\nfunction plural(val) {\n const n = val,\n i = Math.floor(Math.abs(val)),\n v = val.toString().replace(/^[^.]*\\.?/, '').length;\n if (i === 1 && v === 0) return 1;\n return 5;\n}\nvar localeEn = [\"en\", [[\"a\", \"p\"], [\"AM\", \"PM\"], u], [[\"AM\", \"PM\"], u, u], [[\"S\", \"M\", \"T\", \"W\", \"T\", \"F\", \"S\"], [\"Sun\", \"Mon\", \"Tue\", \"Wed\", \"Thu\", \"Fri\", \"Sat\"], [\"Sunday\", \"Monday\", \"Tuesday\", \"Wednesday\", \"Thursday\", \"Friday\", \"Saturday\"], [\"Su\", \"Mo\", \"Tu\", \"We\", \"Th\", \"Fr\", \"Sa\"]], u, [[\"J\", \"F\", \"M\", \"A\", \"M\", \"J\", \"J\", \"A\", \"S\", \"O\", \"N\", \"D\"], [\"Jan\", \"Feb\", \"Mar\", \"Apr\", \"May\", \"Jun\", \"Jul\", \"Aug\", \"Sep\", \"Oct\", \"Nov\", \"Dec\"], [\"January\", \"February\", \"March\", \"April\", \"May\", \"June\", \"July\", \"August\", \"September\", \"October\", \"November\", \"December\"]], u, [[\"B\", \"A\"], [\"BC\", \"AD\"], [\"Before Christ\", \"Anno Domini\"]], 0, [6, 0], [\"M/d/yy\", \"MMM d, y\", \"MMMM d, y\", \"EEEE, MMMM d, y\"], [\"h:mm a\", \"h:mm:ss a\", \"h:mm:ss a z\", \"h:mm:ss a zzzz\"], [\"{1}, {0}\", u, \"{1} 'at' {0}\", u], [\".\", \",\", \";\", \"%\", \"+\", \"-\", \"E\", \"×\", \"‰\", \"∞\", \"NaN\", \":\"], [\"#,##0.###\", \"#,##0%\", \"¤#,##0.00\", \"#E0\"], \"USD\", \"$\", \"US Dollar\", {}, \"ltr\", plural];\n\n/**\n * This const is used to store the locale data registered with `registerLocaleData`\n */\nlet LOCALE_DATA = {};\n/**\n * Register locale data to be used internally by Angular. See the\n * [\"I18n guide\"](guide/i18n/format-data-locale) to know how to import additional locale\n * data.\n *\n * The signature `registerLocaleData(data: any, extraData?: any)` is deprecated since v5.1\n */\nfunction registerLocaleData(data, localeId, extraData) {\n if (typeof localeId !== 'string') {\n extraData = localeId;\n localeId = data[LocaleDataIndex.LocaleId];\n }\n localeId = localeId.toLowerCase().replace(/_/g, '-');\n LOCALE_DATA[localeId] = data;\n if (extraData) {\n LOCALE_DATA[localeId][LocaleDataIndex.ExtraData] = extraData;\n }\n}\n/**\n * Finds the locale data for a given locale.\n *\n * @param locale The locale code.\n * @returns The locale data.\n * @see [Internationalization (i18n) Guide](https://angular.io/guide/i18n)\n */\nfunction findLocaleData(locale) {\n const normalizedLocale = normalizeLocale(locale);\n let match = getLocaleData(normalizedLocale);\n if (match) {\n return match;\n }\n // let's try to find a parent locale\n const parentLocale = normalizedLocale.split('-')[0];\n match = getLocaleData(parentLocale);\n if (match) {\n return match;\n }\n if (parentLocale === 'en') {\n return localeEn;\n }\n throw new RuntimeError(701 /* RuntimeErrorCode.MISSING_LOCALE_DATA */, ngDevMode && `Missing locale data for the locale \"${locale}\".`);\n}\n/**\n * Retrieves the default currency code for the given locale.\n *\n * The default is defined as the first currency which is still in use.\n *\n * @param locale The code of the locale whose currency code we want.\n * @returns The code of the default currency for the given locale.\n *\n */\nfunction getLocaleCurrencyCode(locale) {\n const data = findLocaleData(locale);\n return data[LocaleDataIndex.CurrencyCode] || null;\n}\n/**\n * Retrieves the plural function used by ICU expressions to determine the plural case to use\n * for a given locale.\n * @param locale A locale code for the locale format rules to use.\n * @returns The plural function for the locale.\n * @see {@link NgPlural}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n */\nfunction getLocalePluralCase(locale) {\n const data = findLocaleData(locale);\n return data[LocaleDataIndex.PluralCase];\n}\n/**\n * Helper function to get the given `normalizedLocale` from `LOCALE_DATA`\n * or from the global `ng.common.locale`.\n */\nfunction getLocaleData(normalizedLocale) {\n if (!(normalizedLocale in LOCALE_DATA)) {\n LOCALE_DATA[normalizedLocale] = _global.ng && _global.ng.common && _global.ng.common.locales && _global.ng.common.locales[normalizedLocale];\n }\n return LOCALE_DATA[normalizedLocale];\n}\n/**\n * Helper function to remove all the locale data from `LOCALE_DATA`.\n */\nfunction unregisterAllLocaleData() {\n LOCALE_DATA = {};\n}\n/**\n * Index of each type of locale data from the locale data array\n */\nvar LocaleDataIndex;\n(function (LocaleDataIndex) {\n LocaleDataIndex[LocaleDataIndex[\"LocaleId\"] = 0] = \"LocaleId\";\n LocaleDataIndex[LocaleDataIndex[\"DayPeriodsFormat\"] = 1] = \"DayPeriodsFormat\";\n LocaleDataIndex[LocaleDataIndex[\"DayPeriodsStandalone\"] = 2] = \"DayPeriodsStandalone\";\n LocaleDataIndex[LocaleDataIndex[\"DaysFormat\"] = 3] = \"DaysFormat\";\n LocaleDataIndex[LocaleDataIndex[\"DaysStandalone\"] = 4] = \"DaysStandalone\";\n LocaleDataIndex[LocaleDataIndex[\"MonthsFormat\"] = 5] = \"MonthsFormat\";\n LocaleDataIndex[LocaleDataIndex[\"MonthsStandalone\"] = 6] = \"MonthsStandalone\";\n LocaleDataIndex[LocaleDataIndex[\"Eras\"] = 7] = \"Eras\";\n LocaleDataIndex[LocaleDataIndex[\"FirstDayOfWeek\"] = 8] = \"FirstDayOfWeek\";\n LocaleDataIndex[LocaleDataIndex[\"WeekendRange\"] = 9] = \"WeekendRange\";\n LocaleDataIndex[LocaleDataIndex[\"DateFormat\"] = 10] = \"DateFormat\";\n LocaleDataIndex[LocaleDataIndex[\"TimeFormat\"] = 11] = \"TimeFormat\";\n LocaleDataIndex[LocaleDataIndex[\"DateTimeFormat\"] = 12] = \"DateTimeFormat\";\n LocaleDataIndex[LocaleDataIndex[\"NumberSymbols\"] = 13] = \"NumberSymbols\";\n LocaleDataIndex[LocaleDataIndex[\"NumberFormats\"] = 14] = \"NumberFormats\";\n LocaleDataIndex[LocaleDataIndex[\"CurrencyCode\"] = 15] = \"CurrencyCode\";\n LocaleDataIndex[LocaleDataIndex[\"CurrencySymbol\"] = 16] = \"CurrencySymbol\";\n LocaleDataIndex[LocaleDataIndex[\"CurrencyName\"] = 17] = \"CurrencyName\";\n LocaleDataIndex[LocaleDataIndex[\"Currencies\"] = 18] = \"Currencies\";\n LocaleDataIndex[LocaleDataIndex[\"Directionality\"] = 19] = \"Directionality\";\n LocaleDataIndex[LocaleDataIndex[\"PluralCase\"] = 20] = \"PluralCase\";\n LocaleDataIndex[LocaleDataIndex[\"ExtraData\"] = 21] = \"ExtraData\";\n})(LocaleDataIndex || (LocaleDataIndex = {}));\n/**\n * Returns the canonical form of a locale name - lowercase with `_` replaced with `-`.\n */\nfunction normalizeLocale(locale) {\n return locale.toLowerCase().replace(/_/g, '-');\n}\nconst pluralMapping = ['zero', 'one', 'two', 'few', 'many'];\n/**\n * Returns the plural case based on the locale\n */\nfunction getPluralCase(value, locale) {\n const plural = getLocalePluralCase(locale)(parseInt(value, 10));\n const result = pluralMapping[plural];\n return result !== undefined ? result : 'other';\n}\n/**\n * The locale id that the application is using by default (for translations and ICU expressions).\n */\nconst DEFAULT_LOCALE_ID = 'en-US';\n/**\n * USD currency code that the application uses by default for CurrencyPipe when no\n * DEFAULT_CURRENCY_CODE is provided.\n */\nconst USD_CURRENCY_CODE = 'USD';\n\n/**\n * Marks that the next string is an element name.\n *\n * See `I18nMutateOpCodes` documentation.\n */\nconst ELEMENT_MARKER = {\n marker: 'element'\n};\n/**\n * Marks that the next string is comment text need for ICU.\n *\n * See `I18nMutateOpCodes` documentation.\n */\nconst ICU_MARKER = {\n marker: 'ICU'\n};\n/**\n * See `I18nCreateOpCodes`\n */\nvar I18nCreateOpCode;\n(function (I18nCreateOpCode) {\n /**\n * Number of bits to shift index so that it can be combined with the `APPEND_EAGERLY` and\n * `COMMENT`.\n */\n I18nCreateOpCode[I18nCreateOpCode[\"SHIFT\"] = 2] = \"SHIFT\";\n /**\n * Should the node be appended to parent immediately after creation.\n */\n I18nCreateOpCode[I18nCreateOpCode[\"APPEND_EAGERLY\"] = 1] = \"APPEND_EAGERLY\";\n /**\n * If set the node should be comment (rather than a text) node.\n */\n I18nCreateOpCode[I18nCreateOpCode[\"COMMENT\"] = 2] = \"COMMENT\";\n})(I18nCreateOpCode || (I18nCreateOpCode = {}));\n\n/**\n * The locale id that the application is currently using (for translations and ICU expressions).\n * This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine\n * but is now defined as a global value.\n */\nlet LOCALE_ID$1 = DEFAULT_LOCALE_ID;\n/**\n * Sets the locale id that will be used for translations and ICU expressions.\n * This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine\n * but is now defined as a global value.\n *\n * @param localeId\n */\nfunction setLocaleId(localeId) {\n ngDevMode && assertDefined(localeId, `Expected localeId to be defined`);\n if (typeof localeId === 'string') {\n LOCALE_ID$1 = localeId.toLowerCase().replace(/_/g, '-');\n }\n}\n/**\n * Gets the locale id that will be used for translations and ICU expressions.\n * This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine\n * but is now defined as a global value.\n */\nfunction getLocaleId() {\n return LOCALE_ID$1;\n}\n\n/**\n * Keep track of which input bindings in `ɵɵi18nExp` have changed.\n *\n * This is used to efficiently update expressions in i18n only when the corresponding input has\n * changed.\n *\n * 1) Each bit represents which of the `ɵɵi18nExp` has changed.\n * 2) There are 32 bits allowed in JS.\n * 3) Bit 32 is special as it is shared for all changes past 32. (In other words if you have more\n * than 32 `ɵɵi18nExp` then all changes past 32nd `ɵɵi18nExp` will be mapped to same bit. This means\n * that we may end up changing more than we need to. But i18n expressions with 32 bindings is rare\n * so in practice it should not be an issue.)\n */\nlet changeMask = 0b0;\n/**\n * Keeps track of which bit needs to be updated in `changeMask`\n *\n * This value gets incremented on every call to `ɵɵi18nExp`\n */\nlet changeMaskCounter = 0;\n/**\n * Keep track of which input bindings in `ɵɵi18nExp` have changed.\n *\n * `setMaskBit` gets invoked by each call to `ɵɵi18nExp`.\n *\n * @param hasChange did `ɵɵi18nExp` detect a change.\n */\nfunction setMaskBit(hasChange) {\n if (hasChange) {\n changeMask = changeMask | 1 << Math.min(changeMaskCounter, 31);\n }\n changeMaskCounter++;\n}\nfunction applyI18n(tView, lView, index) {\n if (changeMaskCounter > 0) {\n ngDevMode && assertDefined(tView, `tView should be defined`);\n const tI18n = tView.data[index];\n // When `index` points to an `ɵɵi18nAttributes` then we have an array otherwise `TI18n`\n const updateOpCodes = Array.isArray(tI18n) ? tI18n : tI18n.update;\n const bindingsStartIndex = getBindingIndex() - changeMaskCounter - 1;\n applyUpdateOpCodes(tView, lView, updateOpCodes, bindingsStartIndex, changeMask);\n }\n // Reset changeMask & maskBit to default for the next update cycle\n changeMask = 0b0;\n changeMaskCounter = 0;\n}\nfunction createNodeWithoutHydration(lView, textOrName, nodeType) {\n const renderer = lView[RENDERER];\n switch (nodeType) {\n case Node.COMMENT_NODE:\n return createCommentNode(renderer, textOrName);\n case Node.TEXT_NODE:\n return createTextNode(renderer, textOrName);\n case Node.ELEMENT_NODE:\n return createElementNode(renderer, textOrName, null);\n }\n}\nlet _locateOrCreateNode = (lView, index, textOrName, nodeType) => {\n lastNodeWasCreated(true);\n return createNodeWithoutHydration(lView, textOrName, nodeType);\n};\nfunction locateOrCreateNodeImpl(lView, index, textOrName, nodeType) {\n const hydrationInfo = lView[HYDRATION];\n const noOffsetIndex = index - HEADER_OFFSET;\n const isNodeCreationMode = !isI18nHydrationSupportEnabled() || !hydrationInfo || isInSkipHydrationBlock$1() || isDisconnectedNode$1(hydrationInfo, noOffsetIndex);\n lastNodeWasCreated(isNodeCreationMode);\n if (isNodeCreationMode) {\n return createNodeWithoutHydration(lView, textOrName, nodeType);\n }\n const native = locateI18nRNodeByIndex(hydrationInfo, noOffsetIndex);\n // TODO: Improve error handling\n //\n // Other hydration paths use validateMatchingNode() in order to provide\n // detailed information in development mode about the expected DOM.\n // However, not every node in an i18n block has a TNode. Instead, we\n // need to be able to use the AST to generate a similar message.\n ngDevMode && assertDefined(native, 'expected native element');\n ngDevMode && assertEqual(native.nodeType, nodeType, 'expected matching nodeType');\n ngDevMode && nodeType === Node.ELEMENT_NODE && assertEqual(native.tagName.toLowerCase(), textOrName.toLowerCase(), 'expecting matching tagName');\n ngDevMode && markRNodeAsClaimedByHydration(native);\n return native;\n}\nfunction enableLocateOrCreateI18nNodeImpl() {\n _locateOrCreateNode = locateOrCreateNodeImpl;\n}\n/**\n * Apply `I18nCreateOpCodes` op-codes as stored in `TI18n.create`.\n *\n * Creates text (and comment) nodes which are internationalized.\n *\n * @param lView Current lView\n * @param createOpCodes Set of op-codes to apply\n * @param parentRNode Parent node (so that direct children can be added eagerly) or `null` if it is\n * a root node.\n * @param insertInFrontOf DOM node that should be used as an anchor.\n */\nfunction applyCreateOpCodes(lView, createOpCodes, parentRNode, insertInFrontOf) {\n const renderer = lView[RENDERER];\n for (let i = 0; i < createOpCodes.length; i++) {\n const opCode = createOpCodes[i++];\n const text = createOpCodes[i];\n const isComment = (opCode & I18nCreateOpCode.COMMENT) === I18nCreateOpCode.COMMENT;\n const appendNow = (opCode & I18nCreateOpCode.APPEND_EAGERLY) === I18nCreateOpCode.APPEND_EAGERLY;\n const index = opCode >>> I18nCreateOpCode.SHIFT;\n let rNode = lView[index];\n let lastNodeWasCreated = false;\n if (rNode === null) {\n // We only create new DOM nodes if they don't already exist: If ICU switches case back to a\n // case which was already instantiated, no need to create new DOM nodes.\n rNode = lView[index] = _locateOrCreateNode(lView, index, text, isComment ? Node.COMMENT_NODE : Node.TEXT_NODE);\n lastNodeWasCreated = wasLastNodeCreated();\n }\n if (appendNow && parentRNode !== null && lastNodeWasCreated) {\n nativeInsertBefore(renderer, parentRNode, rNode, insertInFrontOf, false);\n }\n }\n}\n/**\n * Apply `I18nMutateOpCodes` OpCodes.\n *\n * @param tView Current `TView`\n * @param mutableOpCodes Mutable OpCodes to process\n * @param lView Current `LView`\n * @param anchorRNode place where the i18n node should be inserted.\n */\nfunction applyMutableOpCodes(tView, mutableOpCodes, lView, anchorRNode) {\n ngDevMode && assertDomNode(anchorRNode);\n const renderer = lView[RENDERER];\n // `rootIdx` represents the node into which all inserts happen.\n let rootIdx = null;\n // `rootRNode` represents the real node into which we insert. This can be different from\n // `lView[rootIdx]` if we have projection.\n // - null we don't have a parent (as can be the case in when we are inserting into a root of\n // LView which has no parent.)\n // - `RElement` The element representing the root after taking projection into account.\n let rootRNode;\n for (let i = 0; i < mutableOpCodes.length; i++) {\n const opCode = mutableOpCodes[i];\n if (typeof opCode == 'string') {\n const textNodeIndex = mutableOpCodes[++i];\n if (lView[textNodeIndex] === null) {\n ngDevMode && ngDevMode.rendererCreateTextNode++;\n ngDevMode && assertIndexInRange(lView, textNodeIndex);\n lView[textNodeIndex] = _locateOrCreateNode(lView, textNodeIndex, opCode, Node.TEXT_NODE);\n }\n } else if (typeof opCode == 'number') {\n switch (opCode & 1 /* IcuCreateOpCode.MASK_INSTRUCTION */) {\n case 0 /* IcuCreateOpCode.AppendChild */:\n const parentIdx = getParentFromIcuCreateOpCode(opCode);\n if (rootIdx === null) {\n // The first operation should save the `rootIdx` because the first operation\n // must insert into the root. (Only subsequent operations can insert into a dynamic\n // parent)\n rootIdx = parentIdx;\n rootRNode = renderer.parentNode(anchorRNode);\n }\n let insertInFrontOf;\n let parentRNode;\n if (parentIdx === rootIdx) {\n insertInFrontOf = anchorRNode;\n parentRNode = rootRNode;\n } else {\n insertInFrontOf = null;\n parentRNode = unwrapRNode(lView[parentIdx]);\n }\n // FIXME(misko): Refactor with `processI18nText`\n if (parentRNode !== null) {\n // This can happen if the `LView` we are adding to is not attached to a parent `LView`.\n // In such a case there is no \"root\" we can attach to. This is fine, as we still need to\n // create the elements. When the `LView` gets later added to a parent these \"root\" nodes\n // get picked up and added.\n ngDevMode && assertDomNode(parentRNode);\n const refIdx = getRefFromIcuCreateOpCode(opCode);\n ngDevMode && assertGreaterThan(refIdx, HEADER_OFFSET, 'Missing ref');\n // `unwrapRNode` is not needed here as all of these point to RNodes as part of the i18n\n // which can't have components.\n const child = lView[refIdx];\n ngDevMode && assertDomNode(child);\n nativeInsertBefore(renderer, parentRNode, child, insertInFrontOf, false);\n const tIcu = getTIcu(tView, refIdx);\n if (tIcu !== null && typeof tIcu === 'object') {\n // If we just added a comment node which has ICU then that ICU may have already been\n // rendered and therefore we need to re-add it here.\n ngDevMode && assertTIcu(tIcu);\n const caseIndex = getCurrentICUCaseIndex(tIcu, lView);\n if (caseIndex !== null) {\n applyMutableOpCodes(tView, tIcu.create[caseIndex], lView, lView[tIcu.anchorIdx]);\n }\n }\n }\n break;\n case 1 /* IcuCreateOpCode.Attr */:\n const elementNodeIndex = opCode >>> 1 /* IcuCreateOpCode.SHIFT_REF */;\n const attrName = mutableOpCodes[++i];\n const attrValue = mutableOpCodes[++i];\n // This code is used for ICU expressions only, since we don't support\n // directives/components in ICUs, we don't need to worry about inputs here\n setElementAttribute(renderer, getNativeByIndex(elementNodeIndex, lView), null, null, attrName, attrValue, null);\n break;\n default:\n if (ngDevMode) {\n throw new RuntimeError(700 /* RuntimeErrorCode.INVALID_I18N_STRUCTURE */, `Unable to determine the type of mutate operation for \"${opCode}\"`);\n }\n }\n } else {\n switch (opCode) {\n case ICU_MARKER:\n const commentValue = mutableOpCodes[++i];\n const commentNodeIndex = mutableOpCodes[++i];\n if (lView[commentNodeIndex] === null) {\n ngDevMode && assertEqual(typeof commentValue, 'string', `Expected \"${commentValue}\" to be a comment node value`);\n ngDevMode && ngDevMode.rendererCreateComment++;\n ngDevMode && assertIndexInExpandoRange(lView, commentNodeIndex);\n const commentRNode = lView[commentNodeIndex] = _locateOrCreateNode(lView, commentNodeIndex, commentValue, Node.COMMENT_NODE);\n // FIXME(misko): Attaching patch data is only needed for the root (Also add tests)\n attachPatchData(commentRNode, lView);\n }\n break;\n case ELEMENT_MARKER:\n const tagName = mutableOpCodes[++i];\n const elementNodeIndex = mutableOpCodes[++i];\n if (lView[elementNodeIndex] === null) {\n ngDevMode && assertEqual(typeof tagName, 'string', `Expected \"${tagName}\" to be an element node tag name`);\n ngDevMode && ngDevMode.rendererCreateElement++;\n ngDevMode && assertIndexInExpandoRange(lView, elementNodeIndex);\n const elementRNode = lView[elementNodeIndex] = _locateOrCreateNode(lView, elementNodeIndex, tagName, Node.ELEMENT_NODE);\n // FIXME(misko): Attaching patch data is only needed for the root (Also add tests)\n attachPatchData(elementRNode, lView);\n }\n break;\n default:\n ngDevMode && throwError(`Unable to determine the type of mutate operation for \"${opCode}\"`);\n }\n }\n }\n}\n/**\n * Apply `I18nUpdateOpCodes` OpCodes\n *\n * @param tView Current `TView`\n * @param lView Current `LView`\n * @param updateOpCodes OpCodes to process\n * @param bindingsStartIndex Location of the first `ɵɵi18nApply`\n * @param changeMask Each bit corresponds to a `ɵɵi18nExp` (Counting backwards from\n * `bindingsStartIndex`)\n */\nfunction applyUpdateOpCodes(tView, lView, updateOpCodes, bindingsStartIndex, changeMask) {\n for (let i = 0; i < updateOpCodes.length; i++) {\n // bit code to check if we should apply the next update\n const checkBit = updateOpCodes[i];\n // Number of opCodes to skip until next set of update codes\n const skipCodes = updateOpCodes[++i];\n if (checkBit & changeMask) {\n // The value has been updated since last checked\n let value = '';\n for (let j = i + 1; j <= i + skipCodes; j++) {\n const opCode = updateOpCodes[j];\n if (typeof opCode == 'string') {\n value += opCode;\n } else if (typeof opCode == 'number') {\n if (opCode < 0) {\n // Negative opCode represent `i18nExp` values offset.\n value += renderStringify(lView[bindingsStartIndex - opCode]);\n } else {\n const nodeIndex = opCode >>> 2 /* I18nUpdateOpCode.SHIFT_REF */;\n switch (opCode & 3 /* I18nUpdateOpCode.MASK_OPCODE */) {\n case 1 /* I18nUpdateOpCode.Attr */:\n const propName = updateOpCodes[++j];\n const sanitizeFn = updateOpCodes[++j];\n const tNodeOrTagName = tView.data[nodeIndex];\n ngDevMode && assertDefined(tNodeOrTagName, 'Experting TNode or string');\n if (typeof tNodeOrTagName === 'string') {\n // IF we don't have a `TNode`, then we are an element in ICU (as ICU content does\n // not have TNode), in which case we know that there are no directives, and hence\n // we use attribute setting.\n setElementAttribute(lView[RENDERER], lView[nodeIndex], null, tNodeOrTagName, propName, value, sanitizeFn);\n } else {\n elementPropertyInternal(tView, tNodeOrTagName, lView, propName, value, lView[RENDERER], sanitizeFn, false);\n }\n break;\n case 0 /* I18nUpdateOpCode.Text */:\n const rText = lView[nodeIndex];\n rText !== null && updateTextNode(lView[RENDERER], rText, value);\n break;\n case 2 /* I18nUpdateOpCode.IcuSwitch */:\n applyIcuSwitchCase(tView, getTIcu(tView, nodeIndex), lView, value);\n break;\n case 3 /* I18nUpdateOpCode.IcuUpdate */:\n applyIcuUpdateCase(tView, getTIcu(tView, nodeIndex), bindingsStartIndex, lView);\n break;\n }\n }\n }\n }\n } else {\n const opCode = updateOpCodes[i + 1];\n if (opCode > 0 && (opCode & 3 /* I18nUpdateOpCode.MASK_OPCODE */) === 3 /* I18nUpdateOpCode.IcuUpdate */) {\n // Special case for the `icuUpdateCase`. It could be that the mask did not match, but\n // we still need to execute `icuUpdateCase` because the case has changed recently due to\n // previous `icuSwitchCase` instruction. (`icuSwitchCase` and `icuUpdateCase` always come in\n // pairs.)\n const nodeIndex = opCode >>> 2 /* I18nUpdateOpCode.SHIFT_REF */;\n const tIcu = getTIcu(tView, nodeIndex);\n const currentIndex = lView[tIcu.currentCaseLViewIndex];\n if (currentIndex < 0) {\n applyIcuUpdateCase(tView, tIcu, bindingsStartIndex, lView);\n }\n }\n }\n i += skipCodes;\n }\n}\n/**\n * Apply OpCodes associated with updating an existing ICU.\n *\n * @param tView Current `TView`\n * @param tIcu Current `TIcu`\n * @param bindingsStartIndex Location of the first `ɵɵi18nApply`\n * @param lView Current `LView`\n */\nfunction applyIcuUpdateCase(tView, tIcu, bindingsStartIndex, lView) {\n ngDevMode && assertIndexInRange(lView, tIcu.currentCaseLViewIndex);\n let activeCaseIndex = lView[tIcu.currentCaseLViewIndex];\n if (activeCaseIndex !== null) {\n let mask = changeMask;\n if (activeCaseIndex < 0) {\n // Clear the flag.\n // Negative number means that the ICU was freshly created and we need to force the update.\n activeCaseIndex = lView[tIcu.currentCaseLViewIndex] = ~activeCaseIndex;\n // -1 is same as all bits on, which simulates creation since it marks all bits dirty\n mask = -1;\n }\n applyUpdateOpCodes(tView, lView, tIcu.update[activeCaseIndex], bindingsStartIndex, mask);\n }\n}\n/**\n * Apply OpCodes associated with switching a case on ICU.\n *\n * This involves tearing down existing case and than building up a new case.\n *\n * @param tView Current `TView`\n * @param tIcu Current `TIcu`\n * @param lView Current `LView`\n * @param value Value of the case to update to.\n */\nfunction applyIcuSwitchCase(tView, tIcu, lView, value) {\n // Rebuild a new case for this ICU\n const caseIndex = getCaseIndex(tIcu, value);\n let activeCaseIndex = getCurrentICUCaseIndex(tIcu, lView);\n if (activeCaseIndex !== caseIndex) {\n applyIcuSwitchCaseRemove(tView, tIcu, lView);\n lView[tIcu.currentCaseLViewIndex] = caseIndex === null ? null : ~caseIndex;\n if (caseIndex !== null) {\n // Add the nodes for the new case\n const anchorRNode = lView[tIcu.anchorIdx];\n if (anchorRNode) {\n ngDevMode && assertDomNode(anchorRNode);\n applyMutableOpCodes(tView, tIcu.create[caseIndex], lView, anchorRNode);\n }\n claimDehydratedIcuCase(lView, tIcu.anchorIdx, caseIndex);\n }\n }\n}\n/**\n * Apply OpCodes associated with tearing ICU case.\n *\n * This involves tearing down existing case and than building up a new case.\n *\n * @param tView Current `TView`\n * @param tIcu Current `TIcu`\n * @param lView Current `LView`\n */\nfunction applyIcuSwitchCaseRemove(tView, tIcu, lView) {\n let activeCaseIndex = getCurrentICUCaseIndex(tIcu, lView);\n if (activeCaseIndex !== null) {\n const removeCodes = tIcu.remove[activeCaseIndex];\n for (let i = 0; i < removeCodes.length; i++) {\n const nodeOrIcuIndex = removeCodes[i];\n if (nodeOrIcuIndex > 0) {\n // Positive numbers are `RNode`s.\n const rNode = getNativeByIndex(nodeOrIcuIndex, lView);\n rNode !== null && nativeRemoveNode(lView[RENDERER], rNode);\n } else {\n // Negative numbers are ICUs\n applyIcuSwitchCaseRemove(tView, getTIcu(tView, ~nodeOrIcuIndex), lView);\n }\n }\n }\n}\n/**\n * Returns the index of the current case of an ICU expression depending on the main binding value\n *\n * @param icuExpression\n * @param bindingValue The value of the main binding used by this ICU expression\n */\nfunction getCaseIndex(icuExpression, bindingValue) {\n let index = icuExpression.cases.indexOf(bindingValue);\n if (index === -1) {\n switch (icuExpression.type) {\n case 1 /* IcuType.plural */:\n {\n const resolvedCase = getPluralCase(bindingValue, getLocaleId());\n index = icuExpression.cases.indexOf(resolvedCase);\n if (index === -1 && resolvedCase !== 'other') {\n index = icuExpression.cases.indexOf('other');\n }\n break;\n }\n case 0 /* IcuType.select */:\n {\n index = icuExpression.cases.indexOf('other');\n break;\n }\n }\n }\n return index === -1 ? null : index;\n}\n\n/**\n * Converts `I18nCreateOpCodes` array into a human readable format.\n *\n * This function is attached to the `I18nCreateOpCodes.debug` property if `ngDevMode` is enabled.\n * This function provides a human readable view of the opcodes. This is useful when debugging the\n * application as well as writing more readable tests.\n *\n * @param this `I18nCreateOpCodes` if attached as a method.\n * @param opcodes `I18nCreateOpCodes` if invoked as a function.\n */\nfunction i18nCreateOpCodesToString(opcodes) {\n const createOpCodes = opcodes || (Array.isArray(this) ? this : []);\n let lines = [];\n for (let i = 0; i < createOpCodes.length; i++) {\n const opCode = createOpCodes[i++];\n const text = createOpCodes[i];\n const isComment = (opCode & I18nCreateOpCode.COMMENT) === I18nCreateOpCode.COMMENT;\n const appendNow = (opCode & I18nCreateOpCode.APPEND_EAGERLY) === I18nCreateOpCode.APPEND_EAGERLY;\n const index = opCode >>> I18nCreateOpCode.SHIFT;\n lines.push(`lView[${index}] = document.${isComment ? 'createComment' : 'createText'}(${JSON.stringify(text)});`);\n if (appendNow) {\n lines.push(`parent.appendChild(lView[${index}]);`);\n }\n }\n return lines;\n}\n/**\n * Converts `I18nUpdateOpCodes` array into a human readable format.\n *\n * This function is attached to the `I18nUpdateOpCodes.debug` property if `ngDevMode` is enabled.\n * This function provides a human readable view of the opcodes. This is useful when debugging the\n * application as well as writing more readable tests.\n *\n * @param this `I18nUpdateOpCodes` if attached as a method.\n * @param opcodes `I18nUpdateOpCodes` if invoked as a function.\n */\nfunction i18nUpdateOpCodesToString(opcodes) {\n const parser = new OpCodeParser(opcodes || (Array.isArray(this) ? this : []));\n let lines = [];\n function consumeOpCode(value) {\n const ref = value >>> 2 /* I18nUpdateOpCode.SHIFT_REF */;\n const opCode = value & 3 /* I18nUpdateOpCode.MASK_OPCODE */;\n switch (opCode) {\n case 0 /* I18nUpdateOpCode.Text */:\n return `(lView[${ref}] as Text).textContent = $$$`;\n case 1 /* I18nUpdateOpCode.Attr */:\n const attrName = parser.consumeString();\n const sanitizationFn = parser.consumeFunction();\n const value = sanitizationFn ? `(${sanitizationFn})($$$)` : '$$$';\n return `(lView[${ref}] as Element).setAttribute('${attrName}', ${value})`;\n case 2 /* I18nUpdateOpCode.IcuSwitch */:\n return `icuSwitchCase(${ref}, $$$)`;\n case 3 /* I18nUpdateOpCode.IcuUpdate */:\n return `icuUpdateCase(${ref})`;\n }\n throw new Error('unexpected OpCode');\n }\n while (parser.hasMore()) {\n let mask = parser.consumeNumber();\n let size = parser.consumeNumber();\n const end = parser.i + size;\n const statements = [];\n let statement = '';\n while (parser.i < end) {\n let value = parser.consumeNumberOrString();\n if (typeof value === 'string') {\n statement += value;\n } else if (value < 0) {\n // Negative numbers are ref indexes\n // Here `i` refers to current binding index. It is to signify that the value is relative,\n // rather than absolute.\n statement += '${lView[i' + value + ']}';\n } else {\n // Positive numbers are operations.\n const opCodeText = consumeOpCode(value);\n statements.push(opCodeText.replace('$$$', '`' + statement + '`') + ';');\n statement = '';\n }\n }\n lines.push(`if (mask & 0b${mask.toString(2)}) { ${statements.join(' ')} }`);\n }\n return lines;\n}\n/**\n * Converts `I18nCreateOpCodes` array into a human readable format.\n *\n * This function is attached to the `I18nCreateOpCodes.debug` if `ngDevMode` is enabled. This\n * function provides a human readable view of the opcodes. This is useful when debugging the\n * application as well as writing more readable tests.\n *\n * @param this `I18nCreateOpCodes` if attached as a method.\n * @param opcodes `I18nCreateOpCodes` if invoked as a function.\n */\nfunction icuCreateOpCodesToString(opcodes) {\n const parser = new OpCodeParser(opcodes || (Array.isArray(this) ? this : []));\n let lines = [];\n function consumeOpCode(opCode) {\n const parent = getParentFromIcuCreateOpCode(opCode);\n const ref = getRefFromIcuCreateOpCode(opCode);\n switch (getInstructionFromIcuCreateOpCode(opCode)) {\n case 0 /* IcuCreateOpCode.AppendChild */:\n return `(lView[${parent}] as Element).appendChild(lView[${lastRef}])`;\n case 1 /* IcuCreateOpCode.Attr */:\n return `(lView[${ref}] as Element).setAttribute(\"${parser.consumeString()}\", \"${parser.consumeString()}\")`;\n }\n throw new Error('Unexpected OpCode: ' + getInstructionFromIcuCreateOpCode(opCode));\n }\n let lastRef = -1;\n while (parser.hasMore()) {\n let value = parser.consumeNumberStringOrMarker();\n if (value === ICU_MARKER) {\n const text = parser.consumeString();\n lastRef = parser.consumeNumber();\n lines.push(`lView[${lastRef}] = document.createComment(\"${text}\")`);\n } else if (value === ELEMENT_MARKER) {\n const text = parser.consumeString();\n lastRef = parser.consumeNumber();\n lines.push(`lView[${lastRef}] = document.createElement(\"${text}\")`);\n } else if (typeof value === 'string') {\n lastRef = parser.consumeNumber();\n lines.push(`lView[${lastRef}] = document.createTextNode(\"${value}\")`);\n } else if (typeof value === 'number') {\n const line = consumeOpCode(value);\n line && lines.push(line);\n } else {\n throw new Error('Unexpected value');\n }\n }\n return lines;\n}\n/**\n * Converts `I18nRemoveOpCodes` array into a human readable format.\n *\n * This function is attached to the `I18nRemoveOpCodes.debug` if `ngDevMode` is enabled. This\n * function provides a human readable view of the opcodes. This is useful when debugging the\n * application as well as writing more readable tests.\n *\n * @param this `I18nRemoveOpCodes` if attached as a method.\n * @param opcodes `I18nRemoveOpCodes` if invoked as a function.\n */\nfunction i18nRemoveOpCodesToString(opcodes) {\n const removeCodes = opcodes || (Array.isArray(this) ? this : []);\n let lines = [];\n for (let i = 0; i < removeCodes.length; i++) {\n const nodeOrIcuIndex = removeCodes[i];\n if (nodeOrIcuIndex > 0) {\n // Positive numbers are `RNode`s.\n lines.push(`remove(lView[${nodeOrIcuIndex}])`);\n } else {\n // Negative numbers are ICUs\n lines.push(`removeNestedICU(${~nodeOrIcuIndex})`);\n }\n }\n return lines;\n}\nclass OpCodeParser {\n i = 0;\n codes;\n constructor(codes) {\n this.codes = codes;\n }\n hasMore() {\n return this.i < this.codes.length;\n }\n consumeNumber() {\n let value = this.codes[this.i++];\n assertNumber(value, 'expecting number in OpCode');\n return value;\n }\n consumeString() {\n let value = this.codes[this.i++];\n assertString(value, 'expecting string in OpCode');\n return value;\n }\n consumeFunction() {\n let value = this.codes[this.i++];\n if (value === null || typeof value === 'function') {\n return value;\n }\n throw new Error('expecting function in OpCode');\n }\n consumeNumberOrString() {\n let value = this.codes[this.i++];\n if (typeof value === 'string') {\n return value;\n }\n assertNumber(value, 'expecting number or string in OpCode');\n return value;\n }\n consumeNumberStringOrMarker() {\n let value = this.codes[this.i++];\n if (typeof value === 'string' || typeof value === 'number' || value == ICU_MARKER || value == ELEMENT_MARKER) {\n return value;\n }\n assertNumber(value, 'expecting number, string, ICU_MARKER or ELEMENT_MARKER in OpCode');\n return value;\n }\n}\nconst BINDING_REGEXP = /�(\\d+):?\\d*�/gi;\nconst ICU_REGEXP = /({\\s*�\\d+:?\\d*�\\s*,\\s*\\S{6}\\s*,[\\s\\S]*})/gi;\nconst NESTED_ICU = /�(\\d+)�/;\nconst ICU_BLOCK_REGEXP = /^\\s*(�\\d+:?\\d*�)\\s*,\\s*(select|plural)\\s*,/;\nconst MARKER = `�`;\nconst SUBTEMPLATE_REGEXP = /�\\/?\\*(\\d+:\\d+)�/gi;\nconst PH_REGEXP = /�(\\/?[#*]\\d+):?\\d*�/gi;\n/**\n * Angular uses the special entity &ngsp; as a placeholder for non-removable space.\n * It's replaced by the 0xE500 PUA (Private Use Areas) unicode character and later on replaced by a\n * space.\n * We are re-implementing the same idea since translations might contain this special character.\n */\nconst NGSP_UNICODE_REGEXP = /\\uE500/g;\nfunction replaceNgsp(value) {\n return value.replace(NGSP_UNICODE_REGEXP, ' ');\n}\n/**\n * Patch a `debug` property getter on top of the existing object.\n *\n * NOTE: always call this method with `ngDevMode && attachDebugObject(...)`\n *\n * @param obj Object to patch\n * @param debugGetter Getter returning a value to patch\n */\nfunction attachDebugGetter(obj, debugGetter) {\n if (ngDevMode) {\n Object.defineProperty(obj, 'debug', {\n get: debugGetter,\n enumerable: false\n });\n } else {\n throw new Error('This method should be guarded with `ngDevMode` so that it can be tree shaken in production!');\n }\n}\n/**\n * Create dynamic nodes from i18n translation block.\n *\n * - Text nodes are created synchronously\n * - TNodes are linked into tree lazily\n *\n * @param tView Current `TView`\n * @parentTNodeIndex index to the parent TNode of this i18n block\n * @param lView Current `LView`\n * @param index Index of `ɵɵi18nStart` instruction.\n * @param message Message to translate.\n * @param subTemplateIndex Index into the sub template of message translation. (ie in case of\n * `ngIf`) (-1 otherwise)\n */\nfunction i18nStartFirstCreatePass(tView, parentTNodeIndex, lView, index, message, subTemplateIndex) {\n const rootTNode = getCurrentParentTNode();\n const createOpCodes = [];\n const updateOpCodes = [];\n const existingTNodeStack = [[]];\n const astStack = [[]];\n if (ngDevMode) {\n attachDebugGetter(createOpCodes, i18nCreateOpCodesToString);\n attachDebugGetter(updateOpCodes, i18nUpdateOpCodesToString);\n }\n message = getTranslationForTemplate(message, subTemplateIndex);\n const msgParts = replaceNgsp(message).split(PH_REGEXP);\n for (let i = 0; i < msgParts.length; i++) {\n let value = msgParts[i];\n if ((i & 1) === 0) {\n // Even indexes are text (including bindings & ICU expressions)\n const parts = i18nParseTextIntoPartsAndICU(value);\n for (let j = 0; j < parts.length; j++) {\n let part = parts[j];\n if ((j & 1) === 0) {\n // `j` is odd therefore `part` is string\n const text = part;\n ngDevMode && assertString(text, 'Parsed ICU part should be string');\n if (text !== '') {\n i18nStartFirstCreatePassProcessTextNode(astStack[0], tView, rootTNode, existingTNodeStack[0], createOpCodes, updateOpCodes, lView, text);\n }\n } else {\n // `j` is Even therefor `part` is an `ICUExpression`\n const icuExpression = part;\n // Verify that ICU expression has the right shape. Translations might contain invalid\n // constructions (while original messages were correct), so ICU parsing at runtime may\n // not succeed (thus `icuExpression` remains a string).\n // Note: we intentionally retain the error here by not using `ngDevMode`, because\n // the value can change based on the locale and users aren't guaranteed to hit\n // an invalid string while they're developing.\n if (typeof icuExpression !== 'object') {\n throw new Error(`Unable to parse ICU expression in \"${message}\" message.`);\n }\n const icuContainerTNode = createTNodeAndAddOpCode(tView, rootTNode, existingTNodeStack[0], lView, createOpCodes, ngDevMode ? `ICU ${index}:${icuExpression.mainBinding}` : '', true);\n const icuNodeIndex = icuContainerTNode.index;\n ngDevMode && assertGreaterThanOrEqual(icuNodeIndex, HEADER_OFFSET, 'Index must be in absolute LView offset');\n icuStart(astStack[0], tView, lView, updateOpCodes, parentTNodeIndex, icuExpression, icuNodeIndex);\n }\n }\n } else {\n // Odd indexes are placeholders (elements and sub-templates)\n // At this point value is something like: '/#1:2' (originally coming from '�/#1:2�')\n const isClosing = value.charCodeAt(0) === 47 /* CharCode.SLASH */;\n const type = value.charCodeAt(isClosing ? 1 : 0);\n ngDevMode && assertOneOf(type, 42 /* CharCode.STAR */, 35 /* CharCode.HASH */);\n const index = HEADER_OFFSET + Number.parseInt(value.substring(isClosing ? 2 : 1));\n if (isClosing) {\n existingTNodeStack.shift();\n astStack.shift();\n setCurrentTNode(getCurrentParentTNode(), false);\n } else {\n const tNode = createTNodePlaceholder(tView, existingTNodeStack[0], index);\n existingTNodeStack.unshift([]);\n setCurrentTNode(tNode, true);\n const placeholderNode = {\n kind: 2 /* I18nNodeKind.PLACEHOLDER */,\n index,\n children: [],\n type: type === 35 /* CharCode.HASH */ ? 0 /* I18nPlaceholderType.ELEMENT */ : 1 /* I18nPlaceholderType.SUBTEMPLATE */\n };\n astStack[0].push(placeholderNode);\n astStack.unshift(placeholderNode.children);\n }\n }\n }\n tView.data[index] = {\n create: createOpCodes,\n update: updateOpCodes,\n ast: astStack[0],\n parentTNodeIndex\n };\n}\n/**\n * Allocate space in i18n Range add create OpCode instruction to create a text or comment node.\n *\n * @param tView Current `TView` needed to allocate space in i18n range.\n * @param rootTNode Root `TNode` of the i18n block. This node determines if the new TNode will be\n * added as part of the `i18nStart` instruction or as part of the `TNode.insertBeforeIndex`.\n * @param existingTNodes internal state for `addTNodeAndUpdateInsertBeforeIndex`.\n * @param lView Current `LView` needed to allocate space in i18n range.\n * @param createOpCodes Array storing `I18nCreateOpCodes` where new opCodes will be added.\n * @param text Text to be added when the `Text` or `Comment` node will be created.\n * @param isICU true if a `Comment` node for ICU (instead of `Text`) node should be created.\n */\nfunction createTNodeAndAddOpCode(tView, rootTNode, existingTNodes, lView, createOpCodes, text, isICU) {\n const i18nNodeIdx = allocExpando(tView, lView, 1, null);\n let opCode = i18nNodeIdx << I18nCreateOpCode.SHIFT;\n let parentTNode = getCurrentParentTNode();\n if (rootTNode === parentTNode) {\n // FIXME(misko): A null `parentTNode` should represent when we fall of the `LView` boundary.\n // (there is no parent), but in some circumstances (because we are inconsistent about how we set\n // `previousOrParentTNode`) it could point to `rootTNode` So this is a work around.\n parentTNode = null;\n }\n if (parentTNode === null) {\n // If we don't have a parent that means that we can eagerly add nodes.\n // If we have a parent than these nodes can't be added now (as the parent has not been created\n // yet) and instead the `parentTNode` is responsible for adding it. See\n // `TNode.insertBeforeIndex`\n opCode |= I18nCreateOpCode.APPEND_EAGERLY;\n }\n if (isICU) {\n opCode |= I18nCreateOpCode.COMMENT;\n ensureIcuContainerVisitorLoaded(loadIcuContainerVisitor);\n }\n createOpCodes.push(opCode, text === null ? '' : text);\n // We store `{{?}}` so that when looking at debug `TNodeType.template` we can see where the\n // bindings are.\n const tNode = createTNodeAtIndex(tView, i18nNodeIdx, isICU ? 32 /* TNodeType.Icu */ : 1 /* TNodeType.Text */, text === null ? ngDevMode ? '{{?}}' : '' : text, null);\n addTNodeAndUpdateInsertBeforeIndex(existingTNodes, tNode);\n const tNodeIdx = tNode.index;\n setCurrentTNode(tNode, false /* Text nodes are self closing */);\n if (parentTNode !== null && rootTNode !== parentTNode) {\n // We are a child of deeper node (rather than a direct child of `i18nStart` instruction.)\n // We have to make sure to add ourselves to the parent.\n setTNodeInsertBeforeIndex(parentTNode, tNodeIdx);\n }\n return tNode;\n}\n/**\n * Processes text node in i18n block.\n *\n * Text nodes can have:\n * - Create instruction in `createOpCodes` for creating the text node.\n * - Allocate spec for text node in i18n range of `LView`\n * - If contains binding:\n * - bindings => allocate space in i18n range of `LView` to store the binding value.\n * - populate `updateOpCodes` with update instructions.\n *\n * @param tView Current `TView`\n * @param rootTNode Root `TNode` of the i18n block. This node determines if the new TNode will\n * be added as part of the `i18nStart` instruction or as part of the\n * `TNode.insertBeforeIndex`.\n * @param existingTNodes internal state for `addTNodeAndUpdateInsertBeforeIndex`.\n * @param createOpCodes Location where the creation OpCodes will be stored.\n * @param lView Current `LView`\n * @param text The translated text (which may contain binding)\n */\nfunction i18nStartFirstCreatePassProcessTextNode(ast, tView, rootTNode, existingTNodes, createOpCodes, updateOpCodes, lView, text) {\n const hasBinding = text.match(BINDING_REGEXP);\n const tNode = createTNodeAndAddOpCode(tView, rootTNode, existingTNodes, lView, createOpCodes, hasBinding ? null : text, false);\n const index = tNode.index;\n if (hasBinding) {\n generateBindingUpdateOpCodes(updateOpCodes, text, index, null, 0, null);\n }\n ast.push({\n kind: 0 /* I18nNodeKind.TEXT */,\n index\n });\n}\n/**\n * See `i18nAttributes` above.\n */\nfunction i18nAttributesFirstPass(tView, index, values) {\n const previousElement = getCurrentTNode();\n const previousElementIndex = previousElement.index;\n const updateOpCodes = [];\n if (ngDevMode) {\n attachDebugGetter(updateOpCodes, i18nUpdateOpCodesToString);\n }\n if (tView.firstCreatePass && tView.data[index] === null) {\n for (let i = 0; i < values.length; i += 2) {\n const attrName = values[i];\n const message = values[i + 1];\n if (message !== '') {\n // Check if attribute value contains an ICU and throw an error if that's the case.\n // ICUs in element attributes are not supported.\n // Note: we intentionally retain the error here by not using `ngDevMode`, because\n // the `value` can change based on the locale and users aren't guaranteed to hit\n // an invalid string while they're developing.\n if (ICU_REGEXP.test(message)) {\n throw new Error(`ICU expressions are not supported in attributes. Message: \"${message}\".`);\n }\n // i18n attributes that hit this code path are guaranteed to have bindings, because\n // the compiler treats static i18n attributes as regular attribute bindings.\n // Since this may not be the first i18n attribute on this element we need to pass in how\n // many previous bindings there have already been.\n generateBindingUpdateOpCodes(updateOpCodes, message, previousElementIndex, attrName, countBindings(updateOpCodes), null);\n }\n }\n tView.data[index] = updateOpCodes;\n }\n}\n/**\n * Generate the OpCodes to update the bindings of a string.\n *\n * @param updateOpCodes Place where the update opcodes will be stored.\n * @param str The string containing the bindings.\n * @param destinationNode Index of the destination node which will receive the binding.\n * @param attrName Name of the attribute, if the string belongs to an attribute.\n * @param sanitizeFn Sanitization function used to sanitize the string after update, if necessary.\n * @param bindingStart The lView index of the next expression that can be bound via an opCode.\n * @returns The mask value for these bindings\n */\nfunction generateBindingUpdateOpCodes(updateOpCodes, str, destinationNode, attrName, bindingStart, sanitizeFn) {\n ngDevMode && assertGreaterThanOrEqual(destinationNode, HEADER_OFFSET, 'Index must be in absolute LView offset');\n const maskIndex = updateOpCodes.length; // Location of mask\n const sizeIndex = maskIndex + 1; // location of size for skipping\n updateOpCodes.push(null, null); // Alloc space for mask and size\n const startIndex = maskIndex + 2; // location of first allocation.\n if (ngDevMode) {\n attachDebugGetter(updateOpCodes, i18nUpdateOpCodesToString);\n }\n const textParts = str.split(BINDING_REGEXP);\n let mask = 0;\n for (let j = 0; j < textParts.length; j++) {\n const textValue = textParts[j];\n if (j & 1) {\n // Odd indexes are bindings\n const bindingIndex = bindingStart + parseInt(textValue, 10);\n updateOpCodes.push(-1 - bindingIndex);\n mask = mask | toMaskBit(bindingIndex);\n } else if (textValue !== '') {\n // Even indexes are text\n updateOpCodes.push(textValue);\n }\n }\n updateOpCodes.push(destinationNode << 2 /* I18nUpdateOpCode.SHIFT_REF */ | (attrName ? 1 /* I18nUpdateOpCode.Attr */ : 0 /* I18nUpdateOpCode.Text */));\n if (attrName) {\n updateOpCodes.push(attrName, sanitizeFn);\n }\n updateOpCodes[maskIndex] = mask;\n updateOpCodes[sizeIndex] = updateOpCodes.length - startIndex;\n return mask;\n}\n/**\n * Count the number of bindings in the given `opCodes`.\n *\n * It could be possible to speed this up, by passing the number of bindings found back from\n * `generateBindingUpdateOpCodes()` to `i18nAttributesFirstPass()` but this would then require more\n * complexity in the code and/or transient objects to be created.\n *\n * Since this function is only called once when the template is instantiated, is trivial in the\n * first instance (since `opCodes` will be an empty array), and it is not common for elements to\n * contain multiple i18n bound attributes, it seems like this is a reasonable compromise.\n */\nfunction countBindings(opCodes) {\n let count = 0;\n for (let i = 0; i < opCodes.length; i++) {\n const opCode = opCodes[i];\n // Bindings are negative numbers.\n if (typeof opCode === 'number' && opCode < 0) {\n count++;\n }\n }\n return count;\n}\n/**\n * Convert binding index to mask bit.\n *\n * Each index represents a single bit on the bit-mask. Because bit-mask only has 32 bits, we make\n * the 32nd bit share all masks for all bindings higher than 32. Since it is extremely rare to\n * have more than 32 bindings this will be hit very rarely. The downside of hitting this corner\n * case is that we will execute binding code more often than necessary. (penalty of performance)\n */\nfunction toMaskBit(bindingIndex) {\n return 1 << Math.min(bindingIndex, 31);\n}\n/**\n * Removes everything inside the sub-templates of a message.\n */\nfunction removeInnerTemplateTranslation(message) {\n let match;\n let res = '';\n let index = 0;\n let inTemplate = false;\n let tagMatched;\n while ((match = SUBTEMPLATE_REGEXP.exec(message)) !== null) {\n if (!inTemplate) {\n res += message.substring(index, match.index + match[0].length);\n tagMatched = match[1];\n inTemplate = true;\n } else {\n if (match[0] === `${MARKER}/*${tagMatched}${MARKER}`) {\n index = match.index;\n inTemplate = false;\n }\n }\n }\n ngDevMode && assertEqual(inTemplate, false, `Tag mismatch: unable to find the end of the sub-template in the translation \"${message}\"`);\n res += message.slice(index);\n return res;\n}\n/**\n * Extracts a part of a message and removes the rest.\n *\n * This method is used for extracting a part of the message associated with a template. A\n * translated message can span multiple templates.\n *\n * Example:\n * ```html\n * <div i18n>Translate <span *ngIf>me</span>!</div>\n * ```\n *\n * @param message The message to crop\n * @param subTemplateIndex Index of the sub-template to extract. If undefined it returns the\n * external template and removes all sub-templates.\n */\nfunction getTranslationForTemplate(message, subTemplateIndex) {\n if (isRootTemplateMessage(subTemplateIndex)) {\n // We want the root template message, ignore all sub-templates\n return removeInnerTemplateTranslation(message);\n } else {\n // We want a specific sub-template\n const start = message.indexOf(`:${subTemplateIndex}${MARKER}`) + 2 + subTemplateIndex.toString().length;\n const end = message.search(new RegExp(`${MARKER}\\\\/\\\\*\\\\d+:${subTemplateIndex}${MARKER}`));\n return removeInnerTemplateTranslation(message.substring(start, end));\n }\n}\n/**\n * Generate the OpCodes for ICU expressions.\n *\n * @param icuExpression\n * @param index Index where the anchor is stored and an optional `TIcuContainerNode`\n * - `lView[anchorIdx]` points to a `Comment` node representing the anchor for the ICU.\n * - `tView.data[anchorIdx]` points to the `TIcuContainerNode` if ICU is root (`null` otherwise)\n */\nfunction icuStart(ast, tView, lView, updateOpCodes, parentIdx, icuExpression, anchorIdx) {\n ngDevMode && assertDefined(icuExpression, 'ICU expression must be defined');\n let bindingMask = 0;\n const tIcu = {\n type: icuExpression.type,\n currentCaseLViewIndex: allocExpando(tView, lView, 1, null),\n anchorIdx,\n cases: [],\n create: [],\n remove: [],\n update: []\n };\n addUpdateIcuSwitch(updateOpCodes, icuExpression, anchorIdx);\n setTIcu(tView, anchorIdx, tIcu);\n const values = icuExpression.values;\n const cases = [];\n for (let i = 0; i < values.length; i++) {\n // Each value is an array of strings & other ICU expressions\n const valueArr = values[i];\n const nestedIcus = [];\n for (let j = 0; j < valueArr.length; j++) {\n const value = valueArr[j];\n if (typeof value !== 'string') {\n // It is an nested ICU expression\n const icuIndex = nestedIcus.push(value) - 1;\n // Replace nested ICU expression by a comment node\n valueArr[j] = `<!--�${icuIndex}�-->`;\n }\n }\n const caseAst = [];\n cases.push(caseAst);\n bindingMask = parseIcuCase(caseAst, tView, tIcu, lView, updateOpCodes, parentIdx, icuExpression.cases[i], valueArr.join(''), nestedIcus) | bindingMask;\n }\n if (bindingMask) {\n addUpdateIcuUpdate(updateOpCodes, bindingMask, anchorIdx);\n }\n ast.push({\n kind: 3 /* I18nNodeKind.ICU */,\n index: anchorIdx,\n cases,\n currentCaseLViewIndex: tIcu.currentCaseLViewIndex\n });\n}\n/**\n * Parses text containing an ICU expression and produces a JSON object for it.\n * Original code from closure library, modified for Angular.\n *\n * @param pattern Text containing an ICU expression that needs to be parsed.\n *\n */\nfunction parseICUBlock(pattern) {\n const cases = [];\n const values = [];\n let icuType = 1 /* IcuType.plural */;\n let mainBinding = 0;\n pattern = pattern.replace(ICU_BLOCK_REGEXP, function (str, binding, type) {\n if (type === 'select') {\n icuType = 0 /* IcuType.select */;\n } else {\n icuType = 1 /* IcuType.plural */;\n }\n mainBinding = parseInt(binding.slice(1), 10);\n return '';\n });\n const parts = i18nParseTextIntoPartsAndICU(pattern);\n // Looking for (key block)+ sequence. One of the keys has to be \"other\".\n for (let pos = 0; pos < parts.length;) {\n let key = parts[pos++].trim();\n if (icuType === 1 /* IcuType.plural */) {\n // Key can be \"=x\", we just want \"x\"\n key = key.replace(/\\s*(?:=)?(\\w+)\\s*/, '$1');\n }\n if (key.length) {\n cases.push(key);\n }\n const blocks = i18nParseTextIntoPartsAndICU(parts[pos++]);\n if (cases.length > values.length) {\n values.push(blocks);\n }\n }\n // TODO(ocombe): support ICU expressions in attributes, see #21615\n return {\n type: icuType,\n mainBinding: mainBinding,\n cases,\n values\n };\n}\n/**\n * Breaks pattern into strings and top level {...} blocks.\n * Can be used to break a message into text and ICU expressions, or to break an ICU expression\n * into keys and cases. Original code from closure library, modified for Angular.\n *\n * @param pattern (sub)Pattern to be broken.\n * @returns An `Array<string|IcuExpression>` where:\n * - odd positions: `string` => text between ICU expressions\n * - even positions: `ICUExpression` => ICU expression parsed into `ICUExpression` record.\n */\nfunction i18nParseTextIntoPartsAndICU(pattern) {\n if (!pattern) {\n return [];\n }\n let prevPos = 0;\n const braceStack = [];\n const results = [];\n const braces = /[{}]/g;\n // lastIndex doesn't get set to 0 so we have to.\n braces.lastIndex = 0;\n let match;\n while (match = braces.exec(pattern)) {\n const pos = match.index;\n if (match[0] == '}') {\n braceStack.pop();\n if (braceStack.length == 0) {\n // End of the block.\n const block = pattern.substring(prevPos, pos);\n if (ICU_BLOCK_REGEXP.test(block)) {\n results.push(parseICUBlock(block));\n } else {\n results.push(block);\n }\n prevPos = pos + 1;\n }\n } else {\n if (braceStack.length == 0) {\n const substring = pattern.substring(prevPos, pos);\n results.push(substring);\n prevPos = pos + 1;\n }\n braceStack.push('{');\n }\n }\n const substring = pattern.substring(prevPos);\n results.push(substring);\n return results;\n}\n/**\n * Parses a node, its children and its siblings, and generates the mutate & update OpCodes.\n *\n */\nfunction parseIcuCase(ast, tView, tIcu, lView, updateOpCodes, parentIdx, caseName, unsafeCaseHtml, nestedIcus) {\n const create = [];\n const remove = [];\n const update = [];\n if (ngDevMode) {\n attachDebugGetter(create, icuCreateOpCodesToString);\n attachDebugGetter(remove, i18nRemoveOpCodesToString);\n attachDebugGetter(update, i18nUpdateOpCodesToString);\n }\n tIcu.cases.push(caseName);\n tIcu.create.push(create);\n tIcu.remove.push(remove);\n tIcu.update.push(update);\n const inertBodyHelper = getInertBodyHelper(getDocument());\n const inertBodyElement = inertBodyHelper.getInertBodyElement(unsafeCaseHtml);\n ngDevMode && assertDefined(inertBodyElement, 'Unable to generate inert body element');\n const inertRootNode = getTemplateContent(inertBodyElement) || inertBodyElement;\n if (inertRootNode) {\n return walkIcuTree(ast, tView, tIcu, lView, updateOpCodes, create, remove, update, inertRootNode, parentIdx, nestedIcus, 0);\n } else {\n return 0;\n }\n}\nfunction walkIcuTree(ast, tView, tIcu, lView, sharedUpdateOpCodes, create, remove, update, parentNode, parentIdx, nestedIcus, depth) {\n let bindingMask = 0;\n let currentNode = parentNode.firstChild;\n while (currentNode) {\n const newIndex = allocExpando(tView, lView, 1, null);\n switch (currentNode.nodeType) {\n case Node.ELEMENT_NODE:\n const element = currentNode;\n const tagName = element.tagName.toLowerCase();\n if (VALID_ELEMENTS.hasOwnProperty(tagName)) {\n addCreateNodeAndAppend(create, ELEMENT_MARKER, tagName, parentIdx, newIndex);\n tView.data[newIndex] = tagName;\n const elAttrs = element.attributes;\n for (let i = 0; i < elAttrs.length; i++) {\n const attr = elAttrs.item(i);\n const lowerAttrName = attr.name.toLowerCase();\n const hasBinding = !!attr.value.match(BINDING_REGEXP);\n // we assume the input string is safe, unless it's using a binding\n if (hasBinding) {\n if (VALID_ATTRS.hasOwnProperty(lowerAttrName)) {\n if (URI_ATTRS[lowerAttrName]) {\n generateBindingUpdateOpCodes(update, attr.value, newIndex, attr.name, 0, _sanitizeUrl);\n } else {\n generateBindingUpdateOpCodes(update, attr.value, newIndex, attr.name, 0, null);\n }\n } else {\n ngDevMode && console.warn(`WARNING: ignoring unsafe attribute value ` + `${lowerAttrName} on element ${tagName} ` + `(see ${XSS_SECURITY_URL})`);\n }\n } else {\n addCreateAttribute(create, newIndex, attr);\n }\n }\n const elementNode = {\n kind: 1 /* I18nNodeKind.ELEMENT */,\n index: newIndex,\n children: []\n };\n ast.push(elementNode);\n // Parse the children of this node (if any)\n bindingMask = walkIcuTree(elementNode.children, tView, tIcu, lView, sharedUpdateOpCodes, create, remove, update, currentNode, newIndex, nestedIcus, depth + 1) | bindingMask;\n addRemoveNode(remove, newIndex, depth);\n }\n break;\n case Node.TEXT_NODE:\n const value = currentNode.textContent || '';\n const hasBinding = value.match(BINDING_REGEXP);\n addCreateNodeAndAppend(create, null, hasBinding ? '' : value, parentIdx, newIndex);\n addRemoveNode(remove, newIndex, depth);\n if (hasBinding) {\n bindingMask = generateBindingUpdateOpCodes(update, value, newIndex, null, 0, null) | bindingMask;\n }\n ast.push({\n kind: 0 /* I18nNodeKind.TEXT */,\n index: newIndex\n });\n break;\n case Node.COMMENT_NODE:\n // Check if the comment node is a placeholder for a nested ICU\n const isNestedIcu = NESTED_ICU.exec(currentNode.textContent || '');\n if (isNestedIcu) {\n const nestedIcuIndex = parseInt(isNestedIcu[1], 10);\n const icuExpression = nestedIcus[nestedIcuIndex];\n // Create the comment node that will anchor the ICU expression\n addCreateNodeAndAppend(create, ICU_MARKER, ngDevMode ? `nested ICU ${nestedIcuIndex}` : '', parentIdx, newIndex);\n icuStart(ast, tView, lView, sharedUpdateOpCodes, parentIdx, icuExpression, newIndex);\n addRemoveNestedIcu(remove, newIndex, depth);\n }\n break;\n }\n currentNode = currentNode.nextSibling;\n }\n return bindingMask;\n}\nfunction addRemoveNode(remove, index, depth) {\n if (depth === 0) {\n remove.push(index);\n }\n}\nfunction addRemoveNestedIcu(remove, index, depth) {\n if (depth === 0) {\n remove.push(~index); // remove ICU at `index`\n remove.push(index); // remove ICU comment at `index`\n }\n}\nfunction addUpdateIcuSwitch(update, icuExpression, index) {\n update.push(toMaskBit(icuExpression.mainBinding), 2, -1 - icuExpression.mainBinding, index << 2 /* I18nUpdateOpCode.SHIFT_REF */ | 2 /* I18nUpdateOpCode.IcuSwitch */);\n}\nfunction addUpdateIcuUpdate(update, bindingMask, index) {\n update.push(bindingMask, 1, index << 2 /* I18nUpdateOpCode.SHIFT_REF */ | 3 /* I18nUpdateOpCode.IcuUpdate */);\n}\nfunction addCreateNodeAndAppend(create, marker, text, appendToParentIdx, createAtIdx) {\n if (marker !== null) {\n create.push(marker);\n }\n create.push(text, createAtIdx, icuCreateOpCode(0 /* IcuCreateOpCode.AppendChild */, appendToParentIdx, createAtIdx));\n}\nfunction addCreateAttribute(create, newIndex, attr) {\n create.push(newIndex << 1 /* IcuCreateOpCode.SHIFT_REF */ | 1 /* IcuCreateOpCode.Attr */, attr.name, attr.value);\n}\n\n// i18nPostprocess consts\nconst ROOT_TEMPLATE_ID = 0;\nconst PP_MULTI_VALUE_PLACEHOLDERS_REGEXP = /\\[(�.+?�?)\\]/;\nconst PP_PLACEHOLDERS_REGEXP = /\\[(�.+?�?)\\]|(�\\/?\\*\\d+:\\d+�)/g;\nconst PP_ICU_VARS_REGEXP = /({\\s*)(VAR_(PLURAL|SELECT)(_\\d+)?)(\\s*,)/g;\nconst PP_ICU_PLACEHOLDERS_REGEXP = /{([A-Z0-9_]+)}/g;\nconst PP_ICUS_REGEXP = /�I18N_EXP_(ICU(_\\d+)?)�/g;\nconst PP_CLOSE_TEMPLATE_REGEXP = /\\/\\*/;\nconst PP_TEMPLATE_ID_REGEXP = /\\d+\\:(\\d+)/;\n/**\n * Handles message string post-processing for internationalization.\n *\n * Handles message string post-processing by transforming it from intermediate\n * format (that might contain some markers that we need to replace) to the final\n * form, consumable by i18nStart instruction. Post processing steps include:\n *\n * 1. Resolve all multi-value cases (like [�*1:1��#2:1�|�#4:1�|�5�])\n * 2. Replace all ICU vars (like \"VAR_PLURAL\")\n * 3. Replace all placeholders used inside ICUs in a form of {PLACEHOLDER}\n * 4. Replace all ICU references with corresponding values (like �ICU_EXP_ICU_1�)\n * in case multiple ICUs have the same placeholder name\n *\n * @param message Raw translation string for post processing\n * @param replacements Set of replacements that should be applied\n *\n * @returns Transformed string that can be consumed by i18nStart instruction\n *\n * @codeGenApi\n */\nfunction i18nPostprocess(message, replacements = {}) {\n /**\n * Step 1: resolve all multi-value placeholders like [�#5�|�*1:1��#2:1�|�#4:1�]\n *\n * Note: due to the way we process nested templates (BFS), multi-value placeholders are typically\n * grouped by templates, for example: [�#5�|�#6�|�#1:1�|�#3:2�] where �#5� and �#6� belong to root\n * template, �#1:1� belong to nested template with index 1 and �#1:2� - nested template with index\n * 3. However in real templates the order might be different: i.e. �#1:1� and/or �#3:2� may go in\n * front of �#6�. The post processing step restores the right order by keeping track of the\n * template id stack and looks for placeholders that belong to the currently active template.\n */\n let result = message;\n if (PP_MULTI_VALUE_PLACEHOLDERS_REGEXP.test(message)) {\n const matches = {};\n const templateIdsStack = [ROOT_TEMPLATE_ID];\n result = result.replace(PP_PLACEHOLDERS_REGEXP, (m, phs, tmpl) => {\n const content = phs || tmpl;\n const placeholders = matches[content] || [];\n if (!placeholders.length) {\n content.split('|').forEach(placeholder => {\n const match = placeholder.match(PP_TEMPLATE_ID_REGEXP);\n const templateId = match ? parseInt(match[1], 10) : ROOT_TEMPLATE_ID;\n const isCloseTemplateTag = PP_CLOSE_TEMPLATE_REGEXP.test(placeholder);\n placeholders.push([templateId, isCloseTemplateTag, placeholder]);\n });\n matches[content] = placeholders;\n }\n if (!placeholders.length) {\n throw new Error(`i18n postprocess: unmatched placeholder - ${content}`);\n }\n const currentTemplateId = templateIdsStack[templateIdsStack.length - 1];\n let idx = 0;\n // find placeholder index that matches current template id\n for (let i = 0; i < placeholders.length; i++) {\n if (placeholders[i][0] === currentTemplateId) {\n idx = i;\n break;\n }\n }\n // update template id stack based on the current tag extracted\n const [templateId, isCloseTemplateTag, placeholder] = placeholders[idx];\n if (isCloseTemplateTag) {\n templateIdsStack.pop();\n } else if (currentTemplateId !== templateId) {\n templateIdsStack.push(templateId);\n }\n // remove processed tag from the list\n placeholders.splice(idx, 1);\n return placeholder;\n });\n }\n // return current result if no replacements specified\n if (!Object.keys(replacements).length) {\n return result;\n }\n /**\n * Step 2: replace all ICU vars (like \"VAR_PLURAL\")\n */\n result = result.replace(PP_ICU_VARS_REGEXP, (match, start, key, _type, _idx, end) => {\n return replacements.hasOwnProperty(key) ? `${start}${replacements[key]}${end}` : match;\n });\n /**\n * Step 3: replace all placeholders used inside ICUs in a form of {PLACEHOLDER}\n */\n result = result.replace(PP_ICU_PLACEHOLDERS_REGEXP, (match, key) => {\n return replacements.hasOwnProperty(key) ? replacements[key] : match;\n });\n /**\n * Step 4: replace all ICU references with corresponding values (like �ICU_EXP_ICU_1�) in case\n * multiple ICUs have the same placeholder name\n */\n result = result.replace(PP_ICUS_REGEXP, (match, key) => {\n if (replacements.hasOwnProperty(key)) {\n const list = replacements[key];\n if (!list.length) {\n throw new Error(`i18n postprocess: unmatched ICU - ${match} with key: ${key}`);\n }\n return list.shift();\n }\n return match;\n });\n return result;\n}\n\n/**\n * Marks a block of text as translatable.\n *\n * The instructions `i18nStart` and `i18nEnd` mark the translation block in the template.\n * The translation `message` is the value which is locale specific. The translation string may\n * contain placeholders which associate inner elements and sub-templates within the translation.\n *\n * The translation `message` placeholders are:\n * - `�{index}(:{block})�`: *Binding Placeholder*: Marks a location where an expression will be\n * interpolated into. The placeholder `index` points to the expression binding index. An optional\n * `block` that matches the sub-template in which it was declared.\n * - `�#{index}(:{block})�`/`�/#{index}(:{block})�`: *Element Placeholder*: Marks the beginning\n * and end of DOM element that were embedded in the original translation block. The placeholder\n * `index` points to the element index in the template instructions set. An optional `block` that\n * matches the sub-template in which it was declared.\n * - `�*{index}:{block}�`/`�/*{index}:{block}�`: *Sub-template Placeholder*: Sub-templates must be\n * split up and translated separately in each angular template function. The `index` points to the\n * `template` instruction index. A `block` that matches the sub-template in which it was declared.\n *\n * @param index A unique index of the translation in the static block.\n * @param messageIndex An index of the translation message from the `def.consts` array.\n * @param subTemplateIndex Optional sub-template index in the `message`.\n *\n * @codeGenApi\n */\nfunction ɵɵi18nStart(index, messageIndex, subTemplateIndex = -1) {\n const tView = getTView();\n const lView = getLView();\n const adjustedIndex = HEADER_OFFSET + index;\n ngDevMode && assertDefined(tView, `tView should be defined`);\n const message = getConstant(tView.consts, messageIndex);\n const parentTNode = getCurrentParentTNode();\n if (tView.firstCreatePass) {\n i18nStartFirstCreatePass(tView, parentTNode === null ? 0 : parentTNode.index, lView, adjustedIndex, message, subTemplateIndex);\n }\n // Set a flag that this LView has i18n blocks.\n // The flag is later used to determine whether this component should\n // be hydrated (currently hydration is not supported for i18n blocks).\n if (tView.type === 2 /* TViewType.Embedded */) {\n // Annotate host component's LView (not embedded view's LView),\n // since hydration can be skipped on per-component basis only.\n const componentLView = lView[DECLARATION_COMPONENT_VIEW];\n componentLView[FLAGS] |= 32 /* LViewFlags.HasI18n */;\n } else {\n lView[FLAGS] |= 32 /* LViewFlags.HasI18n */;\n }\n const tI18n = tView.data[adjustedIndex];\n const sameViewParentTNode = parentTNode === lView[T_HOST] ? null : parentTNode;\n const parentRNode = getClosestRElement(tView, sameViewParentTNode, lView);\n // If `parentTNode` is an `ElementContainer` than it has `<!--ng-container--->`.\n // When we do inserts we have to make sure to insert in front of `<!--ng-container--->`.\n const insertInFrontOf = parentTNode && parentTNode.type & 8 /* TNodeType.ElementContainer */ ? lView[parentTNode.index] : null;\n prepareI18nBlockForHydration(lView, adjustedIndex, parentTNode, subTemplateIndex);\n applyCreateOpCodes(lView, tI18n.create, parentRNode, insertInFrontOf);\n setInI18nBlock(true);\n}\n/**\n * Translates a translation block marked by `i18nStart` and `i18nEnd`. It inserts the text/ICU nodes\n * into the render tree, moves the placeholder nodes and removes the deleted nodes.\n *\n * @codeGenApi\n */\nfunction ɵɵi18nEnd() {\n setInI18nBlock(false);\n}\n/**\n *\n * Use this instruction to create a translation block that doesn't contain any placeholder.\n * It calls both {@link i18nStart} and {@link i18nEnd} in one instruction.\n *\n * The translation `message` is the value which is locale specific. The translation string may\n * contain placeholders which associate inner elements and sub-templates within the translation.\n *\n * The translation `message` placeholders are:\n * - `�{index}(:{block})�`: *Binding Placeholder*: Marks a location where an expression will be\n * interpolated into. The placeholder `index` points to the expression binding index. An optional\n * `block` that matches the sub-template in which it was declared.\n * - `�#{index}(:{block})�`/`�/#{index}(:{block})�`: *Element Placeholder*: Marks the beginning\n * and end of DOM element that were embedded in the original translation block. The placeholder\n * `index` points to the element index in the template instructions set. An optional `block` that\n * matches the sub-template in which it was declared.\n * - `�*{index}:{block}�`/`�/*{index}:{block}�`: *Sub-template Placeholder*: Sub-templates must be\n * split up and translated separately in each angular template function. The `index` points to the\n * `template` instruction index. A `block` that matches the sub-template in which it was declared.\n *\n * @param index A unique index of the translation in the static block.\n * @param messageIndex An index of the translation message from the `def.consts` array.\n * @param subTemplateIndex Optional sub-template index in the `message`.\n *\n * @codeGenApi\n */\nfunction ɵɵi18n(index, messageIndex, subTemplateIndex) {\n ɵɵi18nStart(index, messageIndex, subTemplateIndex);\n ɵɵi18nEnd();\n}\n/**\n * Marks a list of attributes as translatable.\n *\n * @param index A unique index in the static block\n * @param values\n *\n * @codeGenApi\n */\nfunction ɵɵi18nAttributes(index, attrsIndex) {\n const tView = getTView();\n ngDevMode && assertDefined(tView, `tView should be defined`);\n const attrs = getConstant(tView.consts, attrsIndex);\n i18nAttributesFirstPass(tView, index + HEADER_OFFSET, attrs);\n}\n/**\n * Stores the values of the bindings during each update cycle in order to determine if we need to\n * update the translated nodes.\n *\n * @param value The binding's value\n * @returns This function returns itself so that it may be chained\n * (e.g. `i18nExp(ctx.name)(ctx.title)`)\n *\n * @codeGenApi\n */\nfunction ɵɵi18nExp(value) {\n const lView = getLView();\n setMaskBit(bindingUpdated(lView, nextBindingIndex(), value));\n return ɵɵi18nExp;\n}\n/**\n * Updates a translation block or an i18n attribute when the bindings have changed.\n *\n * @param index Index of either {@link i18nStart} (translation block) or {@link i18nAttributes}\n * (i18n attribute) on which it should update the content.\n *\n * @codeGenApi\n */\nfunction ɵɵi18nApply(index) {\n applyI18n(getTView(), getLView(), index + HEADER_OFFSET);\n}\n/**\n * Handles message string post-processing for internationalization.\n *\n * Handles message string post-processing by transforming it from intermediate\n * format (that might contain some markers that we need to replace) to the final\n * form, consumable by i18nStart instruction. Post processing steps include:\n *\n * 1. Resolve all multi-value cases (like [�*1:1��#2:1�|�#4:1�|�5�])\n * 2. Replace all ICU vars (like \"VAR_PLURAL\")\n * 3. Replace all placeholders used inside ICUs in a form of {PLACEHOLDER}\n * 4. Replace all ICU references with corresponding values (like �ICU_EXP_ICU_1�)\n * in case multiple ICUs have the same placeholder name\n *\n * @param message Raw translation string for post processing\n * @param replacements Set of replacements that should be applied\n *\n * @returns Transformed string that can be consumed by i18nStart instruction\n *\n * @codeGenApi\n */\nfunction ɵɵi18nPostprocess(message, replacements = {}) {\n return i18nPostprocess(message, replacements);\n}\n\n/**\n * Contains a reference to a function that disables event replay feature\n * for server-side rendered applications. This function is overridden with\n * an actual implementation when the event replay feature is enabled via\n * `withEventReplay()` call.\n */\nlet stashEventListener = (el, eventName, listenerFn) => {};\nfunction setStashFn(fn) {\n stashEventListener = fn;\n}\n/**\n * Adds an event listener to the current node.\n *\n * If an output exists on one of the node's directives, it also subscribes to the output\n * and saves the subscription for later cleanup.\n *\n * @param eventName Name of the event\n * @param listenerFn The function to be called when event emits\n * @param useCapture Whether or not to use capture in event listener - this argument is a reminder\n * from the Renderer3 infrastructure and should be removed from the instruction arguments\n * @param eventTargetResolver Function that returns global target information in case this listener\n * should be attached to a global object like window, document or body\n *\n * @codeGenApi\n */\nfunction ɵɵlistener(eventName, listenerFn, useCapture, eventTargetResolver) {\n const lView = getLView();\n const tView = getTView();\n const tNode = getCurrentTNode();\n listenerInternal(tView, lView, lView[RENDERER], tNode, eventName, listenerFn, eventTargetResolver);\n return ɵɵlistener;\n}\n/**\n * Registers a synthetic host listener (e.g. `(@foo.start)`) on a component or directive.\n *\n * This instruction is for compatibility purposes and is designed to ensure that a\n * synthetic host listener (e.g. `@HostListener('@foo.start')`) properly gets rendered\n * in the component's renderer. Normally all host listeners are evaluated with the\n * parent component's renderer, but, in the case of animation @triggers, they need\n * to be evaluated with the sub component's renderer (because that's where the\n * animation triggers are defined).\n *\n * Do not use this instruction as a replacement for `listener`. This instruction\n * only exists to ensure compatibility with the ViewEngine's host binding behavior.\n *\n * @param eventName Name of the event\n * @param listenerFn The function to be called when event emits\n * @param useCapture Whether or not to use capture in event listener\n * @param eventTargetResolver Function that returns global target information in case this listener\n * should be attached to a global object like window, document or body\n *\n * @codeGenApi\n */\nfunction ɵɵsyntheticHostListener(eventName, listenerFn) {\n const tNode = getCurrentTNode();\n const lView = getLView();\n const tView = getTView();\n const currentDef = getCurrentDirectiveDef(tView.data);\n const renderer = loadComponentRenderer(currentDef, tNode, lView);\n listenerInternal(tView, lView, renderer, tNode, eventName, listenerFn);\n return ɵɵsyntheticHostListener;\n}\n/**\n * A utility function that checks if a given element has already an event handler registered for an\n * event with a specified name. The TView.cleanup data structure is used to find out which events\n * are registered for a given element.\n */\nfunction findExistingListener(tView, lView, eventName, tNodeIdx) {\n const tCleanup = tView.cleanup;\n if (tCleanup != null) {\n for (let i = 0; i < tCleanup.length - 1; i += 2) {\n const cleanupEventName = tCleanup[i];\n if (cleanupEventName === eventName && tCleanup[i + 1] === tNodeIdx) {\n // We have found a matching event name on the same node but it might not have been\n // registered yet, so we must explicitly verify entries in the LView cleanup data\n // structures.\n const lCleanup = lView[CLEANUP];\n const listenerIdxInLCleanup = tCleanup[i + 2];\n return lCleanup.length > listenerIdxInLCleanup ? lCleanup[listenerIdxInLCleanup] : null;\n }\n // TView.cleanup can have a mix of 4-elements entries (for event handler cleanups) or\n // 2-element entries (for directive and queries destroy hooks). As such we can encounter\n // blocks of 4 or 2 items in the tView.cleanup and this is why we iterate over 2 elements\n // first and jump another 2 elements if we detect listeners cleanup (4 elements). Also check\n // documentation of TView.cleanup for more details of this data structure layout.\n if (typeof cleanupEventName === 'string') {\n i += 2;\n }\n }\n }\n return null;\n}\nfunction listenerInternal(tView, lView, renderer, tNode, eventName, listenerFn, eventTargetResolver) {\n const isTNodeDirectiveHost = isDirectiveHost(tNode);\n const firstCreatePass = tView.firstCreatePass;\n const tCleanup = firstCreatePass ? getOrCreateTViewCleanup(tView) : null;\n const context = lView[CONTEXT];\n // When the ɵɵlistener instruction was generated and is executed we know that there is either a\n // native listener or a directive output on this element. As such we we know that we will have to\n // register a listener and store its cleanup function on LView.\n const lCleanup = getOrCreateLViewCleanup(lView);\n ngDevMode && assertTNodeType(tNode, 3 /* TNodeType.AnyRNode */ | 12 /* TNodeType.AnyContainer */);\n let processOutputs = true;\n // Adding a native event listener is applicable when:\n // - The corresponding TNode represents a DOM element.\n // - The event target has a resolver (usually resulting in a global object,\n // such as `window` or `document`).\n if (tNode.type & 3 /* TNodeType.AnyRNode */ || eventTargetResolver) {\n const native = getNativeByTNode(tNode, lView);\n const target = eventTargetResolver ? eventTargetResolver(native) : native;\n const lCleanupIndex = lCleanup.length;\n const idxOrTargetGetter = eventTargetResolver ? _lView => eventTargetResolver(unwrapRNode(_lView[tNode.index])) : tNode.index;\n // In order to match current behavior, native DOM event listeners must be added for all\n // events (including outputs).\n // There might be cases where multiple directives on the same element try to register an event\n // handler function for the same event. In this situation we want to avoid registration of\n // several native listeners as each registration would be intercepted by NgZone and\n // trigger change detection. This would mean that a single user action would result in several\n // change detections being invoked. To avoid this situation we want to have only one call to\n // native handler registration (for the same element and same type of event).\n //\n // In order to have just one native event handler in presence of multiple handler functions,\n // we just register a first handler function as a native event listener and then chain\n // (coalesce) other handler functions on top of the first native handler function.\n let existingListener = null;\n // Please note that the coalescing described here doesn't happen for events specifying an\n // alternative target (ex. (document:click)) - this is to keep backward compatibility with the\n // view engine.\n // Also, we don't have to search for existing listeners is there are no directives\n // matching on a given node as we can't register multiple event handlers for the same event in\n // a template (this would mean having duplicate attributes).\n if (!eventTargetResolver && isTNodeDirectiveHost) {\n existingListener = findExistingListener(tView, lView, eventName, tNode.index);\n }\n if (existingListener !== null) {\n // Attach a new listener to coalesced listeners list, maintaining the order in which\n // listeners are registered. For performance reasons, we keep a reference to the last\n // listener in that list (in `__ngLastListenerFn__` field), so we can avoid going through\n // the entire set each time we need to add a new listener.\n const lastListenerFn = existingListener.__ngLastListenerFn__ || existingListener;\n lastListenerFn.__ngNextListenerFn__ = listenerFn;\n existingListener.__ngLastListenerFn__ = listenerFn;\n processOutputs = false;\n } else {\n listenerFn = wrapListener(tNode, lView, context, listenerFn);\n stashEventListener(target, eventName, listenerFn);\n const cleanupFn = renderer.listen(target, eventName, listenerFn);\n ngDevMode && ngDevMode.rendererAddEventListener++;\n lCleanup.push(listenerFn, cleanupFn);\n tCleanup && tCleanup.push(eventName, idxOrTargetGetter, lCleanupIndex, lCleanupIndex + 1);\n }\n } else {\n // Even if there is no native listener to add, we still need to wrap the listener so that OnPush\n // ancestors are marked dirty when an event occurs.\n listenerFn = wrapListener(tNode, lView, context, listenerFn);\n }\n if (processOutputs) {\n const outputConfig = tNode.outputs?.[eventName];\n const hostDirectiveOutputConfig = tNode.hostDirectiveOutputs?.[eventName];\n if (hostDirectiveOutputConfig && hostDirectiveOutputConfig.length) {\n for (let i = 0; i < hostDirectiveOutputConfig.length; i += 2) {\n const index = hostDirectiveOutputConfig[i];\n const lookupName = hostDirectiveOutputConfig[i + 1];\n listenToOutput(tNode, tView, lView, index, lookupName, eventName, listenerFn, lCleanup, tCleanup);\n }\n }\n if (outputConfig && outputConfig.length) {\n for (const index of outputConfig) {\n listenToOutput(tNode, tView, lView, index, eventName, eventName, listenerFn, lCleanup, tCleanup);\n }\n }\n }\n}\nfunction listenToOutput(tNode, tView, lView, index, lookupName, eventName, listenerFn, lCleanup, tCleanup) {\n ngDevMode && assertIndexInRange(lView, index);\n const instance = lView[index];\n const def = tView.data[index];\n const propertyName = def.outputs[lookupName];\n const output = instance[propertyName];\n if (ngDevMode && !isOutputSubscribable(output)) {\n throw new Error(`@Output ${propertyName} not initialized in '${instance.constructor.name}'.`);\n }\n const subscription = output.subscribe(listenerFn);\n const idx = lCleanup.length;\n lCleanup.push(listenerFn, subscription);\n tCleanup && tCleanup.push(eventName, tNode.index, idx, -(idx + 1));\n}\nfunction executeListenerWithErrorHandling(lView, context, listenerFn, e) {\n const prevConsumer = setActiveConsumer$1(null);\n try {\n profiler(6 /* ProfilerEvent.OutputStart */, context, listenerFn);\n // Only explicitly returning false from a listener should preventDefault\n return listenerFn(e) !== false;\n } catch (error) {\n handleError(lView, error);\n return false;\n } finally {\n profiler(7 /* ProfilerEvent.OutputEnd */, context, listenerFn);\n setActiveConsumer$1(prevConsumer);\n }\n}\n/**\n * Wraps an event listener with a function that marks ancestors dirty and prevents default behavior,\n * if applicable.\n *\n * @param tNode The TNode associated with this listener\n * @param lView The LView that contains this listener\n * @param listenerFn The listener function to call\n * @param wrapWithPreventDefault Whether or not to prevent default behavior\n * (the procedural renderer does this already, so in those cases, we should skip)\n */\nfunction wrapListener(tNode, lView, context, listenerFn) {\n // Note: we are performing most of the work in the listener function itself\n // to optimize listener registration.\n return function wrapListenerIn_markDirtyAndPreventDefault(e) {\n // Ivy uses `Function` as a special token that allows us to unwrap the function\n // so that it can be invoked programmatically by `DebugNode.triggerEventHandler`.\n if (e === Function) {\n return listenerFn;\n }\n // In order to be backwards compatible with View Engine, events on component host nodes\n // must also mark the component view itself dirty (i.e. the view that it owns).\n const startView = isComponentHost(tNode) ? getComponentLViewByIndex(tNode.index, lView) : lView;\n markViewDirty(startView, 5 /* NotificationSource.Listener */);\n let result = executeListenerWithErrorHandling(lView, context, listenerFn, e);\n // A just-invoked listener function might have coalesced listeners so we need to check for\n // their presence and invoke as needed.\n let nextListenerFn = wrapListenerIn_markDirtyAndPreventDefault.__ngNextListenerFn__;\n while (nextListenerFn) {\n // We should prevent default if any of the listeners explicitly return false\n result = executeListenerWithErrorHandling(lView, context, nextListenerFn, e) && result;\n nextListenerFn = nextListenerFn.__ngNextListenerFn__;\n }\n return result;\n };\n}\n/**\n * Whether the given value represents a subscribable output.\n *\n * For example, an `EventEmitter, a `Subject`, an `Observable` or an\n * `OutputEmitter`.\n */\nfunction isOutputSubscribable(value) {\n return value != null && typeof value.subscribe === 'function';\n}\n\n/**\n * Retrieves a context at the level specified and saves it as the global, contextViewData.\n * Will get the next level up if level is not specified.\n *\n * This is used to save contexts of parent views so they can be bound in embedded views, or\n * in conjunction with reference() to bind a ref from a parent view.\n *\n * @param level The relative level of the view from which to grab context compared to contextVewData\n * @returns context\n *\n * @codeGenApi\n */\nfunction ɵɵnextContext(level = 1) {\n return nextContextImpl(level);\n}\n\n/**\n * Checks a given node against matching projection slots and returns the\n * determined slot index. Returns \"null\" if no slot matched the given node.\n *\n * This function takes into account the parsed ngProjectAs selector from the\n * node's attributes. If present, it will check whether the ngProjectAs selector\n * matches any of the projection slot selectors.\n */\nfunction matchingProjectionSlotIndex(tNode, projectionSlots) {\n let wildcardNgContentIndex = null;\n const ngProjectAsAttrVal = getProjectAsAttrValue(tNode);\n for (let i = 0; i < projectionSlots.length; i++) {\n const slotValue = projectionSlots[i];\n // The last wildcard projection slot should match all nodes which aren't matching\n // any selector. This is necessary to be backwards compatible with view engine.\n if (slotValue === '*') {\n wildcardNgContentIndex = i;\n continue;\n }\n // If we ran into an `ngProjectAs` attribute, we should match its parsed selector\n // to the list of selectors, otherwise we fall back to matching against the node.\n if (ngProjectAsAttrVal === null ? isNodeMatchingSelectorList(tNode, slotValue, /* isProjectionMode */true) : isSelectorInSelectorList(ngProjectAsAttrVal, slotValue)) {\n return i; // first matching selector \"captures\" a given node\n }\n }\n return wildcardNgContentIndex;\n}\n/**\n * Instruction to distribute projectable nodes among <ng-content> occurrences in a given template.\n * It takes all the selectors from the entire component's template and decides where\n * each projected node belongs (it re-distributes nodes among \"buckets\" where each \"bucket\" is\n * backed by a selector).\n *\n * This function requires CSS selectors to be provided in 2 forms: parsed (by a compiler) and text,\n * un-parsed form.\n *\n * The parsed form is needed for efficient matching of a node against a given CSS selector.\n * The un-parsed, textual form is needed for support of the ngProjectAs attribute.\n *\n * Having a CSS selector in 2 different formats is not ideal, but alternatives have even more\n * drawbacks:\n * - having only a textual form would require runtime parsing of CSS selectors;\n * - we can't have only a parsed as we can't re-construct textual form from it (as entered by a\n * template author).\n *\n * @param projectionSlots? A collection of projection slots. A projection slot can be based\n * on a parsed CSS selectors or set to the wildcard selector (\"*\") in order to match\n * all nodes which do not match any selector. If not specified, a single wildcard\n * selector projection slot will be defined.\n *\n * @codeGenApi\n */\nfunction ɵɵprojectionDef(projectionSlots) {\n const componentNode = getLView()[DECLARATION_COMPONENT_VIEW][T_HOST];\n if (!componentNode.projection) {\n // If no explicit projection slots are defined, fall back to a single\n // projection slot with the wildcard selector.\n const numProjectionSlots = projectionSlots ? projectionSlots.length : 1;\n const projectionHeads = componentNode.projection = newArray(numProjectionSlots, null);\n const tails = projectionHeads.slice();\n let componentChild = componentNode.child;\n while (componentChild !== null) {\n // Do not project let declarations so they don't occupy a slot.\n if (componentChild.type !== 128 /* TNodeType.LetDeclaration */) {\n const slotIndex = projectionSlots ? matchingProjectionSlotIndex(componentChild, projectionSlots) : 0;\n if (slotIndex !== null) {\n if (tails[slotIndex]) {\n tails[slotIndex].projectionNext = componentChild;\n } else {\n projectionHeads[slotIndex] = componentChild;\n }\n tails[slotIndex] = componentChild;\n }\n }\n componentChild = componentChild.next;\n }\n }\n}\n/**\n * Inserts previously re-distributed projected nodes. This instruction must be preceded by a call\n * to the projectionDef instruction.\n *\n * @param nodeIndex Index of the projection node.\n * @param selectorIndex Index of the slot selector.\n * - 0 when the selector is `*` (or unspecified as this is the default value),\n * - 1 based index of the selector from the {@link projectionDef}\n * @param attrs Static attributes set on the `ng-content` node.\n * @param fallbackTemplateFn Template function with fallback content.\n * Will be rendered if the slot is empty at runtime.\n * @param fallbackDecls Number of declarations in the fallback template.\n * @param fallbackVars Number of variables in the fallback template.\n *\n * @codeGenApi\n */\nfunction ɵɵprojection(nodeIndex, selectorIndex = 0, attrs, fallbackTemplateFn, fallbackDecls, fallbackVars) {\n const lView = getLView();\n const tView = getTView();\n const fallbackIndex = fallbackTemplateFn ? nodeIndex + 1 : null;\n // Fallback content needs to be declared no matter whether the slot is empty since different\n // instances of the component may or may not insert it. Also it needs to be declare *before*\n // the projection node in order to work correctly with hydration.\n if (fallbackIndex !== null) {\n declareTemplate(lView, tView, fallbackIndex, fallbackTemplateFn, fallbackDecls, fallbackVars, null, attrs);\n }\n const tProjectionNode = getOrCreateTNode(tView, HEADER_OFFSET + nodeIndex, 16 /* TNodeType.Projection */, null, attrs || null);\n // We can't use viewData[HOST_NODE] because projection nodes can be nested in embedded views.\n if (tProjectionNode.projection === null) {\n tProjectionNode.projection = selectorIndex;\n }\n // `<ng-content>` has no content. Even if there's fallback\n // content, the fallback is shown next to it.\n setCurrentTNodeAsNotParent();\n const hydrationInfo = lView[HYDRATION];\n const isNodeCreationMode = !hydrationInfo || isInSkipHydrationBlock$1();\n const componentHostNode = lView[DECLARATION_COMPONENT_VIEW][T_HOST];\n const isEmpty = componentHostNode.projection[tProjectionNode.projection] === null;\n if (isEmpty && fallbackIndex !== null) {\n insertFallbackContent(lView, tView, fallbackIndex);\n } else if (isNodeCreationMode && !isDetachedByI18n(tProjectionNode)) {\n // re-distribution of projectable nodes is stored on a component's view level\n applyProjection(tView, lView, tProjectionNode);\n }\n}\n/** Inserts the fallback content of a projection slot. Assumes there's no projected content. */\nfunction insertFallbackContent(lView, tView, fallbackIndex) {\n const adjustedIndex = HEADER_OFFSET + fallbackIndex;\n const fallbackTNode = tView.data[adjustedIndex];\n const fallbackLContainer = lView[adjustedIndex];\n ngDevMode && assertTNode(fallbackTNode);\n ngDevMode && assertLContainer(fallbackLContainer);\n const dehydratedView = findMatchingDehydratedView(fallbackLContainer, fallbackTNode.tView.ssrId);\n const fallbackLView = createAndRenderEmbeddedLView(lView, fallbackTNode, undefined, {\n dehydratedView\n });\n addLViewToLContainer(fallbackLContainer, fallbackLView, 0, shouldAddViewToDom(fallbackTNode, dehydratedView));\n}\n\n/**\n *\n * Update an interpolated property on an element with a lone bound value\n *\n * Used when the value passed to a property has 1 interpolated value in it, an no additional text\n * surrounds that interpolated value:\n *\n * ```html\n * <div title=\"{{v0}}\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate('title', v0);\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate(propName, v0, sanitizer) {\n ɵɵpropertyInterpolate1(propName, '', v0, '', sanitizer);\n return ɵɵpropertyInterpolate;\n}\n/**\n *\n * Update an interpolated property on an element with single bound value surrounded by text.\n *\n * Used when the value passed to a property has 1 interpolated value in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate1('title', 'prefix', v0, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate1(propName, prefix, v0, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation1(lView, prefix, v0, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 1, prefix, suffix);\n }\n return ɵɵpropertyInterpolate1;\n}\n/**\n *\n * Update an interpolated property on an element with 2 bound values surrounded by text.\n *\n * Used when the value passed to a property has 2 interpolated values in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}-{{v1}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate2(propName, prefix, v0, i0, v1, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 2, prefix, i0, suffix);\n }\n return ɵɵpropertyInterpolate2;\n}\n/**\n *\n * Update an interpolated property on an element with 3 bound values surrounded by text.\n *\n * Used when the value passed to a property has 3 interpolated values in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}-{{v1}}-{{v2}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate3(\n * 'title', 'prefix', v0, '-', v1, '-', v2, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate3(propName, prefix, v0, i0, v1, i1, v2, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 3, prefix, i0, i1, suffix);\n }\n return ɵɵpropertyInterpolate3;\n}\n/**\n *\n * Update an interpolated property on an element with 4 bound values surrounded by text.\n *\n * Used when the value passed to a property has 4 interpolated values in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate4(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate4(propName, prefix, v0, i0, v1, i1, v2, i2, v3, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 4, prefix, i0, i1, i2, suffix);\n }\n return ɵɵpropertyInterpolate4;\n}\n/**\n *\n * Update an interpolated property on an element with 5 bound values surrounded by text.\n *\n * Used when the value passed to a property has 5 interpolated values in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate5(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate5(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 5, prefix, i0, i1, i2, i3, suffix);\n }\n return ɵɵpropertyInterpolate5;\n}\n/**\n *\n * Update an interpolated property on an element with 6 bound values surrounded by text.\n *\n * Used when the value passed to a property has 6 interpolated values in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate6(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate6(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 6, prefix, i0, i1, i2, i3, i4, suffix);\n }\n return ɵɵpropertyInterpolate6;\n}\n/**\n *\n * Update an interpolated property on an element with 7 bound values surrounded by text.\n *\n * Used when the value passed to a property has 7 interpolated values in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate7(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate7(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 7, prefix, i0, i1, i2, i3, i4, i5, suffix);\n }\n return ɵɵpropertyInterpolate7;\n}\n/**\n *\n * Update an interpolated property on an element with 8 bound values surrounded by text.\n *\n * Used when the value passed to a property has 8 interpolated values in it:\n *\n * ```html\n * <div title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolate8(\n * 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param i6 Static value used for concatenation only.\n * @param v7 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolate8(propName, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - 8, prefix, i0, i1, i2, i3, i4, i5, i6, suffix);\n }\n return ɵɵpropertyInterpolate8;\n}\n/**\n * Update an interpolated property on an element with 9 or more bound values surrounded by text.\n *\n * Used when the number of interpolated values exceeds 8.\n *\n * ```html\n * <div\n * title=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix\"></div>\n * ```\n *\n * Its compiled representation is::\n *\n * ```ts\n * ɵɵpropertyInterpolateV(\n * 'title', ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,\n * 'suffix']);\n * ```\n *\n * If the property name also exists as an input property on one of the element's directives,\n * the component property will be set instead of the element property. This check must\n * be conducted at runtime so child components that add new `@Inputs` don't have to be re-compiled.\n *\n * @param propName The name of the property to update.\n * @param values The collection of values and the strings in between those values, beginning with a\n * string prefix and ending with a string suffix.\n * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)\n * @param sanitizer An optional sanitizer function\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵpropertyInterpolateV(propName, values, sanitizer) {\n const lView = getLView();\n const interpolatedValue = interpolationV(lView, values);\n if (interpolatedValue !== NO_CHANGE) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, interpolatedValue, lView[RENDERER], sanitizer, false);\n if (ngDevMode) {\n const interpolationInBetween = [values[0]]; // prefix\n for (let i = 2; i < values.length; i += 2) {\n interpolationInBetween.push(values[i]);\n }\n storePropertyBindingMetadata(tView.data, tNode, propName, getBindingIndex() - interpolationInBetween.length + 1, ...interpolationInBetween);\n }\n }\n return ɵɵpropertyInterpolateV;\n}\n\n/**\n * Registers a QueryList, associated with a content query, for later refresh (part of a view\n * refresh).\n *\n * @param directiveIndex Current directive index\n * @param predicate The type for which the query will search\n * @param flags Flags associated with the query\n * @param read What to save in the query\n * @returns QueryList<T>\n *\n * @codeGenApi\n */\nfunction ɵɵcontentQuery(directiveIndex, predicate, flags, read) {\n createContentQuery(directiveIndex, predicate, flags, read);\n}\n/**\n * Creates a new view query by initializing internal data structures.\n *\n * @param predicate The type for which the query will search\n * @param flags Flags associated with the query\n * @param read What to save in the query\n *\n * @codeGenApi\n */\nfunction ɵɵviewQuery(predicate, flags, read) {\n createViewQuery(predicate, flags, read);\n}\n/**\n * Refreshes a query by combining matches from all active views and removing matches from deleted\n * views.\n *\n * @returns `true` if a query got dirty during change detection or if this is a static query\n * resolving in creation mode, `false` otherwise.\n *\n * @codeGenApi\n */\nfunction ɵɵqueryRefresh(queryList) {\n const lView = getLView();\n const tView = getTView();\n const queryIndex = getCurrentQueryIndex();\n setCurrentQueryIndex(queryIndex + 1);\n const tQuery = getTQuery(tView, queryIndex);\n if (queryList.dirty && isCreationMode(lView) === ((tQuery.metadata.flags & 2 /* QueryFlags.isStatic */) === 2 /* QueryFlags.isStatic */)) {\n if (tQuery.matches === null) {\n queryList.reset([]);\n } else {\n const result = getQueryResults(lView, queryIndex);\n queryList.reset(result, unwrapElementRef);\n queryList.notifyOnChanges();\n }\n return true;\n }\n return false;\n}\n/**\n * Loads a QueryList corresponding to the current view or content query.\n *\n * @codeGenApi\n */\nfunction ɵɵloadQuery() {\n return loadQueryInternal(getLView(), getCurrentQueryIndex());\n}\n\n/**\n * Creates a new content query and binds it to a signal created by an authoring function.\n *\n * @param directiveIndex Current directive index\n * @param target The target signal to which the query should be bound\n * @param predicate The type for which the query will search\n * @param flags Flags associated with the query\n * @param read What to save in the query\n *\n * @codeGenApi\n */\nfunction ɵɵcontentQuerySignal(directiveIndex, target, predicate, flags, read) {\n bindQueryToSignal(target, createContentQuery(directiveIndex, predicate, flags, read));\n}\n/**\n * Creates a new view query by initializing internal data structures and binding a new query to the\n * target signal.\n *\n * @param target The target signal to assign the query results to.\n * @param predicate The type or label that should match a given query\n * @param flags Flags associated with the query\n * @param read What to save in the query\n *\n * @codeGenApi\n */\nfunction ɵɵviewQuerySignal(target, predicate, flags, read) {\n bindQueryToSignal(target, createViewQuery(predicate, flags, read));\n}\n/**\n * Advances the current query index by a specified offset.\n *\n * Adjusting the current query index is necessary in cases where a given directive has a mix of\n * zone-based and signal-based queries. The signal-based queries don't require tracking of the\n * current index (those are refreshed on demand and not during change detection) so this instruction\n * is only necessary for backward-compatibility.\n *\n * @param index offset to apply to the current query index (defaults to 1)\n *\n * @codeGenApi\n */\nfunction ɵɵqueryAdvance(indexOffset = 1) {\n setCurrentQueryIndex(getCurrentQueryIndex() + indexOffset);\n}\n\n/** Store a value in the `data` at a given `index`. */\nfunction store(tView, lView, index, value) {\n // We don't store any static data for local variables, so the first time\n // we see the template, we should store as null to avoid a sparse array\n if (index >= tView.data.length) {\n tView.data[index] = null;\n tView.blueprint[index] = null;\n }\n lView[index] = value;\n}\n/**\n * Retrieves a local reference from the current contextViewData.\n *\n * If the reference to retrieve is in a parent view, this instruction is used in conjunction\n * with a nextContext() call, which walks up the tree and updates the contextViewData instance.\n *\n * @param index The index of the local ref in contextViewData.\n *\n * @codeGenApi\n */\nfunction ɵɵreference(index) {\n const contextLView = getContextLView();\n return load(contextLView, HEADER_OFFSET + index);\n}\n\n/**\n *\n * Update an interpolated style on an element with single bound value surrounded by text.\n *\n * Used when the value passed to a property has 1 interpolated value in it:\n *\n * ```html\n * <div style=\"key: {{v0}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate1('key: ', v0, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate1(prefix, v0, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation1(lView, prefix, v0, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n *\n * Update an interpolated style on an element with 2 bound values surrounded by text.\n *\n * Used when the value passed to a property has 2 interpolated values in it:\n *\n * ```html\n * <div style=\"key: {{v0}}; key1: {{v1}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate2('key: ', v0, '; key1: ', v1, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate2(prefix, v0, i0, v1, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n *\n * Update an interpolated style on an element with 3 bound values surrounded by text.\n *\n * Used when the value passed to a property has 3 interpolated values in it:\n *\n * ```html\n * <div style=\"key: {{v0}}; key2: {{v1}}; key2: {{v2}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate3(\n * 'key: ', v0, '; key1: ', v1, '; key2: ', v2, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate3(prefix, v0, i0, v1, i1, v2, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n *\n * Update an interpolated style on an element with 4 bound values surrounded by text.\n *\n * Used when the value passed to a property has 4 interpolated values in it:\n *\n * ```html\n * <div style=\"key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate4(\n * 'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n *\n * Update an interpolated style on an element with 5 bound values surrounded by text.\n *\n * Used when the value passed to a property has 5 interpolated values in it:\n *\n * ```html\n * <div style=\"key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate5(\n * 'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n *\n * Update an interpolated style on an element with 6 bound values surrounded by text.\n *\n * Used when the value passed to a property has 6 interpolated values in it:\n *\n * ```html\n * <div style=\"key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}};\n * key5: {{v5}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate6(\n * 'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,\n * 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n *\n * Update an interpolated style on an element with 7 bound values surrounded by text.\n *\n * Used when the value passed to a property has 7 interpolated values in it:\n *\n * ```html\n * <div style=\"key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}; key5: {{v5}};\n * key6: {{v6}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate7(\n * 'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,\n * '; key6: ', v6, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n *\n * Update an interpolated style on an element with 8 bound values surrounded by text.\n *\n * Used when the value passed to a property has 8 interpolated values in it:\n *\n * ```html\n * <div style=\"key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}; key5: {{v5}};\n * key6: {{v6}}; key7: {{v7}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolate8(\n * 'key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,\n * '; key6: ', v6, '; key7: ', v7, 'suffix');\n * ```\n *\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param i6 Static value used for concatenation only.\n * @param v7 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolate8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {\n const lView = getLView();\n const interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);\n ɵɵstyleMap(interpolatedValue);\n}\n/**\n * Update an interpolated style on an element with 9 or more bound values surrounded by text.\n *\n * Used when the number of interpolated values exceeds 8.\n *\n * ```html\n * <div\n * class=\"key: {{v0}}; key1: {{v1}}; key2: {{v2}}; key3: {{v3}}; key4: {{v4}}; key5: {{v5}};\n * key6: {{v6}}; key7: {{v7}}; key8: {{v8}}; key9: {{v9}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstyleMapInterpolateV(\n * ['key: ', v0, '; key1: ', v1, '; key2: ', v2, '; key3: ', v3, '; key4: ', v4, '; key5: ', v5,\n * '; key6: ', v6, '; key7: ', v7, '; key8: ', v8, '; key9: ', v9, 'suffix']);\n * ```\n *.\n * @param values The collection of values and the strings in-between those values, beginning with\n * a string prefix and ending with a string suffix.\n * (e.g. `['prefix', value0, '; key2: ', value1, '; key2: ', value2, ..., value99, 'suffix']`)\n * @codeGenApi\n */\nfunction ɵɵstyleMapInterpolateV(values) {\n const lView = getLView();\n const interpolatedValue = interpolationV(lView, values);\n ɵɵstyleMap(interpolatedValue);\n}\n\n/**\n *\n * Update an interpolated style property on an element with single bound value surrounded by text.\n *\n * Used when the value passed to a property has 1 interpolated value in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate1(0, 'prefix', v0, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate1(prop, prefix, v0, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation1(lView, prefix, v0, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate1;\n}\n/**\n *\n * Update an interpolated style property on an element with 2 bound values surrounded by text.\n *\n * Used when the value passed to a property has 2 interpolated values in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}-{{v1}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate2(0, 'prefix', v0, '-', v1, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate2(prop, prefix, v0, i0, v1, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation2(lView, prefix, v0, i0, v1, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate2;\n}\n/**\n *\n * Update an interpolated style property on an element with 3 bound values surrounded by text.\n *\n * Used when the value passed to a property has 3 interpolated values in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}-{{v1}}-{{v2}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate3(0, 'prefix', v0, '-', v1, '-', v2, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate3(prop, prefix, v0, i0, v1, i1, v2, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate3;\n}\n/**\n *\n * Update an interpolated style property on an element with 4 bound values surrounded by text.\n *\n * Used when the value passed to a property has 4 interpolated values in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate4(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate4(prop, prefix, v0, i0, v1, i1, v2, i2, v3, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate4;\n}\n/**\n *\n * Update an interpolated style property on an element with 5 bound values surrounded by text.\n *\n * Used when the value passed to a property has 5 interpolated values in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate5(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate5(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate5;\n}\n/**\n *\n * Update an interpolated style property on an element with 6 bound values surrounded by text.\n *\n * Used when the value passed to a property has 6 interpolated values in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate6(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate6(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate6;\n}\n/**\n *\n * Update an interpolated style property on an element with 7 bound values surrounded by text.\n *\n * Used when the value passed to a property has 7 interpolated values in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate7(\n * 0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate7(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate7;\n}\n/**\n *\n * Update an interpolated style property on an element with 8 bound values surrounded by text.\n *\n * Used when the value passed to a property has 8 interpolated values in it:\n *\n * ```html\n * <div style.color=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix\"></div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolate8(0, 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6,\n * '-', v7, 'suffix');\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`.\n * @param prefix Static value used for concatenation only.\n * @param v0 Value checked for change.\n * @param i0 Static value used for concatenation only.\n * @param v1 Value checked for change.\n * @param i1 Static value used for concatenation only.\n * @param v2 Value checked for change.\n * @param i2 Static value used for concatenation only.\n * @param v3 Value checked for change.\n * @param i3 Static value used for concatenation only.\n * @param v4 Value checked for change.\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change.\n * @param i5 Static value used for concatenation only.\n * @param v6 Value checked for change.\n * @param i6 Static value used for concatenation only.\n * @param v7 Value checked for change.\n * @param suffix Static value used for concatenation only.\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolate8(prop, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolate8;\n}\n/**\n * Update an interpolated style property on an element with 9 or more bound values surrounded by\n * text.\n *\n * Used when the number of interpolated values exceeds 8.\n *\n * ```html\n * <div\n * style.color=\"prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix\">\n * </div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵstylePropInterpolateV(\n * 0, ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,\n * 'suffix']);\n * ```\n *\n * @param styleIndex Index of style to update. This index value refers to the\n * index of the style in the style bindings array that was passed into\n * `styling`..\n * @param values The collection of values and the strings in-between those values, beginning with\n * a string prefix and ending with a string suffix.\n * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)\n * @param valueSuffix Optional suffix. Used with scalar values to add unit such as `px`.\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵstylePropInterpolateV(prop, values, valueSuffix) {\n const lView = getLView();\n const interpolatedValue = interpolationV(lView, values);\n checkStylingProperty(prop, interpolatedValue, valueSuffix, false);\n return ɵɵstylePropInterpolateV;\n}\n\n/**\n * Create static text node\n *\n * @param index Index of the node in the data array\n * @param value Static string value to write.\n *\n * @codeGenApi\n */\nfunction ɵɵtext(index, value = '') {\n const lView = getLView();\n const tView = getTView();\n const adjustedIndex = index + HEADER_OFFSET;\n ngDevMode && assertEqual(getBindingIndex(), tView.bindingStartIndex, 'text nodes should be created before any bindings');\n ngDevMode && assertIndexInRange(lView, adjustedIndex);\n const tNode = tView.firstCreatePass ? getOrCreateTNode(tView, adjustedIndex, 1 /* TNodeType.Text */, value, null) : tView.data[adjustedIndex];\n const textNative = _locateOrCreateTextNode(tView, lView, tNode, value, index);\n lView[adjustedIndex] = textNative;\n if (wasLastNodeCreated()) {\n appendChild(tView, lView, textNative, tNode);\n }\n // Text nodes are self closing.\n setCurrentTNode(tNode, false);\n}\nlet _locateOrCreateTextNode = (tView, lView, tNode, value, index) => {\n lastNodeWasCreated(true);\n return createTextNode(lView[RENDERER], value);\n};\n/**\n * Enables hydration code path (to lookup existing elements in DOM)\n * in addition to the regular creation mode of text nodes.\n */\nfunction locateOrCreateTextNodeImpl(tView, lView, tNode, value, index) {\n const hydrationInfo = lView[HYDRATION];\n const isNodeCreationMode = !hydrationInfo || isInSkipHydrationBlock$1() || isDetachedByI18n(tNode) || isDisconnectedNode$1(hydrationInfo, index);\n lastNodeWasCreated(isNodeCreationMode);\n // Regular creation mode.\n if (isNodeCreationMode) {\n return createTextNode(lView[RENDERER], value);\n }\n // Hydration mode, looking up an existing element in DOM.\n const textNative = locateNextRNode(hydrationInfo, tView, lView, tNode);\n ngDevMode && validateMatchingNode(textNative, Node.TEXT_NODE, null, lView, tNode);\n ngDevMode && markRNodeAsClaimedByHydration(textNative);\n return textNative;\n}\nfunction enableLocateOrCreateTextNodeImpl() {\n _locateOrCreateTextNode = locateOrCreateTextNodeImpl;\n}\n\n/**\n *\n * Update text content with a lone bound value\n *\n * Used when a text node has 1 interpolated value in it, an no additional text\n * surrounds that interpolated value:\n *\n * ```html\n * <div>{{v0}}</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate(v0);\n * ```\n * @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate(v0) {\n ɵɵtextInterpolate1('', v0, '');\n return ɵɵtextInterpolate;\n}\n/**\n *\n * Update text content with single bound value surrounded by other text.\n *\n * Used when a text node has 1 interpolated value in it:\n *\n * ```html\n * <div>prefix{{v0}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate1('prefix', v0, 'suffix');\n * ```\n * @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate1(prefix, v0, suffix) {\n const lView = getLView();\n const interpolated = interpolation1(lView, prefix, v0, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate1;\n}\n/**\n *\n * Update text content with 2 bound values surrounded by other text.\n *\n * Used when a text node has 2 interpolated values in it:\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate2('prefix', v0, '-', v1, 'suffix');\n * ```\n * @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate2(prefix, v0, i0, v1, suffix) {\n const lView = getLView();\n const interpolated = interpolation2(lView, prefix, v0, i0, v1, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate2;\n}\n/**\n *\n * Update text content with 3 bound values surrounded by other text.\n *\n * Used when a text node has 3 interpolated values in it:\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}-{{v2}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate3(\n * 'prefix', v0, '-', v1, '-', v2, 'suffix');\n * ```\n * @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate3(prefix, v0, i0, v1, i1, v2, suffix) {\n const lView = getLView();\n const interpolated = interpolation3(lView, prefix, v0, i0, v1, i1, v2, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate3;\n}\n/**\n *\n * Update text content with 4 bound values surrounded by other text.\n *\n * Used when a text node has 4 interpolated values in it:\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate4(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');\n * ```\n * @returns itself, so that it may be chained.\n * @see ɵɵtextInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix) {\n const lView = getLView();\n const interpolated = interpolation4(lView, prefix, v0, i0, v1, i1, v2, i2, v3, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate4;\n}\n/**\n *\n * Update text content with 5 bound values surrounded by other text.\n *\n * Used when a text node has 5 interpolated values in it:\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate5(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');\n * ```\n * @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix) {\n const lView = getLView();\n const interpolated = interpolation5(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate5;\n}\n/**\n *\n * Update text content with 6 bound values surrounded by other text.\n *\n * Used when a text node has 6 interpolated values in it:\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate6(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');\n * ```\n *\n * @param i4 Static value used for concatenation only.\n * @param v5 Value checked for change. @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix) {\n const lView = getLView();\n const interpolated = interpolation6(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate6;\n}\n/**\n *\n * Update text content with 7 bound values surrounded by other text.\n *\n * Used when a text node has 7 interpolated values in it:\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate7(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');\n * ```\n * @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix) {\n const lView = getLView();\n const interpolated = interpolation7(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate7;\n}\n/**\n *\n * Update text content with 8 bound values surrounded by other text.\n *\n * Used when a text node has 8 interpolated values in it:\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolate8(\n * 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');\n * ```\n * @returns itself, so that it may be chained.\n * @see textInterpolateV\n * @codeGenApi\n */\nfunction ɵɵtextInterpolate8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix) {\n const lView = getLView();\n const interpolated = interpolation8(lView, prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolate8;\n}\n/**\n * Update text content with 9 or more bound values other surrounded by text.\n *\n * Used when the number of interpolated values exceeds 8.\n *\n * ```html\n * <div>prefix{{v0}}-{{v1}}-{{v2}}-{{v3}}-{{v4}}-{{v5}}-{{v6}}-{{v7}}-{{v8}}-{{v9}}suffix</div>\n * ```\n *\n * Its compiled representation is:\n *\n * ```ts\n * ɵɵtextInterpolateV(\n * ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,\n * 'suffix']);\n * ```\n *.\n * @param values The collection of values and the strings in between those values, beginning with\n * a string prefix and ending with a string suffix.\n * (e.g. `['prefix', value0, '-', value1, '-', value2, ..., value99, 'suffix']`)\n *\n * @returns itself, so that it may be chained.\n * @codeGenApi\n */\nfunction ɵɵtextInterpolateV(values) {\n const lView = getLView();\n const interpolated = interpolationV(lView, values);\n if (interpolated !== NO_CHANGE) {\n textBindingInternal(lView, getSelectedIndex(), interpolated);\n }\n return ɵɵtextInterpolateV;\n}\n/**\n * Updates a text binding at a given index in a given LView.\n */\nfunction textBindingInternal(lView, index, value) {\n ngDevMode && assertString(value, 'Value should be a string');\n ngDevMode && assertNotSame(value, NO_CHANGE, 'value should not be NO_CHANGE');\n ngDevMode && assertIndexInRange(lView, index);\n const element = getNativeByIndex(index, lView);\n ngDevMode && assertDefined(element, 'native element should exist');\n updateTextNode(lView[RENDERER], element, value);\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Update a two-way bound property on a selected element.\n *\n * Operates on the element selected by index via the {@link select} instruction.\n *\n * @param propName Name of property.\n * @param value New value to write.\n * @param sanitizer An optional function used to sanitize the value.\n * @returns This function returns itself so that it may be chained\n * (e.g. `twoWayProperty('name', ctx.name)('title', ctx.title)`)\n *\n * @codeGenApi\n */\nfunction ɵɵtwoWayProperty(propName, value, sanitizer) {\n // TODO(crisbeto): perf impact of re-evaluating this on each change detection?\n if (isWritableSignal(value)) {\n value = value();\n }\n const lView = getLView();\n const bindingIndex = nextBindingIndex();\n if (bindingUpdated(lView, bindingIndex, value)) {\n const tView = getTView();\n const tNode = getSelectedTNode();\n elementPropertyInternal(tView, tNode, lView, propName, value, lView[RENDERER], sanitizer, false);\n ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);\n }\n return ɵɵtwoWayProperty;\n}\n/**\n * Function used inside two-way listeners to conditionally set the value of the bound expression.\n *\n * @param target Field on which to set the value.\n * @param value Value to be set to the field.\n *\n * @codeGenApi\n */\nfunction ɵɵtwoWayBindingSet(target, value) {\n const canWrite = isWritableSignal(target);\n canWrite && target.set(value);\n return canWrite;\n}\n/**\n * Adds an event listener that updates a two-way binding to the current node.\n *\n * @param eventName Name of the event.\n * @param listenerFn The function to be called when event emits.\n *\n * @codeGenApi\n */\nfunction ɵɵtwoWayListener(eventName, listenerFn) {\n const lView = getLView();\n const tView = getTView();\n const tNode = getCurrentTNode();\n listenerInternal(tView, lView, lView[RENDERER], tNode, eventName, listenerFn);\n return ɵɵtwoWayListener;\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/** Object that indicates the value of a `@let` declaration that hasn't been initialized yet. */\nconst UNINITIALIZED_LET = {};\n/**\n * Declares an `@let` at a specific data slot. Returns itself to allow chaining.\n *\n * @param index Index at which to declare the `@let`.\n *\n * @codeGenApi\n */\nfunction ɵɵdeclareLet(index) {\n const tView = getTView();\n const lView = getLView();\n const adjustedIndex = index + HEADER_OFFSET;\n const tNode = getOrCreateTNode(tView, adjustedIndex, 128 /* TNodeType.LetDeclaration */, null, null);\n setCurrentTNode(tNode, false);\n store(tView, lView, adjustedIndex, UNINITIALIZED_LET);\n return ɵɵdeclareLet;\n}\n/**\n * Instruction that stores the value of a `@let` declaration on the current view.\n * Returns the value to allow usage inside variable initializers.\n *\n * @codeGenApi\n */\nfunction ɵɵstoreLet(value) {\n performanceMarkFeature('NgLet');\n const tView = getTView();\n const lView = getLView();\n const index = getSelectedIndex();\n store(tView, lView, index, value);\n return value;\n}\n/**\n * Retrieves the value of a `@let` declaration defined in a parent view.\n *\n * @param index Index of the declaration within the view.\n *\n * @codeGenApi\n */\nfunction ɵɵreadContextLet(index) {\n const contextLView = getContextLView();\n const value = load(contextLView, HEADER_OFFSET + index);\n if (value === UNINITIALIZED_LET) {\n throw new RuntimeError(314 /* RuntimeErrorCode.UNINITIALIZED_LET_ACCESS */, ngDevMode && 'Attempting to access a @let declaration whose value is not available yet');\n }\n return value;\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Sets the location within the source template at which\n * each element in the current view was defined.\n *\n * @param index Index at which the DOM node was created.\n * @param templatePath Path to the template at which the node was defined.\n * @param locations Element locations to which to attach the source location.\n *\n * @codeGenApi\n */\nfunction ɵɵattachSourceLocations(templatePath, locations) {\n const tView = getTView();\n const lView = getLView();\n const renderer = lView[RENDERER];\n const attributeName = 'data-ng-source-location';\n for (const [index, offset, line, column] of locations) {\n const tNode = getTNode(tView, index + HEADER_OFFSET);\n // The compiler shouldn't generate the instruction for non-element nodes, but assert just in case.\n ngDevMode && assertTNodeType(tNode, 2 /* TNodeType.Element */);\n const node = getNativeByIndex(index + HEADER_OFFSET, lView);\n // Set the attribute directly in the DOM so it doesn't participate in directive matching.\n if (!node.hasAttribute(attributeName)) {\n const attributeValue = `${templatePath}@o:${offset},l:${line},c:${column}`;\n renderer.setAttribute(node, attributeName, attributeValue);\n }\n }\n}\n\n/*\n * This file re-exports all symbols contained in this directory.\n *\n * Why is this file not `index.ts`?\n *\n * There seems to be an inconsistent path resolution of an `index.ts` file\n * when only the parent directory is referenced. This could be due to the\n * node module resolution configuration differing from rollup and/or typescript.\n *\n * With commit\n * https://github.com/angular/angular/commit/d5e3f2c64bd13ce83e7c70788b7fc514ca4a9918\n * the `instructions.ts` file was moved to `instructions/instructions.ts` and an\n * `index.ts` file was used to re-export everything. Having had file names that were\n * importing from `instructions' directly (not the from the sub file or the `index.ts`\n * file) caused strange CI issues. `index.ts` had to be renamed to `all.ts` for this\n * to work.\n *\n * Jira Issue = FW-1184\n */\n\n/**\n * Resolves the providers which are defined in the DirectiveDef.\n *\n * When inserting the tokens and the factories in their respective arrays, we can assume that\n * this method is called first for the component (if any), and then for other directives on the same\n * node.\n * As a consequence,the providers are always processed in that order:\n * 1) The view providers of the component\n * 2) The providers of the component\n * 3) The providers of the other directives\n * This matches the structure of the injectables arrays of a view (for each node).\n * So the tokens and the factories can be pushed at the end of the arrays, except\n * in one case for multi providers.\n *\n * @param def the directive definition\n * @param providers: Array of `providers`.\n * @param viewProviders: Array of `viewProviders`.\n */\nfunction providersResolver(def, providers, viewProviders) {\n const tView = getTView();\n if (tView.firstCreatePass) {\n const isComponent = isComponentDef(def);\n // The list of view providers is processed first, and the flags are updated\n resolveProvider(viewProviders, tView.data, tView.blueprint, isComponent, true);\n // Then, the list of providers is processed, and the flags are updated\n resolveProvider(providers, tView.data, tView.blueprint, isComponent, false);\n }\n}\n/**\n * Resolves a provider and publishes it to the DI system.\n */\nfunction resolveProvider(provider, tInjectables, lInjectablesBlueprint, isComponent, isViewProvider) {\n provider = resolveForwardRef(provider);\n if (Array.isArray(provider)) {\n // Recursively call `resolveProvider`\n // Recursion is OK in this case because this code will not be in hot-path once we implement\n // cloning of the initial state.\n for (let i = 0; i < provider.length; i++) {\n resolveProvider(provider[i], tInjectables, lInjectablesBlueprint, isComponent, isViewProvider);\n }\n } else {\n const tView = getTView();\n const lView = getLView();\n const tNode = getCurrentTNode();\n let token = isTypeProvider(provider) ? provider : resolveForwardRef(provider.provide);\n const providerFactory = providerToFactory(provider);\n if (ngDevMode) {\n const injector = new NodeInjector(tNode, lView);\n runInInjectorProfilerContext(injector, token, () => {\n emitProviderConfiguredEvent(provider, isViewProvider);\n });\n }\n const beginIndex = tNode.providerIndexes & 1048575 /* TNodeProviderIndexes.ProvidersStartIndexMask */;\n const endIndex = tNode.directiveStart;\n const cptViewProvidersCount = tNode.providerIndexes >> 20 /* TNodeProviderIndexes.CptViewProvidersCountShift */;\n if (isTypeProvider(provider) || !provider.multi) {\n // Single provider case: the factory is created and pushed immediately\n const factory = new NodeInjectorFactory(providerFactory, isViewProvider, ɵɵdirectiveInject);\n const existingFactoryIndex = indexOf(token, tInjectables, isViewProvider ? beginIndex : beginIndex + cptViewProvidersCount, endIndex);\n if (existingFactoryIndex === -1) {\n diPublicInInjector(getOrCreateNodeInjectorForNode(tNode, lView), tView, token);\n registerDestroyHooksIfSupported(tView, provider, tInjectables.length);\n tInjectables.push(token);\n tNode.directiveStart++;\n tNode.directiveEnd++;\n if (isViewProvider) {\n tNode.providerIndexes += 1048576 /* TNodeProviderIndexes.CptViewProvidersCountShifter */;\n }\n lInjectablesBlueprint.push(factory);\n lView.push(factory);\n } else {\n lInjectablesBlueprint[existingFactoryIndex] = factory;\n lView[existingFactoryIndex] = factory;\n }\n } else {\n // Multi provider case:\n // We create a multi factory which is going to aggregate all the values.\n // Since the output of such a factory depends on content or view injection,\n // we create two of them, which are linked together.\n //\n // The first one (for view providers) is always in the first block of the injectables array,\n // and the second one (for providers) is always in the second block.\n // This is important because view providers have higher priority. When a multi token\n // is being looked up, the view providers should be found first.\n // Note that it is not possible to have a multi factory in the third block (directive block).\n //\n // The algorithm to process multi providers is as follows:\n // 1) If the multi provider comes from the `viewProviders` of the component:\n // a) If the special view providers factory doesn't exist, it is created and pushed.\n // b) Else, the multi provider is added to the existing multi factory.\n // 2) If the multi provider comes from the `providers` of the component or of another\n // directive:\n // a) If the multi factory doesn't exist, it is created and provider pushed into it.\n // It is also linked to the multi factory for view providers, if it exists.\n // b) Else, the multi provider is added to the existing multi factory.\n const existingProvidersFactoryIndex = indexOf(token, tInjectables, beginIndex + cptViewProvidersCount, endIndex);\n const existingViewProvidersFactoryIndex = indexOf(token, tInjectables, beginIndex, beginIndex + cptViewProvidersCount);\n const doesProvidersFactoryExist = existingProvidersFactoryIndex >= 0 && lInjectablesBlueprint[existingProvidersFactoryIndex];\n const doesViewProvidersFactoryExist = existingViewProvidersFactoryIndex >= 0 && lInjectablesBlueprint[existingViewProvidersFactoryIndex];\n if (isViewProvider && !doesViewProvidersFactoryExist || !isViewProvider && !doesProvidersFactoryExist) {\n // Cases 1.a and 2.a\n diPublicInInjector(getOrCreateNodeInjectorForNode(tNode, lView), tView, token);\n const factory = multiFactory(isViewProvider ? multiViewProvidersFactoryResolver : multiProvidersFactoryResolver, lInjectablesBlueprint.length, isViewProvider, isComponent, providerFactory);\n if (!isViewProvider && doesViewProvidersFactoryExist) {\n lInjectablesBlueprint[existingViewProvidersFactoryIndex].providerFactory = factory;\n }\n registerDestroyHooksIfSupported(tView, provider, tInjectables.length, 0);\n tInjectables.push(token);\n tNode.directiveStart++;\n tNode.directiveEnd++;\n if (isViewProvider) {\n tNode.providerIndexes += 1048576 /* TNodeProviderIndexes.CptViewProvidersCountShifter */;\n }\n lInjectablesBlueprint.push(factory);\n lView.push(factory);\n } else {\n // Cases 1.b and 2.b\n const indexInFactory = multiFactoryAdd(lInjectablesBlueprint[isViewProvider ? existingViewProvidersFactoryIndex : existingProvidersFactoryIndex], providerFactory, !isViewProvider && isComponent);\n registerDestroyHooksIfSupported(tView, provider, existingProvidersFactoryIndex > -1 ? existingProvidersFactoryIndex : existingViewProvidersFactoryIndex, indexInFactory);\n }\n if (!isViewProvider && isComponent && doesViewProvidersFactoryExist) {\n lInjectablesBlueprint[existingViewProvidersFactoryIndex].componentProviders++;\n }\n }\n }\n}\n/**\n * Registers the `ngOnDestroy` hook of a provider, if the provider supports destroy hooks.\n * @param tView `TView` in which to register the hook.\n * @param provider Provider whose hook should be registered.\n * @param contextIndex Index under which to find the context for the hook when it's being invoked.\n * @param indexInFactory Only required for `multi` providers. Index of the provider in the multi\n * provider factory.\n */\nfunction registerDestroyHooksIfSupported(tView, provider, contextIndex, indexInFactory) {\n const providerIsTypeProvider = isTypeProvider(provider);\n const providerIsClassProvider = isClassProvider(provider);\n if (providerIsTypeProvider || providerIsClassProvider) {\n // Resolve forward references as `useClass` can hold a forward reference.\n const classToken = providerIsClassProvider ? resolveForwardRef(provider.useClass) : provider;\n const prototype = classToken.prototype;\n const ngOnDestroy = prototype.ngOnDestroy;\n if (ngOnDestroy) {\n const hooks = tView.destroyHooks || (tView.destroyHooks = []);\n if (!providerIsTypeProvider && provider.multi) {\n ngDevMode && assertDefined(indexInFactory, 'indexInFactory when registering multi factory destroy hook');\n const existingCallbacksIndex = hooks.indexOf(contextIndex);\n if (existingCallbacksIndex === -1) {\n hooks.push(contextIndex, [indexInFactory, ngOnDestroy]);\n } else {\n hooks[existingCallbacksIndex + 1].push(indexInFactory, ngOnDestroy);\n }\n } else {\n hooks.push(contextIndex, ngOnDestroy);\n }\n }\n }\n}\n/**\n * Add a factory in a multi factory.\n * @returns Index at which the factory was inserted.\n */\nfunction multiFactoryAdd(multiFactory, factory, isComponentProvider) {\n if (isComponentProvider) {\n multiFactory.componentProviders++;\n }\n return multiFactory.multi.push(factory) - 1;\n}\n/**\n * Returns the index of item in the array, but only in the begin to end range.\n */\nfunction indexOf(item, arr, begin, end) {\n for (let i = begin; i < end; i++) {\n if (arr[i] === item) return i;\n }\n return -1;\n}\n/**\n * Use this with `multi` `providers`.\n */\nfunction multiProvidersFactoryResolver(_, tData, lData, tNode) {\n return multiResolve(this.multi, []);\n}\n/**\n * Use this with `multi` `viewProviders`.\n *\n * This factory knows how to concatenate itself with the existing `multi` `providers`.\n */\nfunction multiViewProvidersFactoryResolver(_, tData, lView, tNode) {\n const factories = this.multi;\n let result;\n if (this.providerFactory) {\n const componentCount = this.providerFactory.componentProviders;\n const multiProviders = getNodeInjectable(lView, lView[TVIEW], this.providerFactory.index, tNode);\n // Copy the section of the array which contains `multi` `providers` from the component\n result = multiProviders.slice(0, componentCount);\n // Insert the `viewProvider` instances.\n multiResolve(factories, result);\n // Copy the section of the array which contains `multi` `providers` from other directives\n for (let i = componentCount; i < multiProviders.length; i++) {\n result.push(multiProviders[i]);\n }\n } else {\n result = [];\n // Insert the `viewProvider` instances.\n multiResolve(factories, result);\n }\n return result;\n}\n/**\n * Maps an array of factories into an array of values.\n */\nfunction multiResolve(factories, result) {\n for (let i = 0; i < factories.length; i++) {\n const factory = factories[i];\n result.push(factory());\n }\n return result;\n}\n/**\n * Creates a multi factory.\n */\nfunction multiFactory(factoryFn, index, isViewProvider, isComponent, f) {\n const factory = new NodeInjectorFactory(factoryFn, isViewProvider, ɵɵdirectiveInject);\n factory.multi = [];\n factory.index = index;\n factory.componentProviders = 0;\n multiFactoryAdd(factory, f, isComponent && !isViewProvider);\n return factory;\n}\n\n/**\n * This feature resolves the providers of a directive (or component),\n * and publish them into the DI system, making it visible to others for injection.\n *\n * For example:\n * ```ts\n * class ComponentWithProviders {\n * constructor(private greeter: GreeterDE) {}\n *\n * static ɵcmp = defineComponent({\n * type: ComponentWithProviders,\n * selectors: [['component-with-providers']],\n * factory: () => new ComponentWithProviders(directiveInject(GreeterDE as any)),\n * decls: 1,\n * vars: 1,\n * template: function(fs: RenderFlags, ctx: ComponentWithProviders) {\n * if (fs & RenderFlags.Create) {\n * ɵɵtext(0);\n * }\n * if (fs & RenderFlags.Update) {\n * ɵɵtextInterpolate(ctx.greeter.greet());\n * }\n * },\n * features: [ɵɵProvidersFeature([GreeterDE])]\n * });\n * }\n * ```\n *\n * @param definition\n *\n * @codeGenApi\n */\nfunction ɵɵProvidersFeature(providers, viewProviders = []) {\n return definition => {\n definition.providersResolver = (def, processProvidersFn) => {\n return providersResolver(def,\n //\n processProvidersFn ? processProvidersFn(providers) : providers,\n //\n viewProviders);\n };\n };\n}\n\n/**\n * A feature that adds support for external runtime styles for a component.\n * An external runtime style is a URL to a CSS stylesheet that contains the styles\n * for a given component. For browsers, this URL will be used in an appended `link` element\n * when the component is rendered. This feature is typically used for Hot Module Replacement\n * (HMR) of component stylesheets by leveraging preexisting global stylesheet HMR available\n * in most development servers.\n *\n * @codeGenApi\n */\nfunction ɵɵExternalStylesFeature(styleUrls) {\n return definition => {\n if (styleUrls.length < 1) {\n return;\n }\n definition.getExternalStyles = encapsulationId => {\n // Add encapsulation ID search parameter `ngcomp` to support external style encapsulation as well as the encapsulation mode\n // for usage tracking.\n const urls = styleUrls.map(value => value + '?ngcomp' + (encapsulationId ? '=' + encodeURIComponent(encapsulationId) : '') + '&e=' + definition.encapsulation);\n return urls;\n };\n };\n}\n\n/**\n * Generated next to NgModules to monkey-patch directive and pipe references onto a component's\n * definition, when generating a direct reference in the component file would otherwise create an\n * import cycle.\n *\n * See [this explanation](https://hackmd.io/Odw80D0pR6yfsOjg_7XCJg?view) for more details.\n *\n * @codeGenApi\n */\nfunction ɵɵsetComponentScope(type, directives, pipes) {\n const def = type.ɵcmp;\n def.directiveDefs = extractDefListOrFactory(directives, /* pipeDef */false);\n def.pipeDefs = extractDefListOrFactory(pipes, /* pipeDef */true);\n}\n/**\n * Adds the module metadata that is necessary to compute the module's transitive scope to an\n * existing module definition.\n *\n * Scope metadata of modules is not used in production builds, so calls to this function can be\n * marked pure to tree-shake it from the bundle, allowing for all referenced declarations\n * to become eligible for tree-shaking as well.\n *\n * @codeGenApi\n */\nfunction ɵɵsetNgModuleScope(type, scope) {\n return noSideEffects(() => {\n const ngModuleDef = getNgModuleDef(type, true);\n ngModuleDef.declarations = convertToTypeArray(scope.declarations || EMPTY_ARRAY);\n ngModuleDef.imports = convertToTypeArray(scope.imports || EMPTY_ARRAY);\n ngModuleDef.exports = convertToTypeArray(scope.exports || EMPTY_ARRAY);\n if (scope.bootstrap) {\n // This only happens in local compilation mode.\n ngModuleDef.bootstrap = convertToTypeArray(scope.bootstrap);\n }\n depsTracker.registerNgModule(type, scope);\n });\n}\nfunction convertToTypeArray(values) {\n if (typeof values === 'function') {\n return values;\n }\n const flattenValues = flatten(values);\n if (flattenValues.some(isForwardRef)) {\n return () => flattenValues.map(resolveForwardRef).map(maybeUnwrapModuleWithProviders);\n } else {\n return flattenValues.map(maybeUnwrapModuleWithProviders);\n }\n}\nfunction maybeUnwrapModuleWithProviders(value) {\n return isModuleWithProviders(value) ? value.ngModule : value;\n}\n\n/**\n * Bindings for pure functions are stored after regular bindings.\n *\n * |-------decls------|---------vars---------| |----- hostVars (dir1) ------|\n * ------------------------------------------------------------------------------------------\n * | nodes/refs/pipes | bindings | fn slots | injector | dir1 | host bindings | host slots |\n * ------------------------------------------------------------------------------------------\n * ^ ^\n * TView.bindingStartIndex TView.expandoStartIndex\n *\n * Pure function instructions are given an offset from the binding root. Adding the offset to the\n * binding root gives the first index where the bindings are stored. In component views, the binding\n * root is the bindingStartIndex. In host bindings, the binding root is the expandoStartIndex +\n * any directive instances + any hostVars in directives evaluated before it.\n *\n * See VIEW_DATA.md for more information about host binding resolution.\n */\n/**\n * If the value hasn't been saved, calls the pure function to store and return the\n * value. If it has been saved, returns the saved value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn Function that returns a value\n * @param thisArg Optional calling context of pureFn\n * @returns value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction0(slotOffset, pureFn, thisArg) {\n const bindingIndex = getBindingRoot() + slotOffset;\n const lView = getLView();\n return lView[bindingIndex] === NO_CHANGE ? updateBinding(lView, bindingIndex, thisArg ? pureFn.call(thisArg) : pureFn()) : getBinding(lView, bindingIndex);\n}\n/**\n * If the value of the provided exp has changed, calls the pure function to return\n * an updated value. Or if the value has not changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn Function that returns an updated value\n * @param exp Updated expression value\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction1(slotOffset, pureFn, exp, thisArg) {\n return pureFunction1Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp, thisArg);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction2(slotOffset, pureFn, exp1, exp2, thisArg) {\n return pureFunction2Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp1, exp2, thisArg);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction3(slotOffset, pureFn, exp1, exp2, exp3, thisArg) {\n return pureFunction3Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp1, exp2, exp3, thisArg);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param exp4\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction4(slotOffset, pureFn, exp1, exp2, exp3, exp4, thisArg) {\n return pureFunction4Internal(getLView(), getBindingRoot(), slotOffset, pureFn, exp1, exp2, exp3, exp4, thisArg);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param exp4\n * @param exp5\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction5(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, thisArg) {\n const bindingIndex = getBindingRoot() + slotOffset;\n const lView = getLView();\n const different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);\n return bindingUpdated(lView, bindingIndex + 4, exp5) || different ? updateBinding(lView, bindingIndex + 5, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5) : pureFn(exp1, exp2, exp3, exp4, exp5)) : getBinding(lView, bindingIndex + 5);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param exp4\n * @param exp5\n * @param exp6\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction6(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, exp6, thisArg) {\n const bindingIndex = getBindingRoot() + slotOffset;\n const lView = getLView();\n const different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);\n return bindingUpdated2(lView, bindingIndex + 4, exp5, exp6) || different ? updateBinding(lView, bindingIndex + 6, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5, exp6) : pureFn(exp1, exp2, exp3, exp4, exp5, exp6)) : getBinding(lView, bindingIndex + 6);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param exp4\n * @param exp5\n * @param exp6\n * @param exp7\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction7(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, exp6, exp7, thisArg) {\n const bindingIndex = getBindingRoot() + slotOffset;\n const lView = getLView();\n let different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);\n return bindingUpdated3(lView, bindingIndex + 4, exp5, exp6, exp7) || different ? updateBinding(lView, bindingIndex + 7, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5, exp6, exp7) : pureFn(exp1, exp2, exp3, exp4, exp5, exp6, exp7)) : getBinding(lView, bindingIndex + 7);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param exp4\n * @param exp5\n * @param exp6\n * @param exp7\n * @param exp8\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunction8(slotOffset, pureFn, exp1, exp2, exp3, exp4, exp5, exp6, exp7, exp8, thisArg) {\n const bindingIndex = getBindingRoot() + slotOffset;\n const lView = getLView();\n const different = bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4);\n return bindingUpdated4(lView, bindingIndex + 4, exp5, exp6, exp7, exp8) || different ? updateBinding(lView, bindingIndex + 8, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4, exp5, exp6, exp7, exp8) : pureFn(exp1, exp2, exp3, exp4, exp5, exp6, exp7, exp8)) : getBinding(lView, bindingIndex + 8);\n}\n/**\n * pureFunction instruction that can support any number of bindings.\n *\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn A pure function that takes binding values and builds an object or array\n * containing those values.\n * @param exps An array of binding values\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n * @codeGenApi\n */\nfunction ɵɵpureFunctionV(slotOffset, pureFn, exps, thisArg) {\n return pureFunctionVInternal(getLView(), getBindingRoot(), slotOffset, pureFn, exps, thisArg);\n}\n/**\n * Results of a pure function invocation are stored in LView in a dedicated slot that is initialized\n * to NO_CHANGE. In rare situations a pure pipe might throw an exception on the very first\n * invocation and not produce any valid results. In this case LView would keep holding the NO_CHANGE\n * value. The NO_CHANGE is not something that we can use in expressions / bindings thus we convert\n * it to `undefined`.\n */\nfunction getPureFunctionReturnValue(lView, returnValueIndex) {\n ngDevMode && assertIndexInRange(lView, returnValueIndex);\n const lastReturnValue = lView[returnValueIndex];\n return lastReturnValue === NO_CHANGE ? undefined : lastReturnValue;\n}\n/**\n * If the value of the provided exp has changed, calls the pure function to return\n * an updated value. Or if the value has not changed, returns cached value.\n *\n * @param lView LView in which the function is being executed.\n * @param bindingRoot Binding root index.\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn Function that returns an updated value\n * @param exp Updated expression value\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n */\nfunction pureFunction1Internal(lView, bindingRoot, slotOffset, pureFn, exp, thisArg) {\n const bindingIndex = bindingRoot + slotOffset;\n return bindingUpdated(lView, bindingIndex, exp) ? updateBinding(lView, bindingIndex + 1, thisArg ? pureFn.call(thisArg, exp) : pureFn(exp)) : getPureFunctionReturnValue(lView, bindingIndex + 1);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param lView LView in which the function is being executed.\n * @param bindingRoot Binding root index.\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n */\nfunction pureFunction2Internal(lView, bindingRoot, slotOffset, pureFn, exp1, exp2, thisArg) {\n const bindingIndex = bindingRoot + slotOffset;\n return bindingUpdated2(lView, bindingIndex, exp1, exp2) ? updateBinding(lView, bindingIndex + 2, thisArg ? pureFn.call(thisArg, exp1, exp2) : pureFn(exp1, exp2)) : getPureFunctionReturnValue(lView, bindingIndex + 2);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param lView LView in which the function is being executed.\n * @param bindingRoot Binding root index.\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n */\nfunction pureFunction3Internal(lView, bindingRoot, slotOffset, pureFn, exp1, exp2, exp3, thisArg) {\n const bindingIndex = bindingRoot + slotOffset;\n return bindingUpdated3(lView, bindingIndex, exp1, exp2, exp3) ? updateBinding(lView, bindingIndex + 3, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3) : pureFn(exp1, exp2, exp3)) : getPureFunctionReturnValue(lView, bindingIndex + 3);\n}\n/**\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param lView LView in which the function is being executed.\n * @param bindingRoot Binding root index.\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn\n * @param exp1\n * @param exp2\n * @param exp3\n * @param exp4\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n *\n */\nfunction pureFunction4Internal(lView, bindingRoot, slotOffset, pureFn, exp1, exp2, exp3, exp4, thisArg) {\n const bindingIndex = bindingRoot + slotOffset;\n return bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4) ? updateBinding(lView, bindingIndex + 4, thisArg ? pureFn.call(thisArg, exp1, exp2, exp3, exp4) : pureFn(exp1, exp2, exp3, exp4)) : getPureFunctionReturnValue(lView, bindingIndex + 4);\n}\n/**\n * pureFunction instruction that can support any number of bindings.\n *\n * If the value of any provided exp has changed, calls the pure function to return\n * an updated value. Or if no values have changed, returns cached value.\n *\n * @param lView LView in which the function is being executed.\n * @param bindingRoot Binding root index.\n * @param slotOffset the offset from binding root to the reserved slot\n * @param pureFn A pure function that takes binding values and builds an object or array\n * containing those values.\n * @param exps An array of binding values\n * @param thisArg Optional calling context of pureFn\n * @returns Updated or cached value\n */\nfunction pureFunctionVInternal(lView, bindingRoot, slotOffset, pureFn, exps, thisArg) {\n let bindingIndex = bindingRoot + slotOffset;\n let different = false;\n for (let i = 0; i < exps.length; i++) {\n bindingUpdated(lView, bindingIndex++, exps[i]) && (different = true);\n }\n return different ? updateBinding(lView, bindingIndex, pureFn.apply(thisArg, exps)) : getPureFunctionReturnValue(lView, bindingIndex);\n}\n\n/**\n * Create a pipe.\n *\n * @param index Pipe index where the pipe will be stored.\n * @param pipeName The name of the pipe\n * @returns T the instance of the pipe.\n *\n * @codeGenApi\n */\nfunction ɵɵpipe(index, pipeName) {\n const tView = getTView();\n let pipeDef;\n const adjustedIndex = index + HEADER_OFFSET;\n if (tView.firstCreatePass) {\n // The `getPipeDef` throws if a pipe with a given name is not found\n // (so we use non-null assertion below).\n pipeDef = getPipeDef(pipeName, tView.pipeRegistry);\n tView.data[adjustedIndex] = pipeDef;\n if (pipeDef.onDestroy) {\n (tView.destroyHooks ??= []).push(adjustedIndex, pipeDef.onDestroy);\n }\n } else {\n pipeDef = tView.data[adjustedIndex];\n }\n const pipeFactory = pipeDef.factory || (pipeDef.factory = getFactoryDef(pipeDef.type, true));\n let previousInjectorProfilerContext;\n if (ngDevMode) {\n previousInjectorProfilerContext = setInjectorProfilerContext({\n injector: new NodeInjector(getCurrentTNode(), getLView()),\n token: pipeDef.type\n });\n }\n const previousInjectImplementation = setInjectImplementation(ɵɵdirectiveInject);\n try {\n // DI for pipes is supposed to behave like directives when placed on a component\n // host node, which means that we have to disable access to `viewProviders`.\n const previousIncludeViewProviders = setIncludeViewProviders(false);\n const pipeInstance = pipeFactory();\n setIncludeViewProviders(previousIncludeViewProviders);\n store(tView, getLView(), adjustedIndex, pipeInstance);\n return pipeInstance;\n } finally {\n // we have to restore the injector implementation in finally, just in case the creation of the\n // pipe throws an error.\n setInjectImplementation(previousInjectImplementation);\n ngDevMode && setInjectorProfilerContext(previousInjectorProfilerContext);\n }\n}\n/**\n * Searches the pipe registry for a pipe with the given name. If one is found,\n * returns the pipe. Otherwise, an error is thrown because the pipe cannot be resolved.\n *\n * @param name Name of pipe to resolve\n * @param registry Full list of available pipes\n * @returns Matching PipeDef\n */\nfunction getPipeDef(name, registry) {\n if (registry) {\n if (ngDevMode) {\n const pipes = registry.filter(pipe => pipe.name === name);\n // TODO: Throw an error in the next major\n if (pipes.length > 1) {\n console.warn(formatRuntimeError(313 /* RuntimeErrorCode.MULTIPLE_MATCHING_PIPES */, getMultipleMatchingPipesMessage(name)));\n }\n }\n for (let i = registry.length - 1; i >= 0; i--) {\n const pipeDef = registry[i];\n if (name === pipeDef.name) {\n return pipeDef;\n }\n }\n }\n if (ngDevMode) {\n throw new RuntimeError(-302 /* RuntimeErrorCode.PIPE_NOT_FOUND */, getPipeNotFoundErrorMessage(name));\n }\n return;\n}\n/**\n * Generates a helpful error message for the user when multiple pipes match the name.\n *\n * @param name Name of the pipe\n * @returns The error message\n */\nfunction getMultipleMatchingPipesMessage(name) {\n const lView = getLView();\n const declarationLView = lView[DECLARATION_COMPONENT_VIEW];\n const context = declarationLView[CONTEXT];\n const hostIsStandalone = isHostComponentStandalone(lView);\n const componentInfoMessage = context ? ` in the '${context.constructor.name}' component` : '';\n const verifyMessage = `check ${hostIsStandalone ? \"'@Component.imports' of this component\" : 'the imports of this module'}`;\n const errorMessage = `Multiple pipes match the name \\`${name}\\`${componentInfoMessage}. ${verifyMessage}`;\n return errorMessage;\n}\n/**\n * Generates a helpful error message for the user when a pipe is not found.\n *\n * @param name Name of the missing pipe\n * @returns The error message\n */\nfunction getPipeNotFoundErrorMessage(name) {\n const lView = getLView();\n const declarationLView = lView[DECLARATION_COMPONENT_VIEW];\n const context = declarationLView[CONTEXT];\n const hostIsStandalone = isHostComponentStandalone(lView);\n const componentInfoMessage = context ? ` in the '${context.constructor.name}' component` : '';\n const verifyMessage = `Verify that it is ${hostIsStandalone ? \"included in the '@Component.imports' of this component\" : 'declared or imported in this module'}`;\n const errorMessage = `The pipe '${name}' could not be found${componentInfoMessage}. ${verifyMessage}`;\n return errorMessage;\n}\n/**\n * Invokes a pipe with 1 arguments.\n *\n * This instruction acts as a guard to {@link PipeTransform#transform} invoking\n * the pipe only when an input to the pipe changes.\n *\n * @param index Pipe index where the pipe was stored on creation.\n * @param offset the binding offset\n * @param v1 1st argument to {@link PipeTransform#transform}.\n *\n * @codeGenApi\n */\nfunction ɵɵpipeBind1(index, offset, v1) {\n const adjustedIndex = index + HEADER_OFFSET;\n const lView = getLView();\n const pipeInstance = load(lView, adjustedIndex);\n return isPure(lView, adjustedIndex) ? pureFunction1Internal(lView, getBindingRoot(), offset, pipeInstance.transform, v1, pipeInstance) : pipeInstance.transform(v1);\n}\n/**\n * Invokes a pipe with 2 arguments.\n *\n * This instruction acts as a guard to {@link PipeTransform#transform} invoking\n * the pipe only when an input to the pipe changes.\n *\n * @param index Pipe index where the pipe was stored on creation.\n * @param slotOffset the offset in the reserved slot space\n * @param v1 1st argument to {@link PipeTransform#transform}.\n * @param v2 2nd argument to {@link PipeTransform#transform}.\n *\n * @codeGenApi\n */\nfunction ɵɵpipeBind2(index, slotOffset, v1, v2) {\n const adjustedIndex = index + HEADER_OFFSET;\n const lView = getLView();\n const pipeInstance = load(lView, adjustedIndex);\n return isPure(lView, adjustedIndex) ? pureFunction2Internal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, v1, v2, pipeInstance) : pipeInstance.transform(v1, v2);\n}\n/**\n * Invokes a pipe with 3 arguments.\n *\n * This instruction acts as a guard to {@link PipeTransform#transform} invoking\n * the pipe only when an input to the pipe changes.\n *\n * @param index Pipe index where the pipe was stored on creation.\n * @param slotOffset the offset in the reserved slot space\n * @param v1 1st argument to {@link PipeTransform#transform}.\n * @param v2 2nd argument to {@link PipeTransform#transform}.\n * @param v3 4rd argument to {@link PipeTransform#transform}.\n *\n * @codeGenApi\n */\nfunction ɵɵpipeBind3(index, slotOffset, v1, v2, v3) {\n const adjustedIndex = index + HEADER_OFFSET;\n const lView = getLView();\n const pipeInstance = load(lView, adjustedIndex);\n return isPure(lView, adjustedIndex) ? pureFunction3Internal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, v1, v2, v3, pipeInstance) : pipeInstance.transform(v1, v2, v3);\n}\n/**\n * Invokes a pipe with 4 arguments.\n *\n * This instruction acts as a guard to {@link PipeTransform#transform} invoking\n * the pipe only when an input to the pipe changes.\n *\n * @param index Pipe index where the pipe was stored on creation.\n * @param slotOffset the offset in the reserved slot space\n * @param v1 1st argument to {@link PipeTransform#transform}.\n * @param v2 2nd argument to {@link PipeTransform#transform}.\n * @param v3 3rd argument to {@link PipeTransform#transform}.\n * @param v4 4th argument to {@link PipeTransform#transform}.\n *\n * @codeGenApi\n */\nfunction ɵɵpipeBind4(index, slotOffset, v1, v2, v3, v4) {\n const adjustedIndex = index + HEADER_OFFSET;\n const lView = getLView();\n const pipeInstance = load(lView, adjustedIndex);\n return isPure(lView, adjustedIndex) ? pureFunction4Internal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, v1, v2, v3, v4, pipeInstance) : pipeInstance.transform(v1, v2, v3, v4);\n}\n/**\n * Invokes a pipe with variable number of arguments.\n *\n * This instruction acts as a guard to {@link PipeTransform#transform} invoking\n * the pipe only when an input to the pipe changes.\n *\n * @param index Pipe index where the pipe was stored on creation.\n * @param slotOffset the offset in the reserved slot space\n * @param values Array of arguments to pass to {@link PipeTransform#transform} method.\n *\n * @codeGenApi\n */\nfunction ɵɵpipeBindV(index, slotOffset, values) {\n const adjustedIndex = index + HEADER_OFFSET;\n const lView = getLView();\n const pipeInstance = load(lView, adjustedIndex);\n return isPure(lView, adjustedIndex) ? pureFunctionVInternal(lView, getBindingRoot(), slotOffset, pipeInstance.transform, values, pipeInstance) : pipeInstance.transform.apply(pipeInstance, values);\n}\nfunction isPure(lView, index) {\n return lView[TVIEW].data[index].pure;\n}\n\n/**\n * Retrieves `TemplateRef` instance from `Injector` when a local reference is placed on the\n * `<ng-template>` element.\n *\n * @codeGenApi\n */\nfunction ɵɵtemplateRefExtractor(tNode, lView) {\n return createTemplateRef(tNode, lView);\n}\nfunction ɵɵgetComponentDepsFactory(type, rawImports) {\n return () => {\n try {\n return depsTracker.getComponentDependencies(type, rawImports).dependencies;\n } catch (e) {\n console.error(`Computing dependencies in local compilation mode for the component \"${type.name}\" failed with the exception:`, e);\n throw e;\n }\n };\n}\n\n/**\n * Sets the debug info for an Angular class.\n *\n * This runtime is guarded by ngDevMode flag.\n */\nfunction ɵsetClassDebugInfo(type, debugInfo) {\n const def = getComponentDef(type);\n if (def !== null) {\n def.debugInfo = debugInfo;\n }\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Replaces the metadata of a component type and re-renders all live instances of the component.\n * @param type Class whose metadata will be replaced.\n * @param applyMetadata Callback that will apply a new set of metadata on the `type` when invoked.\n * @param environment Syntehtic namespace imports that need to be passed along to the callback.\n * @param locals Local symbols from the source location that have to be exposed to the callback.\n * @param importMeta `import.meta` from the call site of the replacement function. Optional since\n * it isn't used internally.\n * @param id ID to the class being replaced. **Not** the same as the component definition ID.\n * Optional since the ID might not be available internally.\n * @codeGenApi\n */\nfunction ɵɵreplaceMetadata(type, applyMetadata, namespaces, locals, importMeta = null, id = null) {\n ngDevMode && assertComponentDef(type);\n const currentDef = getComponentDef(type);\n // The reason `applyMetadata` is a callback that is invoked (almost) immediately is because\n // the compiler usually produces more code than just the component definition, e.g. there\n // can be functions for embedded views, the variables for the constant pool and `setClassMetadata`\n // calls. The callback allows us to keep them isolate from the rest of the app and to invoke\n // them at the right time.\n applyMetadata.apply(null, [type, namespaces, ...locals]);\n const {\n newDef,\n oldDef\n } = mergeWithExistingDefinition(currentDef, getComponentDef(type));\n // TODO(crisbeto): the `applyMetadata` call above will replace the definition on the type.\n // Ideally we should adjust the compiler output so the metadata is returned, however that'll\n // require some internal changes. We re-add the metadata here manually.\n type[NG_COMP_DEF] = newDef;\n // If a `tView` hasn't been created yet, it means that this component hasn't been instantianted\n // before. In this case there's nothing left for us to do aside from patching it in.\n if (oldDef.tView) {\n const trackedViews = getTrackedLViews().values();\n for (const root of trackedViews) {\n // Note: we have the additional check, because `IsRoot` can also indicate\n // a component created through something like `createComponent`.\n if (isRootView(root) && root[PARENT] === null) {\n recreateMatchingLViews(importMeta, id, newDef, oldDef, root);\n }\n }\n }\n}\n/**\n * Merges two component definitions while preseving the original one in place.\n * @param currentDef Definition that should receive the new metadata.\n * @param newDef Source of the new metadata.\n */\nfunction mergeWithExistingDefinition(currentDef, newDef) {\n // Clone the current definition since we reference its original data further\n // down in the replacement process (e.g. when destroying the renderer).\n const clone = {\n ...currentDef\n };\n // Assign the new metadata in place while preserving the object literal. It's important to\n // Keep the object in place, because there can be references to it, for example in the\n // `directiveDefs` of another definition.\n const replacement = Object.assign(currentDef, newDef, {\n // We need to keep the existing directive and pipe defs, because they can get patched on\n // by a call to `setComponentScope` from a module file. That call won't make it into the\n // HMR replacement function, because it lives in an entirely different file.\n directiveDefs: clone.directiveDefs,\n pipeDefs: clone.pipeDefs,\n // Preserve the old `setInput` function, because it has some state.\n // This is fine, because the component instance is preserved as well.\n setInput: clone.setInput,\n // Externally this is redundant since we redeclare the definition using the original type.\n // Internally we may receive a definition with an alternate, but identical, type so we have\n // to ensure that the original one is preserved.\n type: clone.type\n });\n ngDevMode && assertEqual(replacement, currentDef, 'Expected definition to be merged in place');\n return {\n newDef: replacement,\n oldDef: clone\n };\n}\n/**\n * Finds all LViews matching a specific component definition and recreates them.\n * @param importMeta `import.meta` information.\n * @param id HMR ID of the component.\n * @param oldDef Component definition to search for.\n * @param rootLView View from which to start the search.\n */\nfunction recreateMatchingLViews(importMeta, id, newDef, oldDef, rootLView) {\n ngDevMode && assertDefined(oldDef.tView, 'Expected a component definition that has been instantiated at least once');\n const tView = rootLView[TVIEW];\n // Use `tView` to match the LView since `instanceof` can\n // produce false positives when using inheritance.\n if (tView === oldDef.tView) {\n ngDevMode && assertComponentDef(oldDef.type);\n recreateLView(importMeta, id, newDef, oldDef, rootLView);\n return;\n }\n for (let i = HEADER_OFFSET; i < tView.bindingStartIndex; i++) {\n const current = rootLView[i];\n if (isLContainer(current)) {\n // The host can be an LView if a component is injecting `ViewContainerRef`.\n if (isLView(current[HOST])) {\n recreateMatchingLViews(importMeta, id, newDef, oldDef, current[HOST]);\n }\n for (let j = CONTAINER_HEADER_OFFSET; j < current.length; j++) {\n recreateMatchingLViews(importMeta, id, newDef, oldDef, current[j]);\n }\n } else if (isLView(current)) {\n recreateMatchingLViews(importMeta, id, newDef, oldDef, current);\n }\n }\n}\n/**\n * Removes any cached renderers from the factory for the provided type.\n * This is currently used by the HMR logic to ensure Renderers are kept\n * synchronized with any definition metadata updates.\n * @param factory A RendererFactory2 instance.\n * @param def A ComponentDef instance.\n */\nfunction clearRendererCache(factory, def) {\n // Cast to read a private field.\n // NOTE: This must be kept synchronized with the renderer factory implementation in\n // platform-browser and platform-browser/animations.\n factory.componentReplaced?.(def.id);\n}\n/**\n * Recreates an LView in-place from a new component definition.\n * @param importMeta `import.meta` information.\n * @param id HMR ID for the component.\n * @param newDef Definition from which to recreate the view.\n * @param oldDef Previous component definition being swapped out.\n * @param lView View to be recreated.\n */\nfunction recreateLView(importMeta, id, newDef, oldDef, lView) {\n const instance = lView[CONTEXT];\n let host = lView[HOST];\n // In theory the parent can also be an LContainer, but it appears like that's\n // only the case for embedded views which we won't be replacing here.\n const parentLView = lView[PARENT];\n ngDevMode && assertLView(parentLView);\n const tNode = lView[T_HOST];\n ngDevMode && assertTNodeType(tNode, 2 /* TNodeType.Element */);\n ngDevMode && assertNotEqual(newDef, oldDef, 'Expected different component definition');\n const zone = lView[INJECTOR].get(NgZone, null);\n const recreate = () => {\n // If we're recreating a component with shadow DOM encapsulation, it will have attached a\n // shadow root. The browser will throw if we attempt to attach another one and there's no way\n // to detach it. Our only option is to make a clone only of the root node, replace the node\n // with the clone and use it for the newly-created LView.\n if (oldDef.encapsulation === ViewEncapsulation.ShadowDom) {\n const newHost = host.cloneNode(false);\n host.replaceWith(newHost);\n host = newHost;\n }\n // Recreate the TView since the template might've changed.\n const newTView = getOrCreateComponentTView(newDef);\n // Create a new LView from the new TView, but reusing the existing TNode and DOM node.\n const newLView = createLView(parentLView, newTView, instance, getInitialLViewFlagsFromDef(newDef), host, tNode, null, null,\n // The renderer will be created a bit further down once the old one is destroyed.\n null, null, null);\n // Detach the LView from its current place in the tree so we don't\n // start traversing any siblings and modifying their structure.\n replaceLViewInTree(parentLView, lView, newLView, tNode.index);\n // Destroy the detached LView.\n destroyLView(lView[TVIEW], lView);\n // Always force the creation of a new renderer to ensure state captured during construction\n // stays consistent with the new component definition by clearing any old ached factories.\n const rendererFactory = lView[ENVIRONMENT].rendererFactory;\n clearRendererCache(rendererFactory, oldDef);\n // Patch a brand-new renderer onto the new view only after the old\n // view is destroyed so that the runtime doesn't try to reuse it.\n newLView[RENDERER] = rendererFactory.createRenderer(host, newDef);\n // Remove the nodes associated with the destroyed LView. This removes the\n // descendants, but not the host which we want to stay in place.\n removeViewFromDOM(lView[TVIEW], lView);\n // Reset the content projection state of the TNode before the first render.\n // Note that this has to happen after the LView has been destroyed or we\n // risk some projected nodes not being removed correctly.\n resetProjectionState(tNode);\n // Creation pass for the new view.\n renderView(newTView, newLView, instance);\n // Update pass for the new view.\n refreshView(newTView, newLView, newTView.template, instance);\n };\n // The callback isn't guaranteed to be inside the Zone so we need to bring it in ourselves.\n if (zone === null) {\n executeWithInvalidateFallback(importMeta, id, recreate);\n } else {\n zone.run(() => executeWithInvalidateFallback(importMeta, id, recreate));\n }\n}\n/**\n * Runs an HMR-related function and falls back to\n * invalidating the HMR data if it throws an error.\n */\nfunction executeWithInvalidateFallback(importMeta, id, callback) {\n try {\n callback();\n } catch (e) {\n const error = e;\n // If we have all the necessary information and APIs to send off the invalidation\n // request, send it before rethrowing so the dev server can decide what to do.\n if (id !== null && error.message) {\n const toLog = error.message + (error.stack ? '\\n' + error.stack : '');\n importMeta?.hot?.send?.('angular:invalidate', {\n id,\n message: toLog,\n error: true\n });\n }\n // Throw the error in case the page doesn't get refreshed.\n throw e;\n }\n}\n/**\n * Replaces one LView in the tree with another one.\n * @param parentLView Parent of the LView being replaced.\n * @param oldLView LView being replaced.\n * @param newLView Replacement LView to be inserted.\n * @param index Index at which the LView should be inserted.\n */\nfunction replaceLViewInTree(parentLView, oldLView, newLView, index) {\n // Update the sibling whose `NEXT` pointer refers to the old view.\n for (let i = HEADER_OFFSET; i < parentLView[TVIEW].bindingStartIndex; i++) {\n const current = parentLView[i];\n if ((isLView(current) || isLContainer(current)) && current[NEXT] === oldLView) {\n current[NEXT] = newLView;\n break;\n }\n }\n // Set the new view as the head, if the old view was first.\n if (parentLView[CHILD_HEAD] === oldLView) {\n parentLView[CHILD_HEAD] = newLView;\n }\n // Set the new view as the tail, if the old view was last.\n if (parentLView[CHILD_TAIL] === oldLView) {\n parentLView[CHILD_TAIL] = newLView;\n }\n // Update the `NEXT` pointer to the same as the old view.\n newLView[NEXT] = oldLView[NEXT];\n // Clear out the `NEXT` of the old view.\n oldLView[NEXT] = null;\n // Insert the new LView at the correct index.\n parentLView[index] = newLView;\n}\n/**\n * Child nodes mutate the `projection` state of their parent node as they're being projected.\n * This function resets the `project` back to its initial state.\n * @param tNode\n */\nfunction resetProjectionState(tNode) {\n // The `projection` is mutated by child nodes as they're being projected. We need to\n // reset it to the initial state so projection works after the template is swapped out.\n if (tNode.projection !== null) {\n for (const current of tNode.projection) {\n if (isTNodeShape(current)) {\n // Reset `projectionNext` since it can affect the traversal order during projection.\n current.projectionNext = null;\n current.flags &= ~2 /* TNodeFlags.isProjected */;\n }\n }\n tNode.projection = null;\n }\n}\n\n/**\n * A mapping of the @angular/core API surface used in generated expressions to the actual symbols.\n *\n * This should be kept up to date with the public exports of @angular/core.\n */\nconst angularCoreEnv = (() => ({\n 'ɵɵattribute': ɵɵattribute,\n 'ɵɵattributeInterpolate1': ɵɵattributeInterpolate1,\n 'ɵɵattributeInterpolate2': ɵɵattributeInterpolate2,\n 'ɵɵattributeInterpolate3': ɵɵattributeInterpolate3,\n 'ɵɵattributeInterpolate4': ɵɵattributeInterpolate4,\n 'ɵɵattributeInterpolate5': ɵɵattributeInterpolate5,\n 'ɵɵattributeInterpolate6': ɵɵattributeInterpolate6,\n 'ɵɵattributeInterpolate7': ɵɵattributeInterpolate7,\n 'ɵɵattributeInterpolate8': ɵɵattributeInterpolate8,\n 'ɵɵattributeInterpolateV': ɵɵattributeInterpolateV,\n 'ɵɵdefineComponent': ɵɵdefineComponent,\n 'ɵɵdefineDirective': ɵɵdefineDirective,\n 'ɵɵdefineInjectable': ɵɵdefineInjectable,\n 'ɵɵdefineInjector': ɵɵdefineInjector,\n 'ɵɵdefineNgModule': ɵɵdefineNgModule,\n 'ɵɵdefinePipe': ɵɵdefinePipe,\n 'ɵɵdirectiveInject': ɵɵdirectiveInject,\n 'ɵɵgetInheritedFactory': ɵɵgetInheritedFactory,\n 'ɵɵinject': ɵɵinject,\n 'ɵɵinjectAttribute': ɵɵinjectAttribute,\n 'ɵɵinvalidFactory': ɵɵinvalidFactory,\n 'ɵɵinvalidFactoryDep': ɵɵinvalidFactoryDep,\n 'ɵɵtemplateRefExtractor': ɵɵtemplateRefExtractor,\n 'ɵɵresetView': ɵɵresetView,\n 'ɵɵHostDirectivesFeature': ɵɵHostDirectivesFeature,\n 'ɵɵNgOnChangesFeature': ɵɵNgOnChangesFeature,\n 'ɵɵProvidersFeature': ɵɵProvidersFeature,\n 'ɵɵCopyDefinitionFeature': ɵɵCopyDefinitionFeature,\n 'ɵɵInheritDefinitionFeature': ɵɵInheritDefinitionFeature,\n 'ɵɵExternalStylesFeature': ɵɵExternalStylesFeature,\n 'ɵɵnextContext': ɵɵnextContext,\n 'ɵɵnamespaceHTML': ɵɵnamespaceHTML,\n 'ɵɵnamespaceMathML': ɵɵnamespaceMathML,\n 'ɵɵnamespaceSVG': ɵɵnamespaceSVG,\n 'ɵɵenableBindings': ɵɵenableBindings,\n 'ɵɵdisableBindings': ɵɵdisableBindings,\n 'ɵɵelementStart': ɵɵelementStart,\n 'ɵɵelementEnd': ɵɵelementEnd,\n 'ɵɵelement': ɵɵelement,\n 'ɵɵelementContainerStart': ɵɵelementContainerStart,\n 'ɵɵelementContainerEnd': ɵɵelementContainerEnd,\n 'ɵɵelementContainer': ɵɵelementContainer,\n 'ɵɵpureFunction0': ɵɵpureFunction0,\n 'ɵɵpureFunction1': ɵɵpureFunction1,\n 'ɵɵpureFunction2': ɵɵpureFunction2,\n 'ɵɵpureFunction3': ɵɵpureFunction3,\n 'ɵɵpureFunction4': ɵɵpureFunction4,\n 'ɵɵpureFunction5': ɵɵpureFunction5,\n 'ɵɵpureFunction6': ɵɵpureFunction6,\n 'ɵɵpureFunction7': ɵɵpureFunction7,\n 'ɵɵpureFunction8': ɵɵpureFunction8,\n 'ɵɵpureFunctionV': ɵɵpureFunctionV,\n 'ɵɵgetCurrentView': ɵɵgetCurrentView,\n 'ɵɵrestoreView': ɵɵrestoreView,\n 'ɵɵlistener': ɵɵlistener,\n 'ɵɵprojection': ɵɵprojection,\n 'ɵɵsyntheticHostProperty': ɵɵsyntheticHostProperty,\n 'ɵɵsyntheticHostListener': ɵɵsyntheticHostListener,\n 'ɵɵpipeBind1': ɵɵpipeBind1,\n 'ɵɵpipeBind2': ɵɵpipeBind2,\n 'ɵɵpipeBind3': ɵɵpipeBind3,\n 'ɵɵpipeBind4': ɵɵpipeBind4,\n 'ɵɵpipeBindV': ɵɵpipeBindV,\n 'ɵɵprojectionDef': ɵɵprojectionDef,\n 'ɵɵhostProperty': ɵɵhostProperty,\n 'ɵɵproperty': ɵɵproperty,\n 'ɵɵpropertyInterpolate': ɵɵpropertyInterpolate,\n 'ɵɵpropertyInterpolate1': ɵɵpropertyInterpolate1,\n 'ɵɵpropertyInterpolate2': ɵɵpropertyInterpolate2,\n 'ɵɵpropertyInterpolate3': ɵɵpropertyInterpolate3,\n 'ɵɵpropertyInterpolate4': ɵɵpropertyInterpolate4,\n 'ɵɵpropertyInterpolate5': ɵɵpropertyInterpolate5,\n 'ɵɵpropertyInterpolate6': ɵɵpropertyInterpolate6,\n 'ɵɵpropertyInterpolate7': ɵɵpropertyInterpolate7,\n 'ɵɵpropertyInterpolate8': ɵɵpropertyInterpolate8,\n 'ɵɵpropertyInterpolateV': ɵɵpropertyInterpolateV,\n 'ɵɵpipe': ɵɵpipe,\n 'ɵɵqueryRefresh': ɵɵqueryRefresh,\n 'ɵɵqueryAdvance': ɵɵqueryAdvance,\n 'ɵɵviewQuery': ɵɵviewQuery,\n 'ɵɵviewQuerySignal': ɵɵviewQuerySignal,\n 'ɵɵloadQuery': ɵɵloadQuery,\n 'ɵɵcontentQuery': ɵɵcontentQuery,\n 'ɵɵcontentQuerySignal': ɵɵcontentQuerySignal,\n 'ɵɵreference': ɵɵreference,\n 'ɵɵclassMap': ɵɵclassMap,\n 'ɵɵclassMapInterpolate1': ɵɵclassMapInterpolate1,\n 'ɵɵclassMapInterpolate2': ɵɵclassMapInterpolate2,\n 'ɵɵclassMapInterpolate3': ɵɵclassMapInterpolate3,\n 'ɵɵclassMapInterpolate4': ɵɵclassMapInterpolate4,\n 'ɵɵclassMapInterpolate5': ɵɵclassMapInterpolate5,\n 'ɵɵclassMapInterpolate6': ɵɵclassMapInterpolate6,\n 'ɵɵclassMapInterpolate7': ɵɵclassMapInterpolate7,\n 'ɵɵclassMapInterpolate8': ɵɵclassMapInterpolate8,\n 'ɵɵclassMapInterpolateV': ɵɵclassMapInterpolateV,\n 'ɵɵstyleMap': ɵɵstyleMap,\n 'ɵɵstyleMapInterpolate1': ɵɵstyleMapInterpolate1,\n 'ɵɵstyleMapInterpolate2': ɵɵstyleMapInterpolate2,\n 'ɵɵstyleMapInterpolate3': ɵɵstyleMapInterpolate3,\n 'ɵɵstyleMapInterpolate4': ɵɵstyleMapInterpolate4,\n 'ɵɵstyleMapInterpolate5': ɵɵstyleMapInterpolate5,\n 'ɵɵstyleMapInterpolate6': ɵɵstyleMapInterpolate6,\n 'ɵɵstyleMapInterpolate7': ɵɵstyleMapInterpolate7,\n 'ɵɵstyleMapInterpolate8': ɵɵstyleMapInterpolate8,\n 'ɵɵstyleMapInterpolateV': ɵɵstyleMapInterpolateV,\n 'ɵɵstyleProp': ɵɵstyleProp,\n 'ɵɵstylePropInterpolate1': ɵɵstylePropInterpolate1,\n 'ɵɵstylePropInterpolate2': ɵɵstylePropInterpolate2,\n 'ɵɵstylePropInterpolate3': ɵɵstylePropInterpolate3,\n 'ɵɵstylePropInterpolate4': ɵɵstylePropInterpolate4,\n 'ɵɵstylePropInterpolate5': ɵɵstylePropInterpolate5,\n 'ɵɵstylePropInterpolate6': ɵɵstylePropInterpolate6,\n 'ɵɵstylePropInterpolate7': ɵɵstylePropInterpolate7,\n 'ɵɵstylePropInterpolate8': ɵɵstylePropInterpolate8,\n 'ɵɵstylePropInterpolateV': ɵɵstylePropInterpolateV,\n 'ɵɵclassProp': ɵɵclassProp,\n 'ɵɵadvance': ɵɵadvance,\n 'ɵɵtemplate': ɵɵtemplate,\n 'ɵɵconditional': ɵɵconditional,\n 'ɵɵdefer': ɵɵdefer,\n 'ɵɵdeferWhen': ɵɵdeferWhen,\n 'ɵɵdeferOnIdle': ɵɵdeferOnIdle,\n 'ɵɵdeferOnImmediate': ɵɵdeferOnImmediate,\n 'ɵɵdeferOnTimer': ɵɵdeferOnTimer,\n 'ɵɵdeferOnHover': ɵɵdeferOnHover,\n 'ɵɵdeferOnInteraction': ɵɵdeferOnInteraction,\n 'ɵɵdeferOnViewport': ɵɵdeferOnViewport,\n 'ɵɵdeferPrefetchWhen': ɵɵdeferPrefetchWhen,\n 'ɵɵdeferPrefetchOnIdle': ɵɵdeferPrefetchOnIdle,\n 'ɵɵdeferPrefetchOnImmediate': ɵɵdeferPrefetchOnImmediate,\n 'ɵɵdeferPrefetchOnTimer': ɵɵdeferPrefetchOnTimer,\n 'ɵɵdeferPrefetchOnHover': ɵɵdeferPrefetchOnHover,\n 'ɵɵdeferPrefetchOnInteraction': ɵɵdeferPrefetchOnInteraction,\n 'ɵɵdeferPrefetchOnViewport': ɵɵdeferPrefetchOnViewport,\n 'ɵɵdeferHydrateWhen': ɵɵdeferHydrateWhen,\n 'ɵɵdeferHydrateNever': ɵɵdeferHydrateNever,\n 'ɵɵdeferHydrateOnIdle': ɵɵdeferHydrateOnIdle,\n 'ɵɵdeferHydrateOnImmediate': ɵɵdeferHydrateOnImmediate,\n 'ɵɵdeferHydrateOnTimer': ɵɵdeferHydrateOnTimer,\n 'ɵɵdeferHydrateOnHover': ɵɵdeferHydrateOnHover,\n 'ɵɵdeferHydrateOnInteraction': ɵɵdeferHydrateOnInteraction,\n 'ɵɵdeferHydrateOnViewport': ɵɵdeferHydrateOnViewport,\n 'ɵɵdeferEnableTimerScheduling': ɵɵdeferEnableTimerScheduling,\n 'ɵɵrepeater': ɵɵrepeater,\n 'ɵɵrepeaterCreate': ɵɵrepeaterCreate,\n 'ɵɵrepeaterTrackByIndex': ɵɵrepeaterTrackByIndex,\n 'ɵɵrepeaterTrackByIdentity': ɵɵrepeaterTrackByIdentity,\n 'ɵɵcomponentInstance': ɵɵcomponentInstance,\n 'ɵɵtext': ɵɵtext,\n 'ɵɵtextInterpolate': ɵɵtextInterpolate,\n 'ɵɵtextInterpolate1': ɵɵtextInterpolate1,\n 'ɵɵtextInterpolate2': ɵɵtextInterpolate2,\n 'ɵɵtextInterpolate3': ɵɵtextInterpolate3,\n 'ɵɵtextInterpolate4': ɵɵtextInterpolate4,\n 'ɵɵtextInterpolate5': ɵɵtextInterpolate5,\n 'ɵɵtextInterpolate6': ɵɵtextInterpolate6,\n 'ɵɵtextInterpolate7': ɵɵtextInterpolate7,\n 'ɵɵtextInterpolate8': ɵɵtextInterpolate8,\n 'ɵɵtextInterpolateV': ɵɵtextInterpolateV,\n 'ɵɵi18n': ɵɵi18n,\n 'ɵɵi18nAttributes': ɵɵi18nAttributes,\n 'ɵɵi18nExp': ɵɵi18nExp,\n 'ɵɵi18nStart': ɵɵi18nStart,\n 'ɵɵi18nEnd': ɵɵi18nEnd,\n 'ɵɵi18nApply': ɵɵi18nApply,\n 'ɵɵi18nPostprocess': ɵɵi18nPostprocess,\n 'ɵɵresolveWindow': ɵɵresolveWindow,\n 'ɵɵresolveDocument': ɵɵresolveDocument,\n 'ɵɵresolveBody': ɵɵresolveBody,\n 'ɵɵsetComponentScope': ɵɵsetComponentScope,\n 'ɵɵsetNgModuleScope': ɵɵsetNgModuleScope,\n 'ɵɵregisterNgModuleType': registerNgModuleType,\n 'ɵɵgetComponentDepsFactory': ɵɵgetComponentDepsFactory,\n 'ɵsetClassDebugInfo': ɵsetClassDebugInfo,\n 'ɵɵdeclareLet': ɵɵdeclareLet,\n 'ɵɵstoreLet': ɵɵstoreLet,\n 'ɵɵreadContextLet': ɵɵreadContextLet,\n 'ɵɵattachSourceLocations': ɵɵattachSourceLocations,\n 'ɵɵsanitizeHtml': ɵɵsanitizeHtml,\n 'ɵɵsanitizeStyle': ɵɵsanitizeStyle,\n 'ɵɵsanitizeResourceUrl': ɵɵsanitizeResourceUrl,\n 'ɵɵsanitizeScript': ɵɵsanitizeScript,\n 'ɵɵsanitizeUrl': ɵɵsanitizeUrl,\n 'ɵɵsanitizeUrlOrResourceUrl': ɵɵsanitizeUrlOrResourceUrl,\n 'ɵɵtrustConstantHtml': ɵɵtrustConstantHtml,\n 'ɵɵtrustConstantResourceUrl': ɵɵtrustConstantResourceUrl,\n 'ɵɵvalidateIframeAttribute': ɵɵvalidateIframeAttribute,\n 'forwardRef': forwardRef,\n 'resolveForwardRef': resolveForwardRef,\n 'ɵɵtwoWayProperty': ɵɵtwoWayProperty,\n 'ɵɵtwoWayBindingSet': ɵɵtwoWayBindingSet,\n 'ɵɵtwoWayListener': ɵɵtwoWayListener,\n 'ɵɵreplaceMetadata': ɵɵreplaceMetadata\n}))();\nlet jitOptions = null;\nfunction setJitOptions(options) {\n if (jitOptions !== null) {\n if (options.defaultEncapsulation !== jitOptions.defaultEncapsulation) {\n ngDevMode && console.error('Provided value for `defaultEncapsulation` can not be changed once it has been set.');\n return;\n }\n if (options.preserveWhitespaces !== jitOptions.preserveWhitespaces) {\n ngDevMode && console.error('Provided value for `preserveWhitespaces` can not be changed once it has been set.');\n return;\n }\n }\n jitOptions = options;\n}\nfunction getJitOptions() {\n return jitOptions;\n}\nfunction resetJitOptions() {\n jitOptions = null;\n}\nfunction patchModuleCompilation() {\n // Does nothing, but exists as a target for patching.\n}\nconst moduleQueue = [];\n/**\n * Enqueues moduleDef to be checked later to see if scope can be set on its\n * component declarations.\n */\nfunction enqueueModuleForDelayedScoping(moduleType, ngModule) {\n moduleQueue.push({\n moduleType,\n ngModule\n });\n}\nlet flushingModuleQueue = false;\n/**\n * Loops over queued module definitions, if a given module definition has all of its\n * declarations resolved, it dequeues that module definition and sets the scope on\n * its declarations.\n */\nfunction flushModuleScopingQueueAsMuchAsPossible() {\n if (!flushingModuleQueue) {\n flushingModuleQueue = true;\n try {\n for (let i = moduleQueue.length - 1; i >= 0; i--) {\n const {\n moduleType,\n ngModule\n } = moduleQueue[i];\n if (ngModule.declarations && ngModule.declarations.every(isResolvedDeclaration)) {\n // dequeue\n moduleQueue.splice(i, 1);\n setScopeOnDeclaredComponents(moduleType, ngModule);\n }\n }\n } finally {\n flushingModuleQueue = false;\n }\n }\n}\n/**\n * Returns truthy if a declaration has resolved. If the declaration happens to be\n * an array of declarations, it will recurse to check each declaration in that array\n * (which may also be arrays).\n */\nfunction isResolvedDeclaration(declaration) {\n if (Array.isArray(declaration)) {\n return declaration.every(isResolvedDeclaration);\n }\n return !!resolveForwardRef(declaration);\n}\n/**\n * Compiles a module in JIT mode.\n *\n * This function automatically gets called when a class has a `@NgModule` decorator.\n */\nfunction compileNgModule(moduleType, ngModule = {}) {\n patchModuleCompilation();\n compileNgModuleDefs(moduleType, ngModule);\n if (ngModule.id !== undefined) {\n registerNgModuleType(moduleType, ngModule.id);\n }\n // Because we don't know if all declarations have resolved yet at the moment the\n // NgModule decorator is executing, we're enqueueing the setting of module scope\n // on its declarations to be run at a later time when all declarations for the module,\n // including forward refs, have resolved.\n enqueueModuleForDelayedScoping(moduleType, ngModule);\n}\n/**\n * Compiles and adds the `ɵmod`, `ɵfac` and `ɵinj` properties to the module class.\n *\n * It's possible to compile a module via this API which will allow duplicate declarations in its\n * root.\n */\nfunction compileNgModuleDefs(moduleType, ngModule, allowDuplicateDeclarationsInRoot = false) {\n ngDevMode && assertDefined(moduleType, 'Required value moduleType');\n ngDevMode && assertDefined(ngModule, 'Required value ngModule');\n const declarations = flatten(ngModule.declarations || EMPTY_ARRAY);\n let ngModuleDef = null;\n Object.defineProperty(moduleType, NG_MOD_DEF, {\n configurable: true,\n get: () => {\n if (ngModuleDef === null) {\n if (ngDevMode && ngModule.imports && ngModule.imports.indexOf(moduleType) > -1) {\n // We need to assert this immediately, because allowing it to continue will cause it to\n // go into an infinite loop before we've reached the point where we throw all the errors.\n throw new Error(`'${stringifyForError(moduleType)}' module can't import itself`);\n }\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'NgModule',\n type: moduleType\n });\n ngModuleDef = compiler.compileNgModule(angularCoreEnv, `ng:///${moduleType.name}/ɵmod.js`, {\n type: moduleType,\n bootstrap: flatten(ngModule.bootstrap || EMPTY_ARRAY).map(resolveForwardRef),\n declarations: declarations.map(resolveForwardRef),\n imports: flatten(ngModule.imports || EMPTY_ARRAY).map(resolveForwardRef).map(expandModuleWithProviders),\n exports: flatten(ngModule.exports || EMPTY_ARRAY).map(resolveForwardRef).map(expandModuleWithProviders),\n schemas: ngModule.schemas ? flatten(ngModule.schemas) : null,\n id: ngModule.id || null\n });\n // Set `schemas` on ngModuleDef to an empty array in JIT mode to indicate that runtime\n // should verify that there are no unknown elements in a template. In AOT mode, that check\n // happens at compile time and `schemas` information is not present on Component and Module\n // defs after compilation (so the check doesn't happen the second time at runtime).\n if (!ngModuleDef.schemas) {\n ngModuleDef.schemas = [];\n }\n }\n return ngModuleDef;\n }\n });\n let ngFactoryDef = null;\n Object.defineProperty(moduleType, NG_FACTORY_DEF, {\n get: () => {\n if (ngFactoryDef === null) {\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'NgModule',\n type: moduleType\n });\n ngFactoryDef = compiler.compileFactory(angularCoreEnv, `ng:///${moduleType.name}/ɵfac.js`, {\n name: moduleType.name,\n type: moduleType,\n deps: reflectDependencies(moduleType),\n target: compiler.FactoryTarget.NgModule,\n typeArgumentCount: 0\n });\n }\n return ngFactoryDef;\n },\n // Make the property configurable in dev mode to allow overriding in tests\n configurable: !!ngDevMode\n });\n let ngInjectorDef = null;\n Object.defineProperty(moduleType, NG_INJ_DEF, {\n get: () => {\n if (ngInjectorDef === null) {\n ngDevMode && verifySemanticsOfNgModuleDef(moduleType, allowDuplicateDeclarationsInRoot);\n const meta = {\n name: moduleType.name,\n type: moduleType,\n providers: ngModule.providers || EMPTY_ARRAY,\n imports: [(ngModule.imports || EMPTY_ARRAY).map(resolveForwardRef), (ngModule.exports || EMPTY_ARRAY).map(resolveForwardRef)]\n };\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'NgModule',\n type: moduleType\n });\n ngInjectorDef = compiler.compileInjector(angularCoreEnv, `ng:///${moduleType.name}/ɵinj.js`, meta);\n }\n return ngInjectorDef;\n },\n // Make the property configurable in dev mode to allow overriding in tests\n configurable: !!ngDevMode\n });\n}\nfunction generateStandaloneInDeclarationsError(type, location) {\n const prefix = `Unexpected \"${stringifyForError(type)}\" found in the \"declarations\" array of the`;\n const suffix = `\"${stringifyForError(type)}\" is marked as standalone and can't be declared ` + 'in any NgModule - did you intend to import it instead (by adding it to the \"imports\" array)?';\n return `${prefix} ${location}, ${suffix}`;\n}\nfunction verifySemanticsOfNgModuleDef(moduleType, allowDuplicateDeclarationsInRoot, importingModule) {\n if (verifiedNgModule.get(moduleType)) return;\n // skip verifications of standalone components, directives, and pipes\n if (isStandalone(moduleType)) return;\n verifiedNgModule.set(moduleType, true);\n moduleType = resolveForwardRef(moduleType);\n let ngModuleDef;\n if (importingModule) {\n ngModuleDef = getNgModuleDef(moduleType);\n if (!ngModuleDef) {\n throw new Error(`Unexpected value '${moduleType.name}' imported by the module '${importingModule.name}'. Please add an @NgModule annotation.`);\n }\n } else {\n ngModuleDef = getNgModuleDef(moduleType, true);\n }\n const errors = [];\n const declarations = maybeUnwrapFn(ngModuleDef.declarations);\n const imports = maybeUnwrapFn(ngModuleDef.imports);\n flatten(imports).map(unwrapModuleWithProvidersImports).forEach(modOrStandaloneCmpt => {\n verifySemanticsOfNgModuleImport(modOrStandaloneCmpt, moduleType);\n verifySemanticsOfNgModuleDef(modOrStandaloneCmpt, false, moduleType);\n });\n const exports = maybeUnwrapFn(ngModuleDef.exports);\n declarations.forEach(verifyDeclarationsHaveDefinitions);\n declarations.forEach(verifyDirectivesHaveSelector);\n declarations.forEach(declarationType => verifyNotStandalone(declarationType, moduleType));\n const combinedDeclarations = [...declarations.map(resolveForwardRef), ...flatten(imports.map(computeCombinedExports)).map(resolveForwardRef)];\n exports.forEach(verifyExportsAreDeclaredOrReExported);\n declarations.forEach(decl => verifyDeclarationIsUnique(decl, allowDuplicateDeclarationsInRoot));\n const ngModule = getAnnotation(moduleType, 'NgModule');\n if (ngModule) {\n ngModule.imports && flatten(ngModule.imports).map(unwrapModuleWithProvidersImports).forEach(mod => {\n verifySemanticsOfNgModuleImport(mod, moduleType);\n verifySemanticsOfNgModuleDef(mod, false, moduleType);\n });\n ngModule.bootstrap && deepForEach(ngModule.bootstrap, verifyCorrectBootstrapType);\n ngModule.bootstrap && deepForEach(ngModule.bootstrap, verifyComponentIsPartOfNgModule);\n }\n // Throw Error if any errors were detected.\n if (errors.length) {\n throw new Error(errors.join('\\n'));\n }\n ////////////////////////////////////////////////////////////////////////////////////////////////\n function verifyDeclarationsHaveDefinitions(type) {\n type = resolveForwardRef(type);\n const def = getComponentDef(type) || getDirectiveDef(type) || getPipeDef$1(type);\n if (!def) {\n errors.push(`Unexpected value '${stringifyForError(type)}' declared by the module '${stringifyForError(moduleType)}'. Please add a @Pipe/@Directive/@Component annotation.`);\n }\n }\n function verifyDirectivesHaveSelector(type) {\n type = resolveForwardRef(type);\n const def = getDirectiveDef(type);\n if (!getComponentDef(type) && def && def.selectors.length == 0) {\n errors.push(`Directive ${stringifyForError(type)} has no selector, please add it!`);\n }\n }\n function verifyNotStandalone(type, moduleType) {\n type = resolveForwardRef(type);\n const def = getComponentDef(type) || getDirectiveDef(type) || getPipeDef$1(type);\n if (def?.standalone) {\n const location = `\"${stringifyForError(moduleType)}\" NgModule`;\n errors.push(generateStandaloneInDeclarationsError(type, location));\n }\n }\n function verifyExportsAreDeclaredOrReExported(type) {\n type = resolveForwardRef(type);\n const kind = getComponentDef(type) && 'component' || getDirectiveDef(type) && 'directive' || getPipeDef$1(type) && 'pipe';\n if (kind) {\n // only checked if we are declared as Component, Directive, or Pipe\n // Modules don't need to be declared or imported.\n if (combinedDeclarations.lastIndexOf(type) === -1) {\n // We are exporting something which we don't explicitly declare or import.\n errors.push(`Can't export ${kind} ${stringifyForError(type)} from ${stringifyForError(moduleType)} as it was neither declared nor imported!`);\n }\n }\n }\n function verifyDeclarationIsUnique(type, suppressErrors) {\n type = resolveForwardRef(type);\n const existingModule = ownerNgModule.get(type);\n if (existingModule && existingModule !== moduleType) {\n if (!suppressErrors) {\n const modules = [existingModule, moduleType].map(stringifyForError).sort();\n errors.push(`Type ${stringifyForError(type)} is part of the declarations of 2 modules: ${modules[0]} and ${modules[1]}! ` + `Please consider moving ${stringifyForError(type)} to a higher module that imports ${modules[0]} and ${modules[1]}. ` + `You can also create a new NgModule that exports and includes ${stringifyForError(type)} then import that NgModule in ${modules[0]} and ${modules[1]}.`);\n }\n } else {\n // Mark type as having owner.\n ownerNgModule.set(type, moduleType);\n }\n }\n function verifyComponentIsPartOfNgModule(type) {\n type = resolveForwardRef(type);\n const existingModule = ownerNgModule.get(type);\n if (!existingModule && !isStandalone(type)) {\n errors.push(`Component ${stringifyForError(type)} is not part of any NgModule or the module has not been imported into your module.`);\n }\n }\n function verifyCorrectBootstrapType(type) {\n type = resolveForwardRef(type);\n if (!getComponentDef(type)) {\n errors.push(`${stringifyForError(type)} cannot be used as an entry component.`);\n }\n if (isStandalone(type)) {\n // Note: this error should be the same as the\n // `NGMODULE_BOOTSTRAP_IS_STANDALONE` one in AOT compiler.\n errors.push(`The \\`${stringifyForError(type)}\\` class is a standalone component, which can ` + `not be used in the \\`@NgModule.bootstrap\\` array. Use the \\`bootstrapApplication\\` ` + `function for bootstrap instead.`);\n }\n }\n function verifySemanticsOfNgModuleImport(type, importingModule) {\n type = resolveForwardRef(type);\n const directiveDef = getComponentDef(type) || getDirectiveDef(type);\n if (directiveDef !== null && !directiveDef.standalone) {\n throw new Error(`Unexpected directive '${type.name}' imported by the module '${importingModule.name}'. Please add an @NgModule annotation.`);\n }\n const pipeDef = getPipeDef$1(type);\n if (pipeDef !== null && !pipeDef.standalone) {\n throw new Error(`Unexpected pipe '${type.name}' imported by the module '${importingModule.name}'. Please add an @NgModule annotation.`);\n }\n }\n}\nfunction unwrapModuleWithProvidersImports(typeOrWithProviders) {\n typeOrWithProviders = resolveForwardRef(typeOrWithProviders);\n return typeOrWithProviders.ngModule || typeOrWithProviders;\n}\nfunction getAnnotation(type, name) {\n let annotation = null;\n collect(type.__annotations__);\n collect(type.decorators);\n return annotation;\n function collect(annotations) {\n if (annotations) {\n annotations.forEach(readAnnotation);\n }\n }\n function readAnnotation(decorator) {\n if (!annotation) {\n const proto = Object.getPrototypeOf(decorator);\n if (proto.ngMetadataName == name) {\n annotation = decorator;\n } else if (decorator.type) {\n const proto = Object.getPrototypeOf(decorator.type);\n if (proto.ngMetadataName == name) {\n annotation = decorator.args[0];\n }\n }\n }\n }\n}\n/**\n * Keep track of compiled components. This is needed because in tests we often want to compile the\n * same component with more than one NgModule. This would cause an error unless we reset which\n * NgModule the component belongs to. We keep the list of compiled components here so that the\n * TestBed can reset it later.\n */\nlet ownerNgModule = new WeakMap();\nlet verifiedNgModule = new WeakMap();\nfunction resetCompiledComponents() {\n ownerNgModule = new WeakMap();\n verifiedNgModule = new WeakMap();\n moduleQueue.length = 0;\n GENERATED_COMP_IDS.clear();\n}\n/**\n * Computes the combined declarations of explicit declarations, as well as declarations inherited by\n * traversing the exports of imported modules.\n * @param type\n */\nfunction computeCombinedExports(type) {\n type = resolveForwardRef(type);\n const ngModuleDef = getNgModuleDef(type);\n // a standalone component, directive or pipe\n if (ngModuleDef === null) {\n return [type];\n }\n return flatten(maybeUnwrapFn(ngModuleDef.exports).map(type => {\n const ngModuleDef = getNgModuleDef(type);\n if (ngModuleDef) {\n verifySemanticsOfNgModuleDef(type, false);\n return computeCombinedExports(type);\n } else {\n return type;\n }\n }));\n}\n/**\n * Some declared components may be compiled asynchronously, and thus may not have their\n * ɵcmp set yet. If this is the case, then a reference to the module is written into\n * the `ngSelectorScope` property of the declared type.\n */\nfunction setScopeOnDeclaredComponents(moduleType, ngModule) {\n const declarations = flatten(ngModule.declarations || EMPTY_ARRAY);\n const transitiveScopes = transitiveScopesFor(moduleType);\n declarations.forEach(declaration => {\n declaration = resolveForwardRef(declaration);\n if (declaration.hasOwnProperty(NG_COMP_DEF)) {\n // A `ɵcmp` field exists - go ahead and patch the component directly.\n const component = declaration;\n const componentDef = getComponentDef(component);\n patchComponentDefWithScope(componentDef, transitiveScopes);\n } else if (!declaration.hasOwnProperty(NG_DIR_DEF) && !declaration.hasOwnProperty(NG_PIPE_DEF)) {\n // Set `ngSelectorScope` for future reference when the component compilation finishes.\n declaration.ngSelectorScope = moduleType;\n }\n });\n}\n/**\n * Patch the definition of a component with directives and pipes from the compilation scope of\n * a given module.\n */\nfunction patchComponentDefWithScope(componentDef, transitiveScopes) {\n componentDef.directiveDefs = () => Array.from(transitiveScopes.compilation.directives).map(dir => dir.hasOwnProperty(NG_COMP_DEF) ? getComponentDef(dir) : getDirectiveDef(dir)).filter(def => !!def);\n componentDef.pipeDefs = () => Array.from(transitiveScopes.compilation.pipes).map(pipe => getPipeDef$1(pipe));\n componentDef.schemas = transitiveScopes.schemas;\n // Since we avoid Components/Directives/Pipes recompiling in case there are no overrides, we\n // may face a problem where previously compiled defs available to a given Component/Directive\n // are cached in TView and may become stale (in case any of these defs gets recompiled). In\n // order to avoid this problem, we force fresh TView to be created.\n componentDef.tView = null;\n}\n/**\n * Compute the pair of transitive scopes (compilation scope and exported scope) for a given type\n * (either a NgModule or a standalone component / directive / pipe).\n */\nfunction transitiveScopesFor(type) {\n if (isNgModule(type)) {\n if (USE_RUNTIME_DEPS_TRACKER_FOR_JIT) {\n const scope = depsTracker.getNgModuleScope(type);\n const def = getNgModuleDef(type, true);\n return {\n schemas: def.schemas || null,\n ...scope\n };\n } else {\n return transitiveScopesForNgModule(type);\n }\n } else if (isStandalone(type)) {\n const directiveDef = getComponentDef(type) || getDirectiveDef(type);\n if (directiveDef !== null) {\n return {\n schemas: null,\n compilation: {\n directives: new Set(),\n pipes: new Set()\n },\n exported: {\n directives: new Set([type]),\n pipes: new Set()\n }\n };\n }\n const pipeDef = getPipeDef$1(type);\n if (pipeDef !== null) {\n return {\n schemas: null,\n compilation: {\n directives: new Set(),\n pipes: new Set()\n },\n exported: {\n directives: new Set(),\n pipes: new Set([type])\n }\n };\n }\n }\n // TODO: change the error message to be more user-facing and take standalone into account\n throw new Error(`${type.name} does not have a module def (ɵmod property)`);\n}\n/**\n * Compute the pair of transitive scopes (compilation scope and exported scope) for a given module.\n *\n * This operation is memoized and the result is cached on the module's definition. This function can\n * be called on modules with components that have not fully compiled yet, but the result should not\n * be used until they have.\n *\n * @param moduleType module that transitive scope should be calculated for.\n */\nfunction transitiveScopesForNgModule(moduleType) {\n const def = getNgModuleDef(moduleType, true);\n if (def.transitiveCompileScopes !== null) {\n return def.transitiveCompileScopes;\n }\n const scopes = {\n schemas: def.schemas || null,\n compilation: {\n directives: new Set(),\n pipes: new Set()\n },\n exported: {\n directives: new Set(),\n pipes: new Set()\n }\n };\n maybeUnwrapFn(def.imports).forEach(imported => {\n // When this module imports another, the imported module's exported directives and pipes are\n // added to the compilation scope of this module.\n const importedScope = transitiveScopesFor(imported);\n importedScope.exported.directives.forEach(entry => scopes.compilation.directives.add(entry));\n importedScope.exported.pipes.forEach(entry => scopes.compilation.pipes.add(entry));\n });\n maybeUnwrapFn(def.declarations).forEach(declared => {\n const declaredWithDefs = declared;\n if (getPipeDef$1(declaredWithDefs)) {\n scopes.compilation.pipes.add(declared);\n } else {\n // Either declared has a ɵcmp or ɵdir, or it's a component which hasn't\n // had its template compiled yet. In either case, it gets added to the compilation's\n // directives.\n scopes.compilation.directives.add(declared);\n }\n });\n maybeUnwrapFn(def.exports).forEach(exported => {\n const exportedType = exported;\n // Either the type is a module, a pipe, or a component/directive (which may not have a\n // ɵcmp as it might be compiled asynchronously).\n if (isNgModule(exportedType)) {\n // When this module exports another, the exported module's exported directives and pipes are\n // added to both the compilation and exported scopes of this module.\n const exportedScope = transitiveScopesFor(exportedType);\n exportedScope.exported.directives.forEach(entry => {\n scopes.compilation.directives.add(entry);\n scopes.exported.directives.add(entry);\n });\n exportedScope.exported.pipes.forEach(entry => {\n scopes.compilation.pipes.add(entry);\n scopes.exported.pipes.add(entry);\n });\n } else if (getPipeDef$1(exportedType)) {\n scopes.exported.pipes.add(exportedType);\n } else {\n scopes.exported.directives.add(exportedType);\n }\n });\n def.transitiveCompileScopes = scopes;\n return scopes;\n}\nfunction expandModuleWithProviders(value) {\n if (isModuleWithProviders(value)) {\n return value.ngModule;\n }\n return value;\n}\n\n/**\n * Keep track of the compilation depth to avoid reentrancy issues during JIT compilation. This\n * matters in the following scenario:\n *\n * Consider a component 'A' that extends component 'B', both declared in module 'M'. During\n * the compilation of 'A' the definition of 'B' is requested to capture the inheritance chain,\n * potentially triggering compilation of 'B'. If this nested compilation were to trigger\n * `flushModuleScopingQueueAsMuchAsPossible` it may happen that module 'M' is still pending in the\n * queue, resulting in 'A' and 'B' to be patched with the NgModule scope. As the compilation of\n * 'A' is still in progress, this would introduce a circular dependency on its compilation. To avoid\n * this issue, the module scope queue is only flushed for compilations at the depth 0, to ensure\n * all compilations have finished.\n */\nlet compilationDepth = 0;\n/**\n * Compile an Angular component according to its decorator metadata, and patch the resulting\n * component def (ɵcmp) onto the component type.\n *\n * Compilation may be asynchronous (due to the need to resolve URLs for the component template or\n * other resources, for example). In the event that compilation is not immediate, `compileComponent`\n * will enqueue resource resolution into a global queue and will fail to return the `ɵcmp`\n * until the global queue has been resolved with a call to `resolveComponentResources`.\n */\nfunction compileComponent(type, metadata) {\n // Initialize ngDevMode. This must be the first statement in compileComponent.\n // See the `initNgDevMode` docstring for more information.\n (typeof ngDevMode === 'undefined' || ngDevMode) && initNgDevMode();\n let ngComponentDef = null;\n // Metadata may have resources which need to be resolved.\n maybeQueueResolutionOfComponentResources(type, metadata);\n // Note that we're using the same function as `Directive`, because that's only subset of metadata\n // that we need to create the ngFactoryDef. We're avoiding using the component metadata\n // because we'd have to resolve the asynchronous templates.\n addDirectiveFactoryDef(type, metadata);\n Object.defineProperty(type, NG_COMP_DEF, {\n get: () => {\n if (ngComponentDef === null) {\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'component',\n type: type\n });\n if (componentNeedsResolution(metadata)) {\n const error = [`Component '${type.name}' is not resolved:`];\n if (metadata.templateUrl) {\n error.push(` - templateUrl: ${metadata.templateUrl}`);\n }\n if (metadata.styleUrls && metadata.styleUrls.length) {\n error.push(` - styleUrls: ${JSON.stringify(metadata.styleUrls)}`);\n }\n if (metadata.styleUrl) {\n error.push(` - styleUrl: ${metadata.styleUrl}`);\n }\n error.push(`Did you run and wait for 'resolveComponentResources()'?`);\n throw new Error(error.join('\\n'));\n }\n // This const was called `jitOptions` previously but had to be renamed to `options` because\n // of a bug with Terser that caused optimized JIT builds to throw a `ReferenceError`.\n // This bug was investigated in https://github.com/angular/angular-cli/issues/17264.\n // We should not rename it back until https://github.com/terser/terser/issues/615 is fixed.\n const options = getJitOptions();\n let preserveWhitespaces = metadata.preserveWhitespaces;\n if (preserveWhitespaces === undefined) {\n if (options !== null && options.preserveWhitespaces !== undefined) {\n preserveWhitespaces = options.preserveWhitespaces;\n } else {\n preserveWhitespaces = false;\n }\n }\n let encapsulation = metadata.encapsulation;\n if (encapsulation === undefined) {\n if (options !== null && options.defaultEncapsulation !== undefined) {\n encapsulation = options.defaultEncapsulation;\n } else {\n encapsulation = ViewEncapsulation.Emulated;\n }\n }\n const templateUrl = metadata.templateUrl || `ng:///${type.name}/template.html`;\n const meta = {\n ...directiveMetadata(type, metadata),\n typeSourceSpan: compiler.createParseSourceSpan('Component', type.name, templateUrl),\n template: metadata.template || '',\n preserveWhitespaces,\n styles: typeof metadata.styles === 'string' ? [metadata.styles] : metadata.styles || EMPTY_ARRAY,\n animations: metadata.animations,\n // JIT components are always compiled against an empty set of `declarations`. Instead, the\n // `directiveDefs` and `pipeDefs` are updated at a later point:\n // * for NgModule-based components, they're set when the NgModule which declares the\n // component resolves in the module scoping queue\n // * for standalone components, they're set just below, after `compileComponent`.\n declarations: [],\n changeDetection: metadata.changeDetection,\n encapsulation,\n interpolation: metadata.interpolation,\n viewProviders: metadata.viewProviders || null\n };\n compilationDepth++;\n try {\n if (meta.usesInheritance) {\n addDirectiveDefToUndecoratedParents(type);\n }\n ngComponentDef = compiler.compileComponent(angularCoreEnv, templateUrl, meta);\n if (meta.isStandalone) {\n // Patch the component definition for standalone components with `directiveDefs` and\n // `pipeDefs` functions which lazily compute the directives/pipes available in the\n // standalone component. Also set `dependencies` to the lazily resolved list of imports.\n const imports = flatten(metadata.imports || EMPTY_ARRAY);\n const {\n directiveDefs,\n pipeDefs\n } = getStandaloneDefFunctions(type, imports);\n ngComponentDef.directiveDefs = directiveDefs;\n ngComponentDef.pipeDefs = pipeDefs;\n ngComponentDef.dependencies = () => imports.map(resolveForwardRef);\n }\n } finally {\n // Ensure that the compilation depth is decremented even when the compilation failed.\n compilationDepth--;\n }\n if (compilationDepth === 0) {\n // When NgModule decorator executed, we enqueued the module definition such that\n // it would only dequeue and add itself as module scope to all of its declarations,\n // but only if if all of its declarations had resolved. This call runs the check\n // to see if any modules that are in the queue can be dequeued and add scope to\n // their declarations.\n flushModuleScopingQueueAsMuchAsPossible();\n }\n // If component compilation is async, then the @NgModule annotation which declares the\n // component may execute and set an ngSelectorScope property on the component type. This\n // allows the component to patch itself with directiveDefs from the module after it\n // finishes compiling.\n if (hasSelectorScope(type)) {\n const scopes = transitiveScopesFor(type.ngSelectorScope);\n patchComponentDefWithScope(ngComponentDef, scopes);\n }\n if (metadata.schemas) {\n if (meta.isStandalone) {\n ngComponentDef.schemas = metadata.schemas;\n } else {\n throw new Error(`The 'schemas' was specified for the ${stringifyForError(type)} but is only valid on a component that is standalone.`);\n }\n } else if (meta.isStandalone) {\n ngComponentDef.schemas = [];\n }\n }\n return ngComponentDef;\n },\n set: def => {\n ngComponentDef = def;\n },\n // Make the property configurable in dev mode to allow overriding in tests\n configurable: !!ngDevMode\n });\n}\n/**\n * Build memoized `directiveDefs` and `pipeDefs` functions for the component definition of a\n * standalone component, which process `imports` and filter out directives and pipes. The use of\n * memoized functions here allows for the delayed resolution of any `forwardRef`s present in the\n * component's `imports`.\n */\nfunction getStandaloneDefFunctions(type, imports) {\n let cachedDirectiveDefs = null;\n let cachedPipeDefs = null;\n const directiveDefs = () => {\n if (!USE_RUNTIME_DEPS_TRACKER_FOR_JIT) {\n if (cachedDirectiveDefs === null) {\n // Standalone components are always able to self-reference, so include the component's own\n // definition in its `directiveDefs`.\n cachedDirectiveDefs = [getComponentDef(type)];\n const seen = new Set([type]);\n for (const rawDep of imports) {\n ngDevMode && verifyStandaloneImport(rawDep, type);\n const dep = resolveForwardRef(rawDep);\n if (seen.has(dep)) {\n continue;\n }\n seen.add(dep);\n if (!!getNgModuleDef(dep)) {\n const scope = transitiveScopesFor(dep);\n for (const dir of scope.exported.directives) {\n const def = getComponentDef(dir) || getDirectiveDef(dir);\n if (def && !seen.has(dir)) {\n seen.add(dir);\n cachedDirectiveDefs.push(def);\n }\n }\n } else {\n const def = getComponentDef(dep) || getDirectiveDef(dep);\n if (def) {\n cachedDirectiveDefs.push(def);\n }\n }\n }\n }\n return cachedDirectiveDefs;\n } else {\n if (ngDevMode) {\n for (const rawDep of imports) {\n verifyStandaloneImport(rawDep, type);\n }\n }\n if (!isComponent(type)) {\n return [];\n }\n const scope = depsTracker.getStandaloneComponentScope(type, imports);\n return [...scope.compilation.directives].map(p => getComponentDef(p) || getDirectiveDef(p)).filter(d => d !== null);\n }\n };\n const pipeDefs = () => {\n if (!USE_RUNTIME_DEPS_TRACKER_FOR_JIT) {\n if (cachedPipeDefs === null) {\n cachedPipeDefs = [];\n const seen = new Set();\n for (const rawDep of imports) {\n const dep = resolveForwardRef(rawDep);\n if (seen.has(dep)) {\n continue;\n }\n seen.add(dep);\n if (!!getNgModuleDef(dep)) {\n const scope = transitiveScopesFor(dep);\n for (const pipe of scope.exported.pipes) {\n const def = getPipeDef$1(pipe);\n if (def && !seen.has(pipe)) {\n seen.add(pipe);\n cachedPipeDefs.push(def);\n }\n }\n } else {\n const def = getPipeDef$1(dep);\n if (def) {\n cachedPipeDefs.push(def);\n }\n }\n }\n }\n return cachedPipeDefs;\n } else {\n if (ngDevMode) {\n for (const rawDep of imports) {\n verifyStandaloneImport(rawDep, type);\n }\n }\n if (!isComponent(type)) {\n return [];\n }\n const scope = depsTracker.getStandaloneComponentScope(type, imports);\n return [...scope.compilation.pipes].map(p => getPipeDef$1(p)).filter(d => d !== null);\n }\n };\n return {\n directiveDefs,\n pipeDefs\n };\n}\nfunction hasSelectorScope(component) {\n return component.ngSelectorScope !== undefined;\n}\n/**\n * Compile an Angular directive according to its decorator metadata, and patch the resulting\n * directive def onto the component type.\n *\n * In the event that compilation is not immediate, `compileDirective` will return a `Promise` which\n * will resolve when compilation completes and the directive becomes usable.\n */\nfunction compileDirective(type, directive) {\n let ngDirectiveDef = null;\n addDirectiveFactoryDef(type, directive || {});\n Object.defineProperty(type, NG_DIR_DEF, {\n get: () => {\n if (ngDirectiveDef === null) {\n // `directive` can be null in the case of abstract directives as a base class\n // that use `@Directive()` with no selector. In that case, pass empty object to the\n // `directiveMetadata` function instead of null.\n const meta = getDirectiveMetadata(type, directive || {});\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'directive',\n type\n });\n ngDirectiveDef = compiler.compileDirective(angularCoreEnv, meta.sourceMapUrl, meta.metadata);\n }\n return ngDirectiveDef;\n },\n // Make the property configurable in dev mode to allow overriding in tests\n configurable: !!ngDevMode\n });\n}\nfunction getDirectiveMetadata(type, metadata) {\n const name = type && type.name;\n const sourceMapUrl = `ng:///${name}/ɵdir.js`;\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'directive',\n type\n });\n const facade = directiveMetadata(type, metadata);\n facade.typeSourceSpan = compiler.createParseSourceSpan('Directive', name, sourceMapUrl);\n if (facade.usesInheritance) {\n addDirectiveDefToUndecoratedParents(type);\n }\n return {\n metadata: facade,\n sourceMapUrl\n };\n}\nfunction addDirectiveFactoryDef(type, metadata) {\n let ngFactoryDef = null;\n Object.defineProperty(type, NG_FACTORY_DEF, {\n get: () => {\n if (ngFactoryDef === null) {\n const meta = getDirectiveMetadata(type, metadata);\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'directive',\n type\n });\n ngFactoryDef = compiler.compileFactory(angularCoreEnv, `ng:///${type.name}/ɵfac.js`, {\n name: meta.metadata.name,\n type: meta.metadata.type,\n typeArgumentCount: 0,\n deps: reflectDependencies(type),\n target: compiler.FactoryTarget.Directive\n });\n }\n return ngFactoryDef;\n },\n // Make the property configurable in dev mode to allow overriding in tests\n configurable: !!ngDevMode\n });\n}\nfunction extendsDirectlyFromObject(type) {\n return Object.getPrototypeOf(type.prototype) === Object.prototype;\n}\n/**\n * Extract the `R3DirectiveMetadata` for a particular directive (either a `Directive` or a\n * `Component`).\n */\nfunction directiveMetadata(type, metadata) {\n // Reflect inputs and outputs.\n const reflect = getReflect();\n const propMetadata = reflect.ownPropMetadata(type);\n return {\n name: type.name,\n type: type,\n selector: metadata.selector !== undefined ? metadata.selector : null,\n host: metadata.host || EMPTY_OBJ,\n propMetadata: propMetadata,\n inputs: metadata.inputs || EMPTY_ARRAY,\n outputs: metadata.outputs || EMPTY_ARRAY,\n queries: extractQueriesMetadata(type, propMetadata, isContentQuery),\n lifecycle: {\n usesOnChanges: reflect.hasLifecycleHook(type, 'ngOnChanges')\n },\n typeSourceSpan: null,\n usesInheritance: !extendsDirectlyFromObject(type),\n exportAs: extractExportAs(metadata.exportAs),\n providers: metadata.providers || null,\n viewQueries: extractQueriesMetadata(type, propMetadata, isViewQuery),\n isStandalone: metadata.standalone === undefined ? true : !!metadata.standalone,\n isSignal: !!metadata.signals,\n hostDirectives: metadata.hostDirectives?.map(directive => typeof directive === 'function' ? {\n directive\n } : directive) || null\n };\n}\n/**\n * Adds a directive definition to all parent classes of a type that don't have an Angular decorator.\n */\nfunction addDirectiveDefToUndecoratedParents(type) {\n const objPrototype = Object.prototype;\n let parent = Object.getPrototypeOf(type.prototype).constructor;\n // Go up the prototype until we hit `Object`.\n while (parent && parent !== objPrototype) {\n // Since inheritance works if the class was annotated already, we only need to add\n // the def if there are no annotations and the def hasn't been created already.\n if (!getDirectiveDef(parent) && !getComponentDef(parent) && shouldAddAbstractDirective(parent)) {\n compileDirective(parent, null);\n }\n parent = Object.getPrototypeOf(parent);\n }\n}\nfunction convertToR3QueryPredicate(selector) {\n return typeof selector === 'string' ? splitByComma(selector) : resolveForwardRef(selector);\n}\nfunction convertToR3QueryMetadata(propertyName, ann) {\n return {\n propertyName: propertyName,\n predicate: convertToR3QueryPredicate(ann.selector),\n descendants: ann.descendants,\n first: ann.first,\n read: ann.read ? ann.read : null,\n static: !!ann.static,\n emitDistinctChangesOnly: !!ann.emitDistinctChangesOnly,\n isSignal: !!ann.isSignal\n };\n}\nfunction extractQueriesMetadata(type, propMetadata, isQueryAnn) {\n const queriesMeta = [];\n for (const field in propMetadata) {\n if (propMetadata.hasOwnProperty(field)) {\n const annotations = propMetadata[field];\n annotations.forEach(ann => {\n if (isQueryAnn(ann)) {\n if (!ann.selector) {\n throw new Error(`Can't construct a query for the property \"${field}\" of ` + `\"${stringifyForError(type)}\" since the query selector wasn't defined.`);\n }\n if (annotations.some(isInputAnnotation)) {\n throw new Error(`Cannot combine @Input decorators with query decorators`);\n }\n queriesMeta.push(convertToR3QueryMetadata(field, ann));\n }\n });\n }\n }\n return queriesMeta;\n}\nfunction extractExportAs(exportAs) {\n return exportAs === undefined ? null : splitByComma(exportAs);\n}\nfunction isContentQuery(value) {\n const name = value.ngMetadataName;\n return name === 'ContentChild' || name === 'ContentChildren';\n}\nfunction isViewQuery(value) {\n const name = value.ngMetadataName;\n return name === 'ViewChild' || name === 'ViewChildren';\n}\nfunction isInputAnnotation(value) {\n return value.ngMetadataName === 'Input';\n}\nfunction splitByComma(value) {\n return value.split(',').map(piece => piece.trim());\n}\nconst LIFECYCLE_HOOKS = ['ngOnChanges', 'ngOnInit', 'ngOnDestroy', 'ngDoCheck', 'ngAfterViewInit', 'ngAfterViewChecked', 'ngAfterContentInit', 'ngAfterContentChecked'];\nfunction shouldAddAbstractDirective(type) {\n const reflect = getReflect();\n if (LIFECYCLE_HOOKS.some(hookName => reflect.hasLifecycleHook(type, hookName))) {\n return true;\n }\n const propMetadata = reflect.propMetadata(type);\n for (const field in propMetadata) {\n const annotations = propMetadata[field];\n for (let i = 0; i < annotations.length; i++) {\n const current = annotations[i];\n const metadataName = current.ngMetadataName;\n if (isInputAnnotation(current) || isContentQuery(current) || isViewQuery(current) || metadataName === 'Output' || metadataName === 'HostBinding' || metadataName === 'HostListener') {\n return true;\n }\n }\n }\n return false;\n}\nfunction compilePipe(type, meta) {\n let ngPipeDef = null;\n let ngFactoryDef = null;\n Object.defineProperty(type, NG_FACTORY_DEF, {\n get: () => {\n if (ngFactoryDef === null) {\n const metadata = getPipeMetadata(type, meta);\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'pipe',\n type: metadata.type\n });\n ngFactoryDef = compiler.compileFactory(angularCoreEnv, `ng:///${metadata.name}/ɵfac.js`, {\n name: metadata.name,\n type: metadata.type,\n typeArgumentCount: 0,\n deps: reflectDependencies(type),\n target: compiler.FactoryTarget.Pipe\n });\n }\n return ngFactoryDef;\n },\n // Make the property configurable in dev mode to allow overriding in tests\n configurable: !!ngDevMode\n });\n Object.defineProperty(type, NG_PIPE_DEF, {\n get: () => {\n if (ngPipeDef === null) {\n const metadata = getPipeMetadata(type, meta);\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'pipe',\n type: metadata.type\n });\n ngPipeDef = compiler.compilePipe(angularCoreEnv, `ng:///${metadata.name}/ɵpipe.js`, metadata);\n }\n return ngPipeDef;\n },\n // Make the property configurable in dev mode to allow overriding in tests\n configurable: !!ngDevMode\n });\n}\nfunction getPipeMetadata(type, meta) {\n return {\n type: type,\n name: type.name,\n pipeName: meta.name,\n pure: meta.pure !== undefined ? meta.pure : true,\n isStandalone: meta.standalone === undefined ? true : !!meta.standalone\n };\n}\n\n/**\n * Type of the Directive metadata.\n *\n * @publicApi\n */\nconst Directive = makeDecorator('Directive', (dir = {}) => dir, undefined, undefined, (type, meta) => compileDirective(type, meta));\n/**\n * Component decorator and metadata.\n *\n * @Annotation\n * @publicApi\n */\nconst Component = makeDecorator('Component', (c = {}) => ({\n changeDetection: ChangeDetectionStrategy.Default,\n ...c\n}), Directive, undefined, (type, meta) => compileComponent(type, meta));\n/**\n * @Annotation\n * @publicApi\n */\nconst Pipe = makeDecorator('Pipe', p => ({\n pure: true,\n ...p\n}), undefined, undefined, (type, meta) => compilePipe(type, meta));\n/**\n * @Annotation\n * @publicApi\n */\nconst Input = makePropDecorator('Input', arg => {\n if (!arg) {\n return {};\n }\n return typeof arg === 'string' ? {\n alias: arg\n } : arg;\n});\n/**\n * @Annotation\n * @publicApi\n */\nconst Output = makePropDecorator('Output', alias => ({\n alias\n}));\n/**\n * @Annotation\n * @publicApi\n */\nconst HostBinding = makePropDecorator('HostBinding', hostPropertyName => ({\n hostPropertyName\n}));\n/**\n * @Annotation\n * @publicApi\n */\nconst HostListener = makePropDecorator('HostListener', (eventName, args) => ({\n eventName,\n args\n}));\n\n/**\n * @Annotation\n */\nconst NgModule = makeDecorator('NgModule', ngModule => ngModule, undefined, undefined,\n/**\n * Decorator that marks the following class as an NgModule, and supplies\n * configuration metadata for it.\n *\n * * The `declarations` option configures the compiler\n * with information about what belongs to the NgModule.\n * * The `providers` options configures the NgModule's injector to provide\n * dependencies the NgModule members.\n * * The `imports` and `exports` options bring in members from other modules, and make\n * this module's members available to others.\n */\n(type, meta) => compileNgModule(type, meta));\n\n/**\n * This indirection is needed to free up Component, etc symbols in the public API\n * to be used by the decorator versions of these annotations.\n */\n\n/**\n * @description Represents the version of Angular\n *\n * @publicApi\n */\nclass Version {\n full;\n major;\n minor;\n patch;\n constructor(full) {\n this.full = full;\n const parts = full.split('.');\n this.major = parts[0];\n this.minor = parts[1];\n this.patch = parts.slice(2).join('.');\n }\n}\n/**\n * @publicApi\n */\nconst VERSION = new Version('19.2.1');\n\n/**\n * Combination of NgModuleFactory and ComponentFactories.\n *\n * @publicApi\n *\n * @deprecated\n * Ivy JIT mode doesn't require accessing this symbol.\n */\nclass ModuleWithComponentFactories {\n ngModuleFactory;\n componentFactories;\n constructor(ngModuleFactory, componentFactories) {\n this.ngModuleFactory = ngModuleFactory;\n this.componentFactories = componentFactories;\n }\n}\n/**\n * Low-level service for running the angular compiler during runtime\n * to create {@link ComponentFactory}s, which\n * can later be used to create and render a Component instance.\n *\n * Each `@NgModule` provides an own `Compiler` to its injector,\n * that will use the directives/pipes of the ng module for compilation\n * of components.\n *\n * @publicApi\n *\n * @deprecated\n * Ivy JIT mode doesn't require accessing this symbol.\n */\nclass Compiler {\n /**\n * Compiles the given NgModule and all of its components. All templates of the components\n * have to be inlined.\n */\n compileModuleSync(moduleType) {\n return new NgModuleFactory(moduleType);\n }\n /**\n * Compiles the given NgModule and all of its components\n */\n compileModuleAsync(moduleType) {\n return Promise.resolve(this.compileModuleSync(moduleType));\n }\n /**\n * Same as {@link Compiler#compileModuleSync compileModuleSync} but also creates ComponentFactories for all components.\n */\n compileModuleAndAllComponentsSync(moduleType) {\n const ngModuleFactory = this.compileModuleSync(moduleType);\n const moduleDef = getNgModuleDef(moduleType);\n const componentFactories = maybeUnwrapFn(moduleDef.declarations).reduce((factories, declaration) => {\n const componentDef = getComponentDef(declaration);\n componentDef && factories.push(new ComponentFactory(componentDef));\n return factories;\n }, []);\n return new ModuleWithComponentFactories(ngModuleFactory, componentFactories);\n }\n /**\n * Same as {@link Compiler#compileModuleAsync compileModuleAsync} but also creates ComponentFactories for all components.\n */\n compileModuleAndAllComponentsAsync(moduleType) {\n return Promise.resolve(this.compileModuleAndAllComponentsSync(moduleType));\n }\n /**\n * Clears all caches.\n */\n clearCache() {}\n /**\n * Clears the cache for the given component/ngModule.\n */\n clearCacheFor(type) {}\n /**\n * Returns the id for a given NgModule, if one is defined and known to the compiler.\n */\n getModuleId(moduleType) {\n return undefined;\n }\n static ɵfac = function Compiler_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || Compiler)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: Compiler,\n factory: Compiler.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(Compiler, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n/**\n * Token to provide CompilerOptions in the platform injector.\n *\n * @publicApi\n */\nconst COMPILER_OPTIONS = new InjectionToken(ngDevMode ? 'compilerOptions' : '');\n/**\n * A factory for creating a Compiler\n *\n * @publicApi\n *\n * @deprecated\n * Ivy JIT mode doesn't require accessing this symbol.\n */\nclass CompilerFactory {}\nfunction compileNgModuleFactory(injector, options, moduleType) {\n ngDevMode && assertNgModuleType(moduleType);\n const moduleFactory = new NgModuleFactory(moduleType);\n // All of the logic below is irrelevant for AOT-compiled code.\n if (typeof ngJitMode !== 'undefined' && !ngJitMode) {\n return Promise.resolve(moduleFactory);\n }\n const compilerOptions = injector.get(COMPILER_OPTIONS, []).concat(options);\n // Configure the compiler to use the provided options. This call may fail when multiple modules\n // are bootstrapped with incompatible options, as a component can only be compiled according to\n // a single set of options.\n setJitOptions({\n defaultEncapsulation: _lastDefined(compilerOptions.map(opts => opts.defaultEncapsulation)),\n preserveWhitespaces: _lastDefined(compilerOptions.map(opts => opts.preserveWhitespaces))\n });\n if (isComponentResourceResolutionQueueEmpty()) {\n return Promise.resolve(moduleFactory);\n }\n const compilerProviders = compilerOptions.flatMap(option => option.providers ?? []);\n // In case there are no compiler providers, we just return the module factory as\n // there won't be any resource loader. This can happen with Ivy, because AOT compiled\n // modules can be still passed through \"bootstrapModule\". In that case we shouldn't\n // unnecessarily require the JIT compiler.\n if (compilerProviders.length === 0) {\n return Promise.resolve(moduleFactory);\n }\n const compiler = getCompilerFacade({\n usage: 0 /* JitCompilerUsage.Decorator */,\n kind: 'NgModule',\n type: moduleType\n });\n const compilerInjector = Injector.create({\n providers: compilerProviders\n });\n const resourceLoader = compilerInjector.get(compiler.ResourceLoader);\n // The resource loader can also return a string while the \"resolveComponentResources\"\n // always expects a promise. Therefore we need to wrap the returned value in a promise.\n return resolveComponentResources(url => Promise.resolve(resourceLoader.get(url))).then(() => moduleFactory);\n}\nfunction _lastDefined(args) {\n for (let i = args.length - 1; i >= 0; i--) {\n if (args[i] !== undefined) {\n return args[i];\n }\n }\n return undefined;\n}\nclass NgZoneChangeDetectionScheduler {\n zone = inject(NgZone);\n changeDetectionScheduler = inject(ChangeDetectionScheduler);\n applicationRef = inject(ApplicationRef);\n _onMicrotaskEmptySubscription;\n initialize() {\n if (this._onMicrotaskEmptySubscription) {\n return;\n }\n this._onMicrotaskEmptySubscription = this.zone.onMicrotaskEmpty.subscribe({\n next: () => {\n // `onMicroTaskEmpty` can happen _during_ the zoneless scheduler change detection because\n // zone.run(() => {}) will result in `checkStable` at the end of the `zone.run` closure\n // and emit `onMicrotaskEmpty` synchronously if run coalsecing is false.\n if (this.changeDetectionScheduler.runningTick) {\n return;\n }\n this.zone.run(() => {\n this.applicationRef.tick();\n });\n }\n });\n }\n ngOnDestroy() {\n this._onMicrotaskEmptySubscription?.unsubscribe();\n }\n static ɵfac = function NgZoneChangeDetectionScheduler_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgZoneChangeDetectionScheduler)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: NgZoneChangeDetectionScheduler,\n factory: NgZoneChangeDetectionScheduler.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(NgZoneChangeDetectionScheduler, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n/**\n * Internal token used to verify that `provideZoneChangeDetection` is not used\n * with the bootstrapModule API.\n */\nconst PROVIDED_NG_ZONE = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'provideZoneChangeDetection token' : '', {\n factory: () => false\n});\nfunction internalProvideZoneChangeDetection({\n ngZoneFactory,\n ignoreChangesOutsideZone,\n scheduleInRootZone\n}) {\n ngZoneFactory ??= () => new NgZone({\n ...getNgZoneOptions(),\n scheduleInRootZone\n });\n return [{\n provide: NgZone,\n useFactory: ngZoneFactory\n }, {\n provide: ENVIRONMENT_INITIALIZER,\n multi: true,\n useFactory: () => {\n const ngZoneChangeDetectionScheduler = inject(NgZoneChangeDetectionScheduler, {\n optional: true\n });\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && ngZoneChangeDetectionScheduler === null) {\n throw new RuntimeError(402 /* RuntimeErrorCode.MISSING_REQUIRED_INJECTABLE_IN_BOOTSTRAP */, `A required Injectable was not found in the dependency injection tree. ` + 'If you are bootstrapping an NgModule, make sure that the `BrowserModule` is imported.');\n }\n return () => ngZoneChangeDetectionScheduler.initialize();\n }\n }, {\n provide: ENVIRONMENT_INITIALIZER,\n multi: true,\n useFactory: () => {\n const service = inject(ZoneStablePendingTask);\n return () => {\n service.initialize();\n };\n }\n },\n // Always disable scheduler whenever explicitly disabled, even if another place called\n // `provideZoneChangeDetection` without the 'ignore' option.\n ignoreChangesOutsideZone === true ? {\n provide: ZONELESS_SCHEDULER_DISABLED,\n useValue: true\n } : [], {\n provide: SCHEDULE_IN_ROOT_ZONE,\n useValue: scheduleInRootZone ?? SCHEDULE_IN_ROOT_ZONE_DEFAULT\n }];\n}\n/**\n * Provides `NgZone`-based change detection for the application bootstrapped using\n * `bootstrapApplication`.\n *\n * `NgZone` is already provided in applications by default. This provider allows you to configure\n * options like `eventCoalescing` in the `NgZone`.\n * This provider is not available for `platformBrowser().bootstrapModule`, which uses\n * `BootstrapOptions` instead.\n *\n * @usageNotes\n * ```ts\n * bootstrapApplication(MyApp, {providers: [\n * provideZoneChangeDetection({eventCoalescing: true}),\n * ]});\n * ```\n *\n * @publicApi\n * @see {@link /api/core/bootstrapApplication bootstrapApplication}\n * @see {@link NgZoneOptions}\n */\nfunction provideZoneChangeDetection(options) {\n const ignoreChangesOutsideZone = options?.ignoreChangesOutsideZone;\n const scheduleInRootZone = options?.scheduleInRootZone;\n const zoneProviders = internalProvideZoneChangeDetection({\n ngZoneFactory: () => {\n const ngZoneOptions = getNgZoneOptions(options);\n ngZoneOptions.scheduleInRootZone = scheduleInRootZone;\n if (ngZoneOptions.shouldCoalesceEventChangeDetection) {\n performanceMarkFeature('NgZone_CoalesceEvent');\n }\n return new NgZone(ngZoneOptions);\n },\n ignoreChangesOutsideZone,\n scheduleInRootZone\n });\n return makeEnvironmentProviders([{\n provide: PROVIDED_NG_ZONE,\n useValue: true\n }, {\n provide: ZONELESS_ENABLED,\n useValue: false\n }, zoneProviders]);\n}\n// Transforms a set of `BootstrapOptions` (supported by the NgModule-based bootstrap APIs) ->\n// `NgZoneOptions` that are recognized by the NgZone constructor. Passing no options will result in\n// a set of default options returned.\nfunction getNgZoneOptions(options) {\n return {\n enableLongStackTrace: typeof ngDevMode === 'undefined' ? false : !!ngDevMode,\n shouldCoalesceEventChangeDetection: options?.eventCoalescing ?? false,\n shouldCoalesceRunChangeDetection: options?.runCoalescing ?? false\n };\n}\nclass ZoneStablePendingTask {\n subscription = new Subscription();\n initialized = false;\n zone = inject(NgZone);\n pendingTasks = inject(PendingTasksInternal);\n initialize() {\n if (this.initialized) {\n return;\n }\n this.initialized = true;\n let task = null;\n if (!this.zone.isStable && !this.zone.hasPendingMacrotasks && !this.zone.hasPendingMicrotasks) {\n task = this.pendingTasks.add();\n }\n this.zone.runOutsideAngular(() => {\n this.subscription.add(this.zone.onStable.subscribe(() => {\n NgZone.assertNotInAngularZone();\n // Check whether there are no pending macro/micro tasks in the next tick\n // to allow for NgZone to update the state.\n queueMicrotask(() => {\n if (task !== null && !this.zone.hasPendingMacrotasks && !this.zone.hasPendingMicrotasks) {\n this.pendingTasks.remove(task);\n task = null;\n }\n });\n }));\n });\n this.subscription.add(this.zone.onUnstable.subscribe(() => {\n NgZone.assertInAngularZone();\n task ??= this.pendingTasks.add();\n }));\n }\n ngOnDestroy() {\n this.subscription.unsubscribe();\n }\n static ɵfac = function ZoneStablePendingTask_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ZoneStablePendingTask)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: ZoneStablePendingTask,\n factory: ZoneStablePendingTask.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(ZoneStablePendingTask, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\nconst CONSECUTIVE_MICROTASK_NOTIFICATION_LIMIT = 100;\nlet consecutiveMicrotaskNotifications = 0;\nlet stackFromLastFewNotifications = [];\nfunction trackMicrotaskNotificationForDebugging() {\n consecutiveMicrotaskNotifications++;\n if (CONSECUTIVE_MICROTASK_NOTIFICATION_LIMIT - consecutiveMicrotaskNotifications < 5) {\n const stack = new Error().stack;\n if (stack) {\n stackFromLastFewNotifications.push(stack);\n }\n }\n if (consecutiveMicrotaskNotifications === CONSECUTIVE_MICROTASK_NOTIFICATION_LIMIT) {\n throw new RuntimeError(103 /* RuntimeErrorCode.INFINITE_CHANGE_DETECTION */, 'Angular could not stabilize because there were endless change notifications within the browser event loop. ' + 'The stack from the last several notifications: \\n' + stackFromLastFewNotifications.join('\\n'));\n }\n}\nclass ChangeDetectionSchedulerImpl {\n appRef = inject(ApplicationRef);\n taskService = inject(PendingTasksInternal);\n ngZone = inject(NgZone);\n zonelessEnabled = inject(ZONELESS_ENABLED);\n tracing = inject(TracingService, {\n optional: true\n });\n disableScheduling = inject(ZONELESS_SCHEDULER_DISABLED, {\n optional: true\n }) ?? false;\n zoneIsDefined = typeof Zone !== 'undefined' && !!Zone.root.run;\n schedulerTickApplyArgs = [{\n data: {\n '__scheduler_tick__': true\n }\n }];\n subscriptions = new Subscription();\n angularZoneId = this.zoneIsDefined ? this.ngZone._inner?.get(angularZoneInstanceIdProperty) : null;\n scheduleInRootZone = !this.zonelessEnabled && this.zoneIsDefined && (inject(SCHEDULE_IN_ROOT_ZONE, {\n optional: true\n }) ?? false);\n cancelScheduledCallback = null;\n useMicrotaskScheduler = false;\n runningTick = false;\n pendingRenderTaskId = null;\n constructor() {\n this.subscriptions.add(this.appRef.afterTick.subscribe(() => {\n // If the scheduler isn't running a tick but the application ticked, that means\n // someone called ApplicationRef.tick manually. In this case, we should cancel\n // any change detections that had been scheduled so we don't run an extra one.\n if (!this.runningTick) {\n this.cleanup();\n }\n }));\n this.subscriptions.add(this.ngZone.onUnstable.subscribe(() => {\n // If the zone becomes unstable when we're not running tick (this happens from the zone.run),\n // we should cancel any scheduled change detection here because at this point we\n // know that the zone will stabilize at some point and run change detection itself.\n if (!this.runningTick) {\n this.cleanup();\n }\n }));\n // TODO(atscott): These conditions will need to change when zoneless is the default\n // Instead, they should flip to checking if ZoneJS scheduling is provided\n this.disableScheduling ||= !this.zonelessEnabled && (\n // NoopNgZone without enabling zoneless means no scheduling whatsoever\n this.ngZone instanceof NoopNgZone ||\n // The same goes for the lack of Zone without enabling zoneless scheduling\n !this.zoneIsDefined);\n }\n notify(source) {\n if (!this.zonelessEnabled && source === 5 /* NotificationSource.Listener */) {\n // When the notification comes from a listener, we skip the notification unless the\n // application has enabled zoneless. Ideally, listeners wouldn't notify the scheduler at all\n // automatically. We do not know that a developer made a change in the listener callback that\n // requires an `ApplicationRef.tick` (synchronize templates / run render hooks). We do this\n // only for an easier migration from OnPush components to zoneless. Because listeners are\n // usually executed inside the Angular zone and listeners automatically call `markViewDirty`,\n // developers never needed to manually use `ChangeDetectorRef.markForCheck` or some other API\n // to make listener callbacks work correctly with `OnPush` components.\n return;\n }\n let force = false;\n switch (source) {\n case 0 /* NotificationSource.MarkAncestorsForTraversal */:\n {\n this.appRef.dirtyFlags |= 2 /* ApplicationRefDirtyFlags.ViewTreeTraversal */;\n break;\n }\n case 3 /* NotificationSource.DebugApplyChanges */:\n case 2 /* NotificationSource.DeferBlockStateUpdate */:\n case 4 /* NotificationSource.MarkForCheck */:\n case 5 /* NotificationSource.Listener */:\n case 1 /* NotificationSource.SetInput */:\n {\n this.appRef.dirtyFlags |= 4 /* ApplicationRefDirtyFlags.ViewTreeCheck */;\n break;\n }\n case 6 /* NotificationSource.CustomElement */:\n {\n // We use `ViewTreeTraversal` to ensure we refresh the element even if this is triggered\n // during CD. In practice this is a no-op since the elements code also calls via a\n // `markForRefresh()` API which sends `NotificationSource.MarkAncestorsForTraversal` anyway.\n this.appRef.dirtyFlags |= 2 /* ApplicationRefDirtyFlags.ViewTreeTraversal */;\n force = true;\n break;\n }\n case 12 /* NotificationSource.RootEffect */:\n {\n this.appRef.dirtyFlags |= 16 /* ApplicationRefDirtyFlags.RootEffects */;\n // Root effects still force a CD, even if the scheduler is disabled. This ensures that\n // effects always run, even when triggered from outside the zone when the scheduler is\n // otherwise disabled.\n force = true;\n break;\n }\n case 13 /* NotificationSource.ViewEffect */:\n {\n // This is technically a no-op, since view effects will also send a\n // `MarkAncestorsForTraversal` notification. Still, we set this for logical consistency.\n this.appRef.dirtyFlags |= 2 /* ApplicationRefDirtyFlags.ViewTreeTraversal */;\n // View effects still force a CD, even if the scheduler is disabled. This ensures that\n // effects always run, even when triggered from outside the zone when the scheduler is\n // otherwise disabled.\n force = true;\n break;\n }\n case 11 /* NotificationSource.PendingTaskRemoved */:\n {\n // Removing a pending task via the public API forces a scheduled tick, ensuring that\n // stability is async and delayed until there was at least an opportunity to run\n // application synchronization. This prevents some footguns when working with the\n // public API for pending tasks where developers attempt to update application state\n // immediately after removing the last task.\n force = true;\n break;\n }\n case 9 /* NotificationSource.ViewDetachedFromDOM */:\n case 8 /* NotificationSource.ViewAttached */:\n case 7 /* NotificationSource.RenderHook */:\n case 10 /* NotificationSource.AsyncAnimationsLoaded */:\n default:\n {\n // These notifications only schedule a tick but do not change whether we should refresh\n // views. Instead, we only need to run render hooks unless another notification from the\n // other set is also received before `tick` happens.\n this.appRef.dirtyFlags |= 8 /* ApplicationRefDirtyFlags.AfterRender */;\n }\n }\n // If not already defined, attempt to capture a tracing snapshot of this\n // notification so that the resulting CD run can be attributed to the\n // context which produced the notification.\n this.appRef.tracingSnapshot = this.tracing?.snapshot(this.appRef.tracingSnapshot) ?? null;\n if (!this.shouldScheduleTick(force)) {\n return;\n }\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (this.useMicrotaskScheduler) {\n trackMicrotaskNotificationForDebugging();\n } else {\n consecutiveMicrotaskNotifications = 0;\n stackFromLastFewNotifications.length = 0;\n }\n }\n const scheduleCallback = this.useMicrotaskScheduler ? scheduleCallbackWithMicrotask : scheduleCallbackWithRafRace;\n this.pendingRenderTaskId = this.taskService.add();\n if (this.scheduleInRootZone) {\n this.cancelScheduledCallback = Zone.root.run(() => scheduleCallback(() => this.tick()));\n } else {\n this.cancelScheduledCallback = this.ngZone.runOutsideAngular(() => scheduleCallback(() => this.tick()));\n }\n }\n shouldScheduleTick(force) {\n if (this.disableScheduling && !force || this.appRef.destroyed) {\n return false;\n }\n // already scheduled or running\n if (this.pendingRenderTaskId !== null || this.runningTick || this.appRef._runningTick) {\n return false;\n }\n // If we're inside the zone don't bother with scheduler. Zone will stabilize\n // eventually and run change detection.\n if (!this.zonelessEnabled && this.zoneIsDefined && Zone.current.get(angularZoneInstanceIdProperty + this.angularZoneId)) {\n return false;\n }\n return true;\n }\n /**\n * Calls ApplicationRef._tick inside the `NgZone`.\n *\n * Calling `tick` directly runs change detection and cancels any change detection that had been\n * scheduled previously.\n *\n * @param shouldRefreshViews Passed directly to `ApplicationRef._tick` and skips straight to\n * render hooks when `false`.\n */\n tick() {\n // When ngZone.run below exits, onMicrotaskEmpty may emit if the zone is\n // stable. We want to prevent double ticking so we track whether the tick is\n // already running and skip it if so.\n if (this.runningTick || this.appRef.destroyed) {\n return;\n }\n // If we reach the tick and there is no work to be done in ApplicationRef.tick,\n // skip it altogether and clean up. There may be no work if, for example, the only\n // event that notified the scheduler was the removal of a pending task.\n if (this.appRef.dirtyFlags === 0 /* ApplicationRefDirtyFlags.None */) {\n this.cleanup();\n return;\n }\n // The scheduler used to pass \"whether to check views\" as a boolean flag instead of setting\n // fine-grained dirtiness flags, and global checking was always used on the first pass. This\n // created an interesting edge case: if a notification made a view dirty and then ticked via the\n // scheduler (and not the zone) a global check was still performed.\n //\n // Ideally, this would not be the case, and only zone-based ticks would do global passes.\n // However this is a breaking change and requires fixes in g3. Until this cleanup can be done,\n // we add the `ViewTreeGlobal` flag to request a global check if any views are dirty in a\n // scheduled tick (unless zoneless is enabled, in which case global checks aren't really a\n // thing).\n //\n // TODO(alxhub): clean up and remove this workaround as a breaking change.\n if (!this.zonelessEnabled && this.appRef.dirtyFlags & 7 /* ApplicationRefDirtyFlags.ViewTreeAny */) {\n this.appRef.dirtyFlags |= 1 /* ApplicationRefDirtyFlags.ViewTreeGlobal */;\n }\n const task = this.taskService.add();\n try {\n this.ngZone.run(() => {\n this.runningTick = true;\n this.appRef._tick();\n }, undefined, this.schedulerTickApplyArgs);\n } catch (e) {\n this.taskService.remove(task);\n throw e;\n } finally {\n this.cleanup();\n }\n // If we're notified of a change within 1 microtask of running change\n // detection, run another round in the same event loop. This allows code\n // which uses Promise.resolve (see NgModel) to avoid\n // ExpressionChanged...Error to still be reflected in a single browser\n // paint, even if that spans multiple rounds of change detection.\n this.useMicrotaskScheduler = true;\n scheduleCallbackWithMicrotask(() => {\n this.useMicrotaskScheduler = false;\n this.taskService.remove(task);\n });\n }\n ngOnDestroy() {\n this.subscriptions.unsubscribe();\n this.cleanup();\n }\n cleanup() {\n this.runningTick = false;\n this.cancelScheduledCallback?.();\n this.cancelScheduledCallback = null;\n // If this is the last task, the service will synchronously emit a stable\n // notification. If there is a subscriber that then acts in a way that\n // tries to notify the scheduler again, we need to be able to respond to\n // schedule a new change detection. Therefore, we should clear the task ID\n // before removing it from the pending tasks (or the tasks service should\n // not synchronously emit stable, similar to how Zone stableness only\n // happens if it's still stable after a microtask).\n if (this.pendingRenderTaskId !== null) {\n const taskId = this.pendingRenderTaskId;\n this.pendingRenderTaskId = null;\n this.taskService.remove(taskId);\n }\n }\n static ɵfac = function ChangeDetectionSchedulerImpl_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ChangeDetectionSchedulerImpl)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: ChangeDetectionSchedulerImpl,\n factory: ChangeDetectionSchedulerImpl.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(ChangeDetectionSchedulerImpl, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [], null);\n})();\n/**\n * Provides change detection without ZoneJS for the application bootstrapped using\n * `bootstrapApplication`.\n *\n * This function allows you to configure the application to not use the state/state changes of\n * ZoneJS to schedule change detection in the application. This will work when ZoneJS is not present\n * on the page at all or if it exists because something else is using it (either another Angular\n * application which uses ZoneJS for scheduling or some other library that relies on ZoneJS).\n *\n * This can also be added to the `TestBed` providers to configure the test environment to more\n * closely match production behavior. This will help give higher confidence that components are\n * compatible with zoneless change detection.\n *\n * ZoneJS uses browser events to trigger change detection. When using this provider, Angular will\n * instead use Angular APIs to schedule change detection. These APIs include:\n *\n * - `ChangeDetectorRef.markForCheck`\n * - `ComponentRef.setInput`\n * - updating a signal that is read in a template\n * - when bound host or template listeners are triggered\n * - attaching a view that was marked dirty by one of the above\n * - removing a view\n * - registering a render hook (templates are only refreshed if render hooks do one of the above)\n *\n * @usageNotes\n * ```ts\n * bootstrapApplication(MyApp, {providers: [\n * provideExperimentalZonelessChangeDetection(),\n * ]});\n * ```\n *\n * This API is experimental. Neither the shape, nor the underlying behavior is stable and can change\n * in patch versions. There are known feature gaps and API ergonomic considerations. We will iterate\n * on the exact API based on the feedback and our understanding of the problem and solution space.\n *\n * @publicApi\n * @experimental\n * @see {@link /api/platform-browser/bootstrapApplication bootstrapApplication}\n */\nfunction provideExperimentalZonelessChangeDetection() {\n performanceMarkFeature('NgZoneless');\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && typeof Zone !== 'undefined' && Zone) {\n const message = formatRuntimeError(914 /* RuntimeErrorCode.UNEXPECTED_ZONEJS_PRESENT_IN_ZONELESS_MODE */, `The application is using zoneless change detection, but is still loading Zone.js. ` + `Consider removing Zone.js to get the full benefits of zoneless. ` + `In applications using the Angular CLI, Zone.js is typically included in the \"polyfills\" section of the angular.json file.`);\n console.warn(message);\n }\n return makeEnvironmentProviders([{\n provide: ChangeDetectionScheduler,\n useExisting: ChangeDetectionSchedulerImpl\n }, {\n provide: NgZone,\n useClass: NoopNgZone\n }, {\n provide: ZONELESS_ENABLED,\n useValue: true\n }, {\n provide: SCHEDULE_IN_ROOT_ZONE,\n useValue: false\n }, typeof ngDevMode === 'undefined' || ngDevMode ? [{\n provide: PROVIDED_ZONELESS,\n useValue: true\n }] : []]);\n}\n\n/**\n * Work out the locale from the potential global properties.\n *\n * * Closure Compiler: use `goog.LOCALE`.\n * * Ivy enabled: use `$localize.locale`\n */\nfunction getGlobalLocale() {\n if (typeof ngI18nClosureMode !== 'undefined' && ngI18nClosureMode && typeof goog !== 'undefined' && goog.LOCALE !== 'en') {\n // * The default `goog.LOCALE` value is `en`, while Angular used `en-US`.\n // * In order to preserve backwards compatibility, we use Angular default value over\n // Closure Compiler's one.\n return goog.LOCALE;\n } else {\n // KEEP `typeof $localize !== 'undefined' && $localize.locale` IN SYNC WITH THE LOCALIZE\n // COMPILE-TIME INLINER.\n //\n // * During compile time inlining of translations the expression will be replaced\n // with a string literal that is the current locale. Other forms of this expression are not\n // guaranteed to be replaced.\n //\n // * During runtime translation evaluation, the developer is required to set `$localize.locale`\n // if required, or just to provide their own `LOCALE_ID` provider.\n return typeof $localize !== 'undefined' && $localize.locale || DEFAULT_LOCALE_ID;\n }\n}\n/**\n * Provide this token to set the locale of your application.\n * It is used for i18n extraction, by i18n pipes (DatePipe, I18nPluralPipe, CurrencyPipe,\n * DecimalPipe and PercentPipe) and by ICU expressions.\n *\n * See the [i18n guide](guide/i18n/locale-id) for more information.\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * import { LOCALE_ID } from '@angular/core';\n * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';\n * import { AppModule } from './app/app.module';\n *\n * platformBrowserDynamic().bootstrapModule(AppModule, {\n * providers: [{provide: LOCALE_ID, useValue: 'en-US' }]\n * });\n * ```\n *\n * @publicApi\n */\nconst LOCALE_ID = new InjectionToken(ngDevMode ? 'LocaleId' : '', {\n providedIn: 'root',\n factory: () => inject(LOCALE_ID, InjectFlags.Optional | InjectFlags.SkipSelf) || getGlobalLocale()\n});\n/**\n * Provide this token to set the default currency code your application uses for\n * CurrencyPipe when there is no currency code passed into it. This is only used by\n * CurrencyPipe and has no relation to locale currency. Defaults to USD if not configured.\n *\n * See the [i18n guide](guide/i18n/locale-id) for more information.\n *\n * <div class=\"docs-alert docs-alert-helpful\">\n *\n * The default currency code is currently always `USD`.\n *\n * If you need the previous behavior then set it by creating a `DEFAULT_CURRENCY_CODE` provider in\n * your application `NgModule`:\n *\n * ```ts\n * {provide: DEFAULT_CURRENCY_CODE, useValue: 'USD'}\n * ```\n *\n * </div>\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';\n * import { AppModule } from './app/app.module';\n *\n * platformBrowserDynamic().bootstrapModule(AppModule, {\n * providers: [{provide: DEFAULT_CURRENCY_CODE, useValue: 'EUR' }]\n * });\n * ```\n *\n * @publicApi\n */\nconst DEFAULT_CURRENCY_CODE = new InjectionToken(ngDevMode ? 'DefaultCurrencyCode' : '', {\n providedIn: 'root',\n factory: () => USD_CURRENCY_CODE\n});\n/**\n * Use this token at bootstrap to provide the content of your translation file (`xtb`,\n * `xlf` or `xlf2`) when you want to translate your application in another language.\n *\n * See the [i18n guide](guide/i18n/merge) for more information.\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * import { TRANSLATIONS } from '@angular/core';\n * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';\n * import { AppModule } from './app/app.module';\n *\n * // content of your translation file\n * const translations = '....';\n *\n * platformBrowserDynamic().bootstrapModule(AppModule, {\n * providers: [{provide: TRANSLATIONS, useValue: translations }]\n * });\n * ```\n *\n * @publicApi\n */\nconst TRANSLATIONS = new InjectionToken(ngDevMode ? 'Translations' : '');\n/**\n * Provide this token at bootstrap to set the format of your {@link TRANSLATIONS}: `xtb`,\n * `xlf` or `xlf2`.\n *\n * See the [i18n guide](guide/i18n/merge) for more information.\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * import { TRANSLATIONS_FORMAT } from '@angular/core';\n * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';\n * import { AppModule } from './app/app.module';\n *\n * platformBrowserDynamic().bootstrapModule(AppModule, {\n * providers: [{provide: TRANSLATIONS_FORMAT, useValue: 'xlf' }]\n * });\n * ```\n *\n * @publicApi\n */\nconst TRANSLATIONS_FORMAT = new InjectionToken(ngDevMode ? 'TranslationsFormat' : '');\n/**\n * Use this enum at bootstrap as an option of `bootstrapModule` to define the strategy\n * that the compiler should use in case of missing translations:\n * - Error: throw if you have missing translations.\n * - Warning (default): show a warning in the console and/or shell.\n * - Ignore: do nothing.\n *\n * See the [i18n guide](guide/i18n/merge#report-missing-translations) for more information.\n *\n * @usageNotes\n * ### Example\n * ```ts\n * import { MissingTranslationStrategy } from '@angular/core';\n * import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';\n * import { AppModule } from './app/app.module';\n *\n * platformBrowserDynamic().bootstrapModule(AppModule, {\n * missingTranslation: MissingTranslationStrategy.Error\n * });\n * ```\n *\n * @publicApi\n */\nvar MissingTranslationStrategy;\n(function (MissingTranslationStrategy) {\n MissingTranslationStrategy[MissingTranslationStrategy[\"Error\"] = 0] = \"Error\";\n MissingTranslationStrategy[MissingTranslationStrategy[\"Warning\"] = 1] = \"Warning\";\n MissingTranslationStrategy[MissingTranslationStrategy[\"Ignore\"] = 2] = \"Ignore\";\n})(MissingTranslationStrategy || (MissingTranslationStrategy = {}));\n\n// A delay in milliseconds before the scan is run after onLoad, to avoid any\n// potential race conditions with other LCP-related functions. This delay\n// happens outside of the main JavaScript execution and will only effect the timing\n// on when the warning becomes visible in the console.\nconst SCAN_DELAY = 200;\nconst OVERSIZED_IMAGE_TOLERANCE = 1200;\nclass ImagePerformanceWarning {\n // Map of full image URLs -> original `ngSrc` values.\n window = null;\n observer = null;\n options = inject(IMAGE_CONFIG);\n lcpImageUrl;\n start() {\n if (typeof ngServerMode !== 'undefined' && ngServerMode || typeof PerformanceObserver === 'undefined' || this.options?.disableImageSizeWarning && this.options?.disableImageLazyLoadWarning) {\n return;\n }\n this.observer = this.initPerformanceObserver();\n const doc = getDocument();\n const win = doc.defaultView;\n if (win) {\n this.window = win;\n // Wait to avoid race conditions where LCP image triggers\n // load event before it's recorded by the performance observer\n const waitToScan = () => {\n setTimeout(this.scanImages.bind(this), SCAN_DELAY);\n };\n const setup = () => {\n // Consider the case when the application is created and destroyed multiple times.\n // Typically, applications are created instantly once the page is loaded, and the\n // `window.load` listener is always triggered. However, the `window.load` event will never\n // be fired if the page is loaded, and the application is created later. Checking for\n // `readyState` is the easiest way to determine whether the page has been loaded or not.\n if (doc.readyState === 'complete') {\n waitToScan();\n } else {\n this.window?.addEventListener('load', waitToScan, {\n once: true\n });\n }\n };\n // Angular doesn't have to run change detection whenever any asynchronous tasks are invoked in\n // the scope of this functionality.\n if (typeof Zone !== 'undefined') {\n Zone.root.run(() => setup());\n } else {\n setup();\n }\n }\n }\n ngOnDestroy() {\n this.observer?.disconnect();\n }\n initPerformanceObserver() {\n if (typeof PerformanceObserver === 'undefined') {\n return null;\n }\n const observer = new PerformanceObserver(entryList => {\n const entries = entryList.getEntries();\n if (entries.length === 0) return;\n // We use the latest entry produced by the `PerformanceObserver` as the best\n // signal on which element is actually an LCP one. As an example, the first image to load on\n // a page, by virtue of being the only thing on the page so far, is often a LCP candidate\n // and gets reported by PerformanceObserver, but isn't necessarily the LCP element.\n const lcpElement = entries[entries.length - 1];\n // Cast to `any` due to missing `element` on the `LargestContentfulPaint` type of entry.\n // See https://developer.mozilla.org/en-US/docs/Web/API/LargestContentfulPaint\n const imgSrc = lcpElement.element?.src ?? '';\n // Exclude `data:` and `blob:` URLs, since they are fetched resources.\n if (imgSrc.startsWith('data:') || imgSrc.startsWith('blob:')) return;\n this.lcpImageUrl = imgSrc;\n });\n observer.observe({\n type: 'largest-contentful-paint',\n buffered: true\n });\n return observer;\n }\n scanImages() {\n const images = getDocument().querySelectorAll('img');\n let lcpElementFound,\n lcpElementLoadedCorrectly = false;\n images.forEach(image => {\n if (!this.options?.disableImageSizeWarning) {\n // Image elements using the NgOptimizedImage directive are excluded,\n // as that directive has its own version of this check.\n if (!image.getAttribute('ng-img') && this.isOversized(image)) {\n logOversizedImageWarning(image.src);\n }\n }\n if (!this.options?.disableImageLazyLoadWarning && this.lcpImageUrl) {\n if (image.src === this.lcpImageUrl) {\n lcpElementFound = true;\n if (image.loading !== 'lazy' || image.getAttribute('ng-img')) {\n // This variable is set to true and never goes back to false to account\n // for the case where multiple images have the same src url, and some\n // have lazy loading while others don't.\n // Also ignore NgOptimizedImage because there's a different warning for that.\n lcpElementLoadedCorrectly = true;\n }\n }\n }\n });\n if (lcpElementFound && !lcpElementLoadedCorrectly && this.lcpImageUrl && !this.options?.disableImageLazyLoadWarning) {\n logLazyLCPWarning(this.lcpImageUrl);\n }\n }\n isOversized(image) {\n if (!this.window) {\n return false;\n }\n // The `isOversized` check may not be applicable or may require adjustments\n // for several types of image formats or scenarios. Currently, we specify only\n // `svg`, but this may also include `gif` since their quality isn’t tied to\n // dimensions in the same way as raster images.\n const nonOversizedImageExtentions = [\n // SVG images are vector-based, which means they can scale\n // to any size without losing quality.\n '.svg'];\n // Convert it to lowercase because this may have uppercase\n // extensions, such as `IMAGE.SVG`.\n // We fallback to an empty string because `src` may be `undefined`\n // if it is explicitly set to `null` by some third-party code\n // (e.g., `image.src = null`).\n const imageSource = (image.src || '').toLowerCase();\n if (nonOversizedImageExtentions.some(extension => imageSource.endsWith(extension))) {\n return false;\n }\n const computedStyle = this.window.getComputedStyle(image);\n let renderedWidth = parseFloat(computedStyle.getPropertyValue('width'));\n let renderedHeight = parseFloat(computedStyle.getPropertyValue('height'));\n const boxSizing = computedStyle.getPropertyValue('box-sizing');\n const objectFit = computedStyle.getPropertyValue('object-fit');\n if (objectFit === `cover`) {\n // Object fit cover may indicate a use case such as a sprite sheet where\n // this warning does not apply.\n return false;\n }\n if (boxSizing === 'border-box') {\n // If the image `box-sizing` is set to `border-box`, we adjust the rendered\n // dimensions by subtracting padding values.\n const paddingTop = computedStyle.getPropertyValue('padding-top');\n const paddingRight = computedStyle.getPropertyValue('padding-right');\n const paddingBottom = computedStyle.getPropertyValue('padding-bottom');\n const paddingLeft = computedStyle.getPropertyValue('padding-left');\n renderedWidth -= parseFloat(paddingRight) + parseFloat(paddingLeft);\n renderedHeight -= parseFloat(paddingTop) + parseFloat(paddingBottom);\n }\n const intrinsicWidth = image.naturalWidth;\n const intrinsicHeight = image.naturalHeight;\n const recommendedWidth = this.window.devicePixelRatio * renderedWidth;\n const recommendedHeight = this.window.devicePixelRatio * renderedHeight;\n const oversizedWidth = intrinsicWidth - recommendedWidth >= OVERSIZED_IMAGE_TOLERANCE;\n const oversizedHeight = intrinsicHeight - recommendedHeight >= OVERSIZED_IMAGE_TOLERANCE;\n return oversizedWidth || oversizedHeight;\n }\n static ɵfac = function ImagePerformanceWarning_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ImagePerformanceWarning)();\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: ImagePerformanceWarning,\n factory: ImagePerformanceWarning.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(ImagePerformanceWarning, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\nfunction logLazyLCPWarning(src) {\n console.warn(formatRuntimeError(-913 /* RuntimeErrorCode.IMAGE_PERFORMANCE_WARNING */, `An image with src ${src} is the Largest Contentful Paint (LCP) element ` + `but was given a \"loading\" value of \"lazy\", which can negatively impact ` + `application loading performance. This warning can be addressed by ` + `changing the loading value of the LCP image to \"eager\", or by using the ` + `NgOptimizedImage directive's prioritization utilities. For more ` + `information about addressing or disabling this warning, see ` + `https://angular.dev/errors/NG0913`));\n}\nfunction logOversizedImageWarning(src) {\n console.warn(formatRuntimeError(-913 /* RuntimeErrorCode.IMAGE_PERFORMANCE_WARNING */, `An image with src ${src} has intrinsic file dimensions much larger than its ` + `rendered size. This can negatively impact application loading performance. ` + `For more information about addressing or disabling this warning, see ` + `https://angular.dev/errors/NG0913`));\n}\n\n/**\n * Internal token that allows to register extra callbacks that should be invoked during the\n * `PlatformRef.destroy` operation. This token is needed to avoid a direct reference to the\n * `PlatformRef` class (i.e. register the callback via `PlatformRef.onDestroy`), thus making the\n * entire class tree-shakeable.\n */\nconst PLATFORM_DESTROY_LISTENERS = new InjectionToken(ngDevMode ? 'PlatformDestroyListeners' : '');\n\n/**\n * InjectionToken to control root component bootstrap behavior.\n *\n * This token is primarily used in Angular's server-side rendering (SSR) scenarios,\n * particularly by the `@angular/ssr` package, to manage whether the root component\n * should be bootstrapped during the application initialization process.\n *\n * ## Purpose:\n * During SSR route extraction, setting this token to `false` prevents Angular from\n * bootstrapping the root component. This avoids unnecessary component rendering,\n * enabling route extraction without requiring additional APIs or triggering\n * component logic.\n *\n * ## Behavior:\n * - **`false`**: Prevents the root component from being bootstrapped.\n * - **`true`** (default): Proceeds with the normal root component bootstrap process.\n *\n * This mechanism ensures SSR can efficiently separate route extraction logic\n * from component rendering.\n */\nconst ENABLE_ROOT_COMPONENT_BOOTSTRAP = new InjectionToken(ngDevMode ? 'ENABLE_ROOT_COMPONENT_BOOTSTRAP' : '');\nfunction isApplicationBootstrapConfig(config) {\n return !config.moduleRef;\n}\nfunction bootstrap(config) {\n const envInjector = isApplicationBootstrapConfig(config) ? config.r3Injector : config.moduleRef.injector;\n const ngZone = envInjector.get(NgZone);\n return ngZone.run(() => {\n if (isApplicationBootstrapConfig(config)) {\n config.r3Injector.resolveInjectorInitializers();\n } else {\n config.moduleRef.resolveInjectorInitializers();\n }\n const exceptionHandler = envInjector.get(ErrorHandler, null);\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (exceptionHandler === null) {\n const errorMessage = isApplicationBootstrapConfig(config) ? 'No `ErrorHandler` found in the Dependency Injection tree.' : 'No ErrorHandler. Is platform module (BrowserModule) included';\n throw new RuntimeError(402 /* RuntimeErrorCode.MISSING_REQUIRED_INJECTABLE_IN_BOOTSTRAP */, errorMessage);\n }\n if (envInjector.get(PROVIDED_ZONELESS) && envInjector.get(PROVIDED_NG_ZONE)) {\n throw new RuntimeError(408 /* RuntimeErrorCode.PROVIDED_BOTH_ZONE_AND_ZONELESS */, 'Invalid change detection configuration: ' + 'provideZoneChangeDetection and provideExperimentalZonelessChangeDetection cannot be used together.');\n }\n }\n let onErrorSubscription;\n ngZone.runOutsideAngular(() => {\n onErrorSubscription = ngZone.onError.subscribe({\n next: error => {\n exceptionHandler.handleError(error);\n }\n });\n });\n // If the whole platform is destroyed, invoke the `destroy` method\n // for all bootstrapped applications as well.\n if (isApplicationBootstrapConfig(config)) {\n const destroyListener = () => envInjector.destroy();\n const onPlatformDestroyListeners = config.platformInjector.get(PLATFORM_DESTROY_LISTENERS);\n onPlatformDestroyListeners.add(destroyListener);\n envInjector.onDestroy(() => {\n onErrorSubscription.unsubscribe();\n onPlatformDestroyListeners.delete(destroyListener);\n });\n } else {\n const destroyListener = () => config.moduleRef.destroy();\n const onPlatformDestroyListeners = config.platformInjector.get(PLATFORM_DESTROY_LISTENERS);\n onPlatformDestroyListeners.add(destroyListener);\n config.moduleRef.onDestroy(() => {\n remove(config.allPlatformModules, config.moduleRef);\n onErrorSubscription.unsubscribe();\n onPlatformDestroyListeners.delete(destroyListener);\n });\n }\n return _callAndReportToErrorHandler(exceptionHandler, ngZone, () => {\n const initStatus = envInjector.get(ApplicationInitStatus);\n initStatus.runInitializers();\n return initStatus.donePromise.then(() => {\n // If the `LOCALE_ID` provider is defined at bootstrap then we set the value for ivy\n const localeId = envInjector.get(LOCALE_ID, DEFAULT_LOCALE_ID);\n setLocaleId(localeId || DEFAULT_LOCALE_ID);\n const enableRootComponentBoostrap = envInjector.get(ENABLE_ROOT_COMPONENT_BOOTSTRAP, true);\n if (!enableRootComponentBoostrap) {\n if (isApplicationBootstrapConfig(config)) {\n return envInjector.get(ApplicationRef);\n }\n config.allPlatformModules.push(config.moduleRef);\n return config.moduleRef;\n }\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const imagePerformanceService = envInjector.get(ImagePerformanceWarning);\n imagePerformanceService.start();\n }\n if (isApplicationBootstrapConfig(config)) {\n const appRef = envInjector.get(ApplicationRef);\n if (config.rootComponent !== undefined) {\n appRef.bootstrap(config.rootComponent);\n }\n return appRef;\n } else {\n moduleDoBootstrap(config.moduleRef, config.allPlatformModules);\n return config.moduleRef;\n }\n });\n });\n });\n}\nfunction moduleDoBootstrap(moduleRef, allPlatformModules) {\n const appRef = moduleRef.injector.get(ApplicationRef);\n if (moduleRef._bootstrapComponents.length > 0) {\n moduleRef._bootstrapComponents.forEach(f => appRef.bootstrap(f));\n } else if (moduleRef.instance.ngDoBootstrap) {\n moduleRef.instance.ngDoBootstrap(appRef);\n } else {\n throw new RuntimeError(-403 /* RuntimeErrorCode.BOOTSTRAP_COMPONENTS_NOT_FOUND */, ngDevMode && `The module ${stringify(moduleRef.instance.constructor)} was bootstrapped, ` + `but it does not declare \"@NgModule.bootstrap\" components nor a \"ngDoBootstrap\" method. ` + `Please define one of these.`);\n }\n allPlatformModules.push(moduleRef);\n}\nfunction _callAndReportToErrorHandler(errorHandler, ngZone, callback) {\n try {\n const result = callback();\n if (isPromise(result)) {\n return result.catch(e => {\n ngZone.runOutsideAngular(() => errorHandler.handleError(e));\n // rethrow as the exception handler might not do it\n throw e;\n });\n }\n return result;\n } catch (e) {\n ngZone.runOutsideAngular(() => errorHandler.handleError(e));\n // rethrow as the exception handler might not do it\n throw e;\n }\n}\n\n/**\n * The Angular platform is the entry point for Angular on a web page.\n * Each page has exactly one platform. Services (such as reflection) which are common\n * to every Angular application running on the page are bound in its scope.\n * A page's platform is initialized implicitly when a platform is created using a platform\n * factory such as `PlatformBrowser`, or explicitly by calling the `createPlatform()` function.\n *\n * @publicApi\n */\nclass PlatformRef {\n _injector;\n _modules = [];\n _destroyListeners = [];\n _destroyed = false;\n /** @internal */\n constructor(_injector) {\n this._injector = _injector;\n }\n /**\n * Creates an instance of an `@NgModule` for the given platform.\n *\n * @deprecated Passing NgModule factories as the `PlatformRef.bootstrapModuleFactory` function\n * argument is deprecated. Use the `PlatformRef.bootstrapModule` API instead.\n */\n bootstrapModuleFactory(moduleFactory, options) {\n const scheduleInRootZone = options?.scheduleInRootZone;\n const ngZoneFactory = () => getNgZone(options?.ngZone, {\n ...getNgZoneOptions({\n eventCoalescing: options?.ngZoneEventCoalescing,\n runCoalescing: options?.ngZoneRunCoalescing\n }),\n scheduleInRootZone\n });\n const ignoreChangesOutsideZone = options?.ignoreChangesOutsideZone;\n const allAppProviders = [internalProvideZoneChangeDetection({\n ngZoneFactory,\n ignoreChangesOutsideZone\n }), {\n provide: ChangeDetectionScheduler,\n useExisting: ChangeDetectionSchedulerImpl\n }];\n const moduleRef = createNgModuleRefWithProviders(moduleFactory.moduleType, this.injector, allAppProviders);\n return bootstrap({\n moduleRef,\n allPlatformModules: this._modules,\n platformInjector: this.injector\n });\n }\n /**\n * Creates an instance of an `@NgModule` for a given platform.\n *\n * @usageNotes\n * ### Simple Example\n *\n * ```ts\n * @NgModule({\n * imports: [BrowserModule]\n * })\n * class MyModule {}\n *\n * let moduleRef = platformBrowser().bootstrapModule(MyModule);\n * ```\n *\n */\n bootstrapModule(moduleType, compilerOptions = []) {\n const options = optionsReducer({}, compilerOptions);\n return compileNgModuleFactory(this.injector, options, moduleType).then(moduleFactory => this.bootstrapModuleFactory(moduleFactory, options));\n }\n /**\n * Registers a listener to be called when the platform is destroyed.\n */\n onDestroy(callback) {\n this._destroyListeners.push(callback);\n }\n /**\n * Retrieves the platform {@link Injector}, which is the parent injector for\n * every Angular application on the page and provides singleton providers.\n */\n get injector() {\n return this._injector;\n }\n /**\n * Destroys the current Angular platform and all Angular applications on the page.\n * Destroys all modules and listeners registered with the platform.\n */\n destroy() {\n if (this._destroyed) {\n throw new RuntimeError(404 /* RuntimeErrorCode.PLATFORM_ALREADY_DESTROYED */, ngDevMode && 'The platform has already been destroyed!');\n }\n this._modules.slice().forEach(module => module.destroy());\n this._destroyListeners.forEach(listener => listener());\n const destroyListeners = this._injector.get(PLATFORM_DESTROY_LISTENERS, null);\n if (destroyListeners) {\n destroyListeners.forEach(listener => listener());\n destroyListeners.clear();\n }\n this._destroyed = true;\n }\n /**\n * Indicates whether this instance was destroyed.\n */\n get destroyed() {\n return this._destroyed;\n }\n static ɵfac = function PlatformRef_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PlatformRef)(ɵɵinject(Injector));\n };\n static ɵprov = /*@__PURE__*/ɵɵdefineInjectable({\n token: PlatformRef,\n factory: PlatformRef.ɵfac,\n providedIn: 'platform'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(PlatformRef, [{\n type: Injectable,\n args: [{\n providedIn: 'platform'\n }]\n }], () => [{\n type: Injector\n }], null);\n})();\nlet _platformInjector = null;\n/**\n * Internal token to indicate whether having multiple bootstrapped platform should be allowed (only\n * one bootstrapped platform is allowed by default). This token helps to support SSR scenarios.\n */\nconst ALLOW_MULTIPLE_PLATFORMS = new InjectionToken(ngDevMode ? 'AllowMultipleToken' : '');\n/**\n * Creates a platform.\n * Platforms must be created on launch using this function.\n *\n * @publicApi\n */\nfunction createPlatform(injector) {\n if (_platformInjector && !_platformInjector.get(ALLOW_MULTIPLE_PLATFORMS, false)) {\n throw new RuntimeError(400 /* RuntimeErrorCode.MULTIPLE_PLATFORMS */, ngDevMode && 'There can be only one platform. Destroy the previous one to create a new one.');\n }\n publishDefaultGlobalUtils();\n publishSignalConfiguration();\n _platformInjector = injector;\n const platform = injector.get(PlatformRef);\n runPlatformInitializers(injector);\n return platform;\n}\n/**\n * Creates a factory for a platform. Can be used to provide or override `Providers` specific to\n * your application's runtime needs, such as `PLATFORM_INITIALIZER` and `PLATFORM_ID`.\n * @param parentPlatformFactory Another platform factory to modify. Allows you to compose factories\n * to build up configurations that might be required by different libraries or parts of the\n * application.\n * @param name Identifies the new platform factory.\n * @param providers A set of dependency providers for platforms created with the new factory.\n *\n * @publicApi\n */\nfunction createPlatformFactory(parentPlatformFactory, name, providers = []) {\n const desc = `Platform: ${name}`;\n const marker = new InjectionToken(desc);\n return (extraProviders = []) => {\n let platform = getPlatform();\n if (!platform || platform.injector.get(ALLOW_MULTIPLE_PLATFORMS, false)) {\n const platformProviders = [...providers, ...extraProviders, {\n provide: marker,\n useValue: true\n }];\n if (parentPlatformFactory) {\n parentPlatformFactory(platformProviders);\n } else {\n createPlatform(createPlatformInjector(platformProviders, desc));\n }\n }\n return assertPlatform(marker);\n };\n}\n/**\n * Helper function to create an instance of a platform injector (that maintains the 'platform'\n * scope).\n */\nfunction createPlatformInjector(providers = [], name) {\n return Injector.create({\n name,\n providers: [{\n provide: INJECTOR_SCOPE,\n useValue: 'platform'\n }, {\n provide: PLATFORM_DESTROY_LISTENERS,\n useValue: new Set([() => _platformInjector = null])\n }, ...providers]\n });\n}\n/**\n * Checks that there is currently a platform that contains the given token as a provider.\n *\n * @publicApi\n */\nfunction assertPlatform(requiredToken) {\n const platform = getPlatform();\n if (!platform) {\n throw new RuntimeError(401 /* RuntimeErrorCode.PLATFORM_NOT_FOUND */, ngDevMode && 'No platform exists!');\n }\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !platform.injector.get(requiredToken, null)) {\n throw new RuntimeError(400 /* RuntimeErrorCode.MULTIPLE_PLATFORMS */, 'A platform with a different configuration has been created. Please destroy it first.');\n }\n return platform;\n}\n/**\n * Returns the current platform.\n *\n * @publicApi\n */\nfunction getPlatform() {\n return _platformInjector?.get(PlatformRef) ?? null;\n}\n/**\n * Destroys the current Angular platform and all Angular applications on the page.\n * Destroys all modules and listeners registered with the platform.\n *\n * @publicApi\n */\nfunction destroyPlatform() {\n getPlatform()?.destroy();\n}\n/**\n * The goal of this function is to bootstrap a platform injector,\n * but avoid referencing `PlatformRef` class.\n * This function is needed for bootstrapping a Standalone Component.\n */\nfunction createOrReusePlatformInjector(providers = []) {\n // If a platform injector already exists, it means that the platform\n // is already bootstrapped and no additional actions are required.\n if (_platformInjector) return _platformInjector;\n publishDefaultGlobalUtils();\n // Otherwise, setup a new platform injector and run platform initializers.\n const injector = createPlatformInjector(providers);\n _platformInjector = injector;\n publishSignalConfiguration();\n runPlatformInitializers(injector);\n return injector;\n}\n/**\n * @description\n * This function is used to provide initialization functions that will be executed upon\n * initialization of the platform injector.\n *\n * Note that the provided initializer is run in the injection context.\n *\n * Previously, this was achieved using the `PLATFORM_INITIALIZER` token which is now deprecated.\n *\n * @see {@link PLATFORM_INITIALIZER}\n *\n * @publicApi\n */\nfunction providePlatformInitializer(initializerFn) {\n return makeEnvironmentProviders([{\n provide: PLATFORM_INITIALIZER,\n useValue: initializerFn,\n multi: true\n }]);\n}\nfunction runPlatformInitializers(injector) {\n const inits = injector.get(PLATFORM_INITIALIZER, null);\n runInInjectionContext(injector, () => {\n inits?.forEach(init => init());\n });\n}\n\n/**\n * Used to periodically verify no expressions have changed after they were checked.\n *\n * @param options Used to configure when the check will execute.\n * - `interval` will periodically run exhaustive `checkNoChanges` on application views\n * - `useNgZoneOnStable` will use ZoneJS to determine when change detection might have run\n * in an application using ZoneJS to drive change detection. When the `NgZone.onStable` would\n * have emitted, all views attached to the `ApplicationRef` are checked for changes.\n * - 'exhaustive' means that all views attached to `ApplicationRef` and all the descendants of those views will be\n * checked for changes (excluding those subtrees which are detached via `ChangeDetectorRef.detach()`).\n * This is useful because the check that runs after regular change detection does not work for components using `ChangeDetectionStrategy.OnPush`.\n * This check is will surface any existing errors hidden by `OnPush` components. By default, this check is exhaustive\n * and will always check all views, regardless of their \"dirty\" state and `ChangeDetectionStrategy`.\n *\n * When the `useNgZoneOnStable` option is `true`, this function will provide its own `NgZone` implementation and needs\n * to come after any other `NgZone` provider, including `provideZoneChangeDetection()` and `provideExperimentalZonelessChangeDetection()`.\n *\n * @experimental\n * @publicApi\n */\nfunction provideExperimentalCheckNoChangesForDebug(options) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (options.interval === undefined && !options.useNgZoneOnStable) {\n throw new Error('Must provide one of `useNgZoneOnStable` or `interval`');\n }\n const checkNoChangesMode = options?.exhaustive === false ? CheckNoChangesMode.OnlyDirtyViews : CheckNoChangesMode.Exhaustive;\n return makeEnvironmentProviders([options?.useNgZoneOnStable ? {\n provide: NgZone,\n useFactory: () => new DebugNgZoneForCheckNoChanges(checkNoChangesMode)\n } : [], options?.interval !== undefined ? exhaustiveCheckNoChangesInterval(options.interval, checkNoChangesMode) : [], {\n provide: ENVIRONMENT_INITIALIZER,\n multi: true,\n useValue: () => {\n if (options?.useNgZoneOnStable && !(inject(NgZone) instanceof DebugNgZoneForCheckNoChanges)) {\n throw new Error('`provideExperimentalCheckNoChangesForDebug` with `useNgZoneOnStable` must be after any other provider for `NgZone`.');\n }\n }\n }]);\n } else {\n return makeEnvironmentProviders([]);\n }\n}\nclass DebugNgZoneForCheckNoChanges extends NgZone {\n checkNoChangesMode;\n applicationRef;\n scheduler;\n errorHandler;\n injector = inject(EnvironmentInjector);\n constructor(checkNoChangesMode) {\n const zonelessEnabled = inject(ZONELESS_ENABLED);\n // Use coalescing to ensure we aren't ever running this check synchronously\n super({\n shouldCoalesceEventChangeDetection: true,\n shouldCoalesceRunChangeDetection: zonelessEnabled\n });\n this.checkNoChangesMode = checkNoChangesMode;\n if (zonelessEnabled) {\n // prevent emits to ensure code doesn't rely on these\n this.onMicrotaskEmpty.emit = () => {};\n this.onStable.emit = () => {\n this.scheduler ||= this.injector.get(ChangeDetectionSchedulerImpl);\n if (this.scheduler.pendingRenderTaskId || this.scheduler.runningTick) {\n return;\n }\n this.checkApplicationViews();\n };\n this.onUnstable.emit = () => {};\n } else {\n this.runOutsideAngular(() => {\n this.onStable.subscribe(() => {\n this.checkApplicationViews();\n });\n });\n }\n }\n checkApplicationViews() {\n this.applicationRef ||= this.injector.get(ApplicationRef);\n for (const view of this.applicationRef.allViews) {\n try {\n checkNoChangesInternal(view._lView, this.checkNoChangesMode, view.notifyErrorHandler);\n } catch (e) {\n this.errorHandler ||= this.injector.get(ErrorHandler);\n this.errorHandler.handleError(e);\n }\n }\n }\n}\nfunction exhaustiveCheckNoChangesInterval(interval, checkNoChangesMode) {\n return {\n provide: ENVIRONMENT_INITIALIZER,\n multi: true,\n useFactory: () => {\n const applicationRef = inject(ApplicationRef);\n const errorHandler = inject(ErrorHandler);\n const scheduler = inject(ChangeDetectionSchedulerImpl);\n const ngZone = inject(NgZone);\n return () => {\n function scheduleCheckNoChanges() {\n ngZone.runOutsideAngular(() => {\n setTimeout(() => {\n if (applicationRef.destroyed) {\n return;\n }\n if (scheduler.pendingRenderTaskId || scheduler.runningTick) {\n scheduleCheckNoChanges();\n return;\n }\n for (const view of applicationRef.allViews) {\n try {\n checkNoChangesInternal(view._lView, checkNoChangesMode, view.notifyErrorHandler);\n } catch (e) {\n errorHandler.handleError(e);\n }\n }\n scheduleCheckNoChanges();\n }, interval);\n });\n }\n scheduleCheckNoChanges();\n };\n }\n };\n}\n\n/**\n * Returns whether Angular is in development mode.\n *\n * By default, this is true, unless `enableProdMode` is invoked prior to calling this method or the\n * application is built using the Angular CLI with the `optimization` option.\n * @see {@link /cli/build ng build}\n *\n * @publicApi\n */\nfunction isDevMode() {\n return typeof ngDevMode === 'undefined' || !!ngDevMode;\n}\n/**\n * Disable Angular's development mode, which turns off assertions and other\n * checks within the framework.\n *\n * One important assertion this disables verifies that a change detection pass\n * does not result in additional changes to any bindings (also known as\n * unidirectional data flow).\n *\n * Using this method is discouraged as the Angular CLI will set production mode when using the\n * `optimization` option.\n * @see {@link /cli/build ng build}\n *\n * @publicApi\n */\nfunction enableProdMode() {\n // The below check is there so when ngDevMode is set via terser\n // `global['ngDevMode'] = false;` is also dropped.\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n _global['ngDevMode'] = false;\n }\n}\n\n// Public API for render\n\n/**\n * Returns the NgModuleFactory with the given id (specified using [@NgModule.id\n * field](api/core/NgModule#id)), if it exists and has been loaded. Factories for NgModules that do\n * not specify an `id` cannot be retrieved. Throws if an NgModule cannot be found.\n * @publicApi\n * @deprecated Use `getNgModuleById` instead.\n */\nfunction getModuleFactory(id) {\n const type = getRegisteredNgModuleType(id);\n if (!type) throw noModuleError(id);\n return new NgModuleFactory(type);\n}\n/**\n * Returns the NgModule class with the given id (specified using [@NgModule.id\n * field](api/core/NgModule#id)), if it exists and has been loaded. Classes for NgModules that do\n * not specify an `id` cannot be retrieved. Throws if an NgModule cannot be found.\n * @publicApi\n */\nfunction getNgModuleById(id) {\n const type = getRegisteredNgModuleType(id);\n if (!type) throw noModuleError(id);\n return type;\n}\nfunction noModuleError(id) {\n return new Error(`No module with ID ${id} loaded`);\n}\n\n/**\n * Base class that provides change detection functionality.\n * A change-detection tree collects all views that are to be checked for changes.\n * Use the methods to add and remove views from the tree, initiate change-detection,\n * and explicitly mark views as _dirty_, meaning that they have changed and need to be re-rendered.\n *\n * @see [Using change detection hooks](guide/components/lifecycle#using-change-detection-hooks)\n * @see [Defining custom change detection](guide/components/lifecycle#defining-custom-change-detection)\n *\n * @usageNotes\n *\n * The following examples demonstrate how to modify default change-detection behavior\n * to perform explicit detection when needed.\n *\n * ### Use `markForCheck()` with `CheckOnce` strategy\n *\n * The following example sets the `OnPush` change-detection strategy for a component\n * (`CheckOnce`, rather than the default `CheckAlways`), then forces a second check\n * after an interval.\n *\n * {@example core/ts/change_detect/change-detection.ts region='mark-for-check'}\n *\n * ### Detach change detector to limit how often check occurs\n *\n * The following example defines a component with a large list of read-only data\n * that is expected to change constantly, many times per second.\n * To improve performance, we want to check and update the list\n * less often than the changes actually occur. To do that, we detach\n * the component's change detector and perform an explicit local check every five seconds.\n *\n * {@example core/ts/change_detect/change-detection.ts region='detach'}\n *\n *\n * ### Reattaching a detached component\n *\n * The following example creates a component displaying live data.\n * The component detaches its change detector from the main change detector tree\n * when the `live` property is set to false, and reattaches it when the property\n * becomes true.\n *\n * {@example core/ts/change_detect/change-detection.ts region='reattach'}\n *\n * @publicApi\n */\nclass ChangeDetectorRef {\n /**\n * @internal\n * @nocollapse\n */\n static __NG_ELEMENT_ID__ = injectChangeDetectorRef;\n}\n/** Returns a ChangeDetectorRef (a.k.a. a ViewRef) */\nfunction injectChangeDetectorRef(flags) {\n return createViewRef(getCurrentTNode(), getLView(), (flags & 16 /* InternalInjectFlags.ForPipe */) === 16 /* InternalInjectFlags.ForPipe */);\n}\n/**\n * Creates a ViewRef and stores it on the injector as ChangeDetectorRef (public alias).\n *\n * @param tNode The node that is requesting a ChangeDetectorRef\n * @param lView The view to which the node belongs\n * @param isPipe Whether the view is being injected into a pipe.\n * @returns The ChangeDetectorRef to use\n */\nfunction createViewRef(tNode, lView, isPipe) {\n if (isComponentHost(tNode) && !isPipe) {\n // The LView represents the location where the component is declared.\n // Instead we want the LView for the component View and so we need to look it up.\n const componentView = getComponentLViewByIndex(tNode.index, lView); // look down\n return new ViewRef$1(componentView, componentView);\n } else if (tNode.type & (3 /* TNodeType.AnyRNode */ | 12 /* TNodeType.AnyContainer */ | 32 /* TNodeType.Icu */ | 128 /* TNodeType.LetDeclaration */)) {\n // The LView represents the location where the injection is requested from.\n // We need to locate the containing LView (in case where the `lView` is an embedded view)\n const hostComponentView = lView[DECLARATION_COMPONENT_VIEW]; // look up\n return new ViewRef$1(hostComponentView, lView);\n }\n return null;\n}\n\n/**\n * Represents an Angular view.\n *\n * @see {@link /api/core/ChangeDetectorRef?tab=usage-notes Change detection usage}\n *\n * @publicApi\n */\nclass ViewRef extends ChangeDetectorRef {}\n/**\n * Represents an Angular view in a view container.\n * An embedded view can be referenced from a component\n * other than the hosting component whose template defines it, or it can be defined\n * independently by a `TemplateRef`.\n *\n * Properties of elements in a view can change, but the structure (number and order) of elements in\n * a view cannot. Change the structure of elements by inserting, moving, or\n * removing nested views in a view container.\n *\n * @see {@link ViewContainerRef}\n *\n * @usageNotes\n *\n * The following template breaks down into two separate `TemplateRef` instances,\n * an outer one and an inner one.\n *\n * ```html\n * Count: {{items.length}}\n * <ul>\n * <li *ngFor=\"let item of items\">{{item}}</li>\n * </ul>\n * ```\n *\n * This is the outer `TemplateRef`:\n *\n * ```html\n * Count: {{items.length}}\n * <ul>\n * <ng-template ngFor let-item [ngForOf]=\"items\"></ng-template>\n * </ul>\n * ```\n *\n * This is the inner `TemplateRef`:\n *\n * ```html\n * <li>{{item}}</li>\n * ```\n *\n * The outer and inner `TemplateRef` instances are assembled into views as follows:\n *\n * ```html\n * <!-- ViewRef: outer-0 -->\n * Count: 2\n * <ul>\n * <ng-template view-container-ref></ng-template>\n * <!-- ViewRef: inner-1 --><li>first</li><!-- /ViewRef: inner-1 -->\n * <!-- ViewRef: inner-2 --><li>second</li><!-- /ViewRef: inner-2 -->\n * </ul>\n * <!-- /ViewRef: outer-0 -->\n * ```\n * @publicApi\n */\nclass EmbeddedViewRef extends ViewRef {}\n\n// Public API for compiler\n\n// This file exists for easily patching NgModuleFactoryLoader in g3\nvar ng_module_factory_loader_impl = {};\n\n/**\n * @publicApi\n */\nclass DebugEventListener {\n name;\n callback;\n constructor(name, callback) {\n this.name = name;\n this.callback = callback;\n }\n}\n/**\n * @publicApi\n */\nfunction asNativeElements(debugEls) {\n return debugEls.map(el => el.nativeElement);\n}\n/**\n * @publicApi\n */\nclass DebugNode {\n /**\n * The underlying DOM node.\n */\n nativeNode;\n constructor(nativeNode) {\n this.nativeNode = nativeNode;\n }\n /**\n * The `DebugElement` parent. Will be `null` if this is the root element.\n */\n get parent() {\n const parent = this.nativeNode.parentNode;\n return parent ? new DebugElement(parent) : null;\n }\n /**\n * The host dependency injector. For example, the root element's component instance injector.\n */\n get injector() {\n return getInjector(this.nativeNode);\n }\n /**\n * The element's own component instance, if it has one.\n */\n get componentInstance() {\n const nativeElement = this.nativeNode;\n return nativeElement && (getComponent(nativeElement) || getOwningComponent(nativeElement));\n }\n /**\n * An object that provides parent context for this element. Often an ancestor component instance\n * that governs this element.\n *\n * When an element is repeated within *ngFor, the context is an `NgForOf` whose `$implicit`\n * property is the value of the row instance value. For example, the `hero` in `*ngFor=\"let hero\n * of heroes\"`.\n */\n get context() {\n return getComponent(this.nativeNode) || getContext(this.nativeNode);\n }\n /**\n * The callbacks attached to the component's @Output properties and/or the element's event\n * properties.\n */\n get listeners() {\n return getListeners(this.nativeNode).filter(listener => listener.type === 'dom');\n }\n /**\n * Dictionary of objects associated with template local variables (e.g. #foo), keyed by the local\n * variable name.\n */\n get references() {\n return getLocalRefs(this.nativeNode);\n }\n /**\n * This component's injector lookup tokens. Includes the component itself plus the tokens that the\n * component lists in its providers metadata.\n */\n get providerTokens() {\n return getInjectionTokens(this.nativeNode);\n }\n}\n/**\n * @publicApi\n *\n * @see [Component testing scenarios](guide/testing/components-scenarios)\n * @see [Basics of testing components](guide/testing/components-basics)\n * @see [Testing utility APIs](guide/testing/utility-apis)\n */\nclass DebugElement extends DebugNode {\n constructor(nativeNode) {\n ngDevMode && assertDomNode(nativeNode);\n super(nativeNode);\n }\n /**\n * The underlying DOM element at the root of the component.\n */\n get nativeElement() {\n return this.nativeNode.nodeType == Node.ELEMENT_NODE ? this.nativeNode : null;\n }\n /**\n * The element tag name, if it is an element.\n */\n get name() {\n const context = getLContext(this.nativeNode);\n const lView = context ? context.lView : null;\n if (lView !== null) {\n const tData = lView[TVIEW].data;\n const tNode = tData[context.nodeIndex];\n return tNode.value;\n } else {\n return this.nativeNode.nodeName;\n }\n }\n /**\n * Gets a map of property names to property values for an element.\n *\n * This map includes:\n * - Regular property bindings (e.g. `[id]=\"id\"`)\n * - Host property bindings (e.g. `host: { '[id]': \"id\" }`)\n * - Interpolated property bindings (e.g. `id=\"{{ value }}\")\n *\n * It does not include:\n * - input property bindings (e.g. `[myCustomInput]=\"value\"`)\n * - attribute bindings (e.g. `[attr.role]=\"menu\"`)\n */\n get properties() {\n const context = getLContext(this.nativeNode);\n const lView = context ? context.lView : null;\n if (lView === null) {\n return {};\n }\n const tData = lView[TVIEW].data;\n const tNode = tData[context.nodeIndex];\n const properties = {};\n // Collect properties from the DOM.\n copyDomProperties(this.nativeElement, properties);\n // Collect properties from the bindings. This is needed for animation renderer which has\n // synthetic properties which don't get reflected into the DOM.\n collectPropertyBindings(properties, tNode, lView, tData);\n return properties;\n }\n /**\n * A map of attribute names to attribute values for an element.\n */\n // TODO: replace null by undefined in the return type\n get attributes() {\n const attributes = {};\n const element = this.nativeElement;\n if (!element) {\n return attributes;\n }\n const context = getLContext(element);\n const lView = context ? context.lView : null;\n if (lView === null) {\n return {};\n }\n const tNodeAttrs = lView[TVIEW].data[context.nodeIndex].attrs;\n const lowercaseTNodeAttrs = [];\n // For debug nodes we take the element's attribute directly from the DOM since it allows us\n // to account for ones that weren't set via bindings (e.g. ViewEngine keeps track of the ones\n // that are set through `Renderer2`). The problem is that the browser will lowercase all names,\n // however since we have the attributes already on the TNode, we can preserve the case by going\n // through them once, adding them to the `attributes` map and putting their lower-cased name\n // into an array. Afterwards when we're going through the native DOM attributes, we can check\n // whether we haven't run into an attribute already through the TNode.\n if (tNodeAttrs) {\n let i = 0;\n while (i < tNodeAttrs.length) {\n const attrName = tNodeAttrs[i];\n // Stop as soon as we hit a marker. We only care about the regular attributes. Everything\n // else will be handled below when we read the final attributes off the DOM.\n if (typeof attrName !== 'string') break;\n const attrValue = tNodeAttrs[i + 1];\n attributes[attrName] = attrValue;\n lowercaseTNodeAttrs.push(attrName.toLowerCase());\n i += 2;\n }\n }\n for (const attr of element.attributes) {\n // Make sure that we don't assign the same attribute both in its\n // case-sensitive form and the lower-cased one from the browser.\n if (!lowercaseTNodeAttrs.includes(attr.name)) {\n attributes[attr.name] = attr.value;\n }\n }\n return attributes;\n }\n /**\n * The inline styles of the DOM element.\n */\n // TODO: replace null by undefined in the return type\n get styles() {\n const element = this.nativeElement;\n return element?.style ?? {};\n }\n /**\n * A map containing the class names on the element as keys.\n *\n * This map is derived from the `className` property of the DOM element.\n *\n * Note: The values of this object will always be `true`. The class key will not appear in the KV\n * object if it does not exist on the element.\n *\n * @see [Element.className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className)\n */\n get classes() {\n const result = {};\n const element = this.nativeElement;\n // SVG elements return an `SVGAnimatedString` instead of a plain string for the `className`.\n const className = element.className;\n const classes = typeof className !== 'string' ? className.baseVal.split(' ') : className.split(' ');\n classes.forEach(value => result[value] = true);\n return result;\n }\n /**\n * The `childNodes` of the DOM element as a `DebugNode` array.\n *\n * @see [Node.childNodes](https://developer.mozilla.org/en-US/docs/Web/API/Node/childNodes)\n */\n get childNodes() {\n const childNodes = this.nativeNode.childNodes;\n const children = [];\n for (let i = 0; i < childNodes.length; i++) {\n const element = childNodes[i];\n children.push(getDebugNode(element));\n }\n return children;\n }\n /**\n * The immediate `DebugElement` children. Walk the tree by descending through `children`.\n */\n get children() {\n const nativeElement = this.nativeElement;\n if (!nativeElement) return [];\n const childNodes = nativeElement.children;\n const children = [];\n for (let i = 0; i < childNodes.length; i++) {\n const element = childNodes[i];\n children.push(getDebugNode(element));\n }\n return children;\n }\n /**\n * @returns the first `DebugElement` that matches the predicate at any depth in the subtree.\n */\n query(predicate) {\n const results = this.queryAll(predicate);\n return results[0] || null;\n }\n /**\n * @returns All `DebugElement` matches for the predicate at any depth in the subtree.\n */\n queryAll(predicate) {\n const matches = [];\n _queryAll(this, predicate, matches, true);\n return matches;\n }\n /**\n * @returns All `DebugNode` matches for the predicate at any depth in the subtree.\n */\n queryAllNodes(predicate) {\n const matches = [];\n _queryAll(this, predicate, matches, false);\n return matches;\n }\n /**\n * Triggers the event by its name if there is a corresponding listener in the element's\n * `listeners` collection.\n *\n * If the event lacks a listener or there's some other problem, consider\n * calling `nativeElement.dispatchEvent(eventObject)`.\n *\n * @param eventName The name of the event to trigger\n * @param eventObj The _event object_ expected by the handler\n *\n * @see [Testing components scenarios](guide/testing/components-scenarios#trigger-event-handler)\n */\n triggerEventHandler(eventName, eventObj) {\n const node = this.nativeNode;\n const invokedListeners = [];\n this.listeners.forEach(listener => {\n if (listener.name === eventName) {\n const callback = listener.callback;\n callback.call(node, eventObj);\n invokedListeners.push(callback);\n }\n });\n // We need to check whether `eventListeners` exists, because it's something\n // that Zone.js only adds to `EventTarget` in browser environments.\n if (typeof node.eventListeners === 'function') {\n // Note that in Ivy we wrap event listeners with a call to `event.preventDefault` in some\n // cases. We use '__ngUnwrap__' as a special token that gives us access to the actual event\n // listener.\n node.eventListeners(eventName).forEach(listener => {\n // In order to ensure that we can detect the special __ngUnwrap__ token described above, we\n // use `toString` on the listener and see if it contains the token. We use this approach to\n // ensure that it still worked with compiled code since it cannot remove or rename string\n // literals. We also considered using a special function name (i.e. if(listener.name ===\n // special)) but that was more cumbersome and we were also concerned the compiled code could\n // strip the name, turning the condition in to (\"\" === \"\") and always returning true.\n if (listener.toString().indexOf('__ngUnwrap__') !== -1) {\n const unwrappedListener = listener('__ngUnwrap__');\n return invokedListeners.indexOf(unwrappedListener) === -1 && unwrappedListener.call(node, eventObj);\n }\n });\n }\n }\n}\nfunction copyDomProperties(element, properties) {\n if (element) {\n // Skip own properties (as those are patched)\n let obj = Object.getPrototypeOf(element);\n const NodePrototype = Node.prototype;\n while (obj !== null && obj !== NodePrototype) {\n const descriptors = Object.getOwnPropertyDescriptors(obj);\n for (let key in descriptors) {\n if (!key.startsWith('__') && !key.startsWith('on')) {\n // don't include properties starting with `__` and `on`.\n // `__` are patched values which should not be included.\n // `on` are listeners which also should not be included.\n const value = element[key];\n if (isPrimitiveValue(value)) {\n properties[key] = value;\n }\n }\n }\n obj = Object.getPrototypeOf(obj);\n }\n }\n}\nfunction isPrimitiveValue(value) {\n return typeof value === 'string' || typeof value === 'boolean' || typeof value === 'number' || value === null;\n}\nfunction _queryAll(parentElement, predicate, matches, elementsOnly) {\n const context = getLContext(parentElement.nativeNode);\n const lView = context ? context.lView : null;\n if (lView !== null) {\n const parentTNode = lView[TVIEW].data[context.nodeIndex];\n _queryNodeChildren(parentTNode, lView, predicate, matches, elementsOnly, parentElement.nativeNode);\n } else {\n // If the context is null, then `parentElement` was either created with Renderer2 or native DOM\n // APIs.\n _queryNativeNodeDescendants(parentElement.nativeNode, predicate, matches, elementsOnly);\n }\n}\n/**\n * Recursively match the current TNode against the predicate, and goes on with the next ones.\n *\n * @param tNode the current TNode\n * @param lView the LView of this TNode\n * @param predicate the predicate to match\n * @param matches the list of positive matches\n * @param elementsOnly whether only elements should be searched\n * @param rootNativeNode the root native node on which predicate should not be matched\n */\nfunction _queryNodeChildren(tNode, lView, predicate, matches, elementsOnly, rootNativeNode) {\n ngDevMode && assertTNodeForLView(tNode, lView);\n const nativeNode = getNativeByTNodeOrNull(tNode, lView);\n // For each type of TNode, specific logic is executed.\n if (tNode.type & (3 /* TNodeType.AnyRNode */ | 8 /* TNodeType.ElementContainer */)) {\n // Case 1: the TNode is an element\n // The native node has to be checked.\n _addQueryMatch(nativeNode, predicate, matches, elementsOnly, rootNativeNode);\n if (isComponentHost(tNode)) {\n // If the element is the host of a component, then all nodes in its view have to be processed.\n // Note: the component's content (tNode.child) will be processed from the insertion points.\n const componentView = getComponentLViewByIndex(tNode.index, lView);\n if (componentView && componentView[TVIEW].firstChild) {\n _queryNodeChildren(componentView[TVIEW].firstChild, componentView, predicate, matches, elementsOnly, rootNativeNode);\n }\n } else {\n if (tNode.child) {\n // Otherwise, its children have to be processed.\n _queryNodeChildren(tNode.child, lView, predicate, matches, elementsOnly, rootNativeNode);\n }\n // We also have to query the DOM directly in order to catch elements inserted through\n // Renderer2. Note that this is __not__ optimal, because we're walking similar trees multiple\n // times. ViewEngine could do it more efficiently, because all the insertions go through\n // Renderer2, however that's not the case in Ivy. This approach is being used because:\n // 1. Matching the ViewEngine behavior would mean potentially introducing a dependency\n // from `Renderer2` to Ivy which could bring Ivy code into ViewEngine.\n // 2. It allows us to capture nodes that were inserted directly via the DOM.\n nativeNode && _queryNativeNodeDescendants(nativeNode, predicate, matches, elementsOnly);\n }\n // In all cases, if a dynamic container exists for this node, each view inside it has to be\n // processed.\n const nodeOrContainer = lView[tNode.index];\n if (isLContainer(nodeOrContainer)) {\n _queryNodeChildrenInContainer(nodeOrContainer, predicate, matches, elementsOnly, rootNativeNode);\n }\n } else if (tNode.type & 4 /* TNodeType.Container */) {\n // Case 2: the TNode is a container\n // The native node has to be checked.\n const lContainer = lView[tNode.index];\n _addQueryMatch(lContainer[NATIVE], predicate, matches, elementsOnly, rootNativeNode);\n // Each view inside the container has to be processed.\n _queryNodeChildrenInContainer(lContainer, predicate, matches, elementsOnly, rootNativeNode);\n } else if (tNode.type & 16 /* TNodeType.Projection */) {\n // Case 3: the TNode is a projection insertion point (i.e. a <ng-content>).\n // The nodes projected at this location all need to be processed.\n const componentView = lView[DECLARATION_COMPONENT_VIEW];\n const componentHost = componentView[T_HOST];\n const head = componentHost.projection[tNode.projection];\n if (Array.isArray(head)) {\n for (let nativeNode of head) {\n _addQueryMatch(nativeNode, predicate, matches, elementsOnly, rootNativeNode);\n }\n } else if (head) {\n const nextLView = componentView[PARENT];\n const nextTNode = nextLView[TVIEW].data[head.index];\n _queryNodeChildren(nextTNode, nextLView, predicate, matches, elementsOnly, rootNativeNode);\n }\n } else if (tNode.child) {\n // Case 4: the TNode is a view.\n _queryNodeChildren(tNode.child, lView, predicate, matches, elementsOnly, rootNativeNode);\n }\n // We don't want to go to the next sibling of the root node.\n if (rootNativeNode !== nativeNode) {\n // To determine the next node to be processed, we need to use the next or the projectionNext\n // link, depending on whether the current node has been projected.\n const nextTNode = tNode.flags & 2 /* TNodeFlags.isProjected */ ? tNode.projectionNext : tNode.next;\n if (nextTNode) {\n _queryNodeChildren(nextTNode, lView, predicate, matches, elementsOnly, rootNativeNode);\n }\n }\n}\n/**\n * Process all TNodes in a given container.\n *\n * @param lContainer the container to be processed\n * @param predicate the predicate to match\n * @param matches the list of positive matches\n * @param elementsOnly whether only elements should be searched\n * @param rootNativeNode the root native node on which predicate should not be matched\n */\nfunction _queryNodeChildrenInContainer(lContainer, predicate, matches, elementsOnly, rootNativeNode) {\n for (let i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {\n const childView = lContainer[i];\n const firstChild = childView[TVIEW].firstChild;\n if (firstChild) {\n _queryNodeChildren(firstChild, childView, predicate, matches, elementsOnly, rootNativeNode);\n }\n }\n}\n/**\n * Match the current native node against the predicate.\n *\n * @param nativeNode the current native node\n * @param predicate the predicate to match\n * @param matches the list of positive matches\n * @param elementsOnly whether only elements should be searched\n * @param rootNativeNode the root native node on which predicate should not be matched\n */\nfunction _addQueryMatch(nativeNode, predicate, matches, elementsOnly, rootNativeNode) {\n if (rootNativeNode !== nativeNode) {\n const debugNode = getDebugNode(nativeNode);\n if (!debugNode) {\n return;\n }\n // Type of the \"predicate and \"matches\" array are set based on the value of\n // the \"elementsOnly\" parameter. TypeScript is not able to properly infer these\n // types with generics, so we manually cast the parameters accordingly.\n if (elementsOnly && debugNode instanceof DebugElement && predicate(debugNode) && matches.indexOf(debugNode) === -1) {\n matches.push(debugNode);\n } else if (!elementsOnly && predicate(debugNode) && matches.indexOf(debugNode) === -1) {\n matches.push(debugNode);\n }\n }\n}\n/**\n * Match all the descendants of a DOM node against a predicate.\n *\n * @param nativeNode the current native node\n * @param predicate the predicate to match\n * @param matches the list where matches are stored\n * @param elementsOnly whether only elements should be searched\n */\nfunction _queryNativeNodeDescendants(parentNode, predicate, matches, elementsOnly) {\n const nodes = parentNode.childNodes;\n const length = nodes.length;\n for (let i = 0; i < length; i++) {\n const node = nodes[i];\n const debugNode = getDebugNode(node);\n if (debugNode) {\n if (elementsOnly && debugNode instanceof DebugElement && predicate(debugNode) && matches.indexOf(debugNode) === -1) {\n matches.push(debugNode);\n } else if (!elementsOnly && predicate(debugNode) && matches.indexOf(debugNode) === -1) {\n matches.push(debugNode);\n }\n _queryNativeNodeDescendants(node, predicate, matches, elementsOnly);\n }\n }\n}\n/**\n * Iterates through the property bindings for a given node and generates\n * a map of property names to values. This map only contains property bindings\n * defined in templates, not in host bindings.\n */\nfunction collectPropertyBindings(properties, tNode, lView, tData) {\n let bindingIndexes = tNode.propertyBindings;\n if (bindingIndexes !== null) {\n for (let i = 0; i < bindingIndexes.length; i++) {\n const bindingIndex = bindingIndexes[i];\n const propMetadata = tData[bindingIndex];\n const metadataParts = propMetadata.split(INTERPOLATION_DELIMITER);\n const propertyName = metadataParts[0];\n if (metadataParts.length > 1) {\n let value = metadataParts[1];\n for (let j = 1; j < metadataParts.length - 1; j++) {\n value += renderStringify(lView[bindingIndex + j - 1]) + metadataParts[j + 1];\n }\n properties[propertyName] = value;\n } else {\n properties[propertyName] = lView[bindingIndex];\n }\n }\n }\n}\n// Need to keep the nodes in a global Map so that multiple angular apps are supported.\nconst _nativeNodeToDebugNode = new Map();\nconst NG_DEBUG_PROPERTY = '__ng_debug__';\n/**\n * @publicApi\n */\nfunction getDebugNode(nativeNode) {\n if (nativeNode instanceof Node) {\n if (!nativeNode.hasOwnProperty(NG_DEBUG_PROPERTY)) {\n nativeNode[NG_DEBUG_PROPERTY] = nativeNode.nodeType == Node.ELEMENT_NODE ? new DebugElement(nativeNode) : new DebugNode(nativeNode);\n }\n return nativeNode[NG_DEBUG_PROPERTY];\n }\n return null;\n}\nfunction getAllDebugNodes() {\n return Array.from(_nativeNodeToDebugNode.values());\n}\nfunction indexDebugNode(node) {\n _nativeNodeToDebugNode.set(node.nativeNode, node);\n}\nfunction removeDebugNodeFromIndex(node) {\n _nativeNodeToDebugNode.delete(node.nativeNode);\n}\nclass DefaultIterableDifferFactory {\n constructor() {}\n supports(obj) {\n return isListLikeIterable(obj);\n }\n create(trackByFn) {\n return new DefaultIterableDiffer(trackByFn);\n }\n}\nconst trackByIdentity = (index, item) => item;\n/**\n * @deprecated v4.0.0 - Should not be part of public API.\n * @publicApi\n */\nclass DefaultIterableDiffer {\n length = 0;\n // TODO: confirm the usage of `collection` as it's unused, readonly and on a non public API.\n collection;\n // Keeps track of the used records at any point in time (during & across `_check()` calls)\n _linkedRecords = null;\n // Keeps track of the removed records at any point in time during `_check()` calls.\n _unlinkedRecords = null;\n _previousItHead = null;\n _itHead = null;\n _itTail = null;\n _additionsHead = null;\n _additionsTail = null;\n _movesHead = null;\n _movesTail = null;\n _removalsHead = null;\n _removalsTail = null;\n // Keeps track of records where custom track by is the same, but item identity has changed\n _identityChangesHead = null;\n _identityChangesTail = null;\n _trackByFn;\n constructor(trackByFn) {\n this._trackByFn = trackByFn || trackByIdentity;\n }\n forEachItem(fn) {\n let record;\n for (record = this._itHead; record !== null; record = record._next) {\n fn(record);\n }\n }\n forEachOperation(fn) {\n let nextIt = this._itHead;\n let nextRemove = this._removalsHead;\n let addRemoveOffset = 0;\n let moveOffsets = null;\n while (nextIt || nextRemove) {\n // Figure out which is the next record to process\n // Order: remove, add, move\n const record = !nextRemove || nextIt && nextIt.currentIndex < getPreviousIndex(nextRemove, addRemoveOffset, moveOffsets) ? nextIt : nextRemove;\n const adjPreviousIndex = getPreviousIndex(record, addRemoveOffset, moveOffsets);\n const currentIndex = record.currentIndex;\n // consume the item, and adjust the addRemoveOffset and update moveDistance if necessary\n if (record === nextRemove) {\n addRemoveOffset--;\n nextRemove = nextRemove._nextRemoved;\n } else {\n nextIt = nextIt._next;\n if (record.previousIndex == null) {\n addRemoveOffset++;\n } else {\n // INVARIANT: currentIndex < previousIndex\n if (!moveOffsets) moveOffsets = [];\n const localMovePreviousIndex = adjPreviousIndex - addRemoveOffset;\n const localCurrentIndex = currentIndex - addRemoveOffset;\n if (localMovePreviousIndex != localCurrentIndex) {\n for (let i = 0; i < localMovePreviousIndex; i++) {\n const offset = i < moveOffsets.length ? moveOffsets[i] : moveOffsets[i] = 0;\n const index = offset + i;\n if (localCurrentIndex <= index && index < localMovePreviousIndex) {\n moveOffsets[i] = offset + 1;\n }\n }\n const previousIndex = record.previousIndex;\n moveOffsets[previousIndex] = localCurrentIndex - localMovePreviousIndex;\n }\n }\n }\n if (adjPreviousIndex !== currentIndex) {\n fn(record, adjPreviousIndex, currentIndex);\n }\n }\n }\n forEachPreviousItem(fn) {\n let record;\n for (record = this._previousItHead; record !== null; record = record._nextPrevious) {\n fn(record);\n }\n }\n forEachAddedItem(fn) {\n let record;\n for (record = this._additionsHead; record !== null; record = record._nextAdded) {\n fn(record);\n }\n }\n forEachMovedItem(fn) {\n let record;\n for (record = this._movesHead; record !== null; record = record._nextMoved) {\n fn(record);\n }\n }\n forEachRemovedItem(fn) {\n let record;\n for (record = this._removalsHead; record !== null; record = record._nextRemoved) {\n fn(record);\n }\n }\n forEachIdentityChange(fn) {\n let record;\n for (record = this._identityChangesHead; record !== null; record = record._nextIdentityChange) {\n fn(record);\n }\n }\n diff(collection) {\n if (collection == null) collection = [];\n if (!isListLikeIterable(collection)) {\n throw new RuntimeError(900 /* RuntimeErrorCode.INVALID_DIFFER_INPUT */, ngDevMode && `Error trying to diff '${stringify(collection)}'. Only arrays and iterables are allowed`);\n }\n if (this.check(collection)) {\n return this;\n } else {\n return null;\n }\n }\n onDestroy() {}\n check(collection) {\n this._reset();\n let record = this._itHead;\n let mayBeDirty = false;\n let index;\n let item;\n let itemTrackBy;\n if (Array.isArray(collection)) {\n this.length = collection.length;\n for (let index = 0; index < this.length; index++) {\n item = collection[index];\n itemTrackBy = this._trackByFn(index, item);\n if (record === null || !Object.is(record.trackById, itemTrackBy)) {\n record = this._mismatch(record, item, itemTrackBy, index);\n mayBeDirty = true;\n } else {\n if (mayBeDirty) {\n // TODO(misko): can we limit this to duplicates only?\n record = this._verifyReinsertion(record, item, itemTrackBy, index);\n }\n if (!Object.is(record.item, item)) this._addIdentityChange(record, item);\n }\n record = record._next;\n }\n } else {\n index = 0;\n iterateListLike(collection, item => {\n itemTrackBy = this._trackByFn(index, item);\n if (record === null || !Object.is(record.trackById, itemTrackBy)) {\n record = this._mismatch(record, item, itemTrackBy, index);\n mayBeDirty = true;\n } else {\n if (mayBeDirty) {\n // TODO(misko): can we limit this to duplicates only?\n record = this._verifyReinsertion(record, item, itemTrackBy, index);\n }\n if (!Object.is(record.item, item)) this._addIdentityChange(record, item);\n }\n record = record._next;\n index++;\n });\n this.length = index;\n }\n this._truncate(record);\n this.collection = collection;\n return this.isDirty;\n }\n /* CollectionChanges is considered dirty if it has any additions, moves, removals, or identity\n * changes.\n */\n get isDirty() {\n return this._additionsHead !== null || this._movesHead !== null || this._removalsHead !== null || this._identityChangesHead !== null;\n }\n /**\n * Reset the state of the change objects to show no changes. This means set previousKey to\n * currentKey, and clear all of the queues (additions, moves, removals).\n * Set the previousIndexes of moved and added items to their currentIndexes\n * Reset the list of additions, moves and removals\n *\n * @internal\n */\n _reset() {\n if (this.isDirty) {\n let record;\n for (record = this._previousItHead = this._itHead; record !== null; record = record._next) {\n record._nextPrevious = record._next;\n }\n for (record = this._additionsHead; record !== null; record = record._nextAdded) {\n record.previousIndex = record.currentIndex;\n }\n this._additionsHead = this._additionsTail = null;\n for (record = this._movesHead; record !== null; record = record._nextMoved) {\n record.previousIndex = record.currentIndex;\n }\n this._movesHead = this._movesTail = null;\n this._removalsHead = this._removalsTail = null;\n this._identityChangesHead = this._identityChangesTail = null;\n // TODO(vicb): when assert gets supported\n // assert(!this.isDirty);\n }\n }\n /**\n * This is the core function which handles differences between collections.\n *\n * - `record` is the record which we saw at this position last time. If null then it is a new\n * item.\n * - `item` is the current item in the collection\n * - `index` is the position of the item in the collection\n *\n * @internal\n */\n _mismatch(record, item, itemTrackBy, index) {\n // The previous record after which we will append the current one.\n let previousRecord;\n if (record === null) {\n previousRecord = this._itTail;\n } else {\n previousRecord = record._prev;\n // Remove the record from the collection since we know it does not match the item.\n this._remove(record);\n }\n // See if we have evicted the item, which used to be at some anterior position of _itHead list.\n record = this._unlinkedRecords === null ? null : this._unlinkedRecords.get(itemTrackBy, null);\n if (record !== null) {\n // It is an item which we have evicted earlier: reinsert it back into the list.\n // But first we need to check if identity changed, so we can update in view if necessary.\n if (!Object.is(record.item, item)) this._addIdentityChange(record, item);\n this._reinsertAfter(record, previousRecord, index);\n } else {\n // Attempt to see if the item is at some posterior position of _itHead list.\n record = this._linkedRecords === null ? null : this._linkedRecords.get(itemTrackBy, index);\n if (record !== null) {\n // We have the item in _itHead at/after `index` position. We need to move it forward in the\n // collection.\n // But first we need to check if identity changed, so we can update in view if necessary.\n if (!Object.is(record.item, item)) this._addIdentityChange(record, item);\n this._moveAfter(record, previousRecord, index);\n } else {\n // It is a new item: add it.\n record = this._addAfter(new IterableChangeRecord_(item, itemTrackBy), previousRecord, index);\n }\n }\n return record;\n }\n /**\n * This check is only needed if an array contains duplicates. (Short circuit of nothing dirty)\n *\n * Use case: `[a, a]` => `[b, a, a]`\n *\n * If we did not have this check then the insertion of `b` would:\n * 1) evict first `a`\n * 2) insert `b` at `0` index.\n * 3) leave `a` at index `1` as is. <-- this is wrong!\n * 3) reinsert `a` at index 2. <-- this is wrong!\n *\n * The correct behavior is:\n * 1) evict first `a`\n * 2) insert `b` at `0` index.\n * 3) reinsert `a` at index 1.\n * 3) move `a` at from `1` to `2`.\n *\n *\n * Double check that we have not evicted a duplicate item. We need to check if the item type may\n * have already been removed:\n * The insertion of b will evict the first 'a'. If we don't reinsert it now it will be reinserted\n * at the end. Which will show up as the two 'a's switching position. This is incorrect, since a\n * better way to think of it is as insert of 'b' rather then switch 'a' with 'b' and then add 'a'\n * at the end.\n *\n * @internal\n */\n _verifyReinsertion(record, item, itemTrackBy, index) {\n let reinsertRecord = this._unlinkedRecords === null ? null : this._unlinkedRecords.get(itemTrackBy, null);\n if (reinsertRecord !== null) {\n record = this._reinsertAfter(reinsertRecord, record._prev, index);\n } else if (record.currentIndex != index) {\n record.currentIndex = index;\n this._addToMoves(record, index);\n }\n return record;\n }\n /**\n * Get rid of any excess {@link IterableChangeRecord_}s from the previous collection\n *\n * - `record` The first excess {@link IterableChangeRecord_}.\n *\n * @internal\n */\n _truncate(record) {\n // Anything after that needs to be removed;\n while (record !== null) {\n const nextRecord = record._next;\n this._addToRemovals(this._unlink(record));\n record = nextRecord;\n }\n if (this._unlinkedRecords !== null) {\n this._unlinkedRecords.clear();\n }\n if (this._additionsTail !== null) {\n this._additionsTail._nextAdded = null;\n }\n if (this._movesTail !== null) {\n this._movesTail._nextMoved = null;\n }\n if (this._itTail !== null) {\n this._itTail._next = null;\n }\n if (this._removalsTail !== null) {\n this._removalsTail._nextRemoved = null;\n }\n if (this._identityChangesTail !== null) {\n this._identityChangesTail._nextIdentityChange = null;\n }\n }\n /** @internal */\n _reinsertAfter(record, prevRecord, index) {\n if (this._unlinkedRecords !== null) {\n this._unlinkedRecords.remove(record);\n }\n const prev = record._prevRemoved;\n const next = record._nextRemoved;\n if (prev === null) {\n this._removalsHead = next;\n } else {\n prev._nextRemoved = next;\n }\n if (next === null) {\n this._removalsTail = prev;\n } else {\n next._prevRemoved = prev;\n }\n this._insertAfter(record, prevRecord, index);\n this._addToMoves(record, index);\n return record;\n }\n /** @internal */\n _moveAfter(record, prevRecord, index) {\n this._unlink(record);\n this._insertAfter(record, prevRecord, index);\n this._addToMoves(record, index);\n return record;\n }\n /** @internal */\n _addAfter(record, prevRecord, index) {\n this._insertAfter(record, prevRecord, index);\n if (this._additionsTail === null) {\n // TODO(vicb):\n // assert(this._additionsHead === null);\n this._additionsTail = this._additionsHead = record;\n } else {\n // TODO(vicb):\n // assert(_additionsTail._nextAdded === null);\n // assert(record._nextAdded === null);\n this._additionsTail = this._additionsTail._nextAdded = record;\n }\n return record;\n }\n /** @internal */\n _insertAfter(record, prevRecord, index) {\n // TODO(vicb):\n // assert(record != prevRecord);\n // assert(record._next === null);\n // assert(record._prev === null);\n const next = prevRecord === null ? this._itHead : prevRecord._next;\n // TODO(vicb):\n // assert(next != record);\n // assert(prevRecord != record);\n record._next = next;\n record._prev = prevRecord;\n if (next === null) {\n this._itTail = record;\n } else {\n next._prev = record;\n }\n if (prevRecord === null) {\n this._itHead = record;\n } else {\n prevRecord._next = record;\n }\n if (this._linkedRecords === null) {\n this._linkedRecords = new _DuplicateMap();\n }\n this._linkedRecords.put(record);\n record.currentIndex = index;\n return record;\n }\n /** @internal */\n _remove(record) {\n return this._addToRemovals(this._unlink(record));\n }\n /** @internal */\n _unlink(record) {\n if (this._linkedRecords !== null) {\n this._linkedRecords.remove(record);\n }\n const prev = record._prev;\n const next = record._next;\n // TODO(vicb):\n // assert((record._prev = null) === null);\n // assert((record._next = null) === null);\n if (prev === null) {\n this._itHead = next;\n } else {\n prev._next = next;\n }\n if (next === null) {\n this._itTail = prev;\n } else {\n next._prev = prev;\n }\n return record;\n }\n /** @internal */\n _addToMoves(record, toIndex) {\n // TODO(vicb):\n // assert(record._nextMoved === null);\n if (record.previousIndex === toIndex) {\n return record;\n }\n if (this._movesTail === null) {\n // TODO(vicb):\n // assert(_movesHead === null);\n this._movesTail = this._movesHead = record;\n } else {\n // TODO(vicb):\n // assert(_movesTail._nextMoved === null);\n this._movesTail = this._movesTail._nextMoved = record;\n }\n return record;\n }\n _addToRemovals(record) {\n if (this._unlinkedRecords === null) {\n this._unlinkedRecords = new _DuplicateMap();\n }\n this._unlinkedRecords.put(record);\n record.currentIndex = null;\n record._nextRemoved = null;\n if (this._removalsTail === null) {\n // TODO(vicb):\n // assert(_removalsHead === null);\n this._removalsTail = this._removalsHead = record;\n record._prevRemoved = null;\n } else {\n // TODO(vicb):\n // assert(_removalsTail._nextRemoved === null);\n // assert(record._nextRemoved === null);\n record._prevRemoved = this._removalsTail;\n this._removalsTail = this._removalsTail._nextRemoved = record;\n }\n return record;\n }\n /** @internal */\n _addIdentityChange(record, item) {\n record.item = item;\n if (this._identityChangesTail === null) {\n this._identityChangesTail = this._identityChangesHead = record;\n } else {\n this._identityChangesTail = this._identityChangesTail._nextIdentityChange = record;\n }\n return record;\n }\n}\nclass IterableChangeRecord_ {\n item;\n trackById;\n currentIndex = null;\n previousIndex = null;\n /** @internal */\n _nextPrevious = null;\n /** @internal */\n _prev = null;\n /** @internal */\n _next = null;\n /** @internal */\n _prevDup = null;\n /** @internal */\n _nextDup = null;\n /** @internal */\n _prevRemoved = null;\n /** @internal */\n _nextRemoved = null;\n /** @internal */\n _nextAdded = null;\n /** @internal */\n _nextMoved = null;\n /** @internal */\n _nextIdentityChange = null;\n constructor(item, trackById) {\n this.item = item;\n this.trackById = trackById;\n }\n}\n// A linked list of IterableChangeRecords with the same IterableChangeRecord_.item\nclass _DuplicateItemRecordList {\n /** @internal */\n _head = null;\n /** @internal */\n _tail = null;\n /**\n * Append the record to the list of duplicates.\n *\n * Note: by design all records in the list of duplicates hold the same value in record.item.\n */\n add(record) {\n if (this._head === null) {\n this._head = this._tail = record;\n record._nextDup = null;\n record._prevDup = null;\n } else {\n // TODO(vicb):\n // assert(record.item == _head.item ||\n // record.item is num && record.item.isNaN && _head.item is num && _head.item.isNaN);\n this._tail._nextDup = record;\n record._prevDup = this._tail;\n record._nextDup = null;\n this._tail = record;\n }\n }\n // Returns a IterableChangeRecord_ having IterableChangeRecord_.trackById == trackById and\n // IterableChangeRecord_.currentIndex >= atOrAfterIndex\n get(trackById, atOrAfterIndex) {\n let record;\n for (record = this._head; record !== null; record = record._nextDup) {\n if ((atOrAfterIndex === null || atOrAfterIndex <= record.currentIndex) && Object.is(record.trackById, trackById)) {\n return record;\n }\n }\n return null;\n }\n /**\n * Remove one {@link IterableChangeRecord_} from the list of duplicates.\n *\n * Returns whether the list of duplicates is empty.\n */\n remove(record) {\n // TODO(vicb):\n // assert(() {\n // // verify that the record being removed is in the list.\n // for (IterableChangeRecord_ cursor = _head; cursor != null; cursor = cursor._nextDup) {\n // if (identical(cursor, record)) return true;\n // }\n // return false;\n //});\n const prev = record._prevDup;\n const next = record._nextDup;\n if (prev === null) {\n this._head = next;\n } else {\n prev._nextDup = next;\n }\n if (next === null) {\n this._tail = prev;\n } else {\n next._prevDup = prev;\n }\n return this._head === null;\n }\n}\nclass _DuplicateMap {\n map = new Map();\n put(record) {\n const key = record.trackById;\n let duplicates = this.map.get(key);\n if (!duplicates) {\n duplicates = new _DuplicateItemRecordList();\n this.map.set(key, duplicates);\n }\n duplicates.add(record);\n }\n /**\n * Retrieve the `value` using key. Because the IterableChangeRecord_ value may be one which we\n * have already iterated over, we use the `atOrAfterIndex` to pretend it is not there.\n *\n * Use case: `[a, b, c, a, a]` if we are at index `3` which is the second `a` then asking if we\n * have any more `a`s needs to return the second `a`.\n */\n get(trackById, atOrAfterIndex) {\n const key = trackById;\n const recordList = this.map.get(key);\n return recordList ? recordList.get(trackById, atOrAfterIndex) : null;\n }\n /**\n * Removes a {@link IterableChangeRecord_} from the list of duplicates.\n *\n * The list of duplicates also is removed from the map if it gets empty.\n */\n remove(record) {\n const key = record.trackById;\n const recordList = this.map.get(key);\n // Remove the list of duplicates when it gets empty\n if (recordList.remove(record)) {\n this.map.delete(key);\n }\n return record;\n }\n get isEmpty() {\n return this.map.size === 0;\n }\n clear() {\n this.map.clear();\n }\n}\nfunction getPreviousIndex(item, addRemoveOffset, moveOffsets) {\n const previousIndex = item.previousIndex;\n if (previousIndex === null) return previousIndex;\n let moveOffset = 0;\n if (moveOffsets && previousIndex < moveOffsets.length) {\n moveOffset = moveOffsets[previousIndex];\n }\n return previousIndex + addRemoveOffset + moveOffset;\n}\nclass DefaultKeyValueDifferFactory {\n constructor() {}\n supports(obj) {\n return obj instanceof Map || isJsObject(obj);\n }\n create() {\n return new DefaultKeyValueDiffer();\n }\n}\nclass DefaultKeyValueDiffer {\n _records = new Map();\n _mapHead = null;\n // _appendAfter is used in the check loop\n _appendAfter = null;\n _previousMapHead = null;\n _changesHead = null;\n _changesTail = null;\n _additionsHead = null;\n _additionsTail = null;\n _removalsHead = null;\n _removalsTail = null;\n get isDirty() {\n return this._additionsHead !== null || this._changesHead !== null || this._removalsHead !== null;\n }\n forEachItem(fn) {\n let record;\n for (record = this._mapHead; record !== null; record = record._next) {\n fn(record);\n }\n }\n forEachPreviousItem(fn) {\n let record;\n for (record = this._previousMapHead; record !== null; record = record._nextPrevious) {\n fn(record);\n }\n }\n forEachChangedItem(fn) {\n let record;\n for (record = this._changesHead; record !== null; record = record._nextChanged) {\n fn(record);\n }\n }\n forEachAddedItem(fn) {\n let record;\n for (record = this._additionsHead; record !== null; record = record._nextAdded) {\n fn(record);\n }\n }\n forEachRemovedItem(fn) {\n let record;\n for (record = this._removalsHead; record !== null; record = record._nextRemoved) {\n fn(record);\n }\n }\n diff(map) {\n if (!map) {\n map = new Map();\n } else if (!(map instanceof Map || isJsObject(map))) {\n throw new RuntimeError(900 /* RuntimeErrorCode.INVALID_DIFFER_INPUT */, ngDevMode && `Error trying to diff '${stringify(map)}'. Only maps and objects are allowed`);\n }\n return this.check(map) ? this : null;\n }\n onDestroy() {}\n /**\n * Check the current state of the map vs the previous.\n * The algorithm is optimised for when the keys do no change.\n */\n check(map) {\n this._reset();\n let insertBefore = this._mapHead;\n this._appendAfter = null;\n this._forEach(map, (value, key) => {\n if (insertBefore && insertBefore.key === key) {\n this._maybeAddToChanges(insertBefore, value);\n this._appendAfter = insertBefore;\n insertBefore = insertBefore._next;\n } else {\n const record = this._getOrCreateRecordForKey(key, value);\n insertBefore = this._insertBeforeOrAppend(insertBefore, record);\n }\n });\n // Items remaining at the end of the list have been deleted\n if (insertBefore) {\n if (insertBefore._prev) {\n insertBefore._prev._next = null;\n }\n this._removalsHead = insertBefore;\n for (let record = insertBefore; record !== null; record = record._nextRemoved) {\n if (record === this._mapHead) {\n this._mapHead = null;\n }\n this._records.delete(record.key);\n record._nextRemoved = record._next;\n record.previousValue = record.currentValue;\n record.currentValue = null;\n record._prev = null;\n record._next = null;\n }\n }\n // Make sure tails have no next records from previous runs\n if (this._changesTail) this._changesTail._nextChanged = null;\n if (this._additionsTail) this._additionsTail._nextAdded = null;\n return this.isDirty;\n }\n /**\n * Inserts a record before `before` or append at the end of the list when `before` is null.\n *\n * Notes:\n * - This method appends at `this._appendAfter`,\n * - This method updates `this._appendAfter`,\n * - The return value is the new value for the insertion pointer.\n */\n _insertBeforeOrAppend(before, record) {\n if (before) {\n const prev = before._prev;\n record._next = before;\n record._prev = prev;\n before._prev = record;\n if (prev) {\n prev._next = record;\n }\n if (before === this._mapHead) {\n this._mapHead = record;\n }\n this._appendAfter = before;\n return before;\n }\n if (this._appendAfter) {\n this._appendAfter._next = record;\n record._prev = this._appendAfter;\n } else {\n this._mapHead = record;\n }\n this._appendAfter = record;\n return null;\n }\n _getOrCreateRecordForKey(key, value) {\n if (this._records.has(key)) {\n const record = this._records.get(key);\n this._maybeAddToChanges(record, value);\n const prev = record._prev;\n const next = record._next;\n if (prev) {\n prev._next = next;\n }\n if (next) {\n next._prev = prev;\n }\n record._next = null;\n record._prev = null;\n return record;\n }\n const record = new KeyValueChangeRecord_(key);\n this._records.set(key, record);\n record.currentValue = value;\n this._addToAdditions(record);\n return record;\n }\n /** @internal */\n _reset() {\n if (this.isDirty) {\n let record;\n // let `_previousMapHead` contain the state of the map before the changes\n this._previousMapHead = this._mapHead;\n for (record = this._previousMapHead; record !== null; record = record._next) {\n record._nextPrevious = record._next;\n }\n // Update `record.previousValue` with the value of the item before the changes\n // We need to update all changed items (that's those which have been added and changed)\n for (record = this._changesHead; record !== null; record = record._nextChanged) {\n record.previousValue = record.currentValue;\n }\n for (record = this._additionsHead; record != null; record = record._nextAdded) {\n record.previousValue = record.currentValue;\n }\n this._changesHead = this._changesTail = null;\n this._additionsHead = this._additionsTail = null;\n this._removalsHead = null;\n }\n }\n // Add the record or a given key to the list of changes only when the value has actually changed\n _maybeAddToChanges(record, newValue) {\n if (!Object.is(newValue, record.currentValue)) {\n record.previousValue = record.currentValue;\n record.currentValue = newValue;\n this._addToChanges(record);\n }\n }\n _addToAdditions(record) {\n if (this._additionsHead === null) {\n this._additionsHead = this._additionsTail = record;\n } else {\n this._additionsTail._nextAdded = record;\n this._additionsTail = record;\n }\n }\n _addToChanges(record) {\n if (this._changesHead === null) {\n this._changesHead = this._changesTail = record;\n } else {\n this._changesTail._nextChanged = record;\n this._changesTail = record;\n }\n }\n /** @internal */\n _forEach(obj, fn) {\n if (obj instanceof Map) {\n obj.forEach(fn);\n } else {\n Object.keys(obj).forEach(k => fn(obj[k], k));\n }\n }\n}\nclass KeyValueChangeRecord_ {\n key;\n previousValue = null;\n currentValue = null;\n /** @internal */\n _nextPrevious = null;\n /** @internal */\n _next = null;\n /** @internal */\n _prev = null;\n /** @internal */\n _nextAdded = null;\n /** @internal */\n _nextRemoved = null;\n /** @internal */\n _nextChanged = null;\n constructor(key) {\n this.key = key;\n }\n}\nfunction defaultIterableDiffersFactory() {\n return new IterableDiffers([new DefaultIterableDifferFactory()]);\n}\n/**\n * A repository of different iterable diffing strategies used by NgFor, NgClass, and others.\n *\n * @publicApi\n */\nclass IterableDiffers {\n factories;\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: IterableDiffers,\n providedIn: 'root',\n factory: defaultIterableDiffersFactory\n });\n constructor(factories) {\n this.factories = factories;\n }\n static create(factories, parent) {\n if (parent != null) {\n const copied = parent.factories.slice();\n factories = factories.concat(copied);\n }\n return new IterableDiffers(factories);\n }\n /**\n * Takes an array of {@link IterableDifferFactory} and returns a provider used to extend the\n * inherited {@link IterableDiffers} instance with the provided factories and return a new\n * {@link IterableDiffers} instance.\n *\n * @usageNotes\n * ### Example\n *\n * The following example shows how to extend an existing list of factories,\n * which will only be applied to the injector for this component and its children.\n * This step is all that's required to make a new {@link IterableDiffer} available.\n *\n * ```ts\n * @Component({\n * viewProviders: [\n * IterableDiffers.extend([new ImmutableListDiffer()])\n * ]\n * })\n * ```\n */\n static extend(factories) {\n return {\n provide: IterableDiffers,\n useFactory: parent => {\n // if parent is null, it means that we are in the root injector and we have just overridden\n // the default injection mechanism for IterableDiffers, in such a case just assume\n // `defaultIterableDiffersFactory`.\n return IterableDiffers.create(factories, parent || defaultIterableDiffersFactory());\n },\n // Dependency technically isn't optional, but we can provide a better error message this way.\n deps: [[IterableDiffers, new SkipSelf(), new Optional()]]\n };\n }\n find(iterable) {\n const factory = this.factories.find(f => f.supports(iterable));\n if (factory != null) {\n return factory;\n } else {\n throw new RuntimeError(901 /* RuntimeErrorCode.NO_SUPPORTING_DIFFER_FACTORY */, ngDevMode && `Cannot find a differ supporting object '${iterable}' of type '${getTypeNameForDebugging(iterable)}'`);\n }\n }\n}\nfunction getTypeNameForDebugging(type) {\n return type['name'] || typeof type;\n}\nfunction defaultKeyValueDiffersFactory() {\n return new KeyValueDiffers([new DefaultKeyValueDifferFactory()]);\n}\n/**\n * A repository of different Map diffing strategies used by NgClass, NgStyle, and others.\n *\n * @publicApi\n */\nclass KeyValueDiffers {\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: KeyValueDiffers,\n providedIn: 'root',\n factory: defaultKeyValueDiffersFactory\n });\n factories;\n constructor(factories) {\n this.factories = factories;\n }\n static create(factories, parent) {\n if (parent) {\n const copied = parent.factories.slice();\n factories = factories.concat(copied);\n }\n return new KeyValueDiffers(factories);\n }\n /**\n * Takes an array of {@link KeyValueDifferFactory} and returns a provider used to extend the\n * inherited {@link KeyValueDiffers} instance with the provided factories and return a new\n * {@link KeyValueDiffers} instance.\n *\n * @usageNotes\n * ### Example\n *\n * The following example shows how to extend an existing list of factories,\n * which will only be applied to the injector for this component and its children.\n * This step is all that's required to make a new {@link KeyValueDiffer} available.\n *\n * ```ts\n * @Component({\n * viewProviders: [\n * KeyValueDiffers.extend([new ImmutableMapDiffer()])\n * ]\n * })\n * ```\n */\n static extend(factories) {\n return {\n provide: KeyValueDiffers,\n useFactory: parent => {\n // if parent is null, it means that we are in the root injector and we have just overridden\n // the default injection mechanism for KeyValueDiffers, in such a case just assume\n // `defaultKeyValueDiffersFactory`.\n return KeyValueDiffers.create(factories, parent || defaultKeyValueDiffersFactory());\n },\n // Dependency technically isn't optional, but we can provide a better error message this way.\n deps: [[KeyValueDiffers, new SkipSelf(), new Optional()]]\n };\n }\n find(kv) {\n const factory = this.factories.find(f => f.supports(kv));\n if (factory) {\n return factory;\n }\n throw new RuntimeError(901 /* RuntimeErrorCode.NO_SUPPORTING_DIFFER_FACTORY */, ngDevMode && `Cannot find a differ supporting object '${kv}'`);\n }\n}\n\n/**\n * Structural diffing for `Object`s and `Map`s.\n */\nconst keyValDiff = [new DefaultKeyValueDifferFactory()];\n/**\n * Structural diffing for `Iterable` types such as `Array`s.\n */\nconst iterableDiff = [new DefaultIterableDifferFactory()];\nconst defaultIterableDiffers = new IterableDiffers(iterableDiff);\nconst defaultKeyValueDiffers = new KeyValueDiffers(keyValDiff);\n\n/**\n * @module\n * @description\n * Change detection enables data binding in Angular.\n */\n\n/**\n * This platform has to be included in any other platform\n *\n * @publicApi\n */\nconst platformCore = createPlatformFactory(null, 'core', []);\n\n/**\n * Re-exported by `BrowserModule`, which is included automatically in the root\n * `AppModule` when you create a new app with the CLI `new` command. Eagerly injects\n * `ApplicationRef` to instantiate it.\n *\n * @publicApi\n */\nclass ApplicationModule {\n // Inject ApplicationRef to make it eager...\n constructor(appRef) {}\n static ɵfac = function ApplicationModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ApplicationModule)(ɵɵinject(ApplicationRef));\n };\n static ɵmod = /*@__PURE__*/ɵɵdefineNgModule({\n type: ApplicationModule\n });\n static ɵinj = /*@__PURE__*/ɵɵdefineInjector({});\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && setClassMetadata(ApplicationModule, [{\n type: NgModule\n }], () => [{\n type: ApplicationRef\n }], null);\n})();\n\n/**\n * The default equality function used for `signal` and `computed`, which uses referential equality.\n */\nfunction defaultEquals(a, b) {\n return Object.is(a, b);\n}\n\n/**\n * The currently active consumer `ReactiveNode`, if running code in a reactive context.\n *\n * Change this via `setActiveConsumer`.\n */\nlet activeConsumer = null;\nlet inNotificationPhase = false;\n/**\n * Global epoch counter. Incremented whenever a source signal is set.\n */\nlet epoch = 1;\n/**\n * Symbol used to tell `Signal`s apart from other functions.\n *\n * This can be used to auto-unwrap signals in various cases, or to auto-wrap non-signal values.\n */\nconst SIGNAL = /* @__PURE__ */Symbol('SIGNAL');\nfunction setActiveConsumer(consumer) {\n const prev = activeConsumer;\n activeConsumer = consumer;\n return prev;\n}\nfunction getActiveConsumer() {\n return activeConsumer;\n}\nfunction isInNotificationPhase() {\n return inNotificationPhase;\n}\nfunction isReactive(value) {\n return value[SIGNAL] !== undefined;\n}\nconst REACTIVE_NODE = {\n version: 0,\n lastCleanEpoch: 0,\n dirty: false,\n producerNode: undefined,\n producerLastReadVersion: undefined,\n producerIndexOfThis: undefined,\n nextProducerIndex: 0,\n liveConsumerNode: undefined,\n liveConsumerIndexOfThis: undefined,\n consumerAllowSignalWrites: false,\n consumerIsAlwaysLive: false,\n kind: 'unknown',\n producerMustRecompute: () => false,\n producerRecomputeValue: () => {},\n consumerMarkedDirty: () => {},\n consumerOnSignalRead: () => {}\n};\n/**\n * Called by implementations when a producer's signal is read.\n */\nfunction producerAccessed(node) {\n if (inNotificationPhase) {\n throw new Error(typeof ngDevMode !== 'undefined' && ngDevMode ? `Assertion error: signal read during notification phase` : '');\n }\n if (activeConsumer === null) {\n // Accessed outside of a reactive context, so nothing to record.\n return;\n }\n activeConsumer.consumerOnSignalRead(node);\n // This producer is the `idx`th dependency of `activeConsumer`.\n const idx = activeConsumer.nextProducerIndex++;\n assertConsumerNode(activeConsumer);\n if (idx < activeConsumer.producerNode.length && activeConsumer.producerNode[idx] !== node) {\n // There's been a change in producers since the last execution of `activeConsumer`.\n // `activeConsumer.producerNode[idx]` holds a stale dependency which will be be removed and\n // replaced with `this`.\n //\n // If `activeConsumer` isn't live, then this is a no-op, since we can replace the producer in\n // `activeConsumer.producerNode` directly. However, if `activeConsumer` is live, then we need\n // to remove it from the stale producer's `liveConsumer`s.\n if (consumerIsLive(activeConsumer)) {\n const staleProducer = activeConsumer.producerNode[idx];\n producerRemoveLiveConsumerAtIndex(staleProducer, activeConsumer.producerIndexOfThis[idx]);\n // At this point, the only record of `staleProducer` is the reference at\n // `activeConsumer.producerNode[idx]` which will be overwritten below.\n }\n }\n if (activeConsumer.producerNode[idx] !== node) {\n // We're a new dependency of the consumer (at `idx`).\n activeConsumer.producerNode[idx] = node;\n // If the active consumer is live, then add it as a live consumer. If not, then use 0 as a\n // placeholder value.\n activeConsumer.producerIndexOfThis[idx] = consumerIsLive(activeConsumer) ? producerAddLiveConsumer(node, activeConsumer, idx) : 0;\n }\n activeConsumer.producerLastReadVersion[idx] = node.version;\n}\n/**\n * Increment the global epoch counter.\n *\n * Called by source producers (that is, not computeds) whenever their values change.\n */\nfunction producerIncrementEpoch() {\n epoch++;\n}\n/**\n * Ensure this producer's `version` is up-to-date.\n */\nfunction producerUpdateValueVersion(node) {\n if (consumerIsLive(node) && !node.dirty) {\n // A live consumer will be marked dirty by producers, so a clean state means that its version\n // is guaranteed to be up-to-date.\n return;\n }\n if (!node.dirty && node.lastCleanEpoch === epoch) {\n // Even non-live consumers can skip polling if they previously found themselves to be clean at\n // the current epoch, since their dependencies could not possibly have changed (such a change\n // would've increased the epoch).\n return;\n }\n if (!node.producerMustRecompute(node) && !consumerPollProducersForChange(node)) {\n // None of our producers report a change since the last time they were read, so no\n // recomputation of our value is necessary, and we can consider ourselves clean.\n producerMarkClean(node);\n return;\n }\n node.producerRecomputeValue(node);\n // After recomputing the value, we're no longer dirty.\n producerMarkClean(node);\n}\n/**\n * Propagate a dirty notification to live consumers of this producer.\n */\nfunction producerNotifyConsumers(node) {\n if (node.liveConsumerNode === undefined) {\n return;\n }\n // Prevent signal reads when we're updating the graph\n const prev = inNotificationPhase;\n inNotificationPhase = true;\n try {\n for (const consumer of node.liveConsumerNode) {\n if (!consumer.dirty) {\n consumerMarkDirty(consumer);\n }\n }\n } finally {\n inNotificationPhase = prev;\n }\n}\n/**\n * Whether this `ReactiveNode` in its producer capacity is currently allowed to initiate updates,\n * based on the current consumer context.\n */\nfunction producerUpdatesAllowed() {\n return activeConsumer?.consumerAllowSignalWrites !== false;\n}\nfunction consumerMarkDirty(node) {\n node.dirty = true;\n producerNotifyConsumers(node);\n node.consumerMarkedDirty?.(node);\n}\nfunction producerMarkClean(node) {\n node.dirty = false;\n node.lastCleanEpoch = epoch;\n}\n/**\n * Prepare this consumer to run a computation in its reactive context.\n *\n * Must be called by subclasses which represent reactive computations, before those computations\n * begin.\n */\nfunction consumerBeforeComputation(node) {\n node && (node.nextProducerIndex = 0);\n return setActiveConsumer(node);\n}\n/**\n * Finalize this consumer's state after a reactive computation has run.\n *\n * Must be called by subclasses which represent reactive computations, after those computations\n * have finished.\n */\nfunction consumerAfterComputation(node, prevConsumer) {\n setActiveConsumer(prevConsumer);\n if (!node || node.producerNode === undefined || node.producerIndexOfThis === undefined || node.producerLastReadVersion === undefined) {\n return;\n }\n if (consumerIsLive(node)) {\n // For live consumers, we need to remove the producer -> consumer edge for any stale producers\n // which weren't dependencies after the recomputation.\n for (let i = node.nextProducerIndex; i < node.producerNode.length; i++) {\n producerRemoveLiveConsumerAtIndex(node.producerNode[i], node.producerIndexOfThis[i]);\n }\n }\n // Truncate the producer tracking arrays.\n // Perf note: this is essentially truncating the length to `node.nextProducerIndex`, but\n // benchmarking has shown that individual pop operations are faster.\n while (node.producerNode.length > node.nextProducerIndex) {\n node.producerNode.pop();\n node.producerLastReadVersion.pop();\n node.producerIndexOfThis.pop();\n }\n}\n/**\n * Determine whether this consumer has any dependencies which have changed since the last time\n * they were read.\n */\nfunction consumerPollProducersForChange(node) {\n assertConsumerNode(node);\n // Poll producers for change.\n for (let i = 0; i < node.producerNode.length; i++) {\n const producer = node.producerNode[i];\n const seenVersion = node.producerLastReadVersion[i];\n // First check the versions. A mismatch means that the producer's value is known to have\n // changed since the last time we read it.\n if (seenVersion !== producer.version) {\n return true;\n }\n // The producer's version is the same as the last time we read it, but it might itself be\n // stale. Force the producer to recompute its version (calculating a new value if necessary).\n producerUpdateValueVersion(producer);\n // Now when we do this check, `producer.version` is guaranteed to be up to date, so if the\n // versions still match then it has not changed since the last time we read it.\n if (seenVersion !== producer.version) {\n return true;\n }\n }\n return false;\n}\n/**\n * Disconnect this consumer from the graph.\n */\nfunction consumerDestroy(node) {\n assertConsumerNode(node);\n if (consumerIsLive(node)) {\n // Drop all connections from the graph to this node.\n for (let i = 0; i < node.producerNode.length; i++) {\n producerRemoveLiveConsumerAtIndex(node.producerNode[i], node.producerIndexOfThis[i]);\n }\n }\n // Truncate all the arrays to drop all connection from this node to the graph.\n node.producerNode.length = node.producerLastReadVersion.length = node.producerIndexOfThis.length = 0;\n if (node.liveConsumerNode) {\n node.liveConsumerNode.length = node.liveConsumerIndexOfThis.length = 0;\n }\n}\n/**\n * Add `consumer` as a live consumer of this node.\n *\n * Note that this operation is potentially transitive. If this node becomes live, then it becomes\n * a live consumer of all of its current producers.\n */\nfunction producerAddLiveConsumer(node, consumer, indexOfThis) {\n assertProducerNode(node);\n if (node.liveConsumerNode.length === 0 && isConsumerNode(node)) {\n // When going from 0 to 1 live consumers, we become a live consumer to our producers.\n for (let i = 0; i < node.producerNode.length; i++) {\n node.producerIndexOfThis[i] = producerAddLiveConsumer(node.producerNode[i], node, i);\n }\n }\n node.liveConsumerIndexOfThis.push(indexOfThis);\n return node.liveConsumerNode.push(consumer) - 1;\n}\n/**\n * Remove the live consumer at `idx`.\n */\nfunction producerRemoveLiveConsumerAtIndex(node, idx) {\n assertProducerNode(node);\n if (typeof ngDevMode !== 'undefined' && ngDevMode && idx >= node.liveConsumerNode.length) {\n throw new Error(`Assertion error: active consumer index ${idx} is out of bounds of ${node.liveConsumerNode.length} consumers)`);\n }\n if (node.liveConsumerNode.length === 1 && isConsumerNode(node)) {\n // When removing the last live consumer, we will no longer be live. We need to remove\n // ourselves from our producers' tracking (which may cause consumer-producers to lose\n // liveness as well).\n for (let i = 0; i < node.producerNode.length; i++) {\n producerRemoveLiveConsumerAtIndex(node.producerNode[i], node.producerIndexOfThis[i]);\n }\n }\n // Move the last value of `liveConsumers` into `idx`. Note that if there's only a single\n // live consumer, this is a no-op.\n const lastIdx = node.liveConsumerNode.length - 1;\n node.liveConsumerNode[idx] = node.liveConsumerNode[lastIdx];\n node.liveConsumerIndexOfThis[idx] = node.liveConsumerIndexOfThis[lastIdx];\n // Truncate the array.\n node.liveConsumerNode.length--;\n node.liveConsumerIndexOfThis.length--;\n // If the index is still valid, then we need to fix the index pointer from the producer to this\n // consumer, and update it from `lastIdx` to `idx` (accounting for the move above).\n if (idx < node.liveConsumerNode.length) {\n const idxProducer = node.liveConsumerIndexOfThis[idx];\n const consumer = node.liveConsumerNode[idx];\n assertConsumerNode(consumer);\n consumer.producerIndexOfThis[idxProducer] = idx;\n }\n}\nfunction consumerIsLive(node) {\n return node.consumerIsAlwaysLive || (node?.liveConsumerNode?.length ?? 0) > 0;\n}\nfunction assertConsumerNode(node) {\n node.producerNode ??= [];\n node.producerIndexOfThis ??= [];\n node.producerLastReadVersion ??= [];\n}\nfunction assertProducerNode(node) {\n node.liveConsumerNode ??= [];\n node.liveConsumerIndexOfThis ??= [];\n}\nfunction isConsumerNode(node) {\n return node.producerNode !== undefined;\n}\n\n/**\n * Create a computed signal which derives a reactive value from an expression.\n */\nfunction createComputed(computation) {\n const node = Object.create(COMPUTED_NODE);\n node.computation = computation;\n const computed = () => {\n // Check if the value needs updating before returning it.\n producerUpdateValueVersion(node);\n // Record that someone looked at this signal.\n producerAccessed(node);\n if (node.value === ERRORED) {\n throw node.error;\n }\n return node.value;\n };\n computed[SIGNAL] = node;\n return computed;\n}\n/**\n * A dedicated symbol used before a computed value has been calculated for the first time.\n * Explicitly typed as `any` so we can use it as signal's value.\n */\nconst UNSET = /* @__PURE__ */Symbol('UNSET');\n/**\n * A dedicated symbol used in place of a computed signal value to indicate that a given computation\n * is in progress. Used to detect cycles in computation chains.\n * Explicitly typed as `any` so we can use it as signal's value.\n */\nconst COMPUTING = /* @__PURE__ */Symbol('COMPUTING');\n/**\n * A dedicated symbol used in place of a computed signal value to indicate that a given computation\n * failed. The thrown error is cached until the computation gets dirty again.\n * Explicitly typed as `any` so we can use it as signal's value.\n */\nconst ERRORED = /* @__PURE__ */Symbol('ERRORED');\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `COMPUTED_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst COMPUTED_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n value: UNSET,\n dirty: true,\n error: null,\n equal: defaultEquals,\n kind: 'computed',\n producerMustRecompute(node) {\n // Force a recomputation if there's no current value, or if the current value is in the\n // process of being calculated (which should throw an error).\n return node.value === UNSET || node.value === COMPUTING;\n },\n producerRecomputeValue(node) {\n if (node.value === COMPUTING) {\n // Our computation somehow led to a cyclic read of itself.\n throw new Error('Detected cycle in computations.');\n }\n const oldValue = node.value;\n node.value = COMPUTING;\n const prevConsumer = consumerBeforeComputation(node);\n let newValue;\n let wasEqual = false;\n try {\n newValue = node.computation();\n // We want to mark this node as errored if calling `equal` throws; however, we don't want\n // to track any reactive reads inside `equal`.\n setActiveConsumer(null);\n wasEqual = oldValue !== UNSET && oldValue !== ERRORED && newValue !== ERRORED && node.equal(oldValue, newValue);\n } catch (err) {\n newValue = ERRORED;\n node.error = err;\n } finally {\n consumerAfterComputation(node, prevConsumer);\n }\n if (wasEqual) {\n // No change to `valueVersion` - old and new values are\n // semantically equivalent.\n node.value = oldValue;\n return;\n }\n node.value = newValue;\n node.version++;\n }\n };\n})();\nfunction defaultThrowError() {\n throw new Error();\n}\nlet throwInvalidWriteToSignalErrorFn = defaultThrowError;\nfunction throwInvalidWriteToSignalError(node) {\n throwInvalidWriteToSignalErrorFn(node);\n}\nfunction setThrowInvalidWriteToSignalError(fn) {\n throwInvalidWriteToSignalErrorFn = fn;\n}\n\n/**\n * If set, called after `WritableSignal`s are updated.\n *\n * This hook can be used to achieve various effects, such as running effects synchronously as part\n * of setting a signal.\n */\nlet postSignalSetFn = null;\n/**\n * Create a `Signal` that can be set or updated directly.\n */\nfunction createSignal(initialValue) {\n const node = Object.create(SIGNAL_NODE);\n node.value = initialValue;\n const getter = () => {\n producerAccessed(node);\n return node.value;\n };\n getter[SIGNAL] = node;\n return getter;\n}\nfunction setPostSignalSetFn(fn) {\n const prev = postSignalSetFn;\n postSignalSetFn = fn;\n return prev;\n}\nfunction signalGetFn() {\n producerAccessed(this);\n return this.value;\n}\nfunction signalSetFn(node, newValue) {\n if (!producerUpdatesAllowed()) {\n throwInvalidWriteToSignalError(node);\n }\n if (!node.equal(node.value, newValue)) {\n node.value = newValue;\n signalValueChanged(node);\n }\n}\nfunction signalUpdateFn(node, updater) {\n if (!producerUpdatesAllowed()) {\n throwInvalidWriteToSignalError(node);\n }\n signalSetFn(node, updater(node.value));\n}\nfunction runPostSignalSetFn() {\n postSignalSetFn?.();\n}\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `COMPUTED_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst SIGNAL_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n equal: defaultEquals,\n value: undefined,\n kind: 'signal'\n };\n})();\nfunction signalValueChanged(node) {\n node.version++;\n producerIncrementEpoch();\n producerNotifyConsumers(node);\n postSignalSetFn?.();\n}\nfunction createLinkedSignal(sourceFn, computationFn, equalityFn) {\n const node = Object.create(LINKED_SIGNAL_NODE);\n node.source = sourceFn;\n node.computation = computationFn;\n if (equalityFn != undefined) {\n node.equal = equalityFn;\n }\n const linkedSignalGetter = () => {\n // Check if the value needs updating before returning it.\n producerUpdateValueVersion(node);\n // Record that someone looked at this signal.\n producerAccessed(node);\n if (node.value === ERRORED) {\n throw node.error;\n }\n return node.value;\n };\n const getter = linkedSignalGetter;\n getter[SIGNAL] = node;\n return getter;\n}\nfunction linkedSignalSetFn(node, newValue) {\n producerUpdateValueVersion(node);\n signalSetFn(node, newValue);\n producerMarkClean(node);\n}\nfunction linkedSignalUpdateFn(node, updater) {\n producerUpdateValueVersion(node);\n signalUpdateFn(node, updater);\n producerMarkClean(node);\n}\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `LINKED_SIGNAL_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst LINKED_SIGNAL_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n value: UNSET,\n dirty: true,\n error: null,\n equal: defaultEquals,\n producerMustRecompute(node) {\n // Force a recomputation if there's no current value, or if the current value is in the\n // process of being calculated (which should throw an error).\n return node.value === UNSET || node.value === COMPUTING;\n },\n producerRecomputeValue(node) {\n if (node.value === COMPUTING) {\n // Our computation somehow led to a cyclic read of itself.\n throw new Error('Detected cycle in computations.');\n }\n const oldValue = node.value;\n node.value = COMPUTING;\n const prevConsumer = consumerBeforeComputation(node);\n let newValue;\n try {\n const newSourceValue = node.source();\n const prev = oldValue === UNSET || oldValue === ERRORED ? undefined : {\n source: node.sourceValue,\n value: oldValue\n };\n newValue = node.computation(newSourceValue, prev);\n node.sourceValue = newSourceValue;\n } catch (err) {\n newValue = ERRORED;\n node.error = err;\n } finally {\n consumerAfterComputation(node, prevConsumer);\n }\n if (oldValue !== UNSET && newValue !== ERRORED && node.equal(oldValue, newValue)) {\n // No change to `valueVersion` - old and new values are\n // semantically equivalent.\n node.value = oldValue;\n return;\n }\n node.value = newValue;\n node.version++;\n }\n };\n})();\nfunction createWatch(fn, schedule, allowSignalWrites) {\n const node = Object.create(WATCH_NODE);\n if (allowSignalWrites) {\n node.consumerAllowSignalWrites = true;\n }\n node.fn = fn;\n node.schedule = schedule;\n const registerOnCleanup = cleanupFn => {\n node.cleanupFn = cleanupFn;\n };\n function isWatchNodeDestroyed(node) {\n return node.fn === null && node.schedule === null;\n }\n function destroyWatchNode(node) {\n if (!isWatchNodeDestroyed(node)) {\n consumerDestroy(node); // disconnect watcher from the reactive graph\n node.cleanupFn();\n // nullify references to the integration functions to mark node as destroyed\n node.fn = null;\n node.schedule = null;\n node.cleanupFn = NOOP_CLEANUP_FN;\n }\n }\n const run = () => {\n if (node.fn === null) {\n // trying to run a destroyed watch is noop\n return;\n }\n if (isInNotificationPhase()) {\n throw new Error(`Schedulers cannot synchronously execute watches while scheduling.`);\n }\n node.dirty = false;\n if (node.hasRun && !consumerPollProducersForChange(node)) {\n return;\n }\n node.hasRun = true;\n const prevConsumer = consumerBeforeComputation(node);\n try {\n node.cleanupFn();\n node.cleanupFn = NOOP_CLEANUP_FN;\n node.fn(registerOnCleanup);\n } finally {\n consumerAfterComputation(node, prevConsumer);\n }\n };\n node.ref = {\n notify: () => consumerMarkDirty(node),\n run,\n cleanup: () => node.cleanupFn(),\n destroy: () => destroyWatchNode(node),\n [SIGNAL]: node\n };\n return node.ref;\n}\nconst NOOP_CLEANUP_FN = () => {};\n// Note: Using an IIFE here to ensure that the spread assignment is not considered\n// a side-effect, ending up preserving `COMPUTED_NODE` and `REACTIVE_NODE`.\n// TODO: remove when https://github.com/evanw/esbuild/issues/3392 is resolved.\nconst WATCH_NODE = /* @__PURE__ */(() => {\n return {\n ...REACTIVE_NODE,\n consumerIsAlwaysLive: true,\n consumerAllowSignalWrites: false,\n consumerMarkedDirty: node => {\n if (node.schedule !== null) {\n node.schedule(node.ref);\n }\n },\n hasRun: false,\n cleanupFn: NOOP_CLEANUP_FN\n };\n})();\nfunction setAlternateWeakRefImpl(impl) {\n // TODO: remove this function\n}\n\n/**\n * Internal create application API that implements the core application creation logic and optional\n * bootstrap logic.\n *\n * Platforms (such as `platform-browser`) may require different set of application and platform\n * providers for an application to function correctly. As a result, platforms may use this function\n * internally and supply the necessary providers during the bootstrap, while exposing\n * platform-specific APIs as a part of their public API.\n *\n * @returns A promise that returns an `ApplicationRef` instance once resolved.\n */\nfunction internalCreateApplication(config) {\n profiler(8 /* ProfilerEvent.BootstrapApplicationStart */);\n try {\n const {\n rootComponent,\n appProviders,\n platformProviders\n } = config;\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && rootComponent !== undefined) {\n assertStandaloneComponentType(rootComponent);\n }\n const platformInjector = createOrReusePlatformInjector(platformProviders);\n // Create root application injector based on a set of providers configured at the platform\n // bootstrap level as well as providers passed to the bootstrap call by a user.\n const allAppProviders = [internalProvideZoneChangeDetection({}), {\n provide: ChangeDetectionScheduler,\n useExisting: ChangeDetectionSchedulerImpl\n }, ...(appProviders || [])];\n const adapter = new EnvironmentNgModuleRefAdapter({\n providers: allAppProviders,\n parent: platformInjector,\n debugName: typeof ngDevMode === 'undefined' || ngDevMode ? 'Environment Injector' : '',\n // We skip environment initializers because we need to run them inside the NgZone, which\n // happens after we get the NgZone instance from the Injector.\n runEnvironmentInitializers: false\n });\n return bootstrap({\n r3Injector: adapter.injector,\n platformInjector,\n rootComponent\n });\n } catch (e) {\n return Promise.reject(e);\n } finally {\n profiler(9 /* ProfilerEvent.BootstrapApplicationEnd */);\n }\n}\n\n/** Apps in which we've enabled event replay.\n * This is to prevent initializing event replay more than once per app.\n */\nconst appsWithEventReplay = new WeakSet();\n/**\n * The key that represents all replayable elements that are not in defer blocks.\n */\nconst EAGER_CONTENT_LISTENERS_KEY = '';\n/**\n * A list of block events that need to be replayed\n */\nlet blockEventQueue = [];\n/**\n * Determines whether Event Replay feature should be activated on the client.\n */\nfunction shouldEnableEventReplay(injector) {\n return injector.get(IS_EVENT_REPLAY_ENABLED, EVENT_REPLAY_ENABLED_DEFAULT);\n}\n/**\n * Returns a set of providers required to setup support for event replay.\n * Requires hydration to be enabled separately.\n */\nfunction withEventReplay() {\n const providers = [{\n provide: IS_EVENT_REPLAY_ENABLED,\n useFactory: () => {\n let isEnabled = true;\n if (typeof ngServerMode === 'undefined' || !ngServerMode) {\n // Note: globalThis[CONTRACT_PROPERTY] may be undefined in case Event Replay feature\n // is enabled, but there are no events configured in this application, in which case\n // we don't activate this feature, since there are no events to replay.\n const appId = inject(APP_ID);\n isEnabled = !!window._ejsas?.[appId];\n }\n if (isEnabled) {\n performanceMarkFeature('NgEventReplay');\n }\n return isEnabled;\n }\n }];\n if (typeof ngServerMode === 'undefined' || !ngServerMode) {\n providers.push({\n provide: ENVIRONMENT_INITIALIZER,\n useValue: () => {\n const injector = inject(Injector);\n const appRef = injector.get(ApplicationRef);\n // We have to check for the appRef here due to the possibility of multiple apps\n // being present on the same page. We only want to enable event replay for the\n // apps that actually want it.\n if (!appsWithEventReplay.has(appRef)) {\n const jsActionMap = inject(JSACTION_BLOCK_ELEMENT_MAP);\n if (shouldEnableEventReplay(injector)) {\n setStashFn((rEl, eventName, listenerFn) => {\n // If a user binds to a ng-container and uses a directive that binds using a host listener,\n // this element could be a comment node. So we need to ensure we have an actual element\n // node before stashing anything.\n if (rEl.nodeType !== Node.ELEMENT_NODE) return;\n sharedStashFunction(rEl, eventName, listenerFn);\n sharedMapFunction(rEl, jsActionMap);\n });\n }\n }\n },\n multi: true\n }, {\n provide: APP_BOOTSTRAP_LISTENER,\n useFactory: () => {\n const appId = inject(APP_ID);\n const injector = inject(Injector);\n const appRef = inject(ApplicationRef);\n return () => {\n // We have to check for the appRef here due to the possibility of multiple apps\n // being present on the same page. We only want to enable event replay for the\n // apps that actually want it.\n if (!shouldEnableEventReplay(injector) || appsWithEventReplay.has(appRef)) {\n return;\n }\n appsWithEventReplay.add(appRef);\n appRef.onDestroy(() => {\n appsWithEventReplay.delete(appRef);\n // Ensure that we're always safe calling this in the browser.\n if (typeof ngServerMode !== 'undefined' && !ngServerMode) {\n // `_ejsa` should be deleted when the app is destroyed, ensuring that\n // no elements are still captured in the global list and are not prevented\n // from being garbage collected.\n clearAppScopedEarlyEventContract(appId);\n // Clean up the reference to the function set by the environment initializer,\n // as the function closure may capture injected elements and prevent them\n // from being properly garbage collected.\n setStashFn(() => {});\n }\n });\n // Kick off event replay logic once hydration for the initial part\n // of the application is completed. This timing is similar to the unclaimed\n // dehydrated views cleanup timing.\n appRef.whenStable().then(() => {\n const eventContractDetails = injector.get(JSACTION_EVENT_CONTRACT);\n initEventReplay(eventContractDetails, injector);\n const jsActionMap = injector.get(JSACTION_BLOCK_ELEMENT_MAP);\n jsActionMap.get(EAGER_CONTENT_LISTENERS_KEY)?.forEach(removeListeners);\n jsActionMap.delete(EAGER_CONTENT_LISTENERS_KEY);\n const eventContract = eventContractDetails.instance;\n // This removes event listeners registered through the container manager,\n // as listeners registered on `document.body` might never be removed if we\n // don't clean up the contract.\n if (isIncrementalHydrationEnabled(injector)) {\n // When incremental hydration is enabled, we cannot clean up the event\n // contract immediately because we're unaware if there are any deferred\n // blocks to hydrate. We can only schedule a contract cleanup when the\n // app is destroyed.\n appRef.onDestroy(() => eventContract.cleanUp());\n } else {\n eventContract.cleanUp();\n }\n });\n };\n },\n multi: true\n });\n }\n return providers;\n}\nconst initEventReplay = (eventDelegation, injector) => {\n const appId = injector.get(APP_ID);\n // This is set in packages/platform-server/src/utils.ts\n const earlyJsactionData = window._ejsas[appId];\n const eventContract = eventDelegation.instance = new EventContract(new EventContractContainer(earlyJsactionData.c));\n for (const et of earlyJsactionData.et) {\n eventContract.addEvent(et);\n }\n for (const et of earlyJsactionData.etc) {\n eventContract.addEvent(et);\n }\n const eventInfos = getAppScopedQueuedEventInfos(appId);\n eventContract.replayEarlyEventInfos(eventInfos);\n clearAppScopedEarlyEventContract(appId);\n const dispatcher = new EventDispatcher(event => {\n invokeRegisteredReplayListeners(injector, event, event.currentTarget);\n });\n registerDispatcher(eventContract, dispatcher);\n};\n/**\n * Extracts information about all DOM events (added in a template) registered on elements in a give\n * LView. Maps collected events to a corresponding DOM element (an element is used as a key).\n */\nfunction collectDomEventsInfo(tView, lView, eventTypesToReplay) {\n const domEventsInfo = new Map();\n const lCleanup = lView[CLEANUP];\n const tCleanup = tView.cleanup;\n if (!tCleanup || !lCleanup) {\n return domEventsInfo;\n }\n for (let i = 0; i < tCleanup.length;) {\n const firstParam = tCleanup[i++];\n const secondParam = tCleanup[i++];\n if (typeof firstParam !== 'string') {\n continue;\n }\n const eventType = firstParam;\n if (!isEarlyEventType(eventType)) {\n continue;\n }\n if (isCaptureEventType(eventType)) {\n eventTypesToReplay.capture.add(eventType);\n } else {\n eventTypesToReplay.regular.add(eventType);\n }\n const listenerElement = unwrapRNode(lView[secondParam]);\n i++; // move the cursor to the next position (location of the listener idx)\n const useCaptureOrIndx = tCleanup[i++];\n // if useCaptureOrIndx is boolean then report it as is.\n // if useCaptureOrIndx is positive number then it in unsubscribe method\n // if useCaptureOrIndx is negative number then it is a Subscription\n const isDomEvent = typeof useCaptureOrIndx === 'boolean' || useCaptureOrIndx >= 0;\n if (!isDomEvent) {\n continue;\n }\n if (!domEventsInfo.has(listenerElement)) {\n domEventsInfo.set(listenerElement, [eventType]);\n } else {\n domEventsInfo.get(listenerElement).push(eventType);\n }\n }\n return domEventsInfo;\n}\nfunction invokeRegisteredReplayListeners(injector, event, currentTarget) {\n const blockName = (currentTarget && currentTarget.getAttribute(DEFER_BLOCK_SSR_ID_ATTRIBUTE)) ?? '';\n if (/d\\d+/.test(blockName)) {\n hydrateAndInvokeBlockListeners(blockName, injector, event, currentTarget);\n } else if (event.eventPhase === EventPhase.REPLAY) {\n invokeListeners(event, currentTarget);\n }\n}\nfunction hydrateAndInvokeBlockListeners(blockName, injector, event, currentTarget) {\n blockEventQueue.push({\n event,\n currentTarget\n });\n triggerHydrationFromBlockName(injector, blockName, replayQueuedBlockEvents);\n}\nfunction replayQueuedBlockEvents(hydratedBlocks) {\n // clone the queue\n const queue = [...blockEventQueue];\n const hydrated = new Set(hydratedBlocks);\n // empty it\n blockEventQueue = [];\n for (let {\n event,\n currentTarget\n } of queue) {\n const blockName = currentTarget.getAttribute(DEFER_BLOCK_SSR_ID_ATTRIBUTE);\n if (hydrated.has(blockName)) {\n invokeListeners(event, currentTarget);\n } else {\n // requeue events that weren't yet hydrated\n blockEventQueue.push({\n event,\n currentTarget\n });\n }\n }\n}\n\n/**\n * A collection that tracks all serialized views (`ngh` DOM annotations)\n * to avoid duplication. An attempt to add a duplicate view results in the\n * collection returning the index of the previously collected serialized view.\n * This reduces the number of annotations needed for a given page.\n */\nclass SerializedViewCollection {\n views = [];\n indexByContent = new Map();\n add(serializedView) {\n const viewAsString = JSON.stringify(serializedView);\n if (!this.indexByContent.has(viewAsString)) {\n const index = this.views.length;\n this.views.push(serializedView);\n this.indexByContent.set(viewAsString, index);\n return index;\n }\n return this.indexByContent.get(viewAsString);\n }\n getAll() {\n return this.views;\n }\n}\n/**\n * Global counter that is used to generate a unique id for TViews\n * during the serialization process.\n */\nlet tViewSsrId = 0;\n/**\n * Generates a unique id for a given TView and returns this id.\n * The id is also stored on this instance of a TView and reused in\n * subsequent calls.\n *\n * This id is needed to uniquely identify and pick up dehydrated views\n * at runtime.\n */\nfunction getSsrId(tView) {\n if (!tView.ssrId) {\n tView.ssrId = `t${tViewSsrId++}`;\n }\n return tView.ssrId;\n}\n/**\n * Computes the number of root nodes in a given view\n * (or child nodes in a given container if a tNode is provided).\n */\nfunction calcNumRootNodes(tView, lView, tNode) {\n const rootNodes = [];\n collectNativeNodes(tView, lView, tNode, rootNodes);\n return rootNodes.length;\n}\n/**\n * Computes the number of root nodes in all views in a given LContainer.\n */\nfunction calcNumRootNodesInLContainer(lContainer) {\n const rootNodes = [];\n collectNativeNodesInLContainer(lContainer, rootNodes);\n return rootNodes.length;\n}\n/**\n * Annotates root level component's LView for hydration,\n * see `annotateHostElementForHydration` for additional information.\n */\nfunction annotateComponentLViewForHydration(lView, context, injector) {\n const hostElement = lView[HOST];\n // Root elements might also be annotated with the `ngSkipHydration` attribute,\n // check if it's present before starting the serialization process.\n if (hostElement && !hostElement.hasAttribute(SKIP_HYDRATION_ATTR_NAME)) {\n return annotateHostElementForHydration(hostElement, lView, null, context);\n }\n return null;\n}\n/**\n * Annotates root level LContainer for hydration. This happens when a root component\n * injects ViewContainerRef, thus making the component an anchor for a view container.\n * This function serializes the component itself as well as all views from the view\n * container.\n */\nfunction annotateLContainerForHydration(lContainer, context, injector) {\n const componentLView = unwrapLView(lContainer[HOST]);\n // Serialize the root component itself.\n const componentLViewNghIndex = annotateComponentLViewForHydration(componentLView, context, injector);\n if (componentLViewNghIndex === null) {\n // Component was not serialized (for example, if hydration was skipped by adding\n // the `ngSkipHydration` attribute or this component uses i18n blocks in the template,\n // but `withI18nSupport()` was not added), avoid annotating host element with the `ngh`\n // attribute.\n return;\n }\n const hostElement = unwrapRNode(componentLView[HOST]);\n // Serialize all views within this view container.\n const rootLView = lContainer[PARENT];\n const rootLViewNghIndex = annotateHostElementForHydration(hostElement, rootLView, null, context);\n const renderer = componentLView[RENDERER];\n // For cases when a root component also acts as an anchor node for a ViewContainerRef\n // (for example, when ViewContainerRef is injected in a root component), there is a need\n // to serialize information about the component itself, as well as an LContainer that\n // represents this ViewContainerRef. Effectively, we need to serialize 2 pieces of info:\n // (1) hydration info for the root component itself and (2) hydration info for the\n // ViewContainerRef instance (an LContainer). Each piece of information is included into\n // the hydration data (in the TransferState object) separately, thus we end up with 2 ids.\n // Since we only have 1 root element, we encode both bits of info into a single string:\n // ids are separated by the `|` char (e.g. `10|25`, where `10` is the ngh for a component view\n // and 25 is the `ngh` for a root view which holds LContainer).\n const finalIndex = `${componentLViewNghIndex}|${rootLViewNghIndex}`;\n renderer.setAttribute(hostElement, NGH_ATTR_NAME, finalIndex);\n}\n/**\n * Annotates all components bootstrapped in a given ApplicationRef\n * with info needed for hydration.\n *\n * @param appRef An instance of an ApplicationRef.\n * @param doc A reference to the current Document instance.\n * @return event types that need to be replayed\n */\nfunction annotateForHydration(appRef, doc) {\n const injector = appRef.injector;\n const isI18nHydrationEnabledVal = isI18nHydrationEnabled(injector);\n const isIncrementalHydrationEnabledVal = isIncrementalHydrationEnabled(injector);\n const serializedViewCollection = new SerializedViewCollection();\n const corruptedTextNodes = new Map();\n const viewRefs = appRef._views;\n const shouldReplayEvents = injector.get(IS_EVENT_REPLAY_ENABLED, EVENT_REPLAY_ENABLED_DEFAULT);\n const eventTypesToReplay = {\n regular: new Set(),\n capture: new Set()\n };\n const deferBlocks = new Map();\n const appId = appRef.injector.get(APP_ID);\n for (const viewRef of viewRefs) {\n const lNode = getLNodeForHydration(viewRef);\n // An `lView` might be `null` if a `ViewRef` represents\n // an embedded view (not a component view).\n if (lNode !== null) {\n const context = {\n serializedViewCollection,\n corruptedTextNodes,\n isI18nHydrationEnabled: isI18nHydrationEnabledVal,\n isIncrementalHydrationEnabled: isIncrementalHydrationEnabledVal,\n i18nChildren: new Map(),\n eventTypesToReplay,\n shouldReplayEvents,\n appId,\n deferBlocks\n };\n if (isLContainer(lNode)) {\n annotateLContainerForHydration(lNode, context, injector);\n } else {\n annotateComponentLViewForHydration(lNode, context, injector);\n }\n insertCorruptedTextNodeMarkers(corruptedTextNodes, doc);\n }\n }\n // Note: we *always* include hydration info key and a corresponding value\n // into the TransferState, even if the list of serialized views is empty.\n // This is needed as a signal to the client that the server part of the\n // hydration logic was setup and enabled correctly. Otherwise, if a client\n // hydration doesn't find a key in the transfer state - an error is produced.\n const serializedViews = serializedViewCollection.getAll();\n const transferState = injector.get(TransferState);\n transferState.set(NGH_DATA_KEY, serializedViews);\n if (deferBlocks.size > 0) {\n const blocks = {};\n for (const [id, info] of deferBlocks.entries()) {\n blocks[id] = info;\n }\n transferState.set(NGH_DEFER_BLOCKS_KEY, blocks);\n }\n return eventTypesToReplay;\n}\n/**\n * Serializes the lContainer data into a list of SerializedView objects,\n * that represent views within this lContainer.\n *\n * @param lContainer the lContainer we are serializing\n * @param tNode the TNode that contains info about this LContainer\n * @param lView that hosts this LContainer\n * @param parentDeferBlockId the defer block id of the parent if it exists\n * @param context the hydration context\n * @returns an array of the `SerializedView` objects\n */\nfunction serializeLContainer(lContainer, tNode, lView, parentDeferBlockId, context) {\n const views = [];\n let lastViewAsString = '';\n for (let i = CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {\n let childLView = lContainer[i];\n let template;\n let numRootNodes;\n let serializedView;\n if (isRootView(childLView)) {\n // If this is a root view, get an LView for the underlying component,\n // because it contains information about the view to serialize.\n childLView = childLView[HEADER_OFFSET];\n // If we have an LContainer at this position, this indicates that the\n // host element was used as a ViewContainerRef anchor (e.g. a `ViewContainerRef`\n // was injected within the component class). This case requires special handling.\n if (isLContainer(childLView)) {\n // Calculate the number of root nodes in all views in a given container\n // and increment by one to account for an anchor node itself, i.e. in this\n // scenario we'll have a layout that would look like this:\n // `<app-root /><#VIEW1><#VIEW2>...<!--container-->`\n // The `+1` is to capture the `<app-root />` element.\n numRootNodes = calcNumRootNodesInLContainer(childLView) + 1;\n annotateLContainerForHydration(childLView, context, lView[INJECTOR]);\n const componentLView = unwrapLView(childLView[HOST]);\n serializedView = {\n [TEMPLATE_ID]: componentLView[TVIEW].ssrId,\n [NUM_ROOT_NODES]: numRootNodes\n };\n }\n }\n if (!serializedView) {\n const childTView = childLView[TVIEW];\n if (childTView.type === 1 /* TViewType.Component */) {\n template = childTView.ssrId;\n // This is a component view, thus it has only 1 root node: the component\n // host node itself (other nodes would be inside that host node).\n numRootNodes = 1;\n } else {\n template = getSsrId(childTView);\n numRootNodes = calcNumRootNodes(childTView, childLView, childTView.firstChild);\n }\n serializedView = {\n [TEMPLATE_ID]: template,\n [NUM_ROOT_NODES]: numRootNodes\n };\n let isHydrateNeverBlock = false;\n // If this is a defer block, serialize extra info.\n if (isDeferBlock(lView[TVIEW], tNode)) {\n const lDetails = getLDeferBlockDetails(lView, tNode);\n const tDetails = getTDeferBlockDetails(lView[TVIEW], tNode);\n if (context.isIncrementalHydrationEnabled && tDetails.hydrateTriggers !== null) {\n const deferBlockId = `d${context.deferBlocks.size}`;\n if (tDetails.hydrateTriggers.has(7 /* DeferBlockTrigger.Never */)) {\n isHydrateNeverBlock = true;\n }\n let rootNodes = [];\n collectNativeNodesInLContainer(lContainer, rootNodes);\n // Add defer block into info context.deferBlocks\n const deferBlockInfo = {\n [NUM_ROOT_NODES]: rootNodes.length,\n [DEFER_BLOCK_STATE$1]: lDetails[DEFER_BLOCK_STATE]\n };\n const serializedTriggers = serializeHydrateTriggers(tDetails.hydrateTriggers);\n if (serializedTriggers.length > 0) {\n deferBlockInfo[DEFER_HYDRATE_TRIGGERS] = serializedTriggers;\n }\n if (parentDeferBlockId !== null) {\n // Serialize parent id only when it's present.\n deferBlockInfo[DEFER_PARENT_BLOCK_ID] = parentDeferBlockId;\n }\n context.deferBlocks.set(deferBlockId, deferBlockInfo);\n const node = unwrapRNode(lContainer);\n if (node !== undefined) {\n if (node.nodeType === Node.COMMENT_NODE) {\n annotateDeferBlockAnchorForHydration(node, deferBlockId);\n }\n } else {\n ngDevMode && validateNodeExists(node, childLView, tNode);\n ngDevMode && validateMatchingNode(node, Node.COMMENT_NODE, null, childLView, tNode, true);\n annotateDeferBlockAnchorForHydration(node, deferBlockId);\n }\n if (!isHydrateNeverBlock) {\n // Add JSAction attributes for root nodes that use some hydration triggers\n annotateDeferBlockRootNodesWithJsAction(tDetails, rootNodes, deferBlockId, context);\n }\n // Use current block id as parent for nested routes.\n parentDeferBlockId = deferBlockId;\n // Serialize extra info into the view object.\n // TODO(incremental-hydration): this should be serialized and included at a different level\n // (not at the view level).\n serializedView[DEFER_BLOCK_ID] = deferBlockId;\n }\n // DEFER_BLOCK_STATE is used for reconciliation in hydration, both regular and incremental.\n // We need to know which template is rendered when hydrating. So we serialize this state\n // regardless of hydration type.\n serializedView[DEFER_BLOCK_STATE$1] = lDetails[DEFER_BLOCK_STATE];\n }\n if (!isHydrateNeverBlock) {\n Object.assign(serializedView, serializeLView(lContainer[i], parentDeferBlockId, context));\n }\n }\n // Check if the previous view has the same shape (for example, it was\n // produced by the *ngFor), in which case bump the counter on the previous\n // view instead of including the same information again.\n const currentViewAsString = JSON.stringify(serializedView);\n if (views.length > 0 && currentViewAsString === lastViewAsString) {\n const previousView = views[views.length - 1];\n previousView[MULTIPLIER] ??= 1;\n previousView[MULTIPLIER]++;\n } else {\n // Record this view as most recently added.\n lastViewAsString = currentViewAsString;\n views.push(serializedView);\n }\n }\n return views;\n}\nfunction serializeHydrateTriggers(triggerMap) {\n const serializableDeferBlockTrigger = new Set([0 /* DeferBlockTrigger.Idle */, 1 /* DeferBlockTrigger.Immediate */, 2 /* DeferBlockTrigger.Viewport */, 5 /* DeferBlockTrigger.Timer */]);\n let triggers = [];\n for (let [trigger, details] of triggerMap) {\n if (serializableDeferBlockTrigger.has(trigger)) {\n if (details === null) {\n triggers.push(trigger);\n } else {\n triggers.push({\n trigger,\n delay: details.delay\n });\n }\n }\n }\n return triggers;\n}\n/**\n * Helper function to produce a node path (which navigation steps runtime logic\n * needs to take to locate a node) and stores it in the `NODES` section of the\n * current serialized view.\n */\nfunction appendSerializedNodePath(ngh, tNode, lView, excludedParentNodes) {\n const noOffsetIndex = tNode.index - HEADER_OFFSET;\n ngh[NODES] ??= {};\n // Ensure we don't calculate the path multiple times.\n ngh[NODES][noOffsetIndex] ??= calcPathForNode(tNode, lView, excludedParentNodes);\n}\n/**\n * Helper function to append information about a disconnected node.\n * This info is needed at runtime to avoid DOM lookups for this element\n * and instead, the element would be created from scratch.\n */\nfunction appendDisconnectedNodeIndex(ngh, tNodeOrNoOffsetIndex) {\n const noOffsetIndex = typeof tNodeOrNoOffsetIndex === 'number' ? tNodeOrNoOffsetIndex : tNodeOrNoOffsetIndex.index - HEADER_OFFSET;\n ngh[DISCONNECTED_NODES] ??= [];\n if (!ngh[DISCONNECTED_NODES].includes(noOffsetIndex)) {\n ngh[DISCONNECTED_NODES].push(noOffsetIndex);\n }\n}\n/**\n * Serializes the lView data into a SerializedView object that will later be added\n * to the TransferState storage and referenced using the `ngh` attribute on a host\n * element.\n *\n * @param lView the lView we are serializing\n * @param context the hydration context\n * @returns the `SerializedView` object containing the data to be added to the host node\n */\nfunction serializeLView(lView, parentDeferBlockId = null, context) {\n const ngh = {};\n const tView = lView[TVIEW];\n const i18nChildren = getOrComputeI18nChildren(tView, context);\n const nativeElementsToEventTypes = context.shouldReplayEvents ? collectDomEventsInfo(tView, lView, context.eventTypesToReplay) : null;\n // Iterate over DOM element references in an LView.\n for (let i = HEADER_OFFSET; i < tView.bindingStartIndex; i++) {\n const tNode = tView.data[i];\n const noOffsetIndex = i - HEADER_OFFSET;\n // Attempt to serialize any i18n data for the given slot. We do this first, as i18n\n // has its own process for serialization.\n const i18nData = trySerializeI18nBlock(lView, i, context);\n if (i18nData) {\n ngh[I18N_DATA] ??= {};\n ngh[I18N_DATA][noOffsetIndex] = i18nData.caseQueue;\n for (const nodeNoOffsetIndex of i18nData.disconnectedNodes) {\n appendDisconnectedNodeIndex(ngh, nodeNoOffsetIndex);\n }\n for (const nodeNoOffsetIndex of i18nData.disjointNodes) {\n const tNode = tView.data[nodeNoOffsetIndex + HEADER_OFFSET];\n ngDevMode && assertTNode(tNode);\n appendSerializedNodePath(ngh, tNode, lView, i18nChildren);\n }\n continue;\n }\n // Skip processing of a given slot in the following cases:\n // - Local refs (e.g. <div #localRef>) take up an extra slot in LViews\n // to store the same element. In this case, there is no information in\n // a corresponding slot in TNode data structure.\n // - When a slot contains something other than a TNode. For example, there\n // might be some metadata information about a defer block or a control flow block.\n if (!isTNodeShape(tNode)) {\n continue;\n }\n // Skip any nodes that are in an i18n block but are considered detached (i.e. not\n // present in the template). These nodes are disconnected from the DOM tree, and\n // so we don't want to serialize any information about them.\n if (isDetachedByI18n(tNode)) {\n continue;\n }\n // Check if a native node that represents a given TNode is disconnected from the DOM tree.\n // Such nodes must be excluded from the hydration (since the hydration won't be able to\n // find them), so the TNode ids are collected and used at runtime to skip the hydration.\n //\n // This situation may happen during the content projection, when some nodes don't make it\n // into one of the content projection slots (for example, when there is no default\n // <ng-content /> slot in projector component's template).\n if (isDisconnectedNode(tNode, lView) && isContentProjectedNode(tNode)) {\n appendDisconnectedNodeIndex(ngh, tNode);\n continue;\n }\n if (Array.isArray(tNode.projection)) {\n for (const projectionHeadTNode of tNode.projection) {\n // We may have `null`s in slots with no projected content.\n if (!projectionHeadTNode) continue;\n if (!Array.isArray(projectionHeadTNode)) {\n // If we process re-projected content (i.e. `<ng-content>`\n // appears at projection location), skip annotations for this content\n // since all DOM nodes in this projection were handled while processing\n // a parent lView, which contains those nodes.\n if (!isProjectionTNode(projectionHeadTNode) && !isInSkipHydrationBlock(projectionHeadTNode)) {\n if (isDisconnectedNode(projectionHeadTNode, lView)) {\n // Check whether this node is connected, since we may have a TNode\n // in the data structure as a projection segment head, but the\n // content projection slot might be disabled (e.g.\n // <ng-content *ngIf=\"false\" />).\n appendDisconnectedNodeIndex(ngh, projectionHeadTNode);\n } else {\n appendSerializedNodePath(ngh, projectionHeadTNode, lView, i18nChildren);\n }\n }\n } else {\n // If a value is an array, it means that we are processing a projection\n // where projectable nodes were passed in as DOM nodes (for example, when\n // calling `ViewContainerRef.createComponent(CmpA, {projectableNodes: [...]})`).\n //\n // In this scenario, nodes can come from anywhere (either created manually,\n // accessed via `document.querySelector`, etc) and may be in any state\n // (attached or detached from the DOM tree). As a result, we can not reliably\n // restore the state for such cases during hydration.\n throw unsupportedProjectionOfDomNodes(unwrapRNode(lView[i]));\n }\n }\n }\n conditionallyAnnotateNodePath(ngh, tNode, lView, i18nChildren);\n if (isLContainer(lView[i])) {\n // Serialize information about a template.\n const embeddedTView = tNode.tView;\n if (embeddedTView !== null) {\n ngh[TEMPLATES] ??= {};\n ngh[TEMPLATES][noOffsetIndex] = getSsrId(embeddedTView);\n }\n // Serialize views within this LContainer.\n const hostNode = lView[i][HOST]; // host node of this container\n // LView[i][HOST] can be of 2 different types:\n // - either a DOM node\n // - or an array that represents an LView of a component\n if (Array.isArray(hostNode)) {\n // This is a component, serialize info about it.\n const targetNode = unwrapRNode(hostNode);\n if (!targetNode.hasAttribute(SKIP_HYDRATION_ATTR_NAME)) {\n annotateHostElementForHydration(targetNode, hostNode, parentDeferBlockId, context);\n }\n }\n ngh[CONTAINERS] ??= {};\n ngh[CONTAINERS][noOffsetIndex] = serializeLContainer(lView[i], tNode, lView, parentDeferBlockId, context);\n } else if (Array.isArray(lView[i]) && !isLetDeclaration(tNode)) {\n // This is a component, annotate the host node with an `ngh` attribute.\n // Note: Let declarations that return an array are also storing an array in the LView,\n // we need to exclude them.\n const targetNode = unwrapRNode(lView[i][HOST]);\n if (!targetNode.hasAttribute(SKIP_HYDRATION_ATTR_NAME)) {\n annotateHostElementForHydration(targetNode, lView[i], parentDeferBlockId, context);\n }\n } else {\n // <ng-container> case\n if (tNode.type & 8 /* TNodeType.ElementContainer */) {\n // An <ng-container> is represented by the number of\n // top-level nodes. This information is needed to skip over\n // those nodes to reach a corresponding anchor node (comment node).\n ngh[ELEMENT_CONTAINERS] ??= {};\n ngh[ELEMENT_CONTAINERS][noOffsetIndex] = calcNumRootNodes(tView, lView, tNode.child);\n } else if (tNode.type & (16 /* TNodeType.Projection */ | 128 /* TNodeType.LetDeclaration */)) {\n // Current TNode represents an `<ng-content>` slot or `@let` declaration,\n // thus it has no DOM elements associated with it, so the **next sibling**\n // node would not be able to find an anchor. In this case, use full path instead.\n let nextTNode = tNode.next;\n // Skip over all `<ng-content>` slots and `@let` declarations in a row.\n while (nextTNode !== null && nextTNode.type & (16 /* TNodeType.Projection */ | 128 /* TNodeType.LetDeclaration */)) {\n nextTNode = nextTNode.next;\n }\n if (nextTNode && !isInSkipHydrationBlock(nextTNode)) {\n // Handle a tNode after the `<ng-content>` slot.\n appendSerializedNodePath(ngh, nextTNode, lView, i18nChildren);\n }\n } else if (tNode.type & 1 /* TNodeType.Text */) {\n const rNode = unwrapRNode(lView[i]);\n processTextNodeBeforeSerialization(context, rNode);\n }\n }\n // Attach `jsaction` attribute to elements that have registered listeners,\n // thus potentially having a need to do an event replay.\n if (nativeElementsToEventTypes && tNode.type & 2 /* TNodeType.Element */) {\n const nativeElement = unwrapRNode(lView[i]);\n if (nativeElementsToEventTypes.has(nativeElement)) {\n setJSActionAttributes(nativeElement, nativeElementsToEventTypes.get(nativeElement), parentDeferBlockId);\n }\n }\n }\n return ngh;\n}\n/**\n * Serializes node location in cases when it's needed, specifically:\n *\n * 1. If `tNode.projectionNext` is different from `tNode.next` - it means that\n * the next `tNode` after projection is different from the one in the original\n * template. Since hydration relies on `tNode.next`, this serialized info\n * is required to help runtime code find the node at the correct location.\n * 2. In certain content projection-based use-cases, it's possible that only\n * a content of a projected element is rendered. In this case, content nodes\n * require an extra annotation, since runtime logic can't rely on parent-child\n * connection to identify the location of a node.\n */\nfunction conditionallyAnnotateNodePath(ngh, tNode, lView, excludedParentNodes) {\n if (isProjectionTNode(tNode)) {\n // Do not annotate projection nodes (<ng-content />), since\n // they don't have a corresponding DOM node representing them.\n return;\n }\n // Handle case #1 described above.\n if (tNode.projectionNext && tNode.projectionNext !== tNode.next && !isInSkipHydrationBlock(tNode.projectionNext)) {\n appendSerializedNodePath(ngh, tNode.projectionNext, lView, excludedParentNodes);\n }\n // Handle case #2 described above.\n // Note: we only do that for the first node (i.e. when `tNode.prev === null`),\n // the rest of the nodes would rely on the current node location, so no extra\n // annotation is needed.\n if (tNode.prev === null && tNode.parent !== null && isDisconnectedNode(tNode.parent, lView) && !isDisconnectedNode(tNode, lView)) {\n appendSerializedNodePath(ngh, tNode, lView, excludedParentNodes);\n }\n}\n/**\n * Determines whether a component instance that is represented\n * by a given LView uses `ViewEncapsulation.ShadowDom`.\n */\nfunction componentUsesShadowDomEncapsulation(lView) {\n const instance = lView[CONTEXT];\n return instance?.constructor ? getComponentDef(instance.constructor)?.encapsulation === ViewEncapsulation.ShadowDom : false;\n}\n/**\n * Annotates component host element for hydration:\n * - by either adding the `ngh` attribute and collecting hydration-related info\n * for the serialization and transferring to the client\n * - or by adding the `ngSkipHydration` attribute in case Angular detects that\n * component contents is not compatible with hydration.\n *\n * @param element The Host element to be annotated\n * @param lView The associated LView\n * @param context The hydration context\n * @returns An index of serialized view from the transfer state object\n * or `null` when a given component can not be serialized.\n */\nfunction annotateHostElementForHydration(element, lView, parentDeferBlockId, context) {\n const renderer = lView[RENDERER];\n if (hasI18n(lView) && !isI18nHydrationSupportEnabled() || componentUsesShadowDomEncapsulation(lView)) {\n // Attach the skip hydration attribute if this component:\n // - either has i18n blocks, since hydrating such blocks is not yet supported\n // - or uses ShadowDom view encapsulation, since Domino doesn't support\n // shadow DOM, so we can not guarantee that client and server representations\n // would exactly match\n renderer.setAttribute(element, SKIP_HYDRATION_ATTR_NAME, '');\n return null;\n } else {\n const ngh = serializeLView(lView, parentDeferBlockId, context);\n const index = context.serializedViewCollection.add(ngh);\n renderer.setAttribute(element, NGH_ATTR_NAME, index.toString());\n return index;\n }\n}\n/**\n * Annotates defer block comment node for hydration:\n *\n * @param comment The Host element to be annotated\n * @param deferBlockId the id of the target defer block\n */\nfunction annotateDeferBlockAnchorForHydration(comment, deferBlockId) {\n comment.textContent = `ngh=${deferBlockId}`;\n}\n/**\n * Physically inserts the comment nodes to ensure empty text nodes and adjacent\n * text node separators are preserved after server serialization of the DOM.\n * These get swapped back for empty text nodes or separators once hydration happens\n * on the client.\n *\n * @param corruptedTextNodes The Map of text nodes to be replaced with comments\n * @param doc The document\n */\nfunction insertCorruptedTextNodeMarkers(corruptedTextNodes, doc) {\n for (const [textNode, marker] of corruptedTextNodes) {\n textNode.after(doc.createComment(marker));\n }\n}\n/**\n * Detects whether a given TNode represents a node that\n * is being content projected.\n */\nfunction isContentProjectedNode(tNode) {\n let currentTNode = tNode;\n while (currentTNode != null) {\n // If we come across a component host node in parent nodes -\n // this TNode is in the content projection section.\n if (isComponentHost(currentTNode)) {\n return true;\n }\n currentTNode = currentTNode.parent;\n }\n return false;\n}\n/**\n * Incremental hydration requires that any defer block root node\n * with interaction or hover triggers have all of their root nodes\n * trigger hydration with those events. So we need to make sure all\n * the root nodes of that block have the proper jsaction attribute\n * to ensure hydration is triggered, since the content is dehydrated\n */\nfunction annotateDeferBlockRootNodesWithJsAction(tDetails, rootNodes, parentDeferBlockId, context) {\n const actionList = convertHydrateTriggersToJsAction(tDetails.hydrateTriggers);\n for (let et of actionList) {\n context.eventTypesToReplay.regular.add(et);\n }\n if (actionList.length > 0) {\n const elementNodes = rootNodes.filter(rn => rn.nodeType === Node.ELEMENT_NODE);\n for (let rNode of elementNodes) {\n setJSActionAttributes(rNode, actionList, parentDeferBlockId);\n }\n }\n}\n\n/**\n * Indicates whether the hydration-related code was added,\n * prevents adding it multiple times.\n */\nlet isHydrationSupportEnabled = false;\n/**\n * Indicates whether the i18n-related code was added,\n * prevents adding it multiple times.\n *\n * Note: This merely controls whether the code is loaded,\n * while `setIsI18nHydrationSupportEnabled` determines\n * whether i18n blocks are serialized or hydrated.\n */\nlet isI18nHydrationRuntimeSupportEnabled = false;\n/**\n * Indicates whether the incremental hydration code was added,\n * prevents adding it multiple times.\n */\nlet isIncrementalHydrationRuntimeSupportEnabled = false;\n/**\n * Defines a period of time that Angular waits for the `ApplicationRef.isStable` to emit `true`.\n * If there was no event with the `true` value during this time, Angular reports a warning.\n */\nconst APPLICATION_IS_STABLE_TIMEOUT = 10_000;\n/**\n * Brings the necessary hydration code in tree-shakable manner.\n * The code is only present when the `provideClientHydration` is\n * invoked. Otherwise, this code is tree-shaken away during the\n * build optimization step.\n *\n * This technique allows us to swap implementations of methods so\n * tree shaking works appropriately when hydration is disabled or\n * enabled. It brings in the appropriate version of the method that\n * supports hydration only when enabled.\n */\nfunction enableHydrationRuntimeSupport() {\n if (!isHydrationSupportEnabled) {\n isHydrationSupportEnabled = true;\n enableRetrieveHydrationInfoImpl();\n enableLocateOrCreateElementNodeImpl();\n enableLocateOrCreateTextNodeImpl();\n enableLocateOrCreateElementContainerNodeImpl();\n enableLocateOrCreateContainerAnchorImpl();\n enableLocateOrCreateContainerRefImpl();\n enableFindMatchingDehydratedViewImpl();\n enableApplyRootElementTransformImpl();\n }\n}\n/**\n * Brings the necessary i18n hydration code in tree-shakable manner.\n * Similar to `enableHydrationRuntimeSupport`, the code is only\n * present when `withI18nSupport` is invoked.\n */\nfunction enableI18nHydrationRuntimeSupport() {\n if (!isI18nHydrationRuntimeSupportEnabled) {\n isI18nHydrationRuntimeSupportEnabled = true;\n enableLocateOrCreateI18nNodeImpl();\n enablePrepareI18nBlockForHydrationImpl();\n enableClaimDehydratedIcuCaseImpl();\n }\n}\n/**\n * Brings the necessary incremental hydration code in tree-shakable manner.\n * Similar to `enableHydrationRuntimeSupport`, the code is only\n * present when `enableIncrementalHydrationRuntimeSupport` is invoked.\n */\nfunction enableIncrementalHydrationRuntimeSupport() {\n if (!isIncrementalHydrationRuntimeSupportEnabled) {\n isIncrementalHydrationRuntimeSupportEnabled = true;\n enableRetrieveDeferBlockDataImpl();\n }\n}\n/**\n * Outputs a message with hydration stats into a console.\n */\nfunction printHydrationStats(injector) {\n const console = injector.get(Console);\n const message = `Angular hydrated ${ngDevMode.hydratedComponents} component(s) ` + `and ${ngDevMode.hydratedNodes} node(s), ` + `${ngDevMode.componentsSkippedHydration} component(s) were skipped. ` + (isIncrementalHydrationEnabled(injector) ? `${ngDevMode.deferBlocksWithIncrementalHydration} defer block(s) were configured to use incremental hydration. ` : '') + `Learn more at https://angular.dev/guide/hydration.`;\n // tslint:disable-next-line:no-console\n console.log(message);\n}\n/**\n * Returns a Promise that is resolved when an application becomes stable.\n */\nfunction whenStableWithTimeout(appRef) {\n const whenStablePromise = appRef.whenStable();\n if (typeof ngDevMode !== 'undefined' && ngDevMode) {\n const timeoutTime = APPLICATION_IS_STABLE_TIMEOUT;\n const console = appRef.injector.get(Console);\n const ngZone = appRef.injector.get(NgZone);\n // The following call should not and does not prevent the app to become stable\n // We cannot use RxJS timer here because the app would remain unstable.\n // This also avoids an extra change detection cycle.\n const timeoutId = ngZone.runOutsideAngular(() => {\n return setTimeout(() => logWarningOnStableTimedout(timeoutTime, console), timeoutTime);\n });\n whenStablePromise.finally(() => clearTimeout(timeoutId));\n }\n return whenStablePromise;\n}\n/**\n * Defines a name of an attribute that is added to the <body> tag\n * in the `index.html` file in case a given route was configured\n * with `RenderMode.Client`. 'cm' is an abbreviation for \"Client Mode\".\n */\nconst CLIENT_RENDER_MODE_FLAG = 'ngcm';\n/**\n * Checks whether the `RenderMode.Client` was defined for the current route.\n */\nfunction isClientRenderModeEnabled() {\n const doc = getDocument();\n return (typeof ngServerMode === 'undefined' || !ngServerMode) && doc.body.hasAttribute(CLIENT_RENDER_MODE_FLAG);\n}\n/**\n * Returns a set of providers required to setup hydration support\n * for an application that is server side rendered. This function is\n * included into the `provideClientHydration` public API function from\n * the `platform-browser` package.\n *\n * The function sets up an internal flag that would be recognized during\n * the server side rendering time as well, so there is no need to\n * configure or change anything in NgUniversal to enable the feature.\n */\nfunction withDomHydration() {\n const providers = [{\n provide: IS_HYDRATION_DOM_REUSE_ENABLED,\n useFactory: () => {\n let isEnabled = true;\n if (typeof ngServerMode === 'undefined' || !ngServerMode) {\n // On the client, verify that the server response contains\n // hydration annotations. Otherwise, keep hydration disabled.\n const transferState = inject(TransferState, {\n optional: true\n });\n isEnabled = !!transferState?.get(NGH_DATA_KEY, null);\n }\n if (isEnabled) {\n performanceMarkFeature('NgHydration');\n }\n return isEnabled;\n }\n }, {\n provide: ENVIRONMENT_INITIALIZER,\n useValue: () => {\n // i18n support is enabled by calling withI18nSupport(), but there's\n // no way to turn it off (e.g. for tests), so we turn it off by default.\n setIsI18nHydrationSupportEnabled(false);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n // Since this function is used across both server and client,\n // make sure that the runtime code is only added when invoked\n // on the client (see the `enableHydrationRuntimeSupport` function\n // call below).\n return;\n }\n if (inject(IS_HYDRATION_DOM_REUSE_ENABLED)) {\n verifySsrContentsIntegrity();\n enableHydrationRuntimeSupport();\n } else if (typeof ngDevMode !== 'undefined' && ngDevMode && !isClientRenderModeEnabled()) {\n const console = inject(Console);\n const message = formatRuntimeError(-505 /* RuntimeErrorCode.MISSING_HYDRATION_ANNOTATIONS */, 'Angular hydration was requested on the client, but there was no ' + 'serialized information present in the server response, ' + 'thus hydration was not enabled. ' + 'Make sure the `provideClientHydration()` is included into the list ' + 'of providers in the server part of the application configuration.');\n console.warn(message);\n }\n },\n multi: true\n }];\n if (typeof ngServerMode === 'undefined' || !ngServerMode) {\n providers.push({\n provide: PRESERVE_HOST_CONTENT,\n useFactory: () => {\n // Preserve host element content only in a browser\n // environment and when hydration is configured properly.\n // On a server, an application is rendered from scratch,\n // so the host content needs to be empty.\n return inject(IS_HYDRATION_DOM_REUSE_ENABLED);\n }\n }, {\n provide: APP_BOOTSTRAP_LISTENER,\n useFactory: () => {\n if (inject(IS_HYDRATION_DOM_REUSE_ENABLED)) {\n const appRef = inject(ApplicationRef);\n return () => {\n // Wait until an app becomes stable and cleanup all views that\n // were not claimed during the application bootstrap process.\n // The timing is similar to when we start the serialization process\n // on the server.\n //\n // Note: the cleanup task *MUST* be scheduled within the Angular zone in Zone apps\n // to ensure that change detection is properly run afterward.\n whenStableWithTimeout(appRef).then(() => {\n // Note: we have to check whether the application is destroyed before\n // performing other operations with the `injector`.\n // The application may be destroyed **before** it becomes stable, so when\n // the `whenStableWithTimeout` resolves, the injector might already be in\n // a destroyed state. Thus, calling `injector.get` would throw an error\n // indicating that the injector has already been destroyed.\n if (appRef.destroyed) {\n return;\n }\n cleanupDehydratedViews(appRef);\n if (typeof ngDevMode !== 'undefined' && ngDevMode) {\n countBlocksSkippedByHydration(appRef.injector);\n printHydrationStats(appRef.injector);\n }\n });\n };\n }\n return () => {}; // noop\n },\n multi: true\n });\n }\n return makeEnvironmentProviders(providers);\n}\n/**\n * Returns a set of providers required to setup support for i18n hydration.\n * Requires hydration to be enabled separately.\n */\nfunction withI18nSupport() {\n return [{\n provide: IS_I18N_HYDRATION_ENABLED,\n useFactory: () => inject(IS_HYDRATION_DOM_REUSE_ENABLED)\n }, {\n provide: ENVIRONMENT_INITIALIZER,\n useValue: () => {\n if (inject(IS_HYDRATION_DOM_REUSE_ENABLED)) {\n enableI18nHydrationRuntimeSupport();\n setIsI18nHydrationSupportEnabled(true);\n performanceMarkFeature('NgI18nHydration');\n }\n },\n multi: true\n }];\n}\n/**\n * Returns a set of providers required to setup support for incremental hydration.\n * Requires hydration to be enabled separately.\n * Enabling incremental hydration also enables event replay for the entire app.\n *\n * @developerPreview\n */\nfunction withIncrementalHydration() {\n const providers = [withEventReplay(), {\n provide: IS_INCREMENTAL_HYDRATION_ENABLED,\n useValue: true\n }, {\n provide: DEHYDRATED_BLOCK_REGISTRY,\n useClass: DehydratedBlockRegistry\n }, {\n provide: ENVIRONMENT_INITIALIZER,\n useValue: () => {\n enableIncrementalHydrationRuntimeSupport();\n performanceMarkFeature('NgIncrementalHydration');\n },\n multi: true\n }];\n if (typeof ngServerMode === 'undefined' || !ngServerMode) {\n providers.push({\n provide: APP_BOOTSTRAP_LISTENER,\n useFactory: () => {\n const injector = inject(Injector);\n const doc = getDocument();\n return () => {\n const deferBlockData = processBlockData(injector);\n const commentsByBlockId = gatherDeferBlocksCommentNodes(doc, doc.body);\n processAndInitTriggers(injector, deferBlockData, commentsByBlockId);\n appendDeferBlocksToJSActionMap(doc, injector);\n };\n },\n multi: true\n });\n }\n return providers;\n}\n/**\n *\n * @param time The time in ms until the stable timedout warning message is logged\n */\nfunction logWarningOnStableTimedout(time, console) {\n const message = `Angular hydration expected the ApplicationRef.isStable() to emit \\`true\\`, but it ` + `didn't happen within ${time}ms. Angular hydration logic depends on the application becoming stable ` + `as a signal to complete hydration process.`;\n console.warn(formatRuntimeError(-506 /* RuntimeErrorCode.HYDRATION_STABLE_TIMEDOUT */, message));\n}\n/**\n * Verifies whether the DOM contains a special marker added during SSR time to make sure\n * there is no SSR'ed contents transformations happen after SSR is completed. Typically that\n * happens either by CDN or during the build process as an optimization to remove comment nodes.\n * Hydration process requires comment nodes produced by Angular to locate correct DOM segments.\n * When this special marker is *not* present - throw an error and do not proceed with hydration,\n * since it will not be able to function correctly.\n *\n * Note: this function is invoked only on the client, so it's safe to use DOM APIs.\n */\nfunction verifySsrContentsIntegrity() {\n const doc = getDocument();\n let hydrationMarker;\n for (const node of doc.body.childNodes) {\n if (node.nodeType === Node.COMMENT_NODE && node.textContent?.trim() === SSR_CONTENT_INTEGRITY_MARKER) {\n hydrationMarker = node;\n break;\n }\n }\n if (!hydrationMarker) {\n throw new RuntimeError(-507 /* RuntimeErrorCode.MISSING_SSR_CONTENT_INTEGRITY_MARKER */, typeof ngDevMode !== 'undefined' && ngDevMode && 'Angular hydration logic detected that HTML content of this page was modified after it ' + 'was produced during server side rendering. Make sure that there are no optimizations ' + 'that remove comment nodes from HTML enabled on your CDN. Angular hydration ' + 'relies on HTML produced by the server, including whitespaces and comment nodes.');\n }\n}\n\n/**\n * Transforms a value (typically a string) to a boolean.\n * Intended to be used as a transform function of an input.\n *\n * @usageNotes\n * ```ts\n * @Input({ transform: booleanAttribute }) status!: boolean;\n * ```\n * @param value Value to be transformed.\n *\n * @publicApi\n */\nfunction booleanAttribute(value) {\n return typeof value === 'boolean' ? value : value != null && value !== 'false';\n}\n/**\n * Transforms a value (typically a string) to a number.\n * Intended to be used as a transform function of an input.\n * @param value Value to be transformed.\n * @param fallbackValue Value to use if the provided value can't be parsed as a number.\n *\n * @usageNotes\n * ```ts\n * @Input({ transform: numberAttribute }) id!: number;\n * ```\n *\n * @publicApi\n */\nfunction numberAttribute(value, fallbackValue = NaN) {\n // parseFloat(value) handles most of the cases we're interested in (it treats null, empty string,\n // and other non-number values as NaN, where Number just uses 0) but it considers the string\n // '123hello' to be a valid number. Therefore we also check if Number(value) is NaN.\n const isNumberValue = !isNaN(parseFloat(value)) && !isNaN(Number(value));\n return isNumberValue ? Number(value) : fallbackValue;\n}\nconst PERFORMANCE_MARK_PREFIX = '🅰ï¸';\nlet enablePerfLogging = false;\n/**\n * Function that will start measuring against the performance API\n * Should be used in pair with stopMeasuring\n */\nfunction startMeasuring(label) {\n if (!enablePerfLogging) {\n return;\n }\n const {\n startLabel\n } = labels(label);\n /* tslint:disable:ban */\n performance.mark(startLabel);\n /* tslint:enable:ban */\n}\n/**\n * Function that will stop measuring against the performance API\n * Should be used in pair with stopMeasuring\n */\nfunction stopMeasuring(label) {\n if (!enablePerfLogging) {\n return;\n }\n const {\n startLabel,\n labelName,\n endLabel\n } = labels(label);\n /* tslint:disable:ban */\n performance.mark(endLabel);\n performance.measure(labelName, startLabel, endLabel);\n performance.clearMarks(startLabel);\n performance.clearMarks(endLabel);\n /* tslint:enable:ban */\n}\nfunction labels(label) {\n const labelName = `${PERFORMANCE_MARK_PREFIX}:${label}`;\n return {\n labelName,\n startLabel: `start:${labelName}`,\n endLabel: `end:${labelName}`\n };\n}\nlet warningLogged = false;\n/**\n * This enables an internal performance profiler\n *\n * It should not be imported in application code\n */\nfunction enableProfiling() {\n if (!warningLogged && (typeof performance === 'undefined' || !performance.mark || !performance.measure)) {\n warningLogged = true;\n console.warn('Performance API is not supported on this platform');\n return;\n }\n enablePerfLogging = true;\n}\nfunction disableProfiling() {\n enablePerfLogging = false;\n}\n\n/**\n * Execute an arbitrary function in a non-reactive (non-tracking) context. The executed function\n * can, optionally, return a value.\n */\nfunction untracked(nonReactiveReadsFn) {\n const prevConsumer = setActiveConsumer$1(null);\n // We are not trying to catch any particular errors here, just making sure that the consumers\n // stack is restored in case of errors.\n try {\n return nonReactiveReadsFn();\n } finally {\n setActiveConsumer$1(prevConsumer);\n }\n}\n\n/**\n * Create a computed `Signal` which derives a reactive value from an expression.\n */\nfunction computed(computation, options) {\n const getter = createComputed$1(computation);\n if (options?.equal) {\n getter[SIGNAL$1].equal = options.equal;\n }\n if (ngDevMode) {\n getter.toString = () => `[Computed: ${getter()}]`;\n getter[SIGNAL$1].debugName = options?.debugName;\n }\n return getter;\n}\n\n/**\n * Controls whether effects use the legacy `microtaskEffect` by default.\n */\nconst USE_MICROTASK_EFFECT_BY_DEFAULT = false;\nclass MicrotaskEffectScheduler extends ZoneAwareEffectScheduler {\n pendingTasks = inject(PendingTasksInternal);\n taskId = null;\n schedule(effect) {\n // Check whether there are any pending effects _before_ queueing in the base class.\n super.schedule(effect);\n if (this.taskId === null) {\n this.taskId = this.pendingTasks.add();\n queueMicrotask(() => this.flush());\n }\n }\n flush() {\n try {\n super.flush();\n } finally {\n if (this.taskId !== null) {\n this.pendingTasks.remove(this.taskId);\n this.taskId = null;\n }\n }\n }\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: MicrotaskEffectScheduler,\n providedIn: 'root',\n factory: () => new MicrotaskEffectScheduler()\n });\n}\n/**\n * Core reactive node for an Angular effect.\n *\n * `EffectHandle` combines the reactive graph's `Watch` base node for effects with the framework's\n * scheduling abstraction (`MicrotaskEffectScheduler`) as well as automatic cleanup via `DestroyRef`\n * if available/requested.\n */\nclass EffectHandle {\n scheduler;\n effectFn;\n zone;\n injector;\n unregisterOnDestroy;\n watcher;\n constructor(scheduler, effectFn, zone, destroyRef, injector, allowSignalWrites) {\n this.scheduler = scheduler;\n this.effectFn = effectFn;\n this.zone = zone;\n this.injector = injector;\n this.watcher = createWatch$1(onCleanup => this.runEffect(onCleanup), () => this.schedule(), allowSignalWrites);\n this.unregisterOnDestroy = destroyRef?.onDestroy(() => this.destroy());\n }\n runEffect(onCleanup) {\n try {\n this.effectFn(onCleanup);\n } catch (err) {\n // Inject the `ErrorHandler` here in order to avoid circular DI error\n // if the effect is used inside of a custom `ErrorHandler`.\n const errorHandler = this.injector.get(ErrorHandler, null, {\n optional: true\n });\n errorHandler?.handleError(err);\n }\n }\n run() {\n this.watcher.run();\n }\n schedule() {\n this.scheduler.schedule(this);\n }\n destroy() {\n this.watcher.destroy();\n this.unregisterOnDestroy?.();\n // Note: if the effect is currently scheduled, it's not un-scheduled, and so the scheduler will\n // retain a reference to it. Attempting to execute it will be a no-op.\n }\n}\n// Just used for the name for the debug error below.\nfunction effect$1() {}\n/**\n * Create a global `Effect` for the given reactive function.\n */\nfunction microtaskEffect(effectFn, options) {\n ngDevMode && assertNotInReactiveContext(effect$1, 'Call `effect` outside of a reactive context. For example, schedule the ' + 'effect inside the component constructor.');\n !options?.injector && assertInInjectionContext(effect$1);\n const injector = options?.injector ?? inject(Injector);\n const destroyRef = options?.manualCleanup !== true ? injector.get(DestroyRef) : null;\n const handle = new EffectHandle(injector.get(MicrotaskEffectScheduler), effectFn, typeof Zone === 'undefined' ? null : Zone.current, destroyRef, injector, options?.allowSignalWrites ?? false);\n // Effects need to be marked dirty manually to trigger their initial run. The timing of this\n // marking matters, because the effects may read signals that track component inputs, which are\n // only available after those components have had their first update pass.\n //\n // We inject `ChangeDetectorRef` optionally, to determine whether this effect is being created in\n // the context of a component or not. If it is, then we check whether the component has already\n // run its update pass, and defer the effect's initial scheduling until the update pass if it\n // hasn't already run.\n const cdr = injector.get(ChangeDetectorRef, null, {\n optional: true\n });\n if (!cdr || !(cdr._lView[FLAGS] & 8 /* LViewFlags.FirstLViewPass */)) {\n // This effect is either not running in a view injector, or the view has already\n // undergone its first change detection pass, which is necessary for any required inputs to be\n // set.\n handle.watcher.notify();\n } else {\n // Delay the initialization of the effect until the view is fully initialized.\n (cdr._lView[EFFECTS_TO_SCHEDULE] ??= []).push(handle.watcher.notify);\n }\n return handle;\n}\nlet useMicrotaskEffectsByDefault = USE_MICROTASK_EFFECT_BY_DEFAULT;\n/**\n * Toggle the flag on whether to use microtask effects (for testing).\n */\nfunction setUseMicrotaskEffectsByDefault(value) {\n const prev = useMicrotaskEffectsByDefault;\n useMicrotaskEffectsByDefault = value;\n return prev;\n}\nclass EffectRefImpl {\n [SIGNAL$1];\n constructor(node) {\n this[SIGNAL$1] = node;\n }\n destroy() {\n this[SIGNAL$1].destroy();\n }\n}\n/**\n * Registers an \"effect\" that will be scheduled & executed whenever the signals that it reads\n * changes.\n *\n * Angular has two different kinds of effect: component effects and root effects. Component effects\n * are created when `effect()` is called from a component, directive, or within a service of a\n * component/directive. Root effects are created when `effect()` is called from outside the\n * component tree, such as in a root service, or when the `forceRoot` option is provided.\n *\n * The two effect types differ in their timing. Component effects run as a component lifecycle\n * event during Angular's synchronization (change detection) process, and can safely read input\n * signals or create/destroy views that depend on component state. Root effects run as microtasks\n * and have no connection to the component tree or change detection.\n *\n * `effect()` must be run in injection context, unless the `injector` option is manually specified.\n *\n * @developerPreview\n */\nfunction effect(effectFn, options) {\n if (useMicrotaskEffectsByDefault) {\n if (ngDevMode && options?.forceRoot) {\n throw new Error(`Cannot use 'forceRoot' option with microtask effects on`);\n }\n return microtaskEffect(effectFn, options);\n }\n ngDevMode && assertNotInReactiveContext(effect, 'Call `effect` outside of a reactive context. For example, schedule the ' + 'effect inside the component constructor.');\n !options?.injector && assertInInjectionContext(effect);\n if (ngDevMode && options?.allowSignalWrites !== undefined) {\n console.warn(`The 'allowSignalWrites' flag is deprecated and no longer impacts effect() (writes are always allowed)`);\n }\n const injector = options?.injector ?? inject(Injector);\n let destroyRef = options?.manualCleanup !== true ? injector.get(DestroyRef) : null;\n let node;\n const viewContext = injector.get(ViewContext, null, {\n optional: true\n });\n const notifier = injector.get(ChangeDetectionScheduler);\n if (viewContext !== null && !options?.forceRoot) {\n // This effect was created in the context of a view, and will be associated with the view.\n node = createViewEffect(viewContext.view, notifier, effectFn);\n if (destroyRef instanceof NodeInjectorDestroyRef && destroyRef._lView === viewContext.view) {\n // The effect is being created in the same view as the `DestroyRef` references, so it will be\n // automatically destroyed without the need for an explicit `DestroyRef` registration.\n destroyRef = null;\n }\n } else {\n // This effect was created outside the context of a view, and will be scheduled independently.\n node = createRootEffect(effectFn, injector.get(EffectScheduler), notifier);\n }\n node.injector = injector;\n if (destroyRef !== null) {\n // If we need to register for cleanup, do that here.\n node.onDestroyFn = destroyRef.onDestroy(() => node.destroy());\n }\n const effectRef = new EffectRefImpl(node);\n if (ngDevMode) {\n node.debugName = options?.debugName ?? '';\n const prevInjectorProfilerContext = setInjectorProfilerContext({\n injector,\n token: null\n });\n try {\n emitEffectCreatedEvent(effectRef);\n } finally {\n setInjectorProfilerContext(prevInjectorProfilerContext);\n }\n }\n return effectRef;\n}\n/**\n * Not public API, which guarantees `EffectScheduler` only ever comes from the application root\n * injector.\n */\nconst APP_EFFECT_SCHEDULER = /* @__PURE__ */new InjectionToken('', {\n providedIn: 'root',\n factory: () => inject(EffectScheduler)\n});\nconst BASE_EFFECT_NODE = /* @__PURE__ */(() => ({\n ...REACTIVE_NODE$1,\n consumerIsAlwaysLive: true,\n consumerAllowSignalWrites: true,\n dirty: true,\n hasRun: false,\n cleanupFns: undefined,\n zone: null,\n kind: 'effect',\n onDestroyFn: noop,\n run() {\n this.dirty = false;\n if (ngDevMode && isInNotificationPhase$1()) {\n throw new Error(`Schedulers cannot synchronously execute watches while scheduling.`);\n }\n if (this.hasRun && !consumerPollProducersForChange$1(this)) {\n return;\n }\n this.hasRun = true;\n const registerCleanupFn = cleanupFn => (this.cleanupFns ??= []).push(cleanupFn);\n const prevNode = consumerBeforeComputation$1(this);\n // We clear `setIsRefreshingViews` so that `markForCheck()` within the body of an effect will\n // cause CD to reach the component in question.\n const prevRefreshingViews = setIsRefreshingViews(false);\n try {\n this.maybeCleanup();\n this.fn(registerCleanupFn);\n } finally {\n setIsRefreshingViews(prevRefreshingViews);\n consumerAfterComputation$1(this, prevNode);\n }\n },\n maybeCleanup() {\n if (!this.cleanupFns?.length) {\n return;\n }\n try {\n // Attempt to run the cleanup functions. Regardless of failure or success, we consider\n // cleanup \"completed\" and clear the list for the next run of the effect. Note that an error\n // from the cleanup function will still crash the current run of the effect.\n while (this.cleanupFns.length) {\n this.cleanupFns.pop()();\n }\n } finally {\n this.cleanupFns = [];\n }\n }\n}))();\nconst ROOT_EFFECT_NODE = /* @__PURE__ */(() => ({\n ...BASE_EFFECT_NODE,\n consumerMarkedDirty() {\n this.scheduler.schedule(this);\n this.notifier.notify(12 /* NotificationSource.RootEffect */);\n },\n destroy() {\n consumerDestroy$1(this);\n this.onDestroyFn();\n this.maybeCleanup();\n this.scheduler.remove(this);\n }\n}))();\nconst VIEW_EFFECT_NODE = /* @__PURE__ */(() => ({\n ...BASE_EFFECT_NODE,\n consumerMarkedDirty() {\n this.view[FLAGS] |= 8192 /* LViewFlags.HasChildViewsToRefresh */;\n markAncestorsForTraversal(this.view);\n this.notifier.notify(13 /* NotificationSource.ViewEffect */);\n },\n destroy() {\n consumerDestroy$1(this);\n this.onDestroyFn();\n this.maybeCleanup();\n this.view[EFFECTS]?.delete(this);\n }\n}))();\nfunction createViewEffect(view, notifier, fn) {\n const node = Object.create(VIEW_EFFECT_NODE);\n node.view = view;\n node.zone = typeof Zone !== 'undefined' ? Zone.current : null;\n node.notifier = notifier;\n node.fn = fn;\n view[EFFECTS] ??= new Set();\n view[EFFECTS].add(node);\n node.consumerMarkedDirty(node);\n return node;\n}\nfunction createRootEffect(fn, scheduler, notifier) {\n const node = Object.create(ROOT_EFFECT_NODE);\n node.fn = fn;\n node.scheduler = scheduler;\n node.notifier = notifier;\n node.zone = typeof Zone !== 'undefined' ? Zone.current : null;\n node.scheduler.schedule(node);\n node.notifier.notify(12 /* NotificationSource.RootEffect */);\n return node;\n}\n\n/**\n * Status of a `Resource`.\n *\n * @experimental\n */\nvar ResourceStatus;\n(function (ResourceStatus) {\n /**\n * The resource has no valid request and will not perform any loading.\n *\n * `value()` will be `undefined`.\n */\n ResourceStatus[ResourceStatus[\"Idle\"] = 0] = \"Idle\";\n /**\n * Loading failed with an error.\n *\n * `value()` will be `undefined`.\n */\n ResourceStatus[ResourceStatus[\"Error\"] = 1] = \"Error\";\n /**\n * The resource is currently loading a new value as a result of a change in its `request`.\n *\n * `value()` will be `undefined`.\n */\n ResourceStatus[ResourceStatus[\"Loading\"] = 2] = \"Loading\";\n /**\n * The resource is currently reloading a fresh value for the same request.\n *\n * `value()` will continue to return the previously fetched value during the reloading operation.\n */\n ResourceStatus[ResourceStatus[\"Reloading\"] = 3] = \"Reloading\";\n /**\n * Loading has completed and the resource has the value returned from the loader.\n */\n ResourceStatus[ResourceStatus[\"Resolved\"] = 4] = \"Resolved\";\n /**\n * The resource's value was set locally via `.set()` or `.update()`.\n */\n ResourceStatus[ResourceStatus[\"Local\"] = 5] = \"Local\";\n})(ResourceStatus || (ResourceStatus = {}));\nconst identityFn = v => v;\nfunction linkedSignal(optionsOrComputation, options) {\n if (typeof optionsOrComputation === 'function') {\n const getter = createLinkedSignal$1(optionsOrComputation, identityFn, options?.equal);\n return upgradeLinkedSignalGetter(getter);\n } else {\n const getter = createLinkedSignal$1(optionsOrComputation.source, optionsOrComputation.computation, optionsOrComputation.equal);\n return upgradeLinkedSignalGetter(getter);\n }\n}\nfunction upgradeLinkedSignalGetter(getter) {\n if (ngDevMode) {\n getter.toString = () => `[LinkedSignal: ${getter()}]`;\n }\n const node = getter[SIGNAL$1];\n const upgradedGetter = getter;\n upgradedGetter.set = newValue => linkedSignalSetFn$1(node, newValue);\n upgradedGetter.update = updateFn => linkedSignalUpdateFn$1(node, updateFn);\n upgradedGetter.asReadonly = signalAsReadonlyFn.bind(getter);\n return upgradedGetter;\n}\nfunction resource(options) {\n options?.injector || assertInInjectionContext(resource);\n const request = options.request ?? (() => null);\n return new ResourceImpl(request, getLoader(options), options.defaultValue, options.equal ? wrapEqualityFn(options.equal) : undefined, options.injector ?? inject(Injector));\n}\n/**\n * Base class which implements `.value` as a `WritableSignal` by delegating `.set` and `.update`.\n */\nclass BaseWritableResource {\n value;\n constructor(value) {\n this.value = value;\n this.value.set = this.set.bind(this);\n this.value.update = this.update.bind(this);\n this.value.asReadonly = signalAsReadonlyFn;\n }\n update(updateFn) {\n this.set(updateFn(untracked(this.value)));\n }\n isLoading = computed(() => this.status() === ResourceStatus.Loading || this.status() === ResourceStatus.Reloading);\n hasValue() {\n return this.value() !== undefined;\n }\n asReadonly() {\n return this;\n }\n}\n/**\n * Implementation for `resource()` which uses a `linkedSignal` to manage the resource's state.\n */\nclass ResourceImpl extends BaseWritableResource {\n loaderFn;\n defaultValue;\n equal;\n pendingTasks;\n /**\n * The current state of the resource. Status, value, and error are derived from this.\n */\n state;\n /**\n * Combines the current request with a reload counter which allows the resource to be reloaded on\n * imperative command.\n */\n extRequest;\n effectRef;\n pendingController;\n resolvePendingTask = undefined;\n destroyed = false;\n constructor(request, loaderFn, defaultValue, equal, injector) {\n super(\n // Feed a computed signal for the value to `BaseWritableResource`, which will upgrade it to a\n // `WritableSignal` that delegates to `ResourceImpl.set`.\n computed(() => {\n const streamValue = this.state().stream?.();\n return streamValue && isResolved(streamValue) ? streamValue.value : this.defaultValue;\n }, {\n equal\n }));\n this.loaderFn = loaderFn;\n this.defaultValue = defaultValue;\n this.equal = equal;\n // Extend `request()` to include a writable reload signal.\n this.extRequest = linkedSignal({\n source: request,\n computation: request => ({\n request,\n reload: 0\n })\n });\n // The main resource state is managed in a `linkedSignal`, which allows the resource to change\n // state instantaneously when the request signal changes.\n this.state = linkedSignal({\n // Whenever the request changes,\n source: this.extRequest,\n // Compute the state of the resource given a change in status.\n computation: (extRequest, previous) => {\n const status = extRequest.request === undefined ? ResourceStatus.Idle : ResourceStatus.Loading;\n if (!previous) {\n return {\n extRequest,\n status,\n previousStatus: ResourceStatus.Idle,\n stream: undefined\n };\n } else {\n return {\n extRequest,\n status,\n previousStatus: projectStatusOfState(previous.value),\n // If the request hasn't changed, keep the previous stream.\n stream: previous.value.extRequest.request === extRequest.request ? previous.value.stream : undefined\n };\n }\n }\n });\n this.effectRef = effect(this.loadEffect.bind(this), {\n injector,\n manualCleanup: true\n });\n this.pendingTasks = injector.get(PendingTasks);\n // Cancel any pending request when the resource itself is destroyed.\n injector.get(DestroyRef).onDestroy(() => this.destroy());\n }\n status = computed(() => projectStatusOfState(this.state()));\n error = computed(() => {\n const stream = this.state().stream?.();\n return stream && !isResolved(stream) ? stream.error : undefined;\n });\n /**\n * Called either directly via `WritableResource.set` or via `.value.set()`.\n */\n set(value) {\n if (this.destroyed) {\n return;\n }\n const current = untracked(this.value);\n const state = untracked(this.state);\n if (state.status === ResourceStatus.Local && (this.equal ? this.equal(current, value) : current === value)) {\n return;\n }\n // Enter Local state with the user-defined value.\n this.state.set({\n extRequest: state.extRequest,\n status: ResourceStatus.Local,\n previousStatus: ResourceStatus.Local,\n stream: signal({\n value\n })\n });\n // We're departing from whatever state the resource was in previously, so cancel any in-progress\n // loading operations.\n this.abortInProgressLoad();\n }\n reload() {\n // We don't want to restart in-progress loads.\n const {\n status\n } = untracked(this.state);\n if (status === ResourceStatus.Idle || status === ResourceStatus.Loading) {\n return false;\n }\n // Increment the request reload to trigger the `state` linked signal to switch us to `Reload`\n this.extRequest.update(({\n request,\n reload\n }) => ({\n request,\n reload: reload + 1\n }));\n return true;\n }\n destroy() {\n this.destroyed = true;\n this.effectRef.destroy();\n this.abortInProgressLoad();\n // Destroyed resources enter Idle state.\n this.state.set({\n extRequest: {\n request: undefined,\n reload: 0\n },\n status: ResourceStatus.Idle,\n previousStatus: ResourceStatus.Idle,\n stream: undefined\n });\n }\n async loadEffect() {\n const extRequest = this.extRequest();\n // Capture the previous status before any state transitions. Note that this is `untracked` since\n // we do not want the effect to depend on the state of the resource, only on the request.\n const {\n status: currentStatus,\n previousStatus\n } = untracked(this.state);\n if (extRequest.request === undefined) {\n // Nothing to load (and we should already be in a non-loading state).\n return;\n } else if (currentStatus !== ResourceStatus.Loading) {\n // We're not in a loading or reloading state, so this loading request is stale.\n return;\n }\n // Cancel any previous loading attempts.\n this.abortInProgressLoad();\n // Capturing _this_ load's pending task in a local variable is important here. We may attempt to\n // resolve it twice:\n //\n // 1. when the loading function promise resolves/rejects\n // 2. when cancelling the loading operation\n //\n // After the loading operation is cancelled, `this.resolvePendingTask` no longer represents this\n // particular task, but this `await` may eventually resolve/reject. Thus, when we cancel in\n // response to (1) below, we need to cancel the locally saved task.\n let resolvePendingTask = this.resolvePendingTask = this.pendingTasks.add();\n const {\n signal: abortSignal\n } = this.pendingController = new AbortController();\n try {\n // The actual loading is run through `untracked` - only the request side of `resource` is\n // reactive. This avoids any confusion with signals tracking or not tracking depending on\n // which side of the `await` they are.\n const stream = await untracked(() => {\n return this.loaderFn({\n request: extRequest.request,\n abortSignal,\n previous: {\n status: previousStatus\n }\n });\n });\n // If this request has been aborted, or the current request no longer\n // matches this load, then we should ignore this resolution.\n if (abortSignal.aborted || untracked(this.extRequest) !== extRequest) {\n return;\n }\n this.state.set({\n extRequest,\n status: ResourceStatus.Resolved,\n previousStatus: ResourceStatus.Resolved,\n stream\n });\n } catch (err) {\n if (abortSignal.aborted || untracked(this.extRequest) !== extRequest) {\n return;\n }\n this.state.set({\n extRequest,\n status: ResourceStatus.Resolved,\n previousStatus: ResourceStatus.Error,\n stream: signal({\n error: err\n })\n });\n } finally {\n // Resolve the pending task now that the resource has a value.\n resolvePendingTask?.();\n resolvePendingTask = undefined;\n }\n }\n abortInProgressLoad() {\n untracked(() => this.pendingController?.abort());\n this.pendingController = undefined;\n // Once the load is aborted, we no longer want to block stability on its resolution.\n this.resolvePendingTask?.();\n this.resolvePendingTask = undefined;\n }\n}\n/**\n * Wraps an equality function to handle either value being `undefined`.\n */\nfunction wrapEqualityFn(equal) {\n return (a, b) => a === undefined || b === undefined ? a === b : equal(a, b);\n}\nfunction getLoader(options) {\n if (isStreamingResourceOptions(options)) {\n return options.stream;\n }\n return async params => {\n try {\n return signal({\n value: await options.loader(params)\n });\n } catch (err) {\n return signal({\n error: err\n });\n }\n };\n}\nfunction isStreamingResourceOptions(options) {\n return !!options.stream;\n}\n/**\n * Project from a state with `ResourceInternalStatus` to the user-facing `ResourceStatus`\n */\nfunction projectStatusOfState(state) {\n switch (state.status) {\n case ResourceStatus.Loading:\n return state.extRequest.reload === 0 ? ResourceStatus.Loading : ResourceStatus.Reloading;\n case ResourceStatus.Resolved:\n return isResolved(untracked(state.stream)) ? ResourceStatus.Resolved : ResourceStatus.Error;\n default:\n return state.status;\n }\n}\nfunction isResolved(state) {\n return state.error === undefined;\n}\n\n/*!\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n/**\n * Gets the class name of the closest component to a node.\n * Warning! this function will return minified names if the name of the component is minified. The\n * consumer of the function is responsible for resolving the minified name to its original name.\n * @param node Node from which to start the search.\n */\nfunction getClosestComponentName(node) {\n let currentNode = node;\n while (currentNode) {\n const lView = readPatchedLView(currentNode);\n if (lView !== null) {\n for (let i = HEADER_OFFSET; i < lView.length; i++) {\n const current = lView[i];\n if (!isLView(current) && !isLContainer(current) || current[HOST] !== currentNode) {\n continue;\n }\n const tView = lView[TVIEW];\n const tNode = getTNode(tView, i);\n if (isComponentHost(tNode)) {\n const def = tView.data[tNode.directiveStart + tNode.componentOffset];\n const name = def.debugInfo?.className || def.type.name;\n // Note: the name may be an empty string if the class name is\n // dropped due to minification. In such cases keep going up the tree.\n if (name) {\n return name;\n } else {\n break;\n }\n }\n }\n }\n currentNode = currentNode.parentNode;\n }\n return null;\n}\n\n/**\n * Compiles a partial directive declaration object into a full directive definition object.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareDirective(decl) {\n const compiler = getCompilerFacade({\n usage: 1 /* JitCompilerUsage.PartialDeclaration */,\n kind: 'directive',\n type: decl.type\n });\n return compiler.compileDirectiveDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵfac.js`, decl);\n}\n/**\n * Evaluates the class metadata declaration.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareClassMetadata(decl) {\n setClassMetadata(decl.type, decl.decorators, decl.ctorParameters ?? null, decl.propDecorators ?? null);\n}\n/**\n * Evaluates the class metadata of a component that contains deferred blocks.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareClassMetadataAsync(decl) {\n setClassMetadataAsync(decl.type, decl.resolveDeferredDeps, (...types) => {\n const meta = decl.resolveMetadata(...types);\n setClassMetadata(decl.type, meta.decorators, meta.ctorParameters, meta.propDecorators);\n });\n}\n/**\n * Compiles a partial component declaration object into a full component definition object.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareComponent(decl) {\n const compiler = getCompilerFacade({\n usage: 1 /* JitCompilerUsage.PartialDeclaration */,\n kind: 'component',\n type: decl.type\n });\n return compiler.compileComponentDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵcmp.js`, decl);\n}\n/**\n * Compiles a partial pipe declaration object into a full pipe definition object.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareFactory(decl) {\n const compiler = getCompilerFacade({\n usage: 1 /* JitCompilerUsage.PartialDeclaration */,\n kind: getFactoryKind(decl.target),\n type: decl.type\n });\n return compiler.compileFactoryDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵfac.js`, decl);\n}\nfunction getFactoryKind(target) {\n switch (target) {\n case FactoryTarget.Directive:\n return 'directive';\n case FactoryTarget.Component:\n return 'component';\n case FactoryTarget.Injectable:\n return 'injectable';\n case FactoryTarget.Pipe:\n return 'pipe';\n case FactoryTarget.NgModule:\n return 'NgModule';\n }\n}\n/**\n * Compiles a partial injectable declaration object into a full injectable definition object.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareInjectable(decl) {\n const compiler = getCompilerFacade({\n usage: 1 /* JitCompilerUsage.PartialDeclaration */,\n kind: 'injectable',\n type: decl.type\n });\n return compiler.compileInjectableDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵprov.js`, decl);\n}\n/**\n * Compiles a partial injector declaration object into a full injector definition object.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareInjector(decl) {\n const compiler = getCompilerFacade({\n usage: 1 /* JitCompilerUsage.PartialDeclaration */,\n kind: 'NgModule',\n type: decl.type\n });\n return compiler.compileInjectorDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵinj.js`, decl);\n}\n/**\n * Compiles a partial NgModule declaration object into a full NgModule definition object.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclareNgModule(decl) {\n const compiler = getCompilerFacade({\n usage: 1 /* JitCompilerUsage.PartialDeclaration */,\n kind: 'NgModule',\n type: decl.type\n });\n return compiler.compileNgModuleDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵmod.js`, decl);\n}\n/**\n * Compiles a partial pipe declaration object into a full pipe definition object.\n *\n * @codeGenApi\n */\nfunction ɵɵngDeclarePipe(decl) {\n const compiler = getCompilerFacade({\n usage: 1 /* JitCompilerUsage.PartialDeclaration */,\n kind: 'pipe',\n type: decl.type\n });\n return compiler.compilePipeDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵpipe.js`, decl);\n}\n\n// we reexport these symbols just so that they are retained during the dead code elimination\n\nconst NOT_SET = Symbol('NOT_SET');\nconst EMPTY_CLEANUP_SET = new Set();\nconst AFTER_RENDER_PHASE_EFFECT_NODE = /* @__PURE__ */(() => ({\n ...SIGNAL_NODE$1,\n consumerIsAlwaysLive: true,\n consumerAllowSignalWrites: true,\n value: NOT_SET,\n cleanup: null,\n /** Called when the effect becomes dirty */\n consumerMarkedDirty() {\n if (this.sequence.impl.executing) {\n // If hooks are in the middle of executing, then it matters whether this node has yet been\n // executed within its sequence. If not, then we don't want to notify the scheduler since\n // this node will be reached naturally.\n if (this.sequence.lastPhase === null || this.sequence.lastPhase < this.phase) {\n return;\n }\n // If during the execution of a later phase an earlier phase became dirty, then we should not\n // run any further phases until the earlier one reruns.\n this.sequence.erroredOrDestroyed = true;\n }\n // Either hooks are not running, or we're marking a node dirty that has already run within its\n // sequence.\n this.sequence.scheduler.notify(7 /* NotificationSource.RenderHook */);\n },\n phaseFn(previousValue) {\n this.sequence.lastPhase = this.phase;\n if (!this.dirty) {\n return this.signal;\n }\n this.dirty = false;\n if (this.value !== NOT_SET && !consumerPollProducersForChange$1(this)) {\n // None of our producers report a change since the last time they were read, so no\n // recomputation of our value is necessary.\n return this.signal;\n }\n // Run any needed cleanup functions.\n try {\n for (const cleanupFn of this.cleanup ?? EMPTY_CLEANUP_SET) {\n cleanupFn();\n }\n } finally {\n // Even if a cleanup function errors, ensure it's cleared.\n this.cleanup?.clear();\n }\n // Prepare to call the user's effect callback. If there was a previous phase, then it gave us\n // its value as a `Signal`, otherwise `previousValue` will be `undefined`.\n const args = [];\n if (previousValue !== undefined) {\n args.push(previousValue);\n }\n args.push(this.registerCleanupFn);\n // Call the user's callback in our reactive context.\n const prevConsumer = consumerBeforeComputation$1(this);\n let newValue;\n try {\n newValue = this.userFn.apply(null, args);\n } finally {\n consumerAfterComputation$1(this, prevConsumer);\n }\n if (this.value === NOT_SET || !this.equal(this.value, newValue)) {\n this.value = newValue;\n this.version++;\n }\n return this.signal;\n }\n}))();\n/**\n * An `AfterRenderSequence` that manages an `afterRenderEffect`'s phase effects.\n */\nclass AfterRenderEffectSequence extends AfterRenderSequence {\n scheduler;\n /**\n * While this sequence is executing, this tracks the last phase which was called by the\n * `afterRender` machinery.\n *\n * When a phase effect is marked dirty, this is used to determine whether it's already run or not.\n */\n lastPhase = null;\n /**\n * The reactive nodes for each phase, if a phase effect is defined for that phase.\n *\n * These are initialized to `undefined` but set in the constructor.\n */\n nodes = [undefined, undefined, undefined, undefined];\n constructor(impl, effectHooks, view, scheduler, destroyRef, snapshot = null) {\n // Note that we also initialize the underlying `AfterRenderSequence` hooks to `undefined` and\n // populate them as we create reactive nodes below.\n super(impl, [undefined, undefined, undefined, undefined], view, false, destroyRef, snapshot);\n this.scheduler = scheduler;\n // Setup a reactive node for each phase.\n for (const phase of AFTER_RENDER_PHASES) {\n const effectHook = effectHooks[phase];\n if (effectHook === undefined) {\n continue;\n }\n const node = Object.create(AFTER_RENDER_PHASE_EFFECT_NODE);\n node.sequence = this;\n node.phase = phase;\n node.userFn = effectHook;\n node.dirty = true;\n node.signal = () => {\n producerAccessed$1(node);\n return node.value;\n };\n node.signal[SIGNAL$1] = node;\n node.registerCleanupFn = fn => (node.cleanup ??= new Set()).add(fn);\n this.nodes[phase] = node;\n // Install the upstream hook which runs the `phaseFn` for this phase.\n this.hooks[phase] = value => node.phaseFn(value);\n }\n }\n afterRun() {\n super.afterRun();\n // We're done running this sequence, so reset `lastPhase`.\n this.lastPhase = null;\n }\n destroy() {\n super.destroy();\n // Run the cleanup functions for each node.\n for (const node of this.nodes) {\n for (const fn of node?.cleanup ?? EMPTY_CLEANUP_SET) {\n fn();\n }\n }\n }\n}\n/**\n * @experimental\n */\nfunction afterRenderEffect(callbackOrSpec, options) {\n ngDevMode && assertNotInReactiveContext(afterRenderEffect, 'Call `afterRenderEffect` outside of a reactive context. For example, create the render ' + 'effect inside the component constructor`.');\n !options?.injector && assertInInjectionContext(afterRenderEffect);\n if (typeof ngServerMode !== 'undefined' && ngServerMode) {\n return NOOP_AFTER_RENDER_REF;\n }\n const injector = options?.injector ?? inject(Injector);\n const scheduler = injector.get(ChangeDetectionScheduler);\n const manager = injector.get(AfterRenderManager);\n const tracing = injector.get(TracingService, null, {\n optional: true\n });\n manager.impl ??= injector.get(AfterRenderImpl);\n let spec = callbackOrSpec;\n if (typeof spec === 'function') {\n spec = {\n mixedReadWrite: callbackOrSpec\n };\n }\n const viewContext = injector.get(ViewContext, null, {\n optional: true\n });\n const sequence = new AfterRenderEffectSequence(manager.impl, [spec.earlyRead, spec.write, spec.mixedReadWrite, spec.read], viewContext?.view, scheduler, injector.get(DestroyRef), tracing?.snapshot(null));\n manager.impl.register(sequence);\n return sequence;\n}\n\n// This file exists to allow the set of reactivity exports to be modified in g3, as these APIs are\n\n/**\n * Creates a `ComponentRef` instance based on provided component type and a set of options.\n *\n * @usageNotes\n *\n * The example below demonstrates how the `createComponent` function can be used\n * to create an instance of a ComponentRef dynamically and attach it to an ApplicationRef,\n * so that it gets included into change detection cycles.\n *\n * Note: the example uses standalone components, but the function can also be used for\n * non-standalone components (declared in an NgModule) as well.\n *\n * ```angular-ts\n * @Component({\n * standalone: true,\n * template: `Hello {{ name }}!`\n * })\n * class HelloComponent {\n * name = 'Angular';\n * }\n *\n * @Component({\n * standalone: true,\n * template: `<div id=\"hello-component-host\"></div>`\n * })\n * class RootComponent {}\n *\n * // Bootstrap an application.\n * const applicationRef = await bootstrapApplication(RootComponent);\n *\n * // Locate a DOM node that would be used as a host.\n * const hostElement = document.getElementById('hello-component-host');\n *\n * // Get an `EnvironmentInjector` instance from the `ApplicationRef`.\n * const environmentInjector = applicationRef.injector;\n *\n * // We can now create a `ComponentRef` instance.\n * const componentRef = createComponent(HelloComponent, {hostElement, environmentInjector});\n *\n * // Last step is to register the newly created ref using the `ApplicationRef` instance\n * // to include the component view into change detection cycles.\n * applicationRef.attachView(componentRef.hostView);\n * componentRef.changeDetectorRef.detectChanges();\n * ```\n *\n * @param component Component class reference.\n * @param options Set of options to use:\n * * `environmentInjector`: An `EnvironmentInjector` instance to be used for the component.\n * * `hostElement` (optional): A DOM node that should act as a host node for the component. If not\n * provided, Angular creates one based on the tag name used in the component selector (and falls\n * back to using `div` if selector doesn't have tag name info).\n * * `elementInjector` (optional): An `ElementInjector` instance, see additional info about it\n * [here](guide/di/hierarchical-dependency-injection#elementinjector).\n * * `projectableNodes` (optional): A list of DOM nodes that should be projected through\n * [`<ng-content>`](api/core/ng-content) of the new component instance, e.g.,\n * `[[element1, element2]]`: projects `element1` and `element2` into the same `<ng-content>`.\n * `[[element1, element2], [element3]]`: projects `element1` and `element2` into one `<ng-content>`,\n * and `element3` into a separate `<ng-content>`.\n * @returns ComponentRef instance that represents a given Component.\n *\n * @publicApi\n */\nfunction createComponent(component, options) {\n ngDevMode && assertComponentDef(component);\n const componentDef = getComponentDef(component);\n const elementInjector = options.elementInjector || getNullInjector();\n const factory = new ComponentFactory(componentDef);\n return factory.create(elementInjector, options.projectableNodes, options.hostElement, options.environmentInjector);\n}\n/**\n * Creates an object that allows to retrieve component metadata.\n *\n * @usageNotes\n *\n * The example below demonstrates how to use the function and how the fields\n * of the returned object map to the component metadata.\n *\n * ```angular-ts\n * @Component({\n * standalone: true,\n * selector: 'foo-component',\n * template: `\n * <ng-content></ng-content>\n * <ng-content select=\"content-selector-a\"></ng-content>\n * `,\n * })\n * class FooComponent {\n * @Input('inputName') inputPropName: string;\n * @Output('outputName') outputPropName = new EventEmitter<void>();\n * }\n *\n * const mirror = reflectComponentType(FooComponent);\n * expect(mirror.type).toBe(FooComponent);\n * expect(mirror.selector).toBe('foo-component');\n * expect(mirror.isStandalone).toBe(true);\n * expect(mirror.inputs).toEqual([{propName: 'inputName', templateName: 'inputPropName'}]);\n * expect(mirror.outputs).toEqual([{propName: 'outputName', templateName: 'outputPropName'}]);\n * expect(mirror.ngContentSelectors).toEqual([\n * '*', // first `<ng-content>` in a template, the selector defaults to `*`\n * 'content-selector-a' // second `<ng-content>` in a template\n * ]);\n * ```\n *\n * @param component Component class reference.\n * @returns An object that allows to retrieve component metadata.\n *\n * @publicApi\n */\nfunction reflectComponentType(component) {\n const componentDef = getComponentDef(component);\n if (!componentDef) return null;\n const factory = new ComponentFactory(componentDef);\n return {\n get selector() {\n return factory.selector;\n },\n get type() {\n return factory.componentType;\n },\n get inputs() {\n return factory.inputs;\n },\n get outputs() {\n return factory.outputs;\n },\n get ngContentSelectors() {\n return factory.ngContentSelectors;\n },\n get isStandalone() {\n return componentDef.standalone;\n },\n get isSignal() {\n return componentDef.signals;\n }\n };\n}\n\n/**\n * Merge multiple application configurations from left to right.\n *\n * @param configs Two or more configurations to be merged.\n * @returns A merged [ApplicationConfig](api/core/ApplicationConfig).\n *\n * @publicApi\n */\nfunction mergeApplicationConfig(...configs) {\n return configs.reduce((prev, curr) => {\n return Object.assign(prev, curr, {\n providers: [...prev.providers, ...curr.providers]\n });\n }, {\n providers: []\n });\n}\n\n/**\n * Injection token representing the current HTTP request object.\n *\n * Use this token to access the current request when handling server-side\n * rendering (SSR).\n *\n * @remarks\n * This token may be `null` in the following scenarios:\n *\n * * During the build processes.\n * * When the application is rendered in the browser (client-side rendering).\n * * When performing static site generation (SSG).\n * * During route extraction in development (at the time of the request).\n *\n * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/Request | `Request` on MDN}\n *\n * @developerPreview\n */\nconst REQUEST = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'REQUEST' : '', {\n providedIn: 'platform',\n factory: () => null\n});\n/**\n * Injection token for response initialization options.\n *\n * Use this token to provide response options for configuring or initializing\n * HTTP responses in server-side rendering or API endpoints.\n *\n * @remarks\n * This token may be `null` in the following scenarios:\n *\n * * During the build processes.\n * * When the application is rendered in the browser (client-side rendering).\n * * When performing static site generation (SSG).\n * * During route extraction in development (at the time of the request).\n *\n * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/Response/Response | `ResponseInit` on MDN}\n *\n * @developerPreview\n */\nconst RESPONSE_INIT = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'RESPONSE_INIT' : '', {\n providedIn: 'platform',\n factory: () => null\n});\n/**\n * Injection token for additional request context.\n *\n * Use this token to pass custom metadata or context related to the current request in server-side rendering.\n *\n * @remarks\n * This token is only available during server-side rendering and will be `null` in other contexts.\n *\n * @developerPreview\n */\nconst REQUEST_CONTEXT = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'REQUEST_CONTEXT' : '', {\n providedIn: 'platform',\n factory: () => null\n});\n\n/**\n * @module\n * @description\n * Entry point from which you should import all public core APIs.\n */\nif (typeof ngDevMode !== 'undefined' && ngDevMode) {\n // This helper is to give a reasonable error message to people upgrading to v9 that have not yet\n // installed `@angular/localize` in their app.\n // tslint:disable-next-line: no-toplevel-property-access\n _global.$localize ??= function () {\n throw new Error('It looks like your application or one of its dependencies is using i18n.\\n' + 'Angular 9 introduced a global `$localize()` function that needs to be loaded.\\n' + 'Please run `ng add @angular/localize` from the Angular CLI.\\n' + \"(For non-CLI projects, add `import '@angular/localize/init';` to your `polyfills.ts` file.\\n\" + 'For server-side rendering applications add the import to your `main.server.ts` file.)');\n };\n}\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of this package.\n */\n// This file only reexports content of the `src` folder. Keep it that way.\n\n/* This file is not used to build this module. It is only used during editing\n * by the TypeScript language service and during build for verification. `ngc`\n * replaces this file with production index.ts when it rewrites private symbol\n * names.\n */\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { ANIMATION_MODULE_TYPE, APP_BOOTSTRAP_LISTENER, APP_ID, APP_INITIALIZER, AfterRenderPhase, ApplicationInitStatus, ApplicationModule, ApplicationRef, Attribute, COMPILER_OPTIONS, CSP_NONCE, CUSTOM_ELEMENTS_SCHEMA, ChangeDetectionStrategy, ChangeDetectorRef, Compiler, CompilerFactory, Component, ComponentFactory$1 as ComponentFactory, ComponentFactoryResolver$1 as ComponentFactoryResolver, ComponentRef$1 as ComponentRef, ContentChild, ContentChildren, DEFAULT_CURRENCY_CODE, DebugElement, DebugEventListener, DebugNode, DefaultIterableDiffer, DestroyRef, Directive, ENVIRONMENT_INITIALIZER, ElementRef, EmbeddedViewRef, EnvironmentInjector, ErrorHandler, EventEmitter, HOST_TAG_NAME, Host, HostAttributeToken, HostBinding, HostListener, INJECTOR$1 as INJECTOR, Inject, InjectFlags, Injectable, InjectionToken, Injector, Input, IterableDiffers, KeyValueDiffers, LOCALE_ID, MissingTranslationStrategy, ModuleWithComponentFactories, NO_ERRORS_SCHEMA, NgModule, NgModuleFactory$1 as NgModuleFactory, NgModuleRef$1 as NgModuleRef, NgProbeToken, NgZone, Optional, Output, OutputEmitterRef, PACKAGE_ROOT_URL, PLATFORM_ID, PLATFORM_INITIALIZER, PendingTasks, Pipe, PlatformRef, Query, QueryList, REQUEST, REQUEST_CONTEXT, RESPONSE_INIT, Renderer2, RendererFactory2, RendererStyleFlags2, ResourceStatus, Sanitizer, SecurityContext, Self, SimpleChange, SkipSelf, TRANSLATIONS, TRANSLATIONS_FORMAT, TemplateRef, Testability, TestabilityRegistry, TransferState, Type, VERSION, Version, ViewChild, ViewChildren, ViewContainerRef, ViewEncapsulation, ViewRef, afterNextRender, afterRender, afterRenderEffect, asNativeElements, assertInInjectionContext, assertNotInReactiveContext, assertPlatform, booleanAttribute, computed, contentChild, contentChildren, createComponent, createEnvironmentInjector, createNgModule, createNgModuleRef, createPlatform, createPlatformFactory, defineInjectable, destroyPlatform, effect, enableProdMode, forwardRef, getDebugNode, getModuleFactory, getNgModuleById, getPlatform, importProvidersFrom, inject, input, isDevMode, isSignal, isStandalone, linkedSignal, makeEnvironmentProviders, makeStateKey, mergeApplicationConfig, model, numberAttribute, output, platformCore, provideAppInitializer, provideEnvironmentInitializer, provideExperimentalCheckNoChangesForDebug, provideExperimentalZonelessChangeDetection, providePlatformInitializer, provideZoneChangeDetection, reflectComponentType, resolveForwardRef, resource, runInInjectionContext, setTestabilityGetter, signal, untracked, viewChild, viewChildren, ALLOW_MULTIPLE_PLATFORMS as ɵALLOW_MULTIPLE_PLATFORMS, AfterRenderManager as ɵAfterRenderManager, CONTAINER_HEADER_OFFSET as ɵCONTAINER_HEADER_OFFSET, ChangeDetectionScheduler as ɵChangeDetectionScheduler, ChangeDetectionSchedulerImpl as ɵChangeDetectionSchedulerImpl, ComponentFactory$1 as ɵComponentFactory, Console as ɵConsole, DEFAULT_LOCALE_ID as ɵDEFAULT_LOCALE_ID, DEFER_BLOCK_CONFIG as ɵDEFER_BLOCK_CONFIG, DEFER_BLOCK_DEPENDENCY_INTERCEPTOR as ɵDEFER_BLOCK_DEPENDENCY_INTERCEPTOR, DeferBlockBehavior as ɵDeferBlockBehavior, DeferBlockState as ɵDeferBlockState, ENABLE_ROOT_COMPONENT_BOOTSTRAP as ɵENABLE_ROOT_COMPONENT_BOOTSTRAP, EffectScheduler as ɵEffectScheduler, IMAGE_CONFIG as ɵIMAGE_CONFIG, IMAGE_CONFIG_DEFAULTS as ɵIMAGE_CONFIG_DEFAULTS, INJECTOR_SCOPE as ɵINJECTOR_SCOPE, ɵINPUT_SIGNAL_BRAND_WRITE_TYPE, INTERNAL_APPLICATION_ERROR_HANDLER as ɵINTERNAL_APPLICATION_ERROR_HANDLER, IS_HYDRATION_DOM_REUSE_ENABLED as ɵIS_HYDRATION_DOM_REUSE_ENABLED, IS_INCREMENTAL_HYDRATION_ENABLED as ɵIS_INCREMENTAL_HYDRATION_ENABLED, JSACTION_EVENT_CONTRACT as ɵJSACTION_EVENT_CONTRACT, LContext as ɵLContext, LocaleDataIndex as ɵLocaleDataIndex, MicrotaskEffectScheduler as ɵMicrotaskEffectScheduler, NG_COMP_DEF as ɵNG_COMP_DEF, NG_DIR_DEF as ɵNG_DIR_DEF, NG_ELEMENT_ID as ɵNG_ELEMENT_ID, NG_INJ_DEF as ɵNG_INJ_DEF, NG_MOD_DEF as ɵNG_MOD_DEF, NG_PIPE_DEF as ɵNG_PIPE_DEF, NG_PROV_DEF as ɵNG_PROV_DEF, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR as ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, NO_CHANGE as ɵNO_CHANGE, NgModuleFactory as ɵNgModuleFactory, NoopNgZone as ɵNoopNgZone, PERFORMANCE_MARK_PREFIX as ɵPERFORMANCE_MARK_PREFIX, PROVIDED_NG_ZONE as ɵPROVIDED_NG_ZONE, PendingTasksInternal as ɵPendingTasksInternal, ReflectionCapabilities as ɵReflectionCapabilities, ComponentFactory as ɵRender3ComponentFactory, ComponentRef as ɵRender3ComponentRef, NgModuleRef as ɵRender3NgModuleRef, ResourceImpl as ɵResourceImpl, RuntimeError as ɵRuntimeError, SSR_CONTENT_INTEGRITY_MARKER as ɵSSR_CONTENT_INTEGRITY_MARKER, TESTABILITY as ɵTESTABILITY, TESTABILITY_GETTER as ɵTESTABILITY_GETTER, TracingAction as ɵTracingAction, TracingService as ɵTracingService, USE_RUNTIME_DEPS_TRACKER_FOR_JIT as ɵUSE_RUNTIME_DEPS_TRACKER_FOR_JIT, ViewRef$1 as ɵViewRef, XSS_SECURITY_URL as ɵXSS_SECURITY_URL, ZONELESS_ENABLED as ɵZONELESS_ENABLED, _sanitizeHtml as ɵ_sanitizeHtml, _sanitizeUrl as ɵ_sanitizeUrl, allowSanitizationBypassAndThrow as ɵallowSanitizationBypassAndThrow, annotateForHydration as ɵannotateForHydration, bypassSanitizationTrustHtml as ɵbypassSanitizationTrustHtml, bypassSanitizationTrustResourceUrl as ɵbypassSanitizationTrustResourceUrl, bypassSanitizationTrustScript as ɵbypassSanitizationTrustScript, bypassSanitizationTrustStyle as ɵbypassSanitizationTrustStyle, bypassSanitizationTrustUrl as ɵbypassSanitizationTrustUrl, clearResolutionOfComponentResourcesQueue as ɵclearResolutionOfComponentResourcesQueue, compileComponent as ɵcompileComponent, compileDirective as ɵcompileDirective, compileNgModule as ɵcompileNgModule, compileNgModuleDefs as ɵcompileNgModuleDefs, compileNgModuleFactory as ɵcompileNgModuleFactory, compilePipe as ɵcompilePipe, convertToBitFlags as ɵconvertToBitFlags, createInjector as ɵcreateInjector, defaultIterableDiffers as ɵdefaultIterableDiffers, defaultKeyValueDiffers as ɵdefaultKeyValueDiffers, depsTracker as ɵdepsTracker, detectChangesInViewIfRequired as ɵdetectChangesInViewIfRequired, devModeEqual as ɵdevModeEqual, disableProfiling as ɵdisableProfiling, enableProfiling as ɵenableProfiling, findLocaleData as ɵfindLocaleData, flushModuleScopingQueueAsMuchAsPossible as ɵflushModuleScopingQueueAsMuchAsPossible, formatRuntimeError as ɵformatRuntimeError, generateStandaloneInDeclarationsError as ɵgenerateStandaloneInDeclarationsError, getAsyncClassMetadataFn as ɵgetAsyncClassMetadataFn, getClosestComponentName as ɵgetClosestComponentName, getDebugNode as ɵgetDebugNode, getDeferBlocks$1 as ɵgetDeferBlocks, getDirectives as ɵgetDirectives, getHostElement as ɵgetHostElement, getInjectableDef as ɵgetInjectableDef, getLContext as ɵgetLContext, getLocaleCurrencyCode as ɵgetLocaleCurrencyCode, getLocalePluralCase as ɵgetLocalePluralCase, getOutputDestroyRef as ɵgetOutputDestroyRef, getSanitizationBypassType as ɵgetSanitizationBypassType, ɵgetUnknownElementStrictMode, ɵgetUnknownPropertyStrictMode, _global as ɵglobal, injectChangeDetectorRef as ɵinjectChangeDetectorRef, internalCreateApplication as ɵinternalCreateApplication, internalProvideZoneChangeDetection as ɵinternalProvideZoneChangeDetection, isBoundToModule as ɵisBoundToModule, isComponentDefPendingResolution as ɵisComponentDefPendingResolution, isEnvironmentProviders as ɵisEnvironmentProviders, isInjectable as ɵisInjectable, isNgModule as ɵisNgModule, isPromise as ɵisPromise, isSubscribable as ɵisSubscribable, isViewDirty as ɵisViewDirty, markForRefresh as ɵmarkForRefresh, microtaskEffect as ɵmicrotaskEffect, noSideEffects as ɵnoSideEffects, patchComponentDefWithScope as ɵpatchComponentDefWithScope, performanceMarkFeature as ɵperformanceMarkFeature, publishExternalGlobalUtil as ɵpublishExternalGlobalUtil, readHydrationInfo as ɵreadHydrationInfo, registerLocaleData as ɵregisterLocaleData, renderDeferBlockState as ɵrenderDeferBlockState, resetCompiledComponents as ɵresetCompiledComponents, resetJitOptions as ɵresetJitOptions, resolveComponentResources as ɵresolveComponentResources, restoreComponentResolutionQueue as ɵrestoreComponentResolutionQueue, setAllowDuplicateNgModuleIdsForTest as ɵsetAllowDuplicateNgModuleIdsForTest, setAlternateWeakRefImpl as ɵsetAlternateWeakRefImpl, ɵsetClassDebugInfo, setClassMetadata as ɵsetClassMetadata, setClassMetadataAsync as ɵsetClassMetadataAsync, setCurrentInjector as ɵsetCurrentInjector, setDocument as ɵsetDocument, setInjectorProfilerContext as ɵsetInjectorProfilerContext, setLocaleId as ɵsetLocaleId, ɵsetUnknownElementStrictMode, ɵsetUnknownPropertyStrictMode, startMeasuring as ɵstartMeasuring, stopMeasuring as ɵstopMeasuring, store as ɵstore, stringify as ɵstringify, transitiveScopesFor as ɵtransitiveScopesFor, triggerResourceLoading as ɵtriggerResourceLoading, truncateMiddle as ɵtruncateMiddle, unregisterAllLocaleData as ɵunregisterLocaleData, unwrapSafeValue as ɵunwrapSafeValue, ɵunwrapWritableSignal, withDomHydration as ɵwithDomHydration, withEventReplay as ɵwithEventReplay, withI18nSupport as ɵwithI18nSupport, withIncrementalHydration as ɵwithIncrementalHydration, ɵɵCopyDefinitionFeature, ɵɵExternalStylesFeature, FactoryTarget as ɵɵFactoryTarget, ɵɵHostDirectivesFeature, ɵɵInheritDefinitionFeature, ɵɵNgOnChangesFeature, ɵɵProvidersFeature, ɵɵadvance, ɵɵattachSourceLocations, ɵɵattribute, ɵɵattributeInterpolate1, ɵɵattributeInterpolate2, ɵɵattributeInterpolate3, ɵɵattributeInterpolate4, ɵɵattributeInterpolate5, ɵɵattributeInterpolate6, ɵɵattributeInterpolate7, ɵɵattributeInterpolate8, ɵɵattributeInterpolateV, ɵɵclassMap, ɵɵclassMapInterpolate1, ɵɵclassMapInterpolate2, ɵɵclassMapInterpolate3, ɵɵclassMapInterpolate4, ɵɵclassMapInterpolate5, ɵɵclassMapInterpolate6, ɵɵclassMapInterpolate7, ɵɵclassMapInterpolate8, ɵɵclassMapInterpolateV, ɵɵclassProp, ɵɵcomponentInstance, ɵɵconditional, ɵɵcontentQuery, ɵɵcontentQuerySignal, ɵɵdeclareLet, ɵɵdefer, ɵɵdeferEnableTimerScheduling, ɵɵdeferHydrateNever, ɵɵdeferHydrateOnHover, ɵɵdeferHydrateOnIdle, ɵɵdeferHydrateOnImmediate, ɵɵdeferHydrateOnInteraction, ɵɵdeferHydrateOnTimer, ɵɵdeferHydrateOnViewport, ɵɵdeferHydrateWhen, ɵɵdeferOnHover, ɵɵdeferOnIdle, ɵɵdeferOnImmediate, ɵɵdeferOnInteraction, ɵɵdeferOnTimer, ɵɵdeferOnViewport, ɵɵdeferPrefetchOnHover, ɵɵdeferPrefetchOnIdle, ɵɵdeferPrefetchOnImmediate, ɵɵdeferPrefetchOnInteraction, ɵɵdeferPrefetchOnTimer, ɵɵdeferPrefetchOnViewport, ɵɵdeferPrefetchWhen, ɵɵdeferWhen, ɵɵdefineComponent, ɵɵdefineDirective, ɵɵdefineInjectable, ɵɵdefineInjector, ɵɵdefineNgModule, ɵɵdefinePipe, ɵɵdirectiveInject, ɵɵdisableBindings, ɵɵelement, ɵɵelementContainer, ɵɵelementContainerEnd, ɵɵelementContainerStart, ɵɵelementEnd, ɵɵelementStart, ɵɵenableBindings, ɵɵgetComponentDepsFactory, ɵɵgetCurrentView, ɵɵgetInheritedFactory, ɵɵhostProperty, ɵɵi18n, ɵɵi18nApply, ɵɵi18nAttributes, ɵɵi18nEnd, ɵɵi18nExp, ɵɵi18nPostprocess, ɵɵi18nStart, ɵɵinject, ɵɵinjectAttribute, ɵɵinvalidFactory, ɵɵinvalidFactoryDep, ɵɵlistener, ɵɵloadQuery, ɵɵnamespaceHTML, ɵɵnamespaceMathML, ɵɵnamespaceSVG, ɵɵnextContext, ɵɵngDeclareClassMetadata, ɵɵngDeclareClassMetadataAsync, ɵɵngDeclareComponent, ɵɵngDeclareDirective, ɵɵngDeclareFactory, ɵɵngDeclareInjectable, ɵɵngDeclareInjector, ɵɵngDeclareNgModule, ɵɵ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, ɵɵqueryAdvance, ɵɵqueryRefresh, ɵɵreadContextLet, ɵɵreference, registerNgModuleType as ɵɵregisterNgModuleType, ɵɵrepeater, ɵɵrepeaterCreate, ɵɵrepeaterTrackByIdentity, ɵɵrepeaterTrackByIndex, ɵɵreplaceMetadata, ɵɵresetView, ɵɵresolveBody, ɵɵresolveDocument, ɵɵresolveWindow, ɵɵrestoreView, ɵɵsanitizeHtml, ɵɵsanitizeResourceUrl, ɵɵsanitizeScript, ɵɵsanitizeStyle, ɵɵsanitizeUrl, ɵɵsanitizeUrlOrResourceUrl, ɵɵsetComponentScope, ɵɵsetNgModuleScope, ɵɵstoreLet, ɵɵ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, ɵɵtwoWayBindingSet, ɵɵtwoWayListener, ɵɵtwoWayProperty, ɵɵvalidateIframeAttribute, ɵɵviewQuery, ɵɵviewQuerySignal };\n","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\nimport * as i0 from '@angular/core';\nimport { Injectable, InjectionToken, inject, Optional, Inject, ɵɵinject, ɵfindLocaleData, ɵLocaleDataIndex, ɵgetLocaleCurrencyCode, ɵgetLocalePluralCase, LOCALE_ID, ɵregisterLocaleData, ɵstringify, Directive, Input, createNgModule, NgModuleRef, ɵRuntimeError, Host, Attribute, RendererStyleFlags2, untracked, ɵisPromise, ɵisSubscribable, Pipe, DEFAULT_CURRENCY_CODE, NgModule, Version, ɵɵdefineInjectable, ɵformatRuntimeError, PLATFORM_ID, ɵIMAGE_CONFIG, Renderer2, ElementRef, Injector, DestroyRef, ɵperformanceMarkFeature, NgZone, ApplicationRef, ChangeDetectorRef, numberAttribute, booleanAttribute, ɵIMAGE_CONFIG_DEFAULTS, ɵunwrapSafeValue } from '@angular/core';\nexport { ɵIMAGE_CONFIG as IMAGE_CONFIG } from '@angular/core';\nimport { Subject } from 'rxjs';\nlet _DOM = null;\nfunction getDOM() {\n return _DOM;\n}\nfunction setRootDomAdapter(adapter) {\n _DOM ??= adapter;\n}\n/**\n * Provides DOM operations in an environment-agnostic way.\n *\n * @security Tread carefully! Interacting with the DOM directly is dangerous and\n * can introduce XSS risks.\n */\nclass DomAdapter {}\n\n/**\n * This class wraps the platform Navigation API which allows server-specific and test\n * implementations.\n */\nclass PlatformNavigation {\n static ɵfac = function PlatformNavigation_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PlatformNavigation)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: PlatformNavigation,\n factory: () => (() => window.navigation)(),\n providedIn: 'platform'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PlatformNavigation, [{\n type: Injectable,\n args: [{\n providedIn: 'platform',\n useFactory: () => window.navigation\n }]\n }], null, null);\n})();\n\n/**\n * A DI Token representing the main rendering context.\n * In a browser and SSR this is the DOM Document.\n * When using SSR, that document is created by [Domino](https://github.com/angular/domino).\n *\n * @publicApi\n */\nconst DOCUMENT = new InjectionToken(ngDevMode ? 'DocumentToken' : '');\n\n/**\n * This class should not be used directly by an application developer. Instead, use\n * {@link Location}.\n *\n * `PlatformLocation` encapsulates all calls to DOM APIs, which allows the Router to be\n * platform-agnostic.\n * This means that we can have different implementation of `PlatformLocation` for the different\n * platforms that Angular supports. For example, `@angular/platform-browser` provides an\n * implementation specific to the browser environment, while `@angular/platform-server` provides\n * one suitable for use with server-side rendering.\n *\n * The `PlatformLocation` class is used directly by all implementations of {@link LocationStrategy}\n * when they need to interact with the DOM APIs like pushState, popState, etc.\n *\n * {@link LocationStrategy} in turn is used by the {@link Location} service which is used directly\n * by the {@link /api/router/Router Router} in order to navigate between routes. Since all interactions between\n * {@link /api/router/Router Router} /\n * {@link Location} / {@link LocationStrategy} and DOM APIs flow through the `PlatformLocation`\n * class, they are all platform-agnostic.\n *\n * @publicApi\n */\nclass PlatformLocation {\n historyGo(relativePosition) {\n throw new Error(ngDevMode ? 'Not implemented' : '');\n }\n static ɵfac = function PlatformLocation_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PlatformLocation)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: PlatformLocation,\n factory: () => (() => inject(BrowserPlatformLocation))(),\n providedIn: 'platform'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PlatformLocation, [{\n type: Injectable,\n args: [{\n providedIn: 'platform',\n useFactory: () => inject(BrowserPlatformLocation)\n }]\n }], null, null);\n})();\n/**\n * @description\n * Indicates when a location is initialized.\n *\n * @publicApi\n */\nconst LOCATION_INITIALIZED = new InjectionToken(ngDevMode ? 'Location Initialized' : '');\n/**\n * `PlatformLocation` encapsulates all of the direct calls to platform APIs.\n * This class should not be used directly by an application developer. Instead, use\n * {@link Location}.\n *\n * @publicApi\n */\nclass BrowserPlatformLocation extends PlatformLocation {\n _location;\n _history;\n _doc = inject(DOCUMENT);\n constructor() {\n super();\n this._location = window.location;\n this._history = window.history;\n }\n getBaseHrefFromDOM() {\n return getDOM().getBaseHref(this._doc);\n }\n onPopState(fn) {\n const window = getDOM().getGlobalEventTarget(this._doc, 'window');\n window.addEventListener('popstate', fn, false);\n return () => window.removeEventListener('popstate', fn);\n }\n onHashChange(fn) {\n const window = getDOM().getGlobalEventTarget(this._doc, 'window');\n window.addEventListener('hashchange', fn, false);\n return () => window.removeEventListener('hashchange', fn);\n }\n get href() {\n return this._location.href;\n }\n get protocol() {\n return this._location.protocol;\n }\n get hostname() {\n return this._location.hostname;\n }\n get port() {\n return this._location.port;\n }\n get pathname() {\n return this._location.pathname;\n }\n get search() {\n return this._location.search;\n }\n get hash() {\n return this._location.hash;\n }\n set pathname(newPath) {\n this._location.pathname = newPath;\n }\n pushState(state, title, url) {\n this._history.pushState(state, title, url);\n }\n replaceState(state, title, url) {\n this._history.replaceState(state, title, url);\n }\n forward() {\n this._history.forward();\n }\n back() {\n this._history.back();\n }\n historyGo(relativePosition = 0) {\n this._history.go(relativePosition);\n }\n getState() {\n return this._history.state;\n }\n static ɵfac = function BrowserPlatformLocation_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || BrowserPlatformLocation)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: BrowserPlatformLocation,\n factory: () => (() => new BrowserPlatformLocation())(),\n providedIn: 'platform'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(BrowserPlatformLocation, [{\n type: Injectable,\n args: [{\n providedIn: 'platform',\n useFactory: () => new BrowserPlatformLocation()\n }]\n }], () => [], null);\n})();\n\n/**\n * Joins two parts of a URL with a slash if needed.\n *\n * @param start URL string\n * @param end URL string\n *\n *\n * @returns The joined URL string.\n */\nfunction joinWithSlash(start, end) {\n // If `start` is an empty string, return `end` as the result.\n if (!start) return end;\n // If `end` is an empty string, return `start` as the result.\n if (!end) return start;\n // If `start` ends with a slash, remove the leading slash from `end`.\n if (start.endsWith('/')) {\n return end.startsWith('/') ? start + end.slice(1) : start + end;\n }\n // If `start` doesn't end with a slash, add one if `end` doesn't start with a slash.\n return end.startsWith('/') ? start + end : `${start}/${end}`;\n}\n/**\n * Removes a trailing slash from a URL string if needed.\n * Looks for the first occurrence of either `#`, `?`, or the end of the\n * line as `/` characters and removes the trailing slash if one exists.\n *\n * @param url URL string.\n *\n * @returns The URL string, modified if needed.\n */\nfunction stripTrailingSlash(url) {\n // Find the index of the first occurrence of `#`, `?`, or the end of the string.\n // This marks the start of the query string, fragment, or the end of the URL path.\n const pathEndIdx = url.search(/#|\\?|$/);\n // Check if the character before `pathEndIdx` is a trailing slash.\n // If it is, remove the trailing slash and return the modified URL.\n // Otherwise, return the URL as is.\n return url[pathEndIdx - 1] === '/' ? url.slice(0, pathEndIdx - 1) + url.slice(pathEndIdx) : url;\n}\n/**\n * Normalizes URL parameters by prepending with `?` if needed.\n *\n * @param params String of URL parameters.\n *\n * @returns The normalized URL parameters string.\n */\nfunction normalizeQueryParams(params) {\n return params && params[0] !== '?' ? `?${params}` : params;\n}\n\n/**\n * Enables the `Location` service to read route state from the browser's URL.\n * Angular provides two strategies:\n * `HashLocationStrategy` and `PathLocationStrategy`.\n *\n * Applications should use the `Router` or `Location` services to\n * interact with application route state.\n *\n * For instance, `HashLocationStrategy` produces URLs like\n * <code class=\"no-auto-link\">http://example.com/#/foo</code>,\n * and `PathLocationStrategy` produces\n * <code class=\"no-auto-link\">http://example.com/foo</code> as an equivalent URL.\n *\n * See these two classes for more.\n *\n * @publicApi\n */\nclass LocationStrategy {\n historyGo(relativePosition) {\n throw new Error(ngDevMode ? 'Not implemented' : '');\n }\n static ɵfac = function LocationStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || LocationStrategy)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: LocationStrategy,\n factory: () => (() => inject(PathLocationStrategy))(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(LocationStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: () => inject(PathLocationStrategy)\n }]\n }], null, null);\n})();\n/**\n * A predefined DI token for the base href\n * to be used with the `PathLocationStrategy`.\n * The base href is the URL prefix that should be preserved when generating\n * and recognizing URLs.\n *\n * @usageNotes\n *\n * The following example shows how to use this token to configure the root app injector\n * with a base href value, so that the DI framework can supply the dependency anywhere in the app.\n *\n * ```ts\n * import {NgModule} from '@angular/core';\n * import {APP_BASE_HREF} from '@angular/common';\n *\n * @NgModule({\n * providers: [{provide: APP_BASE_HREF, useValue: '/my/app'}]\n * })\n * class AppModule {}\n * ```\n *\n * @publicApi\n */\nconst APP_BASE_HREF = new InjectionToken(ngDevMode ? 'appBaseHref' : '');\n/**\n * @description\n * A {@link LocationStrategy} used to configure the {@link Location} service to\n * represent its state in the\n * [path](https://en.wikipedia.org/wiki/Uniform_Resource_Locator#Syntax) of the\n * browser's URL.\n *\n * If you're using `PathLocationStrategy`, you may provide a {@link APP_BASE_HREF}\n * or add a `<base href>` element to the document to override the default.\n *\n * For instance, if you provide an `APP_BASE_HREF` of `'/my/app/'` and call\n * `location.go('/foo')`, the browser's URL will become\n * `example.com/my/app/foo`. To ensure all relative URIs resolve correctly,\n * the `<base href>` and/or `APP_BASE_HREF` should end with a `/`.\n *\n * Similarly, if you add `<base href='/my/app/'/>` to the document and call\n * `location.go('/foo')`, the browser's URL will become\n * `example.com/my/app/foo`.\n *\n * Note that when using `PathLocationStrategy`, neither the query nor\n * the fragment in the `<base href>` will be preserved, as outlined\n * by the [RFC](https://tools.ietf.org/html/rfc3986#section-5.2.2).\n *\n * @usageNotes\n *\n * ### Example\n *\n * {@example common/location/ts/path_location_component.ts region='LocationComponent'}\n *\n * @publicApi\n */\nclass PathLocationStrategy extends LocationStrategy {\n _platformLocation;\n _baseHref;\n _removeListenerFns = [];\n constructor(_platformLocation, href) {\n super();\n this._platformLocation = _platformLocation;\n this._baseHref = href ?? this._platformLocation.getBaseHrefFromDOM() ?? inject(DOCUMENT).location?.origin ?? '';\n }\n /** @nodoc */\n ngOnDestroy() {\n while (this._removeListenerFns.length) {\n this._removeListenerFns.pop()();\n }\n }\n onPopState(fn) {\n this._removeListenerFns.push(this._platformLocation.onPopState(fn), this._platformLocation.onHashChange(fn));\n }\n getBaseHref() {\n return this._baseHref;\n }\n prepareExternalUrl(internal) {\n return joinWithSlash(this._baseHref, internal);\n }\n path(includeHash = false) {\n const pathname = this._platformLocation.pathname + normalizeQueryParams(this._platformLocation.search);\n const hash = this._platformLocation.hash;\n return hash && includeHash ? `${pathname}${hash}` : pathname;\n }\n pushState(state, title, url, queryParams) {\n const externalUrl = this.prepareExternalUrl(url + normalizeQueryParams(queryParams));\n this._platformLocation.pushState(state, title, externalUrl);\n }\n replaceState(state, title, url, queryParams) {\n const externalUrl = this.prepareExternalUrl(url + normalizeQueryParams(queryParams));\n this._platformLocation.replaceState(state, title, externalUrl);\n }\n forward() {\n this._platformLocation.forward();\n }\n back() {\n this._platformLocation.back();\n }\n getState() {\n return this._platformLocation.getState();\n }\n historyGo(relativePosition = 0) {\n this._platformLocation.historyGo?.(relativePosition);\n }\n static ɵfac = function PathLocationStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PathLocationStrategy)(i0.ɵɵinject(PlatformLocation), i0.ɵɵinject(APP_BASE_HREF, 8));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: PathLocationStrategy,\n factory: PathLocationStrategy.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PathLocationStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [{\n type: PlatformLocation\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [APP_BASE_HREF]\n }]\n }], null);\n})();\n\n/**\n * @description\n * A {@link LocationStrategy} used to configure the {@link Location} service to\n * represent its state in the\n * [hash fragment](https://en.wikipedia.org/wiki/Uniform_Resource_Locator#Syntax)\n * of the browser's URL.\n *\n * For instance, if you call `location.go('/foo')`, the browser's URL will become\n * `example.com#/foo`.\n *\n * @usageNotes\n *\n * ### Example\n *\n * {@example common/location/ts/hash_location_component.ts region='LocationComponent'}\n *\n * @publicApi\n */\nclass HashLocationStrategy extends LocationStrategy {\n _platformLocation;\n _baseHref = '';\n _removeListenerFns = [];\n constructor(_platformLocation, _baseHref) {\n super();\n this._platformLocation = _platformLocation;\n if (_baseHref != null) {\n this._baseHref = _baseHref;\n }\n }\n /** @nodoc */\n ngOnDestroy() {\n while (this._removeListenerFns.length) {\n this._removeListenerFns.pop()();\n }\n }\n onPopState(fn) {\n this._removeListenerFns.push(this._platformLocation.onPopState(fn), this._platformLocation.onHashChange(fn));\n }\n getBaseHref() {\n return this._baseHref;\n }\n path(includeHash = false) {\n // the hash value is always prefixed with a `#`\n // and if it is empty then it will stay empty\n const path = this._platformLocation.hash ?? '#';\n return path.length > 0 ? path.substring(1) : path;\n }\n prepareExternalUrl(internal) {\n const url = joinWithSlash(this._baseHref, internal);\n return url.length > 0 ? '#' + url : url;\n }\n pushState(state, title, path, queryParams) {\n const url = this.prepareExternalUrl(path + normalizeQueryParams(queryParams)) || this._platformLocation.pathname;\n this._platformLocation.pushState(state, title, url);\n }\n replaceState(state, title, path, queryParams) {\n const url = this.prepareExternalUrl(path + normalizeQueryParams(queryParams)) || this._platformLocation.pathname;\n this._platformLocation.replaceState(state, title, url);\n }\n forward() {\n this._platformLocation.forward();\n }\n back() {\n this._platformLocation.back();\n }\n getState() {\n return this._platformLocation.getState();\n }\n historyGo(relativePosition = 0) {\n this._platformLocation.historyGo?.(relativePosition);\n }\n static ɵfac = function HashLocationStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HashLocationStrategy)(i0.ɵɵinject(PlatformLocation), i0.ɵɵinject(APP_BASE_HREF, 8));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HashLocationStrategy,\n factory: HashLocationStrategy.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HashLocationStrategy, [{\n type: Injectable\n }], () => [{\n type: PlatformLocation\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [APP_BASE_HREF]\n }]\n }], null);\n})();\n\n/**\n * @description\n *\n * A service that applications can use to interact with a browser's URL.\n *\n * Depending on the `LocationStrategy` used, `Location` persists\n * to the URL's path or the URL's hash segment.\n *\n * @usageNotes\n *\n * It's better to use the `Router.navigate()` service to trigger route changes. Use\n * `Location` only if you need to interact with or create normalized URLs outside of\n * routing.\n *\n * `Location` is responsible for normalizing the URL against the application's base href.\n * A normalized URL is absolute from the URL host, includes the application's base href, and has no\n * trailing slash:\n * - `/my/app/user/123` is normalized\n * - `my/app/user/123` **is not** normalized\n * - `/my/app/user/123/` **is not** normalized\n *\n * ### Example\n *\n * {@example common/location/ts/path_location_component.ts region='LocationComponent'}\n *\n * @publicApi\n */\nclass Location {\n /** @internal */\n _subject = new Subject();\n /** @internal */\n _basePath;\n /** @internal */\n _locationStrategy;\n /** @internal */\n _urlChangeListeners = [];\n /** @internal */\n _urlChangeSubscription = null;\n constructor(locationStrategy) {\n this._locationStrategy = locationStrategy;\n const baseHref = this._locationStrategy.getBaseHref();\n // Note: This class's interaction with base HREF does not fully follow the rules\n // outlined in the spec https://www.freesoft.org/CIE/RFC/1808/18.htm.\n // Instead of trying to fix individual bugs with more and more code, we should\n // investigate using the URL constructor and providing the base as a second\n // argument.\n // https://developer.mozilla.org/en-US/docs/Web/API/URL/URL#parameters\n this._basePath = _stripOrigin(stripTrailingSlash(_stripIndexHtml(baseHref)));\n this._locationStrategy.onPopState(ev => {\n this._subject.next({\n 'url': this.path(true),\n 'pop': true,\n 'state': ev.state,\n 'type': ev.type\n });\n });\n }\n /** @nodoc */\n ngOnDestroy() {\n this._urlChangeSubscription?.unsubscribe();\n this._urlChangeListeners = [];\n }\n /**\n * Normalizes the URL path for this location.\n *\n * @param includeHash True to include an anchor fragment in the path.\n *\n * @returns The normalized URL path.\n */\n // TODO: vsavkin. Remove the boolean flag and always include hash once the deprecated router is\n // removed.\n path(includeHash = false) {\n return this.normalize(this._locationStrategy.path(includeHash));\n }\n /**\n * Reports the current state of the location history.\n * @returns The current value of the `history.state` object.\n */\n getState() {\n return this._locationStrategy.getState();\n }\n /**\n * Normalizes the given path and compares to the current normalized path.\n *\n * @param path The given URL path.\n * @param query Query parameters.\n *\n * @returns True if the given URL path is equal to the current normalized path, false\n * otherwise.\n */\n isCurrentPathEqualTo(path, query = '') {\n return this.path() == this.normalize(path + normalizeQueryParams(query));\n }\n /**\n * Normalizes a URL path by stripping any trailing slashes.\n *\n * @param url String representing a URL.\n *\n * @returns The normalized URL string.\n */\n normalize(url) {\n return Location.stripTrailingSlash(_stripBasePath(this._basePath, _stripIndexHtml(url)));\n }\n /**\n * Normalizes an external URL path.\n * If the given URL doesn't begin with a leading slash (`'/'`), adds one\n * before normalizing. Adds a hash if `HashLocationStrategy` is\n * in use, or the `APP_BASE_HREF` if the `PathLocationStrategy` is in use.\n *\n * @param url String representing a URL.\n *\n * @returns A normalized platform-specific URL.\n */\n prepareExternalUrl(url) {\n if (url && url[0] !== '/') {\n url = '/' + url;\n }\n return this._locationStrategy.prepareExternalUrl(url);\n }\n // TODO: rename this method to pushState\n /**\n * Changes the browser's URL to a normalized version of a given URL, and pushes a\n * new item onto the platform's history.\n *\n * @param path URL path to normalize.\n * @param query Query parameters.\n * @param state Location history state.\n *\n */\n go(path, query = '', state = null) {\n this._locationStrategy.pushState(state, '', path, query);\n this._notifyUrlChangeListeners(this.prepareExternalUrl(path + normalizeQueryParams(query)), state);\n }\n /**\n * Changes the browser's URL to a normalized version of the given URL, and replaces\n * the top item on the platform's history stack.\n *\n * @param path URL path to normalize.\n * @param query Query parameters.\n * @param state Location history state.\n */\n replaceState(path, query = '', state = null) {\n this._locationStrategy.replaceState(state, '', path, query);\n this._notifyUrlChangeListeners(this.prepareExternalUrl(path + normalizeQueryParams(query)), state);\n }\n /**\n * Navigates forward in the platform's history.\n */\n forward() {\n this._locationStrategy.forward();\n }\n /**\n * Navigates back in the platform's history.\n */\n back() {\n this._locationStrategy.back();\n }\n /**\n * Navigate to a specific page from session history, identified by its relative position to the\n * current page.\n *\n * @param relativePosition Position of the target page in the history relative to the current\n * page.\n * A negative value moves backwards, a positive value moves forwards, e.g. `location.historyGo(2)`\n * moves forward two pages and `location.historyGo(-2)` moves back two pages. When we try to go\n * beyond what's stored in the history session, we stay in the current page. Same behaviour occurs\n * when `relativePosition` equals 0.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/History_API#Moving_to_a_specific_point_in_history\n */\n historyGo(relativePosition = 0) {\n this._locationStrategy.historyGo?.(relativePosition);\n }\n /**\n * Registers a URL change listener. Use to catch updates performed by the Angular\n * framework that are not detectible through \"popstate\" or \"hashchange\" events.\n *\n * @param fn The change handler function, which take a URL and a location history state.\n * @returns A function that, when executed, unregisters a URL change listener.\n */\n onUrlChange(fn) {\n this._urlChangeListeners.push(fn);\n this._urlChangeSubscription ??= this.subscribe(v => {\n this._notifyUrlChangeListeners(v.url, v.state);\n });\n return () => {\n const fnIndex = this._urlChangeListeners.indexOf(fn);\n this._urlChangeListeners.splice(fnIndex, 1);\n if (this._urlChangeListeners.length === 0) {\n this._urlChangeSubscription?.unsubscribe();\n this._urlChangeSubscription = null;\n }\n };\n }\n /** @internal */\n _notifyUrlChangeListeners(url = '', state) {\n this._urlChangeListeners.forEach(fn => fn(url, state));\n }\n /**\n * Subscribes to the platform's `popState` events.\n *\n * Note: `Location.go()` does not trigger the `popState` event in the browser. Use\n * `Location.onUrlChange()` to subscribe to URL changes instead.\n *\n * @param value Event that is triggered when the state history changes.\n * @param exception The exception to throw.\n *\n * @see [onpopstate](https://developer.mozilla.org/en-US/docs/Web/API/WindowEventHandlers/onpopstate)\n *\n * @returns Subscribed events.\n */\n subscribe(onNext, onThrow, onReturn) {\n return this._subject.subscribe({\n next: onNext,\n error: onThrow ?? undefined,\n complete: onReturn ?? undefined\n });\n }\n /**\n * Normalizes URL parameters by prepending with `?` if needed.\n *\n * @param params String of URL parameters.\n *\n * @returns The normalized URL parameters string.\n */\n static normalizeQueryParams = normalizeQueryParams;\n /**\n * Joins two parts of a URL with a slash if needed.\n *\n * @param start URL string\n * @param end URL string\n *\n *\n * @returns The joined URL string.\n */\n static joinWithSlash = joinWithSlash;\n /**\n * Removes a trailing slash from a URL string if needed.\n * Looks for the first occurrence of either `#`, `?`, or the end of the\n * line as `/` characters and removes the trailing slash if one exists.\n *\n * @param url URL string.\n *\n * @returns The URL string, modified if needed.\n */\n static stripTrailingSlash = stripTrailingSlash;\n static ɵfac = function Location_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || Location)(i0.ɵɵinject(LocationStrategy));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: Location,\n factory: () => createLocation(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(Location, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n // See #23917\n useFactory: createLocation\n }]\n }], () => [{\n type: LocationStrategy\n }], null);\n})();\nfunction createLocation() {\n return new Location(ɵɵinject(LocationStrategy));\n}\nfunction _stripBasePath(basePath, url) {\n if (!basePath || !url.startsWith(basePath)) {\n return url;\n }\n const strippedUrl = url.substring(basePath.length);\n if (strippedUrl === '' || ['/', ';', '?', '#'].includes(strippedUrl[0])) {\n return strippedUrl;\n }\n return url;\n}\nfunction _stripIndexHtml(url) {\n return url.replace(/\\/index.html$/, '');\n}\nfunction _stripOrigin(baseHref) {\n // DO NOT REFACTOR! Previously, this check looked like this:\n // `/^(https?:)?\\/\\//.test(baseHref)`, but that resulted in\n // syntactically incorrect code after Closure Compiler minification.\n // This was likely caused by a bug in Closure Compiler, but\n // for now, the check is rewritten to use `new RegExp` instead.\n const isAbsoluteUrl = new RegExp('^(https?:)?//').test(baseHref);\n if (isAbsoluteUrl) {\n const [, pathname] = baseHref.split(/\\/\\/[^\\/]+/);\n return pathname;\n }\n return baseHref;\n}\n\n/** @internal */\nconst CURRENCIES_EN = {\n \"ADP\": [undefined, undefined, 0],\n \"AFN\": [undefined, \"Ø‹\", 0],\n \"ALL\": [undefined, undefined, 0],\n \"AMD\": [undefined, \"Ö\", 2],\n \"AOA\": [undefined, \"Kz\"],\n \"ARS\": [undefined, \"$\"],\n \"AUD\": [\"A$\", \"$\"],\n \"AZN\": [undefined, \"₼\"],\n \"BAM\": [undefined, \"KM\"],\n \"BBD\": [undefined, \"$\"],\n \"BDT\": [undefined, \"৳\"],\n \"BHD\": [undefined, undefined, 3],\n \"BIF\": [undefined, undefined, 0],\n \"BMD\": [undefined, \"$\"],\n \"BND\": [undefined, \"$\"],\n \"BOB\": [undefined, \"Bs\"],\n \"BRL\": [\"R$\"],\n \"BSD\": [undefined, \"$\"],\n \"BWP\": [undefined, \"P\"],\n \"BYN\": [undefined, undefined, 2],\n \"BYR\": [undefined, undefined, 0],\n \"BZD\": [undefined, \"$\"],\n \"CAD\": [\"CA$\", \"$\", 2],\n \"CHF\": [undefined, undefined, 2],\n \"CLF\": [undefined, undefined, 4],\n \"CLP\": [undefined, \"$\", 0],\n \"CNY\": [\"CNÂ¥\", \"Â¥\"],\n \"COP\": [undefined, \"$\", 2],\n \"CRC\": [undefined, \"â‚¡\", 2],\n \"CUC\": [undefined, \"$\"],\n \"CUP\": [undefined, \"$\"],\n \"CZK\": [undefined, \"KÄ\", 2],\n \"DJF\": [undefined, undefined, 0],\n \"DKK\": [undefined, \"kr\", 2],\n \"DOP\": [undefined, \"$\"],\n \"EGP\": [undefined, \"E£\"],\n \"ESP\": [undefined, \"₧\", 0],\n \"EUR\": [\"€\"],\n \"FJD\": [undefined, \"$\"],\n \"FKP\": [undefined, \"£\"],\n \"GBP\": [\"£\"],\n \"GEL\": [undefined, \"₾\"],\n \"GHS\": [undefined, \"GH₵\"],\n \"GIP\": [undefined, \"£\"],\n \"GNF\": [undefined, \"FG\", 0],\n \"GTQ\": [undefined, \"Q\"],\n \"GYD\": [undefined, \"$\", 2],\n \"HKD\": [\"HK$\", \"$\"],\n \"HNL\": [undefined, \"L\"],\n \"HRK\": [undefined, \"kn\"],\n \"HUF\": [undefined, \"Ft\", 2],\n \"IDR\": [undefined, \"Rp\", 2],\n \"ILS\": [\"₪\"],\n \"INR\": [\"₹\"],\n \"IQD\": [undefined, undefined, 0],\n \"IRR\": [undefined, undefined, 0],\n \"ISK\": [undefined, \"kr\", 0],\n \"ITL\": [undefined, undefined, 0],\n \"JMD\": [undefined, \"$\"],\n \"JOD\": [undefined, undefined, 3],\n \"JPY\": [\"Â¥\", undefined, 0],\n \"KHR\": [undefined, \"៛\"],\n \"KMF\": [undefined, \"CF\", 0],\n \"KPW\": [undefined, \"â‚©\", 0],\n \"KRW\": [\"â‚©\", undefined, 0],\n \"KWD\": [undefined, undefined, 3],\n \"KYD\": [undefined, \"$\"],\n \"KZT\": [undefined, \"₸\"],\n \"LAK\": [undefined, \"â‚\", 0],\n \"LBP\": [undefined, \"L£\", 0],\n \"LKR\": [undefined, \"Rs\"],\n \"LRD\": [undefined, \"$\"],\n \"LTL\": [undefined, \"Lt\"],\n \"LUF\": [undefined, undefined, 0],\n \"LVL\": [undefined, \"Ls\"],\n \"LYD\": [undefined, undefined, 3],\n \"MGA\": [undefined, \"Ar\", 0],\n \"MGF\": [undefined, undefined, 0],\n \"MMK\": [undefined, \"K\", 0],\n \"MNT\": [undefined, \"â‚®\", 2],\n \"MRO\": [undefined, undefined, 0],\n \"MUR\": [undefined, \"Rs\", 2],\n \"MXN\": [\"MX$\", \"$\"],\n \"MYR\": [undefined, \"RM\"],\n \"NAD\": [undefined, \"$\"],\n \"NGN\": [undefined, \"₦\"],\n \"NIO\": [undefined, \"C$\"],\n \"NOK\": [undefined, \"kr\", 2],\n \"NPR\": [undefined, \"Rs\"],\n \"NZD\": [\"NZ$\", \"$\"],\n \"OMR\": [undefined, undefined, 3],\n \"PHP\": [\"₱\"],\n \"PKR\": [undefined, \"Rs\", 2],\n \"PLN\": [undefined, \"zÅ‚\"],\n \"PYG\": [undefined, \"₲\", 0],\n \"RON\": [undefined, \"lei\"],\n \"RSD\": [undefined, undefined, 0],\n \"RUB\": [undefined, \"₽\"],\n \"RWF\": [undefined, \"RF\", 0],\n \"SBD\": [undefined, \"$\"],\n \"SEK\": [undefined, \"kr\", 2],\n \"SGD\": [undefined, \"$\"],\n \"SHP\": [undefined, \"£\"],\n \"SLE\": [undefined, undefined, 2],\n \"SLL\": [undefined, undefined, 0],\n \"SOS\": [undefined, undefined, 0],\n \"SRD\": [undefined, \"$\"],\n \"SSP\": [undefined, \"£\"],\n \"STD\": [undefined, undefined, 0],\n \"STN\": [undefined, \"Db\"],\n \"SYP\": [undefined, \"£\", 0],\n \"THB\": [undefined, \"฿\"],\n \"TMM\": [undefined, undefined, 0],\n \"TND\": [undefined, undefined, 3],\n \"TOP\": [undefined, \"T$\"],\n \"TRL\": [undefined, undefined, 0],\n \"TRY\": [undefined, \"₺\"],\n \"TTD\": [undefined, \"$\"],\n \"TWD\": [\"NT$\", \"$\", 2],\n \"TZS\": [undefined, undefined, 2],\n \"UAH\": [undefined, \"â‚´\"],\n \"UGX\": [undefined, undefined, 0],\n \"USD\": [\"$\"],\n \"UYI\": [undefined, undefined, 0],\n \"UYU\": [undefined, \"$\"],\n \"UYW\": [undefined, undefined, 4],\n \"UZS\": [undefined, undefined, 2],\n \"VEF\": [undefined, \"Bs\", 2],\n \"VND\": [\"â‚«\", undefined, 0],\n \"VUV\": [undefined, undefined, 0],\n \"XAF\": [\"FCFA\", undefined, 0],\n \"XCD\": [\"EC$\", \"$\"],\n \"XOF\": [\"F CFA\", undefined, 0],\n \"XPF\": [\"CFPF\", undefined, 0],\n \"XXX\": [\"¤\"],\n \"YER\": [undefined, undefined, 0],\n \"ZAR\": [undefined, \"R\"],\n \"ZMK\": [undefined, undefined, 0],\n \"ZMW\": [undefined, \"ZK\"],\n \"ZWD\": [undefined, undefined, 0]\n};\n\n/**\n * Format styles that can be used to represent numbers.\n * @see {@link getLocaleNumberFormat}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated `getLocaleNumberFormat` is deprecated\n */\nvar NumberFormatStyle;\n(function (NumberFormatStyle) {\n NumberFormatStyle[NumberFormatStyle[\"Decimal\"] = 0] = \"Decimal\";\n NumberFormatStyle[NumberFormatStyle[\"Percent\"] = 1] = \"Percent\";\n NumberFormatStyle[NumberFormatStyle[\"Currency\"] = 2] = \"Currency\";\n NumberFormatStyle[NumberFormatStyle[\"Scientific\"] = 3] = \"Scientific\";\n})(NumberFormatStyle || (NumberFormatStyle = {}));\n/**\n * Plurality cases used for translating plurals to different languages.\n *\n * @see {@link NgPlural}\n * @see {@link NgPluralCase}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated `getLocalePluralCase` is deprecated\n */\nvar Plural;\n(function (Plural) {\n Plural[Plural[\"Zero\"] = 0] = \"Zero\";\n Plural[Plural[\"One\"] = 1] = \"One\";\n Plural[Plural[\"Two\"] = 2] = \"Two\";\n Plural[Plural[\"Few\"] = 3] = \"Few\";\n Plural[Plural[\"Many\"] = 4] = \"Many\";\n Plural[Plural[\"Other\"] = 5] = \"Other\";\n})(Plural || (Plural = {}));\n/**\n * Context-dependant translation forms for strings.\n * Typically the standalone version is for the nominative form of the word,\n * and the format version is used for the genitive case.\n * @see [CLDR website](http://cldr.unicode.org/translation/date-time-1/date-time#TOC-Standalone-vs.-Format-Styles)\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated locale data getters are deprecated\n */\nvar FormStyle;\n(function (FormStyle) {\n FormStyle[FormStyle[\"Format\"] = 0] = \"Format\";\n FormStyle[FormStyle[\"Standalone\"] = 1] = \"Standalone\";\n})(FormStyle || (FormStyle = {}));\n/**\n * String widths available for translations.\n * The specific character widths are locale-specific.\n * Examples are given for the word \"Sunday\" in English.\n *\n * @publicApi\n *\n * @deprecated locale data getters are deprecated\n */\nvar TranslationWidth;\n(function (TranslationWidth) {\n /** 1 character for `en-US`. For example: 'S' */\n TranslationWidth[TranslationWidth[\"Narrow\"] = 0] = \"Narrow\";\n /** 3 characters for `en-US`. For example: 'Sun' */\n TranslationWidth[TranslationWidth[\"Abbreviated\"] = 1] = \"Abbreviated\";\n /** Full length for `en-US`. For example: \"Sunday\" */\n TranslationWidth[TranslationWidth[\"Wide\"] = 2] = \"Wide\";\n /** 2 characters for `en-US`, For example: \"Su\" */\n TranslationWidth[TranslationWidth[\"Short\"] = 3] = \"Short\";\n})(TranslationWidth || (TranslationWidth = {}));\n/**\n * String widths available for date-time formats.\n * The specific character widths are locale-specific.\n * Examples are given for `en-US`.\n *\n * @see {@link getLocaleDateFormat}\n * @see {@link getLocaleTimeFormat}\n * @see {@link getLocaleDateTimeFormat}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n * @publicApi\n *\n * @deprecated Date locale data getters are deprecated\n */\nvar FormatWidth;\n(function (FormatWidth) {\n /**\n * For `en-US`, `'M/d/yy, h:mm a'`\n * (Example: `6/15/15, 9:03 AM`)\n */\n FormatWidth[FormatWidth[\"Short\"] = 0] = \"Short\";\n /**\n * For `en-US`, `'MMM d, y, h:mm:ss a'`\n * (Example: `Jun 15, 2015, 9:03:01 AM`)\n */\n FormatWidth[FormatWidth[\"Medium\"] = 1] = \"Medium\";\n /**\n * For `en-US`, `'MMMM d, y, h:mm:ss a z'`\n * (Example: `June 15, 2015 at 9:03:01 AM GMT+1`)\n */\n FormatWidth[FormatWidth[\"Long\"] = 2] = \"Long\";\n /**\n * For `en-US`, `'EEEE, MMMM d, y, h:mm:ss a zzzz'`\n * (Example: `Monday, June 15, 2015 at 9:03:01 AM GMT+01:00`)\n */\n FormatWidth[FormatWidth[\"Full\"] = 3] = \"Full\";\n})(FormatWidth || (FormatWidth = {}));\n// This needs to be an object literal, rather than an enum, because TypeScript 5.4+\n// doesn't allow numeric keys and we have `Infinity` and `NaN`.\n/**\n * Symbols that can be used to replace placeholders in number patterns.\n * Examples are based on `en-US` values.\n *\n * @see {@link getLocaleNumberSymbol}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated `getLocaleNumberSymbol` is deprecated\n *\n * @object-literal-as-enum\n */\nconst NumberSymbol = {\n /**\n * Decimal separator.\n * For `en-US`, the dot character.\n * Example: 2,345`.`67\n */\n Decimal: 0,\n /**\n * Grouping separator, typically for thousands.\n * For `en-US`, the comma character.\n * Example: 2`,`345.67\n */\n Group: 1,\n /**\n * List-item separator.\n * Example: \"one, two, and three\"\n */\n List: 2,\n /**\n * Sign for percentage (out of 100).\n * Example: 23.4%\n */\n PercentSign: 3,\n /**\n * Sign for positive numbers.\n * Example: +23\n */\n PlusSign: 4,\n /**\n * Sign for negative numbers.\n * Example: -23\n */\n MinusSign: 5,\n /**\n * Computer notation for exponential value (n times a power of 10).\n * Example: 1.2E3\n */\n Exponential: 6,\n /**\n * Human-readable format of exponential.\n * Example: 1.2x103\n */\n SuperscriptingExponent: 7,\n /**\n * Sign for permille (out of 1000).\n * Example: 23.4‰\n */\n PerMille: 8,\n /**\n * Infinity, can be used with plus and minus.\n * Example: ∞, +∞, -∞\n */\n Infinity: 9,\n /**\n * Not a number.\n * Example: NaN\n */\n NaN: 10,\n /**\n * Symbol used between time units.\n * Example: 10:52\n */\n TimeSeparator: 11,\n /**\n * Decimal separator for currency values (fallback to `Decimal`).\n * Example: $2,345.67\n */\n CurrencyDecimal: 12,\n /**\n * Group separator for currency values (fallback to `Group`).\n * Example: $2,345.67\n */\n CurrencyGroup: 13\n};\n/**\n * The value for each day of the week, based on the `en-US` locale\n *\n * @publicApi\n *\n * @deprecated Week locale getters are deprecated\n */\nvar WeekDay;\n(function (WeekDay) {\n WeekDay[WeekDay[\"Sunday\"] = 0] = \"Sunday\";\n WeekDay[WeekDay[\"Monday\"] = 1] = \"Monday\";\n WeekDay[WeekDay[\"Tuesday\"] = 2] = \"Tuesday\";\n WeekDay[WeekDay[\"Wednesday\"] = 3] = \"Wednesday\";\n WeekDay[WeekDay[\"Thursday\"] = 4] = \"Thursday\";\n WeekDay[WeekDay[\"Friday\"] = 5] = \"Friday\";\n WeekDay[WeekDay[\"Saturday\"] = 6] = \"Saturday\";\n})(WeekDay || (WeekDay = {}));\n/**\n * Retrieves the locale ID from the currently loaded locale.\n * The loaded locale could be, for example, a global one rather than a regional one.\n * @param locale A locale code, such as `fr-FR`.\n * @returns The locale code. For example, `fr`.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * This function serves no purpose when relying on the `Intl` API.\n */\nfunction getLocaleId(locale) {\n return ɵfindLocaleData(locale)[ɵLocaleDataIndex.LocaleId];\n}\n/**\n * Retrieves day period strings for the given locale.\n *\n * @param locale A locale code for the locale format rules to use.\n * @param formStyle The required grammatical form.\n * @param width The required character width.\n * @returns An array of localized period strings. For example, `[AM, PM]` for `en-US`.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.DateTimeFormat` for date formating instead.\n */\nfunction getLocaleDayPeriods(locale, formStyle, width) {\n const data = ɵfindLocaleData(locale);\n const amPmData = [data[ɵLocaleDataIndex.DayPeriodsFormat], data[ɵLocaleDataIndex.DayPeriodsStandalone]];\n const amPm = getLastDefinedValue(amPmData, formStyle);\n return getLastDefinedValue(amPm, width);\n}\n/**\n * Retrieves days of the week for the given locale, using the Gregorian calendar.\n *\n * @param locale A locale code for the locale format rules to use.\n * @param formStyle The required grammatical form.\n * @param width The required character width.\n * @returns An array of localized name strings.\n * For example,`[Sunday, Monday, ... Saturday]` for `en-US`.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.DateTimeFormat` for date formating instead.\n */\nfunction getLocaleDayNames(locale, formStyle, width) {\n const data = ɵfindLocaleData(locale);\n const daysData = [data[ɵLocaleDataIndex.DaysFormat], data[ɵLocaleDataIndex.DaysStandalone]];\n const days = getLastDefinedValue(daysData, formStyle);\n return getLastDefinedValue(days, width);\n}\n/**\n * Retrieves months of the year for the given locale, using the Gregorian calendar.\n *\n * @param locale A locale code for the locale format rules to use.\n * @param formStyle The required grammatical form.\n * @param width The required character width.\n * @returns An array of localized name strings.\n * For example, `[January, February, ...]` for `en-US`.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.DateTimeFormat` for date formating instead.\n */\nfunction getLocaleMonthNames(locale, formStyle, width) {\n const data = ɵfindLocaleData(locale);\n const monthsData = [data[ɵLocaleDataIndex.MonthsFormat], data[ɵLocaleDataIndex.MonthsStandalone]];\n const months = getLastDefinedValue(monthsData, formStyle);\n return getLastDefinedValue(months, width);\n}\n/**\n * Retrieves Gregorian-calendar eras for the given locale.\n * @param locale A locale code for the locale format rules to use.\n * @param width The required character width.\n\n * @returns An array of localized era strings.\n * For example, `[AD, BC]` for `en-US`.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.DateTimeFormat` for date formating instead.\n */\nfunction getLocaleEraNames(locale, width) {\n const data = ɵfindLocaleData(locale);\n const erasData = data[ɵLocaleDataIndex.Eras];\n return getLastDefinedValue(erasData, width);\n}\n/**\n * Retrieves the first day of the week for the given locale.\n *\n * @param locale A locale code for the locale format rules to use.\n * @returns A day index number, using the 0-based week-day index for `en-US`\n * (Sunday = 0, Monday = 1, ...).\n * For example, for `fr-FR`, returns 1 to indicate that the first day is Monday.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Intl's [`getWeekInfo`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/Locale/getWeekInfo) has partial support (Chromium M99 & Safari 17).\n * You may want to rely on the following alternatives:\n * - Libraries like [`Luxon`](https://moment.github.io/luxon/#/) rely on `Intl` but fallback on the ISO 8601 definition (monday) if `getWeekInfo` is not supported.\n * - Other librairies like [`date-fns`](https://date-fns.org/), [`day.js`](https://day.js.org/en/) or [`weekstart`](https://www.npmjs.com/package/weekstart) library provide their own locale based data for the first day of the week.\n */\nfunction getLocaleFirstDayOfWeek(locale) {\n const data = ɵfindLocaleData(locale);\n return data[ɵLocaleDataIndex.FirstDayOfWeek];\n}\n/**\n * Range of week days that are considered the week-end for the given locale.\n *\n * @param locale A locale code for the locale format rules to use.\n * @returns The range of day values, `[startDay, endDay]`.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Intl's [`getWeekInfo`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/Locale/getWeekInfo) has partial support (Chromium M99 & Safari 17).\n * Libraries like [`Luxon`](https://moment.github.io/luxon/#/) rely on `Intl` but fallback on the ISO 8601 definition (Saturday+Sunday) if `getWeekInfo` is not supported .\n */\nfunction getLocaleWeekEndRange(locale) {\n const data = ɵfindLocaleData(locale);\n return data[ɵLocaleDataIndex.WeekendRange];\n}\n/**\n * Retrieves a localized date-value formatting string.\n *\n * @param locale A locale code for the locale format rules to use.\n * @param width The format type.\n * @returns The localized formatting string.\n * @see {@link FormatWidth}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.DateTimeFormat` for date formating instead.\n */\nfunction getLocaleDateFormat(locale, width) {\n const data = ɵfindLocaleData(locale);\n return getLastDefinedValue(data[ɵLocaleDataIndex.DateFormat], width);\n}\n/**\n * Retrieves a localized time-value formatting string.\n *\n * @param locale A locale code for the locale format rules to use.\n * @param width The format type.\n * @returns The localized formatting string.\n * @see {@link FormatWidth}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n\n * @publicApi\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.DateTimeFormat` for date formating instead.\n */\nfunction getLocaleTimeFormat(locale, width) {\n const data = ɵfindLocaleData(locale);\n return getLastDefinedValue(data[ɵLocaleDataIndex.TimeFormat], width);\n}\n/**\n * Retrieves a localized date-time formatting string.\n *\n * @param locale A locale code for the locale format rules to use.\n * @param width The format type.\n * @returns The localized formatting string.\n * @see {@link FormatWidth}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.DateTimeFormat` for date formating instead.\n */\nfunction getLocaleDateTimeFormat(locale, width) {\n const data = ɵfindLocaleData(locale);\n const dateTimeFormatData = data[ɵLocaleDataIndex.DateTimeFormat];\n return getLastDefinedValue(dateTimeFormatData, width);\n}\n/**\n * Retrieves a localized number symbol that can be used to replace placeholders in number formats.\n * @param locale The locale code.\n * @param symbol The symbol to localize. Must be one of `NumberSymbol`.\n * @returns The character for the localized symbol.\n * @see {@link NumberSymbol}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.NumberFormat` to format numbers instead.\n */\nfunction getLocaleNumberSymbol(locale, symbol) {\n const data = ɵfindLocaleData(locale);\n const res = data[ɵLocaleDataIndex.NumberSymbols][symbol];\n if (typeof res === 'undefined') {\n if (symbol === NumberSymbol.CurrencyDecimal) {\n return data[ɵLocaleDataIndex.NumberSymbols][NumberSymbol.Decimal];\n } else if (symbol === NumberSymbol.CurrencyGroup) {\n return data[ɵLocaleDataIndex.NumberSymbols][NumberSymbol.Group];\n }\n }\n return res;\n}\n/**\n * Retrieves a number format for a given locale.\n *\n * Numbers are formatted using patterns, like `#,###.00`. For example, the pattern `#,###.00`\n * when used to format the number 12345.678 could result in \"12'345,678\". That would happen if the\n * grouping separator for your language is an apostrophe, and the decimal separator is a comma.\n *\n * <b>Important:</b> The characters `.` `,` `0` `#` (and others below) are special placeholders\n * that stand for the decimal separator, and so on, and are NOT real characters.\n * You must NOT \"translate\" the placeholders. For example, don't change `.` to `,` even though in\n * your language the decimal point is written with a comma. The symbols should be replaced by the\n * local equivalents, using the appropriate `NumberSymbol` for your language.\n *\n * Here are the special characters used in number patterns:\n *\n * | Symbol | Meaning |\n * |--------|---------|\n * | . | Replaced automatically by the character used for the decimal point. |\n * | , | Replaced by the \"grouping\" (thousands) separator. |\n * | 0 | Replaced by a digit (or zero if there aren't enough digits). |\n * | # | Replaced by a digit (or nothing if there aren't enough). |\n * | ¤ | Replaced by a currency symbol, such as $ or USD. |\n * | % | Marks a percent format. The % symbol may change position, but must be retained. |\n * | E | Marks a scientific format. The E symbol may change position, but must be retained. |\n * | ' | Special characters used as literal characters are quoted with ASCII single quotes. |\n *\n * @param locale A locale code for the locale format rules to use.\n * @param type The type of numeric value to be formatted (such as `Decimal` or `Currency`.)\n * @returns The localized format string.\n * @see {@link NumberFormatStyle}\n * @see [CLDR website](http://cldr.unicode.org/translation/number-patterns)\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Let `Intl.NumberFormat` determine the number format instead\n */\nfunction getLocaleNumberFormat(locale, type) {\n const data = ɵfindLocaleData(locale);\n return data[ɵLocaleDataIndex.NumberFormats][type];\n}\n/**\n * Retrieves the symbol used to represent the currency for the main country\n * corresponding to a given locale. For example, '$' for `en-US`.\n *\n * @param locale A locale code for the locale format rules to use.\n * @returns The localized symbol character,\n * or `null` if the main country cannot be determined.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Use the `Intl` API to format a currency with from currency code\n */\nfunction getLocaleCurrencySymbol(locale) {\n const data = ɵfindLocaleData(locale);\n return data[ɵLocaleDataIndex.CurrencySymbol] || null;\n}\n/**\n * Retrieves the name of the currency for the main country corresponding\n * to a given locale. For example, 'US Dollar' for `en-US`.\n * @param locale A locale code for the locale format rules to use.\n * @returns The currency name,\n * or `null` if the main country cannot be determined.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Use the `Intl` API to format a currency with from currency code\n */\nfunction getLocaleCurrencyName(locale) {\n const data = ɵfindLocaleData(locale);\n return data[ɵLocaleDataIndex.CurrencyName] || null;\n}\n/**\n * Retrieves the default currency code for the given locale.\n *\n * The default is defined as the first currency which is still in use.\n *\n * @param locale The code of the locale whose currency code we want.\n * @returns The code of the default currency for the given locale.\n *\n * @publicApi\n *\n * @deprecated We recommend you create a map of locale to ISO 4217 currency codes.\n * Time relative currency data is provided by the CLDR project. See https://www.unicode.org/cldr/charts/44/supplemental/detailed_territory_currency_information.html\n */\nfunction getLocaleCurrencyCode(locale) {\n return ɵgetLocaleCurrencyCode(locale);\n}\n/**\n * Retrieves the currency values for a given locale.\n * @param locale A locale code for the locale format rules to use.\n * @returns The currency values.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n */\nfunction getLocaleCurrencies(locale) {\n const data = ɵfindLocaleData(locale);\n return data[ɵLocaleDataIndex.Currencies];\n}\n/**\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Use `Intl.PluralRules` instead\n */\nconst getLocalePluralCase = ɵgetLocalePluralCase;\nfunction checkFullData(data) {\n if (!data[ɵLocaleDataIndex.ExtraData]) {\n throw new Error(`Missing extra locale data for the locale \"${data[ɵLocaleDataIndex.LocaleId]}\". Use \"registerLocaleData\" to load new data. See the \"I18n guide\" on angular.io to know more.`);\n }\n}\n/**\n * Retrieves locale-specific rules used to determine which day period to use\n * when more than one period is defined for a locale.\n *\n * There is a rule for each defined day period. The\n * first rule is applied to the first day period and so on.\n * Fall back to AM/PM when no rules are available.\n *\n * A rule can specify a period as time range, or as a single time value.\n *\n * This functionality is only available when you have loaded the full locale data.\n * See the [\"I18n guide\"](guide/i18n/format-data-locale).\n *\n * @param locale A locale code for the locale format rules to use.\n * @returns The rules for the locale, a single time value or array of *from-time, to-time*,\n * or null if no periods are available.\n *\n * @see {@link getLocaleExtraDayPeriods}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * Let `Intl.DateTimeFormat` determine the day period instead.\n */\nfunction getLocaleExtraDayPeriodRules(locale) {\n const data = ɵfindLocaleData(locale);\n checkFullData(data);\n const rules = data[ɵLocaleDataIndex.ExtraData][2 /* ɵExtraLocaleDataIndex.ExtraDayPeriodsRules */] || [];\n return rules.map(rule => {\n if (typeof rule === 'string') {\n return extractTime(rule);\n }\n return [extractTime(rule[0]), extractTime(rule[1])];\n });\n}\n/**\n * Retrieves locale-specific day periods, which indicate roughly how a day is broken up\n * in different languages.\n * For example, for `en-US`, periods are morning, noon, afternoon, evening, and midnight.\n *\n * This functionality is only available when you have loaded the full locale data.\n * See the [\"I18n guide\"](guide/i18n/format-data-locale).\n *\n * @param locale A locale code for the locale format rules to use.\n * @param formStyle The required grammatical form.\n * @param width The required character width.\n * @returns The translated day-period strings.\n * @see {@link getLocaleExtraDayPeriodRules}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * To extract a day period use `Intl.DateTimeFormat` with the `dayPeriod` option instead.\n */\nfunction getLocaleExtraDayPeriods(locale, formStyle, width) {\n const data = ɵfindLocaleData(locale);\n checkFullData(data);\n const dayPeriodsData = [data[ɵLocaleDataIndex.ExtraData][0 /* ɵExtraLocaleDataIndex.ExtraDayPeriodFormats */], data[ɵLocaleDataIndex.ExtraData][1 /* ɵExtraLocaleDataIndex.ExtraDayPeriodStandalone */]];\n const dayPeriods = getLastDefinedValue(dayPeriodsData, formStyle) || [];\n return getLastDefinedValue(dayPeriods, width) || [];\n}\n/**\n * Retrieves the writing direction of a specified locale\n * @param locale A locale code for the locale format rules to use.\n * @publicApi\n * @returns 'rtl' or 'ltr'\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * For dates and numbers, let `Intl.DateTimeFormat()` and `Intl.NumberFormat()` determine the writing direction.\n * The `Intl` alternative [`getTextInfo`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/Locale/getTextInfo).\n * has only partial support (Chromium M99 & Safari 17).\n * 3rd party alternatives like [`rtl-detect`](https://www.npmjs.com/package/rtl-detect) can work around this issue.\n */\nfunction getLocaleDirection(locale) {\n const data = ɵfindLocaleData(locale);\n return data[ɵLocaleDataIndex.Directionality];\n}\n/**\n * Retrieves the first value that is defined in an array, going backwards from an index position.\n *\n * To avoid repeating the same data (as when the \"format\" and \"standalone\" forms are the same)\n * add the first value to the locale data arrays, and add other values only if they are different.\n *\n * @param data The data array to retrieve from.\n * @param index A 0-based index into the array to start from.\n * @returns The value immediately before the given index position.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n */\nfunction getLastDefinedValue(data, index) {\n for (let i = index; i > -1; i--) {\n if (typeof data[i] !== 'undefined') {\n return data[i];\n }\n }\n throw new Error('Locale data API: locale data undefined');\n}\n/**\n * Extracts the hours and minutes from a string like \"15:45\"\n */\nfunction extractTime(time) {\n const [h, m] = time.split(':');\n return {\n hours: +h,\n minutes: +m\n };\n}\n/**\n * Retrieves the currency symbol for a given currency code.\n *\n * For example, for the default `en-US` locale, the code `USD` can\n * be represented by the narrow symbol `$` or the wide symbol `US$`.\n *\n * @param code The currency code.\n * @param format The format, `wide` or `narrow`.\n * @param locale A locale code for the locale format rules to use.\n *\n * @returns The symbol, or the currency code if no symbol is available.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * You can use `Intl.NumberFormat().formatToParts()` to extract the currency symbol.\n * For example: `Intl.NumberFormat('en', {style:'currency', currency: 'USD'}).formatToParts().find(part => part.type === 'currency').value`\n * returns `$` for USD currency code in the `en` locale.\n * Note: `US$` is a currency symbol for the `en-ca` locale but not the `en-us` locale.\n */\nfunction getCurrencySymbol(code, format, locale = 'en') {\n const currency = getLocaleCurrencies(locale)[code] || CURRENCIES_EN[code] || [];\n const symbolNarrow = currency[1 /* ɵCurrencyIndex.SymbolNarrow */];\n if (format === 'narrow' && typeof symbolNarrow === 'string') {\n return symbolNarrow;\n }\n return currency[0 /* ɵCurrencyIndex.Symbol */] || code;\n}\n// Most currencies have cents, that's why the default is 2\nconst DEFAULT_NB_OF_CURRENCY_DIGITS = 2;\n/**\n * Reports the number of decimal digits for a given currency.\n * The value depends upon the presence of cents in that particular currency.\n *\n * @param code The currency code.\n * @returns The number of decimal digits, typically 0 or 2.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n *\n * @deprecated Angular recommends relying on the `Intl` API for i18n.\n * This function should not be used anymore. Let `Intl.NumberFormat` determine the number of digits to display for the currency\n */\nfunction getNumberOfCurrencyDigits(code) {\n let digits;\n const currency = CURRENCIES_EN[code];\n if (currency) {\n digits = currency[2 /* ɵCurrencyIndex.NbOfDigits */];\n }\n return typeof digits === 'number' ? digits : DEFAULT_NB_OF_CURRENCY_DIGITS;\n}\nconst ISO8601_DATE_REGEX = /^(\\d{4,})-?(\\d\\d)-?(\\d\\d)(?:T(\\d\\d)(?::?(\\d\\d)(?::?(\\d\\d)(?:\\.(\\d+))?)?)?(Z|([+-])(\\d\\d):?(\\d\\d))?)?$/;\n// 1 2 3 4 5 6 7 8 9 10 11\nconst NAMED_FORMATS = {};\nconst DATE_FORMATS_SPLIT = /((?:[^BEGHLMOSWYZabcdhmswyz']+)|(?:'(?:[^']|'')*')|(?:G{1,5}|y{1,4}|Y{1,4}|M{1,5}|L{1,5}|w{1,2}|W{1}|d{1,2}|E{1,6}|c{1,6}|a{1,5}|b{1,5}|B{1,5}|h{1,2}|H{1,2}|m{1,2}|s{1,2}|S{1,3}|z{1,4}|Z{1,5}|O{1,4}))([\\s\\S]*)/;\n/**\n * @ngModule CommonModule\n * @description\n *\n * Formats a date according to locale rules.\n *\n * @param value The date to format, as a Date, or a number (milliseconds since UTC epoch)\n * or an [ISO date-time string](https://www.w3.org/TR/NOTE-datetime).\n * @param format The date-time components to include. See `DatePipe` for details.\n * @param locale A locale code for the locale format rules to use.\n * @param timezone The time zone. A time zone offset from GMT (such as `'+0430'`).\n * If not specified, uses host system settings.\n *\n * @returns The formatted date string.\n *\n * @see {@link DatePipe}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n */\nfunction formatDate(value, format, locale, timezone) {\n let date = toDate(value);\n const namedFormat = getNamedFormat(locale, format);\n format = namedFormat || format;\n let parts = [];\n let match;\n while (format) {\n match = DATE_FORMATS_SPLIT.exec(format);\n if (match) {\n parts = parts.concat(match.slice(1));\n const part = parts.pop();\n if (!part) {\n break;\n }\n format = part;\n } else {\n parts.push(format);\n break;\n }\n }\n let dateTimezoneOffset = date.getTimezoneOffset();\n if (timezone) {\n dateTimezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset);\n date = convertTimezoneToLocal(date, timezone, true);\n }\n let text = '';\n parts.forEach(value => {\n const dateFormatter = getDateFormatter(value);\n text += dateFormatter ? dateFormatter(date, locale, dateTimezoneOffset) : value === \"''\" ? \"'\" : value.replace(/(^'|'$)/g, '').replace(/''/g, \"'\");\n });\n return text;\n}\n/**\n * Create a new Date object with the given date value, and the time set to midnight.\n *\n * We cannot use `new Date(year, month, date)` because it maps years between 0 and 99 to 1900-1999.\n * See: https://github.com/angular/angular/issues/40377\n *\n * Note that this function returns a Date object whose time is midnight in the current locale's\n * timezone. In the future we might want to change this to be midnight in UTC, but this would be a\n * considerable breaking change.\n */\nfunction createDate(year, month, date) {\n // The `newDate` is set to midnight (UTC) on January 1st 1970.\n // - In PST this will be December 31st 1969 at 4pm.\n // - In GMT this will be January 1st 1970 at 1am.\n // Note that they even have different years, dates and months!\n const newDate = new Date(0);\n // `setFullYear()` allows years like 0001 to be set correctly. This function does not\n // change the internal time of the date.\n // Consider calling `setFullYear(2019, 8, 20)` (September 20, 2019).\n // - In PST this will now be September 20, 2019 at 4pm\n // - In GMT this will now be September 20, 2019 at 1am\n newDate.setFullYear(year, month, date);\n // We want the final date to be at local midnight, so we reset the time.\n // - In PST this will now be September 20, 2019 at 12am\n // - In GMT this will now be September 20, 2019 at 12am\n newDate.setHours(0, 0, 0);\n return newDate;\n}\nfunction getNamedFormat(locale, format) {\n const localeId = getLocaleId(locale);\n NAMED_FORMATS[localeId] ??= {};\n if (NAMED_FORMATS[localeId][format]) {\n return NAMED_FORMATS[localeId][format];\n }\n let formatValue = '';\n switch (format) {\n case 'shortDate':\n formatValue = getLocaleDateFormat(locale, FormatWidth.Short);\n break;\n case 'mediumDate':\n formatValue = getLocaleDateFormat(locale, FormatWidth.Medium);\n break;\n case 'longDate':\n formatValue = getLocaleDateFormat(locale, FormatWidth.Long);\n break;\n case 'fullDate':\n formatValue = getLocaleDateFormat(locale, FormatWidth.Full);\n break;\n case 'shortTime':\n formatValue = getLocaleTimeFormat(locale, FormatWidth.Short);\n break;\n case 'mediumTime':\n formatValue = getLocaleTimeFormat(locale, FormatWidth.Medium);\n break;\n case 'longTime':\n formatValue = getLocaleTimeFormat(locale, FormatWidth.Long);\n break;\n case 'fullTime':\n formatValue = getLocaleTimeFormat(locale, FormatWidth.Full);\n break;\n case 'short':\n const shortTime = getNamedFormat(locale, 'shortTime');\n const shortDate = getNamedFormat(locale, 'shortDate');\n formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Short), [shortTime, shortDate]);\n break;\n case 'medium':\n const mediumTime = getNamedFormat(locale, 'mediumTime');\n const mediumDate = getNamedFormat(locale, 'mediumDate');\n formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Medium), [mediumTime, mediumDate]);\n break;\n case 'long':\n const longTime = getNamedFormat(locale, 'longTime');\n const longDate = getNamedFormat(locale, 'longDate');\n formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Long), [longTime, longDate]);\n break;\n case 'full':\n const fullTime = getNamedFormat(locale, 'fullTime');\n const fullDate = getNamedFormat(locale, 'fullDate');\n formatValue = formatDateTime(getLocaleDateTimeFormat(locale, FormatWidth.Full), [fullTime, fullDate]);\n break;\n }\n if (formatValue) {\n NAMED_FORMATS[localeId][format] = formatValue;\n }\n return formatValue;\n}\nfunction formatDateTime(str, opt_values) {\n if (opt_values) {\n str = str.replace(/\\{([^}]+)}/g, function (match, key) {\n return opt_values != null && key in opt_values ? opt_values[key] : match;\n });\n }\n return str;\n}\nfunction padNumber(num, digits, minusSign = '-', trim, negWrap) {\n let neg = '';\n if (num < 0 || negWrap && num <= 0) {\n if (negWrap) {\n num = -num + 1;\n } else {\n num = -num;\n neg = minusSign;\n }\n }\n let strNum = String(num);\n while (strNum.length < digits) {\n strNum = '0' + strNum;\n }\n if (trim) {\n strNum = strNum.slice(strNum.length - digits);\n }\n return neg + strNum;\n}\nfunction formatFractionalSeconds(milliseconds, digits) {\n const strMs = padNumber(milliseconds, 3);\n return strMs.substring(0, digits);\n}\n/**\n * Returns a date formatter that transforms a date into its locale digit representation\n */\nfunction dateGetter(name, size, offset = 0, trim = false, negWrap = false) {\n return function (date, locale) {\n let part = getDatePart(name, date);\n if (offset > 0 || part > -offset) {\n part += offset;\n }\n if (name === 3 /* DateType.Hours */) {\n if (part === 0 && offset === -12) {\n part = 12;\n }\n } else if (name === 6 /* DateType.FractionalSeconds */) {\n return formatFractionalSeconds(part, size);\n }\n const localeMinus = getLocaleNumberSymbol(locale, NumberSymbol.MinusSign);\n return padNumber(part, size, localeMinus, trim, negWrap);\n };\n}\nfunction getDatePart(part, date) {\n switch (part) {\n case 0 /* DateType.FullYear */:\n return date.getFullYear();\n case 1 /* DateType.Month */:\n return date.getMonth();\n case 2 /* DateType.Date */:\n return date.getDate();\n case 3 /* DateType.Hours */:\n return date.getHours();\n case 4 /* DateType.Minutes */:\n return date.getMinutes();\n case 5 /* DateType.Seconds */:\n return date.getSeconds();\n case 6 /* DateType.FractionalSeconds */:\n return date.getMilliseconds();\n case 7 /* DateType.Day */:\n return date.getDay();\n default:\n throw new Error(`Unknown DateType value \"${part}\".`);\n }\n}\n/**\n * Returns a date formatter that transforms a date into its locale string representation\n */\nfunction dateStrGetter(name, width, form = FormStyle.Format, extended = false) {\n return function (date, locale) {\n return getDateTranslation(date, locale, name, width, form, extended);\n };\n}\n/**\n * Returns the locale translation of a date for a given form, type and width\n */\nfunction getDateTranslation(date, locale, name, width, form, extended) {\n switch (name) {\n case 2 /* TranslationType.Months */:\n return getLocaleMonthNames(locale, form, width)[date.getMonth()];\n case 1 /* TranslationType.Days */:\n return getLocaleDayNames(locale, form, width)[date.getDay()];\n case 0 /* TranslationType.DayPeriods */:\n const currentHours = date.getHours();\n const currentMinutes = date.getMinutes();\n if (extended) {\n const rules = getLocaleExtraDayPeriodRules(locale);\n const dayPeriods = getLocaleExtraDayPeriods(locale, form, width);\n const index = rules.findIndex(rule => {\n if (Array.isArray(rule)) {\n // morning, afternoon, evening, night\n const [from, to] = rule;\n const afterFrom = currentHours >= from.hours && currentMinutes >= from.minutes;\n const beforeTo = currentHours < to.hours || currentHours === to.hours && currentMinutes < to.minutes;\n // We must account for normal rules that span a period during the day (e.g. 6am-9am)\n // where `from` is less (earlier) than `to`. But also rules that span midnight (e.g.\n // 10pm - 5am) where `from` is greater (later!) than `to`.\n //\n // In the first case the current time must be BOTH after `from` AND before `to`\n // (e.g. 8am is after 6am AND before 10am).\n //\n // In the second case the current time must be EITHER after `from` OR before `to`\n // (e.g. 4am is before 5am but not after 10pm; and 11pm is not before 5am but it is\n // after 10pm).\n if (from.hours < to.hours) {\n if (afterFrom && beforeTo) {\n return true;\n }\n } else if (afterFrom || beforeTo) {\n return true;\n }\n } else {\n // noon or midnight\n if (rule.hours === currentHours && rule.minutes === currentMinutes) {\n return true;\n }\n }\n return false;\n });\n if (index !== -1) {\n return dayPeriods[index];\n }\n }\n // if no rules for the day periods, we use am/pm by default\n return getLocaleDayPeriods(locale, form, width)[currentHours < 12 ? 0 : 1];\n case 3 /* TranslationType.Eras */:\n return getLocaleEraNames(locale, width)[date.getFullYear() <= 0 ? 0 : 1];\n default:\n // This default case is not needed by TypeScript compiler, as the switch is exhaustive.\n // However Closure Compiler does not understand that and reports an error in typed mode.\n // The `throw new Error` below works around the problem, and the unexpected: never variable\n // makes sure tsc still checks this code is unreachable.\n const unexpected = name;\n throw new Error(`unexpected translation type ${unexpected}`);\n }\n}\n/**\n * Returns a date formatter that transforms a date and an offset into a timezone with ISO8601 or\n * GMT format depending on the width (eg: short = +0430, short:GMT = GMT+4, long = GMT+04:30,\n * extended = +04:30)\n */\nfunction timeZoneGetter(width) {\n return function (date, locale, offset) {\n const zone = -1 * offset;\n const minusSign = getLocaleNumberSymbol(locale, NumberSymbol.MinusSign);\n const hours = zone > 0 ? Math.floor(zone / 60) : Math.ceil(zone / 60);\n switch (width) {\n case 0 /* ZoneWidth.Short */:\n return (zone >= 0 ? '+' : '') + padNumber(hours, 2, minusSign) + padNumber(Math.abs(zone % 60), 2, minusSign);\n case 1 /* ZoneWidth.ShortGMT */:\n return 'GMT' + (zone >= 0 ? '+' : '') + padNumber(hours, 1, minusSign);\n case 2 /* ZoneWidth.Long */:\n return 'GMT' + (zone >= 0 ? '+' : '') + padNumber(hours, 2, minusSign) + ':' + padNumber(Math.abs(zone % 60), 2, minusSign);\n case 3 /* ZoneWidth.Extended */:\n if (offset === 0) {\n return 'Z';\n } else {\n return (zone >= 0 ? '+' : '') + padNumber(hours, 2, minusSign) + ':' + padNumber(Math.abs(zone % 60), 2, minusSign);\n }\n default:\n throw new Error(`Unknown zone width \"${width}\"`);\n }\n };\n}\nconst JANUARY = 0;\nconst THURSDAY = 4;\nfunction getFirstThursdayOfYear(year) {\n const firstDayOfYear = createDate(year, JANUARY, 1).getDay();\n return createDate(year, 0, 1 + (firstDayOfYear <= THURSDAY ? THURSDAY : THURSDAY + 7) - firstDayOfYear);\n}\n/**\n * ISO Week starts on day 1 (Monday) and ends with day 0 (Sunday)\n */\nfunction getThursdayThisIsoWeek(datetime) {\n // getDay returns 0-6 range with sunday as 0.\n const currentDay = datetime.getDay();\n // On a Sunday, read the previous Thursday since ISO weeks start on Monday.\n const deltaToThursday = currentDay === 0 ? -3 : THURSDAY - currentDay;\n return createDate(datetime.getFullYear(), datetime.getMonth(), datetime.getDate() + deltaToThursday);\n}\nfunction weekGetter(size, monthBased = false) {\n return function (date, locale) {\n let result;\n if (monthBased) {\n const nbDaysBefore1stDayOfMonth = new Date(date.getFullYear(), date.getMonth(), 1).getDay() - 1;\n const today = date.getDate();\n result = 1 + Math.floor((today + nbDaysBefore1stDayOfMonth) / 7);\n } else {\n const thisThurs = getThursdayThisIsoWeek(date);\n // Some days of a year are part of next year according to ISO 8601.\n // Compute the firstThurs from the year of this week's Thursday\n const firstThurs = getFirstThursdayOfYear(thisThurs.getFullYear());\n const diff = thisThurs.getTime() - firstThurs.getTime();\n result = 1 + Math.round(diff / 6.048e8); // 6.048e8 ms per week\n }\n return padNumber(result, size, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));\n };\n}\n/**\n * Returns a date formatter that provides the week-numbering year for the input date.\n */\nfunction weekNumberingYearGetter(size, trim = false) {\n return function (date, locale) {\n const thisThurs = getThursdayThisIsoWeek(date);\n const weekNumberingYear = thisThurs.getFullYear();\n return padNumber(weekNumberingYear, size, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign), trim);\n };\n}\nconst DATE_FORMATS = {};\n// Based on CLDR formats:\n// See complete list: http://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table\n// See also explanations: http://cldr.unicode.org/translation/date-time\n// TODO(ocombe): support all missing cldr formats: U, Q, D, F, e, j, J, C, A, v, V, X, x\nfunction getDateFormatter(format) {\n if (DATE_FORMATS[format]) {\n return DATE_FORMATS[format];\n }\n let formatter;\n switch (format) {\n // Era name (AD/BC)\n case 'G':\n case 'GG':\n case 'GGG':\n formatter = dateStrGetter(3 /* TranslationType.Eras */, TranslationWidth.Abbreviated);\n break;\n case 'GGGG':\n formatter = dateStrGetter(3 /* TranslationType.Eras */, TranslationWidth.Wide);\n break;\n case 'GGGGG':\n formatter = dateStrGetter(3 /* TranslationType.Eras */, TranslationWidth.Narrow);\n break;\n // 1 digit representation of the year, e.g. (AD 1 => 1, AD 199 => 199)\n case 'y':\n formatter = dateGetter(0 /* DateType.FullYear */, 1, 0, false, true);\n break;\n // 2 digit representation of the year, padded (00-99). (e.g. AD 2001 => 01, AD 2010 => 10)\n case 'yy':\n formatter = dateGetter(0 /* DateType.FullYear */, 2, 0, true, true);\n break;\n // 3 digit representation of the year, padded (000-999). (e.g. AD 2001 => 01, AD 2010 => 10)\n case 'yyy':\n formatter = dateGetter(0 /* DateType.FullYear */, 3, 0, false, true);\n break;\n // 4 digit representation of the year (e.g. AD 1 => 0001, AD 2010 => 2010)\n case 'yyyy':\n formatter = dateGetter(0 /* DateType.FullYear */, 4, 0, false, true);\n break;\n // 1 digit representation of the week-numbering year, e.g. (AD 1 => 1, AD 199 => 199)\n case 'Y':\n formatter = weekNumberingYearGetter(1);\n break;\n // 2 digit representation of the week-numbering year, padded (00-99). (e.g. AD 2001 => 01, AD\n // 2010 => 10)\n case 'YY':\n formatter = weekNumberingYearGetter(2, true);\n break;\n // 3 digit representation of the week-numbering year, padded (000-999). (e.g. AD 1 => 001, AD\n // 2010 => 2010)\n case 'YYY':\n formatter = weekNumberingYearGetter(3);\n break;\n // 4 digit representation of the week-numbering year (e.g. AD 1 => 0001, AD 2010 => 2010)\n case 'YYYY':\n formatter = weekNumberingYearGetter(4);\n break;\n // Month of the year (1-12), numeric\n case 'M':\n case 'L':\n formatter = dateGetter(1 /* DateType.Month */, 1, 1);\n break;\n case 'MM':\n case 'LL':\n formatter = dateGetter(1 /* DateType.Month */, 2, 1);\n break;\n // Month of the year (January, ...), string, format\n case 'MMM':\n formatter = dateStrGetter(2 /* TranslationType.Months */, TranslationWidth.Abbreviated);\n break;\n case 'MMMM':\n formatter = dateStrGetter(2 /* TranslationType.Months */, TranslationWidth.Wide);\n break;\n case 'MMMMM':\n formatter = dateStrGetter(2 /* TranslationType.Months */, TranslationWidth.Narrow);\n break;\n // Month of the year (January, ...), string, standalone\n case 'LLL':\n formatter = dateStrGetter(2 /* TranslationType.Months */, TranslationWidth.Abbreviated, FormStyle.Standalone);\n break;\n case 'LLLL':\n formatter = dateStrGetter(2 /* TranslationType.Months */, TranslationWidth.Wide, FormStyle.Standalone);\n break;\n case 'LLLLL':\n formatter = dateStrGetter(2 /* TranslationType.Months */, TranslationWidth.Narrow, FormStyle.Standalone);\n break;\n // Week of the year (1, ... 52)\n case 'w':\n formatter = weekGetter(1);\n break;\n case 'ww':\n formatter = weekGetter(2);\n break;\n // Week of the month (1, ...)\n case 'W':\n formatter = weekGetter(1, true);\n break;\n // Day of the month (1-31)\n case 'd':\n formatter = dateGetter(2 /* DateType.Date */, 1);\n break;\n case 'dd':\n formatter = dateGetter(2 /* DateType.Date */, 2);\n break;\n // Day of the Week StandAlone (1, 1, Mon, Monday, M, Mo)\n case 'c':\n case 'cc':\n formatter = dateGetter(7 /* DateType.Day */, 1);\n break;\n case 'ccc':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Abbreviated, FormStyle.Standalone);\n break;\n case 'cccc':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Wide, FormStyle.Standalone);\n break;\n case 'ccccc':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Narrow, FormStyle.Standalone);\n break;\n case 'cccccc':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Short, FormStyle.Standalone);\n break;\n // Day of the Week\n case 'E':\n case 'EE':\n case 'EEE':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Abbreviated);\n break;\n case 'EEEE':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Wide);\n break;\n case 'EEEEE':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Narrow);\n break;\n case 'EEEEEE':\n formatter = dateStrGetter(1 /* TranslationType.Days */, TranslationWidth.Short);\n break;\n // Generic period of the day (am-pm)\n case 'a':\n case 'aa':\n case 'aaa':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Abbreviated);\n break;\n case 'aaaa':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Wide);\n break;\n case 'aaaaa':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Narrow);\n break;\n // Extended period of the day (midnight, at night, ...), standalone\n case 'b':\n case 'bb':\n case 'bbb':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Abbreviated, FormStyle.Standalone, true);\n break;\n case 'bbbb':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Wide, FormStyle.Standalone, true);\n break;\n case 'bbbbb':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Narrow, FormStyle.Standalone, true);\n break;\n // Extended period of the day (midnight, night, ...), standalone\n case 'B':\n case 'BB':\n case 'BBB':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Abbreviated, FormStyle.Format, true);\n break;\n case 'BBBB':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Wide, FormStyle.Format, true);\n break;\n case 'BBBBB':\n formatter = dateStrGetter(0 /* TranslationType.DayPeriods */, TranslationWidth.Narrow, FormStyle.Format, true);\n break;\n // Hour in AM/PM, (1-12)\n case 'h':\n formatter = dateGetter(3 /* DateType.Hours */, 1, -12);\n break;\n case 'hh':\n formatter = dateGetter(3 /* DateType.Hours */, 2, -12);\n break;\n // Hour of the day (0-23)\n case 'H':\n formatter = dateGetter(3 /* DateType.Hours */, 1);\n break;\n // Hour in day, padded (00-23)\n case 'HH':\n formatter = dateGetter(3 /* DateType.Hours */, 2);\n break;\n // Minute of the hour (0-59)\n case 'm':\n formatter = dateGetter(4 /* DateType.Minutes */, 1);\n break;\n case 'mm':\n formatter = dateGetter(4 /* DateType.Minutes */, 2);\n break;\n // Second of the minute (0-59)\n case 's':\n formatter = dateGetter(5 /* DateType.Seconds */, 1);\n break;\n case 'ss':\n formatter = dateGetter(5 /* DateType.Seconds */, 2);\n break;\n // Fractional second\n case 'S':\n formatter = dateGetter(6 /* DateType.FractionalSeconds */, 1);\n break;\n case 'SS':\n formatter = dateGetter(6 /* DateType.FractionalSeconds */, 2);\n break;\n case 'SSS':\n formatter = dateGetter(6 /* DateType.FractionalSeconds */, 3);\n break;\n // Timezone ISO8601 short format (-0430)\n case 'Z':\n case 'ZZ':\n case 'ZZZ':\n formatter = timeZoneGetter(0 /* ZoneWidth.Short */);\n break;\n // Timezone ISO8601 extended format (-04:30)\n case 'ZZZZZ':\n formatter = timeZoneGetter(3 /* ZoneWidth.Extended */);\n break;\n // Timezone GMT short format (GMT+4)\n case 'O':\n case 'OO':\n case 'OOO':\n // Should be location, but fallback to format O instead because we don't have the data yet\n case 'z':\n case 'zz':\n case 'zzz':\n formatter = timeZoneGetter(1 /* ZoneWidth.ShortGMT */);\n break;\n // Timezone GMT long format (GMT+0430)\n case 'OOOO':\n case 'ZZZZ':\n // Should be location, but fallback to format O instead because we don't have the data yet\n case 'zzzz':\n formatter = timeZoneGetter(2 /* ZoneWidth.Long */);\n break;\n default:\n return null;\n }\n DATE_FORMATS[format] = formatter;\n return formatter;\n}\nfunction timezoneToOffset(timezone, fallback) {\n // Support: IE 11 only, Edge 13-15+\n // IE/Edge do not \"understand\" colon (`:`) in timezone\n timezone = timezone.replace(/:/g, '');\n const requestedTimezoneOffset = Date.parse('Jan 01, 1970 00:00:00 ' + timezone) / 60000;\n return isNaN(requestedTimezoneOffset) ? fallback : requestedTimezoneOffset;\n}\nfunction addDateMinutes(date, minutes) {\n date = new Date(date.getTime());\n date.setMinutes(date.getMinutes() + minutes);\n return date;\n}\nfunction convertTimezoneToLocal(date, timezone, reverse) {\n const reverseValue = reverse ? -1 : 1;\n const dateTimezoneOffset = date.getTimezoneOffset();\n const timezoneOffset = timezoneToOffset(timezone, dateTimezoneOffset);\n return addDateMinutes(date, reverseValue * (timezoneOffset - dateTimezoneOffset));\n}\n/**\n * Converts a value to date.\n *\n * Supported input formats:\n * - `Date`\n * - number: timestamp\n * - string: numeric (e.g. \"1234\"), ISO and date strings in a format supported by\n * [Date.parse()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/parse).\n * Note: ISO strings without time return a date without timeoffset.\n *\n * Throws if unable to convert to a date.\n */\nfunction toDate(value) {\n if (isDate(value)) {\n return value;\n }\n if (typeof value === 'number' && !isNaN(value)) {\n return new Date(value);\n }\n if (typeof value === 'string') {\n value = value.trim();\n if (/^(\\d{4}(-\\d{1,2}(-\\d{1,2})?)?)$/.test(value)) {\n /* For ISO Strings without time the day, month and year must be extracted from the ISO String\n before Date creation to avoid time offset and errors in the new Date.\n If we only replace '-' with ',' in the ISO String (\"2015,01,01\"), and try to create a new\n date, some browsers (e.g. IE 9) will throw an invalid Date error.\n If we leave the '-' (\"2015-01-01\") and try to create a new Date(\"2015-01-01\") the timeoffset\n is applied.\n Note: ISO months are 0 for January, 1 for February, ... */\n const [y, m = 1, d = 1] = value.split('-').map(val => +val);\n return createDate(y, m - 1, d);\n }\n const parsedNb = parseFloat(value);\n // any string that only contains numbers, like \"1234\" but not like \"1234hello\"\n if (!isNaN(value - parsedNb)) {\n return new Date(parsedNb);\n }\n let match;\n if (match = value.match(ISO8601_DATE_REGEX)) {\n return isoStringToDate(match);\n }\n }\n const date = new Date(value);\n if (!isDate(date)) {\n throw new Error(`Unable to convert \"${value}\" into a date`);\n }\n return date;\n}\n/**\n * Converts a date in ISO8601 to a Date.\n * Used instead of `Date.parse` because of browser discrepancies.\n */\nfunction isoStringToDate(match) {\n const date = new Date(0);\n let tzHour = 0;\n let tzMin = 0;\n // match[8] means that the string contains \"Z\" (UTC) or a timezone like \"+01:00\" or \"+0100\"\n const dateSetter = match[8] ? date.setUTCFullYear : date.setFullYear;\n const timeSetter = match[8] ? date.setUTCHours : date.setHours;\n // if there is a timezone defined like \"+01:00\" or \"+0100\"\n if (match[9]) {\n tzHour = Number(match[9] + match[10]);\n tzMin = Number(match[9] + match[11]);\n }\n dateSetter.call(date, Number(match[1]), Number(match[2]) - 1, Number(match[3]));\n const h = Number(match[4] || 0) - tzHour;\n const m = Number(match[5] || 0) - tzMin;\n const s = Number(match[6] || 0);\n // The ECMAScript specification (https://www.ecma-international.org/ecma-262/5.1/#sec-15.9.1.11)\n // defines that `DateTime` milliseconds should always be rounded down, so that `999.9ms`\n // becomes `999ms`.\n const ms = Math.floor(parseFloat('0.' + (match[7] || 0)) * 1000);\n timeSetter.call(date, h, m, s, ms);\n return date;\n}\nfunction isDate(value) {\n return value instanceof Date && !isNaN(value.valueOf());\n}\nconst NUMBER_FORMAT_REGEXP = /^(\\d+)?\\.((\\d+)(-(\\d+))?)?$/;\nconst MAX_DIGITS = 22;\nconst DECIMAL_SEP = '.';\nconst ZERO_CHAR = '0';\nconst PATTERN_SEP = ';';\nconst GROUP_SEP = ',';\nconst DIGIT_CHAR = '#';\nconst CURRENCY_CHAR = '¤';\nconst PERCENT_CHAR = '%';\n/**\n * Transforms a number to a locale string based on a style and a format.\n */\nfunction formatNumberToLocaleString(value, pattern, locale, groupSymbol, decimalSymbol, digitsInfo, isPercent = false) {\n let formattedText = '';\n let isZero = false;\n if (!isFinite(value)) {\n formattedText = getLocaleNumberSymbol(locale, NumberSymbol.Infinity);\n } else {\n let parsedNumber = parseNumber(value);\n if (isPercent) {\n parsedNumber = toPercent(parsedNumber);\n }\n let minInt = pattern.minInt;\n let minFraction = pattern.minFrac;\n let maxFraction = pattern.maxFrac;\n if (digitsInfo) {\n const parts = digitsInfo.match(NUMBER_FORMAT_REGEXP);\n if (parts === null) {\n throw new Error(`${digitsInfo} is not a valid digit info`);\n }\n const minIntPart = parts[1];\n const minFractionPart = parts[3];\n const maxFractionPart = parts[5];\n if (minIntPart != null) {\n minInt = parseIntAutoRadix(minIntPart);\n }\n if (minFractionPart != null) {\n minFraction = parseIntAutoRadix(minFractionPart);\n }\n if (maxFractionPart != null) {\n maxFraction = parseIntAutoRadix(maxFractionPart);\n } else if (minFractionPart != null && minFraction > maxFraction) {\n maxFraction = minFraction;\n }\n }\n roundNumber(parsedNumber, minFraction, maxFraction);\n let digits = parsedNumber.digits;\n let integerLen = parsedNumber.integerLen;\n const exponent = parsedNumber.exponent;\n let decimals = [];\n isZero = digits.every(d => !d);\n // pad zeros for small numbers\n for (; integerLen < minInt; integerLen++) {\n digits.unshift(0);\n }\n // pad zeros for small numbers\n for (; integerLen < 0; integerLen++) {\n digits.unshift(0);\n }\n // extract decimals digits\n if (integerLen > 0) {\n decimals = digits.splice(integerLen, digits.length);\n } else {\n decimals = digits;\n digits = [0];\n }\n // format the integer digits with grouping separators\n const groups = [];\n if (digits.length >= pattern.lgSize) {\n groups.unshift(digits.splice(-pattern.lgSize, digits.length).join(''));\n }\n while (digits.length > pattern.gSize) {\n groups.unshift(digits.splice(-pattern.gSize, digits.length).join(''));\n }\n if (digits.length) {\n groups.unshift(digits.join(''));\n }\n formattedText = groups.join(getLocaleNumberSymbol(locale, groupSymbol));\n // append the decimal digits\n if (decimals.length) {\n formattedText += getLocaleNumberSymbol(locale, decimalSymbol) + decimals.join('');\n }\n if (exponent) {\n formattedText += getLocaleNumberSymbol(locale, NumberSymbol.Exponential) + '+' + exponent;\n }\n }\n if (value < 0 && !isZero) {\n formattedText = pattern.negPre + formattedText + pattern.negSuf;\n } else {\n formattedText = pattern.posPre + formattedText + pattern.posSuf;\n }\n return formattedText;\n}\n/**\n * @ngModule CommonModule\n * @description\n *\n * Formats a number as currency using locale rules.\n *\n * @param value The number to format.\n * @param locale A locale code for the locale format rules to use.\n * @param currency A string containing the currency symbol or its name,\n * such as \"$\" or \"Canadian Dollar\". Used in output string, but does not affect the operation\n * of the function.\n * @param currencyCode The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217)\n * currency code, such as `USD` for the US dollar and `EUR` for the euro.\n * Used to determine the number of digits in the decimal part.\n * @param digitsInfo Decimal representation options, specified by a string in the following format:\n * `{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}`. See `DecimalPipe` for more details.\n *\n * @returns The formatted currency value.\n *\n * @see {@link formatNumber}\n * @see {@link DecimalPipe}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n */\nfunction formatCurrency(value, locale, currency, currencyCode, digitsInfo) {\n const format = getLocaleNumberFormat(locale, NumberFormatStyle.Currency);\n const pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));\n pattern.minFrac = getNumberOfCurrencyDigits(currencyCode);\n pattern.maxFrac = pattern.minFrac;\n const res = formatNumberToLocaleString(value, pattern, locale, NumberSymbol.CurrencyGroup, NumberSymbol.CurrencyDecimal, digitsInfo);\n return res.replace(CURRENCY_CHAR, currency)\n // if we have 2 time the currency character, the second one is ignored\n .replace(CURRENCY_CHAR, '')\n // If there is a spacing between currency character and the value and\n // the currency character is suppressed by passing an empty string, the\n // spacing character would remain as part of the string. Then we\n // should remove it.\n .trim();\n}\n/**\n * @ngModule CommonModule\n * @description\n *\n * Formats a number as a percentage according to locale rules.\n *\n * @param value The number to format.\n * @param locale A locale code for the locale format rules to use.\n * @param digitsInfo Decimal representation options, specified by a string in the following format:\n * `{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}`. See `DecimalPipe` for more details.\n *\n * @returns The formatted percentage value.\n *\n * @see {@link formatNumber}\n * @see {@link DecimalPipe}\n * @see [Internationalization (i18n) Guide](guide/i18n)\n * @publicApi\n *\n */\nfunction formatPercent(value, locale, digitsInfo) {\n const format = getLocaleNumberFormat(locale, NumberFormatStyle.Percent);\n const pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));\n const res = formatNumberToLocaleString(value, pattern, locale, NumberSymbol.Group, NumberSymbol.Decimal, digitsInfo, true);\n return res.replace(new RegExp(PERCENT_CHAR, 'g'), getLocaleNumberSymbol(locale, NumberSymbol.PercentSign));\n}\n/**\n * @ngModule CommonModule\n * @description\n *\n * Formats a number as text, with group sizing, separator, and other\n * parameters based on the locale.\n *\n * @param value The number to format.\n * @param locale A locale code for the locale format rules to use.\n * @param digitsInfo Decimal representation options, specified by a string in the following format:\n * `{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}`. See `DecimalPipe` for more details.\n *\n * @returns The formatted text string.\n * @see [Internationalization (i18n) Guide](guide/i18n)\n *\n * @publicApi\n */\nfunction formatNumber(value, locale, digitsInfo) {\n const format = getLocaleNumberFormat(locale, NumberFormatStyle.Decimal);\n const pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));\n return formatNumberToLocaleString(value, pattern, locale, NumberSymbol.Group, NumberSymbol.Decimal, digitsInfo);\n}\nfunction parseNumberFormat(format, minusSign = '-') {\n const p = {\n minInt: 1,\n minFrac: 0,\n maxFrac: 0,\n posPre: '',\n posSuf: '',\n negPre: '',\n negSuf: '',\n gSize: 0,\n lgSize: 0\n };\n const patternParts = format.split(PATTERN_SEP);\n const positive = patternParts[0];\n const negative = patternParts[1];\n const positiveParts = positive.indexOf(DECIMAL_SEP) !== -1 ? positive.split(DECIMAL_SEP) : [positive.substring(0, positive.lastIndexOf(ZERO_CHAR) + 1), positive.substring(positive.lastIndexOf(ZERO_CHAR) + 1)],\n integer = positiveParts[0],\n fraction = positiveParts[1] || '';\n p.posPre = integer.substring(0, integer.indexOf(DIGIT_CHAR));\n for (let i = 0; i < fraction.length; i++) {\n const ch = fraction.charAt(i);\n if (ch === ZERO_CHAR) {\n p.minFrac = p.maxFrac = i + 1;\n } else if (ch === DIGIT_CHAR) {\n p.maxFrac = i + 1;\n } else {\n p.posSuf += ch;\n }\n }\n const groups = integer.split(GROUP_SEP);\n p.gSize = groups[1] ? groups[1].length : 0;\n p.lgSize = groups[2] || groups[1] ? (groups[2] || groups[1]).length : 0;\n if (negative) {\n const trunkLen = positive.length - p.posPre.length - p.posSuf.length,\n pos = negative.indexOf(DIGIT_CHAR);\n p.negPre = negative.substring(0, pos).replace(/'/g, '');\n p.negSuf = negative.slice(pos + trunkLen).replace(/'/g, '');\n } else {\n p.negPre = minusSign + p.posPre;\n p.negSuf = p.posSuf;\n }\n return p;\n}\n// Transforms a parsed number into a percentage by multiplying it by 100\nfunction toPercent(parsedNumber) {\n // if the number is 0, don't do anything\n if (parsedNumber.digits[0] === 0) {\n return parsedNumber;\n }\n // Getting the current number of decimals\n const fractionLen = parsedNumber.digits.length - parsedNumber.integerLen;\n if (parsedNumber.exponent) {\n parsedNumber.exponent += 2;\n } else {\n if (fractionLen === 0) {\n parsedNumber.digits.push(0, 0);\n } else if (fractionLen === 1) {\n parsedNumber.digits.push(0);\n }\n parsedNumber.integerLen += 2;\n }\n return parsedNumber;\n}\n/**\n * Parses a number.\n * Significant bits of this parse algorithm came from https://github.com/MikeMcl/big.js/\n */\nfunction parseNumber(num) {\n let numStr = Math.abs(num) + '';\n let exponent = 0,\n digits,\n integerLen;\n let i, j, zeros;\n // Decimal point?\n if ((integerLen = numStr.indexOf(DECIMAL_SEP)) > -1) {\n numStr = numStr.replace(DECIMAL_SEP, '');\n }\n // Exponential form?\n if ((i = numStr.search(/e/i)) > 0) {\n // Work out the exponent.\n if (integerLen < 0) integerLen = i;\n integerLen += +numStr.slice(i + 1);\n numStr = numStr.substring(0, i);\n } else if (integerLen < 0) {\n // There was no decimal point or exponent so it is an integer.\n integerLen = numStr.length;\n }\n // Count the number of leading zeros.\n for (i = 0; numStr.charAt(i) === ZERO_CHAR; i++) {\n /* empty */\n }\n if (i === (zeros = numStr.length)) {\n // The digits are all zero.\n digits = [0];\n integerLen = 1;\n } else {\n // Count the number of trailing zeros\n zeros--;\n while (numStr.charAt(zeros) === ZERO_CHAR) zeros--;\n // Trailing zeros are insignificant so ignore them\n integerLen -= i;\n digits = [];\n // Convert string to array of digits without leading/trailing zeros.\n for (j = 0; i <= zeros; i++, j++) {\n digits[j] = Number(numStr.charAt(i));\n }\n }\n // If the number overflows the maximum allowed digits then use an exponent.\n if (integerLen > MAX_DIGITS) {\n digits = digits.splice(0, MAX_DIGITS - 1);\n exponent = integerLen - 1;\n integerLen = 1;\n }\n return {\n digits,\n exponent,\n integerLen\n };\n}\n/**\n * Round the parsed number to the specified number of decimal places\n * This function changes the parsedNumber in-place\n */\nfunction roundNumber(parsedNumber, minFrac, maxFrac) {\n if (minFrac > maxFrac) {\n throw new Error(`The minimum number of digits after fraction (${minFrac}) is higher than the maximum (${maxFrac}).`);\n }\n let digits = parsedNumber.digits;\n let fractionLen = digits.length - parsedNumber.integerLen;\n const fractionSize = Math.min(Math.max(minFrac, fractionLen), maxFrac);\n // The index of the digit to where rounding is to occur\n let roundAt = fractionSize + parsedNumber.integerLen;\n let digit = digits[roundAt];\n if (roundAt > 0) {\n // Drop fractional digits beyond `roundAt`\n digits.splice(Math.max(parsedNumber.integerLen, roundAt));\n // Set non-fractional digits beyond `roundAt` to 0\n for (let j = roundAt; j < digits.length; j++) {\n digits[j] = 0;\n }\n } else {\n // We rounded to zero so reset the parsedNumber\n fractionLen = Math.max(0, fractionLen);\n parsedNumber.integerLen = 1;\n digits.length = Math.max(1, roundAt = fractionSize + 1);\n digits[0] = 0;\n for (let i = 1; i < roundAt; i++) digits[i] = 0;\n }\n if (digit >= 5) {\n if (roundAt - 1 < 0) {\n for (let k = 0; k > roundAt; k--) {\n digits.unshift(0);\n parsedNumber.integerLen++;\n }\n digits.unshift(1);\n parsedNumber.integerLen++;\n } else {\n digits[roundAt - 1]++;\n }\n }\n // Pad out with zeros to get the required fraction length\n for (; fractionLen < Math.max(0, fractionSize); fractionLen++) digits.push(0);\n let dropTrailingZeros = fractionSize !== 0;\n // Minimal length = nb of decimals required + current nb of integers\n // Any number besides that is optional and can be removed if it's a trailing 0\n const minLen = minFrac + parsedNumber.integerLen;\n // Do any carrying, e.g. a digit was rounded up to 10\n const carry = digits.reduceRight(function (carry, d, i, digits) {\n d = d + carry;\n digits[i] = d < 10 ? d : d - 10; // d % 10\n if (dropTrailingZeros) {\n // Do not keep meaningless fractional trailing zeros (e.g. 15.52000 --> 15.52)\n if (digits[i] === 0 && i >= minLen) {\n digits.pop();\n } else {\n dropTrailingZeros = false;\n }\n }\n return d >= 10 ? 1 : 0; // Math.floor(d / 10);\n }, 0);\n if (carry) {\n digits.unshift(carry);\n parsedNumber.integerLen++;\n }\n}\nfunction parseIntAutoRadix(text) {\n const result = parseInt(text);\n if (isNaN(result)) {\n throw new Error('Invalid integer literal when parsing ' + text);\n }\n return result;\n}\n\n/**\n * @publicApi\n */\nclass NgLocalization {\n static ɵfac = function NgLocalization_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgLocalization)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: NgLocalization,\n factory: function NgLocalization_Factory(__ngFactoryType__) {\n let __ngConditionalFactory__ = null;\n if (__ngFactoryType__) {\n __ngConditionalFactory__ = new __ngFactoryType__();\n } else {\n __ngConditionalFactory__ = (locale => new NgLocaleLocalization(locale))(i0.ɵɵinject(LOCALE_ID));\n }\n return __ngConditionalFactory__;\n },\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgLocalization, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: locale => new NgLocaleLocalization(locale),\n deps: [LOCALE_ID]\n }]\n }], null, null);\n})();\n/**\n * Returns the plural category for a given value.\n * - \"=value\" when the case exists,\n * - the plural category otherwise\n */\nfunction getPluralCategory(value, cases, ngLocalization, locale) {\n let key = `=${value}`;\n if (cases.indexOf(key) > -1) {\n return key;\n }\n key = ngLocalization.getPluralCategory(value, locale);\n if (cases.indexOf(key) > -1) {\n return key;\n }\n if (cases.indexOf('other') > -1) {\n return 'other';\n }\n throw new Error(`No plural message found for value \"${value}\"`);\n}\n/**\n * Returns the plural case based on the locale\n *\n * @publicApi\n */\nclass NgLocaleLocalization extends NgLocalization {\n locale;\n constructor(locale) {\n super();\n this.locale = locale;\n }\n getPluralCategory(value, locale) {\n const plural = getLocalePluralCase(locale || this.locale)(value);\n switch (plural) {\n case Plural.Zero:\n return 'zero';\n case Plural.One:\n return 'one';\n case Plural.Two:\n return 'two';\n case Plural.Few:\n return 'few';\n case Plural.Many:\n return 'many';\n default:\n return 'other';\n }\n }\n static ɵfac = function NgLocaleLocalization_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgLocaleLocalization)(i0.ɵɵinject(LOCALE_ID));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: NgLocaleLocalization,\n factory: NgLocaleLocalization.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgLocaleLocalization, [{\n type: Injectable\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [LOCALE_ID]\n }]\n }], null);\n})();\n\n/**\n * Register global data to be used internally by Angular. See the\n * [\"I18n guide\"](guide/i18n/format-data-locale) to know how to import additional locale\n * data.\n *\n * The signature registerLocaleData(data: any, extraData?: any) is deprecated since v5.1\n *\n * @publicApi\n */\nfunction registerLocaleData(data, localeId, extraData) {\n return ɵregisterLocaleData(data, localeId, extraData);\n}\nfunction parseCookieValue(cookieStr, name) {\n name = encodeURIComponent(name);\n for (const cookie of cookieStr.split(';')) {\n const eqIndex = cookie.indexOf('=');\n const [cookieName, cookieValue] = eqIndex == -1 ? [cookie, ''] : [cookie.slice(0, eqIndex), cookie.slice(eqIndex + 1)];\n if (cookieName.trim() === name) {\n return decodeURIComponent(cookieValue);\n }\n }\n return null;\n}\nconst WS_REGEXP = /\\s+/;\nconst EMPTY_ARRAY = [];\n/**\n * @ngModule CommonModule\n *\n * @usageNotes\n * ```html\n * <some-element [ngClass]=\"stringExp|arrayExp|objExp|Set\">...</some-element>\n *\n * <some-element [ngClass]=\"{'class1 class2 class3' : true}\">...</some-element>\n * ```\n *\n * For more simple use cases you can use the [class bindings](/guide/templates/binding#css-class-and-style-property-bindings) directly.\n * It doesn't require importing a directive.\n *\n * ```html\n * <some-element [class]=\"'first second'\">...</some-element>\n *\n * <some-element [class.expanded]=\"isExpanded\">...</some-element>\n *\n * <some-element [class]=\"['first', 'second']\">...</some-element>\n *\n * <some-element [class]=\"{'first': true, 'second': true, 'third': false}\">...</some-element>\n * ```\n * @description\n *\n * Adds and removes CSS classes on an HTML element.\n *\n * The CSS classes are updated as follows, depending on the type of the expression evaluation:\n * - `string` - the CSS classes listed in the string (space delimited) are added,\n * - `Array` - the CSS classes declared as Array elements are added,\n * - `Object` - keys are CSS classes that get added when the expression given in the value\n * evaluates to a truthy value, otherwise they are removed.\n *\n *\n * @see [Class bindings](/guide/templates/binding#css-class-and-style-property-bindings)\n *\n * @publicApi\n */\nclass NgClass {\n _ngEl;\n _renderer;\n initialClasses = EMPTY_ARRAY;\n rawClass;\n stateMap = new Map();\n constructor(_ngEl, _renderer) {\n this._ngEl = _ngEl;\n this._renderer = _renderer;\n }\n set klass(value) {\n this.initialClasses = value != null ? value.trim().split(WS_REGEXP) : EMPTY_ARRAY;\n }\n set ngClass(value) {\n this.rawClass = typeof value === 'string' ? value.trim().split(WS_REGEXP) : value;\n }\n /*\n The NgClass directive uses the custom change detection algorithm for its inputs. The custom\n algorithm is necessary since inputs are represented as complex object or arrays that need to be\n deeply-compared.\n This algorithm is perf-sensitive since NgClass is used very frequently and its poor performance\n might negatively impact runtime performance of the entire change detection cycle. The design of\n this algorithm is making sure that:\n - there is no unnecessary DOM manipulation (CSS classes are added / removed from the DOM only when\n needed), even if references to bound objects change;\n - there is no memory allocation if nothing changes (even relatively modest memory allocation\n during the change detection cycle can result in GC pauses for some of the CD cycles).\n The algorithm works by iterating over the set of bound classes, staring with [class] binding and\n then going over [ngClass] binding. For each CSS class name:\n - check if it was seen before (this information is tracked in the state map) and if its value\n changed;\n - mark it as \"touched\" - names that are not marked are not present in the latest set of binding\n and we can remove such class name from the internal data structures;\n After iteration over all the CSS class names we've got data structure with all the information\n necessary to synchronize changes to the DOM - it is enough to iterate over the state map, flush\n changes to the DOM and reset internal data structures so those are ready for the next change\n detection cycle.\n */\n ngDoCheck() {\n // classes from the [class] binding\n for (const klass of this.initialClasses) {\n this._updateState(klass, true);\n }\n // classes from the [ngClass] binding\n const rawClass = this.rawClass;\n if (Array.isArray(rawClass) || rawClass instanceof Set) {\n for (const klass of rawClass) {\n this._updateState(klass, true);\n }\n } else if (rawClass != null) {\n for (const klass of Object.keys(rawClass)) {\n this._updateState(klass, Boolean(rawClass[klass]));\n }\n }\n this._applyStateDiff();\n }\n _updateState(klass, nextEnabled) {\n const state = this.stateMap.get(klass);\n if (state !== undefined) {\n if (state.enabled !== nextEnabled) {\n state.changed = true;\n state.enabled = nextEnabled;\n }\n state.touched = true;\n } else {\n this.stateMap.set(klass, {\n enabled: nextEnabled,\n changed: true,\n touched: true\n });\n }\n }\n _applyStateDiff() {\n for (const stateEntry of this.stateMap) {\n const klass = stateEntry[0];\n const state = stateEntry[1];\n if (state.changed) {\n this._toggleClass(klass, state.enabled);\n state.changed = false;\n } else if (!state.touched) {\n // A class that was previously active got removed from the new collection of classes -\n // remove from the DOM as well.\n if (state.enabled) {\n this._toggleClass(klass, false);\n }\n this.stateMap.delete(klass);\n }\n state.touched = false;\n }\n }\n _toggleClass(klass, enabled) {\n if (ngDevMode) {\n if (typeof klass !== 'string') {\n throw new Error(`NgClass can only toggle CSS classes expressed as strings, got ${ɵstringify(klass)}`);\n }\n }\n klass = klass.trim();\n if (klass.length > 0) {\n klass.split(WS_REGEXP).forEach(klass => {\n if (enabled) {\n this._renderer.addClass(this._ngEl.nativeElement, klass);\n } else {\n this._renderer.removeClass(this._ngEl.nativeElement, klass);\n }\n });\n }\n }\n static ɵfac = function NgClass_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgClass)(i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i0.Renderer2));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgClass,\n selectors: [[\"\", \"ngClass\", \"\"]],\n inputs: {\n klass: [0, \"class\", \"klass\"],\n ngClass: \"ngClass\"\n }\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgClass, [{\n type: Directive,\n args: [{\n selector: '[ngClass]'\n }]\n }], () => [{\n type: i0.ElementRef\n }, {\n type: i0.Renderer2\n }], {\n klass: [{\n type: Input,\n args: ['class']\n }],\n ngClass: [{\n type: Input,\n args: ['ngClass']\n }]\n });\n})();\n\n/**\n * Instantiates a {@link /api/core/Component Component} type and inserts its Host View into the current View.\n * `NgComponentOutlet` provides a declarative approach for dynamic component creation.\n *\n * `NgComponentOutlet` requires a component type, if a falsy value is set the view will clear and\n * any existing component will be destroyed.\n *\n * @usageNotes\n *\n * ### Fine tune control\n *\n * You can control the component creation process by using the following optional attributes:\n *\n * * `ngComponentOutletInputs`: Optional component inputs object, which will be bind to the\n * component.\n *\n * * `ngComponentOutletInjector`: Optional custom {@link Injector} that will be used as parent for\n * the Component. Defaults to the injector of the current view container.\n *\n * * `ngComponentOutletContent`: Optional list of projectable nodes to insert into the content\n * section of the component, if it exists.\n *\n * * `ngComponentOutletNgModule`: Optional NgModule class reference to allow loading another\n * module dynamically, then loading a component from that module.\n *\n * * `ngComponentOutletNgModuleFactory`: Deprecated config option that allows providing optional\n * NgModule factory to allow loading another module dynamically, then loading a component from that\n * module. Use `ngComponentOutletNgModule` instead.\n *\n * ### Syntax\n *\n * Simple\n * ```html\n * <ng-container *ngComponentOutlet=\"componentTypeExpression\"></ng-container>\n * ```\n *\n * With inputs\n * ```html\n * <ng-container *ngComponentOutlet=\"componentTypeExpression;\n * inputs: inputsExpression;\">\n * </ng-container>\n * ```\n *\n * Customized injector/content\n * ```html\n * <ng-container *ngComponentOutlet=\"componentTypeExpression;\n * injector: injectorExpression;\n * content: contentNodesExpression;\">\n * </ng-container>\n * ```\n *\n * Customized NgModule reference\n * ```html\n * <ng-container *ngComponentOutlet=\"componentTypeExpression;\n * ngModule: ngModuleClass;\">\n * </ng-container>\n * ```\n *\n * ### A simple example\n *\n * {@example common/ngComponentOutlet/ts/module.ts region='SimpleExample'}\n *\n * A more complete example with additional options:\n *\n * {@example common/ngComponentOutlet/ts/module.ts region='CompleteExample'}\n *\n * @publicApi\n * @ngModule CommonModule\n */\nclass NgComponentOutlet {\n _viewContainerRef;\n // TODO(crisbeto): this should be `Type<T>`, but doing so broke a few\n // targets in a TGP so we need to do it in a major version.\n /** Component that should be rendered in the outlet. */\n ngComponentOutlet = null;\n ngComponentOutletInputs;\n ngComponentOutletInjector;\n ngComponentOutletContent;\n ngComponentOutletNgModule;\n /**\n * @deprecated This input is deprecated, use `ngComponentOutletNgModule` instead.\n */\n ngComponentOutletNgModuleFactory;\n _componentRef;\n _moduleRef;\n /**\n * A helper data structure that allows us to track inputs that were part of the\n * ngComponentOutletInputs expression. Tracking inputs is necessary for proper removal of ones\n * that are no longer referenced.\n */\n _inputsUsed = new Map();\n /**\n * Gets the instance of the currently-rendered component.\n * Will be null if no component has been rendered.\n */\n get componentInstance() {\n return this._componentRef?.instance ?? null;\n }\n constructor(_viewContainerRef) {\n this._viewContainerRef = _viewContainerRef;\n }\n _needToReCreateNgModuleInstance(changes) {\n // Note: square brackets property accessor is safe for Closure compiler optimizations (the\n // `changes` argument of the `ngOnChanges` lifecycle hook retains the names of the fields that\n // were changed).\n return changes['ngComponentOutletNgModule'] !== undefined || changes['ngComponentOutletNgModuleFactory'] !== undefined;\n }\n _needToReCreateComponentInstance(changes) {\n // Note: square brackets property accessor is safe for Closure compiler optimizations (the\n // `changes` argument of the `ngOnChanges` lifecycle hook retains the names of the fields that\n // were changed).\n return changes['ngComponentOutlet'] !== undefined || changes['ngComponentOutletContent'] !== undefined || changes['ngComponentOutletInjector'] !== undefined || this._needToReCreateNgModuleInstance(changes);\n }\n /** @nodoc */\n ngOnChanges(changes) {\n if (this._needToReCreateComponentInstance(changes)) {\n this._viewContainerRef.clear();\n this._inputsUsed.clear();\n this._componentRef = undefined;\n if (this.ngComponentOutlet) {\n const injector = this.ngComponentOutletInjector || this._viewContainerRef.parentInjector;\n if (this._needToReCreateNgModuleInstance(changes)) {\n this._moduleRef?.destroy();\n if (this.ngComponentOutletNgModule) {\n this._moduleRef = createNgModule(this.ngComponentOutletNgModule, getParentInjector(injector));\n } else if (this.ngComponentOutletNgModuleFactory) {\n this._moduleRef = this.ngComponentOutletNgModuleFactory.create(getParentInjector(injector));\n } else {\n this._moduleRef = undefined;\n }\n }\n this._componentRef = this._viewContainerRef.createComponent(this.ngComponentOutlet, {\n injector,\n ngModuleRef: this._moduleRef,\n projectableNodes: this.ngComponentOutletContent\n });\n }\n }\n }\n /** @nodoc */\n ngDoCheck() {\n if (this._componentRef) {\n if (this.ngComponentOutletInputs) {\n for (const inputName of Object.keys(this.ngComponentOutletInputs)) {\n this._inputsUsed.set(inputName, true);\n }\n }\n this._applyInputStateDiff(this._componentRef);\n }\n }\n /** @nodoc */\n ngOnDestroy() {\n this._moduleRef?.destroy();\n }\n _applyInputStateDiff(componentRef) {\n for (const [inputName, touched] of this._inputsUsed) {\n if (!touched) {\n // The input that was previously active no longer exists and needs to be set to undefined.\n componentRef.setInput(inputName, undefined);\n this._inputsUsed.delete(inputName);\n } else {\n // Since touched is true, it can be asserted that the inputs object is not empty.\n componentRef.setInput(inputName, this.ngComponentOutletInputs[inputName]);\n this._inputsUsed.set(inputName, false);\n }\n }\n }\n static ɵfac = function NgComponentOutlet_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgComponentOutlet)(i0.ɵɵdirectiveInject(i0.ViewContainerRef));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgComponentOutlet,\n selectors: [[\"\", \"ngComponentOutlet\", \"\"]],\n inputs: {\n ngComponentOutlet: \"ngComponentOutlet\",\n ngComponentOutletInputs: \"ngComponentOutletInputs\",\n ngComponentOutletInjector: \"ngComponentOutletInjector\",\n ngComponentOutletContent: \"ngComponentOutletContent\",\n ngComponentOutletNgModule: \"ngComponentOutletNgModule\",\n ngComponentOutletNgModuleFactory: \"ngComponentOutletNgModuleFactory\"\n },\n exportAs: [\"ngComponentOutlet\"],\n features: [i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgComponentOutlet, [{\n type: Directive,\n args: [{\n selector: '[ngComponentOutlet]',\n exportAs: 'ngComponentOutlet'\n }]\n }], () => [{\n type: i0.ViewContainerRef\n }], {\n ngComponentOutlet: [{\n type: Input\n }],\n ngComponentOutletInputs: [{\n type: Input\n }],\n ngComponentOutletInjector: [{\n type: Input\n }],\n ngComponentOutletContent: [{\n type: Input\n }],\n ngComponentOutletNgModule: [{\n type: Input\n }],\n ngComponentOutletNgModuleFactory: [{\n type: Input\n }]\n });\n})();\n// Helper function that returns an Injector instance of a parent NgModule.\nfunction getParentInjector(injector) {\n const parentNgModule = injector.get(NgModuleRef);\n return parentNgModule.injector;\n}\n\n/**\n * @publicApi\n */\nclass NgForOfContext {\n $implicit;\n ngForOf;\n index;\n count;\n constructor(/** Reference to the current item from the collection. */\n $implicit,\n /**\n * The value of the iterable expression. Useful when the expression is\n * more complex then a property access, for example when using the async pipe\n * (`userStreams | async`).\n */\n ngForOf, /** Returns an index of the current item in the collection. */\n index, /** Returns total amount of items in the collection. */\n count) {\n this.$implicit = $implicit;\n this.ngForOf = ngForOf;\n this.index = index;\n this.count = count;\n }\n // Indicates whether this is the first item in the collection.\n get first() {\n return this.index === 0;\n }\n // Indicates whether this is the last item in the collection.\n get last() {\n return this.index === this.count - 1;\n }\n // Indicates whether an index of this item in the collection is even.\n get even() {\n return this.index % 2 === 0;\n }\n // Indicates whether an index of this item in the collection is odd.\n get odd() {\n return !this.even;\n }\n}\n/**\n * A [structural directive](guide/directives/structural-directives) that renders\n * a template for each item in a collection.\n * The directive is placed on an element, which becomes the parent\n * of the cloned templates.\n *\n * The `ngForOf` directive is generally used in the\n * [shorthand form](guide/directives/structural-directives#asterisk) `*ngFor`.\n * In this form, the template to be rendered for each iteration is the content\n * of an anchor element containing the directive.\n *\n * The following example shows the shorthand syntax with some options,\n * contained in an `<li>` element.\n *\n * ```html\n * <li *ngFor=\"let item of items; index as i; trackBy: trackByFn\">...</li>\n * ```\n *\n * The shorthand form expands into a long form that uses the `ngForOf` selector\n * on an `<ng-template>` element.\n * The content of the `<ng-template>` element is the `<li>` element that held the\n * short-form directive.\n *\n * Here is the expanded version of the short-form example.\n *\n * ```html\n * <ng-template ngFor let-item [ngForOf]=\"items\" let-i=\"index\" [ngForTrackBy]=\"trackByFn\">\n * <li>...</li>\n * </ng-template>\n * ```\n *\n * Angular automatically expands the shorthand syntax as it compiles the template.\n * The context for each embedded view is logically merged to the current component\n * context according to its lexical position.\n *\n * When using the shorthand syntax, Angular allows only [one structural directive\n * on an element](guide/directives/structural-directives#one-per-element).\n * If you want to iterate conditionally, for example,\n * put the `*ngIf` on a container element that wraps the `*ngFor` element.\n * For further discussion, see\n * [Structural Directives](guide/directives/structural-directives#one-per-element).\n *\n * @usageNotes\n *\n * ### Local variables\n *\n * `NgForOf` provides exported values that can be aliased to local variables.\n * For example:\n *\n * ```html\n * <li *ngFor=\"let user of users; index as i; first as isFirst\">\n * {{i}}/{{users.length}}. {{user}} <span *ngIf=\"isFirst\">default</span>\n * </li>\n * ```\n *\n * The following exported values can be aliased to local variables:\n *\n * - `$implicit: T`: The value of the individual items in the iterable (`ngForOf`).\n * - `ngForOf: NgIterable<T>`: The value of the iterable expression. Useful when the expression is\n * more complex then a property access, for example when using the async pipe (`userStreams |\n * async`).\n * - `index: number`: The index of the current item in the iterable.\n * - `count: number`: The length of the iterable.\n * - `first: boolean`: True when the item is the first item in the iterable.\n * - `last: boolean`: True when the item is the last item in the iterable.\n * - `even: boolean`: True when the item has an even index in the iterable.\n * - `odd: boolean`: True when the item has an odd index in the iterable.\n *\n * ### Change propagation\n *\n * When the contents of the iterator changes, `NgForOf` makes the corresponding changes to the DOM:\n *\n * * When an item is added, a new instance of the template is added to the DOM.\n * * When an item is removed, its template instance is removed from the DOM.\n * * When items are reordered, their respective templates are reordered in the DOM.\n *\n * Angular uses object identity to track insertions and deletions within the iterator and reproduce\n * those changes in the DOM. This has important implications for animations and any stateful\n * controls that are present, such as `<input>` elements that accept user input. Inserted rows can\n * be animated in, deleted rows can be animated out, and unchanged rows retain any unsaved state\n * such as user input.\n * For more on animations, see [Transitions and Triggers](guide/animations/transition-and-triggers).\n *\n * The identities of elements in the iterator can change while the data does not.\n * This can happen, for example, if the iterator is produced from an RPC to the server, and that\n * RPC is re-run. Even if the data hasn't changed, the second response produces objects with\n * different identities, and Angular must tear down the entire DOM and rebuild it (as if all old\n * elements were deleted and all new elements inserted).\n *\n * To avoid this expensive operation, you can customize the default tracking algorithm.\n * by supplying the `trackBy` option to `NgForOf`.\n * `trackBy` takes a function that has two arguments: `index` and `item`.\n * If `trackBy` is given, Angular tracks changes by the return value of the function.\n *\n * @see [Structural Directives](guide/directives/structural-directives)\n * @ngModule CommonModule\n * @publicApi\n */\nclass NgForOf {\n _viewContainer;\n _template;\n _differs;\n /**\n * The value of the iterable expression, which can be used as a\n * [template input variable](guide/directives/structural-directives#shorthand).\n */\n set ngForOf(ngForOf) {\n this._ngForOf = ngForOf;\n this._ngForOfDirty = true;\n }\n /**\n * Specifies a custom `TrackByFunction` to compute the identity of items in an iterable.\n *\n * If a custom `TrackByFunction` is not provided, `NgForOf` will use the item's [object\n * identity](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is)\n * as the key.\n *\n * `NgForOf` uses the computed key to associate items in an iterable with DOM elements\n * it produces for these items.\n *\n * A custom `TrackByFunction` is useful to provide good user experience in cases when items in an\n * iterable rendered using `NgForOf` have a natural identifier (for example, custom ID or a\n * primary key), and this iterable could be updated with new object instances that still\n * represent the same underlying entity (for example, when data is re-fetched from the server,\n * and the iterable is recreated and re-rendered, but most of the data is still the same).\n *\n * @see {@link TrackByFunction}\n */\n set ngForTrackBy(fn) {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && fn != null && typeof fn !== 'function') {\n console.warn(`trackBy must be a function, but received ${JSON.stringify(fn)}. ` + `See https://angular.io/api/common/NgForOf#change-propagation for more information.`);\n }\n this._trackByFn = fn;\n }\n get ngForTrackBy() {\n return this._trackByFn;\n }\n _ngForOf = null;\n _ngForOfDirty = true;\n _differ = null;\n // TODO(issue/24571): remove '!'\n // waiting for microsoft/typescript#43662 to allow the return type `TrackByFunction|undefined` for\n // the getter\n _trackByFn;\n constructor(_viewContainer, _template, _differs) {\n this._viewContainer = _viewContainer;\n this._template = _template;\n this._differs = _differs;\n }\n /**\n * A reference to the template that is stamped out for each item in the iterable.\n * @see [template reference variable](guide/templates/variables#template-reference-variables)\n */\n set ngForTemplate(value) {\n // TODO(TS2.1): make TemplateRef<Partial<NgForRowOf<T>>> once we move to TS v2.1\n // The current type is too restrictive; a template that just uses index, for example,\n // should be acceptable.\n if (value) {\n this._template = value;\n }\n }\n /**\n * Applies the changes when needed.\n * @nodoc\n */\n ngDoCheck() {\n if (this._ngForOfDirty) {\n this._ngForOfDirty = false;\n // React on ngForOf changes only once all inputs have been initialized\n const value = this._ngForOf;\n if (!this._differ && value) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n try {\n // CAUTION: this logic is duplicated for production mode below, as the try-catch\n // is only present in development builds.\n this._differ = this._differs.find(value).create(this.ngForTrackBy);\n } catch {\n let errorMessage = `Cannot find a differ supporting object '${value}' of type '` + `${getTypeName(value)}'. NgFor only supports binding to Iterables, such as Arrays.`;\n if (typeof value === 'object') {\n errorMessage += ' Did you mean to use the keyvalue pipe?';\n }\n throw new ɵRuntimeError(-2200 /* RuntimeErrorCode.NG_FOR_MISSING_DIFFER */, errorMessage);\n }\n } else {\n // CAUTION: this logic is duplicated for development mode above, as the try-catch\n // is only present in development builds.\n this._differ = this._differs.find(value).create(this.ngForTrackBy);\n }\n }\n }\n if (this._differ) {\n const changes = this._differ.diff(this._ngForOf);\n if (changes) this._applyChanges(changes);\n }\n }\n _applyChanges(changes) {\n const viewContainer = this._viewContainer;\n changes.forEachOperation((item, adjustedPreviousIndex, currentIndex) => {\n if (item.previousIndex == null) {\n // NgForOf is never \"null\" or \"undefined\" here because the differ detected\n // that a new item needs to be inserted from the iterable. This implies that\n // there is an iterable value for \"_ngForOf\".\n viewContainer.createEmbeddedView(this._template, new NgForOfContext(item.item, this._ngForOf, -1, -1), currentIndex === null ? undefined : currentIndex);\n } else if (currentIndex == null) {\n viewContainer.remove(adjustedPreviousIndex === null ? undefined : adjustedPreviousIndex);\n } else if (adjustedPreviousIndex !== null) {\n const view = viewContainer.get(adjustedPreviousIndex);\n viewContainer.move(view, currentIndex);\n applyViewChange(view, item);\n }\n });\n for (let i = 0, ilen = viewContainer.length; i < ilen; i++) {\n const viewRef = viewContainer.get(i);\n const context = viewRef.context;\n context.index = i;\n context.count = ilen;\n context.ngForOf = this._ngForOf;\n }\n changes.forEachIdentityChange(record => {\n const viewRef = viewContainer.get(record.currentIndex);\n applyViewChange(viewRef, record);\n });\n }\n /**\n * Asserts the correct type of the context for the template that `NgForOf` will render.\n *\n * The presence of this method is a signal to the Ivy template type-check compiler that the\n * `NgForOf` structural directive renders its template with a specific context type.\n */\n static ngTemplateContextGuard(dir, ctx) {\n return true;\n }\n static ɵfac = function NgForOf_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgForOf)(i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(i0.TemplateRef), i0.ɵɵdirectiveInject(i0.IterableDiffers));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgForOf,\n selectors: [[\"\", \"ngFor\", \"\", \"ngForOf\", \"\"]],\n inputs: {\n ngForOf: \"ngForOf\",\n ngForTrackBy: \"ngForTrackBy\",\n ngForTemplate: \"ngForTemplate\"\n }\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgForOf, [{\n type: Directive,\n args: [{\n selector: '[ngFor][ngForOf]'\n }]\n }], () => [{\n type: i0.ViewContainerRef\n }, {\n type: i0.TemplateRef\n }, {\n type: i0.IterableDiffers\n }], {\n ngForOf: [{\n type: Input\n }],\n ngForTrackBy: [{\n type: Input\n }],\n ngForTemplate: [{\n type: Input\n }]\n });\n})();\nfunction applyViewChange(view, record) {\n view.context.$implicit = record.item;\n}\nfunction getTypeName(type) {\n return type['name'] || typeof type;\n}\n\n/**\n * A structural directive that conditionally includes a template based on the value of\n * an expression coerced to Boolean.\n * When the expression evaluates to true, Angular renders the template\n * provided in a `then` clause, and when false or null,\n * Angular renders the template provided in an optional `else` clause. The default\n * template for the `else` clause is blank.\n *\n * A [shorthand form](guide/directives/structural-directives#asterisk) of the directive,\n * `*ngIf=\"condition\"`, is generally used, provided\n * as an attribute of the anchor element for the inserted template.\n * Angular expands this into a more explicit version, in which the anchor element\n * is contained in an `<ng-template>` element.\n *\n * Simple form with shorthand syntax:\n *\n * ```html\n * <div *ngIf=\"condition\">Content to render when condition is true.</div>\n * ```\n *\n * Simple form with expanded syntax:\n *\n * ```html\n * <ng-template [ngIf]=\"condition\"><div>Content to render when condition is\n * true.</div></ng-template>\n * ```\n *\n * Form with an \"else\" block:\n *\n * ```html\n * <div *ngIf=\"condition; else elseBlock\">Content to render when condition is true.</div>\n * <ng-template #elseBlock>Content to render when condition is false.</ng-template>\n * ```\n *\n * Shorthand form with \"then\" and \"else\" blocks:\n *\n * ```html\n * <div *ngIf=\"condition; then thenBlock else elseBlock\"></div>\n * <ng-template #thenBlock>Content to render when condition is true.</ng-template>\n * <ng-template #elseBlock>Content to render when condition is false.</ng-template>\n * ```\n *\n * Form with storing the value locally:\n *\n * ```html\n * <div *ngIf=\"condition as value; else elseBlock\">{{value}}</div>\n * <ng-template #elseBlock>Content to render when value is null.</ng-template>\n * ```\n *\n * @usageNotes\n *\n * The `*ngIf` directive is most commonly used to conditionally show an inline template,\n * as seen in the following example.\n * The default `else` template is blank.\n *\n * {@example common/ngIf/ts/module.ts region='NgIfSimple'}\n *\n * ### Showing an alternative template using `else`\n *\n * To display a template when `expression` evaluates to false, use an `else` template\n * binding as shown in the following example.\n * The `else` binding points to an `<ng-template>` element labeled `#elseBlock`.\n * The template can be defined anywhere in the component view, but is typically placed right after\n * `ngIf` for readability.\n *\n * {@example common/ngIf/ts/module.ts region='NgIfElse'}\n *\n * ### Using an external `then` template\n *\n * In the previous example, the then-clause template is specified inline, as the content of the\n * tag that contains the `ngIf` directive. You can also specify a template that is defined\n * externally, by referencing a labeled `<ng-template>` element. When you do this, you can\n * change which template to use at runtime, as shown in the following example.\n *\n * {@example common/ngIf/ts/module.ts region='NgIfThenElse'}\n *\n * ### Storing a conditional result in a variable\n *\n * You might want to show a set of properties from the same object. If you are waiting\n * for asynchronous data, the object can be undefined.\n * In this case, you can use `ngIf` and store the result of the condition in a local\n * variable as shown in the following example.\n *\n * {@example common/ngIf/ts/module.ts region='NgIfAs'}\n *\n * This code uses only one `AsyncPipe`, so only one subscription is created.\n * The conditional statement stores the result of `userStream|async` in the local variable `user`.\n * You can then bind the local `user` repeatedly.\n *\n * The conditional displays the data only if `userStream` returns a value,\n * so you don't need to use the\n * safe-navigation-operator (`?.`)\n * to guard against null values when accessing properties.\n * You can display an alternative template while waiting for the data.\n *\n * ### Shorthand syntax\n *\n * The shorthand syntax `*ngIf` expands into two separate template specifications\n * for the \"then\" and \"else\" clauses. For example, consider the following shorthand statement,\n * that is meant to show a loading page while waiting for data to be loaded.\n *\n * ```html\n * <div class=\"hero-list\" *ngIf=\"heroes else loading\">\n * ...\n * </div>\n *\n * <ng-template #loading>\n * <div>Loading...</div>\n * </ng-template>\n * ```\n *\n * You can see that the \"else\" clause references the `<ng-template>`\n * with the `#loading` label, and the template for the \"then\" clause\n * is provided as the content of the anchor element.\n *\n * However, when Angular expands the shorthand syntax, it creates\n * another `<ng-template>` tag, with `ngIf` and `ngIfElse` directives.\n * The anchor element containing the template for the \"then\" clause becomes\n * the content of this unlabeled `<ng-template>` tag.\n *\n * ```html\n * <ng-template [ngIf]=\"heroes\" [ngIfElse]=\"loading\">\n * <div class=\"hero-list\">\n * ...\n * </div>\n * </ng-template>\n *\n * <ng-template #loading>\n * <div>Loading...</div>\n * </ng-template>\n * ```\n *\n * The presence of the implicit template object has implications for the nesting of\n * structural directives. For more on this subject, see\n * [Structural Directives](guide/directives/structural-directives#one-per-element).\n *\n * @ngModule CommonModule\n * @publicApi\n */\nclass NgIf {\n _viewContainer;\n _context = new NgIfContext();\n _thenTemplateRef = null;\n _elseTemplateRef = null;\n _thenViewRef = null;\n _elseViewRef = null;\n constructor(_viewContainer, templateRef) {\n this._viewContainer = _viewContainer;\n this._thenTemplateRef = templateRef;\n }\n /**\n * The Boolean expression to evaluate as the condition for showing a template.\n */\n set ngIf(condition) {\n this._context.$implicit = this._context.ngIf = condition;\n this._updateView();\n }\n /**\n * A template to show if the condition expression evaluates to true.\n */\n set ngIfThen(templateRef) {\n assertTemplate('ngIfThen', templateRef);\n this._thenTemplateRef = templateRef;\n this._thenViewRef = null; // clear previous view if any.\n this._updateView();\n }\n /**\n * A template to show if the condition expression evaluates to false.\n */\n set ngIfElse(templateRef) {\n assertTemplate('ngIfElse', templateRef);\n this._elseTemplateRef = templateRef;\n this._elseViewRef = null; // clear previous view if any.\n this._updateView();\n }\n _updateView() {\n if (this._context.$implicit) {\n if (!this._thenViewRef) {\n this._viewContainer.clear();\n this._elseViewRef = null;\n if (this._thenTemplateRef) {\n this._thenViewRef = this._viewContainer.createEmbeddedView(this._thenTemplateRef, this._context);\n }\n }\n } else {\n if (!this._elseViewRef) {\n this._viewContainer.clear();\n this._thenViewRef = null;\n if (this._elseTemplateRef) {\n this._elseViewRef = this._viewContainer.createEmbeddedView(this._elseTemplateRef, this._context);\n }\n }\n }\n }\n /** @internal */\n static ngIfUseIfTypeGuard;\n /**\n * Assert the correct type of the expression bound to the `ngIf` input within the template.\n *\n * The presence of this static field is a signal to the Ivy template type check compiler that\n * when the `NgIf` structural directive renders its template, the type of the expression bound\n * to `ngIf` should be narrowed in some way. For `NgIf`, the binding expression itself is used to\n * narrow its type, which allows the strictNullChecks feature of TypeScript to work with `NgIf`.\n */\n static ngTemplateGuard_ngIf;\n /**\n * Asserts the correct type of the context for the template that `NgIf` will render.\n *\n * The presence of this method is a signal to the Ivy template type-check compiler that the\n * `NgIf` structural directive renders its template with a specific context type.\n */\n static ngTemplateContextGuard(dir, ctx) {\n return true;\n }\n static ɵfac = function NgIf_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgIf)(i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(i0.TemplateRef));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgIf,\n selectors: [[\"\", \"ngIf\", \"\"]],\n inputs: {\n ngIf: \"ngIf\",\n ngIfThen: \"ngIfThen\",\n ngIfElse: \"ngIfElse\"\n }\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgIf, [{\n type: Directive,\n args: [{\n selector: '[ngIf]'\n }]\n }], () => [{\n type: i0.ViewContainerRef\n }, {\n type: i0.TemplateRef\n }], {\n ngIf: [{\n type: Input\n }],\n ngIfThen: [{\n type: Input\n }],\n ngIfElse: [{\n type: Input\n }]\n });\n})();\n/**\n * @publicApi\n */\nclass NgIfContext {\n $implicit = null;\n ngIf = null;\n}\nfunction assertTemplate(property, templateRef) {\n const isTemplateRefOrNull = !!(!templateRef || templateRef.createEmbeddedView);\n if (!isTemplateRefOrNull) {\n throw new Error(`${property} must be a TemplateRef, but received '${ɵstringify(templateRef)}'.`);\n }\n}\nclass SwitchView {\n _viewContainerRef;\n _templateRef;\n _created = false;\n constructor(_viewContainerRef, _templateRef) {\n this._viewContainerRef = _viewContainerRef;\n this._templateRef = _templateRef;\n }\n create() {\n this._created = true;\n this._viewContainerRef.createEmbeddedView(this._templateRef);\n }\n destroy() {\n this._created = false;\n this._viewContainerRef.clear();\n }\n enforceState(created) {\n if (created && !this._created) {\n this.create();\n } else if (!created && this._created) {\n this.destroy();\n }\n }\n}\n/**\n * @ngModule CommonModule\n *\n * @description\n * The `[ngSwitch]` directive on a container specifies an expression to match against.\n * The expressions to match are provided by `ngSwitchCase` directives on views within the container.\n * - Every view that matches is rendered.\n * - If there are no matches, a view with the `ngSwitchDefault` directive is rendered.\n * - Elements within the `[NgSwitch]` statement but outside of any `NgSwitchCase`\n * or `ngSwitchDefault` directive are preserved at the location.\n *\n * @usageNotes\n * Define a container element for the directive, and specify the switch expression\n * to match against as an attribute:\n *\n * ```html\n * <container-element [ngSwitch]=\"switch_expression\">\n * ```\n *\n * Within the container, `*ngSwitchCase` statements specify the match expressions\n * as attributes. Include `*ngSwitchDefault` as the final case.\n *\n * ```html\n * <container-element [ngSwitch]=\"switch_expression\">\n * <some-element *ngSwitchCase=\"match_expression_1\">...</some-element>\n * ...\n * <some-element *ngSwitchDefault>...</some-element>\n * </container-element>\n * ```\n *\n * ### Usage Examples\n *\n * The following example shows how to use more than one case to display the same view:\n *\n * ```html\n * <container-element [ngSwitch]=\"switch_expression\">\n * <!-- the same view can be shown in more than one case -->\n * <some-element *ngSwitchCase=\"match_expression_1\">...</some-element>\n * <some-element *ngSwitchCase=\"match_expression_2\">...</some-element>\n * <some-other-element *ngSwitchCase=\"match_expression_3\">...</some-other-element>\n * <!--default case when there are no matches -->\n * <some-element *ngSwitchDefault>...</some-element>\n * </container-element>\n * ```\n *\n * The following example shows how cases can be nested:\n * ```html\n * <container-element [ngSwitch]=\"switch_expression\">\n * <some-element *ngSwitchCase=\"match_expression_1\">...</some-element>\n * <some-element *ngSwitchCase=\"match_expression_2\">...</some-element>\n * <some-other-element *ngSwitchCase=\"match_expression_3\">...</some-other-element>\n * <ng-container *ngSwitchCase=\"match_expression_3\">\n * <!-- use a ng-container to group multiple root nodes -->\n * <inner-element></inner-element>\n * <inner-other-element></inner-other-element>\n * </ng-container>\n * <some-element *ngSwitchDefault>...</some-element>\n * </container-element>\n * ```\n *\n * @publicApi\n * @see {@link NgSwitchCase}\n * @see {@link NgSwitchDefault}\n * @see [Structural Directives](guide/directives/structural-directives)\n *\n */\nclass NgSwitch {\n _defaultViews = [];\n _defaultUsed = false;\n _caseCount = 0;\n _lastCaseCheckIndex = 0;\n _lastCasesMatched = false;\n _ngSwitch;\n set ngSwitch(newValue) {\n this._ngSwitch = newValue;\n if (this._caseCount === 0) {\n this._updateDefaultCases(true);\n }\n }\n /** @internal */\n _addCase() {\n return this._caseCount++;\n }\n /** @internal */\n _addDefault(view) {\n this._defaultViews.push(view);\n }\n /** @internal */\n _matchCase(value) {\n const matched = value === this._ngSwitch;\n this._lastCasesMatched ||= matched;\n this._lastCaseCheckIndex++;\n if (this._lastCaseCheckIndex === this._caseCount) {\n this._updateDefaultCases(!this._lastCasesMatched);\n this._lastCaseCheckIndex = 0;\n this._lastCasesMatched = false;\n }\n return matched;\n }\n _updateDefaultCases(useDefault) {\n if (this._defaultViews.length > 0 && useDefault !== this._defaultUsed) {\n this._defaultUsed = useDefault;\n for (const defaultView of this._defaultViews) {\n defaultView.enforceState(useDefault);\n }\n }\n }\n static ɵfac = function NgSwitch_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgSwitch)();\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgSwitch,\n selectors: [[\"\", \"ngSwitch\", \"\"]],\n inputs: {\n ngSwitch: \"ngSwitch\"\n }\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgSwitch, [{\n type: Directive,\n args: [{\n selector: '[ngSwitch]'\n }]\n }], null, {\n ngSwitch: [{\n type: Input\n }]\n });\n})();\n/**\n * @ngModule CommonModule\n *\n * @description\n * Provides a switch case expression to match against an enclosing `ngSwitch` expression.\n * When the expressions match, the given `NgSwitchCase` template is rendered.\n * If multiple match expressions match the switch expression value, all of them are displayed.\n *\n * @usageNotes\n *\n * Within a switch container, `*ngSwitchCase` statements specify the match expressions\n * as attributes. Include `*ngSwitchDefault` as the final case.\n *\n * ```html\n * <container-element [ngSwitch]=\"switch_expression\">\n * <some-element *ngSwitchCase=\"match_expression_1\">...</some-element>\n * ...\n * <some-element *ngSwitchDefault>...</some-element>\n * </container-element>\n * ```\n *\n * Each switch-case statement contains an in-line HTML template or template reference\n * that defines the subtree to be selected if the value of the match expression\n * matches the value of the switch expression.\n *\n * As of Angular v17 the NgSwitch directive uses strict equality comparison (`===`) instead of\n * loose equality (`==`) to match different cases.\n *\n * @publicApi\n * @see {@link NgSwitch}\n * @see {@link NgSwitchDefault}\n *\n */\nclass NgSwitchCase {\n ngSwitch;\n _view;\n /**\n * Stores the HTML template to be selected on match.\n */\n ngSwitchCase;\n constructor(viewContainer, templateRef, ngSwitch) {\n this.ngSwitch = ngSwitch;\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !ngSwitch) {\n throwNgSwitchProviderNotFoundError('ngSwitchCase', 'NgSwitchCase');\n }\n ngSwitch._addCase();\n this._view = new SwitchView(viewContainer, templateRef);\n }\n /**\n * Performs case matching. For internal use only.\n * @nodoc\n */\n ngDoCheck() {\n this._view.enforceState(this.ngSwitch._matchCase(this.ngSwitchCase));\n }\n static ɵfac = function NgSwitchCase_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgSwitchCase)(i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(i0.TemplateRef), i0.ɵɵdirectiveInject(NgSwitch, 9));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgSwitchCase,\n selectors: [[\"\", \"ngSwitchCase\", \"\"]],\n inputs: {\n ngSwitchCase: \"ngSwitchCase\"\n }\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgSwitchCase, [{\n type: Directive,\n args: [{\n selector: '[ngSwitchCase]'\n }]\n }], () => [{\n type: i0.ViewContainerRef\n }, {\n type: i0.TemplateRef\n }, {\n type: NgSwitch,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }]\n }], {\n ngSwitchCase: [{\n type: Input\n }]\n });\n})();\n/**\n * @ngModule CommonModule\n *\n * @description\n *\n * Creates a view that is rendered when no `NgSwitchCase` expressions\n * match the `NgSwitch` expression.\n * This statement should be the final case in an `NgSwitch`.\n *\n * @publicApi\n * @see {@link NgSwitch}\n * @see {@link NgSwitchCase}\n *\n */\nclass NgSwitchDefault {\n constructor(viewContainer, templateRef, ngSwitch) {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !ngSwitch) {\n throwNgSwitchProviderNotFoundError('ngSwitchDefault', 'NgSwitchDefault');\n }\n ngSwitch._addDefault(new SwitchView(viewContainer, templateRef));\n }\n static ɵfac = function NgSwitchDefault_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgSwitchDefault)(i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(i0.TemplateRef), i0.ɵɵdirectiveInject(NgSwitch, 9));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgSwitchDefault,\n selectors: [[\"\", \"ngSwitchDefault\", \"\"]]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgSwitchDefault, [{\n type: Directive,\n args: [{\n selector: '[ngSwitchDefault]'\n }]\n }], () => [{\n type: i0.ViewContainerRef\n }, {\n type: i0.TemplateRef\n }, {\n type: NgSwitch,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }]\n }], null);\n})();\nfunction throwNgSwitchProviderNotFoundError(attrName, directiveName) {\n throw new ɵRuntimeError(2000 /* RuntimeErrorCode.PARENT_NG_SWITCH_NOT_FOUND */, `An element with the \"${attrName}\" attribute ` + `(matching the \"${directiveName}\" directive) must be located inside an element with the \"ngSwitch\" attribute ` + `(matching \"NgSwitch\" directive)`);\n}\n\n/**\n * @ngModule CommonModule\n *\n * @usageNotes\n * ```html\n * <some-element [ngPlural]=\"value\">\n * <ng-template ngPluralCase=\"=0\">there is nothing</ng-template>\n * <ng-template ngPluralCase=\"=1\">there is one</ng-template>\n * <ng-template ngPluralCase=\"few\">there are a few</ng-template>\n * </some-element>\n * ```\n *\n * @description\n *\n * Adds / removes DOM sub-trees based on a numeric value. Tailored for pluralization.\n *\n * Displays DOM sub-trees that match the switch expression value, or failing that, DOM sub-trees\n * that match the switch expression's pluralization category.\n *\n * To use this directive you must provide a container element that sets the `[ngPlural]` attribute\n * to a switch expression. Inner elements with a `[ngPluralCase]` will display based on their\n * expression:\n * - if `[ngPluralCase]` is set to a value starting with `=`, it will only display if the value\n * matches the switch expression exactly,\n * - otherwise, the view will be treated as a \"category match\", and will only display if exact\n * value matches aren't found and the value maps to its category for the defined locale.\n *\n * See http://cldr.unicode.org/index/cldr-spec/plural-rules\n *\n * @publicApi\n */\nclass NgPlural {\n _localization;\n _activeView;\n _caseViews = {};\n constructor(_localization) {\n this._localization = _localization;\n }\n set ngPlural(value) {\n this._updateView(value);\n }\n addCase(value, switchView) {\n this._caseViews[value] = switchView;\n }\n _updateView(switchValue) {\n this._clearViews();\n const cases = Object.keys(this._caseViews);\n const key = getPluralCategory(switchValue, cases, this._localization);\n this._activateView(this._caseViews[key]);\n }\n _clearViews() {\n if (this._activeView) this._activeView.destroy();\n }\n _activateView(view) {\n if (view) {\n this._activeView = view;\n this._activeView.create();\n }\n }\n static ɵfac = function NgPlural_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgPlural)(i0.ɵɵdirectiveInject(NgLocalization));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgPlural,\n selectors: [[\"\", \"ngPlural\", \"\"]],\n inputs: {\n ngPlural: \"ngPlural\"\n }\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgPlural, [{\n type: Directive,\n args: [{\n selector: '[ngPlural]'\n }]\n }], () => [{\n type: NgLocalization\n }], {\n ngPlural: [{\n type: Input\n }]\n });\n})();\n/**\n * @ngModule CommonModule\n *\n * @description\n *\n * Creates a view that will be added/removed from the parent {@link NgPlural} when the\n * given expression matches the plural expression according to CLDR rules.\n *\n * @usageNotes\n * ```html\n * <some-element [ngPlural]=\"value\">\n * <ng-template ngPluralCase=\"=0\">...</ng-template>\n * <ng-template ngPluralCase=\"other\">...</ng-template>\n * </some-element>\n *```\n *\n * See {@link NgPlural} for more details and example.\n *\n * @publicApi\n */\nclass NgPluralCase {\n value;\n constructor(value, template, viewContainer, ngPlural) {\n this.value = value;\n const isANumber = !isNaN(Number(value));\n ngPlural.addCase(isANumber ? `=${value}` : value, new SwitchView(viewContainer, template));\n }\n static ɵfac = function NgPluralCase_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgPluralCase)(i0.ɵɵinjectAttribute('ngPluralCase'), i0.ɵɵdirectiveInject(i0.TemplateRef), i0.ɵɵdirectiveInject(i0.ViewContainerRef), i0.ɵɵdirectiveInject(NgPlural, 1));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgPluralCase,\n selectors: [[\"\", \"ngPluralCase\", \"\"]]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgPluralCase, [{\n type: Directive,\n args: [{\n selector: '[ngPluralCase]'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Attribute,\n args: ['ngPluralCase']\n }]\n }, {\n type: i0.TemplateRef\n }, {\n type: i0.ViewContainerRef\n }, {\n type: NgPlural,\n decorators: [{\n type: Host\n }]\n }], null);\n})();\n\n/**\n * @ngModule CommonModule\n *\n * @usageNotes\n *\n * Set the width of the containing element to a pixel value returned by an expression.\n *\n * ```html\n * <some-element [ngStyle]=\"{'max-width.px': widthExp}\">...</some-element>\n * ```\n *\n * Set a collection of style values using an expression that returns key-value pairs.\n *\n * ```html\n * <some-element [ngStyle]=\"objExp\">...</some-element>\n * ```\n *\n * For more simple use cases you can use the [style bindings](/guide/templates/binding#css-class-and-style-property-bindings) directly.\n * It doesn't require importing a directive.\n *\n * Set the font of the containing element to the result of an expression.\n *\n * ```html\n * <some-element [style]=\"{'font-style': styleExp}\">...</some-element>\n * ```\n *\n * @description\n *\n * An attribute directive that updates styles for the containing HTML element.\n * Sets one or more style properties, specified as colon-separated key-value pairs.\n * The key is a style name, with an optional `.<unit>` suffix\n * (such as 'top.px', 'font-style.em').\n * The value is an expression to be evaluated.\n * The resulting non-null value, expressed in the given unit,\n * is assigned to the given style property.\n * If the result of evaluation is null, the corresponding style is removed.\n *\n * @see [Style bindings](/guide/templates/binding#css-class-and-style-property-bindings)\n *\n * @publicApi\n */\nclass NgStyle {\n _ngEl;\n _differs;\n _renderer;\n _ngStyle = null;\n _differ = null;\n constructor(_ngEl, _differs, _renderer) {\n this._ngEl = _ngEl;\n this._differs = _differs;\n this._renderer = _renderer;\n }\n set ngStyle(values) {\n this._ngStyle = values;\n if (!this._differ && values) {\n this._differ = this._differs.find(values).create();\n }\n }\n ngDoCheck() {\n if (this._differ) {\n const changes = this._differ.diff(this._ngStyle);\n if (changes) {\n this._applyChanges(changes);\n }\n }\n }\n _setStyle(nameAndUnit, value) {\n const [name, unit] = nameAndUnit.split('.');\n const flags = name.indexOf('-') === -1 ? undefined : RendererStyleFlags2.DashCase;\n if (value != null) {\n this._renderer.setStyle(this._ngEl.nativeElement, name, unit ? `${value}${unit}` : value, flags);\n } else {\n this._renderer.removeStyle(this._ngEl.nativeElement, name, flags);\n }\n }\n _applyChanges(changes) {\n changes.forEachRemovedItem(record => this._setStyle(record.key, null));\n changes.forEachAddedItem(record => this._setStyle(record.key, record.currentValue));\n changes.forEachChangedItem(record => this._setStyle(record.key, record.currentValue));\n }\n static ɵfac = function NgStyle_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgStyle)(i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i0.KeyValueDiffers), i0.ɵɵdirectiveInject(i0.Renderer2));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgStyle,\n selectors: [[\"\", \"ngStyle\", \"\"]],\n inputs: {\n ngStyle: \"ngStyle\"\n }\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgStyle, [{\n type: Directive,\n args: [{\n selector: '[ngStyle]'\n }]\n }], () => [{\n type: i0.ElementRef\n }, {\n type: i0.KeyValueDiffers\n }, {\n type: i0.Renderer2\n }], {\n ngStyle: [{\n type: Input,\n args: ['ngStyle']\n }]\n });\n})();\n\n/**\n * @ngModule CommonModule\n *\n * @description\n *\n * Inserts an embedded view from a prepared `TemplateRef`.\n *\n * You can attach a context object to the `EmbeddedViewRef` by setting `[ngTemplateOutletContext]`.\n * `[ngTemplateOutletContext]` should be an object, the object's keys will be available for binding\n * by the local template `let` declarations.\n *\n * @usageNotes\n * ```html\n * <ng-container *ngTemplateOutlet=\"templateRefExp; context: contextExp\"></ng-container>\n * ```\n *\n * Using the key `$implicit` in the context object will set its value as default.\n *\n * ### Example\n *\n * {@example common/ngTemplateOutlet/ts/module.ts region='NgTemplateOutlet'}\n *\n * @publicApi\n */\nclass NgTemplateOutlet {\n _viewContainerRef;\n _viewRef = null;\n /**\n * A context object to attach to the {@link EmbeddedViewRef}. This should be an\n * object, the object's keys will be available for binding by the local template `let`\n * declarations.\n * Using the key `$implicit` in the context object will set its value as default.\n */\n ngTemplateOutletContext = null;\n /**\n * A string defining the template reference and optionally the context object for the template.\n */\n ngTemplateOutlet = null;\n /** Injector to be used within the embedded view. */\n ngTemplateOutletInjector = null;\n constructor(_viewContainerRef) {\n this._viewContainerRef = _viewContainerRef;\n }\n ngOnChanges(changes) {\n if (this._shouldRecreateView(changes)) {\n const viewContainerRef = this._viewContainerRef;\n if (this._viewRef) {\n viewContainerRef.remove(viewContainerRef.indexOf(this._viewRef));\n }\n // If there is no outlet, clear the destroyed view ref.\n if (!this.ngTemplateOutlet) {\n this._viewRef = null;\n return;\n }\n // Create a context forward `Proxy` that will always bind to the user-specified context,\n // without having to destroy and re-create views whenever the context changes.\n const viewContext = this._createContextForwardProxy();\n this._viewRef = viewContainerRef.createEmbeddedView(this.ngTemplateOutlet, viewContext, {\n injector: this.ngTemplateOutletInjector ?? undefined\n });\n }\n }\n /**\n * We need to re-create existing embedded view if either is true:\n * - the outlet changed.\n * - the injector changed.\n */\n _shouldRecreateView(changes) {\n return !!changes['ngTemplateOutlet'] || !!changes['ngTemplateOutletInjector'];\n }\n /**\n * For a given outlet instance, we create a proxy object that delegates\n * to the user-specified context. This allows changing, or swapping out\n * the context object completely without having to destroy/re-create the view.\n */\n _createContextForwardProxy() {\n return new Proxy({}, {\n set: (_target, prop, newValue) => {\n if (!this.ngTemplateOutletContext) {\n return false;\n }\n return Reflect.set(this.ngTemplateOutletContext, prop, newValue);\n },\n get: (_target, prop, receiver) => {\n if (!this.ngTemplateOutletContext) {\n return undefined;\n }\n return Reflect.get(this.ngTemplateOutletContext, prop, receiver);\n }\n });\n }\n static ɵfac = function NgTemplateOutlet_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgTemplateOutlet)(i0.ɵɵdirectiveInject(i0.ViewContainerRef));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgTemplateOutlet,\n selectors: [[\"\", \"ngTemplateOutlet\", \"\"]],\n inputs: {\n ngTemplateOutletContext: \"ngTemplateOutletContext\",\n ngTemplateOutlet: \"ngTemplateOutlet\",\n ngTemplateOutletInjector: \"ngTemplateOutletInjector\"\n },\n features: [i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgTemplateOutlet, [{\n type: Directive,\n args: [{\n selector: '[ngTemplateOutlet]'\n }]\n }], () => [{\n type: i0.ViewContainerRef\n }], {\n ngTemplateOutletContext: [{\n type: Input\n }],\n ngTemplateOutlet: [{\n type: Input\n }],\n ngTemplateOutletInjector: [{\n type: Input\n }]\n });\n})();\n\n/**\n * A collection of Angular directives that are likely to be used in each and every Angular\n * application.\n */\nconst COMMON_DIRECTIVES = [NgClass, NgComponentOutlet, NgForOf, NgIf, NgTemplateOutlet, NgStyle, NgSwitch, NgSwitchCase, NgSwitchDefault, NgPlural, NgPluralCase];\nfunction invalidPipeArgumentError(type, value) {\n return new ɵRuntimeError(2100 /* RuntimeErrorCode.INVALID_PIPE_ARGUMENT */, ngDevMode && `InvalidPipeArgument: '${value}' for pipe '${ɵstringify(type)}'`);\n}\nclass SubscribableStrategy {\n createSubscription(async, updateLatestValue) {\n // Subscription can be side-effectful, and we don't want any signal reads which happen in the\n // side effect of the subscription to be tracked by a component's template when that\n // subscription is triggered via the async pipe. So we wrap the subscription in `untracked` to\n // decouple from the current reactive context.\n //\n // `untracked` also prevents signal _writes_ which happen in the subscription side effect from\n // being treated as signal writes during the template evaluation (which throws errors).\n return untracked(() => async.subscribe({\n next: updateLatestValue,\n error: e => {\n throw e;\n }\n }));\n }\n dispose(subscription) {\n // See the comment in `createSubscription` above on the use of `untracked`.\n untracked(() => subscription.unsubscribe());\n }\n}\nclass PromiseStrategy {\n createSubscription(async, updateLatestValue) {\n return async.then(updateLatestValue, e => {\n throw e;\n });\n }\n dispose(subscription) {}\n}\nconst _promiseStrategy = new PromiseStrategy();\nconst _subscribableStrategy = new SubscribableStrategy();\n/**\n * @ngModule CommonModule\n * @description\n *\n * Unwraps a value from an asynchronous primitive.\n *\n * The `async` pipe subscribes to an `Observable` or `Promise` and returns the latest value it has\n * emitted. When a new value is emitted, the `async` pipe marks the component to be checked for\n * changes. When the component gets destroyed, the `async` pipe unsubscribes automatically to avoid\n * potential memory leaks. When the reference of the expression changes, the `async` pipe\n * automatically unsubscribes from the old `Observable` or `Promise` and subscribes to the new one.\n *\n * @usageNotes\n *\n * ### Examples\n *\n * This example binds a `Promise` to the view. Clicking the `Resolve` button resolves the\n * promise.\n *\n * {@example common/pipes/ts/async_pipe.ts region='AsyncPipePromise'}\n *\n * It's also possible to use `async` with Observables. The example below binds the `time` Observable\n * to the view. The Observable continuously updates the view with the current time.\n *\n * {@example common/pipes/ts/async_pipe.ts region='AsyncPipeObservable'}\n *\n * @publicApi\n */\nclass AsyncPipe {\n _ref;\n _latestValue = null;\n markForCheckOnValueUpdate = true;\n _subscription = null;\n _obj = null;\n _strategy = null;\n constructor(ref) {\n // Assign `ref` into `this._ref` manually instead of declaring `_ref` in the constructor\n // parameter list, as the type of `this._ref` includes `null` unlike the type of `ref`.\n this._ref = ref;\n }\n ngOnDestroy() {\n if (this._subscription) {\n this._dispose();\n }\n // Clear the `ChangeDetectorRef` and its association with the view data, to mitigate\n // potential memory leaks in Observables that could otherwise cause the view data to\n // be retained.\n // https://github.com/angular/angular/issues/17624\n this._ref = null;\n }\n transform(obj) {\n if (!this._obj) {\n if (obj) {\n try {\n // Only call `markForCheck` if the value is updated asynchronously.\n // Synchronous updates _during_ subscription should not wastefully mark for check -\n // this value is already going to be returned from the transform function.\n this.markForCheckOnValueUpdate = false;\n this._subscribe(obj);\n } finally {\n this.markForCheckOnValueUpdate = true;\n }\n }\n return this._latestValue;\n }\n if (obj !== this._obj) {\n this._dispose();\n return this.transform(obj);\n }\n return this._latestValue;\n }\n _subscribe(obj) {\n this._obj = obj;\n this._strategy = this._selectStrategy(obj);\n this._subscription = this._strategy.createSubscription(obj, value => this._updateLatestValue(obj, value));\n }\n _selectStrategy(obj) {\n if (ɵisPromise(obj)) {\n return _promiseStrategy;\n }\n if (ɵisSubscribable(obj)) {\n return _subscribableStrategy;\n }\n throw invalidPipeArgumentError(AsyncPipe, obj);\n }\n _dispose() {\n // Note: `dispose` is only called if a subscription has been initialized before, indicating\n // that `this._strategy` is also available.\n this._strategy.dispose(this._subscription);\n this._latestValue = null;\n this._subscription = null;\n this._obj = null;\n }\n _updateLatestValue(async, value) {\n if (async === this._obj) {\n this._latestValue = value;\n if (this.markForCheckOnValueUpdate) {\n this._ref?.markForCheck();\n }\n }\n }\n static ɵfac = function AsyncPipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || AsyncPipe)(i0.ɵɵdirectiveInject(i0.ChangeDetectorRef, 16));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"async\",\n type: AsyncPipe,\n pure: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(AsyncPipe, [{\n type: Pipe,\n args: [{\n name: 'async',\n pure: false\n }]\n }], () => [{\n type: i0.ChangeDetectorRef\n }], null);\n})();\n\n/**\n * Transforms text to all lower case.\n *\n * @see {@link UpperCasePipe}\n * @see {@link TitleCasePipe}\n * @usageNotes\n *\n * The following example defines a view that allows the user to enter\n * text, and then uses the pipe to convert the input text to all lower case.\n *\n * {@example common/pipes/ts/lowerupper_pipe.ts region='LowerUpperPipe'}\n *\n * @ngModule CommonModule\n * @publicApi\n */\nclass LowerCasePipe {\n transform(value) {\n if (value == null) return null;\n if (typeof value !== 'string') {\n throw invalidPipeArgumentError(LowerCasePipe, value);\n }\n return value.toLowerCase();\n }\n static ɵfac = function LowerCasePipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || LowerCasePipe)();\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"lowercase\",\n type: LowerCasePipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(LowerCasePipe, [{\n type: Pipe,\n args: [{\n name: 'lowercase'\n }]\n }], null, null);\n})();\n//\n// Regex below matches any Unicode word and number compatible with ES5. In ES2018 the same result\n// can be achieved by using /[0-9\\p{L}]\\S*/gu and also known as Unicode Property Escapes\n// (https://2ality.com/2017/07/regexp-unicode-property-escapes.html). Since there is no\n// transpilation of this functionality down to ES5 without external tool, the only solution is\n// to use already transpiled form. Example can be found here -\n// https://mothereff.in/regexpu#input=var+regex+%3D+%2F%5B0-9%5Cp%7BL%7D%5D%5CS*%2Fgu%3B%0A%0A&unicodePropertyEscape=1\n//\nconst unicodeWordMatch = /(?:[0-9A-Za-z\\xAA\\xB5\\xBA\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0560-\\u0588\\u05D0-\\u05EA\\u05EF-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u0860-\\u086A\\u0870-\\u0887\\u0889-\\u088E\\u08A0-\\u08C9\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u09FC\\u0A05-\\u0A0A\\u0A0F\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F\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F5\\u13F8-\\u13FD\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16F1-\\u16F8\\u1700-\\u1711\\u171F-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1878\\u1880-\\u1884\\u1887-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4C\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1C80-\\u1C88\\u1C90-\\u1CBA\\u1CBD-\\u1CBF\\u1CE9-\\u1CEC\\u1CEE-\\u1CF3\\u1CF5\\u1CF6\\u1CFA\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184\\u2C00-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312F\\u3131-\\u318E\\u31A0-\\u31BF\\u31F0-\\u31FF\\u3400-\\u4DBF\\u4E00-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6E5\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA7CA\\uA7D0\\uA7D1\\uA7D3\\uA7D5-\\uA7D9\\uA7F2-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA8FD\\uA8FE\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uA9E0-\\uA9E4\\uA9E6-\\uA9EF\\uA9FA-\\uA9FE\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA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-\\uDCAF\\uDCC4\\uDCC5\\uDCC7\\uDD80-\\uDDAE\\uDDD8-\\uDDDB\\uDE00-\\uDE2F\\uDE44\\uDE80-\\uDEAA\\uDEB8\\uDF00-\\uDF1A\\uDF40-\\uDF46]|\\uD806[\\uDC00-\\uDC2B\\uDCA0-\\uDCDF\\uDCFF-\\uDD06\\uDD09\\uDD0C-\\uDD13\\uDD15\\uDD16\\uDD18-\\uDD2F\\uDD3F\\uDD41\\uDDA0-\\uDDA7\\uDDAA-\\uDDD0\\uDDE1\\uDDE3\\uDE00\\uDE0B-\\uDE32\\uDE3A\\uDE50\\uDE5C-\\uDE89\\uDE9D\\uDEB0-\\uDEF8]|\\uD807[\\uDC00-\\uDC08\\uDC0A-\\uDC2E\\uDC40\\uDC72-\\uDC8F\\uDD00-\\uDD06\\uDD08\\uDD09\\uDD0B-\\uDD30\\uDD46\\uDD60-\\uDD65\\uDD67\\uDD68\\uDD6A-\\uDD89\\uDD98\\uDEE0-\\uDEF2\\uDFB0]|\\uD808[\\uDC00-\\uDF99]|\\uD809[\\uDC80-\\uDD43]|\\uD80B[\\uDF90-\\uDFF0]|[\\uD80C\\uD81C-\\uD820\\uD822\\uD840-\\uD868\\uD86A-\\uD86C\\uD86F-\\uD872\\uD874-\\uD879\\uD880-\\uD883][\\uDC00-\\uDFFF]|\\uD80D[\\uDC00-\\uDC2E]|\\uD811[\\uDC00-\\uDE46]|\\uD81A[\\uDC00-\\uDE38\\uDE40-\\uDE5E\\uDE70-\\uDEBE\\uDED0-\\uDEED\\uDF00-\\uDF2F\\uDF40-\\uDF43\\uDF63-\\uDF77\\uDF7D-\\uDF8F]|\\uD81B[\\uDE40-\\uDE7F\\uDF00-\\uDF4A\\uDF50\\uDF93-\\uDF9F\\uDFE0\\uDFE1\\uDFE3]|\\uD821[\\uDC00-\\uDFF7]|\\uD823[\\uDC00-\\uDCD5\\uDD00-\\uDD08]|\\uD82B[\\uDFF0-\\uDFF3\\uDFF5-\\uDFFB\\uDFFD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\\uDE89\\uDE8B-\\uDE9B\\uDEA1-\\uDEA3\\uDEA5-\\uDEA9\\uDEAB-\\uDEBB]|\\uD869[\\uDC00-\\uDEDF\\uDF00-\\uDFFF]|\\uD86D[\\uDC00-\\uDF38\\uDF40-\\uDFFF]|\\uD86E[\\uDC00-\\uDC1D\\uDC20-\\uDFFF]|\\uD873[\\uDC00-\\uDEA1\\uDEB0-\\uDFFF]|\\uD87A[\\uDC00-\\uDFE0]|\\uD87E[\\uDC00-\\uDE1D]|\\uD884[\\uDC00-\\uDF4A])\\S*/g;\n/**\n * Transforms text to title case.\n * Capitalizes the first letter of each word and transforms the\n * rest of the word to lower case.\n * Words are delimited by any whitespace character, such as a space, tab, or line-feed character.\n *\n * @see {@link LowerCasePipe}\n * @see {@link UpperCasePipe}\n *\n * @usageNotes\n * The following example shows the result of transforming various strings into title case.\n *\n * {@example common/pipes/ts/titlecase_pipe.ts region='TitleCasePipe'}\n *\n * @ngModule CommonModule\n * @publicApi\n */\nclass TitleCasePipe {\n transform(value) {\n if (value == null) return null;\n if (typeof value !== 'string') {\n throw invalidPipeArgumentError(TitleCasePipe, value);\n }\n return value.replace(unicodeWordMatch, txt => txt[0].toUpperCase() + txt.slice(1).toLowerCase());\n }\n static ɵfac = function TitleCasePipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || TitleCasePipe)();\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"titlecase\",\n type: TitleCasePipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TitleCasePipe, [{\n type: Pipe,\n args: [{\n name: 'titlecase'\n }]\n }], null, null);\n})();\n/**\n * Transforms text to all upper case.\n * @see {@link LowerCasePipe}\n * @see {@link TitleCasePipe}\n *\n * @ngModule CommonModule\n * @publicApi\n */\nclass UpperCasePipe {\n transform(value) {\n if (value == null) return null;\n if (typeof value !== 'string') {\n throw invalidPipeArgumentError(UpperCasePipe, value);\n }\n return value.toUpperCase();\n }\n static ɵfac = function UpperCasePipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || UpperCasePipe)();\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"uppercase\",\n type: UpperCasePipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(UpperCasePipe, [{\n type: Pipe,\n args: [{\n name: 'uppercase'\n }]\n }], null, null);\n})();\n\n/**\n * The default date format of Angular date pipe, which corresponds to the following format:\n * `'MMM d,y'` (e.g. `Jun 15, 2015`)\n */\nconst DEFAULT_DATE_FORMAT = 'mediumDate';\n\n/**\n * Optionally-provided default timezone to use for all instances of `DatePipe` (such as `'+0430'`).\n * If the value isn't provided, the `DatePipe` will use the end-user's local system timezone.\n *\n * @deprecated use DATE_PIPE_DEFAULT_OPTIONS token to configure DatePipe\n */\nconst DATE_PIPE_DEFAULT_TIMEZONE = new InjectionToken(ngDevMode ? 'DATE_PIPE_DEFAULT_TIMEZONE' : '');\n/**\n * DI token that allows to provide default configuration for the `DatePipe` instances in an\n * application. The value is an object which can include the following fields:\n * - `dateFormat`: configures the default date format. If not provided, the `DatePipe`\n * will use the 'mediumDate' as a value.\n * - `timezone`: configures the default timezone. If not provided, the `DatePipe` will\n * use the end-user's local system timezone.\n *\n * @see {@link DatePipeConfig}\n *\n * @usageNotes\n *\n * Various date pipe default values can be overwritten by providing this token with\n * the value that has this interface.\n *\n * For example:\n *\n * Override the default date format by providing a value using the token:\n * ```ts\n * providers: [\n * {provide: DATE_PIPE_DEFAULT_OPTIONS, useValue: {dateFormat: 'shortDate'}}\n * ]\n * ```\n *\n * Override the default timezone by providing a value using the token:\n * ```ts\n * providers: [\n * {provide: DATE_PIPE_DEFAULT_OPTIONS, useValue: {timezone: '-1200'}}\n * ]\n * ```\n */\nconst DATE_PIPE_DEFAULT_OPTIONS = new InjectionToken(ngDevMode ? 'DATE_PIPE_DEFAULT_OPTIONS' : '');\n/**\n * @ngModule CommonModule\n * @description\n *\n * Formats a date value according to locale rules.\n *\n * `DatePipe` is executed only when it detects a pure change to the input value.\n * A pure change is either a change to a primitive input value\n * (such as `String`, `Number`, `Boolean`, or `Symbol`),\n * or a changed object reference (such as `Date`, `Array`, `Function`, or `Object`).\n *\n * Note that mutating a `Date` object does not cause the pipe to be rendered again.\n * To ensure that the pipe is executed, you must create a new `Date` object.\n *\n * Only the `en-US` locale data comes with Angular. To localize dates\n * in another language, you must import the corresponding locale data.\n * See the [I18n guide](guide/i18n/format-data-locale) for more information.\n *\n * The time zone of the formatted value can be specified either by passing it in as the second\n * parameter of the pipe, or by setting the default through the `DATE_PIPE_DEFAULT_OPTIONS`\n * injection token. The value that is passed in as the second parameter takes precedence over\n * the one defined using the injection token.\n *\n * @see {@link formatDate}\n *\n *\n * @usageNotes\n *\n * The result of this pipe is not reevaluated when the input is mutated. To avoid the need to\n * reformat the date on every change-detection cycle, treat the date as an immutable object\n * and change the reference when the pipe needs to run again.\n *\n * ### Pre-defined format options\n *\n * | Option | Equivalent to | Examples (given in `en-US` locale) |\n * |---------------|-------------------------------------|-------------------------------------------------|\n * | `'short'` | `'M/d/yy, h:mm a'` | `6/15/15, 9:03 AM` |\n * | `'medium'` | `'MMM d, y, h:mm:ss a'` | `Jun 15, 2015, 9:03:01 AM` |\n * | `'long'` | `'MMMM d, y, h:mm:ss a z'` | `June 15, 2015 at 9:03:01 AM GMT+1` |\n * | `'full'` | `'EEEE, MMMM d, y, h:mm:ss a zzzz'` | `Monday, June 15, 2015 at 9:03:01 AM GMT+01:00` |\n * | `'shortDate'` | `'M/d/yy'` | `6/15/15` |\n * | `'mediumDate'`| `'MMM d, y'` | `Jun 15, 2015` |\n * | `'longDate'` | `'MMMM d, y'` | `June 15, 2015` |\n * | `'fullDate'` | `'EEEE, MMMM d, y'` | `Monday, June 15, 2015` |\n * | `'shortTime'` | `'h:mm a'` | `9:03 AM` |\n * | `'mediumTime'`| `'h:mm:ss a'` | `9:03:01 AM` |\n * | `'longTime'` | `'h:mm:ss a z'` | `9:03:01 AM GMT+1` |\n * | `'fullTime'` | `'h:mm:ss a zzzz'` | `9:03:01 AM GMT+01:00` |\n *\n * ### Custom format options\n *\n * You can construct a format string using symbols to specify the components\n * of a date-time value, as described in the following table.\n * Format details depend on the locale.\n * Fields marked with (*) are only available in the extra data set for the given locale.\n *\n * | Field type | Format | Description | Example Value |\n * |-------------------------|-------------|---------------------------------------------------------------|------------------------------------------------------------|\n * | Era | G, GG & GGG | Abbreviated | AD |\n * | | GGGG | Wide | Anno Domini |\n * | | GGGGG | Narrow | A |\n * | Year | y | Numeric: minimum digits | 2, 20, 201, 2017, 20173 |\n * | | yy | Numeric: 2 digits + zero padded | 02, 20, 01, 17, 73 |\n * | | yyy | Numeric: 3 digits + zero padded | 002, 020, 201, 2017, 20173 |\n * | | yyyy | Numeric: 4 digits or more + zero padded | 0002, 0020, 0201, 2017, 20173 |\n * | ISO Week-numbering year | Y | Numeric: minimum digits | 2, 20, 201, 2017, 20173 |\n * | | YY | Numeric: 2 digits + zero padded | 02, 20, 01, 17, 73 |\n * | | YYY | Numeric: 3 digits + zero padded | 002, 020, 201, 2017, 20173 |\n * | | YYYY | Numeric: 4 digits or more + zero padded | 0002, 0020, 0201, 2017, 20173 |\n * | Month | M | Numeric: 1 digit | 9, 12 |\n * | | MM | Numeric: 2 digits + zero padded | 09, 12 |\n * | | MMM | Abbreviated | Sep |\n * | | MMMM | Wide | September |\n * | | MMMMM | Narrow | S |\n * | Month standalone | L | Numeric: 1 digit | 9, 12 |\n * | | LL | Numeric: 2 digits + zero padded | 09, 12 |\n * | | LLL | Abbreviated | Sep |\n * | | LLLL | Wide | September |\n * | | LLLLL | Narrow | S |\n * | ISO Week of year | w | Numeric: minimum digits | 1... 53 |\n * | | ww | Numeric: 2 digits + zero padded | 01... 53 |\n * | Week of month | W | Numeric: 1 digit | 1... 5 |\n * | Day of month | d | Numeric: minimum digits | 1 |\n * | | dd | Numeric: 2 digits + zero padded | 01 |\n * | Week day | E, EE & EEE | Abbreviated | Tue |\n * | | EEEE | Wide | Tuesday |\n * | | EEEEE | Narrow | T |\n * | | EEEEEE | Short | Tu |\n * | Week day standalone | c, cc | Numeric: 1 digit | 2 |\n * | | ccc | Abbreviated | Tue |\n * | | cccc | Wide | Tuesday |\n * | | ccccc | Narrow | T |\n * | | cccccc | Short | Tu |\n * | Period | a, aa & aaa | Abbreviated | am/pm or AM/PM |\n * | | aaaa | Wide (fallback to `a` when missing) | ante meridiem/post meridiem |\n * | | aaaaa | Narrow | a/p |\n * | Period* | B, BB & BBB | Abbreviated | mid. |\n * | | BBBB | Wide | am, pm, midnight, noon, morning, afternoon, evening, night |\n * | | BBBBB | Narrow | md |\n * | Period standalone* | b, bb & bbb | Abbreviated | mid. |\n * | | bbbb | Wide | am, pm, midnight, noon, morning, afternoon, evening, night |\n * | | bbbbb | Narrow | md |\n * | Hour 1-12 | h | Numeric: minimum digits | 1, 12 |\n * | | hh | Numeric: 2 digits + zero padded | 01, 12 |\n * | Hour 0-23 | H | Numeric: minimum digits | 0, 23 |\n * | | HH | Numeric: 2 digits + zero padded | 00, 23 |\n * | Minute | m | Numeric: minimum digits | 8, 59 |\n * | | mm | Numeric: 2 digits + zero padded | 08, 59 |\n * | Second | s | Numeric: minimum digits | 0... 59 |\n * | | ss | Numeric: 2 digits + zero padded | 00... 59 |\n * | Fractional seconds | S | Numeric: 1 digit | 0... 9 |\n * | | SS | Numeric: 2 digits + zero padded | 00... 99 |\n * | | SSS | Numeric: 3 digits + zero padded (= milliseconds) | 000... 999 |\n * | Zone | z, zz & zzz | Short specific non location format (fallback to O) | GMT-8 |\n * | | zzzz | Long specific non location format (fallback to OOOO) | GMT-08:00 |\n * | | Z, ZZ & ZZZ | ISO8601 basic format | -0800 |\n * | | ZZZZ | Long localized GMT format | GMT-8:00 |\n * | | ZZZZZ | ISO8601 extended format + Z indicator for offset 0 (= XXXXX) | -08:00 |\n * | | O, OO & OOO | Short localized GMT format | GMT-8 |\n * | | OOOO | Long localized GMT format | GMT-08:00 |\n *\n *\n * ### Format examples\n *\n * These examples transform a date into various formats,\n * assuming that `dateObj` is a JavaScript `Date` object for\n * year: 2015, month: 6, day: 15, hour: 21, minute: 43, second: 11,\n * given in the local time for the `en-US` locale.\n *\n * ```\n * {{ dateObj | date }} // output is 'Jun 15, 2015'\n * {{ dateObj | date:'medium' }} // output is 'Jun 15, 2015, 9:43:11 PM'\n * {{ dateObj | date:'shortTime' }} // output is '9:43 PM'\n * {{ dateObj | date:'mm:ss' }} // output is '43:11'\n * {{ dateObj | date:\"MMM dd, yyyy 'at' hh:mm a\" }} // output is 'Jun 15, 2015 at 09:43 PM'\n * ```\n *\n * ### Usage example\n *\n * The following component uses a date pipe to display the current date in different formats.\n *\n * ```angular-ts\n * @Component({\n * selector: 'date-pipe',\n * template: `<div>\n * <p>Today is {{today | date}}</p>\n * <p>Or if you prefer, {{today | date:'fullDate'}}</p>\n * <p>The time is {{today | date:'h:mm a z'}}</p>\n * </div>`\n * })\n * // Get the current date and time as a date-time value.\n * export class DatePipeComponent {\n * today: number = Date.now();\n * }\n * ```\n *\n * @publicApi\n */\nclass DatePipe {\n locale;\n defaultTimezone;\n defaultOptions;\n constructor(locale, defaultTimezone, defaultOptions) {\n this.locale = locale;\n this.defaultTimezone = defaultTimezone;\n this.defaultOptions = defaultOptions;\n }\n transform(value, format, timezone, locale) {\n if (value == null || value === '' || value !== value) return null;\n try {\n const _format = format ?? this.defaultOptions?.dateFormat ?? DEFAULT_DATE_FORMAT;\n const _timezone = timezone ?? this.defaultOptions?.timezone ?? this.defaultTimezone ?? undefined;\n return formatDate(value, _format, locale || this.locale, _timezone);\n } catch (error) {\n throw invalidPipeArgumentError(DatePipe, error.message);\n }\n }\n static ɵfac = function DatePipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DatePipe)(i0.ɵɵdirectiveInject(LOCALE_ID, 16), i0.ɵɵdirectiveInject(DATE_PIPE_DEFAULT_TIMEZONE, 24), i0.ɵɵdirectiveInject(DATE_PIPE_DEFAULT_OPTIONS, 24));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"date\",\n type: DatePipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DatePipe, [{\n type: Pipe,\n args: [{\n name: 'date'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [LOCALE_ID]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DATE_PIPE_DEFAULT_TIMEZONE]\n }, {\n type: Optional\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DATE_PIPE_DEFAULT_OPTIONS]\n }, {\n type: Optional\n }]\n }], null);\n})();\nconst _INTERPOLATION_REGEXP = /#/g;\n/**\n * @ngModule CommonModule\n * @description\n *\n * Maps a value to a string that pluralizes the value according to locale rules.\n *\n * @usageNotes\n *\n * ### Example\n *\n * {@example common/pipes/ts/i18n_pipe.ts region='I18nPluralPipeComponent'}\n *\n * @publicApi\n */\nclass I18nPluralPipe {\n _localization;\n constructor(_localization) {\n this._localization = _localization;\n }\n /**\n * @param value the number to be formatted\n * @param pluralMap an object that mimics the ICU format, see\n * https://unicode-org.github.io/icu/userguide/format_parse/messages/.\n * @param locale a `string` defining the locale to use (uses the current {@link LOCALE_ID} by\n * default).\n */\n transform(value, pluralMap, locale) {\n if (value == null) return '';\n if (typeof pluralMap !== 'object' || pluralMap === null) {\n throw invalidPipeArgumentError(I18nPluralPipe, pluralMap);\n }\n const key = getPluralCategory(value, Object.keys(pluralMap), this._localization, locale);\n return pluralMap[key].replace(_INTERPOLATION_REGEXP, value.toString());\n }\n static ɵfac = function I18nPluralPipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || I18nPluralPipe)(i0.ɵɵdirectiveInject(NgLocalization, 16));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"i18nPlural\",\n type: I18nPluralPipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(I18nPluralPipe, [{\n type: Pipe,\n args: [{\n name: 'i18nPlural'\n }]\n }], () => [{\n type: NgLocalization\n }], null);\n})();\n\n/**\n * @ngModule CommonModule\n * @description\n *\n * Generic selector that displays the string that matches the current value.\n *\n * If none of the keys of the `mapping` match the `value`, then the content\n * of the `other` key is returned when present, otherwise an empty string is returned.\n *\n * @usageNotes\n *\n * ### Example\n *\n * {@example common/pipes/ts/i18n_pipe.ts region='I18nSelectPipeComponent'}\n *\n * @publicApi\n */\nclass I18nSelectPipe {\n /**\n * @param value a string to be internationalized.\n * @param mapping an object that indicates the text that should be displayed\n * for different values of the provided `value`.\n */\n transform(value, mapping) {\n if (value == null) return '';\n if (typeof mapping !== 'object' || typeof value !== 'string') {\n throw invalidPipeArgumentError(I18nSelectPipe, mapping);\n }\n if (mapping.hasOwnProperty(value)) {\n return mapping[value];\n }\n if (mapping.hasOwnProperty('other')) {\n return mapping['other'];\n }\n return '';\n }\n static ɵfac = function I18nSelectPipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || I18nSelectPipe)();\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"i18nSelect\",\n type: I18nSelectPipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(I18nSelectPipe, [{\n type: Pipe,\n args: [{\n name: 'i18nSelect'\n }]\n }], null, null);\n})();\n\n/**\n * @ngModule CommonModule\n * @description\n *\n * Converts a value into its JSON-format representation. Useful for debugging.\n *\n * @usageNotes\n *\n * The following component uses a JSON pipe to convert an object\n * to JSON format, and displays the string in both formats for comparison.\n *\n * {@example common/pipes/ts/json_pipe.ts region='JsonPipe'}\n *\n * @publicApi\n */\nclass JsonPipe {\n /**\n * @param value A value of any type to convert into a JSON-format string.\n */\n transform(value) {\n return JSON.stringify(value, null, 2);\n }\n static ɵfac = function JsonPipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || JsonPipe)();\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"json\",\n type: JsonPipe,\n pure: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(JsonPipe, [{\n type: Pipe,\n args: [{\n name: 'json',\n pure: false\n }]\n }], null, null);\n})();\nfunction makeKeyValuePair(key, value) {\n return {\n key: key,\n value: value\n };\n}\n/**\n * @ngModule CommonModule\n * @description\n *\n * Transforms Object or Map into an array of key value pairs.\n *\n * The output array will be ordered by keys.\n * By default the comparator will be by Unicode point value.\n * You can optionally pass a compareFn if your keys are complex types.\n * Passing `null` as the compareFn will use natural ordering of the input.\n *\n * @usageNotes\n * ### Examples\n *\n * This examples show how an Object or a Map can be iterated by ngFor with the use of this\n * keyvalue pipe.\n *\n * {@example common/pipes/ts/keyvalue_pipe.ts region='KeyValuePipe'}\n *\n * @publicApi\n */\nclass KeyValuePipe {\n differs;\n constructor(differs) {\n this.differs = differs;\n }\n differ;\n keyValues = [];\n compareFn = defaultComparator;\n transform(input, compareFn = defaultComparator) {\n if (!input || !(input instanceof Map) && typeof input !== 'object') {\n return null;\n }\n // make a differ for whatever type we've been passed in\n this.differ ??= this.differs.find(input).create();\n const differChanges = this.differ.diff(input);\n const compareFnChanged = compareFn !== this.compareFn;\n if (differChanges) {\n this.keyValues = [];\n differChanges.forEachItem(r => {\n this.keyValues.push(makeKeyValuePair(r.key, r.currentValue));\n });\n }\n if (differChanges || compareFnChanged) {\n if (compareFn) {\n this.keyValues.sort(compareFn);\n }\n this.compareFn = compareFn;\n }\n return this.keyValues;\n }\n static ɵfac = function KeyValuePipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || KeyValuePipe)(i0.ɵɵdirectiveInject(i0.KeyValueDiffers, 16));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"keyvalue\",\n type: KeyValuePipe,\n pure: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(KeyValuePipe, [{\n type: Pipe,\n args: [{\n name: 'keyvalue',\n pure: false\n }]\n }], () => [{\n type: i0.KeyValueDiffers\n }], null);\n})();\nfunction defaultComparator(keyValueA, keyValueB) {\n const a = keyValueA.key;\n const b = keyValueB.key;\n // If both keys are the same, return 0 (no sorting needed).\n if (a === b) return 0;\n // If one of the keys is `null` or `undefined`, place it at the end of the sort.\n if (a == null) return 1; // `a` comes after `b`.\n if (b == null) return -1; // `b` comes after `a`.\n // If both keys are strings, compare them lexicographically.\n if (typeof a == 'string' && typeof b == 'string') {\n return a < b ? -1 : 1;\n }\n // If both keys are numbers, sort them numerically.\n if (typeof a == 'number' && typeof b == 'number') {\n return a - b;\n }\n // If both keys are booleans, sort `false` before `true`.\n if (typeof a == 'boolean' && typeof b == 'boolean') {\n return a < b ? -1 : 1;\n }\n // Fallback case: if keys are of different types, compare their string representations.\n const aString = String(a);\n const bString = String(b);\n // Compare the string representations lexicographically.\n return aString == bString ? 0 : aString < bString ? -1 : 1;\n}\n\n/**\n * @ngModule CommonModule\n * @description\n *\n * Formats a value according to digit options and locale rules.\n * Locale determines group sizing and separator,\n * decimal point character, and other locale-specific configurations.\n *\n * @see {@link formatNumber}\n *\n * @usageNotes\n *\n * ### digitsInfo\n *\n * The value's decimal representation is specified by the `digitsInfo`\n * parameter, written in the following format:<br>\n *\n * ```\n * {minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}\n * ```\n *\n * - `minIntegerDigits`:\n * The minimum number of integer digits before the decimal point.\n * Default is 1.\n *\n * - `minFractionDigits`:\n * The minimum number of digits after the decimal point.\n * Default is 0.\n *\n * - `maxFractionDigits`:\n * The maximum number of digits after the decimal point.\n * Default is 3.\n *\n * If the formatted value is truncated it will be rounded using the \"to-nearest\" method:\n *\n * ```\n * {{3.6 | number: '1.0-0'}}\n * <!--will output '4'-->\n *\n * {{-3.6 | number:'1.0-0'}}\n * <!--will output '-4'-->\n * ```\n *\n * ### locale\n *\n * `locale` will format a value according to locale rules.\n * Locale determines group sizing and separator,\n * decimal point character, and other locale-specific configurations.\n *\n * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default.\n *\n * See [Setting your app locale](guide/i18n/locale-id).\n *\n * ### Example\n *\n * The following code shows how the pipe transforms values\n * according to various format specifications,\n * where the caller's default locale is `en-US`.\n *\n * {@example common/pipes/ts/number_pipe.ts region='NumberPipe'}\n *\n * @publicApi\n */\nclass DecimalPipe {\n _locale;\n constructor(_locale) {\n this._locale = _locale;\n }\n transform(value, digitsInfo, locale) {\n if (!isValue(value)) return null;\n locale ||= this._locale;\n try {\n const num = strToNumber(value);\n return formatNumber(num, locale, digitsInfo);\n } catch (error) {\n throw invalidPipeArgumentError(DecimalPipe, error.message);\n }\n }\n static ɵfac = function DecimalPipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DecimalPipe)(i0.ɵɵdirectiveInject(LOCALE_ID, 16));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"number\",\n type: DecimalPipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DecimalPipe, [{\n type: Pipe,\n args: [{\n name: 'number'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [LOCALE_ID]\n }]\n }], null);\n})();\n/**\n * @ngModule CommonModule\n * @description\n *\n * Transforms a number to a percentage\n * string, formatted according to locale rules that determine group sizing and\n * separator, decimal-point character, and other locale-specific\n * configurations.\n *\n * @see {@link formatPercent}\n *\n * @usageNotes\n * The following code shows how the pipe transforms numbers\n * into text strings, according to various format specifications,\n * where the caller's default locale is `en-US`.\n *\n * {@example common/pipes/ts/percent_pipe.ts region='PercentPipe'}\n *\n * @publicApi\n */\nclass PercentPipe {\n _locale;\n constructor(_locale) {\n this._locale = _locale;\n }\n /**\n *\n * @param value The number to be formatted as a percentage.\n * @param digitsInfo Decimal representation options, specified by a string\n * in the following format:<br>\n * <code>{minIntegerDigits}.{minFractionDigits}-{maxFractionDigits}</code>.\n * - `minIntegerDigits`: The minimum number of integer digits before the decimal point.\n * Default is `1`.\n * - `minFractionDigits`: The minimum number of digits after the decimal point.\n * Default is `0`.\n * - `maxFractionDigits`: The maximum number of digits after the decimal point.\n * Default is `0`.\n * @param locale A locale code for the locale format rules to use.\n * When not supplied, uses the value of `LOCALE_ID`, which is `en-US` by default.\n * See [Setting your app locale](guide/i18n/locale-id).\n */\n transform(value, digitsInfo, locale) {\n if (!isValue(value)) return null;\n locale ||= this._locale;\n try {\n const num = strToNumber(value);\n return formatPercent(num, locale, digitsInfo);\n } catch (error) {\n throw invalidPipeArgumentError(PercentPipe, error.message);\n }\n }\n static ɵfac = function PercentPipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PercentPipe)(i0.ɵɵdirectiveInject(LOCALE_ID, 16));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"percent\",\n type: PercentPipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PercentPipe, [{\n type: Pipe,\n args: [{\n name: 'percent'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [LOCALE_ID]\n }]\n }], null);\n})();\n/**\n * @ngModule CommonModule\n * @description\n *\n * Transforms a number to a currency string, formatted according to locale rules\n * that determine group sizing and separator, decimal-point character,\n * and other locale-specific configurations.\n *\n *\n * @see {@link getCurrencySymbol}\n * @see {@link formatCurrency}\n *\n * @usageNotes\n * The following code shows how the pipe transforms numbers\n * into text strings, according to various format specifications,\n * where the caller's default locale is `en-US`.\n *\n * {@example common/pipes/ts/currency_pipe.ts region='CurrencyPipe'}\n *\n * @publicApi\n */\nclass CurrencyPipe {\n _locale;\n _defaultCurrencyCode;\n constructor(_locale, _defaultCurrencyCode = 'USD') {\n this._locale = _locale;\n this._defaultCurrencyCode = _defaultCurrencyCode;\n }\n transform(value, currencyCode = this._defaultCurrencyCode, display = 'symbol', digitsInfo, locale) {\n if (!isValue(value)) return null;\n locale ||= this._locale;\n if (typeof display === 'boolean') {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && console && console.warn) {\n console.warn(`Warning: the currency pipe has been changed in Angular v5. The symbolDisplay option (third parameter) is now a string instead of a boolean. The accepted values are \"code\", \"symbol\" or \"symbol-narrow\".`);\n }\n display = display ? 'symbol' : 'code';\n }\n let currency = currencyCode || this._defaultCurrencyCode;\n if (display !== 'code') {\n if (display === 'symbol' || display === 'symbol-narrow') {\n currency = getCurrencySymbol(currency, display === 'symbol' ? 'wide' : 'narrow', locale);\n } else {\n currency = display;\n }\n }\n try {\n const num = strToNumber(value);\n return formatCurrency(num, locale, currency, currencyCode, digitsInfo);\n } catch (error) {\n throw invalidPipeArgumentError(CurrencyPipe, error.message);\n }\n }\n static ɵfac = function CurrencyPipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || CurrencyPipe)(i0.ɵɵdirectiveInject(LOCALE_ID, 16), i0.ɵɵdirectiveInject(DEFAULT_CURRENCY_CODE, 16));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"currency\",\n type: CurrencyPipe,\n pure: true\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(CurrencyPipe, [{\n type: Pipe,\n args: [{\n name: 'currency'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [LOCALE_ID]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DEFAULT_CURRENCY_CODE]\n }]\n }], null);\n})();\nfunction isValue(value) {\n return !(value == null || value === '' || value !== value);\n}\n/**\n * Transforms a string into a number (if needed).\n */\nfunction strToNumber(value) {\n // Convert strings to numbers\n if (typeof value === 'string' && !isNaN(Number(value) - parseFloat(value))) {\n return Number(value);\n }\n if (typeof value !== 'number') {\n throw new Error(`${value} is not a number`);\n }\n return value;\n}\n\n/**\n * @ngModule CommonModule\n * @description\n *\n * Creates a new `Array` or `String` containing a subset (slice) of the elements.\n *\n * @usageNotes\n *\n * All behavior is based on the expected behavior of the JavaScript API `Array.prototype.slice()`\n * and `String.prototype.slice()`.\n *\n * When operating on an `Array`, the returned `Array` is always a copy even when all\n * the elements are being returned.\n *\n * When operating on a blank value, the pipe returns the blank value.\n *\n * ### List Example\n *\n * This `ngFor` example:\n *\n * {@example common/pipes/ts/slice_pipe.ts region='SlicePipe_list'}\n *\n * produces the following:\n *\n * ```html\n * <li>b</li>\n * <li>c</li>\n * ```\n *\n * ### String Examples\n *\n * {@example common/pipes/ts/slice_pipe.ts region='SlicePipe_string'}\n *\n * @publicApi\n */\nclass SlicePipe {\n transform(value, start, end) {\n if (value == null) return null;\n const supports = typeof value === 'string' || Array.isArray(value);\n if (!supports) {\n throw invalidPipeArgumentError(SlicePipe, value);\n }\n return value.slice(start, end);\n }\n static ɵfac = function SlicePipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || SlicePipe)();\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"slice\",\n type: SlicePipe,\n pure: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(SlicePipe, [{\n type: Pipe,\n args: [{\n name: 'slice',\n pure: false\n }]\n }], null, null);\n})();\n\n/**\n * @module\n * @description\n * This module provides a set of common Pipes.\n */\n/**\n * A collection of Angular pipes that are likely to be used in each and every application.\n */\nconst COMMON_PIPES = [AsyncPipe, UpperCasePipe, LowerCasePipe, JsonPipe, SlicePipe, DecimalPipe, PercentPipe, TitleCasePipe, CurrencyPipe, DatePipe, I18nPluralPipe, I18nSelectPipe, KeyValuePipe];\n\n// Note: This does not contain the location providers,\n// as they need some platform specific implementations to work.\n/**\n * Exports all the basic Angular directives and pipes,\n * such as `NgIf`, `NgForOf`, `DecimalPipe`, and so on.\n * Re-exported by `BrowserModule`, which is included automatically in the root\n * `AppModule` when you create a new app with the CLI `new` command.\n *\n * @publicApi\n */\nclass CommonModule {\n static ɵfac = function CommonModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || CommonModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: CommonModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({});\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(CommonModule, [{\n type: NgModule,\n args: [{\n imports: [COMMON_DIRECTIVES, COMMON_PIPES],\n exports: [COMMON_DIRECTIVES, COMMON_PIPES]\n }]\n }], null, null);\n})();\nconst PLATFORM_BROWSER_ID = 'browser';\nconst PLATFORM_SERVER_ID = 'server';\n/**\n * Returns whether a platform id represents a browser platform.\n * @publicApi\n */\nfunction isPlatformBrowser(platformId) {\n return platformId === PLATFORM_BROWSER_ID;\n}\n/**\n * Returns whether a platform id represents a server platform.\n * @publicApi\n */\nfunction isPlatformServer(platformId) {\n return platformId === PLATFORM_SERVER_ID;\n}\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the common package.\n */\n/**\n * @publicApi\n */\nconst VERSION = new Version('19.2.1');\n\n/**\n * Defines a scroll position manager. Implemented by `BrowserViewportScroller`.\n *\n * @publicApi\n */\nclass ViewportScroller {\n // De-sugared tree-shakable injection\n // See #23917\n /** @nocollapse */\n static ɵprov = /** @pureOrBreakMyCode */ /* @__PURE__ */ɵɵdefineInjectable({\n token: ViewportScroller,\n providedIn: 'root',\n factory: () => typeof ngServerMode !== 'undefined' && ngServerMode ? new NullViewportScroller() : new BrowserViewportScroller(inject(DOCUMENT), window)\n });\n}\n/**\n * Manages the scroll position for a browser window.\n */\nclass BrowserViewportScroller {\n document;\n window;\n offset = () => [0, 0];\n constructor(document, window) {\n this.document = document;\n this.window = window;\n }\n /**\n * Configures the top offset used when scrolling to an anchor.\n * @param offset A position in screen coordinates (a tuple with x and y values)\n * or a function that returns the top offset position.\n *\n */\n setOffset(offset) {\n if (Array.isArray(offset)) {\n this.offset = () => offset;\n } else {\n this.offset = offset;\n }\n }\n /**\n * Retrieves the current scroll position.\n * @returns The position in screen coordinates.\n */\n getScrollPosition() {\n return [this.window.scrollX, this.window.scrollY];\n }\n /**\n * Sets the scroll position.\n * @param position The new position in screen coordinates.\n */\n scrollToPosition(position) {\n this.window.scrollTo(position[0], position[1]);\n }\n /**\n * Scrolls to an element and attempts to focus the element.\n *\n * Note that the function name here is misleading in that the target string may be an ID for a\n * non-anchor element.\n *\n * @param target The ID of an element or name of the anchor.\n *\n * @see https://html.spec.whatwg.org/#the-indicated-part-of-the-document\n * @see https://html.spec.whatwg.org/#scroll-to-fragid\n */\n scrollToAnchor(target) {\n const elSelected = findAnchorFromDocument(this.document, target);\n if (elSelected) {\n this.scrollToElement(elSelected);\n // After scrolling to the element, the spec dictates that we follow the focus steps for the\n // target. Rather than following the robust steps, simply attempt focus.\n //\n // @see https://html.spec.whatwg.org/#get-the-focusable-area\n // @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLOrForeignElement/focus\n // @see https://html.spec.whatwg.org/#focusable-area\n elSelected.focus();\n }\n }\n /**\n * Disables automatic scroll restoration provided by the browser.\n */\n setHistoryScrollRestoration(scrollRestoration) {\n this.window.history.scrollRestoration = scrollRestoration;\n }\n /**\n * Scrolls to an element using the native offset and the specified offset set on this scroller.\n *\n * The offset can be used when we know that there is a floating header and scrolling naively to an\n * element (ex: `scrollIntoView`) leaves the element hidden behind the floating header.\n */\n scrollToElement(el) {\n const rect = el.getBoundingClientRect();\n const left = rect.left + this.window.pageXOffset;\n const top = rect.top + this.window.pageYOffset;\n const offset = this.offset();\n this.window.scrollTo(left - offset[0], top - offset[1]);\n }\n}\nfunction findAnchorFromDocument(document, target) {\n const documentResult = document.getElementById(target) || document.getElementsByName(target)[0];\n if (documentResult) {\n return documentResult;\n }\n // `getElementById` and `getElementsByName` won't pierce through the shadow DOM so we\n // have to traverse the DOM manually and do the lookup through the shadow roots.\n if (typeof document.createTreeWalker === 'function' && document.body && typeof document.body.attachShadow === 'function') {\n const treeWalker = document.createTreeWalker(document.body, NodeFilter.SHOW_ELEMENT);\n let currentNode = treeWalker.currentNode;\n while (currentNode) {\n const shadowRoot = currentNode.shadowRoot;\n if (shadowRoot) {\n // Note that `ShadowRoot` doesn't support `getElementsByName`\n // so we have to fall back to `querySelector`.\n const result = shadowRoot.getElementById(target) || shadowRoot.querySelector(`[name=\"${target}\"]`);\n if (result) {\n return result;\n }\n }\n currentNode = treeWalker.nextNode();\n }\n }\n return null;\n}\n/**\n * Provides an empty implementation of the viewport scroller.\n */\nclass NullViewportScroller {\n /**\n * Empty implementation\n */\n setOffset(offset) {}\n /**\n * Empty implementation\n */\n getScrollPosition() {\n return [0, 0];\n }\n /**\n * Empty implementation\n */\n scrollToPosition(position) {}\n /**\n * Empty implementation\n */\n scrollToAnchor(anchor) {}\n /**\n * Empty implementation\n */\n setHistoryScrollRestoration(scrollRestoration) {}\n}\n\n/**\n * A wrapper around the `XMLHttpRequest` constructor.\n *\n * @publicApi\n */\nclass XhrFactory {}\n\n/**\n * Value (out of 100) of the requested quality for placeholder images.\n */\nconst PLACEHOLDER_QUALITY = '20';\n\n// Converts a string that represents a URL into a URL class instance.\nfunction getUrl(src, win) {\n // Don't use a base URL is the URL is absolute.\n return isAbsoluteUrl(src) ? new URL(src) : new URL(src, win.location.href);\n}\n// Checks whether a URL is absolute (i.e. starts with `http://` or `https://`).\nfunction isAbsoluteUrl(src) {\n return /^https?:\\/\\//.test(src);\n}\n// Given a URL, extract the hostname part.\n// If a URL is a relative one - the URL is returned as is.\nfunction extractHostname(url) {\n return isAbsoluteUrl(url) ? new URL(url).hostname : url;\n}\nfunction isValidPath(path) {\n const isString = typeof path === 'string';\n if (!isString || path.trim() === '') {\n return false;\n }\n // Calling new URL() will throw if the path string is malformed\n try {\n const url = new URL(path);\n return true;\n } catch {\n return false;\n }\n}\nfunction normalizePath(path) {\n return path.endsWith('/') ? path.slice(0, -1) : path;\n}\nfunction normalizeSrc(src) {\n return src.startsWith('/') ? src.slice(1) : src;\n}\n\n/**\n * Noop image loader that does no transformation to the original src and just returns it as is.\n * This loader is used as a default one if more specific logic is not provided in an app config.\n *\n * @see {@link ImageLoader}\n * @see {@link NgOptimizedImage}\n */\nconst noopImageLoader = config => config.src;\n/**\n * Injection token that configures the image loader function.\n *\n * @see {@link ImageLoader}\n * @see {@link NgOptimizedImage}\n * @publicApi\n */\nconst IMAGE_LOADER = new InjectionToken(ngDevMode ? 'ImageLoader' : '', {\n providedIn: 'root',\n factory: () => noopImageLoader\n});\n/**\n * Internal helper function that makes it easier to introduce custom image loaders for the\n * `NgOptimizedImage` directive. It is enough to specify a URL builder function to obtain full DI\n * configuration for a given loader: a DI token corresponding to the actual loader function, plus DI\n * tokens managing preconnect check functionality.\n * @param buildUrlFn a function returning a full URL based on loader's configuration\n * @param exampleUrls example of full URLs for a given loader (used in error messages)\n * @returns a set of DI providers corresponding to the configured image loader\n */\nfunction createImageLoader(buildUrlFn, exampleUrls) {\n return function provideImageLoader(path) {\n if (!isValidPath(path)) {\n throwInvalidPathError(path, exampleUrls || []);\n }\n // The trailing / is stripped (if provided) to make URL construction (concatenation) easier in\n // the individual loader functions.\n path = normalizePath(path);\n const loaderFn = config => {\n if (isAbsoluteUrl(config.src)) {\n // Image loader functions expect an image file name (e.g. `my-image.png`)\n // or a relative path + a file name (e.g. `/a/b/c/my-image.png`) as an input,\n // so the final absolute URL can be constructed.\n // When an absolute URL is provided instead - the loader can not\n // build a final URL, thus the error is thrown to indicate that.\n throwUnexpectedAbsoluteUrlError(path, config.src);\n }\n return buildUrlFn(path, {\n ...config,\n src: normalizeSrc(config.src)\n });\n };\n const providers = [{\n provide: IMAGE_LOADER,\n useValue: loaderFn\n }];\n return providers;\n };\n}\nfunction throwInvalidPathError(path, exampleUrls) {\n throw new ɵRuntimeError(2959 /* RuntimeErrorCode.INVALID_LOADER_ARGUMENTS */, ngDevMode && `Image loader has detected an invalid path (\\`${path}\\`). ` + `To fix this, supply a path using one of the following formats: ${exampleUrls.join(' or ')}`);\n}\nfunction throwUnexpectedAbsoluteUrlError(path, url) {\n throw new ɵRuntimeError(2959 /* RuntimeErrorCode.INVALID_LOADER_ARGUMENTS */, ngDevMode && `Image loader has detected a \\`<img>\\` tag with an invalid \\`ngSrc\\` attribute: ${url}. ` + `This image loader expects \\`ngSrc\\` to be a relative URL - ` + `however the provided value is an absolute URL. ` + `To fix this, provide \\`ngSrc\\` as a path relative to the base URL ` + `configured for this loader (\\`${path}\\`).`);\n}\n\n/**\n * Function that generates an ImageLoader for [Cloudflare Image\n * Resizing](https://developers.cloudflare.com/images/image-resizing/) and turns it into an Angular\n * provider. Note: Cloudflare has multiple image products - this provider is specifically for\n * Cloudflare Image Resizing; it will not work with Cloudflare Images or Cloudflare Polish.\n *\n * @param path Your domain name, e.g. https://mysite.com\n * @returns Provider that provides an ImageLoader function\n *\n * @publicApi\n */\nconst provideCloudflareLoader = createImageLoader(createCloudflareUrl, ngDevMode ? ['https://<ZONE>/cdn-cgi/image/<OPTIONS>/<SOURCE-IMAGE>'] : undefined);\nfunction createCloudflareUrl(path, config) {\n let params = `format=auto`;\n if (config.width) {\n params += `,width=${config.width}`;\n }\n // When requesting a placeholder image we ask for a low quality image to reduce the load time.\n if (config.isPlaceholder) {\n params += `,quality=${PLACEHOLDER_QUALITY}`;\n }\n // Cloudflare image URLs format:\n // https://developers.cloudflare.com/images/image-resizing/url-format/\n return `${path}/cdn-cgi/image/${params}/${config.src}`;\n}\n\n/**\n * Name and URL tester for Cloudinary.\n */\nconst cloudinaryLoaderInfo = {\n name: 'Cloudinary',\n testUrl: isCloudinaryUrl\n};\nconst CLOUDINARY_LOADER_REGEX = /https?\\:\\/\\/[^\\/]+\\.cloudinary\\.com\\/.+/;\n/**\n * Tests whether a URL is from Cloudinary CDN.\n */\nfunction isCloudinaryUrl(url) {\n return CLOUDINARY_LOADER_REGEX.test(url);\n}\n/**\n * Function that generates an ImageLoader for Cloudinary and turns it into an Angular provider.\n *\n * @param path Base URL of your Cloudinary images\n * This URL should match one of the following formats:\n * https://res.cloudinary.com/mysite\n * https://mysite.cloudinary.com\n * https://subdomain.mysite.com\n * @returns Set of providers to configure the Cloudinary loader.\n *\n * @publicApi\n */\nconst provideCloudinaryLoader = createImageLoader(createCloudinaryUrl, ngDevMode ? ['https://res.cloudinary.com/mysite', 'https://mysite.cloudinary.com', 'https://subdomain.mysite.com'] : undefined);\nfunction createCloudinaryUrl(path, config) {\n // Cloudinary image URLformat:\n // https://cloudinary.com/documentation/image_transformations#transformation_url_structure\n // Example of a Cloudinary image URL:\n // https://res.cloudinary.com/mysite/image/upload/c_scale,f_auto,q_auto,w_600/marketing/tile-topics-m.png\n // For a placeholder image, we use the lowest image setting available to reduce the load time\n // else we use the auto size\n const quality = config.isPlaceholder ? 'q_auto:low' : 'q_auto';\n let params = `f_auto,${quality}`;\n if (config.width) {\n params += `,w_${config.width}`;\n }\n if (config.loaderParams?.['rounded']) {\n params += `,r_max`;\n }\n return `${path}/image/upload/${params}/${config.src}`;\n}\n\n/**\n * Name and URL tester for ImageKit.\n */\nconst imageKitLoaderInfo = {\n name: 'ImageKit',\n testUrl: isImageKitUrl\n};\nconst IMAGE_KIT_LOADER_REGEX = /https?\\:\\/\\/[^\\/]+\\.imagekit\\.io\\/.+/;\n/**\n * Tests whether a URL is from ImageKit CDN.\n */\nfunction isImageKitUrl(url) {\n return IMAGE_KIT_LOADER_REGEX.test(url);\n}\n/**\n * Function that generates an ImageLoader for ImageKit and turns it into an Angular provider.\n *\n * @param path Base URL of your ImageKit images\n * This URL should match one of the following formats:\n * https://ik.imagekit.io/myaccount\n * https://subdomain.mysite.com\n * @returns Set of providers to configure the ImageKit loader.\n *\n * @publicApi\n */\nconst provideImageKitLoader = createImageLoader(createImagekitUrl, ngDevMode ? ['https://ik.imagekit.io/mysite', 'https://subdomain.mysite.com'] : undefined);\nfunction createImagekitUrl(path, config) {\n // Example of an ImageKit image URL:\n // https://ik.imagekit.io/demo/tr:w-300,h-300/medium_cafe_B1iTdD0C.jpg\n const {\n src,\n width\n } = config;\n const params = [];\n if (width) {\n params.push(`w-${width}`);\n }\n // When requesting a placeholder image we ask for a low quality image to reduce the load time.\n if (config.isPlaceholder) {\n params.push(`q-${PLACEHOLDER_QUALITY}`);\n }\n const urlSegments = params.length ? [path, `tr:${params.join(',')}`, src] : [path, src];\n const url = new URL(urlSegments.join('/'));\n return url.href;\n}\n\n/**\n * Name and URL tester for Imgix.\n */\nconst imgixLoaderInfo = {\n name: 'Imgix',\n testUrl: isImgixUrl\n};\nconst IMGIX_LOADER_REGEX = /https?\\:\\/\\/[^\\/]+\\.imgix\\.net\\/.+/;\n/**\n * Tests whether a URL is from Imgix CDN.\n */\nfunction isImgixUrl(url) {\n return IMGIX_LOADER_REGEX.test(url);\n}\n/**\n * Function that generates an ImageLoader for Imgix and turns it into an Angular provider.\n *\n * @param path path to the desired Imgix origin,\n * e.g. https://somepath.imgix.net or https://images.mysite.com\n * @returns Set of providers to configure the Imgix loader.\n *\n * @publicApi\n */\nconst provideImgixLoader = createImageLoader(createImgixUrl, ngDevMode ? ['https://somepath.imgix.net/'] : undefined);\nfunction createImgixUrl(path, config) {\n const url = new URL(`${path}/${config.src}`);\n // This setting ensures the smallest allowable format is set.\n url.searchParams.set('auto', 'format');\n if (config.width) {\n url.searchParams.set('w', config.width.toString());\n }\n // When requesting a placeholder image we ask a low quality image to reduce the load time.\n if (config.isPlaceholder) {\n url.searchParams.set('q', PLACEHOLDER_QUALITY);\n }\n return url.href;\n}\n\n/**\n * Name and URL tester for Netlify.\n */\nconst netlifyLoaderInfo = {\n name: 'Netlify',\n testUrl: isNetlifyUrl\n};\nconst NETLIFY_LOADER_REGEX = /https?\\:\\/\\/[^\\/]+\\.netlify\\.app\\/.+/;\n/**\n * Tests whether a URL is from a Netlify site. This won't catch sites with a custom domain,\n * but it's a good start for sites in development. This is only used to warn users who haven't\n * configured an image loader.\n */\nfunction isNetlifyUrl(url) {\n return NETLIFY_LOADER_REGEX.test(url);\n}\n/**\n * Function that generates an ImageLoader for Netlify and turns it into an Angular provider.\n *\n * @param path optional URL of the desired Netlify site. Defaults to the current site.\n * @returns Set of providers to configure the Netlify loader.\n *\n * @publicApi\n */\nfunction provideNetlifyLoader(path) {\n if (path && !isValidPath(path)) {\n throw new ɵRuntimeError(2959 /* RuntimeErrorCode.INVALID_LOADER_ARGUMENTS */, ngDevMode && `Image loader has detected an invalid path (\\`${path}\\`). ` + `To fix this, supply either the full URL to the Netlify site, or leave it empty to use the current site.`);\n }\n if (path) {\n const url = new URL(path);\n path = url.origin;\n }\n const loaderFn = config => {\n return createNetlifyUrl(config, path);\n };\n const providers = [{\n provide: IMAGE_LOADER,\n useValue: loaderFn\n }];\n return providers;\n}\nconst validParams = new Map([['height', 'h'], ['fit', 'fit'], ['quality', 'q'], ['q', 'q'], ['position', 'position']]);\nfunction createNetlifyUrl(config, path) {\n // Note: `path` can be undefined, in which case we use a fake one to construct a `URL` instance.\n const url = new URL(path ?? 'https://a/');\n url.pathname = '/.netlify/images';\n if (!isAbsoluteUrl(config.src) && !config.src.startsWith('/')) {\n config.src = '/' + config.src;\n }\n url.searchParams.set('url', config.src);\n if (config.width) {\n url.searchParams.set('w', config.width.toString());\n }\n // When requesting a placeholder image we ask for a low quality image to reduce the load time.\n // If the quality is specified in the loader config - always use provided value.\n const configQuality = config.loaderParams?.['quality'] ?? config.loaderParams?.['q'];\n if (config.isPlaceholder && !configQuality) {\n url.searchParams.set('q', PLACEHOLDER_QUALITY);\n }\n for (const [param, value] of Object.entries(config.loaderParams ?? {})) {\n if (validParams.has(param)) {\n url.searchParams.set(validParams.get(param), value.toString());\n } else {\n if (ngDevMode) {\n console.warn(ɵformatRuntimeError(2959 /* RuntimeErrorCode.INVALID_LOADER_ARGUMENTS */, `The Netlify image loader has detected an \\`<img>\\` tag with the unsupported attribute \"\\`${param}\\`\".`));\n }\n }\n }\n // The \"a\" hostname is used for relative URLs, so we can remove it from the final URL.\n return url.hostname === 'a' ? url.href.replace(url.origin, '') : url.href;\n}\n\n// Assembles directive details string, useful for error messages.\nfunction imgDirectiveDetails(ngSrc, includeNgSrc = true) {\n const ngSrcInfo = includeNgSrc ? `(activated on an <img> element with the \\`ngSrc=\"${ngSrc}\"\\`) ` : '';\n return `The NgOptimizedImage directive ${ngSrcInfo}has detected that`;\n}\n\n/**\n * Asserts that the application is in development mode. Throws an error if the application is in\n * production mode. This assert can be used to make sure that there is no dev-mode code invoked in\n * the prod mode accidentally.\n */\nfunction assertDevMode(checkName) {\n if (!ngDevMode) {\n throw new ɵRuntimeError(2958 /* RuntimeErrorCode.UNEXPECTED_DEV_MODE_CHECK_IN_PROD_MODE */, `Unexpected invocation of the ${checkName} in the prod mode. ` + `Please make sure that the prod mode is enabled for production builds.`);\n }\n}\n\n/**\n * Observer that detects whether an image with `NgOptimizedImage`\n * is treated as a Largest Contentful Paint (LCP) element. If so,\n * asserts that the image has the `priority` attribute.\n *\n * Note: this is a dev-mode only class and it does not appear in prod bundles,\n * thus there is no `ngDevMode` use in the code.\n *\n * Based on https://web.dev/lcp/#measure-lcp-in-javascript.\n */\nclass LCPImageObserver {\n // Map of full image URLs -> original `ngSrc` values.\n images = new Map();\n window = null;\n observer = null;\n constructor() {\n const isBrowser = isPlatformBrowser(inject(PLATFORM_ID));\n assertDevMode('LCP checker');\n const win = inject(DOCUMENT).defaultView;\n if (isBrowser && typeof PerformanceObserver !== 'undefined') {\n this.window = win;\n this.observer = this.initPerformanceObserver();\n }\n }\n /**\n * Inits PerformanceObserver and subscribes to LCP events.\n * Based on https://web.dev/lcp/#measure-lcp-in-javascript\n */\n initPerformanceObserver() {\n const observer = new PerformanceObserver(entryList => {\n const entries = entryList.getEntries();\n if (entries.length === 0) return;\n // We use the latest entry produced by the `PerformanceObserver` as the best\n // signal on which element is actually an LCP one. As an example, the first image to load on\n // a page, by virtue of being the only thing on the page so far, is often a LCP candidate\n // and gets reported by PerformanceObserver, but isn't necessarily the LCP element.\n const lcpElement = entries[entries.length - 1];\n // Cast to `any` due to missing `element` on the `LargestContentfulPaint` type of entry.\n // See https://developer.mozilla.org/en-US/docs/Web/API/LargestContentfulPaint\n const imgSrc = lcpElement.element?.src ?? '';\n // Exclude `data:` and `blob:` URLs, since they are not supported by the directive.\n if (imgSrc.startsWith('data:') || imgSrc.startsWith('blob:')) return;\n const img = this.images.get(imgSrc);\n if (!img) return;\n if (!img.priority && !img.alreadyWarnedPriority) {\n img.alreadyWarnedPriority = true;\n logMissingPriorityError(imgSrc);\n }\n if (img.modified && !img.alreadyWarnedModified) {\n img.alreadyWarnedModified = true;\n logModifiedWarning(imgSrc);\n }\n });\n observer.observe({\n type: 'largest-contentful-paint',\n buffered: true\n });\n return observer;\n }\n registerImage(rewrittenSrc, originalNgSrc, isPriority) {\n if (!this.observer) return;\n const newObservedImageState = {\n priority: isPriority,\n modified: false,\n alreadyWarnedModified: false,\n alreadyWarnedPriority: false\n };\n this.images.set(getUrl(rewrittenSrc, this.window).href, newObservedImageState);\n }\n unregisterImage(rewrittenSrc) {\n if (!this.observer) return;\n this.images.delete(getUrl(rewrittenSrc, this.window).href);\n }\n updateImage(originalSrc, newSrc) {\n if (!this.observer) return;\n const originalUrl = getUrl(originalSrc, this.window).href;\n const img = this.images.get(originalUrl);\n if (img) {\n img.modified = true;\n this.images.set(getUrl(newSrc, this.window).href, img);\n this.images.delete(originalUrl);\n }\n }\n ngOnDestroy() {\n if (!this.observer) return;\n this.observer.disconnect();\n this.images.clear();\n }\n static ɵfac = function LCPImageObserver_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || LCPImageObserver)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: LCPImageObserver,\n factory: LCPImageObserver.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(LCPImageObserver, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [], null);\n})();\nfunction logMissingPriorityError(ngSrc) {\n const directiveDetails = imgDirectiveDetails(ngSrc);\n console.error(ɵformatRuntimeError(2955 /* RuntimeErrorCode.LCP_IMG_MISSING_PRIORITY */, `${directiveDetails} this image is the Largest Contentful Paint (LCP) ` + `element but was not marked \"priority\". This image should be marked ` + `\"priority\" in order to prioritize its loading. ` + `To fix this, add the \"priority\" attribute.`));\n}\nfunction logModifiedWarning(ngSrc) {\n const directiveDetails = imgDirectiveDetails(ngSrc);\n console.warn(ɵformatRuntimeError(2964 /* RuntimeErrorCode.LCP_IMG_NGSRC_MODIFIED */, `${directiveDetails} this image is the Largest Contentful Paint (LCP) ` + `element and has had its \"ngSrc\" attribute modified. This can cause ` + `slower loading performance. It is recommended not to modify the \"ngSrc\" ` + `property on any image which could be the LCP element.`));\n}\n\n// Set of origins that are always excluded from the preconnect checks.\nconst INTERNAL_PRECONNECT_CHECK_BLOCKLIST = new Set(['localhost', '127.0.0.1', '0.0.0.0']);\n/**\n * Injection token to configure which origins should be excluded\n * from the preconnect checks. It can either be a single string or an array of strings\n * to represent a group of origins, for example:\n *\n * ```ts\n * {provide: PRECONNECT_CHECK_BLOCKLIST, useValue: 'https://your-domain.com'}\n * ```\n *\n * or:\n *\n * ```ts\n * {provide: PRECONNECT_CHECK_BLOCKLIST,\n * useValue: ['https://your-domain-1.com', 'https://your-domain-2.com']}\n * ```\n *\n * @publicApi\n */\nconst PRECONNECT_CHECK_BLOCKLIST = new InjectionToken(ngDevMode ? 'PRECONNECT_CHECK_BLOCKLIST' : '');\n/**\n * Contains the logic to detect whether an image, marked with the \"priority\" attribute\n * has a corresponding `<link rel=\"preconnect\">` tag in the `document.head`.\n *\n * Note: this is a dev-mode only class, which should not appear in prod bundles,\n * thus there is no `ngDevMode` use in the code.\n */\nclass PreconnectLinkChecker {\n document = inject(DOCUMENT);\n /**\n * Set of <link rel=\"preconnect\"> tags found on this page.\n * The `null` value indicates that there was no DOM query operation performed.\n */\n preconnectLinks = null;\n /*\n * Keep track of all already seen origin URLs to avoid repeating the same check.\n */\n alreadySeen = new Set();\n window = this.document.defaultView;\n blocklist = new Set(INTERNAL_PRECONNECT_CHECK_BLOCKLIST);\n constructor() {\n assertDevMode('preconnect link checker');\n const blocklist = inject(PRECONNECT_CHECK_BLOCKLIST, {\n optional: true\n });\n if (blocklist) {\n this.populateBlocklist(blocklist);\n }\n }\n populateBlocklist(origins) {\n if (Array.isArray(origins)) {\n deepForEach(origins, origin => {\n this.blocklist.add(extractHostname(origin));\n });\n } else {\n this.blocklist.add(extractHostname(origins));\n }\n }\n /**\n * Checks that a preconnect resource hint exists in the head for the\n * given src.\n *\n * @param rewrittenSrc src formatted with loader\n * @param originalNgSrc ngSrc value\n */\n assertPreconnect(rewrittenSrc, originalNgSrc) {\n if (typeof ngServerMode !== 'undefined' && ngServerMode) return;\n const imgUrl = getUrl(rewrittenSrc, this.window);\n if (this.blocklist.has(imgUrl.hostname) || this.alreadySeen.has(imgUrl.origin)) return;\n // Register this origin as seen, so we don't check it again later.\n this.alreadySeen.add(imgUrl.origin);\n // Note: we query for preconnect links only *once* and cache the results\n // for the entire lifespan of an application, since it's unlikely that the\n // list would change frequently. This allows to make sure there are no\n // performance implications of making extra DOM lookups for each image.\n this.preconnectLinks ??= this.queryPreconnectLinks();\n if (!this.preconnectLinks.has(imgUrl.origin)) {\n console.warn(ɵformatRuntimeError(2956 /* RuntimeErrorCode.PRIORITY_IMG_MISSING_PRECONNECT_TAG */, `${imgDirectiveDetails(originalNgSrc)} there is no preconnect tag present for this ` + `image. Preconnecting to the origin(s) that serve priority images ensures that these ` + `images are delivered as soon as possible. To fix this, please add the following ` + `element into the <head> of the document:\\n` + ` <link rel=\"preconnect\" href=\"${imgUrl.origin}\">`));\n }\n }\n queryPreconnectLinks() {\n const preconnectUrls = new Set();\n const selector = 'link[rel=preconnect]';\n const links = Array.from(this.document.querySelectorAll(selector));\n for (let link of links) {\n const url = getUrl(link.href, this.window);\n preconnectUrls.add(url.origin);\n }\n return preconnectUrls;\n }\n ngOnDestroy() {\n this.preconnectLinks?.clear();\n this.alreadySeen.clear();\n }\n static ɵfac = function PreconnectLinkChecker_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PreconnectLinkChecker)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: PreconnectLinkChecker,\n factory: PreconnectLinkChecker.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PreconnectLinkChecker, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [], null);\n})();\n/**\n * Invokes a callback for each element in the array. Also invokes a callback\n * recursively for each nested array.\n */\nfunction deepForEach(input, fn) {\n for (let value of input) {\n Array.isArray(value) ? deepForEach(value, fn) : fn(value);\n }\n}\n\n/**\n * In SSR scenarios, a preload `<link>` element is generated for priority images.\n * Having a large number of preload tags may negatively affect the performance,\n * so we warn developers (by throwing an error) if the number of preloaded images\n * is above a certain threshold. This const specifies this threshold.\n */\nconst DEFAULT_PRELOADED_IMAGES_LIMIT = 5;\n/**\n * Helps to keep track of priority images that already have a corresponding\n * preload tag (to avoid generating multiple preload tags with the same URL).\n *\n * This Set tracks the original src passed into the `ngSrc` input not the src after it has been\n * run through the specified `IMAGE_LOADER`.\n */\nconst PRELOADED_IMAGES = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'NG_OPTIMIZED_PRELOADED_IMAGES' : '', {\n providedIn: 'root',\n factory: () => new Set()\n});\n\n/**\n * @description Contains the logic needed to track and add preload link tags to the `<head>` tag. It\n * will also track what images have already had preload link tags added so as to not duplicate link\n * tags.\n *\n * In dev mode this service will validate that the number of preloaded images does not exceed the\n * configured default preloaded images limit: {@link DEFAULT_PRELOADED_IMAGES_LIMIT}.\n */\nclass PreloadLinkCreator {\n preloadedImages = inject(PRELOADED_IMAGES);\n document = inject(DOCUMENT);\n /**\n * @description Add a preload `<link>` to the `<head>` of the `index.html` that is served from the\n * server while using Angular Universal and SSR to kick off image loads for high priority images.\n *\n * The `sizes` (passed in from the user) and `srcset` (parsed and formatted from `ngSrcset`)\n * properties used to set the corresponding attributes, `imagesizes` and `imagesrcset`\n * respectively, on the preload `<link>` tag so that the correctly sized image is preloaded from\n * the CDN.\n *\n * {@link https://web.dev/preload-responsive-images/#imagesrcset-and-imagesizes}\n *\n * @param renderer The `Renderer2` passed in from the directive\n * @param src The original src of the image that is set on the `ngSrc` input.\n * @param srcset The parsed and formatted srcset created from the `ngSrcset` input\n * @param sizes The value of the `sizes` attribute passed in to the `<img>` tag\n */\n createPreloadLinkTag(renderer, src, srcset, sizes) {\n if (ngDevMode) {\n if (this.preloadedImages.size >= DEFAULT_PRELOADED_IMAGES_LIMIT) {\n throw new ɵRuntimeError(2961 /* RuntimeErrorCode.TOO_MANY_PRELOADED_IMAGES */, ngDevMode && `The \\`NgOptimizedImage\\` directive has detected that more than ` + `${DEFAULT_PRELOADED_IMAGES_LIMIT} images were marked as priority. ` + `This might negatively affect an overall performance of the page. ` + `To fix this, remove the \"priority\" attribute from images with less priority.`);\n }\n }\n if (this.preloadedImages.has(src)) {\n return;\n }\n this.preloadedImages.add(src);\n const preload = renderer.createElement('link');\n renderer.setAttribute(preload, 'as', 'image');\n renderer.setAttribute(preload, 'href', src);\n renderer.setAttribute(preload, 'rel', 'preload');\n renderer.setAttribute(preload, 'fetchpriority', 'high');\n if (sizes) {\n renderer.setAttribute(preload, 'imageSizes', sizes);\n }\n if (srcset) {\n renderer.setAttribute(preload, 'imageSrcset', srcset);\n }\n renderer.appendChild(this.document.head, preload);\n }\n static ɵfac = function PreloadLinkCreator_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PreloadLinkCreator)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: PreloadLinkCreator,\n factory: PreloadLinkCreator.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PreloadLinkCreator, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n\n/**\n * When a Base64-encoded image is passed as an input to the `NgOptimizedImage` directive,\n * an error is thrown. The image content (as a string) might be very long, thus making\n * it hard to read an error message if the entire string is included. This const defines\n * the number of characters that should be included into the error message. The rest\n * of the content is truncated.\n */\nconst BASE64_IMG_MAX_LENGTH_IN_ERROR = 50;\n/**\n * RegExpr to determine whether a src in a srcset is using width descriptors.\n * Should match something like: \"100w, 200w\".\n */\nconst VALID_WIDTH_DESCRIPTOR_SRCSET = /^((\\s*\\d+w\\s*(,|$)){1,})$/;\n/**\n * RegExpr to determine whether a src in a srcset is using density descriptors.\n * Should match something like: \"1x, 2x, 50x\". Also supports decimals like \"1.5x, 1.50x\".\n */\nconst VALID_DENSITY_DESCRIPTOR_SRCSET = /^((\\s*\\d+(\\.\\d+)?x\\s*(,|$)){1,})$/;\n/**\n * Srcset values with a density descriptor higher than this value will actively\n * throw an error. Such densities are not permitted as they cause image sizes\n * to be unreasonably large and slow down LCP.\n */\nconst ABSOLUTE_SRCSET_DENSITY_CAP = 3;\n/**\n * Used only in error message text to communicate best practices, as we will\n * only throw based on the slightly more conservative ABSOLUTE_SRCSET_DENSITY_CAP.\n */\nconst RECOMMENDED_SRCSET_DENSITY_CAP = 2;\n/**\n * Used in generating automatic density-based srcsets\n */\nconst DENSITY_SRCSET_MULTIPLIERS = [1, 2];\n/**\n * Used to determine which breakpoints to use on full-width images\n */\nconst VIEWPORT_BREAKPOINT_CUTOFF = 640;\n/**\n * Used to determine whether two aspect ratios are similar in value.\n */\nconst ASPECT_RATIO_TOLERANCE = 0.1;\n/**\n * Used to determine whether the image has been requested at an overly\n * large size compared to the actual rendered image size (after taking\n * into account a typical device pixel ratio). In pixels.\n */\nconst OVERSIZED_IMAGE_TOLERANCE = 1000;\n/**\n * Used to limit automatic srcset generation of very large sources for\n * fixed-size images. In pixels.\n */\nconst FIXED_SRCSET_WIDTH_LIMIT = 1920;\nconst FIXED_SRCSET_HEIGHT_LIMIT = 1080;\n/**\n * Default blur radius of the CSS filter used on placeholder images, in pixels\n */\nconst PLACEHOLDER_BLUR_AMOUNT = 15;\n/**\n * Placeholder dimension (height or width) limit in pixels. Angular produces a warning\n * when this limit is crossed.\n */\nconst PLACEHOLDER_DIMENSION_LIMIT = 1000;\n/**\n * Used to warn or error when the user provides an overly large dataURL for the placeholder\n * attribute.\n * Character count of Base64 images is 1 character per byte, and base64 encoding is approximately\n * 33% larger than base images, so 4000 characters is around 3KB on disk and 10000 characters is\n * around 7.7KB. Experimentally, 4000 characters is about 20x20px in PNG or medium-quality JPEG\n * format, and 10,000 is around 50x50px, but there's quite a bit of variation depending on how the\n * image is saved.\n */\nconst DATA_URL_WARN_LIMIT = 4000;\nconst DATA_URL_ERROR_LIMIT = 10000;\n/** Info about built-in loaders we can test for. */\nconst BUILT_IN_LOADERS = [imgixLoaderInfo, imageKitLoaderInfo, cloudinaryLoaderInfo, netlifyLoaderInfo];\n/**\n * Threshold for the PRIORITY_TRUE_COUNT\n */\nconst PRIORITY_COUNT_THRESHOLD = 10;\n/**\n * This count is used to log a devMode warning\n * when the count of directive instances with priority=true\n * exceeds the threshold PRIORITY_COUNT_THRESHOLD\n */\nlet IMGS_WITH_PRIORITY_ATTR_COUNT = 0;\n/**\n * This function is for testing purpose.\n */\nfunction resetImagePriorityCount() {\n IMGS_WITH_PRIORITY_ATTR_COUNT = 0;\n}\n/**\n * Directive that improves image loading performance by enforcing best practices.\n *\n * `NgOptimizedImage` ensures that the loading of the Largest Contentful Paint (LCP) image is\n * prioritized by:\n * - Automatically setting the `fetchpriority` attribute on the `<img>` tag\n * - Lazy loading non-priority images by default\n * - Automatically generating a preconnect link tag in the document head\n *\n * In addition, the directive:\n * - Generates appropriate asset URLs if a corresponding `ImageLoader` function is provided\n * - Automatically generates a srcset\n * - Requires that `width` and `height` are set\n * - Warns if `width` or `height` have been set incorrectly\n * - Warns if the image will be visually distorted when rendered\n *\n * @usageNotes\n * The `NgOptimizedImage` directive is marked as [standalone](guide/components/importing) and can\n * be imported directly.\n *\n * Follow the steps below to enable and use the directive:\n * 1. Import it into the necessary NgModule or a standalone Component.\n * 2. Optionally provide an `ImageLoader` if you use an image hosting service.\n * 3. Update the necessary `<img>` tags in templates and replace `src` attributes with `ngSrc`.\n * Using a `ngSrc` allows the directive to control when the `src` gets set, which triggers an image\n * download.\n *\n * Step 1: import the `NgOptimizedImage` directive.\n *\n * ```ts\n * import { NgOptimizedImage } from '@angular/common';\n *\n * // Include it into the necessary NgModule\n * @NgModule({\n * imports: [NgOptimizedImage],\n * })\n * class AppModule {}\n *\n * // ... or a standalone Component\n * @Component({\n * imports: [NgOptimizedImage],\n * })\n * class MyStandaloneComponent {}\n * ```\n *\n * Step 2: configure a loader.\n *\n * To use the **default loader**: no additional code changes are necessary. The URL returned by the\n * generic loader will always match the value of \"src\". In other words, this loader applies no\n * transformations to the resource URL and the value of the `ngSrc` attribute will be used as is.\n *\n * To use an existing loader for a **third-party image service**: add the provider factory for your\n * chosen service to the `providers` array. In the example below, the Imgix loader is used:\n *\n * ```ts\n * import {provideImgixLoader} from '@angular/common';\n *\n * // Call the function and add the result to the `providers` array:\n * providers: [\n * provideImgixLoader(\"https://my.base.url/\"),\n * ],\n * ```\n *\n * The `NgOptimizedImage` directive provides the following functions:\n * - `provideCloudflareLoader`\n * - `provideCloudinaryLoader`\n * - `provideImageKitLoader`\n * - `provideImgixLoader`\n *\n * If you use a different image provider, you can create a custom loader function as described\n * below.\n *\n * To use a **custom loader**: provide your loader function as a value for the `IMAGE_LOADER` DI\n * token.\n *\n * ```ts\n * import {IMAGE_LOADER, ImageLoaderConfig} from '@angular/common';\n *\n * // Configure the loader using the `IMAGE_LOADER` token.\n * providers: [\n * {\n * provide: IMAGE_LOADER,\n * useValue: (config: ImageLoaderConfig) => {\n * return `https://example.com/${config.src}-${config.width}.jpg`;\n * }\n * },\n * ],\n * ```\n *\n * Step 3: update `<img>` tags in templates to use `ngSrc` instead of `src`.\n *\n * ```html\n * <img ngSrc=\"logo.png\" width=\"200\" height=\"100\">\n * ```\n *\n * @publicApi\n */\nclass NgOptimizedImage {\n imageLoader = inject(IMAGE_LOADER);\n config = processConfig(inject(ɵIMAGE_CONFIG));\n renderer = inject(Renderer2);\n imgElement = inject(ElementRef).nativeElement;\n injector = inject(Injector);\n // An LCP image observer should be injected only in development mode.\n // Do not assign it to `null` to avoid having a redundant property in the production bundle.\n lcpObserver;\n /**\n * Calculate the rewritten `src` once and store it.\n * This is needed to avoid repetitive calculations and make sure the directive cleanup in the\n * `ngOnDestroy` does not rely on the `IMAGE_LOADER` logic (which in turn can rely on some other\n * instance that might be already destroyed).\n */\n _renderedSrc = null;\n /**\n * Name of the source image.\n * Image name will be processed by the image loader and the final URL will be applied as the `src`\n * property of the image.\n */\n ngSrc;\n /**\n * A comma separated list of width or density descriptors.\n * The image name will be taken from `ngSrc` and combined with the list of width or density\n * descriptors to generate the final `srcset` property of the image.\n *\n * Example:\n * ```html\n * <img ngSrc=\"hello.jpg\" ngSrcset=\"100w, 200w\" /> =>\n * <img src=\"path/hello.jpg\" srcset=\"path/hello.jpg?w=100 100w, path/hello.jpg?w=200 200w\" />\n * ```\n */\n ngSrcset;\n /**\n * The base `sizes` attribute passed through to the `<img>` element.\n * Providing sizes causes the image to create an automatic responsive srcset.\n */\n sizes;\n /**\n * For responsive images: the intrinsic width of the image in pixels.\n * For fixed size images: the desired rendered width of the image in pixels.\n */\n width;\n /**\n * For responsive images: the intrinsic height of the image in pixels.\n * For fixed size images: the desired rendered height of the image in pixels.\n */\n height;\n /**\n * The desired loading behavior (lazy, eager, or auto). Defaults to `lazy`,\n * which is recommended for most images.\n *\n * Warning: Setting images as loading=\"eager\" or loading=\"auto\" marks them\n * as non-priority images and can hurt loading performance. For images which\n * may be the LCP element, use the `priority` attribute instead of `loading`.\n */\n loading;\n /**\n * Indicates whether this image should have a high priority.\n */\n priority = false;\n /**\n * Data to pass through to custom loaders.\n */\n loaderParams;\n /**\n * Disables automatic srcset generation for this image.\n */\n disableOptimizedSrcset = false;\n /**\n * Sets the image to \"fill mode\", which eliminates the height/width requirement and adds\n * styles such that the image fills its containing element.\n */\n fill = false;\n /**\n * A URL or data URL for an image to be used as a placeholder while this image loads.\n */\n placeholder;\n /**\n * Configuration object for placeholder settings. Options:\n * * blur: Setting this to false disables the automatic CSS blur.\n */\n placeholderConfig;\n /**\n * Value of the `src` attribute if set on the host `<img>` element.\n * This input is exclusively read to assert that `src` is not set in conflict\n * with `ngSrc` and that images don't start to load until a lazy loading strategy is set.\n * @internal\n */\n src;\n /**\n * Value of the `srcset` attribute if set on the host `<img>` element.\n * This input is exclusively read to assert that `srcset` is not set in conflict\n * with `ngSrcset` and that images don't start to load until a lazy loading strategy is set.\n * @internal\n */\n srcset;\n constructor() {\n if (ngDevMode) {\n this.lcpObserver = this.injector.get(LCPImageObserver);\n // Using `DestroyRef` to avoid having an empty `ngOnDestroy` method since this\n // is only run in development mode.\n const destroyRef = inject(DestroyRef);\n destroyRef.onDestroy(() => {\n if (!this.priority && this._renderedSrc !== null) {\n this.lcpObserver.unregisterImage(this._renderedSrc);\n }\n });\n }\n }\n /** @nodoc */\n ngOnInit() {\n ɵperformanceMarkFeature('NgOptimizedImage');\n if (ngDevMode) {\n const ngZone = this.injector.get(NgZone);\n assertNonEmptyInput(this, 'ngSrc', this.ngSrc);\n assertValidNgSrcset(this, this.ngSrcset);\n assertNoConflictingSrc(this);\n if (this.ngSrcset) {\n assertNoConflictingSrcset(this);\n }\n assertNotBase64Image(this);\n assertNotBlobUrl(this);\n if (this.fill) {\n assertEmptyWidthAndHeight(this);\n // This leaves the Angular zone to avoid triggering unnecessary change detection cycles when\n // `load` tasks are invoked on images.\n ngZone.runOutsideAngular(() => assertNonZeroRenderedHeight(this, this.imgElement, this.renderer));\n } else {\n assertNonEmptyWidthAndHeight(this);\n if (this.height !== undefined) {\n assertGreaterThanZero(this, this.height, 'height');\n }\n if (this.width !== undefined) {\n assertGreaterThanZero(this, this.width, 'width');\n }\n // Only check for distorted images when not in fill mode, where\n // images may be intentionally stretched, cropped or letterboxed.\n ngZone.runOutsideAngular(() => assertNoImageDistortion(this, this.imgElement, this.renderer));\n }\n assertValidLoadingInput(this);\n if (!this.ngSrcset) {\n assertNoComplexSizes(this);\n }\n assertValidPlaceholder(this, this.imageLoader);\n assertNotMissingBuiltInLoader(this.ngSrc, this.imageLoader);\n assertNoNgSrcsetWithoutLoader(this, this.imageLoader);\n assertNoLoaderParamsWithoutLoader(this, this.imageLoader);\n ngZone.runOutsideAngular(() => {\n this.lcpObserver.registerImage(this.getRewrittenSrc(), this.ngSrc, this.priority);\n });\n if (this.priority) {\n const checker = this.injector.get(PreconnectLinkChecker);\n checker.assertPreconnect(this.getRewrittenSrc(), this.ngSrc);\n if (typeof ngServerMode !== 'undefined' && !ngServerMode) {\n const applicationRef = this.injector.get(ApplicationRef);\n assetPriorityCountBelowThreshold(applicationRef);\n }\n }\n }\n if (this.placeholder) {\n this.removePlaceholderOnLoad(this.imgElement);\n }\n this.setHostAttributes();\n }\n setHostAttributes() {\n // Must set width/height explicitly in case they are bound (in which case they will\n // only be reflected and not found by the browser)\n if (this.fill) {\n this.sizes ||= '100vw';\n } else {\n this.setHostAttribute('width', this.width.toString());\n this.setHostAttribute('height', this.height.toString());\n }\n this.setHostAttribute('loading', this.getLoadingBehavior());\n this.setHostAttribute('fetchpriority', this.getFetchPriority());\n // The `data-ng-img` attribute flags an image as using the directive, to allow\n // for analysis of the directive's performance.\n this.setHostAttribute('ng-img', 'true');\n // The `src` and `srcset` attributes should be set last since other attributes\n // could affect the image's loading behavior.\n const rewrittenSrcset = this.updateSrcAndSrcset();\n if (this.sizes) {\n if (this.getLoadingBehavior() === 'lazy') {\n this.setHostAttribute('sizes', 'auto, ' + this.sizes);\n } else {\n this.setHostAttribute('sizes', this.sizes);\n }\n } else {\n if (this.ngSrcset && VALID_WIDTH_DESCRIPTOR_SRCSET.test(this.ngSrcset) && this.getLoadingBehavior() === 'lazy') {\n this.setHostAttribute('sizes', 'auto, 100vw');\n }\n }\n if (typeof ngServerMode !== 'undefined' && ngServerMode && this.priority) {\n const preloadLinkCreator = this.injector.get(PreloadLinkCreator);\n preloadLinkCreator.createPreloadLinkTag(this.renderer, this.getRewrittenSrc(), rewrittenSrcset, this.sizes);\n }\n }\n /** @nodoc */\n ngOnChanges(changes) {\n if (ngDevMode) {\n assertNoPostInitInputChange(this, changes, ['ngSrcset', 'width', 'height', 'priority', 'fill', 'loading', 'sizes', 'loaderParams', 'disableOptimizedSrcset']);\n }\n if (changes['ngSrc'] && !changes['ngSrc'].isFirstChange()) {\n const oldSrc = this._renderedSrc;\n this.updateSrcAndSrcset(true);\n if (ngDevMode) {\n const newSrc = this._renderedSrc;\n if (oldSrc && newSrc && oldSrc !== newSrc) {\n const ngZone = this.injector.get(NgZone);\n ngZone.runOutsideAngular(() => {\n this.lcpObserver.updateImage(oldSrc, newSrc);\n });\n }\n }\n }\n if (ngDevMode && changes['placeholder']?.currentValue && typeof ngServerMode !== 'undefined' && !ngServerMode) {\n assertPlaceholderDimensions(this, this.imgElement);\n }\n }\n callImageLoader(configWithoutCustomParams) {\n let augmentedConfig = configWithoutCustomParams;\n if (this.loaderParams) {\n augmentedConfig.loaderParams = this.loaderParams;\n }\n return this.imageLoader(augmentedConfig);\n }\n getLoadingBehavior() {\n if (!this.priority && this.loading !== undefined) {\n return this.loading;\n }\n return this.priority ? 'eager' : 'lazy';\n }\n getFetchPriority() {\n return this.priority ? 'high' : 'auto';\n }\n getRewrittenSrc() {\n // ImageLoaderConfig supports setting a width property. However, we're not setting width here\n // because if the developer uses rendered width instead of intrinsic width in the HTML width\n // attribute, the image requested may be too small for 2x+ screens.\n if (!this._renderedSrc) {\n const imgConfig = {\n src: this.ngSrc\n };\n // Cache calculated image src to reuse it later in the code.\n this._renderedSrc = this.callImageLoader(imgConfig);\n }\n return this._renderedSrc;\n }\n getRewrittenSrcset() {\n const widthSrcSet = VALID_WIDTH_DESCRIPTOR_SRCSET.test(this.ngSrcset);\n const finalSrcs = this.ngSrcset.split(',').filter(src => src !== '').map(srcStr => {\n srcStr = srcStr.trim();\n const width = widthSrcSet ? parseFloat(srcStr) : parseFloat(srcStr) * this.width;\n return `${this.callImageLoader({\n src: this.ngSrc,\n width\n })} ${srcStr}`;\n });\n return finalSrcs.join(', ');\n }\n getAutomaticSrcset() {\n if (this.sizes) {\n return this.getResponsiveSrcset();\n } else {\n return this.getFixedSrcset();\n }\n }\n getResponsiveSrcset() {\n const {\n breakpoints\n } = this.config;\n let filteredBreakpoints = breakpoints;\n if (this.sizes?.trim() === '100vw') {\n // Since this is a full-screen-width image, our srcset only needs to include\n // breakpoints with full viewport widths.\n filteredBreakpoints = breakpoints.filter(bp => bp >= VIEWPORT_BREAKPOINT_CUTOFF);\n }\n const finalSrcs = filteredBreakpoints.map(bp => `${this.callImageLoader({\n src: this.ngSrc,\n width: bp\n })} ${bp}w`);\n return finalSrcs.join(', ');\n }\n updateSrcAndSrcset(forceSrcRecalc = false) {\n if (forceSrcRecalc) {\n // Reset cached value, so that the followup `getRewrittenSrc()` call\n // will recalculate it and update the cache.\n this._renderedSrc = null;\n }\n const rewrittenSrc = this.getRewrittenSrc();\n this.setHostAttribute('src', rewrittenSrc);\n let rewrittenSrcset = undefined;\n if (this.ngSrcset) {\n rewrittenSrcset = this.getRewrittenSrcset();\n } else if (this.shouldGenerateAutomaticSrcset()) {\n rewrittenSrcset = this.getAutomaticSrcset();\n }\n if (rewrittenSrcset) {\n this.setHostAttribute('srcset', rewrittenSrcset);\n }\n return rewrittenSrcset;\n }\n getFixedSrcset() {\n const finalSrcs = DENSITY_SRCSET_MULTIPLIERS.map(multiplier => `${this.callImageLoader({\n src: this.ngSrc,\n width: this.width * multiplier\n })} ${multiplier}x`);\n return finalSrcs.join(', ');\n }\n shouldGenerateAutomaticSrcset() {\n let oversizedImage = false;\n if (!this.sizes) {\n oversizedImage = this.width > FIXED_SRCSET_WIDTH_LIMIT || this.height > FIXED_SRCSET_HEIGHT_LIMIT;\n }\n return !this.disableOptimizedSrcset && !this.srcset && this.imageLoader !== noopImageLoader && !oversizedImage;\n }\n /**\n * Returns an image url formatted for use with the CSS background-image property. Expects one of:\n * * A base64 encoded image, which is wrapped and passed through.\n * * A boolean. If true, calls the image loader to generate a small placeholder url.\n */\n generatePlaceholder(placeholderInput) {\n const {\n placeholderResolution\n } = this.config;\n if (placeholderInput === true) {\n return `url(${this.callImageLoader({\n src: this.ngSrc,\n width: placeholderResolution,\n isPlaceholder: true\n })})`;\n } else if (typeof placeholderInput === 'string') {\n return `url(${placeholderInput})`;\n }\n return null;\n }\n /**\n * Determines if blur should be applied, based on an optional boolean\n * property `blur` within the optional configuration object `placeholderConfig`.\n */\n shouldBlurPlaceholder(placeholderConfig) {\n if (!placeholderConfig || !placeholderConfig.hasOwnProperty('blur')) {\n return true;\n }\n return Boolean(placeholderConfig.blur);\n }\n removePlaceholderOnLoad(img) {\n const callback = () => {\n const changeDetectorRef = this.injector.get(ChangeDetectorRef);\n removeLoadListenerFn();\n removeErrorListenerFn();\n this.placeholder = false;\n changeDetectorRef.markForCheck();\n };\n const removeLoadListenerFn = this.renderer.listen(img, 'load', callback);\n const removeErrorListenerFn = this.renderer.listen(img, 'error', callback);\n callOnLoadIfImageIsLoaded(img, callback);\n }\n setHostAttribute(name, value) {\n this.renderer.setAttribute(this.imgElement, name, value);\n }\n static ɵfac = function NgOptimizedImage_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgOptimizedImage)();\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgOptimizedImage,\n selectors: [[\"img\", \"ngSrc\", \"\"]],\n hostVars: 18,\n hostBindings: function NgOptimizedImage_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵstyleProp(\"position\", ctx.fill ? \"absolute\" : null)(\"width\", ctx.fill ? \"100%\" : null)(\"height\", ctx.fill ? \"100%\" : null)(\"inset\", ctx.fill ? \"0\" : null)(\"background-size\", ctx.placeholder ? \"cover\" : null)(\"background-position\", ctx.placeholder ? \"50% 50%\" : null)(\"background-repeat\", ctx.placeholder ? \"no-repeat\" : null)(\"background-image\", ctx.placeholder ? ctx.generatePlaceholder(ctx.placeholder) : null)(\"filter\", ctx.placeholder && ctx.shouldBlurPlaceholder(ctx.placeholderConfig) ? \"blur(15px)\" : null);\n }\n },\n inputs: {\n ngSrc: [2, \"ngSrc\", \"ngSrc\", unwrapSafeUrl],\n ngSrcset: \"ngSrcset\",\n sizes: \"sizes\",\n width: [2, \"width\", \"width\", numberAttribute],\n height: [2, \"height\", \"height\", numberAttribute],\n loading: \"loading\",\n priority: [2, \"priority\", \"priority\", booleanAttribute],\n loaderParams: \"loaderParams\",\n disableOptimizedSrcset: [2, \"disableOptimizedSrcset\", \"disableOptimizedSrcset\", booleanAttribute],\n fill: [2, \"fill\", \"fill\", booleanAttribute],\n placeholder: [2, \"placeholder\", \"placeholder\", booleanOrUrlAttribute],\n placeholderConfig: \"placeholderConfig\",\n src: \"src\",\n srcset: \"srcset\"\n },\n features: [i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgOptimizedImage, [{\n type: Directive,\n args: [{\n selector: 'img[ngSrc]',\n host: {\n '[style.position]': 'fill ? \"absolute\" : null',\n '[style.width]': 'fill ? \"100%\" : null',\n '[style.height]': 'fill ? \"100%\" : null',\n '[style.inset]': 'fill ? \"0\" : null',\n '[style.background-size]': 'placeholder ? \"cover\" : null',\n '[style.background-position]': 'placeholder ? \"50% 50%\" : null',\n '[style.background-repeat]': 'placeholder ? \"no-repeat\" : null',\n '[style.background-image]': 'placeholder ? generatePlaceholder(placeholder) : null',\n '[style.filter]': `placeholder && shouldBlurPlaceholder(placeholderConfig) ? \"blur(${PLACEHOLDER_BLUR_AMOUNT}px)\" : null`\n }\n }]\n }], () => [], {\n ngSrc: [{\n type: Input,\n args: [{\n required: true,\n transform: unwrapSafeUrl\n }]\n }],\n ngSrcset: [{\n type: Input\n }],\n sizes: [{\n type: Input\n }],\n width: [{\n type: Input,\n args: [{\n transform: numberAttribute\n }]\n }],\n height: [{\n type: Input,\n args: [{\n transform: numberAttribute\n }]\n }],\n loading: [{\n type: Input\n }],\n priority: [{\n type: Input,\n args: [{\n transform: booleanAttribute\n }]\n }],\n loaderParams: [{\n type: Input\n }],\n disableOptimizedSrcset: [{\n type: Input,\n args: [{\n transform: booleanAttribute\n }]\n }],\n fill: [{\n type: Input,\n args: [{\n transform: booleanAttribute\n }]\n }],\n placeholder: [{\n type: Input,\n args: [{\n transform: booleanOrUrlAttribute\n }]\n }],\n placeholderConfig: [{\n type: Input\n }],\n src: [{\n type: Input\n }],\n srcset: [{\n type: Input\n }]\n });\n})();\n/***** Helpers *****/\n/**\n * Sorts provided config breakpoints and uses defaults.\n */\nfunction processConfig(config) {\n let sortedBreakpoints = {};\n if (config.breakpoints) {\n sortedBreakpoints.breakpoints = config.breakpoints.sort((a, b) => a - b);\n }\n return Object.assign({}, ɵIMAGE_CONFIG_DEFAULTS, config, sortedBreakpoints);\n}\n/***** Assert functions *****/\n/**\n * Verifies that there is no `src` set on a host element.\n */\nfunction assertNoConflictingSrc(dir) {\n if (dir.src) {\n throw new ɵRuntimeError(2950 /* RuntimeErrorCode.UNEXPECTED_SRC_ATTR */, `${imgDirectiveDetails(dir.ngSrc)} both \\`src\\` and \\`ngSrc\\` have been set. ` + `Supplying both of these attributes breaks lazy loading. ` + `The NgOptimizedImage directive sets \\`src\\` itself based on the value of \\`ngSrc\\`. ` + `To fix this, please remove the \\`src\\` attribute.`);\n }\n}\n/**\n * Verifies that there is no `srcset` set on a host element.\n */\nfunction assertNoConflictingSrcset(dir) {\n if (dir.srcset) {\n throw new ɵRuntimeError(2951 /* RuntimeErrorCode.UNEXPECTED_SRCSET_ATTR */, `${imgDirectiveDetails(dir.ngSrc)} both \\`srcset\\` and \\`ngSrcset\\` have been set. ` + `Supplying both of these attributes breaks lazy loading. ` + `The NgOptimizedImage directive sets \\`srcset\\` itself based on the value of ` + `\\`ngSrcset\\`. To fix this, please remove the \\`srcset\\` attribute.`);\n }\n}\n/**\n * Verifies that the `ngSrc` is not a Base64-encoded image.\n */\nfunction assertNotBase64Image(dir) {\n let ngSrc = dir.ngSrc.trim();\n if (ngSrc.startsWith('data:')) {\n if (ngSrc.length > BASE64_IMG_MAX_LENGTH_IN_ERROR) {\n ngSrc = ngSrc.substring(0, BASE64_IMG_MAX_LENGTH_IN_ERROR) + '...';\n }\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc, false)} \\`ngSrc\\` is a Base64-encoded string ` + `(${ngSrc}). NgOptimizedImage does not support Base64-encoded strings. ` + `To fix this, disable the NgOptimizedImage directive for this element ` + `by removing \\`ngSrc\\` and using a standard \\`src\\` attribute instead.`);\n }\n}\n/**\n * Verifies that the 'sizes' only includes responsive values.\n */\nfunction assertNoComplexSizes(dir) {\n let sizes = dir.sizes;\n if (sizes?.match(/((\\)|,)\\s|^)\\d+px/)) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc, false)} \\`sizes\\` was set to a string including ` + `pixel values. For automatic \\`srcset\\` generation, \\`sizes\\` must only include responsive ` + `values, such as \\`sizes=\"50vw\"\\` or \\`sizes=\"(min-width: 768px) 50vw, 100vw\"\\`. ` + `To fix this, modify the \\`sizes\\` attribute, or provide your own \\`ngSrcset\\` value directly.`);\n }\n}\nfunction assertValidPlaceholder(dir, imageLoader) {\n assertNoPlaceholderConfigWithoutPlaceholder(dir);\n assertNoRelativePlaceholderWithoutLoader(dir, imageLoader);\n assertNoOversizedDataUrl(dir);\n}\n/**\n * Verifies that placeholderConfig isn't being used without placeholder\n */\nfunction assertNoPlaceholderConfigWithoutPlaceholder(dir) {\n if (dir.placeholderConfig && !dir.placeholder) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc, false)} \\`placeholderConfig\\` options were provided for an ` + `image that does not use the \\`placeholder\\` attribute, and will have no effect.`);\n }\n}\n/**\n * Warns if a relative URL placeholder is specified, but no loader is present to provide the small\n * image.\n */\nfunction assertNoRelativePlaceholderWithoutLoader(dir, imageLoader) {\n if (dir.placeholder === true && imageLoader === noopImageLoader) {\n throw new ɵRuntimeError(2963 /* RuntimeErrorCode.MISSING_NECESSARY_LOADER */, `${imgDirectiveDetails(dir.ngSrc)} the \\`placeholder\\` attribute is set to true but ` + `no image loader is configured (i.e. the default one is being used), ` + `which would result in the same image being used for the primary image and its placeholder. ` + `To fix this, provide a loader or remove the \\`placeholder\\` attribute from the image.`);\n }\n}\n/**\n * Warns or throws an error if an oversized dataURL placeholder is provided.\n */\nfunction assertNoOversizedDataUrl(dir) {\n if (dir.placeholder && typeof dir.placeholder === 'string' && dir.placeholder.startsWith('data:')) {\n if (dir.placeholder.length > DATA_URL_ERROR_LIMIT) {\n throw new ɵRuntimeError(2965 /* RuntimeErrorCode.OVERSIZED_PLACEHOLDER */, `${imgDirectiveDetails(dir.ngSrc)} the \\`placeholder\\` attribute is set to a data URL which is longer ` + `than ${DATA_URL_ERROR_LIMIT} characters. This is strongly discouraged, as large inline placeholders ` + `directly increase the bundle size of Angular and hurt page load performance. To fix this, generate ` + `a smaller data URL placeholder.`);\n }\n if (dir.placeholder.length > DATA_URL_WARN_LIMIT) {\n console.warn(ɵformatRuntimeError(2965 /* RuntimeErrorCode.OVERSIZED_PLACEHOLDER */, `${imgDirectiveDetails(dir.ngSrc)} the \\`placeholder\\` attribute is set to a data URL which is longer ` + `than ${DATA_URL_WARN_LIMIT} characters. This is discouraged, as large inline placeholders ` + `directly increase the bundle size of Angular and hurt page load performance. For better loading performance, ` + `generate a smaller data URL placeholder.`));\n }\n }\n}\n/**\n * Verifies that the `ngSrc` is not a Blob URL.\n */\nfunction assertNotBlobUrl(dir) {\n const ngSrc = dir.ngSrc.trim();\n if (ngSrc.startsWith('blob:')) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} \\`ngSrc\\` was set to a blob URL (${ngSrc}). ` + `Blob URLs are not supported by the NgOptimizedImage directive. ` + `To fix this, disable the NgOptimizedImage directive for this element ` + `by removing \\`ngSrc\\` and using a regular \\`src\\` attribute instead.`);\n }\n}\n/**\n * Verifies that the input is set to a non-empty string.\n */\nfunction assertNonEmptyInput(dir, name, value) {\n const isString = typeof value === 'string';\n const isEmptyString = isString && value.trim() === '';\n if (!isString || isEmptyString) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} \\`${name}\\` has an invalid value ` + `(\\`${value}\\`). To fix this, change the value to a non-empty string.`);\n }\n}\n/**\n * Verifies that the `ngSrcset` is in a valid format, e.g. \"100w, 200w\" or \"1x, 2x\".\n */\nfunction assertValidNgSrcset(dir, value) {\n if (value == null) return;\n assertNonEmptyInput(dir, 'ngSrcset', value);\n const stringVal = value;\n const isValidWidthDescriptor = VALID_WIDTH_DESCRIPTOR_SRCSET.test(stringVal);\n const isValidDensityDescriptor = VALID_DENSITY_DESCRIPTOR_SRCSET.test(stringVal);\n if (isValidDensityDescriptor) {\n assertUnderDensityCap(dir, stringVal);\n }\n const isValidSrcset = isValidWidthDescriptor || isValidDensityDescriptor;\n if (!isValidSrcset) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} \\`ngSrcset\\` has an invalid value (\\`${value}\\`). ` + `To fix this, supply \\`ngSrcset\\` using a comma-separated list of one or more width ` + `descriptors (e.g. \"100w, 200w\") or density descriptors (e.g. \"1x, 2x\").`);\n }\n}\nfunction assertUnderDensityCap(dir, value) {\n const underDensityCap = value.split(',').every(num => num === '' || parseFloat(num) <= ABSOLUTE_SRCSET_DENSITY_CAP);\n if (!underDensityCap) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} the \\`ngSrcset\\` contains an unsupported image density:` + `\\`${value}\\`. NgOptimizedImage generally recommends a max image density of ` + `${RECOMMENDED_SRCSET_DENSITY_CAP}x but supports image densities up to ` + `${ABSOLUTE_SRCSET_DENSITY_CAP}x. The human eye cannot distinguish between image densities ` + `greater than ${RECOMMENDED_SRCSET_DENSITY_CAP}x - which makes them unnecessary for ` + `most use cases. Images that will be pinch-zoomed are typically the primary use case for ` + `${ABSOLUTE_SRCSET_DENSITY_CAP}x images. Please remove the high density descriptor and try again.`);\n }\n}\n/**\n * Creates a `RuntimeError` instance to represent a situation when an input is set after\n * the directive has initialized.\n */\nfunction postInitInputChangeError(dir, inputName) {\n let reason;\n if (inputName === 'width' || inputName === 'height') {\n reason = `Changing \\`${inputName}\\` may result in different attribute value ` + `applied to the underlying image element and cause layout shifts on a page.`;\n } else {\n reason = `Changing the \\`${inputName}\\` would have no effect on the underlying ` + `image element, because the resource loading has already occurred.`;\n }\n return new ɵRuntimeError(2953 /* RuntimeErrorCode.UNEXPECTED_INPUT_CHANGE */, `${imgDirectiveDetails(dir.ngSrc)} \\`${inputName}\\` was updated after initialization. ` + `The NgOptimizedImage directive will not react to this input change. ${reason} ` + `To fix this, either switch \\`${inputName}\\` to a static value ` + `or wrap the image element in an @if that is gated on the necessary value.`);\n}\n/**\n * Verify that none of the listed inputs has changed.\n */\nfunction assertNoPostInitInputChange(dir, changes, inputs) {\n inputs.forEach(input => {\n const isUpdated = changes.hasOwnProperty(input);\n if (isUpdated && !changes[input].isFirstChange()) {\n if (input === 'ngSrc') {\n // When the `ngSrc` input changes, we detect that only in the\n // `ngOnChanges` hook, thus the `ngSrc` is already set. We use\n // `ngSrc` in the error message, so we use a previous value, but\n // not the updated one in it.\n dir = {\n ngSrc: changes[input].previousValue\n };\n }\n throw postInitInputChangeError(dir, input);\n }\n });\n}\n/**\n * Verifies that a specified input is a number greater than 0.\n */\nfunction assertGreaterThanZero(dir, inputValue, inputName) {\n const validNumber = typeof inputValue === 'number' && inputValue > 0;\n const validString = typeof inputValue === 'string' && /^\\d+$/.test(inputValue.trim()) && parseInt(inputValue) > 0;\n if (!validNumber && !validString) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} \\`${inputName}\\` has an invalid value. ` + `To fix this, provide \\`${inputName}\\` as a number greater than 0.`);\n }\n}\n/**\n * Verifies that the rendered image is not visually distorted. Effectively this is checking:\n * - Whether the \"width\" and \"height\" attributes reflect the actual dimensions of the image.\n * - Whether image styling is \"correct\" (see below for a longer explanation).\n */\nfunction assertNoImageDistortion(dir, img, renderer) {\n const callback = () => {\n removeLoadListenerFn();\n removeErrorListenerFn();\n const computedStyle = window.getComputedStyle(img);\n let renderedWidth = parseFloat(computedStyle.getPropertyValue('width'));\n let renderedHeight = parseFloat(computedStyle.getPropertyValue('height'));\n const boxSizing = computedStyle.getPropertyValue('box-sizing');\n if (boxSizing === 'border-box') {\n const paddingTop = computedStyle.getPropertyValue('padding-top');\n const paddingRight = computedStyle.getPropertyValue('padding-right');\n const paddingBottom = computedStyle.getPropertyValue('padding-bottom');\n const paddingLeft = computedStyle.getPropertyValue('padding-left');\n renderedWidth -= parseFloat(paddingRight) + parseFloat(paddingLeft);\n renderedHeight -= parseFloat(paddingTop) + parseFloat(paddingBottom);\n }\n const renderedAspectRatio = renderedWidth / renderedHeight;\n const nonZeroRenderedDimensions = renderedWidth !== 0 && renderedHeight !== 0;\n const intrinsicWidth = img.naturalWidth;\n const intrinsicHeight = img.naturalHeight;\n const intrinsicAspectRatio = intrinsicWidth / intrinsicHeight;\n const suppliedWidth = dir.width;\n const suppliedHeight = dir.height;\n const suppliedAspectRatio = suppliedWidth / suppliedHeight;\n // Tolerance is used to account for the impact of subpixel rendering.\n // Due to subpixel rendering, the rendered, intrinsic, and supplied\n // aspect ratios of a correctly configured image may not exactly match.\n // For example, a `width=4030 height=3020` image might have a rendered\n // size of \"1062w, 796.48h\". (An aspect ratio of 1.334... vs. 1.333...)\n const inaccurateDimensions = Math.abs(suppliedAspectRatio - intrinsicAspectRatio) > ASPECT_RATIO_TOLERANCE;\n const stylingDistortion = nonZeroRenderedDimensions && Math.abs(intrinsicAspectRatio - renderedAspectRatio) > ASPECT_RATIO_TOLERANCE;\n if (inaccurateDimensions) {\n console.warn(ɵformatRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} the aspect ratio of the image does not match ` + `the aspect ratio indicated by the width and height attributes. ` + `\\nIntrinsic image size: ${intrinsicWidth}w x ${intrinsicHeight}h ` + `(aspect-ratio: ${round(intrinsicAspectRatio)}). \\nSupplied width and height attributes: ` + `${suppliedWidth}w x ${suppliedHeight}h (aspect-ratio: ${round(suppliedAspectRatio)}). ` + `\\nTo fix this, update the width and height attributes.`));\n } else if (stylingDistortion) {\n console.warn(ɵformatRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} the aspect ratio of the rendered image ` + `does not match the image's intrinsic aspect ratio. ` + `\\nIntrinsic image size: ${intrinsicWidth}w x ${intrinsicHeight}h ` + `(aspect-ratio: ${round(intrinsicAspectRatio)}). \\nRendered image size: ` + `${renderedWidth}w x ${renderedHeight}h (aspect-ratio: ` + `${round(renderedAspectRatio)}). \\nThis issue can occur if \"width\" and \"height\" ` + `attributes are added to an image without updating the corresponding ` + `image styling. To fix this, adjust image styling. In most cases, ` + `adding \"height: auto\" or \"width: auto\" to the image styling will fix ` + `this issue.`));\n } else if (!dir.ngSrcset && nonZeroRenderedDimensions) {\n // If `ngSrcset` hasn't been set, sanity check the intrinsic size.\n const recommendedWidth = RECOMMENDED_SRCSET_DENSITY_CAP * renderedWidth;\n const recommendedHeight = RECOMMENDED_SRCSET_DENSITY_CAP * renderedHeight;\n const oversizedWidth = intrinsicWidth - recommendedWidth >= OVERSIZED_IMAGE_TOLERANCE;\n const oversizedHeight = intrinsicHeight - recommendedHeight >= OVERSIZED_IMAGE_TOLERANCE;\n if (oversizedWidth || oversizedHeight) {\n console.warn(ɵformatRuntimeError(2960 /* RuntimeErrorCode.OVERSIZED_IMAGE */, `${imgDirectiveDetails(dir.ngSrc)} the intrinsic image is significantly ` + `larger than necessary. ` + `\\nRendered image size: ${renderedWidth}w x ${renderedHeight}h. ` + `\\nIntrinsic image size: ${intrinsicWidth}w x ${intrinsicHeight}h. ` + `\\nRecommended intrinsic image size: ${recommendedWidth}w x ${recommendedHeight}h. ` + `\\nNote: Recommended intrinsic image size is calculated assuming a maximum DPR of ` + `${RECOMMENDED_SRCSET_DENSITY_CAP}. To improve loading time, resize the image ` + `or consider using the \"ngSrcset\" and \"sizes\" attributes.`));\n }\n }\n };\n const removeLoadListenerFn = renderer.listen(img, 'load', callback);\n // We only listen to the `error` event to remove the `load` event listener because it will not be\n // fired if the image fails to load. This is done to prevent memory leaks in development mode\n // because image elements aren't garbage-collected properly. It happens because zone.js stores the\n // event listener directly on the element and closures capture `dir`.\n const removeErrorListenerFn = renderer.listen(img, 'error', () => {\n removeLoadListenerFn();\n removeErrorListenerFn();\n });\n callOnLoadIfImageIsLoaded(img, callback);\n}\n/**\n * Verifies that a specified input is set.\n */\nfunction assertNonEmptyWidthAndHeight(dir) {\n let missingAttributes = [];\n if (dir.width === undefined) missingAttributes.push('width');\n if (dir.height === undefined) missingAttributes.push('height');\n if (missingAttributes.length > 0) {\n throw new ɵRuntimeError(2954 /* RuntimeErrorCode.REQUIRED_INPUT_MISSING */, `${imgDirectiveDetails(dir.ngSrc)} these required attributes ` + `are missing: ${missingAttributes.map(attr => `\"${attr}\"`).join(', ')}. ` + `Including \"width\" and \"height\" attributes will prevent image-related layout shifts. ` + `To fix this, include \"width\" and \"height\" attributes on the image tag or turn on ` + `\"fill\" mode with the \\`fill\\` attribute.`);\n }\n}\n/**\n * Verifies that width and height are not set. Used in fill mode, where those attributes don't make\n * sense.\n */\nfunction assertEmptyWidthAndHeight(dir) {\n if (dir.width || dir.height) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} the attributes \\`height\\` and/or \\`width\\` are present ` + `along with the \\`fill\\` attribute. Because \\`fill\\` mode causes an image to fill its containing ` + `element, the size attributes have no effect and should be removed.`);\n }\n}\n/**\n * Verifies that the rendered image has a nonzero height. If the image is in fill mode, provides\n * guidance that this can be caused by the containing element's CSS position property.\n */\nfunction assertNonZeroRenderedHeight(dir, img, renderer) {\n const callback = () => {\n removeLoadListenerFn();\n removeErrorListenerFn();\n const renderedHeight = img.clientHeight;\n if (dir.fill && renderedHeight === 0) {\n console.warn(ɵformatRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} the height of the fill-mode image is zero. ` + `This is likely because the containing element does not have the CSS 'position' ` + `property set to one of the following: \"relative\", \"fixed\", or \"absolute\". ` + `To fix this problem, make sure the container element has the CSS 'position' ` + `property defined and the height of the element is not zero.`));\n }\n };\n const removeLoadListenerFn = renderer.listen(img, 'load', callback);\n // See comments in the `assertNoImageDistortion`.\n const removeErrorListenerFn = renderer.listen(img, 'error', () => {\n removeLoadListenerFn();\n removeErrorListenerFn();\n });\n callOnLoadIfImageIsLoaded(img, callback);\n}\n/**\n * Verifies that the `loading` attribute is set to a valid input &\n * is not used on priority images.\n */\nfunction assertValidLoadingInput(dir) {\n if (dir.loading && dir.priority) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} the \\`loading\\` attribute ` + `was used on an image that was marked \"priority\". ` + `Setting \\`loading\\` on priority images is not allowed ` + `because these images will always be eagerly loaded. ` + `To fix this, remove the “loading†attribute from the priority image.`);\n }\n const validInputs = ['auto', 'eager', 'lazy'];\n if (typeof dir.loading === 'string' && !validInputs.includes(dir.loading)) {\n throw new ɵRuntimeError(2952 /* RuntimeErrorCode.INVALID_INPUT */, `${imgDirectiveDetails(dir.ngSrc)} the \\`loading\\` attribute ` + `has an invalid value (\\`${dir.loading}\\`). ` + `To fix this, provide a valid value (\"lazy\", \"eager\", or \"auto\").`);\n }\n}\n/**\n * Warns if NOT using a loader (falling back to the generic loader) and\n * the image appears to be hosted on one of the image CDNs for which\n * we do have a built-in image loader. Suggests switching to the\n * built-in loader.\n *\n * @param ngSrc Value of the ngSrc attribute\n * @param imageLoader ImageLoader provided\n */\nfunction assertNotMissingBuiltInLoader(ngSrc, imageLoader) {\n if (imageLoader === noopImageLoader) {\n let builtInLoaderName = '';\n for (const loader of BUILT_IN_LOADERS) {\n if (loader.testUrl(ngSrc)) {\n builtInLoaderName = loader.name;\n break;\n }\n }\n if (builtInLoaderName) {\n console.warn(ɵformatRuntimeError(2962 /* RuntimeErrorCode.MISSING_BUILTIN_LOADER */, `NgOptimizedImage: It looks like your images may be hosted on the ` + `${builtInLoaderName} CDN, but your app is not using Angular's ` + `built-in loader for that CDN. We recommend switching to use ` + `the built-in by calling \\`provide${builtInLoaderName}Loader()\\` ` + `in your \\`providers\\` and passing it your instance's base URL. ` + `If you don't want to use the built-in loader, define a custom ` + `loader function using IMAGE_LOADER to silence this warning.`));\n }\n }\n}\n/**\n * Warns if ngSrcset is present and no loader is configured (i.e. the default one is being used).\n */\nfunction assertNoNgSrcsetWithoutLoader(dir, imageLoader) {\n if (dir.ngSrcset && imageLoader === noopImageLoader) {\n console.warn(ɵformatRuntimeError(2963 /* RuntimeErrorCode.MISSING_NECESSARY_LOADER */, `${imgDirectiveDetails(dir.ngSrc)} the \\`ngSrcset\\` attribute is present but ` + `no image loader is configured (i.e. the default one is being used), ` + `which would result in the same image being used for all configured sizes. ` + `To fix this, provide a loader or remove the \\`ngSrcset\\` attribute from the image.`));\n }\n}\n/**\n * Warns if loaderParams is present and no loader is configured (i.e. the default one is being\n * used).\n */\nfunction assertNoLoaderParamsWithoutLoader(dir, imageLoader) {\n if (dir.loaderParams && imageLoader === noopImageLoader) {\n console.warn(ɵformatRuntimeError(2963 /* RuntimeErrorCode.MISSING_NECESSARY_LOADER */, `${imgDirectiveDetails(dir.ngSrc)} the \\`loaderParams\\` attribute is present but ` + `no image loader is configured (i.e. the default one is being used), ` + `which means that the loaderParams data will not be consumed and will not affect the URL. ` + `To fix this, provide a custom loader or remove the \\`loaderParams\\` attribute from the image.`));\n }\n}\n/**\n * Warns if the priority attribute is used too often on page load\n */\nasync function assetPriorityCountBelowThreshold(appRef) {\n if (IMGS_WITH_PRIORITY_ATTR_COUNT === 0) {\n IMGS_WITH_PRIORITY_ATTR_COUNT++;\n await appRef.whenStable();\n if (IMGS_WITH_PRIORITY_ATTR_COUNT > PRIORITY_COUNT_THRESHOLD) {\n console.warn(ɵformatRuntimeError(2966 /* RuntimeErrorCode.TOO_MANY_PRIORITY_ATTRIBUTES */, `NgOptimizedImage: The \"priority\" attribute is set to true more than ${PRIORITY_COUNT_THRESHOLD} times (${IMGS_WITH_PRIORITY_ATTR_COUNT} times). ` + `Marking too many images as \"high\" priority can hurt your application's LCP (https://web.dev/lcp). ` + `\"Priority\" should only be set on the image expected to be the page's LCP element.`));\n }\n } else {\n IMGS_WITH_PRIORITY_ATTR_COUNT++;\n }\n}\n/**\n * Warns if placeholder's dimension are over a threshold.\n *\n * This assert function is meant to only run on the browser.\n */\nfunction assertPlaceholderDimensions(dir, imgElement) {\n const computedStyle = window.getComputedStyle(imgElement);\n let renderedWidth = parseFloat(computedStyle.getPropertyValue('width'));\n let renderedHeight = parseFloat(computedStyle.getPropertyValue('height'));\n if (renderedWidth > PLACEHOLDER_DIMENSION_LIMIT || renderedHeight > PLACEHOLDER_DIMENSION_LIMIT) {\n console.warn(ɵformatRuntimeError(2967 /* RuntimeErrorCode.PLACEHOLDER_DIMENSION_LIMIT_EXCEEDED */, `${imgDirectiveDetails(dir.ngSrc)} it uses a placeholder image, but at least one ` + `of the dimensions attribute (height or width) exceeds the limit of ${PLACEHOLDER_DIMENSION_LIMIT}px. ` + `To fix this, use a smaller image as a placeholder.`));\n }\n}\nfunction callOnLoadIfImageIsLoaded(img, callback) {\n // https://html.spec.whatwg.org/multipage/embedded-content.html#dom-img-complete\n // The spec defines that `complete` is truthy once its request state is fully available.\n // The image may already be available if it’s loaded from the browser cache.\n // In that case, the `load` event will not fire at all, meaning that all setup\n // callbacks listening for the `load` event will not be invoked.\n // In Safari, there is a known behavior where the `complete` property of an\n // `HTMLImageElement` may sometimes return `true` even when the image is not fully loaded.\n // Checking both `img.complete` and `img.naturalWidth` is the most reliable way to\n // determine if an image has been fully loaded, especially in browsers where the\n // `complete` property may return `true` prematurely.\n if (img.complete && img.naturalWidth) {\n callback();\n }\n}\nfunction round(input) {\n return Number.isInteger(input) ? input : input.toFixed(2);\n}\n// Transform function to handle SafeValue input for ngSrc. This doesn't do any sanitization,\n// as that is not needed for img.src and img.srcset. This transform is purely for compatibility.\nfunction unwrapSafeUrl(value) {\n if (typeof value === 'string') {\n return value;\n }\n return ɵunwrapSafeValue(value);\n}\n// Transform function to handle inputs which may be booleans, strings, or string representations\n// of boolean values. Used for the placeholder attribute.\nfunction booleanOrUrlAttribute(value) {\n if (typeof value === 'string' && value !== 'true' && value !== 'false' && value !== '') {\n return value;\n }\n return booleanAttribute(value);\n}\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the common package.\n */\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of this package.\n */\n// This file only reexports content of the `src` folder. Keep it that way.\n\n// This file is not used to build this module. It is only used during editing\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { APP_BASE_HREF, AsyncPipe, BrowserPlatformLocation, CommonModule, CurrencyPipe, DATE_PIPE_DEFAULT_OPTIONS, DATE_PIPE_DEFAULT_TIMEZONE, DOCUMENT, DatePipe, DecimalPipe, FormStyle, FormatWidth, HashLocationStrategy, I18nPluralPipe, I18nSelectPipe, IMAGE_LOADER, JsonPipe, KeyValuePipe, LOCATION_INITIALIZED, Location, LocationStrategy, LowerCasePipe, NgClass, NgComponentOutlet, NgForOf as NgFor, NgForOf, NgForOfContext, NgIf, NgIfContext, NgLocaleLocalization, NgLocalization, NgOptimizedImage, NgPlural, NgPluralCase, NgStyle, NgSwitch, NgSwitchCase, NgSwitchDefault, NgTemplateOutlet, NumberFormatStyle, NumberSymbol, PRECONNECT_CHECK_BLOCKLIST, PathLocationStrategy, PercentPipe, PlatformLocation, Plural, SlicePipe, TitleCasePipe, TranslationWidth, UpperCasePipe, VERSION, ViewportScroller, WeekDay, XhrFactory, formatCurrency, formatDate, formatNumber, formatPercent, getCurrencySymbol, getLocaleCurrencyCode, getLocaleCurrencyName, getLocaleCurrencySymbol, getLocaleDateFormat, getLocaleDateTimeFormat, getLocaleDayNames, getLocaleDayPeriods, getLocaleDirection, getLocaleEraNames, getLocaleExtraDayPeriodRules, getLocaleExtraDayPeriods, getLocaleFirstDayOfWeek, getLocaleId, getLocaleMonthNames, getLocaleNumberFormat, getLocaleNumberSymbol, getLocalePluralCase, getLocaleTimeFormat, getLocaleWeekEndRange, getNumberOfCurrencyDigits, isPlatformBrowser, isPlatformServer, provideCloudflareLoader, provideCloudinaryLoader, provideImageKitLoader, provideImgixLoader, provideNetlifyLoader, registerLocaleData, DomAdapter as ɵDomAdapter, NullViewportScroller as ɵNullViewportScroller, PLATFORM_BROWSER_ID as ɵPLATFORM_BROWSER_ID, PLATFORM_SERVER_ID as ɵPLATFORM_SERVER_ID, PlatformNavigation as ɵPlatformNavigation, getDOM as ɵgetDOM, normalizeQueryParams as ɵnormalizeQueryParams, parseCookieValue as ɵparseCookieValue, setRootDomAdapter as ɵsetRootDomAdapter };\n","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\nimport * as i0 from '@angular/core';\nimport { ɵRuntimeError, Injectable, InjectionToken, inject, NgZone, runInInjectionContext, ɵPendingTasksInternal, PLATFORM_ID, ɵConsole, ɵformatRuntimeError, Inject, makeEnvironmentProviders, NgModule, assertInInjectionContext, Injector, ɵResourceImpl, linkedSignal, computed, ResourceStatus, signal, TransferState, makeStateKey, ɵperformanceMarkFeature, APP_BOOTSTRAP_LISTENER, ApplicationRef, ɵtruncateMiddle } from '@angular/core';\nimport { of, Observable, from } from 'rxjs';\nimport { concatMap, filter, map, finalize, switchMap, tap } from 'rxjs/operators';\nimport * as i1 from '@angular/common';\nimport { isPlatformServer, DOCUMENT, ɵparseCookieValue } from '@angular/common';\n\n/**\n * Transforms an `HttpRequest` into a stream of `HttpEvent`s, one of which will likely be a\n * `HttpResponse`.\n *\n * `HttpHandler` is injectable. When injected, the handler instance dispatches requests to the\n * first interceptor in the chain, which dispatches to the second, etc, eventually reaching the\n * `HttpBackend`.\n *\n * In an `HttpInterceptor`, the `HttpHandler` parameter is the next interceptor in the chain.\n *\n * @publicApi\n */\nclass HttpHandler {}\n/**\n * A final `HttpHandler` which will dispatch the request via browser HTTP APIs to a backend.\n *\n * Interceptors sit between the `HttpClient` interface and the `HttpBackend`.\n *\n * When injected, `HttpBackend` dispatches requests directly to the backend, without going\n * through the interceptor chain.\n *\n * @publicApi\n */\nclass HttpBackend {}\n\n/**\n * Represents the header configuration options for an HTTP request.\n * Instances are immutable. Modifying methods return a cloned\n * instance with the change. The original object is never changed.\n *\n * @publicApi\n */\nclass HttpHeaders {\n /**\n * Internal map of lowercase header names to values.\n */\n // TODO(issue/24571): remove '!'.\n headers;\n /**\n * Internal map of lowercased header names to the normalized\n * form of the name (the form seen first).\n */\n normalizedNames = new Map();\n /**\n * Complete the lazy initialization of this object (needed before reading).\n */\n lazyInit;\n /**\n * Queued updates to be materialized the next initialization.\n */\n lazyUpdate = null;\n /** Constructs a new HTTP header object with the given values.*/\n constructor(headers) {\n if (!headers) {\n this.headers = new Map();\n } else if (typeof headers === 'string') {\n this.lazyInit = () => {\n this.headers = new Map();\n headers.split('\\n').forEach(line => {\n const index = line.indexOf(':');\n if (index > 0) {\n const name = line.slice(0, index);\n const value = line.slice(index + 1).trim();\n this.addHeaderEntry(name, value);\n }\n });\n };\n } else if (typeof Headers !== 'undefined' && headers instanceof Headers) {\n this.headers = new Map();\n headers.forEach((value, name) => {\n this.addHeaderEntry(name, value);\n });\n } else {\n this.lazyInit = () => {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n assertValidHeaders(headers);\n }\n this.headers = new Map();\n Object.entries(headers).forEach(([name, values]) => {\n this.setHeaderEntries(name, values);\n });\n };\n }\n }\n /**\n * Checks for existence of a given header.\n *\n * @param name The header name to check for existence.\n *\n * @returns True if the header exists, false otherwise.\n */\n has(name) {\n this.init();\n return this.headers.has(name.toLowerCase());\n }\n /**\n * Retrieves the first value of a given header.\n *\n * @param name The header name.\n *\n * @returns The value string if the header exists, null otherwise\n */\n get(name) {\n this.init();\n const values = this.headers.get(name.toLowerCase());\n return values && values.length > 0 ? values[0] : null;\n }\n /**\n * Retrieves the names of the headers.\n *\n * @returns A list of header names.\n */\n keys() {\n this.init();\n return Array.from(this.normalizedNames.values());\n }\n /**\n * Retrieves a list of values for a given header.\n *\n * @param name The header name from which to retrieve values.\n *\n * @returns A string of values if the header exists, null otherwise.\n */\n getAll(name) {\n this.init();\n return this.headers.get(name.toLowerCase()) || null;\n }\n /**\n * Appends a new value to the existing set of values for a header\n * and returns them in a clone of the original instance.\n *\n * @param name The header name for which to append the values.\n * @param value The value to append.\n *\n * @returns A clone of the HTTP headers object with the value appended to the given header.\n */\n append(name, value) {\n return this.clone({\n name,\n value,\n op: 'a'\n });\n }\n /**\n * Sets or modifies a value for a given header in a clone of the original instance.\n * If the header already exists, its value is replaced with the given value\n * in the returned object.\n *\n * @param name The header name.\n * @param value The value or values to set or override for the given header.\n *\n * @returns A clone of the HTTP headers object with the newly set header value.\n */\n set(name, value) {\n return this.clone({\n name,\n value,\n op: 's'\n });\n }\n /**\n * Deletes values for a given header in a clone of the original instance.\n *\n * @param name The header name.\n * @param value The value or values to delete for the given header.\n *\n * @returns A clone of the HTTP headers object with the given value deleted.\n */\n delete(name, value) {\n return this.clone({\n name,\n value,\n op: 'd'\n });\n }\n maybeSetNormalizedName(name, lcName) {\n if (!this.normalizedNames.has(lcName)) {\n this.normalizedNames.set(lcName, name);\n }\n }\n init() {\n if (!!this.lazyInit) {\n if (this.lazyInit instanceof HttpHeaders) {\n this.copyFrom(this.lazyInit);\n } else {\n this.lazyInit();\n }\n this.lazyInit = null;\n if (!!this.lazyUpdate) {\n this.lazyUpdate.forEach(update => this.applyUpdate(update));\n this.lazyUpdate = null;\n }\n }\n }\n copyFrom(other) {\n other.init();\n Array.from(other.headers.keys()).forEach(key => {\n this.headers.set(key, other.headers.get(key));\n this.normalizedNames.set(key, other.normalizedNames.get(key));\n });\n }\n clone(update) {\n const clone = new HttpHeaders();\n clone.lazyInit = !!this.lazyInit && this.lazyInit instanceof HttpHeaders ? this.lazyInit : this;\n clone.lazyUpdate = (this.lazyUpdate || []).concat([update]);\n return clone;\n }\n applyUpdate(update) {\n const key = update.name.toLowerCase();\n switch (update.op) {\n case 'a':\n case 's':\n let value = update.value;\n if (typeof value === 'string') {\n value = [value];\n }\n if (value.length === 0) {\n return;\n }\n this.maybeSetNormalizedName(update.name, key);\n const base = (update.op === 'a' ? this.headers.get(key) : undefined) || [];\n base.push(...value);\n this.headers.set(key, base);\n break;\n case 'd':\n const toDelete = update.value;\n if (!toDelete) {\n this.headers.delete(key);\n this.normalizedNames.delete(key);\n } else {\n let existing = this.headers.get(key);\n if (!existing) {\n return;\n }\n existing = existing.filter(value => toDelete.indexOf(value) === -1);\n if (existing.length === 0) {\n this.headers.delete(key);\n this.normalizedNames.delete(key);\n } else {\n this.headers.set(key, existing);\n }\n }\n break;\n }\n }\n addHeaderEntry(name, value) {\n const key = name.toLowerCase();\n this.maybeSetNormalizedName(name, key);\n if (this.headers.has(key)) {\n this.headers.get(key).push(value);\n } else {\n this.headers.set(key, [value]);\n }\n }\n setHeaderEntries(name, values) {\n const headerValues = (Array.isArray(values) ? values : [values]).map(value => value.toString());\n const key = name.toLowerCase();\n this.headers.set(key, headerValues);\n this.maybeSetNormalizedName(name, key);\n }\n /**\n * @internal\n */\n forEach(fn) {\n this.init();\n Array.from(this.normalizedNames.keys()).forEach(key => fn(this.normalizedNames.get(key), this.headers.get(key)));\n }\n}\n/**\n * Verifies that the headers object has the right shape: the values\n * must be either strings, numbers or arrays. Throws an error if an invalid\n * header value is present.\n */\nfunction assertValidHeaders(headers) {\n for (const [key, value] of Object.entries(headers)) {\n if (!(typeof value === 'string' || typeof value === 'number') && !Array.isArray(value)) {\n throw new Error(`Unexpected value of the \\`${key}\\` header provided. ` + `Expecting either a string, a number or an array, but got: \\`${value}\\`.`);\n }\n }\n}\n\n/**\n * Provides encoding and decoding of URL parameter and query-string values.\n *\n * Serializes and parses URL parameter keys and values to encode and decode them.\n * If you pass URL query parameters without encoding,\n * the query parameters can be misinterpreted at the receiving end.\n *\n *\n * @publicApi\n */\nclass HttpUrlEncodingCodec {\n /**\n * Encodes a key name for a URL parameter or query-string.\n * @param key The key name.\n * @returns The encoded key name.\n */\n encodeKey(key) {\n return standardEncoding(key);\n }\n /**\n * Encodes the value of a URL parameter or query-string.\n * @param value The value.\n * @returns The encoded value.\n */\n encodeValue(value) {\n return standardEncoding(value);\n }\n /**\n * Decodes an encoded URL parameter or query-string key.\n * @param key The encoded key name.\n * @returns The decoded key name.\n */\n decodeKey(key) {\n return decodeURIComponent(key);\n }\n /**\n * Decodes an encoded URL parameter or query-string value.\n * @param value The encoded value.\n * @returns The decoded value.\n */\n decodeValue(value) {\n return decodeURIComponent(value);\n }\n}\nfunction paramParser(rawParams, codec) {\n const map = new Map();\n if (rawParams.length > 0) {\n // The `window.location.search` can be used while creating an instance of the `HttpParams` class\n // (e.g. `new HttpParams({ fromString: window.location.search })`). The `window.location.search`\n // may start with the `?` char, so we strip it if it's present.\n const params = rawParams.replace(/^\\?/, '').split('&');\n params.forEach(param => {\n const eqIdx = param.indexOf('=');\n const [key, val] = eqIdx == -1 ? [codec.decodeKey(param), ''] : [codec.decodeKey(param.slice(0, eqIdx)), codec.decodeValue(param.slice(eqIdx + 1))];\n const list = map.get(key) || [];\n list.push(val);\n map.set(key, list);\n });\n }\n return map;\n}\n/**\n * Encode input string with standard encodeURIComponent and then un-encode specific characters.\n */\nconst STANDARD_ENCODING_REGEX = /%(\\d[a-f0-9])/gi;\nconst STANDARD_ENCODING_REPLACEMENTS = {\n '40': '@',\n '3A': ':',\n '24': '$',\n '2C': ',',\n '3B': ';',\n '3D': '=',\n '3F': '?',\n '2F': '/'\n};\nfunction standardEncoding(v) {\n return encodeURIComponent(v).replace(STANDARD_ENCODING_REGEX, (s, t) => STANDARD_ENCODING_REPLACEMENTS[t] ?? s);\n}\nfunction valueToString(value) {\n return `${value}`;\n}\n/**\n * An HTTP request/response body that represents serialized parameters,\n * per the MIME type `application/x-www-form-urlencoded`.\n *\n * This class is immutable; all mutation operations return a new instance.\n *\n * @publicApi\n */\nclass HttpParams {\n map;\n encoder;\n updates = null;\n cloneFrom = null;\n constructor(options = {}) {\n this.encoder = options.encoder || new HttpUrlEncodingCodec();\n if (options.fromString) {\n if (options.fromObject) {\n throw new ɵRuntimeError(2805 /* RuntimeErrorCode.CANNOT_SPECIFY_BOTH_FROM_STRING_AND_FROM_OBJECT */, ngDevMode && 'Cannot specify both fromString and fromObject.');\n }\n this.map = paramParser(options.fromString, this.encoder);\n } else if (!!options.fromObject) {\n this.map = new Map();\n Object.keys(options.fromObject).forEach(key => {\n const value = options.fromObject[key];\n // convert the values to strings\n const values = Array.isArray(value) ? value.map(valueToString) : [valueToString(value)];\n this.map.set(key, values);\n });\n } else {\n this.map = null;\n }\n }\n /**\n * Reports whether the body includes one or more values for a given parameter.\n * @param param The parameter name.\n * @returns True if the parameter has one or more values,\n * false if it has no value or is not present.\n */\n has(param) {\n this.init();\n return this.map.has(param);\n }\n /**\n * Retrieves the first value for a parameter.\n * @param param The parameter name.\n * @returns The first value of the given parameter,\n * or `null` if the parameter is not present.\n */\n get(param) {\n this.init();\n const res = this.map.get(param);\n return !!res ? res[0] : null;\n }\n /**\n * Retrieves all values for a parameter.\n * @param param The parameter name.\n * @returns All values in a string array,\n * or `null` if the parameter not present.\n */\n getAll(param) {\n this.init();\n return this.map.get(param) || null;\n }\n /**\n * Retrieves all the parameters for this body.\n * @returns The parameter names in a string array.\n */\n keys() {\n this.init();\n return Array.from(this.map.keys());\n }\n /**\n * Appends a new value to existing values for a parameter.\n * @param param The parameter name.\n * @param value The new value to add.\n * @return A new body with the appended value.\n */\n append(param, value) {\n return this.clone({\n param,\n value,\n op: 'a'\n });\n }\n /**\n * Constructs a new body with appended values for the given parameter name.\n * @param params parameters and values\n * @return A new body with the new value.\n */\n appendAll(params) {\n const updates = [];\n Object.keys(params).forEach(param => {\n const value = params[param];\n if (Array.isArray(value)) {\n value.forEach(_value => {\n updates.push({\n param,\n value: _value,\n op: 'a'\n });\n });\n } else {\n updates.push({\n param,\n value: value,\n op: 'a'\n });\n }\n });\n return this.clone(updates);\n }\n /**\n * Replaces the value for a parameter.\n * @param param The parameter name.\n * @param value The new value.\n * @return A new body with the new value.\n */\n set(param, value) {\n return this.clone({\n param,\n value,\n op: 's'\n });\n }\n /**\n * Removes a given value or all values from a parameter.\n * @param param The parameter name.\n * @param value The value to remove, if provided.\n * @return A new body with the given value removed, or with all values\n * removed if no value is specified.\n */\n delete(param, value) {\n return this.clone({\n param,\n value,\n op: 'd'\n });\n }\n /**\n * Serializes the body to an encoded string, where key-value pairs (separated by `=`) are\n * separated by `&`s.\n */\n toString() {\n this.init();\n return this.keys().map(key => {\n const eKey = this.encoder.encodeKey(key);\n // `a: ['1']` produces `'a=1'`\n // `b: []` produces `''`\n // `c: ['1', '2']` produces `'c=1&c=2'`\n return this.map.get(key).map(value => eKey + '=' + this.encoder.encodeValue(value)).join('&');\n })\n // filter out empty values because `b: []` produces `''`\n // which results in `a=1&&c=1&c=2` instead of `a=1&c=1&c=2` if we don't\n .filter(param => param !== '').join('&');\n }\n clone(update) {\n const clone = new HttpParams({\n encoder: this.encoder\n });\n clone.cloneFrom = this.cloneFrom || this;\n clone.updates = (this.updates || []).concat(update);\n return clone;\n }\n init() {\n if (this.map === null) {\n this.map = new Map();\n }\n if (this.cloneFrom !== null) {\n this.cloneFrom.init();\n this.cloneFrom.keys().forEach(key => this.map.set(key, this.cloneFrom.map.get(key)));\n this.updates.forEach(update => {\n switch (update.op) {\n case 'a':\n case 's':\n const base = (update.op === 'a' ? this.map.get(update.param) : undefined) || [];\n base.push(valueToString(update.value));\n this.map.set(update.param, base);\n break;\n case 'd':\n if (update.value !== undefined) {\n let base = this.map.get(update.param) || [];\n const idx = base.indexOf(valueToString(update.value));\n if (idx !== -1) {\n base.splice(idx, 1);\n }\n if (base.length > 0) {\n this.map.set(update.param, base);\n } else {\n this.map.delete(update.param);\n }\n } else {\n this.map.delete(update.param);\n break;\n }\n }\n });\n this.cloneFrom = this.updates = null;\n }\n }\n}\n\n/**\n * A token used to manipulate and access values stored in `HttpContext`.\n *\n * @publicApi\n */\nclass HttpContextToken {\n defaultValue;\n constructor(defaultValue) {\n this.defaultValue = defaultValue;\n }\n}\n/**\n * Http context stores arbitrary user defined values and ensures type safety without\n * actually knowing the types. It is backed by a `Map` and guarantees that keys do not clash.\n *\n * This context is mutable and is shared between cloned requests unless explicitly specified.\n *\n * @usageNotes\n *\n * ### Usage Example\n *\n * ```ts\n * // inside cache.interceptors.ts\n * export const IS_CACHE_ENABLED = new HttpContextToken<boolean>(() => false);\n *\n * export class CacheInterceptor implements HttpInterceptor {\n *\n * intercept(req: HttpRequest<any>, delegate: HttpHandler): Observable<HttpEvent<any>> {\n * if (req.context.get(IS_CACHE_ENABLED) === true) {\n * return ...;\n * }\n * return delegate.handle(req);\n * }\n * }\n *\n * // inside a service\n *\n * this.httpClient.get('/api/weather', {\n * context: new HttpContext().set(IS_CACHE_ENABLED, true)\n * }).subscribe(...);\n * ```\n *\n * @publicApi\n */\nclass HttpContext {\n map = new Map();\n /**\n * Store a value in the context. If a value is already present it will be overwritten.\n *\n * @param token The reference to an instance of `HttpContextToken`.\n * @param value The value to store.\n *\n * @returns A reference to itself for easy chaining.\n */\n set(token, value) {\n this.map.set(token, value);\n return this;\n }\n /**\n * Retrieve the value associated with the given token.\n *\n * @param token The reference to an instance of `HttpContextToken`.\n *\n * @returns The stored value or default if one is defined.\n */\n get(token) {\n if (!this.map.has(token)) {\n this.map.set(token, token.defaultValue());\n }\n return this.map.get(token);\n }\n /**\n * Delete the value associated with the given token.\n *\n * @param token The reference to an instance of `HttpContextToken`.\n *\n * @returns A reference to itself for easy chaining.\n */\n delete(token) {\n this.map.delete(token);\n return this;\n }\n /**\n * Checks for existence of a given token.\n *\n * @param token The reference to an instance of `HttpContextToken`.\n *\n * @returns True if the token exists, false otherwise.\n */\n has(token) {\n return this.map.has(token);\n }\n /**\n * @returns a list of tokens currently stored in the context.\n */\n keys() {\n return this.map.keys();\n }\n}\n\n/**\n * Determine whether the given HTTP method may include a body.\n */\nfunction mightHaveBody(method) {\n switch (method) {\n case 'DELETE':\n case 'GET':\n case 'HEAD':\n case 'OPTIONS':\n case 'JSONP':\n return false;\n default:\n return true;\n }\n}\n/**\n * Safely assert whether the given value is an ArrayBuffer.\n *\n * In some execution environments ArrayBuffer is not defined.\n */\nfunction isArrayBuffer(value) {\n return typeof ArrayBuffer !== 'undefined' && value instanceof ArrayBuffer;\n}\n/**\n * Safely assert whether the given value is a Blob.\n *\n * In some execution environments Blob is not defined.\n */\nfunction isBlob(value) {\n return typeof Blob !== 'undefined' && value instanceof Blob;\n}\n/**\n * Safely assert whether the given value is a FormData instance.\n *\n * In some execution environments FormData is not defined.\n */\nfunction isFormData(value) {\n return typeof FormData !== 'undefined' && value instanceof FormData;\n}\n/**\n * Safely assert whether the given value is a URLSearchParams instance.\n *\n * In some execution environments URLSearchParams is not defined.\n */\nfunction isUrlSearchParams(value) {\n return typeof URLSearchParams !== 'undefined' && value instanceof URLSearchParams;\n}\n/**\n * `Content-Type` is an HTTP header used to indicate the media type\n * (also known as MIME type) of the resource being sent to the client\n * or received from the server.\n */\nconst CONTENT_TYPE_HEADER = 'Content-Type';\n/**\n * The `Accept` header is an HTTP request header that indicates the media types\n * (or content types) the client is willing to receive from the server.\n */\nconst ACCEPT_HEADER = 'Accept';\n/**\n * `X-Request-URL` is a custom HTTP header used in older browser versions,\n * including Firefox (< 32), Chrome (< 37), Safari (< 8), and Internet Explorer,\n * to include the full URL of the request in cross-origin requests.\n */\nconst X_REQUEST_URL_HEADER = 'X-Request-URL';\n/**\n * `text/plain` is a content type used to indicate that the content being\n * sent is plain text with no special formatting or structured data\n * like HTML, XML, or JSON.\n */\nconst TEXT_CONTENT_TYPE = 'text/plain';\n/**\n * `application/json` is a content type used to indicate that the content\n * being sent is in the JSON format.\n */\nconst JSON_CONTENT_TYPE = 'application/json';\n/**\n * `application/json, text/plain, *\\/*` is a content negotiation string often seen in the\n * Accept header of HTTP requests. It indicates the types of content the client is willing\n * to accept from the server, with a preference for `application/json` and `text/plain`,\n * but also accepting any other type (*\\/*).\n */\nconst ACCEPT_HEADER_VALUE = `${JSON_CONTENT_TYPE}, ${TEXT_CONTENT_TYPE}, */*`;\n/**\n * An outgoing HTTP request with an optional typed body.\n *\n * `HttpRequest` represents an outgoing request, including URL, method,\n * headers, body, and other request configuration options. Instances should be\n * assumed to be immutable. To modify a `HttpRequest`, the `clone`\n * method should be used.\n *\n * @publicApi\n */\nclass HttpRequest {\n url;\n /**\n * The request body, or `null` if one isn't set.\n *\n * Bodies are not enforced to be immutable, as they can include a reference to any\n * user-defined data type. However, interceptors should take care to preserve\n * idempotence by treating them as such.\n */\n body = null;\n /**\n * Outgoing headers for this request.\n */\n // TODO(issue/24571): remove '!'.\n headers;\n /**\n * Shared and mutable context that can be used by interceptors\n */\n context;\n /**\n * Whether this request should be made in a way that exposes progress events.\n *\n * Progress events are expensive (change detection runs on each event) and so\n * they should only be requested if the consumer intends to monitor them.\n *\n * Note: The `FetchBackend` doesn't support progress report on uploads.\n */\n reportProgress = false;\n /**\n * Whether this request should be sent with outgoing credentials (cookies).\n */\n withCredentials = false;\n /**\n * The expected response type of the server.\n *\n * This is used to parse the response appropriately before returning it to\n * the requestee.\n */\n responseType = 'json';\n /**\n * The outgoing HTTP request method.\n */\n method;\n /**\n * Outgoing URL parameters.\n *\n * To pass a string representation of HTTP parameters in the URL-query-string format,\n * the `HttpParamsOptions`' `fromString` may be used. For example:\n *\n * ```ts\n * new HttpParams({fromString: 'angular=awesome'})\n * ```\n */\n // TODO(issue/24571): remove '!'.\n params;\n /**\n * The outgoing URL with all URL parameters set.\n */\n urlWithParams;\n /**\n * The HttpTransferCache option for the request\n */\n transferCache;\n constructor(method, url, third, fourth) {\n this.url = url;\n this.method = method.toUpperCase();\n // Next, need to figure out which argument holds the HttpRequestInit\n // options, if any.\n let options;\n // Check whether a body argument is expected. The only valid way to omit\n // the body argument is to use a known no-body method like GET.\n if (mightHaveBody(this.method) || !!fourth) {\n // Body is the third argument, options are the fourth.\n this.body = third !== undefined ? third : null;\n options = fourth;\n } else {\n // No body required, options are the third argument. The body stays null.\n options = third;\n }\n // If options have been passed, interpret them.\n if (options) {\n // Normalize reportProgress and withCredentials.\n this.reportProgress = !!options.reportProgress;\n this.withCredentials = !!options.withCredentials;\n // Override default response type of 'json' if one is provided.\n if (!!options.responseType) {\n this.responseType = options.responseType;\n }\n // Override headers if they're provided.\n if (!!options.headers) {\n this.headers = options.headers;\n }\n if (!!options.context) {\n this.context = options.context;\n }\n if (!!options.params) {\n this.params = options.params;\n }\n // We do want to assign transferCache even if it's falsy (false is valid value)\n this.transferCache = options.transferCache;\n }\n // If no headers have been passed in, construct a new HttpHeaders instance.\n this.headers ??= new HttpHeaders();\n // If no context have been passed in, construct a new HttpContext instance.\n this.context ??= new HttpContext();\n // If no parameters have been passed in, construct a new HttpUrlEncodedParams instance.\n if (!this.params) {\n this.params = new HttpParams();\n this.urlWithParams = url;\n } else {\n // Encode the parameters to a string in preparation for inclusion in the URL.\n const params = this.params.toString();\n if (params.length === 0) {\n // No parameters, the visible URL is just the URL given at creation time.\n this.urlWithParams = url;\n } else {\n // Does the URL already have query parameters? Look for '?'.\n const qIdx = url.indexOf('?');\n // There are 3 cases to handle:\n // 1) No existing parameters -> append '?' followed by params.\n // 2) '?' exists and is followed by existing query string ->\n // append '&' followed by params.\n // 3) '?' exists at the end of the url -> append params directly.\n // This basically amounts to determining the character, if any, with\n // which to join the URL and parameters.\n const sep = qIdx === -1 ? '?' : qIdx < url.length - 1 ? '&' : '';\n this.urlWithParams = url + sep + params;\n }\n }\n }\n /**\n * Transform the free-form body into a serialized format suitable for\n * transmission to the server.\n */\n serializeBody() {\n // If no body is present, no need to serialize it.\n if (this.body === null) {\n return null;\n }\n // Check whether the body is already in a serialized form. If so,\n // it can just be returned directly.\n if (typeof this.body === 'string' || isArrayBuffer(this.body) || isBlob(this.body) || isFormData(this.body) || isUrlSearchParams(this.body)) {\n return this.body;\n }\n // Check whether the body is an instance of HttpUrlEncodedParams.\n if (this.body instanceof HttpParams) {\n return this.body.toString();\n }\n // Check whether the body is an object or array, and serialize with JSON if so.\n if (typeof this.body === 'object' || typeof this.body === 'boolean' || Array.isArray(this.body)) {\n return JSON.stringify(this.body);\n }\n // Fall back on toString() for everything else.\n return this.body.toString();\n }\n /**\n * Examine the body and attempt to infer an appropriate MIME type\n * for it.\n *\n * If no such type can be inferred, this method will return `null`.\n */\n detectContentTypeHeader() {\n // An empty body has no content type.\n if (this.body === null) {\n return null;\n }\n // FormData bodies rely on the browser's content type assignment.\n if (isFormData(this.body)) {\n return null;\n }\n // Blobs usually have their own content type. If it doesn't, then\n // no type can be inferred.\n if (isBlob(this.body)) {\n return this.body.type || null;\n }\n // Array buffers have unknown contents and thus no type can be inferred.\n if (isArrayBuffer(this.body)) {\n return null;\n }\n // Technically, strings could be a form of JSON data, but it's safe enough\n // to assume they're plain strings.\n if (typeof this.body === 'string') {\n return TEXT_CONTENT_TYPE;\n }\n // `HttpUrlEncodedParams` has its own content-type.\n if (this.body instanceof HttpParams) {\n return 'application/x-www-form-urlencoded;charset=UTF-8';\n }\n // Arrays, objects, boolean and numbers will be encoded as JSON.\n if (typeof this.body === 'object' || typeof this.body === 'number' || typeof this.body === 'boolean') {\n return JSON_CONTENT_TYPE;\n }\n // No type could be inferred.\n return null;\n }\n clone(update = {}) {\n // For method, url, and responseType, take the current value unless\n // it is overridden in the update hash.\n const method = update.method || this.method;\n const url = update.url || this.url;\n const responseType = update.responseType || this.responseType;\n // Carefully handle the transferCache to differentiate between\n // `false` and `undefined` in the update args.\n const transferCache = update.transferCache ?? this.transferCache;\n // The body is somewhat special - a `null` value in update.body means\n // whatever current body is present is being overridden with an empty\n // body, whereas an `undefined` value in update.body implies no\n // override.\n const body = update.body !== undefined ? update.body : this.body;\n // Carefully handle the boolean options to differentiate between\n // `false` and `undefined` in the update args.\n const withCredentials = update.withCredentials ?? this.withCredentials;\n const reportProgress = update.reportProgress ?? this.reportProgress;\n // Headers and params may be appended to if `setHeaders` or\n // `setParams` are used.\n let headers = update.headers || this.headers;\n let params = update.params || this.params;\n // Pass on context if needed\n const context = update.context ?? this.context;\n // Check whether the caller has asked to add headers.\n if (update.setHeaders !== undefined) {\n // Set every requested header.\n headers = Object.keys(update.setHeaders).reduce((headers, name) => headers.set(name, update.setHeaders[name]), headers);\n }\n // Check whether the caller has asked to set params.\n if (update.setParams) {\n // Set every requested param.\n params = Object.keys(update.setParams).reduce((params, param) => params.set(param, update.setParams[param]), params);\n }\n // Finally, construct the new HttpRequest using the pieces from above.\n return new HttpRequest(method, url, body, {\n params,\n headers,\n context,\n reportProgress,\n responseType,\n withCredentials,\n transferCache\n });\n }\n}\n\n/**\n * Type enumeration for the different kinds of `HttpEvent`.\n *\n * @publicApi\n */\nvar HttpEventType;\n(function (HttpEventType) {\n /**\n * The request was sent out over the wire.\n */\n HttpEventType[HttpEventType[\"Sent\"] = 0] = \"Sent\";\n /**\n * An upload progress event was received.\n *\n * Note: The `FetchBackend` doesn't support progress report on uploads.\n */\n HttpEventType[HttpEventType[\"UploadProgress\"] = 1] = \"UploadProgress\";\n /**\n * The response status code and headers were received.\n */\n HttpEventType[HttpEventType[\"ResponseHeader\"] = 2] = \"ResponseHeader\";\n /**\n * A download progress event was received.\n */\n HttpEventType[HttpEventType[\"DownloadProgress\"] = 3] = \"DownloadProgress\";\n /**\n * The full response including the body was received.\n */\n HttpEventType[HttpEventType[\"Response\"] = 4] = \"Response\";\n /**\n * A custom event from an interceptor or a backend.\n */\n HttpEventType[HttpEventType[\"User\"] = 5] = \"User\";\n})(HttpEventType || (HttpEventType = {}));\n/**\n * Base class for both `HttpResponse` and `HttpHeaderResponse`.\n *\n * @publicApi\n */\nclass HttpResponseBase {\n /**\n * All response headers.\n */\n headers;\n /**\n * Response status code.\n */\n status;\n /**\n * Textual description of response status code, defaults to OK.\n *\n * Do not depend on this.\n */\n statusText;\n /**\n * URL of the resource retrieved, or null if not available.\n */\n url;\n /**\n * Whether the status code falls in the 2xx range.\n */\n ok;\n /**\n * Type of the response, narrowed to either the full response or the header.\n */\n // TODO(issue/24571): remove '!'.\n type;\n /**\n * Super-constructor for all responses.\n *\n * The single parameter accepted is an initialization hash. Any properties\n * of the response passed there will override the default values.\n */\n constructor(init, defaultStatus = 200, defaultStatusText = 'OK') {\n // If the hash has values passed, use them to initialize the response.\n // Otherwise use the default values.\n this.headers = init.headers || new HttpHeaders();\n this.status = init.status !== undefined ? init.status : defaultStatus;\n this.statusText = init.statusText || defaultStatusText;\n this.url = init.url || null;\n // Cache the ok value to avoid defining a getter.\n this.ok = this.status >= 200 && this.status < 300;\n }\n}\n/**\n * A partial HTTP response which only includes the status and header data,\n * but no response body.\n *\n * `HttpHeaderResponse` is a `HttpEvent` available on the response\n * event stream, only when progress events are requested.\n *\n * @publicApi\n */\nclass HttpHeaderResponse extends HttpResponseBase {\n /**\n * Create a new `HttpHeaderResponse` with the given parameters.\n */\n constructor(init = {}) {\n super(init);\n }\n type = HttpEventType.ResponseHeader;\n /**\n * Copy this `HttpHeaderResponse`, overriding its contents with the\n * given parameter hash.\n */\n clone(update = {}) {\n // Perform a straightforward initialization of the new HttpHeaderResponse,\n // overriding the current parameters with new ones if given.\n return new HttpHeaderResponse({\n headers: update.headers || this.headers,\n status: update.status !== undefined ? update.status : this.status,\n statusText: update.statusText || this.statusText,\n url: update.url || this.url || undefined\n });\n }\n}\n/**\n * A full HTTP response, including a typed response body (which may be `null`\n * if one was not returned).\n *\n * `HttpResponse` is a `HttpEvent` available on the response event\n * stream.\n *\n * @publicApi\n */\nclass HttpResponse extends HttpResponseBase {\n /**\n * The response body, or `null` if one was not returned.\n */\n body;\n /**\n * Construct a new `HttpResponse`.\n */\n constructor(init = {}) {\n super(init);\n this.body = init.body !== undefined ? init.body : null;\n }\n type = HttpEventType.Response;\n clone(update = {}) {\n return new HttpResponse({\n body: update.body !== undefined ? update.body : this.body,\n headers: update.headers || this.headers,\n status: update.status !== undefined ? update.status : this.status,\n statusText: update.statusText || this.statusText,\n url: update.url || this.url || undefined\n });\n }\n}\n/**\n * A response that represents an error or failure, either from a\n * non-successful HTTP status, an error while executing the request,\n * or some other failure which occurred during the parsing of the response.\n *\n * Any error returned on the `Observable` response stream will be\n * wrapped in an `HttpErrorResponse` to provide additional context about\n * the state of the HTTP layer when the error occurred. The error property\n * will contain either a wrapped Error object or the error response returned\n * from the server.\n *\n * @publicApi\n */\nclass HttpErrorResponse extends HttpResponseBase {\n name = 'HttpErrorResponse';\n message;\n error;\n /**\n * Errors are never okay, even when the status code is in the 2xx success range.\n */\n ok = false;\n constructor(init) {\n // Initialize with a default status of 0 / Unknown Error.\n super(init, 0, 'Unknown Error');\n // If the response was successful, then this was a parse error. Otherwise, it was\n // a protocol-level failure of some sort. Either the request failed in transit\n // or the server returned an unsuccessful status code.\n if (this.status >= 200 && this.status < 300) {\n this.message = `Http failure during parsing for ${init.url || '(unknown url)'}`;\n } else {\n this.message = `Http failure response for ${init.url || '(unknown url)'}: ${init.status} ${init.statusText}`;\n }\n this.error = init.error || null;\n }\n}\n/**\n * We use these constant to prevent pulling the whole HttpStatusCode enum\n * Those are the only ones referenced directly by the framework\n */\nconst HTTP_STATUS_CODE_OK = 200;\nconst HTTP_STATUS_CODE_NO_CONTENT = 204;\n/**\n * Http status codes.\n * As per https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml\n * @publicApi\n */\nvar HttpStatusCode;\n(function (HttpStatusCode) {\n HttpStatusCode[HttpStatusCode[\"Continue\"] = 100] = \"Continue\";\n HttpStatusCode[HttpStatusCode[\"SwitchingProtocols\"] = 101] = \"SwitchingProtocols\";\n HttpStatusCode[HttpStatusCode[\"Processing\"] = 102] = \"Processing\";\n HttpStatusCode[HttpStatusCode[\"EarlyHints\"] = 103] = \"EarlyHints\";\n HttpStatusCode[HttpStatusCode[\"Ok\"] = 200] = \"Ok\";\n HttpStatusCode[HttpStatusCode[\"Created\"] = 201] = \"Created\";\n HttpStatusCode[HttpStatusCode[\"Accepted\"] = 202] = \"Accepted\";\n HttpStatusCode[HttpStatusCode[\"NonAuthoritativeInformation\"] = 203] = \"NonAuthoritativeInformation\";\n HttpStatusCode[HttpStatusCode[\"NoContent\"] = 204] = \"NoContent\";\n HttpStatusCode[HttpStatusCode[\"ResetContent\"] = 205] = \"ResetContent\";\n HttpStatusCode[HttpStatusCode[\"PartialContent\"] = 206] = \"PartialContent\";\n HttpStatusCode[HttpStatusCode[\"MultiStatus\"] = 207] = \"MultiStatus\";\n HttpStatusCode[HttpStatusCode[\"AlreadyReported\"] = 208] = \"AlreadyReported\";\n HttpStatusCode[HttpStatusCode[\"ImUsed\"] = 226] = \"ImUsed\";\n HttpStatusCode[HttpStatusCode[\"MultipleChoices\"] = 300] = \"MultipleChoices\";\n HttpStatusCode[HttpStatusCode[\"MovedPermanently\"] = 301] = \"MovedPermanently\";\n HttpStatusCode[HttpStatusCode[\"Found\"] = 302] = \"Found\";\n HttpStatusCode[HttpStatusCode[\"SeeOther\"] = 303] = \"SeeOther\";\n HttpStatusCode[HttpStatusCode[\"NotModified\"] = 304] = \"NotModified\";\n HttpStatusCode[HttpStatusCode[\"UseProxy\"] = 305] = \"UseProxy\";\n HttpStatusCode[HttpStatusCode[\"Unused\"] = 306] = \"Unused\";\n HttpStatusCode[HttpStatusCode[\"TemporaryRedirect\"] = 307] = \"TemporaryRedirect\";\n HttpStatusCode[HttpStatusCode[\"PermanentRedirect\"] = 308] = \"PermanentRedirect\";\n HttpStatusCode[HttpStatusCode[\"BadRequest\"] = 400] = \"BadRequest\";\n HttpStatusCode[HttpStatusCode[\"Unauthorized\"] = 401] = \"Unauthorized\";\n HttpStatusCode[HttpStatusCode[\"PaymentRequired\"] = 402] = \"PaymentRequired\";\n HttpStatusCode[HttpStatusCode[\"Forbidden\"] = 403] = \"Forbidden\";\n HttpStatusCode[HttpStatusCode[\"NotFound\"] = 404] = \"NotFound\";\n HttpStatusCode[HttpStatusCode[\"MethodNotAllowed\"] = 405] = \"MethodNotAllowed\";\n HttpStatusCode[HttpStatusCode[\"NotAcceptable\"] = 406] = \"NotAcceptable\";\n HttpStatusCode[HttpStatusCode[\"ProxyAuthenticationRequired\"] = 407] = \"ProxyAuthenticationRequired\";\n HttpStatusCode[HttpStatusCode[\"RequestTimeout\"] = 408] = \"RequestTimeout\";\n HttpStatusCode[HttpStatusCode[\"Conflict\"] = 409] = \"Conflict\";\n HttpStatusCode[HttpStatusCode[\"Gone\"] = 410] = \"Gone\";\n HttpStatusCode[HttpStatusCode[\"LengthRequired\"] = 411] = \"LengthRequired\";\n HttpStatusCode[HttpStatusCode[\"PreconditionFailed\"] = 412] = \"PreconditionFailed\";\n HttpStatusCode[HttpStatusCode[\"PayloadTooLarge\"] = 413] = \"PayloadTooLarge\";\n HttpStatusCode[HttpStatusCode[\"UriTooLong\"] = 414] = \"UriTooLong\";\n HttpStatusCode[HttpStatusCode[\"UnsupportedMediaType\"] = 415] = \"UnsupportedMediaType\";\n HttpStatusCode[HttpStatusCode[\"RangeNotSatisfiable\"] = 416] = \"RangeNotSatisfiable\";\n HttpStatusCode[HttpStatusCode[\"ExpectationFailed\"] = 417] = \"ExpectationFailed\";\n HttpStatusCode[HttpStatusCode[\"ImATeapot\"] = 418] = \"ImATeapot\";\n HttpStatusCode[HttpStatusCode[\"MisdirectedRequest\"] = 421] = \"MisdirectedRequest\";\n HttpStatusCode[HttpStatusCode[\"UnprocessableEntity\"] = 422] = \"UnprocessableEntity\";\n HttpStatusCode[HttpStatusCode[\"Locked\"] = 423] = \"Locked\";\n HttpStatusCode[HttpStatusCode[\"FailedDependency\"] = 424] = \"FailedDependency\";\n HttpStatusCode[HttpStatusCode[\"TooEarly\"] = 425] = \"TooEarly\";\n HttpStatusCode[HttpStatusCode[\"UpgradeRequired\"] = 426] = \"UpgradeRequired\";\n HttpStatusCode[HttpStatusCode[\"PreconditionRequired\"] = 428] = \"PreconditionRequired\";\n HttpStatusCode[HttpStatusCode[\"TooManyRequests\"] = 429] = \"TooManyRequests\";\n HttpStatusCode[HttpStatusCode[\"RequestHeaderFieldsTooLarge\"] = 431] = \"RequestHeaderFieldsTooLarge\";\n HttpStatusCode[HttpStatusCode[\"UnavailableForLegalReasons\"] = 451] = \"UnavailableForLegalReasons\";\n HttpStatusCode[HttpStatusCode[\"InternalServerError\"] = 500] = \"InternalServerError\";\n HttpStatusCode[HttpStatusCode[\"NotImplemented\"] = 501] = \"NotImplemented\";\n HttpStatusCode[HttpStatusCode[\"BadGateway\"] = 502] = \"BadGateway\";\n HttpStatusCode[HttpStatusCode[\"ServiceUnavailable\"] = 503] = \"ServiceUnavailable\";\n HttpStatusCode[HttpStatusCode[\"GatewayTimeout\"] = 504] = \"GatewayTimeout\";\n HttpStatusCode[HttpStatusCode[\"HttpVersionNotSupported\"] = 505] = \"HttpVersionNotSupported\";\n HttpStatusCode[HttpStatusCode[\"VariantAlsoNegotiates\"] = 506] = \"VariantAlsoNegotiates\";\n HttpStatusCode[HttpStatusCode[\"InsufficientStorage\"] = 507] = \"InsufficientStorage\";\n HttpStatusCode[HttpStatusCode[\"LoopDetected\"] = 508] = \"LoopDetected\";\n HttpStatusCode[HttpStatusCode[\"NotExtended\"] = 510] = \"NotExtended\";\n HttpStatusCode[HttpStatusCode[\"NetworkAuthenticationRequired\"] = 511] = \"NetworkAuthenticationRequired\";\n})(HttpStatusCode || (HttpStatusCode = {}));\n\n/**\n * Constructs an instance of `HttpRequestOptions<T>` from a source `HttpMethodOptions` and\n * the given `body`. This function clones the object and adds the body.\n *\n * Note that the `responseType` *options* value is a String that identifies the\n * single data type of the response.\n * A single overload version of the method handles each response type.\n * The value of `responseType` cannot be a union, as the combined signature could imply.\n *\n */\nfunction addBody(options, body) {\n return {\n body,\n headers: options.headers,\n context: options.context,\n observe: options.observe,\n params: options.params,\n reportProgress: options.reportProgress,\n responseType: options.responseType,\n withCredentials: options.withCredentials,\n transferCache: options.transferCache\n };\n}\n/**\n * Performs HTTP requests.\n * This service is available as an injectable class, with methods to perform HTTP requests.\n * Each request method has multiple signatures, and the return type varies based on\n * the signature that is called (mainly the values of `observe` and `responseType`).\n *\n * Note that the `responseType` *options* value is a String that identifies the\n * single data type of the response.\n * A single overload version of the method handles each response type.\n * The value of `responseType` cannot be a union, as the combined signature could imply.\n *\n * @usageNotes\n *\n * ### HTTP Request Example\n *\n * ```ts\n * // GET heroes whose name contains search term\n * searchHeroes(term: string): observable<Hero[]>{\n *\n * const params = new HttpParams({fromString: 'name=term'});\n * return this.httpClient.request('GET', this.heroesUrl, {responseType:'json', params});\n * }\n * ```\n *\n * Alternatively, the parameter string can be used without invoking HttpParams\n * by directly joining to the URL.\n * ```ts\n * this.httpClient.request('GET', this.heroesUrl + '?' + 'name=term', {responseType:'json'});\n * ```\n *\n *\n * ### JSONP Example\n * ```ts\n * requestJsonp(url, callback = 'callback') {\n * return this.httpClient.jsonp(this.heroesURL, callback);\n * }\n * ```\n *\n * ### PATCH Example\n * ```ts\n * // PATCH one of the heroes' name\n * patchHero (id: number, heroName: string): Observable<{}> {\n * const url = `${this.heroesUrl}/${id}`; // PATCH api/heroes/42\n * return this.httpClient.patch(url, {name: heroName}, httpOptions)\n * .pipe(catchError(this.handleError('patchHero')));\n * }\n * ```\n *\n * @see [HTTP Guide](guide/http)\n * @see [HTTP Request](api/common/http/HttpRequest)\n *\n * @publicApi\n */\nclass HttpClient {\n handler;\n constructor(handler) {\n this.handler = handler;\n }\n /**\n * Constructs an observable for a generic HTTP request that, when subscribed,\n * fires the request through the chain of registered interceptors and on to the\n * server.\n *\n * You can pass an `HttpRequest` directly as the only parameter. In this case,\n * the call returns an observable of the raw `HttpEvent` stream.\n *\n * Alternatively you can pass an HTTP method as the first parameter,\n * a URL string as the second, and an options hash containing the request body as the third.\n * See `addBody()`. In this case, the specified `responseType` and `observe` options determine the\n * type of returned observable.\n * * The `responseType` value determines how a successful response body is parsed.\n * * If `responseType` is the default `json`, you can pass a type interface for the resulting\n * object as a type parameter to the call.\n *\n * The `observe` value determines the return type, according to what you are interested in\n * observing.\n * * An `observe` value of events returns an observable of the raw `HttpEvent` stream, including\n * progress events by default.\n * * An `observe` value of response returns an observable of `HttpResponse<T>`,\n * where the `T` parameter depends on the `responseType` and any optionally provided type\n * parameter.\n * * An `observe` value of body returns an observable of `<T>` with the same `T` body type.\n *\n */\n request(first, url, options = {}) {\n let req;\n // First, check whether the primary argument is an instance of `HttpRequest`.\n if (first instanceof HttpRequest) {\n // It is. The other arguments must be undefined (per the signatures) and can be\n // ignored.\n req = first;\n } else {\n // It's a string, so it represents a URL. Construct a request based on it,\n // and incorporate the remaining arguments (assuming `GET` unless a method is\n // provided.\n // Figure out the headers.\n let headers = undefined;\n if (options.headers instanceof HttpHeaders) {\n headers = options.headers;\n } else {\n headers = new HttpHeaders(options.headers);\n }\n // Sort out parameters.\n let params = undefined;\n if (!!options.params) {\n if (options.params instanceof HttpParams) {\n params = options.params;\n } else {\n params = new HttpParams({\n fromObject: options.params\n });\n }\n }\n // Construct the request.\n req = new HttpRequest(first, url, options.body !== undefined ? options.body : null, {\n headers,\n context: options.context,\n params,\n reportProgress: options.reportProgress,\n // By default, JSON is assumed to be returned for all calls.\n responseType: options.responseType || 'json',\n withCredentials: options.withCredentials,\n transferCache: options.transferCache\n });\n }\n // Start with an Observable.of() the initial request, and run the handler (which\n // includes all interceptors) inside a concatMap(). This way, the handler runs\n // inside an Observable chain, which causes interceptors to be re-run on every\n // subscription (this also makes retries re-run the handler, including interceptors).\n const events$ = of(req).pipe(concatMap(req => this.handler.handle(req)));\n // If coming via the API signature which accepts a previously constructed HttpRequest,\n // the only option is to get the event stream. Otherwise, return the event stream if\n // that is what was requested.\n if (first instanceof HttpRequest || options.observe === 'events') {\n return events$;\n }\n // The requested stream contains either the full response or the body. In either\n // case, the first step is to filter the event stream to extract a stream of\n // responses(s).\n const res$ = events$.pipe(filter(event => event instanceof HttpResponse));\n // Decide which stream to return.\n switch (options.observe || 'body') {\n case 'body':\n // The requested stream is the body. Map the response stream to the response\n // body. This could be done more simply, but a misbehaving interceptor might\n // transform the response body into a different format and ignore the requested\n // responseType. Guard against this by validating that the response is of the\n // requested type.\n switch (req.responseType) {\n case 'arraybuffer':\n return res$.pipe(map(res => {\n // Validate that the body is an ArrayBuffer.\n if (res.body !== null && !(res.body instanceof ArrayBuffer)) {\n throw new ɵRuntimeError(2806 /* RuntimeErrorCode.RESPONSE_IS_NOT_AN_ARRAY_BUFFER */, ngDevMode && 'Response is not an ArrayBuffer.');\n }\n return res.body;\n }));\n case 'blob':\n return res$.pipe(map(res => {\n // Validate that the body is a Blob.\n if (res.body !== null && !(res.body instanceof Blob)) {\n throw new ɵRuntimeError(2807 /* RuntimeErrorCode.RESPONSE_IS_NOT_A_BLOB */, ngDevMode && 'Response is not a Blob.');\n }\n return res.body;\n }));\n case 'text':\n return res$.pipe(map(res => {\n // Validate that the body is a string.\n if (res.body !== null && typeof res.body !== 'string') {\n throw new ɵRuntimeError(2808 /* RuntimeErrorCode.RESPONSE_IS_NOT_A_STRING */, ngDevMode && 'Response is not a string.');\n }\n return res.body;\n }));\n case 'json':\n default:\n // No validation needed for JSON responses, as they can be of any type.\n return res$.pipe(map(res => res.body));\n }\n case 'response':\n // The response stream was requested directly, so return it.\n return res$;\n default:\n // Guard against new future observe types being added.\n throw new ɵRuntimeError(2809 /* RuntimeErrorCode.UNHANDLED_OBSERVE_TYPE */, ngDevMode && `Unreachable: unhandled observe type ${options.observe}}`);\n }\n }\n /**\n * Constructs an observable that, when subscribed, causes the configured\n * `DELETE` request to execute on the server. See the individual overloads for\n * details on the return type.\n *\n * @param url The endpoint URL.\n * @param options The HTTP options to send with the request.\n *\n */\n delete(url, options = {}) {\n return this.request('DELETE', url, options);\n }\n /**\n * Constructs an observable that, when subscribed, causes the configured\n * `GET` request to execute on the server. See the individual overloads for\n * details on the return type.\n */\n get(url, options = {}) {\n return this.request('GET', url, options);\n }\n /**\n * Constructs an observable that, when subscribed, causes the configured\n * `HEAD` request to execute on the server. The `HEAD` method returns\n * meta information about the resource without transferring the\n * resource itself. See the individual overloads for\n * details on the return type.\n */\n head(url, options = {}) {\n return this.request('HEAD', url, options);\n }\n /**\n * Constructs an `Observable` that, when subscribed, causes a request with the special method\n * `JSONP` to be dispatched via the interceptor pipeline.\n * The [JSONP pattern](https://en.wikipedia.org/wiki/JSONP) works around limitations of certain\n * API endpoints that don't support newer,\n * and preferable [CORS](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) protocol.\n * JSONP treats the endpoint API as a JavaScript file and tricks the browser to process the\n * requests even if the API endpoint is not located on the same domain (origin) as the client-side\n * application making the request.\n * The endpoint API must support JSONP callback for JSONP requests to work.\n * The resource API returns the JSON response wrapped in a callback function.\n * You can pass the callback function name as one of the query parameters.\n * Note that JSONP requests can only be used with `GET` requests.\n *\n * @param url The resource URL.\n * @param callbackParam The callback function name.\n *\n */\n jsonp(url, callbackParam) {\n return this.request('JSONP', url, {\n params: new HttpParams().append(callbackParam, 'JSONP_CALLBACK'),\n observe: 'body',\n responseType: 'json'\n });\n }\n /**\n * Constructs an `Observable` that, when subscribed, causes the configured\n * `OPTIONS` request to execute on the server. This method allows the client\n * to determine the supported HTTP methods and other capabilities of an endpoint,\n * without implying a resource action. See the individual overloads for\n * details on the return type.\n */\n options(url, options = {}) {\n return this.request('OPTIONS', url, options);\n }\n /**\n * Constructs an observable that, when subscribed, causes the configured\n * `PATCH` request to execute on the server. See the individual overloads for\n * details on the return type.\n */\n patch(url, body, options = {}) {\n return this.request('PATCH', url, addBody(options, body));\n }\n /**\n * Constructs an observable that, when subscribed, causes the configured\n * `POST` request to execute on the server. The server responds with the location of\n * the replaced resource. See the individual overloads for\n * details on the return type.\n */\n post(url, body, options = {}) {\n return this.request('POST', url, addBody(options, body));\n }\n /**\n * Constructs an observable that, when subscribed, causes the configured\n * `PUT` request to execute on the server. The `PUT` method replaces an existing resource\n * with a new set of values.\n * See the individual overloads for details on the return type.\n */\n put(url, body, options = {}) {\n return this.request('PUT', url, addBody(options, body));\n }\n static ɵfac = function HttpClient_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpClient)(i0.ɵɵinject(HttpHandler));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HttpClient,\n factory: HttpClient.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpClient, [{\n type: Injectable\n }], () => [{\n type: HttpHandler\n }], null);\n})();\nconst XSSI_PREFIX$1 = /^\\)\\]\\}',?\\n/;\n/**\n * Determine an appropriate URL for the response, by checking either\n * response url or the X-Request-URL header.\n */\nfunction getResponseUrl$1(response) {\n if (response.url) {\n return response.url;\n }\n // stored as lowercase in the map\n const xRequestUrl = X_REQUEST_URL_HEADER.toLocaleLowerCase();\n return response.headers.get(xRequestUrl);\n}\n/**\n * An internal injection token to reference `FetchBackend` implementation\n * in a tree-shakable way.\n */\nconst FETCH_BACKEND = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'FETCH_BACKEND' : '');\n/**\n * Uses `fetch` to send requests to a backend server.\n *\n * This `FetchBackend` requires the support of the\n * [Fetch API](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API) which is available on all\n * supported browsers and on Node.js v18 or later.\n *\n * @see {@link HttpHandler}\n *\n * @publicApi\n */\nclass FetchBackend {\n // We use an arrow function to always reference the current global implementation of `fetch`.\n // This is helpful for cases when the global `fetch` implementation is modified by external code,\n // see https://github.com/angular/angular/issues/57527.\n fetchImpl = inject(FetchFactory, {\n optional: true\n })?.fetch ?? ((...args) => globalThis.fetch(...args));\n ngZone = inject(NgZone);\n handle(request) {\n return new Observable(observer => {\n const aborter = new AbortController();\n this.doRequest(request, aborter.signal, observer).then(noop, error => observer.error(new HttpErrorResponse({\n error\n })));\n return () => aborter.abort();\n });\n }\n async doRequest(request, signal, observer) {\n const init = this.createRequestInit(request);\n let response;\n try {\n // Run fetch outside of Angular zone.\n // This is due to Node.js fetch implementation (Undici) which uses a number of setTimeouts to check if\n // the response should eventually timeout which causes extra CD cycles every 500ms\n const fetchPromise = this.ngZone.runOutsideAngular(() => this.fetchImpl(request.urlWithParams, {\n signal,\n ...init\n }));\n // Make sure Zone.js doesn't trigger false-positive unhandled promise\n // error in case the Promise is rejected synchronously. See function\n // description for additional information.\n silenceSuperfluousUnhandledPromiseRejection(fetchPromise);\n // Send the `Sent` event before awaiting the response.\n observer.next({\n type: HttpEventType.Sent\n });\n response = await fetchPromise;\n } catch (error) {\n observer.error(new HttpErrorResponse({\n error,\n status: error.status ?? 0,\n statusText: error.statusText,\n url: request.urlWithParams,\n headers: error.headers\n }));\n return;\n }\n const headers = new HttpHeaders(response.headers);\n const statusText = response.statusText;\n const url = getResponseUrl$1(response) ?? request.urlWithParams;\n let status = response.status;\n let body = null;\n if (request.reportProgress) {\n observer.next(new HttpHeaderResponse({\n headers,\n status,\n statusText,\n url\n }));\n }\n if (response.body) {\n // Read Progress\n const contentLength = response.headers.get('content-length');\n const chunks = [];\n const reader = response.body.getReader();\n let receivedLength = 0;\n let decoder;\n let partialText;\n // We have to check whether the Zone is defined in the global scope because this may be called\n // when the zone is nooped.\n const reqZone = typeof Zone !== 'undefined' && Zone.current;\n // Perform response processing outside of Angular zone to\n // ensure no excessive change detection runs are executed\n // Here calling the async ReadableStreamDefaultReader.read() is responsible for triggering CD\n await this.ngZone.runOutsideAngular(async () => {\n while (true) {\n const {\n done,\n value\n } = await reader.read();\n if (done) {\n break;\n }\n chunks.push(value);\n receivedLength += value.length;\n if (request.reportProgress) {\n partialText = request.responseType === 'text' ? (partialText ?? '') + (decoder ??= new TextDecoder()).decode(value, {\n stream: true\n }) : undefined;\n const reportProgress = () => observer.next({\n type: HttpEventType.DownloadProgress,\n total: contentLength ? +contentLength : undefined,\n loaded: receivedLength,\n partialText\n });\n reqZone ? reqZone.run(reportProgress) : reportProgress();\n }\n }\n });\n // Combine all chunks.\n const chunksAll = this.concatChunks(chunks, receivedLength);\n try {\n const contentType = response.headers.get(CONTENT_TYPE_HEADER) ?? '';\n body = this.parseBody(request, chunksAll, contentType);\n } catch (error) {\n // Body loading or parsing failed\n observer.error(new HttpErrorResponse({\n error,\n headers: new HttpHeaders(response.headers),\n status: response.status,\n statusText: response.statusText,\n url: getResponseUrl$1(response) ?? request.urlWithParams\n }));\n return;\n }\n }\n // Same behavior as the XhrBackend\n if (status === 0) {\n status = body ? HTTP_STATUS_CODE_OK : 0;\n }\n // ok determines whether the response will be transmitted on the event or\n // error channel. Unsuccessful status codes (not 2xx) will always be errors,\n // but a successful status code can still result in an error if the user\n // asked for JSON data and the body cannot be parsed as such.\n const ok = status >= 200 && status < 300;\n if (ok) {\n observer.next(new HttpResponse({\n body,\n headers,\n status,\n statusText,\n url\n }));\n // The full body has been received and delivered, no further events\n // are possible. This request is complete.\n observer.complete();\n } else {\n observer.error(new HttpErrorResponse({\n error: body,\n headers,\n status,\n statusText,\n url\n }));\n }\n }\n parseBody(request, binContent, contentType) {\n switch (request.responseType) {\n case 'json':\n // stripping the XSSI when present\n const text = new TextDecoder().decode(binContent).replace(XSSI_PREFIX$1, '');\n return text === '' ? null : JSON.parse(text);\n case 'text':\n return new TextDecoder().decode(binContent);\n case 'blob':\n return new Blob([binContent], {\n type: contentType\n });\n case 'arraybuffer':\n return binContent.buffer;\n }\n }\n createRequestInit(req) {\n // We could share some of this logic with the XhrBackend\n const headers = {};\n const credentials = req.withCredentials ? 'include' : undefined;\n // Setting all the requested headers.\n req.headers.forEach((name, values) => headers[name] = values.join(','));\n // Add an Accept header if one isn't present already.\n if (!req.headers.has(ACCEPT_HEADER)) {\n headers[ACCEPT_HEADER] = ACCEPT_HEADER_VALUE;\n }\n // Auto-detect the Content-Type header if one isn't present already.\n if (!req.headers.has(CONTENT_TYPE_HEADER)) {\n const detectedType = req.detectContentTypeHeader();\n // Sometimes Content-Type detection fails.\n if (detectedType !== null) {\n headers[CONTENT_TYPE_HEADER] = detectedType;\n }\n }\n return {\n body: req.serializeBody(),\n method: req.method,\n headers,\n credentials\n };\n }\n concatChunks(chunks, totalLength) {\n const chunksAll = new Uint8Array(totalLength);\n let position = 0;\n for (const chunk of chunks) {\n chunksAll.set(chunk, position);\n position += chunk.length;\n }\n return chunksAll;\n }\n static ɵfac = function FetchBackend_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FetchBackend)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: FetchBackend,\n factory: FetchBackend.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FetchBackend, [{\n type: Injectable\n }], null, null);\n})();\n/**\n * Abstract class to provide a mocked implementation of `fetch()`\n */\nclass FetchFactory {}\nfunction noop() {}\n/**\n * Zone.js treats a rejected promise that has not yet been awaited\n * as an unhandled error. This function adds a noop `.then` to make\n * sure that Zone.js doesn't throw an error if the Promise is rejected\n * synchronously.\n */\nfunction silenceSuperfluousUnhandledPromiseRejection(promise) {\n promise.then(noop, noop);\n}\nfunction interceptorChainEndFn(req, finalHandlerFn) {\n return finalHandlerFn(req);\n}\n/**\n * Constructs a `ChainedInterceptorFn` which adapts a legacy `HttpInterceptor` to the\n * `ChainedInterceptorFn` interface.\n */\nfunction adaptLegacyInterceptorToChain(chainTailFn, interceptor) {\n return (initialRequest, finalHandlerFn) => interceptor.intercept(initialRequest, {\n handle: downstreamRequest => chainTailFn(downstreamRequest, finalHandlerFn)\n });\n}\n/**\n * Constructs a `ChainedInterceptorFn` which wraps and invokes a functional interceptor in the given\n * injector.\n */\nfunction chainedInterceptorFn(chainTailFn, interceptorFn, injector) {\n return (initialRequest, finalHandlerFn) => runInInjectionContext(injector, () => interceptorFn(initialRequest, downstreamRequest => chainTailFn(downstreamRequest, finalHandlerFn)));\n}\n/**\n * A multi-provider token that represents the array of registered\n * `HttpInterceptor` objects.\n *\n * @publicApi\n */\nconst HTTP_INTERCEPTORS = new InjectionToken(ngDevMode ? 'HTTP_INTERCEPTORS' : '');\n/**\n * A multi-provided token of `HttpInterceptorFn`s.\n */\nconst HTTP_INTERCEPTOR_FNS = new InjectionToken(ngDevMode ? 'HTTP_INTERCEPTOR_FNS' : '');\n/**\n * A multi-provided token of `HttpInterceptorFn`s that are only set in root.\n */\nconst HTTP_ROOT_INTERCEPTOR_FNS = new InjectionToken(ngDevMode ? 'HTTP_ROOT_INTERCEPTOR_FNS' : '');\n// TODO(atscott): We need a larger discussion about stability and what should contribute to stability.\n// Should the whole interceptor chain contribute to stability or just the backend request #55075?\n// Should HttpClient contribute to stability automatically at all?\nconst REQUESTS_CONTRIBUTE_TO_STABILITY = new InjectionToken(ngDevMode ? 'REQUESTS_CONTRIBUTE_TO_STABILITY' : '', {\n providedIn: 'root',\n factory: () => true\n});\n/**\n * Creates an `HttpInterceptorFn` which lazily initializes an interceptor chain from the legacy\n * class-based interceptors and runs the request through it.\n */\nfunction legacyInterceptorFnFactory() {\n let chain = null;\n return (req, handler) => {\n if (chain === null) {\n const interceptors = inject(HTTP_INTERCEPTORS, {\n optional: true\n }) ?? [];\n // Note: interceptors are wrapped right-to-left so that final execution order is\n // left-to-right. That is, if `interceptors` is the array `[a, b, c]`, we want to\n // produce a chain that is conceptually `c(b(a(end)))`, which we build from the inside\n // out.\n chain = interceptors.reduceRight(adaptLegacyInterceptorToChain, interceptorChainEndFn);\n }\n const pendingTasks = inject(ɵPendingTasksInternal);\n const contributeToStability = inject(REQUESTS_CONTRIBUTE_TO_STABILITY);\n if (contributeToStability) {\n const taskId = pendingTasks.add();\n return chain(req, handler).pipe(finalize(() => pendingTasks.remove(taskId)));\n } else {\n return chain(req, handler);\n }\n };\n}\nlet fetchBackendWarningDisplayed = false;\n/** Internal function to reset the flag in tests */\nfunction resetFetchBackendWarningFlag() {\n fetchBackendWarningDisplayed = false;\n}\nclass HttpInterceptorHandler extends HttpHandler {\n backend;\n injector;\n chain = null;\n pendingTasks = inject(ɵPendingTasksInternal);\n contributeToStability = inject(REQUESTS_CONTRIBUTE_TO_STABILITY);\n constructor(backend, injector) {\n super();\n this.backend = backend;\n this.injector = injector;\n // We strongly recommend using fetch backend for HTTP calls when SSR is used\n // for an application. The logic below checks if that's the case and produces\n // a warning otherwise.\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !fetchBackendWarningDisplayed) {\n const isServer = isPlatformServer(injector.get(PLATFORM_ID));\n // This flag is necessary because provideHttpClientTesting() overrides the backend\n // even if `withFetch()` is used within the test. When the testing HTTP backend is provided,\n // no HTTP calls are actually performed during the test, so producing a warning would be\n // misleading.\n const isTestingBackend = this.backend.isTestingBackend;\n if (isServer && !(this.backend instanceof FetchBackend) && !isTestingBackend) {\n fetchBackendWarningDisplayed = true;\n injector.get(ɵConsole).warn(ɵformatRuntimeError(2801 /* RuntimeErrorCode.NOT_USING_FETCH_BACKEND_IN_SSR */, 'Angular detected that `HttpClient` is not configured ' + \"to use `fetch` APIs. It's strongly recommended to \" + 'enable `fetch` for applications that use Server-Side Rendering ' + 'for better performance and compatibility. ' + 'To enable `fetch`, add the `withFetch()` to the `provideHttpClient()` ' + 'call at the root of the application.'));\n }\n }\n }\n handle(initialRequest) {\n if (this.chain === null) {\n const dedupedInterceptorFns = Array.from(new Set([...this.injector.get(HTTP_INTERCEPTOR_FNS), ...this.injector.get(HTTP_ROOT_INTERCEPTOR_FNS, [])]));\n // Note: interceptors are wrapped right-to-left so that final execution order is\n // left-to-right. That is, if `dedupedInterceptorFns` is the array `[a, b, c]`, we want to\n // produce a chain that is conceptually `c(b(a(end)))`, which we build from the inside\n // out.\n this.chain = dedupedInterceptorFns.reduceRight((nextSequencedFn, interceptorFn) => chainedInterceptorFn(nextSequencedFn, interceptorFn, this.injector), interceptorChainEndFn);\n }\n if (this.contributeToStability) {\n const taskId = this.pendingTasks.add();\n return this.chain(initialRequest, downstreamRequest => this.backend.handle(downstreamRequest)).pipe(finalize(() => this.pendingTasks.remove(taskId)));\n } else {\n return this.chain(initialRequest, downstreamRequest => this.backend.handle(downstreamRequest));\n }\n }\n static ɵfac = function HttpInterceptorHandler_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpInterceptorHandler)(i0.ɵɵinject(HttpBackend), i0.ɵɵinject(i0.EnvironmentInjector));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HttpInterceptorHandler,\n factory: HttpInterceptorHandler.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpInterceptorHandler, [{\n type: Injectable\n }], () => [{\n type: HttpBackend\n }, {\n type: i0.EnvironmentInjector\n }], null);\n})();\n\n// Every request made through JSONP needs a callback name that's unique across the\n// whole page. Each request is assigned an id and the callback name is constructed\n// from that. The next id to be assigned is tracked in a global variable here that\n// is shared among all applications on the page.\nlet nextRequestId = 0;\n/**\n * When a pending <script> is unsubscribed we'll move it to this document, so it won't be\n * executed.\n */\nlet foreignDocument;\n// Error text given when a JSONP script is injected, but doesn't invoke the callback\n// passed in its URL.\nconst JSONP_ERR_NO_CALLBACK = 'JSONP injected script did not invoke callback.';\n// Error text given when a request is passed to the JsonpClientBackend that doesn't\n// have a request method JSONP.\nconst JSONP_ERR_WRONG_METHOD = 'JSONP requests must use JSONP request method.';\nconst JSONP_ERR_WRONG_RESPONSE_TYPE = 'JSONP requests must use Json response type.';\n// Error text given when a request is passed to the JsonpClientBackend that has\n// headers set\nconst JSONP_ERR_HEADERS_NOT_SUPPORTED = 'JSONP requests do not support headers.';\n/**\n * DI token/abstract type representing a map of JSONP callbacks.\n *\n * In the browser, this should always be the `window` object.\n *\n *\n */\nclass JsonpCallbackContext {}\n/**\n * Factory function that determines where to store JSONP callbacks.\n *\n * Ordinarily JSONP callbacks are stored on the `window` object, but this may not exist\n * in test environments. In that case, callbacks are stored on an anonymous object instead.\n *\n *\n */\nfunction jsonpCallbackContext() {\n if (typeof window === 'object') {\n return window;\n }\n return {};\n}\n/**\n * Processes an `HttpRequest` with the JSONP method,\n * by performing JSONP style requests.\n * @see {@link HttpHandler}\n * @see {@link HttpXhrBackend}\n *\n * @publicApi\n */\nclass JsonpClientBackend {\n callbackMap;\n document;\n /**\n * A resolved promise that can be used to schedule microtasks in the event handlers.\n */\n resolvedPromise = Promise.resolve();\n constructor(callbackMap, document) {\n this.callbackMap = callbackMap;\n this.document = document;\n }\n /**\n * Get the name of the next callback method, by incrementing the global `nextRequestId`.\n */\n nextCallback() {\n return `ng_jsonp_callback_${nextRequestId++}`;\n }\n /**\n * Processes a JSONP request and returns an event stream of the results.\n * @param req The request object.\n * @returns An observable of the response events.\n *\n */\n handle(req) {\n // Firstly, check both the method and response type. If either doesn't match\n // then the request was improperly routed here and cannot be handled.\n if (req.method !== 'JSONP') {\n throw new Error(JSONP_ERR_WRONG_METHOD);\n } else if (req.responseType !== 'json') {\n throw new Error(JSONP_ERR_WRONG_RESPONSE_TYPE);\n }\n // Check the request headers. JSONP doesn't support headers and\n // cannot set any that were supplied.\n if (req.headers.keys().length > 0) {\n throw new Error(JSONP_ERR_HEADERS_NOT_SUPPORTED);\n }\n // Everything else happens inside the Observable boundary.\n return new Observable(observer => {\n // The first step to make a request is to generate the callback name, and replace the\n // callback placeholder in the URL with the name. Care has to be taken here to ensure\n // a trailing &, if matched, gets inserted back into the URL in the correct place.\n const callback = this.nextCallback();\n const url = req.urlWithParams.replace(/=JSONP_CALLBACK(&|$)/, `=${callback}$1`);\n // Construct the <script> tag and point it at the URL.\n const node = this.document.createElement('script');\n node.src = url;\n // A JSONP request requires waiting for multiple callbacks. These variables\n // are closed over and track state across those callbacks.\n // The response object, if one has been received, or null otherwise.\n let body = null;\n // Whether the response callback has been called.\n let finished = false;\n // Set the response callback in this.callbackMap (which will be the window\n // object in the browser. The script being loaded via the <script> tag will\n // eventually call this callback.\n this.callbackMap[callback] = data => {\n // Data has been received from the JSONP script. Firstly, delete this callback.\n delete this.callbackMap[callback];\n // Set state to indicate data was received.\n body = data;\n finished = true;\n };\n // cleanup() is a utility closure that removes the <script> from the page and\n // the response callback from the window. This logic is used in both the\n // success, error, and cancellation paths, so it's extracted out for convenience.\n const cleanup = () => {\n node.removeEventListener('load', onLoad);\n node.removeEventListener('error', onError);\n // Remove the <script> tag if it's still on the page.\n node.remove();\n // Remove the response callback from the callbackMap (window object in the\n // browser).\n delete this.callbackMap[callback];\n };\n // onLoad() is the success callback which runs after the response callback\n // if the JSONP script loads successfully. The event itself is unimportant.\n // If something went wrong, onLoad() may run without the response callback\n // having been invoked.\n const onLoad = event => {\n // We wrap it in an extra Promise, to ensure the microtask\n // is scheduled after the loaded endpoint has executed any potential microtask itself,\n // which is not guaranteed in Internet Explorer and EdgeHTML. See issue #39496\n this.resolvedPromise.then(() => {\n // Cleanup the page.\n cleanup();\n // Check whether the response callback has run.\n if (!finished) {\n // It hasn't, something went wrong with the request. Return an error via\n // the Observable error path. All JSONP errors have status 0.\n observer.error(new HttpErrorResponse({\n url,\n status: 0,\n statusText: 'JSONP Error',\n error: new Error(JSONP_ERR_NO_CALLBACK)\n }));\n return;\n }\n // Success. body either contains the response body or null if none was\n // returned.\n observer.next(new HttpResponse({\n body,\n status: HTTP_STATUS_CODE_OK,\n statusText: 'OK',\n url\n }));\n // Complete the stream, the response is over.\n observer.complete();\n });\n };\n // onError() is the error callback, which runs if the script returned generates\n // a Javascript error. It emits the error via the Observable error channel as\n // a HttpErrorResponse.\n const onError = error => {\n cleanup();\n // Wrap the error in a HttpErrorResponse.\n observer.error(new HttpErrorResponse({\n error,\n status: 0,\n statusText: 'JSONP Error',\n url\n }));\n };\n // Subscribe to both the success (load) and error events on the <script> tag,\n // and add it to the page.\n node.addEventListener('load', onLoad);\n node.addEventListener('error', onError);\n this.document.body.appendChild(node);\n // The request has now been successfully sent.\n observer.next({\n type: HttpEventType.Sent\n });\n // Cancellation handler.\n return () => {\n if (!finished) {\n this.removeListeners(node);\n }\n // And finally, clean up the page.\n cleanup();\n };\n });\n }\n removeListeners(script) {\n // Issue #34818\n // Changing <script>'s ownerDocument will prevent it from execution.\n // https://html.spec.whatwg.org/multipage/scripting.html#execute-the-script-block\n foreignDocument ??= this.document.implementation.createHTMLDocument();\n foreignDocument.adoptNode(script);\n }\n static ɵfac = function JsonpClientBackend_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || JsonpClientBackend)(i0.ɵɵinject(JsonpCallbackContext), i0.ɵɵinject(DOCUMENT));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: JsonpClientBackend,\n factory: JsonpClientBackend.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(JsonpClientBackend, [{\n type: Injectable\n }], () => [{\n type: JsonpCallbackContext\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }], null);\n})();\n/**\n * Identifies requests with the method JSONP and shifts them to the `JsonpClientBackend`.\n */\nfunction jsonpInterceptorFn(req, next) {\n if (req.method === 'JSONP') {\n return inject(JsonpClientBackend).handle(req);\n }\n // Fall through for normal HTTP requests.\n return next(req);\n}\n/**\n * Identifies requests with the method JSONP and\n * shifts them to the `JsonpClientBackend`.\n *\n * @see {@link HttpInterceptor}\n *\n * @publicApi\n */\nclass JsonpInterceptor {\n injector;\n constructor(injector) {\n this.injector = injector;\n }\n /**\n * Identifies and handles a given JSONP request.\n * @param initialRequest The outgoing request object to handle.\n * @param next The next interceptor in the chain, or the backend\n * if no interceptors remain in the chain.\n * @returns An observable of the event stream.\n */\n intercept(initialRequest, next) {\n return runInInjectionContext(this.injector, () => jsonpInterceptorFn(initialRequest, downstreamRequest => next.handle(downstreamRequest)));\n }\n static ɵfac = function JsonpInterceptor_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || JsonpInterceptor)(i0.ɵɵinject(i0.EnvironmentInjector));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: JsonpInterceptor,\n factory: JsonpInterceptor.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(JsonpInterceptor, [{\n type: Injectable\n }], () => [{\n type: i0.EnvironmentInjector\n }], null);\n})();\nconst XSSI_PREFIX = /^\\)\\]\\}',?\\n/;\nconst X_REQUEST_URL_REGEXP = RegExp(`^${X_REQUEST_URL_HEADER}:`, 'm');\n/**\n * Determine an appropriate URL for the response, by checking either\n * XMLHttpRequest.responseURL or the X-Request-URL header.\n */\nfunction getResponseUrl(xhr) {\n if ('responseURL' in xhr && xhr.responseURL) {\n return xhr.responseURL;\n }\n if (X_REQUEST_URL_REGEXP.test(xhr.getAllResponseHeaders())) {\n return xhr.getResponseHeader(X_REQUEST_URL_HEADER);\n }\n return null;\n}\n/**\n * Uses `XMLHttpRequest` to send requests to a backend server.\n * @see {@link HttpHandler}\n * @see {@link JsonpClientBackend}\n *\n * @publicApi\n */\nclass HttpXhrBackend {\n xhrFactory;\n constructor(xhrFactory) {\n this.xhrFactory = xhrFactory;\n }\n /**\n * Processes a request and returns a stream of response events.\n * @param req The request object.\n * @returns An observable of the response events.\n */\n handle(req) {\n // Quick check to give a better error message when a user attempts to use\n // HttpClient.jsonp() without installing the HttpClientJsonpModule\n if (req.method === 'JSONP') {\n throw new ɵRuntimeError(-2800 /* RuntimeErrorCode.MISSING_JSONP_MODULE */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Cannot make a JSONP request without JSONP support. To fix the problem, either add the \\`withJsonpSupport()\\` call (if \\`provideHttpClient()\\` is used) or import the \\`HttpClientJsonpModule\\` in the root NgModule.`);\n }\n // Check whether this factory has a special function to load an XHR implementation\n // for various non-browser environments. We currently limit it to only `ServerXhr`\n // class, which needs to load an XHR implementation.\n const xhrFactory = this.xhrFactory;\n const source = xhrFactory.ɵloadImpl ? from(xhrFactory.ɵloadImpl()) : of(null);\n return source.pipe(switchMap(() => {\n // Everything happens on Observable subscription.\n return new Observable(observer => {\n // Start by setting up the XHR object with request method, URL, and withCredentials\n // flag.\n const xhr = xhrFactory.build();\n xhr.open(req.method, req.urlWithParams);\n if (req.withCredentials) {\n xhr.withCredentials = true;\n }\n // Add all the requested headers.\n req.headers.forEach((name, values) => xhr.setRequestHeader(name, values.join(',')));\n // Add an Accept header if one isn't present already.\n if (!req.headers.has(ACCEPT_HEADER)) {\n xhr.setRequestHeader(ACCEPT_HEADER, ACCEPT_HEADER_VALUE);\n }\n // Auto-detect the Content-Type header if one isn't present already.\n if (!req.headers.has(CONTENT_TYPE_HEADER)) {\n const detectedType = req.detectContentTypeHeader();\n // Sometimes Content-Type detection fails.\n if (detectedType !== null) {\n xhr.setRequestHeader(CONTENT_TYPE_HEADER, detectedType);\n }\n }\n // Set the responseType if one was requested.\n if (req.responseType) {\n const responseType = req.responseType.toLowerCase();\n // JSON responses need to be processed as text. This is because if the server\n // returns an XSSI-prefixed JSON response, the browser will fail to parse it,\n // xhr.response will be null, and xhr.responseText cannot be accessed to\n // retrieve the prefixed JSON data in order to strip the prefix. Thus, all JSON\n // is parsed by first requesting text and then applying JSON.parse.\n xhr.responseType = responseType !== 'json' ? responseType : 'text';\n }\n // Serialize the request body if one is present. If not, this will be set to null.\n const reqBody = req.serializeBody();\n // If progress events are enabled, response headers will be delivered\n // in two events - the HttpHeaderResponse event and the full HttpResponse\n // event. However, since response headers don't change in between these\n // two events, it doesn't make sense to parse them twice. So headerResponse\n // caches the data extracted from the response whenever it's first parsed,\n // to ensure parsing isn't duplicated.\n let headerResponse = null;\n // partialFromXhr extracts the HttpHeaderResponse from the current XMLHttpRequest\n // state, and memoizes it into headerResponse.\n const partialFromXhr = () => {\n if (headerResponse !== null) {\n return headerResponse;\n }\n const statusText = xhr.statusText || 'OK';\n // Parse headers from XMLHttpRequest - this step is lazy.\n const headers = new HttpHeaders(xhr.getAllResponseHeaders());\n // Read the response URL from the XMLHttpResponse instance and fall back on the\n // request URL.\n const url = getResponseUrl(xhr) || req.url;\n // Construct the HttpHeaderResponse and memoize it.\n headerResponse = new HttpHeaderResponse({\n headers,\n status: xhr.status,\n statusText,\n url\n });\n return headerResponse;\n };\n // Next, a few closures are defined for the various events which XMLHttpRequest can\n // emit. This allows them to be unregistered as event listeners later.\n // First up is the load event, which represents a response being fully available.\n const onLoad = () => {\n // Read response state from the memoized partial data.\n let {\n headers,\n status,\n statusText,\n url\n } = partialFromXhr();\n // The body will be read out if present.\n let body = null;\n if (status !== HTTP_STATUS_CODE_NO_CONTENT) {\n // Use XMLHttpRequest.response if set, responseText otherwise.\n body = typeof xhr.response === 'undefined' ? xhr.responseText : xhr.response;\n }\n // Normalize another potential bug (this one comes from CORS).\n if (status === 0) {\n status = !!body ? HTTP_STATUS_CODE_OK : 0;\n }\n // ok determines whether the response will be transmitted on the event or\n // error channel. Unsuccessful status codes (not 2xx) will always be errors,\n // but a successful status code can still result in an error if the user\n // asked for JSON data and the body cannot be parsed as such.\n let ok = status >= 200 && status < 300;\n // Check whether the body needs to be parsed as JSON (in many cases the browser\n // will have done that already).\n if (req.responseType === 'json' && typeof body === 'string') {\n // Save the original body, before attempting XSSI prefix stripping.\n const originalBody = body;\n body = body.replace(XSSI_PREFIX, '');\n try {\n // Attempt the parse. If it fails, a parse error should be delivered to the\n // user.\n body = body !== '' ? JSON.parse(body) : null;\n } catch (error) {\n // Since the JSON.parse failed, it's reasonable to assume this might not have\n // been a JSON response. Restore the original body (including any XSSI prefix)\n // to deliver a better error response.\n body = originalBody;\n // If this was an error request to begin with, leave it as a string, it\n // probably just isn't JSON. Otherwise, deliver the parsing error to the user.\n if (ok) {\n // Even though the response status was 2xx, this is still an error.\n ok = false;\n // The parse error contains the text of the body that failed to parse.\n body = {\n error,\n text: body\n };\n }\n }\n }\n if (ok) {\n // A successful response is delivered on the event stream.\n observer.next(new HttpResponse({\n body,\n headers,\n status,\n statusText,\n url: url || undefined\n }));\n // The full body has been received and delivered, no further events\n // are possible. This request is complete.\n observer.complete();\n } else {\n // An unsuccessful request is delivered on the error channel.\n observer.error(new HttpErrorResponse({\n // The error in this case is the response body (error from the server).\n error: body,\n headers,\n status,\n statusText,\n url: url || undefined\n }));\n }\n };\n // The onError callback is called when something goes wrong at the network level.\n // Connection timeout, DNS error, offline, etc. These are actual errors, and are\n // transmitted on the error channel.\n const onError = error => {\n const {\n url\n } = partialFromXhr();\n const res = new HttpErrorResponse({\n error,\n status: xhr.status || 0,\n statusText: xhr.statusText || 'Unknown Error',\n url: url || undefined\n });\n observer.error(res);\n };\n // The sentHeaders flag tracks whether the HttpResponseHeaders event\n // has been sent on the stream. This is necessary to track if progress\n // is enabled since the event will be sent on only the first download\n // progress event.\n let sentHeaders = false;\n // The download progress event handler, which is only registered if\n // progress events are enabled.\n const onDownProgress = event => {\n // Send the HttpResponseHeaders event if it hasn't been sent already.\n if (!sentHeaders) {\n observer.next(partialFromXhr());\n sentHeaders = true;\n }\n // Start building the download progress event to deliver on the response\n // event stream.\n let progressEvent = {\n type: HttpEventType.DownloadProgress,\n loaded: event.loaded\n };\n // Set the total number of bytes in the event if it's available.\n if (event.lengthComputable) {\n progressEvent.total = event.total;\n }\n // If the request was for text content and a partial response is\n // available on XMLHttpRequest, include it in the progress event\n // to allow for streaming reads.\n if (req.responseType === 'text' && !!xhr.responseText) {\n progressEvent.partialText = xhr.responseText;\n }\n // Finally, fire the event.\n observer.next(progressEvent);\n };\n // The upload progress event handler, which is only registered if\n // progress events are enabled.\n const onUpProgress = event => {\n // Upload progress events are simpler. Begin building the progress\n // event.\n let progress = {\n type: HttpEventType.UploadProgress,\n loaded: event.loaded\n };\n // If the total number of bytes being uploaded is available, include\n // it.\n if (event.lengthComputable) {\n progress.total = event.total;\n }\n // Send the event.\n observer.next(progress);\n };\n // By default, register for load and error events.\n xhr.addEventListener('load', onLoad);\n xhr.addEventListener('error', onError);\n xhr.addEventListener('timeout', onError);\n xhr.addEventListener('abort', onError);\n // Progress events are only enabled if requested.\n if (req.reportProgress) {\n // Download progress is always enabled if requested.\n xhr.addEventListener('progress', onDownProgress);\n // Upload progress depends on whether there is a body to upload.\n if (reqBody !== null && xhr.upload) {\n xhr.upload.addEventListener('progress', onUpProgress);\n }\n }\n // Fire the request, and notify the event stream that it was fired.\n xhr.send(reqBody);\n observer.next({\n type: HttpEventType.Sent\n });\n // This is the return from the Observable function, which is the\n // request cancellation handler.\n return () => {\n // On a cancellation, remove all registered event listeners.\n xhr.removeEventListener('error', onError);\n xhr.removeEventListener('abort', onError);\n xhr.removeEventListener('load', onLoad);\n xhr.removeEventListener('timeout', onError);\n if (req.reportProgress) {\n xhr.removeEventListener('progress', onDownProgress);\n if (reqBody !== null && xhr.upload) {\n xhr.upload.removeEventListener('progress', onUpProgress);\n }\n }\n // Finally, abort the in-flight request.\n if (xhr.readyState !== xhr.DONE) {\n xhr.abort();\n }\n };\n });\n }));\n }\n static ɵfac = function HttpXhrBackend_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpXhrBackend)(i0.ɵɵinject(i1.XhrFactory));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HttpXhrBackend,\n factory: HttpXhrBackend.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpXhrBackend, [{\n type: Injectable\n }], () => [{\n type: i1.XhrFactory\n }], null);\n})();\nconst XSRF_ENABLED = new InjectionToken(ngDevMode ? 'XSRF_ENABLED' : '');\nconst XSRF_DEFAULT_COOKIE_NAME = 'XSRF-TOKEN';\nconst XSRF_COOKIE_NAME = new InjectionToken(ngDevMode ? 'XSRF_COOKIE_NAME' : '', {\n providedIn: 'root',\n factory: () => XSRF_DEFAULT_COOKIE_NAME\n});\nconst XSRF_DEFAULT_HEADER_NAME = 'X-XSRF-TOKEN';\nconst XSRF_HEADER_NAME = new InjectionToken(ngDevMode ? 'XSRF_HEADER_NAME' : '', {\n providedIn: 'root',\n factory: () => XSRF_DEFAULT_HEADER_NAME\n});\n/**\n * Retrieves the current XSRF token to use with the next outgoing request.\n *\n * @publicApi\n */\nclass HttpXsrfTokenExtractor {}\n/**\n * `HttpXsrfTokenExtractor` which retrieves the token from a cookie.\n */\nclass HttpXsrfCookieExtractor {\n doc;\n platform;\n cookieName;\n lastCookieString = '';\n lastToken = null;\n /**\n * @internal for testing\n */\n parseCount = 0;\n constructor(doc, platform, cookieName) {\n this.doc = doc;\n this.platform = platform;\n this.cookieName = cookieName;\n }\n getToken() {\n if (this.platform === 'server') {\n return null;\n }\n const cookieString = this.doc.cookie || '';\n if (cookieString !== this.lastCookieString) {\n this.parseCount++;\n this.lastToken = ɵparseCookieValue(cookieString, this.cookieName);\n this.lastCookieString = cookieString;\n }\n return this.lastToken;\n }\n static ɵfac = function HttpXsrfCookieExtractor_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpXsrfCookieExtractor)(i0.ɵɵinject(DOCUMENT), i0.ɵɵinject(PLATFORM_ID), i0.ɵɵinject(XSRF_COOKIE_NAME));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HttpXsrfCookieExtractor,\n factory: HttpXsrfCookieExtractor.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpXsrfCookieExtractor, [{\n type: Injectable\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [PLATFORM_ID]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [XSRF_COOKIE_NAME]\n }]\n }], null);\n})();\nfunction xsrfInterceptorFn(req, next) {\n const lcUrl = req.url.toLowerCase();\n // Skip both non-mutating requests and absolute URLs.\n // Non-mutating requests don't require a token, and absolute URLs require special handling\n // anyway as the cookie set\n // on our origin is not the same as the token expected by another origin.\n if (!inject(XSRF_ENABLED) || req.method === 'GET' || req.method === 'HEAD' || lcUrl.startsWith('http://') || lcUrl.startsWith('https://')) {\n return next(req);\n }\n const token = inject(HttpXsrfTokenExtractor).getToken();\n const headerName = inject(XSRF_HEADER_NAME);\n // Be careful not to overwrite an existing header of the same name.\n if (token != null && !req.headers.has(headerName)) {\n req = req.clone({\n headers: req.headers.set(headerName, token)\n });\n }\n return next(req);\n}\n/**\n * `HttpInterceptor` which adds an XSRF token to eligible outgoing requests.\n */\nclass HttpXsrfInterceptor {\n injector;\n constructor(injector) {\n this.injector = injector;\n }\n intercept(initialRequest, next) {\n return runInInjectionContext(this.injector, () => xsrfInterceptorFn(initialRequest, downstreamRequest => next.handle(downstreamRequest)));\n }\n static ɵfac = function HttpXsrfInterceptor_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpXsrfInterceptor)(i0.ɵɵinject(i0.EnvironmentInjector));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HttpXsrfInterceptor,\n factory: HttpXsrfInterceptor.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpXsrfInterceptor, [{\n type: Injectable\n }], () => [{\n type: i0.EnvironmentInjector\n }], null);\n})();\n\n/**\n * Identifies a particular kind of `HttpFeature`.\n *\n * @publicApi\n */\nvar HttpFeatureKind;\n(function (HttpFeatureKind) {\n HttpFeatureKind[HttpFeatureKind[\"Interceptors\"] = 0] = \"Interceptors\";\n HttpFeatureKind[HttpFeatureKind[\"LegacyInterceptors\"] = 1] = \"LegacyInterceptors\";\n HttpFeatureKind[HttpFeatureKind[\"CustomXsrfConfiguration\"] = 2] = \"CustomXsrfConfiguration\";\n HttpFeatureKind[HttpFeatureKind[\"NoXsrfProtection\"] = 3] = \"NoXsrfProtection\";\n HttpFeatureKind[HttpFeatureKind[\"JsonpSupport\"] = 4] = \"JsonpSupport\";\n HttpFeatureKind[HttpFeatureKind[\"RequestsMadeViaParent\"] = 5] = \"RequestsMadeViaParent\";\n HttpFeatureKind[HttpFeatureKind[\"Fetch\"] = 6] = \"Fetch\";\n})(HttpFeatureKind || (HttpFeatureKind = {}));\nfunction makeHttpFeature(kind, providers) {\n return {\n ɵkind: kind,\n ɵproviders: providers\n };\n}\n/**\n * Configures Angular's `HttpClient` service to be available for injection.\n *\n * By default, `HttpClient` will be configured for injection with its default options for XSRF\n * protection of outgoing requests. Additional configuration options can be provided by passing\n * feature functions to `provideHttpClient`. For example, HTTP interceptors can be added using the\n * `withInterceptors(...)` feature.\n *\n * <div class=\"docs-alert docs-alert-helpful\">\n *\n * It's strongly recommended to enable\n * [`fetch`](https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API) for applications that use\n * Server-Side Rendering for better performance and compatibility. To enable `fetch`, add\n * `withFetch()` feature to the `provideHttpClient()` call at the root of the application:\n *\n * ```ts\n * provideHttpClient(withFetch());\n * ```\n *\n * </div>\n *\n * @see {@link withInterceptors}\n * @see {@link withInterceptorsFromDi}\n * @see {@link withXsrfConfiguration}\n * @see {@link withNoXsrfProtection}\n * @see {@link withJsonpSupport}\n * @see {@link withRequestsMadeViaParent}\n * @see {@link withFetch}\n */\nfunction provideHttpClient(...features) {\n if (ngDevMode) {\n const featureKinds = new Set(features.map(f => f.ɵkind));\n if (featureKinds.has(HttpFeatureKind.NoXsrfProtection) && featureKinds.has(HttpFeatureKind.CustomXsrfConfiguration)) {\n throw new Error(ngDevMode ? `Configuration error: found both withXsrfConfiguration() and withNoXsrfProtection() in the same call to provideHttpClient(), which is a contradiction.` : '');\n }\n }\n const providers = [HttpClient, HttpXhrBackend, HttpInterceptorHandler, {\n provide: HttpHandler,\n useExisting: HttpInterceptorHandler\n }, {\n provide: HttpBackend,\n useFactory: () => {\n return inject(FETCH_BACKEND, {\n optional: true\n }) ?? inject(HttpXhrBackend);\n }\n }, {\n provide: HTTP_INTERCEPTOR_FNS,\n useValue: xsrfInterceptorFn,\n multi: true\n }, {\n provide: XSRF_ENABLED,\n useValue: true\n }, {\n provide: HttpXsrfTokenExtractor,\n useClass: HttpXsrfCookieExtractor\n }];\n for (const feature of features) {\n providers.push(...feature.ɵproviders);\n }\n return makeEnvironmentProviders(providers);\n}\n/**\n * Adds one or more functional-style HTTP interceptors to the configuration of the `HttpClient`\n * instance.\n *\n * @see {@link HttpInterceptorFn}\n * @see {@link provideHttpClient}\n * @publicApi\n */\nfunction withInterceptors(interceptorFns) {\n return makeHttpFeature(HttpFeatureKind.Interceptors, interceptorFns.map(interceptorFn => {\n return {\n provide: HTTP_INTERCEPTOR_FNS,\n useValue: interceptorFn,\n multi: true\n };\n }));\n}\nconst LEGACY_INTERCEPTOR_FN = new InjectionToken(ngDevMode ? 'LEGACY_INTERCEPTOR_FN' : '');\n/**\n * Includes class-based interceptors configured using a multi-provider in the current injector into\n * the configured `HttpClient` instance.\n *\n * Prefer `withInterceptors` and functional interceptors instead, as support for DI-provided\n * interceptors may be phased out in a later release.\n *\n * @see {@link HttpInterceptor}\n * @see {@link HTTP_INTERCEPTORS}\n * @see {@link provideHttpClient}\n */\nfunction withInterceptorsFromDi() {\n // Note: the legacy interceptor function is provided here via an intermediate token\n // (`LEGACY_INTERCEPTOR_FN`), using a pattern which guarantees that if these providers are\n // included multiple times, all of the multi-provider entries will have the same instance of the\n // interceptor function. That way, the `HttpINterceptorHandler` will dedup them and legacy\n // interceptors will not run multiple times.\n return makeHttpFeature(HttpFeatureKind.LegacyInterceptors, [{\n provide: LEGACY_INTERCEPTOR_FN,\n useFactory: legacyInterceptorFnFactory\n }, {\n provide: HTTP_INTERCEPTOR_FNS,\n useExisting: LEGACY_INTERCEPTOR_FN,\n multi: true\n }]);\n}\n/**\n * Customizes the XSRF protection for the configuration of the current `HttpClient` instance.\n *\n * This feature is incompatible with the `withNoXsrfProtection` feature.\n *\n * @see {@link provideHttpClient}\n */\nfunction withXsrfConfiguration({\n cookieName,\n headerName\n}) {\n const providers = [];\n if (cookieName !== undefined) {\n providers.push({\n provide: XSRF_COOKIE_NAME,\n useValue: cookieName\n });\n }\n if (headerName !== undefined) {\n providers.push({\n provide: XSRF_HEADER_NAME,\n useValue: headerName\n });\n }\n return makeHttpFeature(HttpFeatureKind.CustomXsrfConfiguration, providers);\n}\n/**\n * Disables XSRF protection in the configuration of the current `HttpClient` instance.\n *\n * This feature is incompatible with the `withXsrfConfiguration` feature.\n *\n * @see {@link provideHttpClient}\n */\nfunction withNoXsrfProtection() {\n return makeHttpFeature(HttpFeatureKind.NoXsrfProtection, [{\n provide: XSRF_ENABLED,\n useValue: false\n }]);\n}\n/**\n * Add JSONP support to the configuration of the current `HttpClient` instance.\n *\n * @see {@link provideHttpClient}\n */\nfunction withJsonpSupport() {\n return makeHttpFeature(HttpFeatureKind.JsonpSupport, [JsonpClientBackend, {\n provide: JsonpCallbackContext,\n useFactory: jsonpCallbackContext\n }, {\n provide: HTTP_INTERCEPTOR_FNS,\n useValue: jsonpInterceptorFn,\n multi: true\n }]);\n}\n/**\n * Configures the current `HttpClient` instance to make requests via the parent injector's\n * `HttpClient` instead of directly.\n *\n * By default, `provideHttpClient` configures `HttpClient` in its injector to be an independent\n * instance. For example, even if `HttpClient` is configured in the parent injector with\n * one or more interceptors, they will not intercept requests made via this instance.\n *\n * With this option enabled, once the request has passed through the current injector's\n * interceptors, it will be delegated to the parent injector's `HttpClient` chain instead of\n * dispatched directly, and interceptors in the parent configuration will be applied to the request.\n *\n * If there are several `HttpClient` instances in the injector hierarchy, it's possible for\n * `withRequestsMadeViaParent` to be used at multiple levels, which will cause the request to\n * \"bubble up\" until either reaching the root level or an `HttpClient` which was not configured with\n * this option.\n *\n * @see {@link provideHttpClient}\n * @publicApi\n */\nfunction withRequestsMadeViaParent() {\n return makeHttpFeature(HttpFeatureKind.RequestsMadeViaParent, [{\n provide: HttpBackend,\n useFactory: () => {\n const handlerFromParent = inject(HttpHandler, {\n skipSelf: true,\n optional: true\n });\n if (ngDevMode && handlerFromParent === null) {\n throw new Error('withRequestsMadeViaParent() can only be used when the parent injector also configures HttpClient');\n }\n return handlerFromParent;\n }\n }]);\n}\n/**\n * Configures the current `HttpClient` instance to make requests using the fetch API.\n *\n * Note: The Fetch API doesn't support progress report on uploads.\n *\n * @publicApi\n */\nfunction withFetch() {\n return makeHttpFeature(HttpFeatureKind.Fetch, [FetchBackend, {\n provide: FETCH_BACKEND,\n useExisting: FetchBackend\n }, {\n provide: HttpBackend,\n useExisting: FetchBackend\n }]);\n}\n\n/**\n * Configures XSRF protection support for outgoing requests.\n *\n * For a server that supports a cookie-based XSRF protection system,\n * use directly to configure XSRF protection with the correct\n * cookie and header names.\n *\n * If no names are supplied, the default cookie name is `XSRF-TOKEN`\n * and the default header name is `X-XSRF-TOKEN`.\n *\n * @publicApi\n * @deprecated Use withXsrfConfiguration({cookieName: 'XSRF-TOKEN', headerName: 'X-XSRF-TOKEN'}) as\n * providers instead or `withNoXsrfProtection` if you want to disabled XSRF protection.\n */\nclass HttpClientXsrfModule {\n /**\n * Disable the default XSRF protection.\n */\n static disable() {\n return {\n ngModule: HttpClientXsrfModule,\n providers: [withNoXsrfProtection().ɵproviders]\n };\n }\n /**\n * Configure XSRF protection.\n * @param options An object that can specify either or both\n * cookie name or header name.\n * - Cookie name default is `XSRF-TOKEN`.\n * - Header name default is `X-XSRF-TOKEN`.\n *\n */\n static withOptions(options = {}) {\n return {\n ngModule: HttpClientXsrfModule,\n providers: withXsrfConfiguration(options).ɵproviders\n };\n }\n static ɵfac = function HttpClientXsrfModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpClientXsrfModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: HttpClientXsrfModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n providers: [HttpXsrfInterceptor, {\n provide: HTTP_INTERCEPTORS,\n useExisting: HttpXsrfInterceptor,\n multi: true\n }, {\n provide: HttpXsrfTokenExtractor,\n useClass: HttpXsrfCookieExtractor\n }, withXsrfConfiguration({\n cookieName: XSRF_DEFAULT_COOKIE_NAME,\n headerName: XSRF_DEFAULT_HEADER_NAME\n }).ɵproviders, {\n provide: XSRF_ENABLED,\n useValue: true\n }]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpClientXsrfModule, [{\n type: NgModule,\n args: [{\n providers: [HttpXsrfInterceptor, {\n provide: HTTP_INTERCEPTORS,\n useExisting: HttpXsrfInterceptor,\n multi: true\n }, {\n provide: HttpXsrfTokenExtractor,\n useClass: HttpXsrfCookieExtractor\n }, withXsrfConfiguration({\n cookieName: XSRF_DEFAULT_COOKIE_NAME,\n headerName: XSRF_DEFAULT_HEADER_NAME\n }).ɵproviders, {\n provide: XSRF_ENABLED,\n useValue: true\n }]\n }]\n }], null, null);\n})();\n/**\n * Configures the dependency injector for `HttpClient`\n * with supporting services for XSRF. Automatically imported by `HttpClientModule`.\n *\n * You can add interceptors to the chain behind `HttpClient` by binding them to the\n * multiprovider for built-in DI token `HTTP_INTERCEPTORS`.\n *\n * @publicApi\n * @deprecated use `provideHttpClient(withInterceptorsFromDi())` as providers instead\n */\nclass HttpClientModule {\n static ɵfac = function HttpClientModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpClientModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: HttpClientModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n providers: [provideHttpClient(withInterceptorsFromDi())]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpClientModule, [{\n type: NgModule,\n args: [{\n /**\n * Configures the dependency injector where it is imported\n * with supporting services for HTTP communications.\n */\n providers: [provideHttpClient(withInterceptorsFromDi())]\n }]\n }], null, null);\n})();\n/**\n * Configures the dependency injector for `HttpClient`\n * with supporting services for JSONP.\n * Without this module, Jsonp requests reach the backend\n * with method JSONP, where they are rejected.\n *\n * @publicApi\n * @deprecated `withJsonpSupport()` as providers instead\n */\nclass HttpClientJsonpModule {\n static ɵfac = function HttpClientJsonpModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HttpClientJsonpModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: HttpClientJsonpModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n providers: [withJsonpSupport().ɵproviders]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HttpClientJsonpModule, [{\n type: NgModule,\n args: [{\n providers: [withJsonpSupport().ɵproviders]\n }]\n }], null, null);\n})();\n\n/**\n * `httpResource` makes a reactive HTTP request and exposes the request status and response value as\n * a `WritableResource`. By default, it assumes that the backend will return JSON data. To make a\n * request that expects a different kind of data, you can use a sub-constructor of `httpResource`,\n * such as `httpResource.text`.\n *\n * @experimental\n * @initializerApiFunction\n */\nconst httpResource = (() => {\n const jsonFn = makeHttpResourceFn('json');\n jsonFn.arrayBuffer = makeHttpResourceFn('arraybuffer');\n jsonFn.blob = makeHttpResourceFn('blob');\n jsonFn.text = makeHttpResourceFn('text');\n return jsonFn;\n})();\nfunction makeHttpResourceFn(responseType) {\n return function httpResourceRef(request, options) {\n options?.injector || assertInInjectionContext(httpResource);\n const injector = options?.injector ?? inject(Injector);\n return new HttpResourceImpl(injector, () => normalizeRequest(request, responseType), options?.defaultValue, options?.parse);\n };\n}\nfunction normalizeRequest(request, responseType) {\n let unwrappedRequest = typeof request === 'function' ? request() : request;\n if (unwrappedRequest === undefined) {\n return undefined;\n } else if (typeof unwrappedRequest === 'string') {\n unwrappedRequest = {\n url: unwrappedRequest\n };\n }\n const headers = unwrappedRequest.headers instanceof HttpHeaders ? unwrappedRequest.headers : new HttpHeaders(unwrappedRequest.headers);\n const params = unwrappedRequest.params instanceof HttpParams ? unwrappedRequest.params : new HttpParams({\n fromObject: unwrappedRequest.params\n });\n return new HttpRequest(unwrappedRequest.method ?? 'GET', unwrappedRequest.url, unwrappedRequest.body ?? null, {\n headers,\n params,\n reportProgress: unwrappedRequest.reportProgress,\n withCredentials: unwrappedRequest.withCredentials,\n responseType\n });\n}\nclass HttpResourceImpl extends ɵResourceImpl {\n client;\n _headers = linkedSignal({\n source: this.extRequest,\n computation: () => undefined\n });\n _progress = linkedSignal({\n source: this.extRequest,\n computation: () => undefined\n });\n _statusCode = linkedSignal({\n source: this.extRequest,\n computation: () => undefined\n });\n headers = computed(() => this.status() === ResourceStatus.Resolved || this.status() === ResourceStatus.Error ? this._headers() : undefined);\n progress = this._progress.asReadonly();\n statusCode = this._statusCode.asReadonly();\n constructor(injector, request, defaultValue, parse) {\n super(request, ({\n request,\n abortSignal\n }) => {\n let sub;\n // Track the abort listener so it can be removed if the Observable completes (as a memory\n // optimization).\n const onAbort = () => sub.unsubscribe();\n abortSignal.addEventListener('abort', onAbort);\n // Start off stream as undefined.\n const stream = signal({\n value: undefined\n });\n let resolve;\n const promise = new Promise(r => resolve = r);\n const send = value => {\n stream.set(value);\n resolve?.(stream);\n resolve = undefined;\n };\n sub = this.client.request(request).subscribe({\n next: event => {\n switch (event.type) {\n case HttpEventType.Response:\n this._headers.set(event.headers);\n this._statusCode.set(event.status);\n try {\n send({\n value: parse ? parse(event.body) : event.body\n });\n } catch (error) {\n send({\n error\n });\n }\n break;\n case HttpEventType.DownloadProgress:\n this._progress.set(event);\n break;\n }\n },\n error: error => send({\n error\n }),\n complete: () => {\n if (resolve) {\n send({\n error: new Error('Resource completed before producing a value')\n });\n }\n abortSignal.removeEventListener('abort', onAbort);\n }\n });\n return promise;\n }, defaultValue, undefined, injector);\n this.client = injector.get(HttpClient);\n }\n hasValue() {\n return super.hasValue();\n }\n}\n/**\n * A `Resource` of the `HttpResponse` meant for use in `HttpResource` if we decide to go this route.\n *\n * TODO(alxhub): delete this if we decide we don't want it.\n */\nclass HttpResponseResource {\n parent;\n status;\n value;\n error;\n isLoading;\n constructor(parent, request) {\n this.parent = parent;\n this.status = computed(() => {\n // There are two kinds of errors which can occur in an HTTP request: HTTP errors or normal JS\n // errors. Since we have a response for HTTP errors, we report `Resolved` status even if the\n // overall request is considered to be in an Error state.\n if (parent.status() === ResourceStatus.Error) {\n return this.value() !== undefined ? ResourceStatus.Resolved : ResourceStatus.Error;\n }\n return parent.status();\n });\n this.error = computed(() => {\n // Filter out HTTP errors.\n return this.value() === undefined ? parent.error() : undefined;\n });\n this.value = linkedSignal({\n source: request,\n computation: () => undefined\n });\n this.isLoading = parent.isLoading;\n }\n hasValue() {\n return this.value() !== undefined;\n }\n reload() {\n // TODO: should you be able to reload this way?\n return this.parent.reload();\n }\n}\n\n/**\n * If your application uses different HTTP origins to make API calls (via `HttpClient`) on the server and\n * on the client, the `HTTP_TRANSFER_CACHE_ORIGIN_MAP` token allows you to establish a mapping\n * between those origins, so that `HttpTransferCache` feature can recognize those requests as the same\n * ones and reuse the data cached on the server during hydration on the client.\n *\n * **Important note**: the `HTTP_TRANSFER_CACHE_ORIGIN_MAP` token should *only* be provided in\n * the *server* code of your application (typically in the `app.server.config.ts` script). Angular throws an\n * error if it detects that the token is defined while running on the client.\n *\n * @usageNotes\n *\n * When the same API endpoint is accessed via `http://internal-domain.com:8080` on the server and\n * via `https://external-domain.com` on the client, you can use the following configuration:\n * ```ts\n * // in app.server.config.ts\n * {\n * provide: HTTP_TRANSFER_CACHE_ORIGIN_MAP,\n * useValue: {\n * 'http://internal-domain.com:8080': 'https://external-domain.com'\n * }\n * }\n * ```\n *\n * @publicApi\n */\nconst HTTP_TRANSFER_CACHE_ORIGIN_MAP = new InjectionToken(ngDevMode ? 'HTTP_TRANSFER_CACHE_ORIGIN_MAP' : '');\n/**\n * Keys within cached response data structure.\n */\nconst BODY = 'b';\nconst HEADERS = 'h';\nconst STATUS = 's';\nconst STATUS_TEXT = 'st';\nconst REQ_URL = 'u';\nconst RESPONSE_TYPE = 'rt';\nconst CACHE_OPTIONS = new InjectionToken(ngDevMode ? 'HTTP_TRANSFER_STATE_CACHE_OPTIONS' : '');\n/**\n * A list of allowed HTTP methods to cache.\n */\nconst ALLOWED_METHODS = ['GET', 'HEAD'];\nfunction transferCacheInterceptorFn(req, next) {\n const {\n isCacheActive,\n ...globalOptions\n } = inject(CACHE_OPTIONS);\n const {\n transferCache: requestOptions,\n method: requestMethod\n } = req;\n // In the following situations we do not want to cache the request\n if (!isCacheActive || requestOptions === false ||\n // POST requests are allowed either globally or at request level\n requestMethod === 'POST' && !globalOptions.includePostRequests && !requestOptions || requestMethod !== 'POST' && !ALLOWED_METHODS.includes(requestMethod) ||\n // Do not cache request that require authorization when includeRequestsWithAuthHeaders is falsey\n !globalOptions.includeRequestsWithAuthHeaders && hasAuthHeaders(req) || globalOptions.filter?.(req) === false) {\n return next(req);\n }\n const transferState = inject(TransferState);\n const originMap = inject(HTTP_TRANSFER_CACHE_ORIGIN_MAP, {\n optional: true\n });\n if (typeof ngServerMode !== 'undefined' && !ngServerMode && originMap) {\n throw new ɵRuntimeError(2803 /* RuntimeErrorCode.HTTP_ORIGIN_MAP_USED_IN_CLIENT */, ngDevMode && 'Angular detected that the `HTTP_TRANSFER_CACHE_ORIGIN_MAP` token is configured and ' + 'present in the client side code. Please ensure that this token is only provided in the ' + 'server code of the application.');\n }\n const requestUrl = typeof ngServerMode !== 'undefined' && ngServerMode && originMap ? mapRequestOriginUrl(req.url, originMap) : req.url;\n const storeKey = makeCacheKey(req, requestUrl);\n const response = transferState.get(storeKey, null);\n let headersToInclude = globalOptions.includeHeaders;\n if (typeof requestOptions === 'object' && requestOptions.includeHeaders) {\n // Request-specific config takes precedence over the global config.\n headersToInclude = requestOptions.includeHeaders;\n }\n if (response) {\n const {\n [BODY]: undecodedBody,\n [RESPONSE_TYPE]: responseType,\n [HEADERS]: httpHeaders,\n [STATUS]: status,\n [STATUS_TEXT]: statusText,\n [REQ_URL]: url\n } = response;\n // Request found in cache. Respond using it.\n let body = undecodedBody;\n switch (responseType) {\n case 'arraybuffer':\n body = new TextEncoder().encode(undecodedBody).buffer;\n break;\n case 'blob':\n body = new Blob([undecodedBody]);\n break;\n }\n // We want to warn users accessing a header provided from the cache\n // That HttpTransferCache alters the headers\n // The warning will be logged a single time by HttpHeaders instance\n let headers = new HttpHeaders(httpHeaders);\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n // Append extra logic in dev mode to produce a warning when a header\n // that was not transferred to the client is accessed in the code via `get`\n // and `has` calls.\n headers = appendMissingHeadersDetection(req.url, headers, headersToInclude ?? []);\n }\n return of(new HttpResponse({\n body,\n headers,\n status,\n statusText,\n url\n }));\n }\n // Request not found in cache. Make the request and cache it if on the server.\n return next(req).pipe(tap(event => {\n if (event instanceof HttpResponse && typeof ngServerMode !== 'undefined' && ngServerMode) {\n transferState.set(storeKey, {\n [BODY]: event.body,\n [HEADERS]: getFilteredHeaders(event.headers, headersToInclude),\n [STATUS]: event.status,\n [STATUS_TEXT]: event.statusText,\n [REQ_URL]: requestUrl,\n [RESPONSE_TYPE]: req.responseType\n });\n }\n }));\n}\n/** @returns true when the requests contains autorization related headers. */\nfunction hasAuthHeaders(req) {\n return req.headers.has('authorization') || req.headers.has('proxy-authorization');\n}\nfunction getFilteredHeaders(headers, includeHeaders) {\n if (!includeHeaders) {\n return {};\n }\n const headersMap = {};\n for (const key of includeHeaders) {\n const values = headers.getAll(key);\n if (values !== null) {\n headersMap[key] = values;\n }\n }\n return headersMap;\n}\nfunction sortAndConcatParams(params) {\n return [...params.keys()].sort().map(k => `${k}=${params.getAll(k)}`).join('&');\n}\nfunction makeCacheKey(request, mappedRequestUrl) {\n // make the params encoded same as a url so it's easy to identify\n const {\n params,\n method,\n responseType\n } = request;\n const encodedParams = sortAndConcatParams(params);\n let serializedBody = request.serializeBody();\n if (serializedBody instanceof URLSearchParams) {\n serializedBody = sortAndConcatParams(serializedBody);\n } else if (typeof serializedBody !== 'string') {\n serializedBody = '';\n }\n const key = [method, responseType, mappedRequestUrl, serializedBody, encodedParams].join('|');\n const hash = generateHash(key);\n return makeStateKey(hash);\n}\n/**\n * A method that returns a hash representation of a string using a variant of DJB2 hash\n * algorithm.\n *\n * This is the same hashing logic that is used to generate component ids.\n */\nfunction generateHash(value) {\n let hash = 0;\n for (const char of value) {\n hash = Math.imul(31, hash) + char.charCodeAt(0) << 0;\n }\n // Force positive number hash.\n // 2147483647 = equivalent of Integer.MAX_VALUE.\n hash += 2147483647 + 1;\n return hash.toString();\n}\n/**\n * Returns the DI providers needed to enable HTTP transfer cache.\n *\n * By default, when using server rendering, requests are performed twice: once on the server and\n * other one on the browser.\n *\n * When these providers are added, requests performed on the server are cached and reused during the\n * bootstrapping of the application in the browser thus avoiding duplicate requests and reducing\n * load time.\n *\n */\nfunction withHttpTransferCache(cacheOptions) {\n return [{\n provide: CACHE_OPTIONS,\n useFactory: () => {\n ɵperformanceMarkFeature('NgHttpTransferCache');\n return {\n isCacheActive: true,\n ...cacheOptions\n };\n }\n }, {\n provide: HTTP_ROOT_INTERCEPTOR_FNS,\n useValue: transferCacheInterceptorFn,\n multi: true\n }, {\n provide: APP_BOOTSTRAP_LISTENER,\n multi: true,\n useFactory: () => {\n const appRef = inject(ApplicationRef);\n const cacheState = inject(CACHE_OPTIONS);\n return () => {\n appRef.whenStable().then(() => {\n cacheState.isCacheActive = false;\n });\n };\n }\n }];\n}\n/**\n * This function will add a proxy to an HttpHeader to intercept calls to get/has\n * and log a warning if the header entry requested has been removed\n */\nfunction appendMissingHeadersDetection(url, headers, headersToInclude) {\n const warningProduced = new Set();\n return new Proxy(headers, {\n get(target, prop) {\n const value = Reflect.get(target, prop);\n const methods = new Set(['get', 'has', 'getAll']);\n if (typeof value !== 'function' || !methods.has(prop)) {\n return value;\n }\n return headerName => {\n // We log when the key has been removed and a warning hasn't been produced for the header\n const key = (prop + ':' + headerName).toLowerCase(); // e.g. `get:cache-control`\n if (!headersToInclude.includes(headerName) && !warningProduced.has(key)) {\n warningProduced.add(key);\n const truncatedUrl = ɵtruncateMiddle(url);\n // TODO: create Error guide for this warning\n console.warn(ɵformatRuntimeError(2802 /* RuntimeErrorCode.HEADERS_ALTERED_BY_TRANSFER_CACHE */, `Angular detected that the \\`${headerName}\\` header is accessed, but the value of the header ` + `was not transferred from the server to the client by the HttpTransferCache. ` + `To include the value of the \\`${headerName}\\` header for the \\`${truncatedUrl}\\` request, ` + `use the \\`includeHeaders\\` list. The \\`includeHeaders\\` can be defined either ` + `on a request level by adding the \\`transferCache\\` parameter, or on an application ` + `level by adding the \\`httpCacheTransfer.includeHeaders\\` argument to the ` + `\\`provideClientHydration()\\` call. `));\n }\n // invoking the original method\n return value.apply(target, [headerName]);\n };\n }\n });\n}\nfunction mapRequestOriginUrl(url, originMap) {\n const origin = new URL(url, 'resolve://').origin;\n const mappedOrigin = originMap[origin];\n if (!mappedOrigin) {\n return url;\n }\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n verifyMappedOrigin(mappedOrigin);\n }\n return url.replace(origin, mappedOrigin);\n}\nfunction verifyMappedOrigin(url) {\n if (new URL(url, 'resolve://').pathname !== '/') {\n throw new ɵRuntimeError(2804 /* RuntimeErrorCode.HTTP_ORIGIN_MAP_CONTAINS_PATH */, 'Angular detected a URL with a path segment in the value provided for the ' + `\\`HTTP_TRANSFER_CACHE_ORIGIN_MAP\\` token: ${url}. The map should only contain origins ` + 'without any other segments.');\n }\n}\n\n// This file is not used to build this module. It is only used during editing\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { FetchBackend, HTTP_INTERCEPTORS, HTTP_TRANSFER_CACHE_ORIGIN_MAP, HttpBackend, HttpClient, HttpClientJsonpModule, HttpClientModule, HttpClientXsrfModule, HttpContext, HttpContextToken, HttpErrorResponse, HttpEventType, HttpFeatureKind, HttpHandler, HttpHeaderResponse, HttpHeaders, HttpParams, HttpRequest, HttpResponse, HttpResponseBase, HttpStatusCode, HttpUrlEncodingCodec, HttpXhrBackend, HttpXsrfTokenExtractor, JsonpClientBackend, JsonpInterceptor, httpResource, provideHttpClient, withFetch, withInterceptors, withInterceptorsFromDi, withJsonpSupport, withNoXsrfProtection, withRequestsMadeViaParent, withXsrfConfiguration, HTTP_ROOT_INTERCEPTOR_FNS as ɵHTTP_ROOT_INTERCEPTOR_FNS, HttpInterceptorHandler as ɵHttpInterceptingHandler, HttpInterceptorHandler as ɵHttpInterceptorHandler, REQUESTS_CONTRIBUTE_TO_STABILITY as ɵREQUESTS_CONTRIBUTE_TO_STABILITY, withHttpTransferCache as ɵwithHttpTransferCache };\n","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\nimport { ɵDomAdapter, ɵsetRootDomAdapter, ɵparseCookieValue, ɵgetDOM, isPlatformServer, DOCUMENT, ɵPLATFORM_BROWSER_ID, XhrFactory, CommonModule } from '@angular/common';\nexport { ɵgetDOM } from '@angular/common';\nimport * as i0 from '@angular/core';\nimport { ɵglobal, ɵRuntimeError, Injectable, InjectionToken, Inject, APP_ID, CSP_NONCE, PLATFORM_ID, Optional, ViewEncapsulation, ɵTracingService, RendererStyleFlags2, ɵinternalCreateApplication, ErrorHandler, ɵsetDocument, PLATFORM_INITIALIZER, createPlatformFactory, platformCore, ɵTESTABILITY_GETTER, ɵTESTABILITY, Testability, NgZone, TestabilityRegistry, ɵINJECTOR_SCOPE, RendererFactory2, inject, ApplicationModule, NgModule, ApplicationRef, ɵConsole, Injector, forwardRef, ɵXSS_SECURITY_URL, SecurityContext, ɵallowSanitizationBypassAndThrow, ɵunwrapSafeValue, ɵ_sanitizeUrl, ɵ_sanitizeHtml, ɵbypassSanitizationTrustHtml, ɵbypassSanitizationTrustStyle, ɵbypassSanitizationTrustScript, ɵbypassSanitizationTrustUrl, ɵbypassSanitizationTrustResourceUrl, ɵwithI18nSupport, ɵwithEventReplay, ɵwithIncrementalHydration, ENVIRONMENT_INITIALIZER, ɵZONELESS_ENABLED, ɵformatRuntimeError, makeEnvironmentProviders, ɵwithDomHydration, Version } from '@angular/core';\nimport { ɵwithHttpTransferCache } from '@angular/common/http';\n\n/**\n * Provides DOM operations in any browser environment.\n *\n * @security Tread carefully! Interacting with the DOM directly is dangerous and\n * can introduce XSS risks.\n */\nclass GenericBrowserDomAdapter extends ɵDomAdapter {\n supportsDOMEvents = true;\n}\n\n/**\n * A `DomAdapter` powered by full browser DOM APIs.\n *\n * @security Tread carefully! Interacting with the DOM directly is dangerous and\n * can introduce XSS risks.\n */\nclass BrowserDomAdapter extends GenericBrowserDomAdapter {\n static makeCurrent() {\n ɵsetRootDomAdapter(new BrowserDomAdapter());\n }\n onAndCancel(el, evt, listener, options) {\n el.addEventListener(evt, listener, options);\n return () => {\n el.removeEventListener(evt, listener, options);\n };\n }\n dispatchEvent(el, evt) {\n el.dispatchEvent(evt);\n }\n remove(node) {\n node.remove();\n }\n createElement(tagName, doc) {\n doc = doc || this.getDefaultDocument();\n return doc.createElement(tagName);\n }\n createHtmlDocument() {\n return document.implementation.createHTMLDocument('fakeTitle');\n }\n getDefaultDocument() {\n return document;\n }\n isElementNode(node) {\n return node.nodeType === Node.ELEMENT_NODE;\n }\n isShadowRoot(node) {\n return node instanceof DocumentFragment;\n }\n /** @deprecated No longer being used in Ivy code. To be removed in version 14. */\n getGlobalEventTarget(doc, target) {\n if (target === 'window') {\n return window;\n }\n if (target === 'document') {\n return doc;\n }\n if (target === 'body') {\n return doc.body;\n }\n return null;\n }\n getBaseHref(doc) {\n const href = getBaseElementHref();\n return href == null ? null : relativePath(href);\n }\n resetBaseElement() {\n baseElement = null;\n }\n getUserAgent() {\n return window.navigator.userAgent;\n }\n getCookie(name) {\n return ɵparseCookieValue(document.cookie, name);\n }\n}\nlet baseElement = null;\nfunction getBaseElementHref() {\n baseElement = baseElement || document.querySelector('base');\n return baseElement ? baseElement.getAttribute('href') : null;\n}\nfunction relativePath(url) {\n // The base URL doesn't really matter, we just need it so relative paths have something\n // to resolve against. In the browser `HTMLBaseElement.href` is always absolute.\n return new URL(url, document.baseURI).pathname;\n}\nclass BrowserGetTestability {\n addToWindow(registry) {\n ɵglobal['getAngularTestability'] = (elem, findInAncestors = true) => {\n const testability = registry.findTestabilityInTree(elem, findInAncestors);\n if (testability == null) {\n throw new ɵRuntimeError(5103 /* RuntimeErrorCode.TESTABILITY_NOT_FOUND */, (typeof ngDevMode === 'undefined' || ngDevMode) && 'Could not find testability for element.');\n }\n return testability;\n };\n ɵglobal['getAllAngularTestabilities'] = () => registry.getAllTestabilities();\n ɵglobal['getAllAngularRootElements'] = () => registry.getAllRootElements();\n const whenAllStable = callback => {\n const testabilities = ɵglobal['getAllAngularTestabilities']();\n let count = testabilities.length;\n const decrement = function () {\n count--;\n if (count == 0) {\n callback();\n }\n };\n testabilities.forEach(testability => {\n testability.whenStable(decrement);\n });\n };\n if (!ɵglobal['frameworkStabilizers']) {\n ɵglobal['frameworkStabilizers'] = [];\n }\n ɵglobal['frameworkStabilizers'].push(whenAllStable);\n }\n findTestabilityInTree(registry, elem, findInAncestors) {\n if (elem == null) {\n return null;\n }\n const t = registry.getTestability(elem);\n if (t != null) {\n return t;\n } else if (!findInAncestors) {\n return null;\n }\n if (ɵgetDOM().isShadowRoot(elem)) {\n return this.findTestabilityInTree(registry, elem.host, true);\n }\n return this.findTestabilityInTree(registry, elem.parentElement, true);\n }\n}\n\n/**\n * A factory for `HttpXhrBackend` that uses the `XMLHttpRequest` browser API.\n */\nclass BrowserXhr {\n build() {\n return new XMLHttpRequest();\n }\n static ɵfac = function BrowserXhr_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || BrowserXhr)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: BrowserXhr,\n factory: BrowserXhr.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(BrowserXhr, [{\n type: Injectable\n }], null, null);\n})();\n\n/**\n * The injection token for plugins of the `EventManager` service.\n *\n * @publicApi\n */\nconst EVENT_MANAGER_PLUGINS = new InjectionToken(ngDevMode ? 'EventManagerPlugins' : '');\n/**\n * An injectable service that provides event management for Angular\n * through a browser plug-in.\n *\n * @publicApi\n */\nclass EventManager {\n _zone;\n _plugins;\n _eventNameToPlugin = new Map();\n /**\n * Initializes an instance of the event-manager service.\n */\n constructor(plugins, _zone) {\n this._zone = _zone;\n plugins.forEach(plugin => {\n plugin.manager = this;\n });\n this._plugins = plugins.slice().reverse();\n }\n /**\n * Registers a handler for a specific element and event.\n *\n * @param element The HTML element to receive event notifications.\n * @param eventName The name of the event to listen for.\n * @param handler A function to call when the notification occurs. Receives the\n * event object as an argument.\n * @param options Options that configure how the event listener is bound.\n * @returns A callback function that can be used to remove the handler.\n */\n addEventListener(element, eventName, handler, options) {\n const plugin = this._findPluginFor(eventName);\n return plugin.addEventListener(element, eventName, handler, options);\n }\n /**\n * Retrieves the compilation zone in which event listeners are registered.\n */\n getZone() {\n return this._zone;\n }\n /** @internal */\n _findPluginFor(eventName) {\n let plugin = this._eventNameToPlugin.get(eventName);\n if (plugin) {\n return plugin;\n }\n const plugins = this._plugins;\n plugin = plugins.find(plugin => plugin.supports(eventName));\n if (!plugin) {\n throw new ɵRuntimeError(5101 /* RuntimeErrorCode.NO_PLUGIN_FOR_EVENT */, (typeof ngDevMode === 'undefined' || ngDevMode) && `No event manager plugin found for event ${eventName}`);\n }\n this._eventNameToPlugin.set(eventName, plugin);\n return plugin;\n }\n static ɵfac = function EventManager_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || EventManager)(i0.ɵɵinject(EVENT_MANAGER_PLUGINS), i0.ɵɵinject(i0.NgZone));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: EventManager,\n factory: EventManager.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(EventManager, [{\n type: Injectable\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [EVENT_MANAGER_PLUGINS]\n }]\n }, {\n type: i0.NgZone\n }], null);\n})();\n/**\n * The plugin definition for the `EventManager` class\n *\n * It can be used as a base class to create custom manager plugins, i.e. you can create your own\n * class that extends the `EventManagerPlugin` one.\n *\n * @publicApi\n */\nclass EventManagerPlugin {\n _doc;\n // TODO: remove (has some usage in G3)\n constructor(_doc) {\n this._doc = _doc;\n }\n // Using non-null assertion because it's set by EventManager's constructor\n manager;\n}\n\n/** The style elements attribute name used to set value of `APP_ID` token. */\nconst APP_ID_ATTRIBUTE_NAME = 'ng-app-id';\n/**\n * Removes all provided elements from the document.\n * @param elements An array of HTML Elements.\n */\nfunction removeElements(elements) {\n for (const element of elements) {\n element.remove();\n }\n}\n/**\n * Creates a `style` element with the provided inline style content.\n * @param style A string of the inline style content.\n * @param doc A DOM Document to use to create the element.\n * @returns An HTMLStyleElement instance.\n */\nfunction createStyleElement(style, doc) {\n const styleElement = doc.createElement('style');\n styleElement.textContent = style;\n return styleElement;\n}\n/**\n * Searches a DOM document's head element for style elements with a matching application\n * identifier attribute (`ng-app-id`) to the provide identifier and adds usage records for each.\n * @param doc An HTML DOM document instance.\n * @param appId A string containing an Angular application identifer.\n * @param inline A Map object for tracking inline (defined via `styles` in component decorator) style usage.\n * @param external A Map object for tracking external (defined via `styleUrls` in component decorator) style usage.\n */\nfunction addServerStyles(doc, appId, inline, external) {\n const elements = doc.head?.querySelectorAll(`style[${APP_ID_ATTRIBUTE_NAME}=\"${appId}\"],link[${APP_ID_ATTRIBUTE_NAME}=\"${appId}\"]`);\n if (elements) {\n for (const styleElement of elements) {\n styleElement.removeAttribute(APP_ID_ATTRIBUTE_NAME);\n if (styleElement instanceof HTMLLinkElement) {\n // Only use filename from href\n // The href is build time generated with a unique value to prevent duplicates.\n external.set(styleElement.href.slice(styleElement.href.lastIndexOf('/') + 1), {\n usage: 0,\n elements: [styleElement]\n });\n } else if (styleElement.textContent) {\n inline.set(styleElement.textContent, {\n usage: 0,\n elements: [styleElement]\n });\n }\n }\n }\n}\n/**\n * Creates a `link` element for the provided external style URL.\n * @param url A string of the URL for the stylesheet.\n * @param doc A DOM Document to use to create the element.\n * @returns An HTMLLinkElement instance.\n */\nfunction createLinkElement(url, doc) {\n const linkElement = doc.createElement('link');\n linkElement.setAttribute('rel', 'stylesheet');\n linkElement.setAttribute('href', url);\n return linkElement;\n}\nclass SharedStylesHost {\n doc;\n appId;\n nonce;\n /**\n * Provides usage information for active inline style content and associated HTML <style> elements.\n * Embedded styles typically originate from the `styles` metadata of a rendered component.\n */\n inline = new Map();\n /**\n * Provides usage information for active external style URLs and the associated HTML <link> elements.\n * External styles typically originate from the `ɵɵExternalStylesFeature` of a rendered component.\n */\n external = new Map();\n /**\n * Set of host DOM nodes that will have styles attached.\n */\n hosts = new Set();\n /**\n * Whether the application code is currently executing on a server.\n */\n isServer;\n constructor(doc, appId, nonce, platformId = {}) {\n this.doc = doc;\n this.appId = appId;\n this.nonce = nonce;\n this.isServer = isPlatformServer(platformId);\n addServerStyles(doc, appId, this.inline, this.external);\n this.hosts.add(doc.head);\n }\n /**\n * Adds embedded styles to the DOM via HTML `style` elements.\n * @param styles An array of style content strings.\n */\n addStyles(styles, urls) {\n for (const value of styles) {\n this.addUsage(value, this.inline, createStyleElement);\n }\n urls?.forEach(value => this.addUsage(value, this.external, createLinkElement));\n }\n /**\n * Removes embedded styles from the DOM that were added as HTML `style` elements.\n * @param styles An array of style content strings.\n */\n removeStyles(styles, urls) {\n for (const value of styles) {\n this.removeUsage(value, this.inline);\n }\n urls?.forEach(value => this.removeUsage(value, this.external));\n }\n addUsage(value, usages, creator) {\n // Attempt to get any current usage of the value\n const record = usages.get(value);\n // If existing, just increment the usage count\n if (record) {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && record.usage === 0) {\n // A usage count of zero indicates a preexisting server generated style.\n // This attribute is solely used for debugging purposes of SSR style reuse.\n record.elements.forEach(element => element.setAttribute('ng-style-reused', ''));\n }\n record.usage++;\n } else {\n // Otherwise, create an entry to track the elements and add element for each host\n usages.set(value, {\n usage: 1,\n elements: [...this.hosts].map(host => this.addElement(host, creator(value, this.doc)))\n });\n }\n }\n removeUsage(value, usages) {\n // Attempt to get any current usage of the value\n const record = usages.get(value);\n // If there is a record, reduce the usage count and if no longer used,\n // remove from DOM and delete usage record.\n if (record) {\n record.usage--;\n if (record.usage <= 0) {\n removeElements(record.elements);\n usages.delete(value);\n }\n }\n }\n ngOnDestroy() {\n for (const [, {\n elements\n }] of [...this.inline, ...this.external]) {\n removeElements(elements);\n }\n this.hosts.clear();\n }\n /**\n * Adds a host node to the set of style hosts and adds all existing style usage to\n * the newly added host node.\n *\n * This is currently only used for Shadow DOM encapsulation mode.\n */\n addHost(hostNode) {\n this.hosts.add(hostNode);\n // Add existing styles to new host\n for (const [style, {\n elements\n }] of this.inline) {\n elements.push(this.addElement(hostNode, createStyleElement(style, this.doc)));\n }\n for (const [url, {\n elements\n }] of this.external) {\n elements.push(this.addElement(hostNode, createLinkElement(url, this.doc)));\n }\n }\n removeHost(hostNode) {\n this.hosts.delete(hostNode);\n }\n addElement(host, element) {\n // Add a nonce if present\n if (this.nonce) {\n element.setAttribute('nonce', this.nonce);\n }\n // Add application identifier when on the server to support client-side reuse\n if (this.isServer) {\n element.setAttribute(APP_ID_ATTRIBUTE_NAME, this.appId);\n }\n // Insert the element into the DOM with the host node as parent\n return host.appendChild(element);\n }\n static ɵfac = function SharedStylesHost_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || SharedStylesHost)(i0.ɵɵinject(DOCUMENT), i0.ɵɵinject(APP_ID), i0.ɵɵinject(CSP_NONCE, 8), i0.ɵɵinject(PLATFORM_ID));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: SharedStylesHost,\n factory: SharedStylesHost.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(SharedStylesHost, [{\n type: Injectable\n }], () => [{\n type: Document,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [APP_ID]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [CSP_NONCE]\n }, {\n type: Optional\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [PLATFORM_ID]\n }]\n }], null);\n})();\nconst NAMESPACE_URIS = {\n 'svg': 'http://www.w3.org/2000/svg',\n 'xhtml': 'http://www.w3.org/1999/xhtml',\n 'xlink': 'http://www.w3.org/1999/xlink',\n 'xml': 'http://www.w3.org/XML/1998/namespace',\n 'xmlns': 'http://www.w3.org/2000/xmlns/',\n 'math': 'http://www.w3.org/1998/Math/MathML'\n};\nconst COMPONENT_REGEX = /%COMP%/g;\nconst SOURCEMAP_URL_REGEXP = /\\/\\*#\\s*sourceMappingURL=(.+?)\\s*\\*\\//;\nconst PROTOCOL_REGEXP = /^https?:/;\nconst COMPONENT_VARIABLE = '%COMP%';\nconst HOST_ATTR = `_nghost-${COMPONENT_VARIABLE}`;\nconst CONTENT_ATTR = `_ngcontent-${COMPONENT_VARIABLE}`;\n/**\n * The default value for the `REMOVE_STYLES_ON_COMPONENT_DESTROY` DI token.\n */\nconst REMOVE_STYLES_ON_COMPONENT_DESTROY_DEFAULT = true;\n/**\n * A DI token that indicates whether styles\n * of destroyed components should be removed from DOM.\n *\n * By default, the value is set to `true`.\n * @publicApi\n */\nconst REMOVE_STYLES_ON_COMPONENT_DESTROY = new InjectionToken(ngDevMode ? 'RemoveStylesOnCompDestroy' : '', {\n providedIn: 'root',\n factory: () => REMOVE_STYLES_ON_COMPONENT_DESTROY_DEFAULT\n});\nfunction shimContentAttribute(componentShortId) {\n return CONTENT_ATTR.replace(COMPONENT_REGEX, componentShortId);\n}\nfunction shimHostAttribute(componentShortId) {\n return HOST_ATTR.replace(COMPONENT_REGEX, componentShortId);\n}\nfunction shimStylesContent(compId, styles) {\n return styles.map(s => s.replace(COMPONENT_REGEX, compId));\n}\n/**\n * Prepends a baseHref to the `sourceMappingURL` within the provided CSS content.\n * If the `sourceMappingURL` contains an inline (encoded) map, the function skips processing.\n *\n * @note For inline stylesheets, the `sourceMappingURL` is relative to the page's origin\n * and not the provided baseHref. This function is needed as when accessing the page with a URL\n * containing two or more segments.\n * For example, if the baseHref is set to `/`, and you visit a URL like `http://localhost/foo/bar`,\n * the map would be requested from `http://localhost/foo/bar/comp.css.map` instead of what you'd expect,\n * which is `http://localhost/comp.css.map`. This behavior is corrected by modifying the `sourceMappingURL`\n * to ensure external source maps are loaded relative to the baseHref.\n *\n\n * @param baseHref - The base URL to prepend to the `sourceMappingURL`.\n * @param styles - An array of CSS content strings, each potentially containing a `sourceMappingURL`.\n * @returns The updated array of CSS content strings with modified `sourceMappingURL` values,\n * or the original content if no modification is needed.\n */\nfunction addBaseHrefToCssSourceMap(baseHref, styles) {\n if (!baseHref) {\n return styles;\n }\n const absoluteBaseHrefUrl = new URL(baseHref, 'http://localhost');\n return styles.map(cssContent => {\n if (!cssContent.includes('sourceMappingURL=')) {\n return cssContent;\n }\n return cssContent.replace(SOURCEMAP_URL_REGEXP, (_, sourceMapUrl) => {\n if (sourceMapUrl[0] === '/' || sourceMapUrl.startsWith('data:') || PROTOCOL_REGEXP.test(sourceMapUrl)) {\n return `/*# sourceMappingURL=${sourceMapUrl} */`;\n }\n const {\n pathname: resolvedSourceMapUrl\n } = new URL(sourceMapUrl, absoluteBaseHrefUrl);\n return `/*# sourceMappingURL=${resolvedSourceMapUrl} */`;\n });\n });\n}\nclass DomRendererFactory2 {\n eventManager;\n sharedStylesHost;\n appId;\n removeStylesOnCompDestroy;\n doc;\n platformId;\n ngZone;\n nonce;\n tracingService;\n rendererByCompId = new Map();\n defaultRenderer;\n platformIsServer;\n constructor(eventManager, sharedStylesHost, appId, removeStylesOnCompDestroy, doc, platformId, ngZone, nonce = null, tracingService = null) {\n this.eventManager = eventManager;\n this.sharedStylesHost = sharedStylesHost;\n this.appId = appId;\n this.removeStylesOnCompDestroy = removeStylesOnCompDestroy;\n this.doc = doc;\n this.platformId = platformId;\n this.ngZone = ngZone;\n this.nonce = nonce;\n this.tracingService = tracingService;\n this.platformIsServer = isPlatformServer(platformId);\n this.defaultRenderer = new DefaultDomRenderer2(eventManager, doc, ngZone, this.platformIsServer, this.tracingService);\n }\n createRenderer(element, type) {\n if (!element || !type) {\n return this.defaultRenderer;\n }\n if (this.platformIsServer && type.encapsulation === ViewEncapsulation.ShadowDom) {\n // Domino does not support shadow DOM.\n type = {\n ...type,\n encapsulation: ViewEncapsulation.Emulated\n };\n }\n const renderer = this.getOrCreateRenderer(element, type);\n // Renderers have different logic due to different encapsulation behaviours.\n // Ex: for emulated, an attribute is added to the element.\n if (renderer instanceof EmulatedEncapsulationDomRenderer2) {\n renderer.applyToHost(element);\n } else if (renderer instanceof NoneEncapsulationDomRenderer) {\n renderer.applyStyles();\n }\n return renderer;\n }\n getOrCreateRenderer(element, type) {\n const rendererByCompId = this.rendererByCompId;\n let renderer = rendererByCompId.get(type.id);\n if (!renderer) {\n const doc = this.doc;\n const ngZone = this.ngZone;\n const eventManager = this.eventManager;\n const sharedStylesHost = this.sharedStylesHost;\n const removeStylesOnCompDestroy = this.removeStylesOnCompDestroy;\n const platformIsServer = this.platformIsServer;\n const tracingService = this.tracingService;\n switch (type.encapsulation) {\n case ViewEncapsulation.Emulated:\n renderer = new EmulatedEncapsulationDomRenderer2(eventManager, sharedStylesHost, type, this.appId, removeStylesOnCompDestroy, doc, ngZone, platformIsServer, tracingService);\n break;\n case ViewEncapsulation.ShadowDom:\n return new ShadowDomRenderer(eventManager, sharedStylesHost, element, type, doc, ngZone, this.nonce, platformIsServer, tracingService);\n default:\n renderer = new NoneEncapsulationDomRenderer(eventManager, sharedStylesHost, type, removeStylesOnCompDestroy, doc, ngZone, platformIsServer, tracingService);\n break;\n }\n rendererByCompId.set(type.id, renderer);\n }\n return renderer;\n }\n ngOnDestroy() {\n this.rendererByCompId.clear();\n }\n /**\n * Used during HMR to clear any cached data about a component.\n * @param componentId ID of the component that is being replaced.\n */\n componentReplaced(componentId) {\n this.rendererByCompId.delete(componentId);\n }\n static ɵfac = function DomRendererFactory2_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DomRendererFactory2)(i0.ɵɵinject(EventManager), i0.ɵɵinject(SharedStylesHost), i0.ɵɵinject(APP_ID), i0.ɵɵinject(REMOVE_STYLES_ON_COMPONENT_DESTROY), i0.ɵɵinject(DOCUMENT), i0.ɵɵinject(PLATFORM_ID), i0.ɵɵinject(i0.NgZone), i0.ɵɵinject(CSP_NONCE), i0.ɵɵinject(ɵTracingService, 8));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DomRendererFactory2,\n factory: DomRendererFactory2.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DomRendererFactory2, [{\n type: Injectable\n }], () => [{\n type: EventManager\n }, {\n type: SharedStylesHost\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [APP_ID]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [REMOVE_STYLES_ON_COMPONENT_DESTROY]\n }]\n }, {\n type: Document,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }, {\n type: Object,\n decorators: [{\n type: Inject,\n args: [PLATFORM_ID]\n }]\n }, {\n type: i0.NgZone\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [CSP_NONCE]\n }]\n }, {\n type: i0.ɵTracingService,\n decorators: [{\n type: Inject,\n args: [ɵTracingService]\n }, {\n type: Optional\n }]\n }], null);\n})();\nclass DefaultDomRenderer2 {\n eventManager;\n doc;\n ngZone;\n platformIsServer;\n tracingService;\n data = Object.create(null);\n /**\n * By default this renderer throws when encountering synthetic properties\n * This can be disabled for example by the AsyncAnimationRendererFactory\n */\n throwOnSyntheticProps = true;\n constructor(eventManager, doc, ngZone, platformIsServer, tracingService) {\n this.eventManager = eventManager;\n this.doc = doc;\n this.ngZone = ngZone;\n this.platformIsServer = platformIsServer;\n this.tracingService = tracingService;\n }\n destroy() {}\n destroyNode = null;\n createElement(name, namespace) {\n if (namespace) {\n // TODO: `|| namespace` was added in\n // https://github.com/angular/angular/commit/2b9cc8503d48173492c29f5a271b61126104fbdb to\n // support how Ivy passed around the namespace URI rather than short name at the time. It did\n // not, however extend the support to other parts of the system (setAttribute, setAttribute,\n // and the ServerRenderer). We should decide what exactly the semantics for dealing with\n // namespaces should be and make it consistent.\n // Related issues:\n // https://github.com/angular/angular/issues/44028\n // https://github.com/angular/angular/issues/44883\n return this.doc.createElementNS(NAMESPACE_URIS[namespace] || namespace, name);\n }\n return this.doc.createElement(name);\n }\n createComment(value) {\n return this.doc.createComment(value);\n }\n createText(value) {\n return this.doc.createTextNode(value);\n }\n appendChild(parent, newChild) {\n const targetParent = isTemplateNode(parent) ? parent.content : parent;\n targetParent.appendChild(newChild);\n }\n insertBefore(parent, newChild, refChild) {\n if (parent) {\n const targetParent = isTemplateNode(parent) ? parent.content : parent;\n targetParent.insertBefore(newChild, refChild);\n }\n }\n removeChild(_parent, oldChild) {\n oldChild.remove();\n }\n selectRootElement(selectorOrNode, preserveContent) {\n let el = typeof selectorOrNode === 'string' ? this.doc.querySelector(selectorOrNode) : selectorOrNode;\n if (!el) {\n throw new ɵRuntimeError(-5104 /* RuntimeErrorCode.ROOT_NODE_NOT_FOUND */, (typeof ngDevMode === 'undefined' || ngDevMode) && `The selector \"${selectorOrNode}\" did not match any elements`);\n }\n if (!preserveContent) {\n el.textContent = '';\n }\n return el;\n }\n parentNode(node) {\n return node.parentNode;\n }\n nextSibling(node) {\n return node.nextSibling;\n }\n setAttribute(el, name, value, namespace) {\n if (namespace) {\n name = namespace + ':' + name;\n const namespaceUri = NAMESPACE_URIS[namespace];\n if (namespaceUri) {\n el.setAttributeNS(namespaceUri, name, value);\n } else {\n el.setAttribute(name, value);\n }\n } else {\n el.setAttribute(name, value);\n }\n }\n removeAttribute(el, name, namespace) {\n if (namespace) {\n const namespaceUri = NAMESPACE_URIS[namespace];\n if (namespaceUri) {\n el.removeAttributeNS(namespaceUri, name);\n } else {\n el.removeAttribute(`${namespace}:${name}`);\n }\n } else {\n el.removeAttribute(name);\n }\n }\n addClass(el, name) {\n el.classList.add(name);\n }\n removeClass(el, name) {\n el.classList.remove(name);\n }\n setStyle(el, style, value, flags) {\n if (flags & (RendererStyleFlags2.DashCase | RendererStyleFlags2.Important)) {\n el.style.setProperty(style, value, flags & RendererStyleFlags2.Important ? 'important' : '');\n } else {\n el.style[style] = value;\n }\n }\n removeStyle(el, style, flags) {\n if (flags & RendererStyleFlags2.DashCase) {\n // removeProperty has no effect when used on camelCased properties.\n el.style.removeProperty(style);\n } else {\n el.style[style] = '';\n }\n }\n setProperty(el, name, value) {\n if (el == null) {\n return;\n }\n (typeof ngDevMode === 'undefined' || ngDevMode) && this.throwOnSyntheticProps && checkNoSyntheticProp(name, 'property');\n el[name] = value;\n }\n setValue(node, value) {\n node.nodeValue = value;\n }\n listen(target, event, callback, options) {\n (typeof ngDevMode === 'undefined' || ngDevMode) && this.throwOnSyntheticProps && checkNoSyntheticProp(event, 'listener');\n if (typeof target === 'string') {\n target = ɵgetDOM().getGlobalEventTarget(this.doc, target);\n if (!target) {\n throw new Error(`Unsupported event target ${target} for event ${event}`);\n }\n }\n let wrappedCallback = this.decoratePreventDefault(callback);\n if (this.tracingService !== null && this.tracingService.wrapEventListener) {\n wrappedCallback = this.tracingService.wrapEventListener(target, event, wrappedCallback);\n }\n return this.eventManager.addEventListener(target, event, wrappedCallback, options);\n }\n decoratePreventDefault(eventHandler) {\n // `DebugNode.triggerEventHandler` needs to know if the listener was created with\n // decoratePreventDefault or is a listener added outside the Angular context so it can handle\n // the two differently. In the first case, the special '__ngUnwrap__' token is passed to the\n // unwrap the listener (see below).\n return event => {\n // Ivy uses '__ngUnwrap__' as a special token that allows us to unwrap the function\n // so that it can be invoked programmatically by `DebugNode.triggerEventHandler`. The\n // debug_node can inspect the listener toString contents for the existence of this special\n // token. Because the token is a string literal, it is ensured to not be modified by compiled\n // code.\n if (event === '__ngUnwrap__') {\n return eventHandler;\n }\n // Run the event handler inside the ngZone because event handlers are not patched\n // by Zone on the server. This is required only for tests.\n const allowDefaultBehavior = this.platformIsServer ? this.ngZone.runGuarded(() => eventHandler(event)) : eventHandler(event);\n if (allowDefaultBehavior === false) {\n event.preventDefault();\n }\n return undefined;\n };\n }\n}\nconst AT_CHARCODE = (() => '@'.charCodeAt(0))();\nfunction checkNoSyntheticProp(name, nameKind) {\n if (name.charCodeAt(0) === AT_CHARCODE) {\n throw new ɵRuntimeError(5105 /* RuntimeErrorCode.UNEXPECTED_SYNTHETIC_PROPERTY */, `Unexpected synthetic ${nameKind} ${name} found. Please make sure that:\n - Make sure \\`provideAnimationsAsync()\\`, \\`provideAnimations()\\` or \\`provideNoopAnimations()\\` call was added to a list of providers used to bootstrap an application.\n - There is a corresponding animation configuration named \\`${name}\\` defined in the \\`animations\\` field of the \\`@Component\\` decorator (see https://angular.dev/api/core/Component#animations).`);\n }\n}\nfunction isTemplateNode(node) {\n return node.tagName === 'TEMPLATE' && node.content !== undefined;\n}\nclass ShadowDomRenderer extends DefaultDomRenderer2 {\n sharedStylesHost;\n hostEl;\n shadowRoot;\n constructor(eventManager, sharedStylesHost, hostEl, component, doc, ngZone, nonce, platformIsServer, tracingService) {\n super(eventManager, doc, ngZone, platformIsServer, tracingService);\n this.sharedStylesHost = sharedStylesHost;\n this.hostEl = hostEl;\n this.shadowRoot = hostEl.attachShadow({\n mode: 'open'\n });\n this.sharedStylesHost.addHost(this.shadowRoot);\n let styles = component.styles;\n if (ngDevMode) {\n // We only do this in development, as for production users should not add CSS sourcemaps to components.\n const baseHref = ɵgetDOM().getBaseHref(doc) ?? '';\n styles = addBaseHrefToCssSourceMap(baseHref, styles);\n }\n styles = shimStylesContent(component.id, styles);\n for (const style of styles) {\n const styleEl = document.createElement('style');\n if (nonce) {\n styleEl.setAttribute('nonce', nonce);\n }\n styleEl.textContent = style;\n this.shadowRoot.appendChild(styleEl);\n }\n // Apply any external component styles to the shadow root for the component's element.\n // The ShadowDOM renderer uses an alternative execution path for component styles that\n // does not use the SharedStylesHost that other encapsulation modes leverage. Much like\n // the manual addition of embedded styles directly above, any external stylesheets\n // must be manually added here to ensure ShadowDOM components are correctly styled.\n // TODO: Consider reworking the DOM Renderers to consolidate style handling.\n const styleUrls = component.getExternalStyles?.();\n if (styleUrls) {\n for (const styleUrl of styleUrls) {\n const linkEl = createLinkElement(styleUrl, doc);\n if (nonce) {\n linkEl.setAttribute('nonce', nonce);\n }\n this.shadowRoot.appendChild(linkEl);\n }\n }\n }\n nodeOrShadowRoot(node) {\n return node === this.hostEl ? this.shadowRoot : node;\n }\n appendChild(parent, newChild) {\n return super.appendChild(this.nodeOrShadowRoot(parent), newChild);\n }\n insertBefore(parent, newChild, refChild) {\n return super.insertBefore(this.nodeOrShadowRoot(parent), newChild, refChild);\n }\n removeChild(_parent, oldChild) {\n return super.removeChild(null, oldChild);\n }\n parentNode(node) {\n return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(node)));\n }\n destroy() {\n this.sharedStylesHost.removeHost(this.shadowRoot);\n }\n}\nclass NoneEncapsulationDomRenderer extends DefaultDomRenderer2 {\n sharedStylesHost;\n removeStylesOnCompDestroy;\n styles;\n styleUrls;\n constructor(eventManager, sharedStylesHost, component, removeStylesOnCompDestroy, doc, ngZone, platformIsServer, tracingService, compId) {\n super(eventManager, doc, ngZone, platformIsServer, tracingService);\n this.sharedStylesHost = sharedStylesHost;\n this.removeStylesOnCompDestroy = removeStylesOnCompDestroy;\n let styles = component.styles;\n if (ngDevMode) {\n // We only do this in development, as for production users should not add CSS sourcemaps to components.\n const baseHref = ɵgetDOM().getBaseHref(doc) ?? '';\n styles = addBaseHrefToCssSourceMap(baseHref, styles);\n }\n this.styles = compId ? shimStylesContent(compId, styles) : styles;\n this.styleUrls = component.getExternalStyles?.(compId);\n }\n applyStyles() {\n this.sharedStylesHost.addStyles(this.styles, this.styleUrls);\n }\n destroy() {\n if (!this.removeStylesOnCompDestroy) {\n return;\n }\n this.sharedStylesHost.removeStyles(this.styles, this.styleUrls);\n }\n}\nclass EmulatedEncapsulationDomRenderer2 extends NoneEncapsulationDomRenderer {\n contentAttr;\n hostAttr;\n constructor(eventManager, sharedStylesHost, component, appId, removeStylesOnCompDestroy, doc, ngZone, platformIsServer, tracingService) {\n const compId = appId + '-' + component.id;\n super(eventManager, sharedStylesHost, component, removeStylesOnCompDestroy, doc, ngZone, platformIsServer, tracingService, compId);\n this.contentAttr = shimContentAttribute(compId);\n this.hostAttr = shimHostAttribute(compId);\n }\n applyToHost(element) {\n this.applyStyles();\n this.setAttribute(element, this.hostAttr, '');\n }\n createElement(parent, name) {\n const el = super.createElement(parent, name);\n super.setAttribute(el, this.contentAttr, '');\n return el;\n }\n}\nclass DomEventsPlugin extends EventManagerPlugin {\n constructor(doc) {\n super(doc);\n }\n // This plugin should come last in the list of plugins, because it accepts all\n // events.\n supports(eventName) {\n return true;\n }\n addEventListener(element, eventName, handler, options) {\n element.addEventListener(eventName, handler, options);\n return () => this.removeEventListener(element, eventName, handler, options);\n }\n removeEventListener(target, eventName, callback, options) {\n return target.removeEventListener(eventName, callback, options);\n }\n static ɵfac = function DomEventsPlugin_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DomEventsPlugin)(i0.ɵɵinject(DOCUMENT));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DomEventsPlugin,\n factory: DomEventsPlugin.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DomEventsPlugin, [{\n type: Injectable\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }], null);\n})();\n\n/**\n * Defines supported modifiers for key events.\n */\nconst MODIFIER_KEYS = ['alt', 'control', 'meta', 'shift'];\n// The following values are here for cross-browser compatibility and to match the W3C standard\n// cf https://www.w3.org/TR/DOM-Level-3-Events-key/\nconst _keyMap = {\n '\\b': 'Backspace',\n '\\t': 'Tab',\n '\\x7F': 'Delete',\n '\\x1B': 'Escape',\n 'Del': 'Delete',\n 'Esc': 'Escape',\n 'Left': 'ArrowLeft',\n 'Right': 'ArrowRight',\n 'Up': 'ArrowUp',\n 'Down': 'ArrowDown',\n 'Menu': 'ContextMenu',\n 'Scroll': 'ScrollLock',\n 'Win': 'OS'\n};\n/**\n * Retrieves modifiers from key-event objects.\n */\nconst MODIFIER_KEY_GETTERS = {\n 'alt': event => event.altKey,\n 'control': event => event.ctrlKey,\n 'meta': event => event.metaKey,\n 'shift': event => event.shiftKey\n};\n/**\n * A browser plug-in that provides support for handling of key events in Angular.\n */\nclass KeyEventsPlugin extends EventManagerPlugin {\n /**\n * Initializes an instance of the browser plug-in.\n * @param doc The document in which key events will be detected.\n */\n constructor(doc) {\n super(doc);\n }\n /**\n * Reports whether a named key event is supported.\n * @param eventName The event name to query.\n * @return True if the named key event is supported.\n */\n supports(eventName) {\n return KeyEventsPlugin.parseEventName(eventName) != null;\n }\n /**\n * Registers a handler for a specific element and key event.\n * @param element The HTML element to receive event notifications.\n * @param eventName The name of the key event to listen for.\n * @param handler A function to call when the notification occurs. Receives the\n * event object as an argument.\n * @returns The key event that was registered.\n */\n addEventListener(element, eventName, handler, options) {\n const parsedEvent = KeyEventsPlugin.parseEventName(eventName);\n const outsideHandler = KeyEventsPlugin.eventCallback(parsedEvent['fullKey'], handler, this.manager.getZone());\n return this.manager.getZone().runOutsideAngular(() => {\n return ɵgetDOM().onAndCancel(element, parsedEvent['domEventName'], outsideHandler, options);\n });\n }\n /**\n * Parses the user provided full keyboard event definition and normalizes it for\n * later internal use. It ensures the string is all lowercase, converts special\n * characters to a standard spelling, and orders all the values consistently.\n *\n * @param eventName The name of the key event to listen for.\n * @returns an object with the full, normalized string, and the dom event name\n * or null in the case when the event doesn't match a keyboard event.\n */\n static parseEventName(eventName) {\n const parts = eventName.toLowerCase().split('.');\n const domEventName = parts.shift();\n if (parts.length === 0 || !(domEventName === 'keydown' || domEventName === 'keyup')) {\n return null;\n }\n const key = KeyEventsPlugin._normalizeKey(parts.pop());\n let fullKey = '';\n let codeIX = parts.indexOf('code');\n if (codeIX > -1) {\n parts.splice(codeIX, 1);\n fullKey = 'code.';\n }\n MODIFIER_KEYS.forEach(modifierName => {\n const index = parts.indexOf(modifierName);\n if (index > -1) {\n parts.splice(index, 1);\n fullKey += modifierName + '.';\n }\n });\n fullKey += key;\n if (parts.length != 0 || key.length === 0) {\n // returning null instead of throwing to let another plugin process the event\n return null;\n }\n // NOTE: Please don't rewrite this as so, as it will break JSCompiler property renaming.\n // The code must remain in the `result['domEventName']` form.\n // return {domEventName, fullKey};\n const result = {};\n result['domEventName'] = domEventName;\n result['fullKey'] = fullKey;\n return result;\n }\n /**\n * Determines whether the actual keys pressed match the configured key code string.\n * The `fullKeyCode` event is normalized in the `parseEventName` method when the\n * event is attached to the DOM during the `addEventListener` call. This is unseen\n * by the end user and is normalized for internal consistency and parsing.\n *\n * @param event The keyboard event.\n * @param fullKeyCode The normalized user defined expected key event string\n * @returns boolean.\n */\n static matchEventFullKeyCode(event, fullKeyCode) {\n let keycode = _keyMap[event.key] || event.key;\n let key = '';\n if (fullKeyCode.indexOf('code.') > -1) {\n keycode = event.code;\n key = 'code.';\n }\n // the keycode could be unidentified so we have to check here\n if (keycode == null || !keycode) return false;\n keycode = keycode.toLowerCase();\n if (keycode === ' ') {\n keycode = 'space'; // for readability\n } else if (keycode === '.') {\n keycode = 'dot'; // because '.' is used as a separator in event names\n }\n MODIFIER_KEYS.forEach(modifierName => {\n if (modifierName !== keycode) {\n const modifierGetter = MODIFIER_KEY_GETTERS[modifierName];\n if (modifierGetter(event)) {\n key += modifierName + '.';\n }\n }\n });\n key += keycode;\n return key === fullKeyCode;\n }\n /**\n * Configures a handler callback for a key event.\n * @param fullKey The event name that combines all simultaneous keystrokes.\n * @param handler The function that responds to the key event.\n * @param zone The zone in which the event occurred.\n * @returns A callback function.\n */\n static eventCallback(fullKey, handler, zone) {\n return event => {\n if (KeyEventsPlugin.matchEventFullKeyCode(event, fullKey)) {\n zone.runGuarded(() => handler(event));\n }\n };\n }\n /** @internal */\n static _normalizeKey(keyName) {\n return keyName === 'esc' ? 'escape' : keyName;\n }\n static ɵfac = function KeyEventsPlugin_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || KeyEventsPlugin)(i0.ɵɵinject(DOCUMENT));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: KeyEventsPlugin,\n factory: KeyEventsPlugin.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(KeyEventsPlugin, [{\n type: Injectable\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }], null);\n})();\n\n/**\n * Bootstraps an instance of an Angular application and renders a standalone component as the\n * application's root component. More information about standalone components can be found in [this\n * guide](guide/components/importing).\n *\n * @usageNotes\n * The root component passed into this function *must* be a standalone one (should have the\n * `standalone: true` flag in the `@Component` decorator config).\n *\n * ```angular-ts\n * @Component({\n * standalone: true,\n * template: 'Hello world!'\n * })\n * class RootComponent {}\n *\n * const appRef: ApplicationRef = await bootstrapApplication(RootComponent);\n * ```\n *\n * You can add the list of providers that should be available in the application injector by\n * specifying the `providers` field in an object passed as the second argument:\n *\n * ```ts\n * await bootstrapApplication(RootComponent, {\n * providers: [\n * {provide: BACKEND_URL, useValue: 'https://yourdomain.com/api'}\n * ]\n * });\n * ```\n *\n * The `importProvidersFrom` helper method can be used to collect all providers from any\n * existing NgModule (and transitively from all NgModules that it imports):\n *\n * ```ts\n * await bootstrapApplication(RootComponent, {\n * providers: [\n * importProvidersFrom(SomeNgModule)\n * ]\n * });\n * ```\n *\n * Note: the `bootstrapApplication` method doesn't include [Testability](api/core/Testability) by\n * default. You can add [Testability](api/core/Testability) by getting the list of necessary\n * providers using `provideProtractorTestingSupport()` function and adding them into the `providers`\n * array, for example:\n *\n * ```ts\n * import {provideProtractorTestingSupport} from '@angular/platform-browser';\n *\n * await bootstrapApplication(RootComponent, {providers: [provideProtractorTestingSupport()]});\n * ```\n *\n * @param rootComponent A reference to a standalone component that should be rendered.\n * @param options Extra configuration for the bootstrap operation, see `ApplicationConfig` for\n * additional info.\n * @returns A promise that returns an `ApplicationRef` instance once resolved.\n *\n * @publicApi\n */\nfunction bootstrapApplication(rootComponent, options) {\n return ɵinternalCreateApplication({\n rootComponent,\n ...createProvidersConfig(options)\n });\n}\n/**\n * Create an instance of an Angular application without bootstrapping any components. This is useful\n * for the situation where one wants to decouple application environment creation (a platform and\n * associated injectors) from rendering components on a screen. Components can be subsequently\n * bootstrapped on the returned `ApplicationRef`.\n *\n * @param options Extra configuration for the application environment, see `ApplicationConfig` for\n * additional info.\n * @returns A promise that returns an `ApplicationRef` instance once resolved.\n *\n * @publicApi\n */\nfunction createApplication(options) {\n return ɵinternalCreateApplication(createProvidersConfig(options));\n}\nfunction createProvidersConfig(options) {\n return {\n appProviders: [...BROWSER_MODULE_PROVIDERS, ...(options?.providers ?? [])],\n platformProviders: INTERNAL_BROWSER_PLATFORM_PROVIDERS\n };\n}\n/**\n * Returns a set of providers required to setup [Testability](api/core/Testability) for an\n * application bootstrapped using the `bootstrapApplication` function. The set of providers is\n * needed to support testing an application with Protractor (which relies on the Testability APIs\n * to be present).\n *\n * @returns An array of providers required to setup Testability for an application and make it\n * available for testing using Protractor.\n *\n * @publicApi\n */\nfunction provideProtractorTestingSupport() {\n // Return a copy to prevent changes to the original array in case any in-place\n // alterations are performed to the `provideProtractorTestingSupport` call results in app\n // code.\n return [...TESTABILITY_PROVIDERS];\n}\nfunction initDomAdapter() {\n BrowserDomAdapter.makeCurrent();\n}\nfunction errorHandler() {\n return new ErrorHandler();\n}\nfunction _document() {\n // Tell ivy about the global document\n ɵsetDocument(document);\n return document;\n}\nconst INTERNAL_BROWSER_PLATFORM_PROVIDERS = [{\n provide: PLATFORM_ID,\n useValue: ɵPLATFORM_BROWSER_ID\n}, {\n provide: PLATFORM_INITIALIZER,\n useValue: initDomAdapter,\n multi: true\n}, {\n provide: DOCUMENT,\n useFactory: _document,\n deps: []\n}];\n/**\n * A factory function that returns a `PlatformRef` instance associated with browser service\n * providers.\n *\n * @publicApi\n */\nconst platformBrowser = createPlatformFactory(platformCore, 'browser', INTERNAL_BROWSER_PLATFORM_PROVIDERS);\n/**\n * Internal marker to signal whether providers from the `BrowserModule` are already present in DI.\n * This is needed to avoid loading `BrowserModule` providers twice. We can't rely on the\n * `BrowserModule` presence itself, since the standalone-based bootstrap just imports\n * `BrowserModule` providers without referencing the module itself.\n */\nconst BROWSER_MODULE_PROVIDERS_MARKER = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'BrowserModule Providers Marker' : '');\nconst TESTABILITY_PROVIDERS = [{\n provide: ɵTESTABILITY_GETTER,\n useClass: BrowserGetTestability,\n deps: []\n}, {\n provide: ɵTESTABILITY,\n useClass: Testability,\n deps: [NgZone, TestabilityRegistry, ɵTESTABILITY_GETTER]\n}, {\n provide: Testability,\n // Also provide as `Testability` for backwards-compatibility.\n useClass: Testability,\n deps: [NgZone, TestabilityRegistry, ɵTESTABILITY_GETTER]\n}];\nconst BROWSER_MODULE_PROVIDERS = [{\n provide: ɵINJECTOR_SCOPE,\n useValue: 'root'\n}, {\n provide: ErrorHandler,\n useFactory: errorHandler,\n deps: []\n}, {\n provide: EVENT_MANAGER_PLUGINS,\n useClass: DomEventsPlugin,\n multi: true,\n deps: [DOCUMENT]\n}, {\n provide: EVENT_MANAGER_PLUGINS,\n useClass: KeyEventsPlugin,\n multi: true,\n deps: [DOCUMENT]\n}, DomRendererFactory2, SharedStylesHost, EventManager, {\n provide: RendererFactory2,\n useExisting: DomRendererFactory2\n}, {\n provide: XhrFactory,\n useClass: BrowserXhr,\n deps: []\n}, typeof ngDevMode === 'undefined' || ngDevMode ? {\n provide: BROWSER_MODULE_PROVIDERS_MARKER,\n useValue: true\n} : []];\n/**\n * Exports required infrastructure for all Angular apps.\n * Included by default in all Angular apps created with the CLI\n * `new` command.\n * Re-exports `CommonModule` and `ApplicationModule`, making their\n * exports and providers available to all apps.\n *\n * @publicApi\n */\nclass BrowserModule {\n constructor() {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const providersAlreadyPresent = inject(BROWSER_MODULE_PROVIDERS_MARKER, {\n optional: true,\n skipSelf: true\n });\n if (providersAlreadyPresent) {\n throw new ɵRuntimeError(5100 /* RuntimeErrorCode.BROWSER_MODULE_ALREADY_LOADED */, `Providers from the \\`BrowserModule\\` have already been loaded. If you need access ` + `to common directives such as NgIf and NgFor, import the \\`CommonModule\\` instead.`);\n }\n }\n }\n static ɵfac = function BrowserModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || BrowserModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: BrowserModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n providers: [...BROWSER_MODULE_PROVIDERS, ...TESTABILITY_PROVIDERS],\n imports: [CommonModule, ApplicationModule]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(BrowserModule, [{\n type: NgModule,\n args: [{\n providers: [...BROWSER_MODULE_PROVIDERS, ...TESTABILITY_PROVIDERS],\n exports: [CommonModule, ApplicationModule]\n }]\n }], () => [], null);\n})();\n\n/**\n * A service for managing HTML `<meta>` tags.\n *\n * Properties of the `MetaDefinition` object match the attributes of the\n * HTML `<meta>` tag. These tags define document metadata that is important for\n * things like configuring a Content Security Policy, defining browser compatibility\n * and security settings, setting HTTP Headers, defining rich content for social sharing,\n * and Search Engine Optimization (SEO).\n *\n * To identify specific `<meta>` tags in a document, use an attribute selection\n * string in the format `\"tag_attribute='value string'\"`.\n * For example, an `attrSelector` value of `\"name='description'\"` matches a tag\n * whose `name` attribute has the value `\"description\"`.\n * Selectors are used with the `querySelector()` Document method,\n * in the format `meta[{attrSelector}]`.\n *\n * @see [HTML meta tag](https://developer.mozilla.org/docs/Web/HTML/Element/meta)\n * @see [Document.querySelector()](https://developer.mozilla.org/docs/Web/API/Document/querySelector)\n *\n *\n * @publicApi\n */\nclass Meta {\n _doc;\n _dom;\n constructor(_doc) {\n this._doc = _doc;\n this._dom = ɵgetDOM();\n }\n /**\n * Retrieves or creates a specific `<meta>` tag element in the current HTML document.\n * In searching for an existing tag, Angular attempts to match the `name` or `property` attribute\n * values in the provided tag definition, and verifies that all other attribute values are equal.\n * If an existing element is found, it is returned and is not modified in any way.\n * @param tag The definition of a `<meta>` element to match or create.\n * @param forceCreation True to create a new element without checking whether one already exists.\n * @returns The existing element with the same attributes and values if found,\n * the new element if no match is found, or `null` if the tag parameter is not defined.\n */\n addTag(tag, forceCreation = false) {\n if (!tag) return null;\n return this._getOrCreateElement(tag, forceCreation);\n }\n /**\n * Retrieves or creates a set of `<meta>` tag elements in the current HTML document.\n * In searching for an existing tag, Angular attempts to match the `name` or `property` attribute\n * values in the provided tag definition, and verifies that all other attribute values are equal.\n * @param tags An array of tag definitions to match or create.\n * @param forceCreation True to create new elements without checking whether they already exist.\n * @returns The matching elements if found, or the new elements.\n */\n addTags(tags, forceCreation = false) {\n if (!tags) return [];\n return tags.reduce((result, tag) => {\n if (tag) {\n result.push(this._getOrCreateElement(tag, forceCreation));\n }\n return result;\n }, []);\n }\n /**\n * Retrieves a `<meta>` tag element in the current HTML document.\n * @param attrSelector The tag attribute and value to match against, in the format\n * `\"tag_attribute='value string'\"`.\n * @returns The matching element, if any.\n */\n getTag(attrSelector) {\n if (!attrSelector) return null;\n return this._doc.querySelector(`meta[${attrSelector}]`) || null;\n }\n /**\n * Retrieves a set of `<meta>` tag elements in the current HTML document.\n * @param attrSelector The tag attribute and value to match against, in the format\n * `\"tag_attribute='value string'\"`.\n * @returns The matching elements, if any.\n */\n getTags(attrSelector) {\n if (!attrSelector) return [];\n const list /*NodeList*/ = this._doc.querySelectorAll(`meta[${attrSelector}]`);\n return list ? [].slice.call(list) : [];\n }\n /**\n * Modifies an existing `<meta>` tag element in the current HTML document.\n * @param tag The tag description with which to replace the existing tag content.\n * @param selector A tag attribute and value to match against, to identify\n * an existing tag. A string in the format `\"tag_attribute=`value string`\"`.\n * If not supplied, matches a tag with the same `name` or `property` attribute value as the\n * replacement tag.\n * @return The modified element.\n */\n updateTag(tag, selector) {\n if (!tag) return null;\n selector = selector || this._parseSelector(tag);\n const meta = this.getTag(selector);\n if (meta) {\n return this._setMetaElementAttributes(tag, meta);\n }\n return this._getOrCreateElement(tag, true);\n }\n /**\n * Removes an existing `<meta>` tag element from the current HTML document.\n * @param attrSelector A tag attribute and value to match against, to identify\n * an existing tag. A string in the format `\"tag_attribute=`value string`\"`.\n */\n removeTag(attrSelector) {\n this.removeTagElement(this.getTag(attrSelector));\n }\n /**\n * Removes an existing `<meta>` tag element from the current HTML document.\n * @param meta The tag definition to match against to identify an existing tag.\n */\n removeTagElement(meta) {\n if (meta) {\n this._dom.remove(meta);\n }\n }\n _getOrCreateElement(meta, forceCreation = false) {\n if (!forceCreation) {\n const selector = this._parseSelector(meta);\n // It's allowed to have multiple elements with the same name so it's not enough to\n // just check that element with the same name already present on the page. We also need to\n // check if element has tag attributes\n const elem = this.getTags(selector).filter(elem => this._containsAttributes(meta, elem))[0];\n if (elem !== undefined) return elem;\n }\n const element = this._dom.createElement('meta');\n this._setMetaElementAttributes(meta, element);\n const head = this._doc.getElementsByTagName('head')[0];\n head.appendChild(element);\n return element;\n }\n _setMetaElementAttributes(tag, el) {\n Object.keys(tag).forEach(prop => el.setAttribute(this._getMetaKeyMap(prop), tag[prop]));\n return el;\n }\n _parseSelector(tag) {\n const attr = tag.name ? 'name' : 'property';\n return `${attr}=\"${tag[attr]}\"`;\n }\n _containsAttributes(tag, elem) {\n return Object.keys(tag).every(key => elem.getAttribute(this._getMetaKeyMap(key)) === tag[key]);\n }\n _getMetaKeyMap(prop) {\n return META_KEYS_MAP[prop] || prop;\n }\n static ɵfac = function Meta_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || Meta)(i0.ɵɵinject(DOCUMENT));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: Meta,\n factory: Meta.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(Meta, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }], null);\n})();\n/**\n * Mapping for MetaDefinition properties with their correct meta attribute names\n */\nconst META_KEYS_MAP = {\n httpEquiv: 'http-equiv'\n};\n\n/**\n * A service that can be used to get and set the title of a current HTML document.\n *\n * Since an Angular application can't be bootstrapped on the entire HTML document (`<html>` tag)\n * it is not possible to bind to the `text` property of the `HTMLTitleElement` elements\n * (representing the `<title>` tag). Instead, this service can be used to set and get the current\n * title value.\n *\n * @publicApi\n */\nclass Title {\n _doc;\n constructor(_doc) {\n this._doc = _doc;\n }\n /**\n * Get the title of the current HTML document.\n */\n getTitle() {\n return this._doc.title;\n }\n /**\n * Set the title of the current HTML document.\n * @param newTitle\n */\n setTitle(newTitle) {\n this._doc.title = newTitle || '';\n }\n static ɵfac = function Title_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || Title)(i0.ɵɵinject(DOCUMENT));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: Title,\n factory: Title.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(Title, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }], null);\n})();\n\n/**\n * Exports the value under a given `name` in the global property `ng`. For example `ng.probe` if\n * `name` is `'probe'`.\n * @param name Name under which it will be exported. Keep in mind this will be a property of the\n * global `ng` object.\n * @param value The value to export.\n */\nfunction exportNgVar(name, value) {\n if (typeof COMPILED === 'undefined' || !COMPILED) {\n // Note: we can't export `ng` when using closure enhanced optimization as:\n // - closure declares globals itself for minified names, which sometimes clobber our `ng` global\n // - we can't declare a closure extern as the namespace `ng` is already used within Google\n // for typings for angularJS (via `goog.provide('ng....')`).\n const ng = ɵglobal['ng'] = ɵglobal['ng'] || {};\n ng[name] = value;\n }\n}\nclass ChangeDetectionPerfRecord {\n msPerTick;\n numTicks;\n constructor(msPerTick, numTicks) {\n this.msPerTick = msPerTick;\n this.numTicks = numTicks;\n }\n}\n/**\n * Entry point for all Angular profiling-related debug tools. This object\n * corresponds to the `ng.profiler` in the dev console.\n */\nclass AngularProfiler {\n appRef;\n constructor(ref) {\n this.appRef = ref.injector.get(ApplicationRef);\n }\n // tslint:disable:no-console\n /**\n * Exercises change detection in a loop and then prints the average amount of\n * time in milliseconds how long a single round of change detection takes for\n * the current state of the UI. It runs a minimum of 5 rounds for a minimum\n * of 500 milliseconds.\n *\n * Optionally, a user may pass a `config` parameter containing a map of\n * options. Supported options are:\n *\n * `record` (boolean) - causes the profiler to record a CPU profile while\n * it exercises the change detector. Example:\n *\n * ```ts\n * ng.profiler.timeChangeDetection({record: true})\n * ```\n */\n timeChangeDetection(config) {\n const record = config && config['record'];\n const profileName = 'Change Detection';\n // Profiler is not available in Android browsers without dev tools opened\n if (record && 'profile' in console && typeof console.profile === 'function') {\n console.profile(profileName);\n }\n const start = performance.now();\n let numTicks = 0;\n while (numTicks < 5 || performance.now() - start < 500) {\n this.appRef.tick();\n numTicks++;\n }\n const end = performance.now();\n if (record && 'profileEnd' in console && typeof console.profileEnd === 'function') {\n console.profileEnd(profileName);\n }\n const msPerTick = (end - start) / numTicks;\n console.log(`ran ${numTicks} change detection cycles`);\n console.log(`${msPerTick.toFixed(2)} ms per check`);\n return new ChangeDetectionPerfRecord(msPerTick, numTicks);\n }\n}\nconst PROFILER_GLOBAL_NAME = 'profiler';\n/**\n * Enabled Angular debug tools that are accessible via your browser's\n * developer console.\n *\n * Usage:\n *\n * 1. Open developer console (e.g. in Chrome Ctrl + Shift + j)\n * 1. Type `ng.` (usually the console will show auto-complete suggestion)\n * 1. Try the change detection profiler `ng.profiler.timeChangeDetection()`\n * then hit Enter.\n *\n * @publicApi\n */\nfunction enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}\n/**\n * Disables Angular tools.\n *\n * @publicApi\n */\nfunction disableDebugTools() {\n exportNgVar(PROFILER_GLOBAL_NAME, null);\n}\n\n/**\n * Predicates for use with {@link DebugElement}'s query functions.\n *\n * @publicApi\n */\nclass By {\n /**\n * Match all nodes.\n *\n * @usageNotes\n * ### Example\n *\n * {@example platform-browser/dom/debug/ts/by/by.ts region='by_all'}\n */\n static all() {\n return () => true;\n }\n /**\n * Match elements by the given CSS selector.\n *\n * @usageNotes\n * ### Example\n *\n * {@example platform-browser/dom/debug/ts/by/by.ts region='by_css'}\n */\n static css(selector) {\n return debugElement => {\n return debugElement.nativeElement != null ? elementMatches(debugElement.nativeElement, selector) : false;\n };\n }\n /**\n * Match nodes that have the given directive present.\n *\n * @usageNotes\n * ### Example\n *\n * {@example platform-browser/dom/debug/ts/by/by.ts region='by_directive'}\n */\n static directive(type) {\n return debugNode => debugNode.providerTokens.indexOf(type) !== -1;\n }\n}\nfunction elementMatches(n, selector) {\n if (ɵgetDOM().isElementNode(n)) {\n return n.matches && n.matches(selector) || n.msMatchesSelector && n.msMatchesSelector(selector) || n.webkitMatchesSelector && n.webkitMatchesSelector(selector);\n }\n return false;\n}\n\n/**\n * Supported HammerJS recognizer event names.\n */\nconst EVENT_NAMES = {\n // pan\n 'pan': true,\n 'panstart': true,\n 'panmove': true,\n 'panend': true,\n 'pancancel': true,\n 'panleft': true,\n 'panright': true,\n 'panup': true,\n 'pandown': true,\n // pinch\n 'pinch': true,\n 'pinchstart': true,\n 'pinchmove': true,\n 'pinchend': true,\n 'pinchcancel': true,\n 'pinchin': true,\n 'pinchout': true,\n // press\n 'press': true,\n 'pressup': true,\n // rotate\n 'rotate': true,\n 'rotatestart': true,\n 'rotatemove': true,\n 'rotateend': true,\n 'rotatecancel': true,\n // swipe\n 'swipe': true,\n 'swipeleft': true,\n 'swiperight': true,\n 'swipeup': true,\n 'swipedown': true,\n // tap\n 'tap': true,\n 'doubletap': true\n};\n/**\n * DI token for providing [HammerJS](https://hammerjs.github.io/) support to Angular.\n * @see {@link HammerGestureConfig}\n *\n * @ngModule HammerModule\n * @publicApi\n */\nconst HAMMER_GESTURE_CONFIG = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'HammerGestureConfig' : '');\n/**\n * Injection token used to provide a HammerLoader to Angular.\n *\n * @see {@link HammerLoader}\n *\n * @publicApi\n */\nconst HAMMER_LOADER = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'HammerLoader' : '');\n/**\n * An injectable [HammerJS Manager](https://hammerjs.github.io/api/#hammermanager)\n * for gesture recognition. Configures specific event recognition.\n * @publicApi\n */\nclass HammerGestureConfig {\n /**\n * A set of supported event names for gestures to be used in Angular.\n * Angular supports all built-in recognizers, as listed in\n * [HammerJS documentation](https://hammerjs.github.io/).\n */\n events = [];\n /**\n * Maps gesture event names to a set of configuration options\n * that specify overrides to the default values for specific properties.\n *\n * The key is a supported event name to be configured,\n * and the options object contains a set of properties, with override values\n * to be applied to the named recognizer event.\n * For example, to disable recognition of the rotate event, specify\n * `{\"rotate\": {\"enable\": false}}`.\n *\n * Properties that are not present take the HammerJS default values.\n * For information about which properties are supported for which events,\n * and their allowed and default values, see\n * [HammerJS documentation](https://hammerjs.github.io/).\n *\n */\n overrides = {};\n /**\n * Properties whose default values can be overridden for a given event.\n * Different sets of properties apply to different events.\n * For information about which properties are supported for which events,\n * and their allowed and default values, see\n * [HammerJS documentation](https://hammerjs.github.io/).\n */\n options;\n /**\n * Creates a [HammerJS Manager](https://hammerjs.github.io/api/#hammermanager)\n * and attaches it to a given HTML element.\n * @param element The element that will recognize gestures.\n * @returns A HammerJS event-manager object.\n */\n buildHammer(element) {\n const mc = new Hammer(element, this.options);\n mc.get('pinch').set({\n enable: true\n });\n mc.get('rotate').set({\n enable: true\n });\n for (const eventName in this.overrides) {\n mc.get(eventName).set(this.overrides[eventName]);\n }\n return mc;\n }\n static ɵfac = function HammerGestureConfig_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HammerGestureConfig)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HammerGestureConfig,\n factory: HammerGestureConfig.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HammerGestureConfig, [{\n type: Injectable\n }], null, null);\n})();\n/**\n * Event plugin that adds Hammer support to an application.\n *\n * @ngModule HammerModule\n */\nclass HammerGesturesPlugin extends EventManagerPlugin {\n _config;\n _injector;\n loader;\n _loaderPromise = null;\n constructor(doc, _config, _injector, loader) {\n super(doc);\n this._config = _config;\n this._injector = _injector;\n this.loader = loader;\n }\n supports(eventName) {\n if (!EVENT_NAMES.hasOwnProperty(eventName.toLowerCase()) && !this.isCustomEvent(eventName)) {\n return false;\n }\n if (!window.Hammer && !this.loader) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n // Get a `Console` through an injector to tree-shake the\n // class when it is unused in production.\n const _console = this._injector.get(ɵConsole);\n _console.warn(`The \"${eventName}\" event cannot be bound because Hammer.JS is not ` + `loaded and no custom loader has been specified.`);\n }\n return false;\n }\n return true;\n }\n addEventListener(element, eventName, handler) {\n const zone = this.manager.getZone();\n eventName = eventName.toLowerCase();\n // If Hammer is not present but a loader is specified, we defer adding the event listener\n // until Hammer is loaded.\n if (!window.Hammer && this.loader) {\n this._loaderPromise = this._loaderPromise || zone.runOutsideAngular(() => this.loader());\n // This `addEventListener` method returns a function to remove the added listener.\n // Until Hammer is loaded, the returned function needs to *cancel* the registration rather\n // than remove anything.\n let cancelRegistration = false;\n let deregister = () => {\n cancelRegistration = true;\n };\n zone.runOutsideAngular(() => this._loaderPromise.then(() => {\n // If Hammer isn't actually loaded when the custom loader resolves, give up.\n if (!window.Hammer) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const _console = this._injector.get(ɵConsole);\n _console.warn(`The custom HAMMER_LOADER completed, but Hammer.JS is not present.`);\n }\n deregister = () => {};\n return;\n }\n if (!cancelRegistration) {\n // Now that Hammer is loaded and the listener is being loaded for real,\n // the deregistration function changes from canceling registration to\n // removal.\n deregister = this.addEventListener(element, eventName, handler);\n }\n }).catch(() => {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const _console = this._injector.get(ɵConsole);\n _console.warn(`The \"${eventName}\" event cannot be bound because the custom ` + `Hammer.JS loader failed.`);\n }\n deregister = () => {};\n }));\n // Return a function that *executes* `deregister` (and not `deregister` itself) so that we\n // can change the behavior of `deregister` once the listener is added. Using a closure in\n // this way allows us to avoid any additional data structures to track listener removal.\n return () => {\n deregister();\n };\n }\n return zone.runOutsideAngular(() => {\n // Creating the manager bind events, must be done outside of angular\n const mc = this._config.buildHammer(element);\n const callback = function (eventObj) {\n zone.runGuarded(function () {\n handler(eventObj);\n });\n };\n mc.on(eventName, callback);\n return () => {\n mc.off(eventName, callback);\n // destroy mc to prevent memory leak\n if (typeof mc.destroy === 'function') {\n mc.destroy();\n }\n };\n });\n }\n isCustomEvent(eventName) {\n return this._config.events.indexOf(eventName) > -1;\n }\n static ɵfac = function HammerGesturesPlugin_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HammerGesturesPlugin)(i0.ɵɵinject(DOCUMENT), i0.ɵɵinject(HAMMER_GESTURE_CONFIG), i0.ɵɵinject(i0.Injector), i0.ɵɵinject(HAMMER_LOADER, 8));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HammerGesturesPlugin,\n factory: HammerGesturesPlugin.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HammerGesturesPlugin, [{\n type: Injectable\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }, {\n type: HammerGestureConfig,\n decorators: [{\n type: Inject,\n args: [HAMMER_GESTURE_CONFIG]\n }]\n }, {\n type: i0.Injector\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [HAMMER_LOADER]\n }]\n }], null);\n})();\n/**\n * Adds support for HammerJS.\n *\n * Import this module at the root of your application so that Angular can work with\n * HammerJS to detect gesture events.\n *\n * Note that applications still need to include the HammerJS script itself. This module\n * simply sets up the coordination layer between HammerJS and Angular's `EventManager`.\n *\n * @publicApi\n */\nclass HammerModule {\n static ɵfac = function HammerModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || HammerModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: HammerModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n providers: [{\n provide: EVENT_MANAGER_PLUGINS,\n useClass: HammerGesturesPlugin,\n multi: true,\n deps: [DOCUMENT, HAMMER_GESTURE_CONFIG, Injector, [new Optional(), HAMMER_LOADER]]\n }, {\n provide: HAMMER_GESTURE_CONFIG,\n useClass: HammerGestureConfig,\n deps: []\n }]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HammerModule, [{\n type: NgModule,\n args: [{\n providers: [{\n provide: EVENT_MANAGER_PLUGINS,\n useClass: HammerGesturesPlugin,\n multi: true,\n deps: [DOCUMENT, HAMMER_GESTURE_CONFIG, Injector, [new Optional(), HAMMER_LOADER]]\n }, {\n provide: HAMMER_GESTURE_CONFIG,\n useClass: HammerGestureConfig,\n deps: []\n }]\n }]\n }], null, null);\n})();\n\n/**\n * DomSanitizer helps preventing Cross Site Scripting Security bugs (XSS) by sanitizing\n * values to be safe to use in the different DOM contexts.\n *\n * For example, when binding a URL in an `<a [href]=\"someValue\">` hyperlink, `someValue` will be\n * sanitized so that an attacker cannot inject e.g. a `javascript:` URL that would execute code on\n * the website.\n *\n * In specific situations, it might be necessary to disable sanitization, for example if the\n * application genuinely needs to produce a `javascript:` style link with a dynamic value in it.\n * Users can bypass security by constructing a value with one of the `bypassSecurityTrust...`\n * methods, and then binding to that value from the template.\n *\n * These situations should be very rare, and extraordinary care must be taken to avoid creating a\n * Cross Site Scripting (XSS) security bug!\n *\n * When using `bypassSecurityTrust...`, make sure to call the method as early as possible and as\n * close as possible to the source of the value, to make it easy to verify no security bug is\n * created by its use.\n *\n * It is not required (and not recommended) to bypass security if the value is safe, e.g. a URL that\n * does not start with a suspicious protocol, or an HTML snippet that does not contain dangerous\n * code. The sanitizer leaves safe values intact.\n *\n * @security Calling any of the `bypassSecurityTrust...` APIs disables Angular's built-in\n * sanitization for the value passed in. Carefully check and audit all values and code paths going\n * into this call. Make sure any user data is appropriately escaped for this security context.\n * For more detail, see the [Security Guide](https://g.co/ng/security).\n *\n * @publicApi\n */\nclass DomSanitizer {\n static ɵfac = function DomSanitizer_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DomSanitizer)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DomSanitizer,\n factory: function DomSanitizer_Factory(__ngFactoryType__) {\n let __ngConditionalFactory__ = null;\n if (__ngFactoryType__) {\n __ngConditionalFactory__ = new (__ngFactoryType__ || DomSanitizer)();\n } else {\n __ngConditionalFactory__ = i0.ɵɵinject(DomSanitizerImpl);\n }\n return __ngConditionalFactory__;\n },\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DomSanitizer, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useExisting: forwardRef(() => DomSanitizerImpl)\n }]\n }], null, null);\n})();\nclass DomSanitizerImpl extends DomSanitizer {\n _doc;\n constructor(_doc) {\n super();\n this._doc = _doc;\n }\n sanitize(ctx, value) {\n if (value == null) return null;\n switch (ctx) {\n case SecurityContext.NONE:\n return value;\n case SecurityContext.HTML:\n if (ɵallowSanitizationBypassAndThrow(value, \"HTML\" /* BypassType.Html */)) {\n return ɵunwrapSafeValue(value);\n }\n return ɵ_sanitizeHtml(this._doc, String(value)).toString();\n case SecurityContext.STYLE:\n if (ɵallowSanitizationBypassAndThrow(value, \"Style\" /* BypassType.Style */)) {\n return ɵunwrapSafeValue(value);\n }\n return value;\n case SecurityContext.SCRIPT:\n if (ɵallowSanitizationBypassAndThrow(value, \"Script\" /* BypassType.Script */)) {\n return ɵunwrapSafeValue(value);\n }\n throw new ɵRuntimeError(5200 /* RuntimeErrorCode.SANITIZATION_UNSAFE_SCRIPT */, (typeof ngDevMode === 'undefined' || ngDevMode) && 'unsafe value used in a script context');\n case SecurityContext.URL:\n if (ɵallowSanitizationBypassAndThrow(value, \"URL\" /* BypassType.Url */)) {\n return ɵunwrapSafeValue(value);\n }\n return ɵ_sanitizeUrl(String(value));\n case SecurityContext.RESOURCE_URL:\n if (ɵallowSanitizationBypassAndThrow(value, \"ResourceURL\" /* BypassType.ResourceUrl */)) {\n return ɵunwrapSafeValue(value);\n }\n throw new ɵRuntimeError(5201 /* RuntimeErrorCode.SANITIZATION_UNSAFE_RESOURCE_URL */, (typeof ngDevMode === 'undefined' || ngDevMode) && `unsafe value used in a resource URL context (see ${ɵXSS_SECURITY_URL})`);\n default:\n throw new ɵRuntimeError(5202 /* RuntimeErrorCode.SANITIZATION_UNEXPECTED_CTX */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Unexpected SecurityContext ${ctx} (see ${ɵXSS_SECURITY_URL})`);\n }\n }\n bypassSecurityTrustHtml(value) {\n return ɵbypassSanitizationTrustHtml(value);\n }\n bypassSecurityTrustStyle(value) {\n return ɵbypassSanitizationTrustStyle(value);\n }\n bypassSecurityTrustScript(value) {\n return ɵbypassSanitizationTrustScript(value);\n }\n bypassSecurityTrustUrl(value) {\n return ɵbypassSanitizationTrustUrl(value);\n }\n bypassSecurityTrustResourceUrl(value) {\n return ɵbypassSanitizationTrustResourceUrl(value);\n }\n static ɵfac = function DomSanitizerImpl_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DomSanitizerImpl)(i0.ɵɵinject(DOCUMENT));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DomSanitizerImpl,\n factory: DomSanitizerImpl.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DomSanitizerImpl, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DOCUMENT]\n }]\n }], null);\n})();\n\n/**\n * The list of features as an enum to uniquely type each `HydrationFeature`.\n * @see {@link HydrationFeature}\n *\n * @publicApi\n */\nvar HydrationFeatureKind;\n(function (HydrationFeatureKind) {\n HydrationFeatureKind[HydrationFeatureKind[\"NoHttpTransferCache\"] = 0] = \"NoHttpTransferCache\";\n HydrationFeatureKind[HydrationFeatureKind[\"HttpTransferCacheOptions\"] = 1] = \"HttpTransferCacheOptions\";\n HydrationFeatureKind[HydrationFeatureKind[\"I18nSupport\"] = 2] = \"I18nSupport\";\n HydrationFeatureKind[HydrationFeatureKind[\"EventReplay\"] = 3] = \"EventReplay\";\n HydrationFeatureKind[HydrationFeatureKind[\"IncrementalHydration\"] = 4] = \"IncrementalHydration\";\n})(HydrationFeatureKind || (HydrationFeatureKind = {}));\n/**\n * Helper function to create an object that represents a Hydration feature.\n */\nfunction hydrationFeature(ɵkind, ɵproviders = [], ɵoptions = {}) {\n return {\n ɵkind,\n ɵproviders\n };\n}\n/**\n * Disables HTTP transfer cache. Effectively causes HTTP requests to be performed twice: once on the\n * server and other one on the browser.\n *\n * @publicApi\n */\nfunction withNoHttpTransferCache() {\n // This feature has no providers and acts as a flag that turns off\n // HTTP transfer cache (which otherwise is turned on by default).\n return hydrationFeature(HydrationFeatureKind.NoHttpTransferCache);\n}\n/**\n * The function accepts an object, which allows to configure cache parameters,\n * such as which headers should be included (no headers are included by default),\n * whether POST requests should be cached or a callback function to determine if a\n * particular request should be cached.\n *\n * @publicApi\n */\nfunction withHttpTransferCacheOptions(options) {\n // This feature has no providers and acts as a flag to pass options to the HTTP transfer cache.\n return hydrationFeature(HydrationFeatureKind.HttpTransferCacheOptions, ɵwithHttpTransferCache(options));\n}\n/**\n * Enables support for hydrating i18n blocks.\n *\n * @developerPreview\n * @publicApi\n */\nfunction withI18nSupport() {\n return hydrationFeature(HydrationFeatureKind.I18nSupport, ɵwithI18nSupport());\n}\n/**\n * Enables support for replaying user events (e.g. `click`s) that happened on a page\n * before hydration logic has completed. Once an application is hydrated, all captured\n * events are replayed and relevant event listeners are executed.\n *\n * @usageNotes\n *\n * Basic example of how you can enable event replay in your application when\n * `bootstrapApplication` function is used:\n * ```ts\n * bootstrapApplication(AppComponent, {\n * providers: [provideClientHydration(withEventReplay())]\n * });\n * ```\n * @publicApi\n * @see {@link provideClientHydration}\n */\nfunction withEventReplay() {\n return hydrationFeature(HydrationFeatureKind.EventReplay, ɵwithEventReplay());\n}\n/**\n * Enables support for incremental hydration using the `hydrate` trigger syntax.\n *\n * @usageNotes\n *\n * Basic example of how you can enable incremental hydration in your application when\n * the `bootstrapApplication` function is used:\n * ```ts\n * bootstrapApplication(AppComponent, {\n * providers: [provideClientHydration(withIncrementalHydration())]\n * });\n * ```\n * @experimental\n * @publicApi\n * @see {@link provideClientHydration}\n */\nfunction withIncrementalHydration() {\n return hydrationFeature(HydrationFeatureKind.IncrementalHydration, ɵwithIncrementalHydration());\n}\n/**\n * Returns an `ENVIRONMENT_INITIALIZER` token setup with a function\n * that verifies whether compatible ZoneJS was used in an application\n * and logs a warning in a console if it's not the case.\n */\nfunction provideZoneJsCompatibilityDetector() {\n return [{\n provide: ENVIRONMENT_INITIALIZER,\n useValue: () => {\n const ngZone = inject(NgZone);\n const isZoneless = inject(ɵZONELESS_ENABLED);\n // Checking `ngZone instanceof NgZone` would be insufficient here,\n // because custom implementations might use NgZone as a base class.\n if (!isZoneless && ngZone.constructor !== NgZone) {\n const console = inject(ɵConsole);\n const message = ɵformatRuntimeError(-5000 /* RuntimeErrorCode.UNSUPPORTED_ZONEJS_INSTANCE */, 'Angular detected that hydration was enabled for an application ' + 'that uses a custom or a noop Zone.js implementation. ' + 'This is not yet a fully supported configuration.');\n console.warn(message);\n }\n },\n multi: true\n }];\n}\n/**\n * Sets up providers necessary to enable hydration functionality for the application.\n *\n * By default, the function enables the recommended set of features for the optimal\n * performance for most of the applications. It includes the following features:\n *\n * * Reconciling DOM hydration. Learn more about it [here](guide/hydration).\n * * [`HttpClient`](api/common/http/HttpClient) response caching while running on the server and\n * transferring this cache to the client to avoid extra HTTP requests. Learn more about data caching\n * [here](guide/ssr#caching-data-when-using-httpclient).\n *\n * These functions allow you to disable some of the default features or enable new ones:\n *\n * * {@link withNoHttpTransferCache} to disable HTTP transfer cache\n * * {@link withHttpTransferCacheOptions} to configure some HTTP transfer cache options\n * * {@link withI18nSupport} to enable hydration support for i18n blocks\n * * {@link withEventReplay} to enable support for replaying user events\n *\n * @usageNotes\n *\n * Basic example of how you can enable hydration in your application when\n * `bootstrapApplication` function is used:\n * ```ts\n * bootstrapApplication(AppComponent, {\n * providers: [provideClientHydration()]\n * });\n * ```\n *\n * Alternatively if you are using NgModules, you would add `provideClientHydration`\n * to your root app module's provider list.\n * ```ts\n * @NgModule({\n * declarations: [RootCmp],\n * bootstrap: [RootCmp],\n * providers: [provideClientHydration()],\n * })\n * export class AppModule {}\n * ```\n *\n * @see {@link withNoHttpTransferCache}\n * @see {@link withHttpTransferCacheOptions}\n * @see {@link withI18nSupport}\n * @see {@link withEventReplay}\n *\n * @param features Optional features to configure additional router behaviors.\n * @returns A set of providers to enable hydration.\n *\n * @publicApi\n */\nfunction provideClientHydration(...features) {\n const providers = [];\n const featuresKind = new Set();\n const hasHttpTransferCacheOptions = featuresKind.has(HydrationFeatureKind.HttpTransferCacheOptions);\n for (const {\n ɵproviders,\n ɵkind\n } of features) {\n featuresKind.add(ɵkind);\n if (ɵproviders.length) {\n providers.push(ɵproviders);\n }\n }\n if (typeof ngDevMode !== 'undefined' && ngDevMode && featuresKind.has(HydrationFeatureKind.NoHttpTransferCache) && hasHttpTransferCacheOptions) {\n // TODO: Make this a runtime error\n throw new Error('Configuration error: found both withHttpTransferCacheOptions() and withNoHttpTransferCache() in the same call to provideClientHydration(), which is a contradiction.');\n }\n return makeEnvironmentProviders([typeof ngDevMode !== 'undefined' && ngDevMode ? provideZoneJsCompatibilityDetector() : [], ɵwithDomHydration(), featuresKind.has(HydrationFeatureKind.NoHttpTransferCache) || hasHttpTransferCacheOptions ? [] : ɵwithHttpTransferCache({}), providers]);\n}\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the platform-browser package.\n */\n/**\n * @publicApi\n */\nconst VERSION = new Version('19.2.1');\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of this package.\n */\n// This file only reexports content of the `src` folder. Keep it that way.\n\n// This file is not used to build this module. It is only used during editing\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { BrowserModule, By, DomSanitizer, EVENT_MANAGER_PLUGINS, EventManager, EventManagerPlugin, HAMMER_GESTURE_CONFIG, HAMMER_LOADER, HammerGestureConfig, HammerModule, HydrationFeatureKind, Meta, REMOVE_STYLES_ON_COMPONENT_DESTROY, Title, VERSION, bootstrapApplication, createApplication, disableDebugTools, enableDebugTools, platformBrowser, provideClientHydration, provideProtractorTestingSupport, withEventReplay, withHttpTransferCacheOptions, withI18nSupport, withIncrementalHydration, withNoHttpTransferCache, BrowserDomAdapter as ɵBrowserDomAdapter, BrowserGetTestability as ɵBrowserGetTestability, DomEventsPlugin as ɵDomEventsPlugin, DomRendererFactory2 as ɵDomRendererFactory2, DomSanitizerImpl as ɵDomSanitizerImpl, HammerGesturesPlugin as ɵHammerGesturesPlugin, INTERNAL_BROWSER_PLATFORM_PROVIDERS as ɵINTERNAL_BROWSER_PLATFORM_PROVIDERS, KeyEventsPlugin as ɵKeyEventsPlugin, SharedStylesHost as ɵSharedStylesHost, initDomAdapter as ɵinitDomAdapter };\n","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\nimport * as i0 from '@angular/core';\nimport { ɵisPromise, ɵRuntimeError, Injectable, createEnvironmentInjector, ɵisNgModule, isStandalone, InjectionToken, EventEmitter, input, inject, ViewContainerRef, ChangeDetectorRef, Directive, Input, Output, reflectComponentType, ɵisInjectable, runInInjectionContext, Component, Compiler, NgModuleFactory, NgZone, afterNextRender, EnvironmentInjector, DestroyRef, ɵConsole, ɵPendingTasksInternal, ɵɵsanitizeUrlOrResourceUrl, booleanAttribute, Attribute, HostBinding, HostListener, Optional, ContentChildren, makeEnvironmentProviders, APP_BOOTSTRAP_LISTENER, ENVIRONMENT_INITIALIZER, Injector, ApplicationRef, InjectFlags, APP_INITIALIZER, SkipSelf, NgModule, Version, ɵpublishExternalGlobalUtil } from '@angular/core';\nimport { isObservable, from, of, BehaviorSubject, combineLatest, EmptyError, concat, defer, pipe, throwError, EMPTY, ConnectableObservable, Subject, Subscription } from 'rxjs';\nimport * as i3 from '@angular/common';\nimport { DOCUMENT, Location, ViewportScroller, LOCATION_INITIALIZED, LocationStrategy, HashLocationStrategy, PathLocationStrategy } from '@angular/common';\nimport { map, switchMap, take, startWith, filter, mergeMap, first, concatMap, tap, catchError, scan, defaultIfEmpty, last as last$1, takeLast, finalize, refCount, takeUntil, mergeAll } from 'rxjs/operators';\nimport * as i1 from '@angular/platform-browser';\n\n/**\n * The primary routing outlet.\n *\n * @publicApi\n */\nconst PRIMARY_OUTLET = 'primary';\n/**\n * A private symbol used to store the value of `Route.title` inside the `Route.data` if it is a\n * static string or `Route.resolve` if anything else. This allows us to reuse the existing route\n * data/resolvers to support the title feature without new instrumentation in the `Router` pipeline.\n */\nconst RouteTitleKey = /* @__PURE__ */Symbol('RouteTitle');\nclass ParamsAsMap {\n params;\n constructor(params) {\n this.params = params || {};\n }\n has(name) {\n return Object.prototype.hasOwnProperty.call(this.params, name);\n }\n get(name) {\n if (this.has(name)) {\n const v = this.params[name];\n return Array.isArray(v) ? v[0] : v;\n }\n return null;\n }\n getAll(name) {\n if (this.has(name)) {\n const v = this.params[name];\n return Array.isArray(v) ? v : [v];\n }\n return [];\n }\n get keys() {\n return Object.keys(this.params);\n }\n}\n/**\n * Converts a `Params` instance to a `ParamMap`.\n * @param params The instance to convert.\n * @returns The new map instance.\n *\n * @publicApi\n */\nfunction convertToParamMap(params) {\n return new ParamsAsMap(params);\n}\n/**\n * Matches the route configuration (`route`) against the actual URL (`segments`).\n *\n * When no matcher is defined on a `Route`, this is the matcher used by the Router by default.\n *\n * @param segments The remaining unmatched segments in the current navigation\n * @param segmentGroup The current segment group being matched\n * @param route The `Route` to match against.\n *\n * @see {@link UrlMatchResult}\n * @see {@link Route}\n *\n * @returns The resulting match information or `null` if the `route` should not match.\n * @publicApi\n */\nfunction defaultUrlMatcher(segments, segmentGroup, route) {\n const parts = route.path.split('/');\n if (parts.length > segments.length) {\n // The actual URL is shorter than the config, no match\n return null;\n }\n if (route.pathMatch === 'full' && (segmentGroup.hasChildren() || parts.length < segments.length)) {\n // The config is longer than the actual URL but we are looking for a full match, return null\n return null;\n }\n const posParams = {};\n // Check each config part against the actual URL\n for (let index = 0; index < parts.length; index++) {\n const part = parts[index];\n const segment = segments[index];\n const isParameter = part[0] === ':';\n if (isParameter) {\n posParams[part.substring(1)] = segment;\n } else if (part !== segment.path) {\n // The actual URL part does not match the config, no match\n return null;\n }\n }\n return {\n consumed: segments.slice(0, parts.length),\n posParams\n };\n}\nfunction shallowEqualArrays(a, b) {\n if (a.length !== b.length) return false;\n for (let i = 0; i < a.length; ++i) {\n if (!shallowEqual(a[i], b[i])) return false;\n }\n return true;\n}\nfunction shallowEqual(a, b) {\n // While `undefined` should never be possible, it would sometimes be the case in IE 11\n // and pre-chromium Edge. The check below accounts for this edge case.\n const k1 = a ? getDataKeys(a) : undefined;\n const k2 = b ? getDataKeys(b) : undefined;\n if (!k1 || !k2 || k1.length != k2.length) {\n return false;\n }\n let key;\n for (let i = 0; i < k1.length; i++) {\n key = k1[i];\n if (!equalArraysOrString(a[key], b[key])) {\n return false;\n }\n }\n return true;\n}\n/**\n * Gets the keys of an object, including `symbol` keys.\n */\nfunction getDataKeys(obj) {\n return [...Object.keys(obj), ...Object.getOwnPropertySymbols(obj)];\n}\n/**\n * Test equality for arrays of strings or a string.\n */\nfunction equalArraysOrString(a, b) {\n if (Array.isArray(a) && Array.isArray(b)) {\n if (a.length !== b.length) return false;\n const aSorted = [...a].sort();\n const bSorted = [...b].sort();\n return aSorted.every((val, index) => bSorted[index] === val);\n } else {\n return a === b;\n }\n}\n/**\n * Return the last element of an array.\n */\nfunction last(a) {\n return a.length > 0 ? a[a.length - 1] : null;\n}\nfunction wrapIntoObservable(value) {\n if (isObservable(value)) {\n return value;\n }\n if (ɵisPromise(value)) {\n // Use `Promise.resolve()` to wrap promise-like instances.\n // Required ie when a Resolver returns a AngularJS `$q` promise to correctly trigger the\n // change detection.\n return from(Promise.resolve(value));\n }\n return of(value);\n}\nconst pathCompareMap = {\n 'exact': equalSegmentGroups,\n 'subset': containsSegmentGroup\n};\nconst paramCompareMap = {\n 'exact': equalParams,\n 'subset': containsParams,\n 'ignored': () => true\n};\nfunction containsTree(container, containee, options) {\n return pathCompareMap[options.paths](container.root, containee.root, options.matrixParams) && paramCompareMap[options.queryParams](container.queryParams, containee.queryParams) && !(options.fragment === 'exact' && container.fragment !== containee.fragment);\n}\nfunction equalParams(container, containee) {\n // TODO: This does not handle array params correctly.\n return shallowEqual(container, containee);\n}\nfunction equalSegmentGroups(container, containee, matrixParams) {\n if (!equalPath(container.segments, containee.segments)) return false;\n if (!matrixParamsMatch(container.segments, containee.segments, matrixParams)) {\n return false;\n }\n if (container.numberOfChildren !== containee.numberOfChildren) return false;\n for (const c in containee.children) {\n if (!container.children[c]) return false;\n if (!equalSegmentGroups(container.children[c], containee.children[c], matrixParams)) return false;\n }\n return true;\n}\nfunction containsParams(container, containee) {\n return Object.keys(containee).length <= Object.keys(container).length && Object.keys(containee).every(key => equalArraysOrString(container[key], containee[key]));\n}\nfunction containsSegmentGroup(container, containee, matrixParams) {\n return containsSegmentGroupHelper(container, containee, containee.segments, matrixParams);\n}\nfunction containsSegmentGroupHelper(container, containee, containeePaths, matrixParams) {\n if (container.segments.length > containeePaths.length) {\n const current = container.segments.slice(0, containeePaths.length);\n if (!equalPath(current, containeePaths)) return false;\n if (containee.hasChildren()) return false;\n if (!matrixParamsMatch(current, containeePaths, matrixParams)) return false;\n return true;\n } else if (container.segments.length === containeePaths.length) {\n if (!equalPath(container.segments, containeePaths)) return false;\n if (!matrixParamsMatch(container.segments, containeePaths, matrixParams)) return false;\n for (const c in containee.children) {\n if (!container.children[c]) return false;\n if (!containsSegmentGroup(container.children[c], containee.children[c], matrixParams)) {\n return false;\n }\n }\n return true;\n } else {\n const current = containeePaths.slice(0, container.segments.length);\n const next = containeePaths.slice(container.segments.length);\n if (!equalPath(container.segments, current)) return false;\n if (!matrixParamsMatch(container.segments, current, matrixParams)) return false;\n if (!container.children[PRIMARY_OUTLET]) return false;\n return containsSegmentGroupHelper(container.children[PRIMARY_OUTLET], containee, next, matrixParams);\n }\n}\nfunction matrixParamsMatch(containerPaths, containeePaths, options) {\n return containeePaths.every((containeeSegment, i) => {\n return paramCompareMap[options](containerPaths[i].parameters, containeeSegment.parameters);\n });\n}\n/**\n * @description\n *\n * Represents the parsed URL.\n *\n * Since a router state is a tree, and the URL is nothing but a serialized state, the URL is a\n * serialized tree.\n * UrlTree is a data structure that provides a lot of affordances in dealing with URLs\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * @Component({templateUrl:'template.html'})\n * class MyComponent {\n * constructor(router: Router) {\n * const tree: UrlTree =\n * router.parseUrl('/team/33/(user/victor//support:help)?debug=true#fragment');\n * const f = tree.fragment; // return 'fragment'\n * const q = tree.queryParams; // returns {debug: 'true'}\n * const g: UrlSegmentGroup = tree.root.children[PRIMARY_OUTLET];\n * const s: UrlSegment[] = g.segments; // returns 2 segments 'team' and '33'\n * g.children[PRIMARY_OUTLET].segments; // returns 2 segments 'user' and 'victor'\n * g.children['support'].segments; // return 1 segment 'help'\n * }\n * }\n * ```\n *\n * @publicApi\n */\nclass UrlTree {\n root;\n queryParams;\n fragment;\n /** @internal */\n _queryParamMap;\n constructor(/** The root segment group of the URL tree */\n root = new UrlSegmentGroup([], {}), /** The query params of the URL */\n queryParams = {}, /** The fragment of the URL */\n fragment = null) {\n this.root = root;\n this.queryParams = queryParams;\n this.fragment = fragment;\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (root.segments.length > 0) {\n throw new ɵRuntimeError(4015 /* RuntimeErrorCode.INVALID_ROOT_URL_SEGMENT */, 'The root `UrlSegmentGroup` should not contain `segments`. ' + 'Instead, these segments belong in the `children` so they can be associated with a named outlet.');\n }\n }\n }\n get queryParamMap() {\n this._queryParamMap ??= convertToParamMap(this.queryParams);\n return this._queryParamMap;\n }\n /** @docsNotRequired */\n toString() {\n return DEFAULT_SERIALIZER.serialize(this);\n }\n}\n/**\n * @description\n *\n * Represents the parsed URL segment group.\n *\n * See `UrlTree` for more information.\n *\n * @publicApi\n */\nclass UrlSegmentGroup {\n segments;\n children;\n /** The parent node in the url tree */\n parent = null;\n constructor(/** The URL segments of this group. See `UrlSegment` for more information */\n segments, /** The list of children of this group */\n children) {\n this.segments = segments;\n this.children = children;\n Object.values(children).forEach(v => v.parent = this);\n }\n /** Whether the segment has child segments */\n hasChildren() {\n return this.numberOfChildren > 0;\n }\n /** Number of child segments */\n get numberOfChildren() {\n return Object.keys(this.children).length;\n }\n /** @docsNotRequired */\n toString() {\n return serializePaths(this);\n }\n}\n/**\n * @description\n *\n * Represents a single URL segment.\n *\n * A UrlSegment is a part of a URL between the two slashes. It contains a path and the matrix\n * parameters associated with the segment.\n *\n * @usageNotes\n * ### Example\n *\n * ```ts\n * @Component({templateUrl:'template.html'})\n * class MyComponent {\n * constructor(router: Router) {\n * const tree: UrlTree = router.parseUrl('/team;id=33');\n * const g: UrlSegmentGroup = tree.root.children[PRIMARY_OUTLET];\n * const s: UrlSegment[] = g.segments;\n * s[0].path; // returns 'team'\n * s[0].parameters; // returns {id: 33}\n * }\n * }\n * ```\n *\n * @publicApi\n */\nclass UrlSegment {\n path;\n parameters;\n /** @internal */\n _parameterMap;\n constructor(/** The path part of a URL segment */\n path, /** The matrix parameters associated with a segment */\n parameters) {\n this.path = path;\n this.parameters = parameters;\n }\n get parameterMap() {\n this._parameterMap ??= convertToParamMap(this.parameters);\n return this._parameterMap;\n }\n /** @docsNotRequired */\n toString() {\n return serializePath(this);\n }\n}\nfunction equalSegments(as, bs) {\n return equalPath(as, bs) && as.every((a, i) => shallowEqual(a.parameters, bs[i].parameters));\n}\nfunction equalPath(as, bs) {\n if (as.length !== bs.length) return false;\n return as.every((a, i) => a.path === bs[i].path);\n}\nfunction mapChildrenIntoArray(segment, fn) {\n let res = [];\n Object.entries(segment.children).forEach(([childOutlet, child]) => {\n if (childOutlet === PRIMARY_OUTLET) {\n res = res.concat(fn(child, childOutlet));\n }\n });\n Object.entries(segment.children).forEach(([childOutlet, child]) => {\n if (childOutlet !== PRIMARY_OUTLET) {\n res = res.concat(fn(child, childOutlet));\n }\n });\n return res;\n}\n/**\n * @description\n *\n * Serializes and deserializes a URL string into a URL tree.\n *\n * The url serialization strategy is customizable. You can\n * make all URLs case insensitive by providing a custom UrlSerializer.\n *\n * See `DefaultUrlSerializer` for an example of a URL serializer.\n *\n * @publicApi\n */\nclass UrlSerializer {\n static ɵfac = function UrlSerializer_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || UrlSerializer)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: UrlSerializer,\n factory: () => (() => new DefaultUrlSerializer())(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(UrlSerializer, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: () => new DefaultUrlSerializer()\n }]\n }], null, null);\n})();\n/**\n * @description\n *\n * A default implementation of the `UrlSerializer`.\n *\n * Example URLs:\n *\n * ```\n * /inbox/33(popup:compose)\n * /inbox/33;open=true/messages/44\n * ```\n *\n * DefaultUrlSerializer uses parentheses to serialize secondary segments (e.g., popup:compose), the\n * colon syntax to specify the outlet, and the ';parameter=value' syntax (e.g., open=true) to\n * specify route specific parameters.\n *\n * @publicApi\n */\nclass DefaultUrlSerializer {\n /** Parses a url into a `UrlTree` */\n parse(url) {\n const p = new UrlParser(url);\n return new UrlTree(p.parseRootSegment(), p.parseQueryParams(), p.parseFragment());\n }\n /** Converts a `UrlTree` into a url */\n serialize(tree) {\n const segment = `/${serializeSegment(tree.root, true)}`;\n const query = serializeQueryParams(tree.queryParams);\n const fragment = typeof tree.fragment === `string` ? `#${encodeUriFragment(tree.fragment)}` : '';\n return `${segment}${query}${fragment}`;\n }\n}\nconst DEFAULT_SERIALIZER = new DefaultUrlSerializer();\nfunction serializePaths(segment) {\n return segment.segments.map(p => serializePath(p)).join('/');\n}\nfunction serializeSegment(segment, root) {\n if (!segment.hasChildren()) {\n return serializePaths(segment);\n }\n if (root) {\n const primary = segment.children[PRIMARY_OUTLET] ? serializeSegment(segment.children[PRIMARY_OUTLET], false) : '';\n const children = [];\n Object.entries(segment.children).forEach(([k, v]) => {\n if (k !== PRIMARY_OUTLET) {\n children.push(`${k}:${serializeSegment(v, false)}`);\n }\n });\n return children.length > 0 ? `${primary}(${children.join('//')})` : primary;\n } else {\n const children = mapChildrenIntoArray(segment, (v, k) => {\n if (k === PRIMARY_OUTLET) {\n return [serializeSegment(segment.children[PRIMARY_OUTLET], false)];\n }\n return [`${k}:${serializeSegment(v, false)}`];\n });\n // use no parenthesis if the only child is a primary outlet route\n if (Object.keys(segment.children).length === 1 && segment.children[PRIMARY_OUTLET] != null) {\n return `${serializePaths(segment)}/${children[0]}`;\n }\n return `${serializePaths(segment)}/(${children.join('//')})`;\n }\n}\n/**\n * Encodes a URI string with the default encoding. This function will only ever be called from\n * `encodeUriQuery` or `encodeUriSegment` as it's the base set of encodings to be used. We need\n * a custom encoding because encodeURIComponent is too aggressive and encodes stuff that doesn't\n * have to be encoded per https://url.spec.whatwg.org.\n */\nfunction encodeUriString(s) {\n return encodeURIComponent(s).replace(/%40/g, '@').replace(/%3A/gi, ':').replace(/%24/g, '$').replace(/%2C/gi, ',');\n}\n/**\n * This function should be used to encode both keys and values in a query string key/value. In\n * the following URL, you need to call encodeUriQuery on \"k\" and \"v\":\n *\n * http://www.site.org/html;mk=mv?k=v#f\n */\nfunction encodeUriQuery(s) {\n return encodeUriString(s).replace(/%3B/gi, ';');\n}\n/**\n * This function should be used to encode a URL fragment. In the following URL, you need to call\n * encodeUriFragment on \"f\":\n *\n * http://www.site.org/html;mk=mv?k=v#f\n */\nfunction encodeUriFragment(s) {\n return encodeURI(s);\n}\n/**\n * This function should be run on any URI segment as well as the key and value in a key/value\n * pair for matrix params. In the following URL, you need to call encodeUriSegment on \"html\",\n * \"mk\", and \"mv\":\n *\n * http://www.site.org/html;mk=mv?k=v#f\n */\nfunction encodeUriSegment(s) {\n return encodeUriString(s).replace(/\\(/g, '%28').replace(/\\)/g, '%29').replace(/%26/gi, '&');\n}\nfunction decode(s) {\n return decodeURIComponent(s);\n}\n// Query keys/values should have the \"+\" replaced first, as \"+\" in a query string is \" \".\n// decodeURIComponent function will not decode \"+\" as a space.\nfunction decodeQuery(s) {\n return decode(s.replace(/\\+/g, '%20'));\n}\nfunction serializePath(path) {\n return `${encodeUriSegment(path.path)}${serializeMatrixParams(path.parameters)}`;\n}\nfunction serializeMatrixParams(params) {\n return Object.entries(params).map(([key, value]) => `;${encodeUriSegment(key)}=${encodeUriSegment(value)}`).join('');\n}\nfunction serializeQueryParams(params) {\n const strParams = Object.entries(params).map(([name, value]) => {\n return Array.isArray(value) ? value.map(v => `${encodeUriQuery(name)}=${encodeUriQuery(v)}`).join('&') : `${encodeUriQuery(name)}=${encodeUriQuery(value)}`;\n }).filter(s => s);\n return strParams.length ? `?${strParams.join('&')}` : '';\n}\nconst SEGMENT_RE = /^[^\\/()?;#]+/;\nfunction matchSegments(str) {\n const match = str.match(SEGMENT_RE);\n return match ? match[0] : '';\n}\nconst MATRIX_PARAM_SEGMENT_RE = /^[^\\/()?;=#]+/;\nfunction matchMatrixKeySegments(str) {\n const match = str.match(MATRIX_PARAM_SEGMENT_RE);\n return match ? match[0] : '';\n}\nconst QUERY_PARAM_RE = /^[^=?&#]+/;\n// Return the name of the query param at the start of the string or an empty string\nfunction matchQueryParams(str) {\n const match = str.match(QUERY_PARAM_RE);\n return match ? match[0] : '';\n}\nconst QUERY_PARAM_VALUE_RE = /^[^&#]+/;\n// Return the value of the query param at the start of the string or an empty string\nfunction matchUrlQueryParamValue(str) {\n const match = str.match(QUERY_PARAM_VALUE_RE);\n return match ? match[0] : '';\n}\nclass UrlParser {\n url;\n remaining;\n constructor(url) {\n this.url = url;\n this.remaining = url;\n }\n parseRootSegment() {\n this.consumeOptional('/');\n if (this.remaining === '' || this.peekStartsWith('?') || this.peekStartsWith('#')) {\n return new UrlSegmentGroup([], {});\n }\n // The root segment group never has segments\n return new UrlSegmentGroup([], this.parseChildren());\n }\n parseQueryParams() {\n const params = {};\n if (this.consumeOptional('?')) {\n do {\n this.parseQueryParam(params);\n } while (this.consumeOptional('&'));\n }\n return params;\n }\n parseFragment() {\n return this.consumeOptional('#') ? decodeURIComponent(this.remaining) : null;\n }\n parseChildren() {\n if (this.remaining === '') {\n return {};\n }\n this.consumeOptional('/');\n const segments = [];\n if (!this.peekStartsWith('(')) {\n segments.push(this.parseSegment());\n }\n while (this.peekStartsWith('/') && !this.peekStartsWith('//') && !this.peekStartsWith('/(')) {\n this.capture('/');\n segments.push(this.parseSegment());\n }\n let children = {};\n if (this.peekStartsWith('/(')) {\n this.capture('/');\n children = this.parseParens(true);\n }\n let res = {};\n if (this.peekStartsWith('(')) {\n res = this.parseParens(false);\n }\n if (segments.length > 0 || Object.keys(children).length > 0) {\n res[PRIMARY_OUTLET] = new UrlSegmentGroup(segments, children);\n }\n return res;\n }\n // parse a segment with its matrix parameters\n // ie `name;k1=v1;k2`\n parseSegment() {\n const path = matchSegments(this.remaining);\n if (path === '' && this.peekStartsWith(';')) {\n throw new ɵRuntimeError(4009 /* RuntimeErrorCode.EMPTY_PATH_WITH_PARAMS */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Empty path url segment cannot have parameters: '${this.remaining}'.`);\n }\n this.capture(path);\n return new UrlSegment(decode(path), this.parseMatrixParams());\n }\n parseMatrixParams() {\n const params = {};\n while (this.consumeOptional(';')) {\n this.parseParam(params);\n }\n return params;\n }\n parseParam(params) {\n const key = matchMatrixKeySegments(this.remaining);\n if (!key) {\n return;\n }\n this.capture(key);\n let value = '';\n if (this.consumeOptional('=')) {\n const valueMatch = matchSegments(this.remaining);\n if (valueMatch) {\n value = valueMatch;\n this.capture(value);\n }\n }\n params[decode(key)] = decode(value);\n }\n // Parse a single query parameter `name[=value]`\n parseQueryParam(params) {\n const key = matchQueryParams(this.remaining);\n if (!key) {\n return;\n }\n this.capture(key);\n let value = '';\n if (this.consumeOptional('=')) {\n const valueMatch = matchUrlQueryParamValue(this.remaining);\n if (valueMatch) {\n value = valueMatch;\n this.capture(value);\n }\n }\n const decodedKey = decodeQuery(key);\n const decodedVal = decodeQuery(value);\n if (params.hasOwnProperty(decodedKey)) {\n // Append to existing values\n let currentVal = params[decodedKey];\n if (!Array.isArray(currentVal)) {\n currentVal = [currentVal];\n params[decodedKey] = currentVal;\n }\n currentVal.push(decodedVal);\n } else {\n // Create a new value\n params[decodedKey] = decodedVal;\n }\n }\n // parse `(a/b//outlet_name:c/d)`\n parseParens(allowPrimary) {\n const segments = {};\n this.capture('(');\n while (!this.consumeOptional(')') && this.remaining.length > 0) {\n const path = matchSegments(this.remaining);\n const next = this.remaining[path.length];\n // if is is not one of these characters, then the segment was unescaped\n // or the group was not closed\n if (next !== '/' && next !== ')' && next !== ';') {\n throw new ɵRuntimeError(4010 /* RuntimeErrorCode.UNPARSABLE_URL */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Cannot parse url '${this.url}'`);\n }\n let outletName = undefined;\n if (path.indexOf(':') > -1) {\n outletName = path.slice(0, path.indexOf(':'));\n this.capture(outletName);\n this.capture(':');\n } else if (allowPrimary) {\n outletName = PRIMARY_OUTLET;\n }\n const children = this.parseChildren();\n segments[outletName] = Object.keys(children).length === 1 ? children[PRIMARY_OUTLET] : new UrlSegmentGroup([], children);\n this.consumeOptional('//');\n }\n return segments;\n }\n peekStartsWith(str) {\n return this.remaining.startsWith(str);\n }\n // Consumes the prefix when it is present and returns whether it has been consumed\n consumeOptional(str) {\n if (this.peekStartsWith(str)) {\n this.remaining = this.remaining.substring(str.length);\n return true;\n }\n return false;\n }\n capture(str) {\n if (!this.consumeOptional(str)) {\n throw new ɵRuntimeError(4011 /* RuntimeErrorCode.UNEXPECTED_VALUE_IN_URL */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Expected \"${str}\".`);\n }\n }\n}\nfunction createRoot(rootCandidate) {\n return rootCandidate.segments.length > 0 ? new UrlSegmentGroup([], {\n [PRIMARY_OUTLET]: rootCandidate\n }) : rootCandidate;\n}\n/**\n * Recursively\n * - merges primary segment children into their parents\n * - drops empty children (those which have no segments and no children themselves). This latter\n * prevents serializing a group into something like `/a(aux:)`, where `aux` is an empty child\n * segment.\n * - merges named outlets without a primary segment sibling into the children. This prevents\n * serializing a URL like `//(a:a)(b:b) instead of `/(a:a//b:b)` when the aux b route lives on the\n * root but the `a` route lives under an empty path primary route.\n */\nfunction squashSegmentGroup(segmentGroup) {\n const newChildren = {};\n for (const [childOutlet, child] of Object.entries(segmentGroup.children)) {\n const childCandidate = squashSegmentGroup(child);\n // moves named children in an empty path primary child into this group\n if (childOutlet === PRIMARY_OUTLET && childCandidate.segments.length === 0 && childCandidate.hasChildren()) {\n for (const [grandChildOutlet, grandChild] of Object.entries(childCandidate.children)) {\n newChildren[grandChildOutlet] = grandChild;\n }\n } // don't add empty children\n else if (childCandidate.segments.length > 0 || childCandidate.hasChildren()) {\n newChildren[childOutlet] = childCandidate;\n }\n }\n const s = new UrlSegmentGroup(segmentGroup.segments, newChildren);\n return mergeTrivialChildren(s);\n}\n/**\n * When possible, merges the primary outlet child into the parent `UrlSegmentGroup`.\n *\n * When a segment group has only one child which is a primary outlet, merges that child into the\n * parent. That is, the child segment group's segments are merged into the `s` and the child's\n * children become the children of `s`. Think of this like a 'squash', merging the child segment\n * group into the parent.\n */\nfunction mergeTrivialChildren(s) {\n if (s.numberOfChildren === 1 && s.children[PRIMARY_OUTLET]) {\n const c = s.children[PRIMARY_OUTLET];\n return new UrlSegmentGroup(s.segments.concat(c.segments), c.children);\n }\n return s;\n}\nfunction isUrlTree(v) {\n return v instanceof UrlTree;\n}\n\n/**\n * Creates a `UrlTree` relative to an `ActivatedRouteSnapshot`.\n *\n * @publicApi\n *\n *\n * @param relativeTo The `ActivatedRouteSnapshot` to apply the commands to\n * @param commands An array of URL fragments with which to construct the new URL tree.\n * If the path is static, can be the literal URL string. For a dynamic path, pass an array of path\n * segments, followed by the parameters for each segment.\n * The fragments are applied to the one provided in the `relativeTo` parameter.\n * @param queryParams The query parameters for the `UrlTree`. `null` if the `UrlTree` does not have\n * any query parameters.\n * @param fragment The fragment for the `UrlTree`. `null` if the `UrlTree` does not have a fragment.\n *\n * @usageNotes\n *\n * ```ts\n * // create /team/33/user/11\n * createUrlTreeFromSnapshot(snapshot, ['/team', 33, 'user', 11]);\n *\n * // create /team/33;expand=true/user/11\n * createUrlTreeFromSnapshot(snapshot, ['/team', 33, {expand: true}, 'user', 11]);\n *\n * // you can collapse static segments like this (this works only with the first passed-in value):\n * createUrlTreeFromSnapshot(snapshot, ['/team/33/user', userId]);\n *\n * // If the first segment can contain slashes, and you do not want the router to split it,\n * // you can do the following:\n * createUrlTreeFromSnapshot(snapshot, [{segmentPath: '/one/two'}]);\n *\n * // create /team/33/(user/11//right:chat)\n * createUrlTreeFromSnapshot(snapshot, ['/team', 33, {outlets: {primary: 'user/11', right:\n * 'chat'}}], null, null);\n *\n * // remove the right secondary node\n * createUrlTreeFromSnapshot(snapshot, ['/team', 33, {outlets: {primary: 'user/11', right: null}}]);\n *\n * // For the examples below, assume the current URL is for the `/team/33/user/11` and the\n * `ActivatedRouteSnapshot` points to `user/11`:\n *\n * // navigate to /team/33/user/11/details\n * createUrlTreeFromSnapshot(snapshot, ['details']);\n *\n * // navigate to /team/33/user/22\n * createUrlTreeFromSnapshot(snapshot, ['../22']);\n *\n * // navigate to /team/44/user/22\n * createUrlTreeFromSnapshot(snapshot, ['../../team/44/user/22']);\n * ```\n */\nfunction createUrlTreeFromSnapshot(relativeTo, commands, queryParams = null, fragment = null) {\n const relativeToUrlSegmentGroup = createSegmentGroupFromRoute(relativeTo);\n return createUrlTreeFromSegmentGroup(relativeToUrlSegmentGroup, commands, queryParams, fragment);\n}\nfunction createSegmentGroupFromRoute(route) {\n let targetGroup;\n function createSegmentGroupFromRouteRecursive(currentRoute) {\n const childOutlets = {};\n for (const childSnapshot of currentRoute.children) {\n const root = createSegmentGroupFromRouteRecursive(childSnapshot);\n childOutlets[childSnapshot.outlet] = root;\n }\n const segmentGroup = new UrlSegmentGroup(currentRoute.url, childOutlets);\n if (currentRoute === route) {\n targetGroup = segmentGroup;\n }\n return segmentGroup;\n }\n const rootCandidate = createSegmentGroupFromRouteRecursive(route.root);\n const rootSegmentGroup = createRoot(rootCandidate);\n return targetGroup ?? rootSegmentGroup;\n}\nfunction createUrlTreeFromSegmentGroup(relativeTo, commands, queryParams, fragment) {\n let root = relativeTo;\n while (root.parent) {\n root = root.parent;\n }\n // There are no commands so the `UrlTree` goes to the same path as the one created from the\n // `UrlSegmentGroup`. All we need to do is update the `queryParams` and `fragment` without\n // applying any other logic.\n if (commands.length === 0) {\n return tree(root, root, root, queryParams, fragment);\n }\n const nav = computeNavigation(commands);\n if (nav.toRoot()) {\n return tree(root, root, new UrlSegmentGroup([], {}), queryParams, fragment);\n }\n const position = findStartingPositionForTargetGroup(nav, root, relativeTo);\n const newSegmentGroup = position.processChildren ? updateSegmentGroupChildren(position.segmentGroup, position.index, nav.commands) : updateSegmentGroup(position.segmentGroup, position.index, nav.commands);\n return tree(root, position.segmentGroup, newSegmentGroup, queryParams, fragment);\n}\nfunction isMatrixParams(command) {\n return typeof command === 'object' && command != null && !command.outlets && !command.segmentPath;\n}\n/**\n * Determines if a given command has an `outlets` map. When we encounter a command\n * with an outlets k/v map, we need to apply each outlet individually to the existing segment.\n */\nfunction isCommandWithOutlets(command) {\n return typeof command === 'object' && command != null && command.outlets;\n}\nfunction tree(oldRoot, oldSegmentGroup, newSegmentGroup, queryParams, fragment) {\n let qp = {};\n if (queryParams) {\n Object.entries(queryParams).forEach(([name, value]) => {\n qp[name] = Array.isArray(value) ? value.map(v => `${v}`) : `${value}`;\n });\n }\n let rootCandidate;\n if (oldRoot === oldSegmentGroup) {\n rootCandidate = newSegmentGroup;\n } else {\n rootCandidate = replaceSegment(oldRoot, oldSegmentGroup, newSegmentGroup);\n }\n const newRoot = createRoot(squashSegmentGroup(rootCandidate));\n return new UrlTree(newRoot, qp, fragment);\n}\n/**\n * Replaces the `oldSegment` which is located in some child of the `current` with the `newSegment`.\n * This also has the effect of creating new `UrlSegmentGroup` copies to update references. This\n * shouldn't be necessary but the fallback logic for an invalid ActivatedRoute in the creation uses\n * the Router's current url tree. If we don't create new segment groups, we end up modifying that\n * value.\n */\nfunction replaceSegment(current, oldSegment, newSegment) {\n const children = {};\n Object.entries(current.children).forEach(([outletName, c]) => {\n if (c === oldSegment) {\n children[outletName] = newSegment;\n } else {\n children[outletName] = replaceSegment(c, oldSegment, newSegment);\n }\n });\n return new UrlSegmentGroup(current.segments, children);\n}\nclass Navigation {\n isAbsolute;\n numberOfDoubleDots;\n commands;\n constructor(isAbsolute, numberOfDoubleDots, commands) {\n this.isAbsolute = isAbsolute;\n this.numberOfDoubleDots = numberOfDoubleDots;\n this.commands = commands;\n if (isAbsolute && commands.length > 0 && isMatrixParams(commands[0])) {\n throw new ɵRuntimeError(4003 /* RuntimeErrorCode.ROOT_SEGMENT_MATRIX_PARAMS */, (typeof ngDevMode === 'undefined' || ngDevMode) && 'Root segment cannot have matrix parameters');\n }\n const cmdWithOutlet = commands.find(isCommandWithOutlets);\n if (cmdWithOutlet && cmdWithOutlet !== last(commands)) {\n throw new ɵRuntimeError(4004 /* RuntimeErrorCode.MISPLACED_OUTLETS_COMMAND */, (typeof ngDevMode === 'undefined' || ngDevMode) && '{outlets:{}} has to be the last command');\n }\n }\n toRoot() {\n return this.isAbsolute && this.commands.length === 1 && this.commands[0] == '/';\n }\n}\n/** Transforms commands to a normalized `Navigation` */\nfunction computeNavigation(commands) {\n if (typeof commands[0] === 'string' && commands.length === 1 && commands[0] === '/') {\n return new Navigation(true, 0, commands);\n }\n let numberOfDoubleDots = 0;\n let isAbsolute = false;\n const res = commands.reduce((res, cmd, cmdIdx) => {\n if (typeof cmd === 'object' && cmd != null) {\n if (cmd.outlets) {\n const outlets = {};\n Object.entries(cmd.outlets).forEach(([name, commands]) => {\n outlets[name] = typeof commands === 'string' ? commands.split('/') : commands;\n });\n return [...res, {\n outlets\n }];\n }\n if (cmd.segmentPath) {\n return [...res, cmd.segmentPath];\n }\n }\n if (!(typeof cmd === 'string')) {\n return [...res, cmd];\n }\n if (cmdIdx === 0) {\n cmd.split('/').forEach((urlPart, partIndex) => {\n if (partIndex == 0 && urlPart === '.') {\n // skip './a'\n } else if (partIndex == 0 && urlPart === '') {\n // '/a'\n isAbsolute = true;\n } else if (urlPart === '..') {\n // '../a'\n numberOfDoubleDots++;\n } else if (urlPart != '') {\n res.push(urlPart);\n }\n });\n return res;\n }\n return [...res, cmd];\n }, []);\n return new Navigation(isAbsolute, numberOfDoubleDots, res);\n}\nclass Position {\n segmentGroup;\n processChildren;\n index;\n constructor(segmentGroup, processChildren, index) {\n this.segmentGroup = segmentGroup;\n this.processChildren = processChildren;\n this.index = index;\n }\n}\nfunction findStartingPositionForTargetGroup(nav, root, target) {\n if (nav.isAbsolute) {\n return new Position(root, true, 0);\n }\n if (!target) {\n // `NaN` is used only to maintain backwards compatibility with incorrectly mocked\n // `ActivatedRouteSnapshot` in tests. In prior versions of this code, the position here was\n // determined based on an internal property that was rarely mocked, resulting in `NaN`. In\n // reality, this code path should _never_ be touched since `target` is not allowed to be falsey.\n return new Position(root, false, NaN);\n }\n if (target.parent === null) {\n return new Position(target, true, 0);\n }\n const modifier = isMatrixParams(nav.commands[0]) ? 0 : 1;\n const index = target.segments.length - 1 + modifier;\n return createPositionApplyingDoubleDots(target, index, nav.numberOfDoubleDots);\n}\nfunction createPositionApplyingDoubleDots(group, index, numberOfDoubleDots) {\n let g = group;\n let ci = index;\n let dd = numberOfDoubleDots;\n while (dd > ci) {\n dd -= ci;\n g = g.parent;\n if (!g) {\n throw new ɵRuntimeError(4005 /* RuntimeErrorCode.INVALID_DOUBLE_DOTS */, (typeof ngDevMode === 'undefined' || ngDevMode) && \"Invalid number of '../'\");\n }\n ci = g.segments.length;\n }\n return new Position(g, false, ci - dd);\n}\nfunction getOutlets(commands) {\n if (isCommandWithOutlets(commands[0])) {\n return commands[0].outlets;\n }\n return {\n [PRIMARY_OUTLET]: commands\n };\n}\nfunction updateSegmentGroup(segmentGroup, startIndex, commands) {\n segmentGroup ??= new UrlSegmentGroup([], {});\n if (segmentGroup.segments.length === 0 && segmentGroup.hasChildren()) {\n return updateSegmentGroupChildren(segmentGroup, startIndex, commands);\n }\n const m = prefixedWith(segmentGroup, startIndex, commands);\n const slicedCommands = commands.slice(m.commandIndex);\n if (m.match && m.pathIndex < segmentGroup.segments.length) {\n const g = new UrlSegmentGroup(segmentGroup.segments.slice(0, m.pathIndex), {});\n g.children[PRIMARY_OUTLET] = new UrlSegmentGroup(segmentGroup.segments.slice(m.pathIndex), segmentGroup.children);\n return updateSegmentGroupChildren(g, 0, slicedCommands);\n } else if (m.match && slicedCommands.length === 0) {\n return new UrlSegmentGroup(segmentGroup.segments, {});\n } else if (m.match && !segmentGroup.hasChildren()) {\n return createNewSegmentGroup(segmentGroup, startIndex, commands);\n } else if (m.match) {\n return updateSegmentGroupChildren(segmentGroup, 0, slicedCommands);\n } else {\n return createNewSegmentGroup(segmentGroup, startIndex, commands);\n }\n}\nfunction updateSegmentGroupChildren(segmentGroup, startIndex, commands) {\n if (commands.length === 0) {\n return new UrlSegmentGroup(segmentGroup.segments, {});\n } else {\n const outlets = getOutlets(commands);\n const children = {};\n // If the set of commands applies to anything other than the primary outlet and the child\n // segment is an empty path primary segment on its own, we want to apply the commands to the\n // empty child path rather than here. The outcome is that the empty primary child is effectively\n // removed from the final output UrlTree. Imagine the following config:\n //\n // {path: '', children: [{path: '**', outlet: 'popup'}]}.\n //\n // Navigation to /(popup:a) will activate the child outlet correctly Given a follow-up\n // navigation with commands\n // ['/', {outlets: {'popup': 'b'}}], we _would not_ want to apply the outlet commands to the\n // root segment because that would result in\n // //(popup:a)(popup:b) since the outlet command got applied one level above where it appears in\n // the `ActivatedRoute` rather than updating the existing one.\n //\n // Because empty paths do not appear in the URL segments and the fact that the segments used in\n // the output `UrlTree` are squashed to eliminate these empty paths where possible\n // https://github.com/angular/angular/blob/13f10de40e25c6900ca55bd83b36bd533dacfa9e/packages/router/src/url_tree.ts#L755\n // it can be hard to determine what is the right thing to do when applying commands to a\n // `UrlSegmentGroup` that is created from an \"unsquashed\"/expanded `ActivatedRoute` tree.\n // This code effectively \"squashes\" empty path primary routes when they have no siblings on\n // the same level of the tree.\n if (Object.keys(outlets).some(o => o !== PRIMARY_OUTLET) && segmentGroup.children[PRIMARY_OUTLET] && segmentGroup.numberOfChildren === 1 && segmentGroup.children[PRIMARY_OUTLET].segments.length === 0) {\n const childrenOfEmptyChild = updateSegmentGroupChildren(segmentGroup.children[PRIMARY_OUTLET], startIndex, commands);\n return new UrlSegmentGroup(segmentGroup.segments, childrenOfEmptyChild.children);\n }\n Object.entries(outlets).forEach(([outlet, commands]) => {\n if (typeof commands === 'string') {\n commands = [commands];\n }\n if (commands !== null) {\n children[outlet] = updateSegmentGroup(segmentGroup.children[outlet], startIndex, commands);\n }\n });\n Object.entries(segmentGroup.children).forEach(([childOutlet, child]) => {\n if (outlets[childOutlet] === undefined) {\n children[childOutlet] = child;\n }\n });\n return new UrlSegmentGroup(segmentGroup.segments, children);\n }\n}\nfunction prefixedWith(segmentGroup, startIndex, commands) {\n let currentCommandIndex = 0;\n let currentPathIndex = startIndex;\n const noMatch = {\n match: false,\n pathIndex: 0,\n commandIndex: 0\n };\n while (currentPathIndex < segmentGroup.segments.length) {\n if (currentCommandIndex >= commands.length) return noMatch;\n const path = segmentGroup.segments[currentPathIndex];\n const command = commands[currentCommandIndex];\n // Do not try to consume command as part of the prefixing if it has outlets because it can\n // contain outlets other than the one being processed. Consuming the outlets command would\n // result in other outlets being ignored.\n if (isCommandWithOutlets(command)) {\n break;\n }\n const curr = `${command}`;\n const next = currentCommandIndex < commands.length - 1 ? commands[currentCommandIndex + 1] : null;\n if (currentPathIndex > 0 && curr === undefined) break;\n if (curr && next && typeof next === 'object' && next.outlets === undefined) {\n if (!compare(curr, next, path)) return noMatch;\n currentCommandIndex += 2;\n } else {\n if (!compare(curr, {}, path)) return noMatch;\n currentCommandIndex++;\n }\n currentPathIndex++;\n }\n return {\n match: true,\n pathIndex: currentPathIndex,\n commandIndex: currentCommandIndex\n };\n}\nfunction createNewSegmentGroup(segmentGroup, startIndex, commands) {\n const paths = segmentGroup.segments.slice(0, startIndex);\n let i = 0;\n while (i < commands.length) {\n const command = commands[i];\n if (isCommandWithOutlets(command)) {\n const children = createNewSegmentChildren(command.outlets);\n return new UrlSegmentGroup(paths, children);\n }\n // if we start with an object literal, we need to reuse the path part from the segment\n if (i === 0 && isMatrixParams(commands[0])) {\n const p = segmentGroup.segments[startIndex];\n paths.push(new UrlSegment(p.path, stringify(commands[0])));\n i++;\n continue;\n }\n const curr = isCommandWithOutlets(command) ? command.outlets[PRIMARY_OUTLET] : `${command}`;\n const next = i < commands.length - 1 ? commands[i + 1] : null;\n if (curr && next && isMatrixParams(next)) {\n paths.push(new UrlSegment(curr, stringify(next)));\n i += 2;\n } else {\n paths.push(new UrlSegment(curr, {}));\n i++;\n }\n }\n return new UrlSegmentGroup(paths, {});\n}\nfunction createNewSegmentChildren(outlets) {\n const children = {};\n Object.entries(outlets).forEach(([outlet, commands]) => {\n if (typeof commands === 'string') {\n commands = [commands];\n }\n if (commands !== null) {\n children[outlet] = createNewSegmentGroup(new UrlSegmentGroup([], {}), 0, commands);\n }\n });\n return children;\n}\nfunction stringify(params) {\n const res = {};\n Object.entries(params).forEach(([k, v]) => res[k] = `${v}`);\n return res;\n}\nfunction compare(path, params, segment) {\n return path == segment.path && shallowEqual(params, segment.parameters);\n}\nconst IMPERATIVE_NAVIGATION = 'imperative';\n/**\n * Identifies the type of a router event.\n *\n * @publicApi\n */\nvar EventType;\n(function (EventType) {\n EventType[EventType[\"NavigationStart\"] = 0] = \"NavigationStart\";\n EventType[EventType[\"NavigationEnd\"] = 1] = \"NavigationEnd\";\n EventType[EventType[\"NavigationCancel\"] = 2] = \"NavigationCancel\";\n EventType[EventType[\"NavigationError\"] = 3] = \"NavigationError\";\n EventType[EventType[\"RoutesRecognized\"] = 4] = \"RoutesRecognized\";\n EventType[EventType[\"ResolveStart\"] = 5] = \"ResolveStart\";\n EventType[EventType[\"ResolveEnd\"] = 6] = \"ResolveEnd\";\n EventType[EventType[\"GuardsCheckStart\"] = 7] = \"GuardsCheckStart\";\n EventType[EventType[\"GuardsCheckEnd\"] = 8] = \"GuardsCheckEnd\";\n EventType[EventType[\"RouteConfigLoadStart\"] = 9] = \"RouteConfigLoadStart\";\n EventType[EventType[\"RouteConfigLoadEnd\"] = 10] = \"RouteConfigLoadEnd\";\n EventType[EventType[\"ChildActivationStart\"] = 11] = \"ChildActivationStart\";\n EventType[EventType[\"ChildActivationEnd\"] = 12] = \"ChildActivationEnd\";\n EventType[EventType[\"ActivationStart\"] = 13] = \"ActivationStart\";\n EventType[EventType[\"ActivationEnd\"] = 14] = \"ActivationEnd\";\n EventType[EventType[\"Scroll\"] = 15] = \"Scroll\";\n EventType[EventType[\"NavigationSkipped\"] = 16] = \"NavigationSkipped\";\n})(EventType || (EventType = {}));\n/**\n * Base for events the router goes through, as opposed to events tied to a specific\n * route. Fired one time for any given navigation.\n *\n * The following code shows how a class subscribes to router events.\n *\n * ```ts\n * import {Event, RouterEvent, Router} from '@angular/router';\n *\n * class MyService {\n * constructor(public router: Router) {\n * router.events.pipe(\n * filter((e: Event | RouterEvent): e is RouterEvent => e instanceof RouterEvent)\n * ).subscribe((e: RouterEvent) => {\n * // Do something\n * });\n * }\n * }\n * ```\n *\n * @see {@link Event}\n * @see [Router events summary](guide/routing/router-reference#router-events)\n * @publicApi\n */\nclass RouterEvent {\n id;\n url;\n constructor(/** A unique ID that the router assigns to every router navigation. */\n id, /** The URL that is the destination for this navigation. */\n url) {\n this.id = id;\n this.url = url;\n }\n}\n/**\n * An event triggered when a navigation starts.\n *\n * @publicApi\n */\nclass NavigationStart extends RouterEvent {\n type = EventType.NavigationStart;\n /**\n * Identifies the call or event that triggered the navigation.\n * An `imperative` trigger is a call to `router.navigateByUrl()` or `router.navigate()`.\n *\n * @see {@link NavigationEnd}\n * @see {@link NavigationCancel}\n * @see {@link NavigationError}\n */\n navigationTrigger;\n /**\n * The navigation state that was previously supplied to the `pushState` call,\n * when the navigation is triggered by a `popstate` event. Otherwise null.\n *\n * The state object is defined by `NavigationExtras`, and contains any\n * developer-defined state value, as well as a unique ID that\n * the router assigns to every router transition/navigation.\n *\n * From the perspective of the router, the router never \"goes back\".\n * When the user clicks on the back button in the browser,\n * a new navigation ID is created.\n *\n * Use the ID in this previous-state object to differentiate between a newly created\n * state and one returned to by a `popstate` event, so that you can restore some\n * remembered state, such as scroll position.\n *\n */\n restoredState;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n navigationTrigger = 'imperative', /** @docsNotRequired */\n restoredState = null) {\n super(id, url);\n this.navigationTrigger = navigationTrigger;\n this.restoredState = restoredState;\n }\n /** @docsNotRequired */\n toString() {\n return `NavigationStart(id: ${this.id}, url: '${this.url}')`;\n }\n}\n/**\n * An event triggered when a navigation ends successfully.\n *\n * @see {@link NavigationStart}\n * @see {@link NavigationCancel}\n * @see {@link NavigationError}\n *\n * @publicApi\n */\nclass NavigationEnd extends RouterEvent {\n urlAfterRedirects;\n type = EventType.NavigationEnd;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n urlAfterRedirects) {\n super(id, url);\n this.urlAfterRedirects = urlAfterRedirects;\n }\n /** @docsNotRequired */\n toString() {\n return `NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`;\n }\n}\n/**\n * A code for the `NavigationCancel` event of the `Router` to indicate the\n * reason a navigation failed.\n *\n * @publicApi\n */\nvar NavigationCancellationCode;\n(function (NavigationCancellationCode) {\n /**\n * A navigation failed because a guard returned a `UrlTree` to redirect.\n */\n NavigationCancellationCode[NavigationCancellationCode[\"Redirect\"] = 0] = \"Redirect\";\n /**\n * A navigation failed because a more recent navigation started.\n */\n NavigationCancellationCode[NavigationCancellationCode[\"SupersededByNewNavigation\"] = 1] = \"SupersededByNewNavigation\";\n /**\n * A navigation failed because one of the resolvers completed without emitting a value.\n */\n NavigationCancellationCode[NavigationCancellationCode[\"NoDataFromResolver\"] = 2] = \"NoDataFromResolver\";\n /**\n * A navigation failed because a guard returned `false`.\n */\n NavigationCancellationCode[NavigationCancellationCode[\"GuardRejected\"] = 3] = \"GuardRejected\";\n})(NavigationCancellationCode || (NavigationCancellationCode = {}));\n/**\n * A code for the `NavigationSkipped` event of the `Router` to indicate the\n * reason a navigation was skipped.\n *\n * @publicApi\n */\nvar NavigationSkippedCode;\n(function (NavigationSkippedCode) {\n /**\n * A navigation was skipped because the navigation URL was the same as the current Router URL.\n */\n NavigationSkippedCode[NavigationSkippedCode[\"IgnoredSameUrlNavigation\"] = 0] = \"IgnoredSameUrlNavigation\";\n /**\n * A navigation was skipped because the configured `UrlHandlingStrategy` return `false` for both\n * the current Router URL and the target of the navigation.\n *\n * @see {@link UrlHandlingStrategy}\n */\n NavigationSkippedCode[NavigationSkippedCode[\"IgnoredByUrlHandlingStrategy\"] = 1] = \"IgnoredByUrlHandlingStrategy\";\n})(NavigationSkippedCode || (NavigationSkippedCode = {}));\n/**\n * An event triggered when a navigation is canceled, directly or indirectly.\n * This can happen for several reasons including when a route guard\n * returns `false` or initiates a redirect by returning a `UrlTree`.\n *\n * @see {@link NavigationStart}\n * @see {@link NavigationEnd}\n * @see {@link NavigationError}\n *\n * @publicApi\n */\nclass NavigationCancel extends RouterEvent {\n reason;\n code;\n type = EventType.NavigationCancel;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url,\n /**\n * A description of why the navigation was cancelled. For debug purposes only. Use `code`\n * instead for a stable cancellation reason that can be used in production.\n */\n reason,\n /**\n * A code to indicate why the navigation was canceled. This cancellation code is stable for\n * the reason and can be relied on whereas the `reason` string could change and should not be\n * used in production.\n */\n code) {\n super(id, url);\n this.reason = reason;\n this.code = code;\n }\n /** @docsNotRequired */\n toString() {\n return `NavigationCancel(id: ${this.id}, url: '${this.url}')`;\n }\n}\n/**\n * An event triggered when a navigation is skipped.\n * This can happen for a couple reasons including onSameUrlHandling\n * is set to `ignore` and the navigation URL is not different than the\n * current state.\n *\n * @publicApi\n */\nclass NavigationSkipped extends RouterEvent {\n reason;\n code;\n type = EventType.NavigationSkipped;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url,\n /**\n * A description of why the navigation was skipped. For debug purposes only. Use `code`\n * instead for a stable skipped reason that can be used in production.\n */\n reason,\n /**\n * A code to indicate why the navigation was skipped. This code is stable for\n * the reason and can be relied on whereas the `reason` string could change and should not be\n * used in production.\n */\n code) {\n super(id, url);\n this.reason = reason;\n this.code = code;\n }\n}\n/**\n * An event triggered when a navigation fails due to an unexpected error.\n *\n * @see {@link NavigationStart}\n * @see {@link NavigationEnd}\n * @see {@link NavigationCancel}\n *\n * @publicApi\n */\nclass NavigationError extends RouterEvent {\n error;\n target;\n type = EventType.NavigationError;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n error,\n /**\n * The target of the navigation when the error occurred.\n *\n * Note that this can be `undefined` because an error could have occurred before the\n * `RouterStateSnapshot` was created for the navigation.\n */\n target) {\n super(id, url);\n this.error = error;\n this.target = target;\n }\n /** @docsNotRequired */\n toString() {\n return `NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`;\n }\n}\n/**\n * An event triggered when routes are recognized.\n *\n * @publicApi\n */\nclass RoutesRecognized extends RouterEvent {\n urlAfterRedirects;\n state;\n type = EventType.RoutesRecognized;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n urlAfterRedirects, /** @docsNotRequired */\n state) {\n super(id, url);\n this.urlAfterRedirects = urlAfterRedirects;\n this.state = state;\n }\n /** @docsNotRequired */\n toString() {\n return `RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`;\n }\n}\n/**\n * An event triggered at the start of the Guard phase of routing.\n *\n * @see {@link GuardsCheckEnd}\n *\n * @publicApi\n */\nclass GuardsCheckStart extends RouterEvent {\n urlAfterRedirects;\n state;\n type = EventType.GuardsCheckStart;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n urlAfterRedirects, /** @docsNotRequired */\n state) {\n super(id, url);\n this.urlAfterRedirects = urlAfterRedirects;\n this.state = state;\n }\n toString() {\n return `GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`;\n }\n}\n/**\n * An event triggered at the end of the Guard phase of routing.\n *\n * @see {@link GuardsCheckStart}\n *\n * @publicApi\n */\nclass GuardsCheckEnd extends RouterEvent {\n urlAfterRedirects;\n state;\n shouldActivate;\n type = EventType.GuardsCheckEnd;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n urlAfterRedirects, /** @docsNotRequired */\n state, /** @docsNotRequired */\n shouldActivate) {\n super(id, url);\n this.urlAfterRedirects = urlAfterRedirects;\n this.state = state;\n this.shouldActivate = shouldActivate;\n }\n toString() {\n return `GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`;\n }\n}\n/**\n * An event triggered at the start of the Resolve phase of routing.\n *\n * Runs in the \"resolve\" phase whether or not there is anything to resolve.\n * In future, may change to only run when there are things to be resolved.\n *\n * @see {@link ResolveEnd}\n *\n * @publicApi\n */\nclass ResolveStart extends RouterEvent {\n urlAfterRedirects;\n state;\n type = EventType.ResolveStart;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n urlAfterRedirects, /** @docsNotRequired */\n state) {\n super(id, url);\n this.urlAfterRedirects = urlAfterRedirects;\n this.state = state;\n }\n toString() {\n return `ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`;\n }\n}\n/**\n * An event triggered at the end of the Resolve phase of routing.\n * @see {@link ResolveStart}\n *\n * @publicApi\n */\nclass ResolveEnd extends RouterEvent {\n urlAfterRedirects;\n state;\n type = EventType.ResolveEnd;\n constructor(/** @docsNotRequired */\n id, /** @docsNotRequired */\n url, /** @docsNotRequired */\n urlAfterRedirects, /** @docsNotRequired */\n state) {\n super(id, url);\n this.urlAfterRedirects = urlAfterRedirects;\n this.state = state;\n }\n toString() {\n return `ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`;\n }\n}\n/**\n * An event triggered before lazy loading a route configuration.\n *\n * @see {@link RouteConfigLoadEnd}\n *\n * @publicApi\n */\nclass RouteConfigLoadStart {\n route;\n type = EventType.RouteConfigLoadStart;\n constructor(/** @docsNotRequired */\n route) {\n this.route = route;\n }\n toString() {\n return `RouteConfigLoadStart(path: ${this.route.path})`;\n }\n}\n/**\n * An event triggered when a route has been lazy loaded.\n *\n * @see {@link RouteConfigLoadStart}\n *\n * @publicApi\n */\nclass RouteConfigLoadEnd {\n route;\n type = EventType.RouteConfigLoadEnd;\n constructor(/** @docsNotRequired */\n route) {\n this.route = route;\n }\n toString() {\n return `RouteConfigLoadEnd(path: ${this.route.path})`;\n }\n}\n/**\n * An event triggered at the start of the child-activation\n * part of the Resolve phase of routing.\n * @see {@link ChildActivationEnd}\n * @see {@link ResolveStart}\n *\n * @publicApi\n */\nclass ChildActivationStart {\n snapshot;\n type = EventType.ChildActivationStart;\n constructor(/** @docsNotRequired */\n snapshot) {\n this.snapshot = snapshot;\n }\n toString() {\n const path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';\n return `ChildActivationStart(path: '${path}')`;\n }\n}\n/**\n * An event triggered at the end of the child-activation part\n * of the Resolve phase of routing.\n * @see {@link ChildActivationStart}\n * @see {@link ResolveStart}\n * @publicApi\n */\nclass ChildActivationEnd {\n snapshot;\n type = EventType.ChildActivationEnd;\n constructor(/** @docsNotRequired */\n snapshot) {\n this.snapshot = snapshot;\n }\n toString() {\n const path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';\n return `ChildActivationEnd(path: '${path}')`;\n }\n}\n/**\n * An event triggered at the start of the activation part\n * of the Resolve phase of routing.\n * @see {@link ActivationEnd}\n * @see {@link ResolveStart}\n *\n * @publicApi\n */\nclass ActivationStart {\n snapshot;\n type = EventType.ActivationStart;\n constructor(/** @docsNotRequired */\n snapshot) {\n this.snapshot = snapshot;\n }\n toString() {\n const path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';\n return `ActivationStart(path: '${path}')`;\n }\n}\n/**\n * An event triggered at the end of the activation part\n * of the Resolve phase of routing.\n * @see {@link ActivationStart}\n * @see {@link ResolveStart}\n *\n * @publicApi\n */\nclass ActivationEnd {\n snapshot;\n type = EventType.ActivationEnd;\n constructor(/** @docsNotRequired */\n snapshot) {\n this.snapshot = snapshot;\n }\n toString() {\n const path = this.snapshot.routeConfig && this.snapshot.routeConfig.path || '';\n return `ActivationEnd(path: '${path}')`;\n }\n}\n/**\n * An event triggered by scrolling.\n *\n * @publicApi\n */\nclass Scroll {\n routerEvent;\n position;\n anchor;\n type = EventType.Scroll;\n constructor(/** @docsNotRequired */\n routerEvent, /** @docsNotRequired */\n position, /** @docsNotRequired */\n anchor) {\n this.routerEvent = routerEvent;\n this.position = position;\n this.anchor = anchor;\n }\n toString() {\n const pos = this.position ? `${this.position[0]}, ${this.position[1]}` : null;\n return `Scroll(anchor: '${this.anchor}', position: '${pos}')`;\n }\n}\nclass BeforeActivateRoutes {}\nclass RedirectRequest {\n url;\n navigationBehaviorOptions;\n constructor(url, navigationBehaviorOptions) {\n this.url = url;\n this.navigationBehaviorOptions = navigationBehaviorOptions;\n }\n}\nfunction stringifyEvent(routerEvent) {\n switch (routerEvent.type) {\n case EventType.ActivationEnd:\n return `ActivationEnd(path: '${routerEvent.snapshot.routeConfig?.path || ''}')`;\n case EventType.ActivationStart:\n return `ActivationStart(path: '${routerEvent.snapshot.routeConfig?.path || ''}')`;\n case EventType.ChildActivationEnd:\n return `ChildActivationEnd(path: '${routerEvent.snapshot.routeConfig?.path || ''}')`;\n case EventType.ChildActivationStart:\n return `ChildActivationStart(path: '${routerEvent.snapshot.routeConfig?.path || ''}')`;\n case EventType.GuardsCheckEnd:\n return `GuardsCheckEnd(id: ${routerEvent.id}, url: '${routerEvent.url}', urlAfterRedirects: '${routerEvent.urlAfterRedirects}', state: ${routerEvent.state}, shouldActivate: ${routerEvent.shouldActivate})`;\n case EventType.GuardsCheckStart:\n return `GuardsCheckStart(id: ${routerEvent.id}, url: '${routerEvent.url}', urlAfterRedirects: '${routerEvent.urlAfterRedirects}', state: ${routerEvent.state})`;\n case EventType.NavigationCancel:\n return `NavigationCancel(id: ${routerEvent.id}, url: '${routerEvent.url}')`;\n case EventType.NavigationSkipped:\n return `NavigationSkipped(id: ${routerEvent.id}, url: '${routerEvent.url}')`;\n case EventType.NavigationEnd:\n return `NavigationEnd(id: ${routerEvent.id}, url: '${routerEvent.url}', urlAfterRedirects: '${routerEvent.urlAfterRedirects}')`;\n case EventType.NavigationError:\n return `NavigationError(id: ${routerEvent.id}, url: '${routerEvent.url}', error: ${routerEvent.error})`;\n case EventType.NavigationStart:\n return `NavigationStart(id: ${routerEvent.id}, url: '${routerEvent.url}')`;\n case EventType.ResolveEnd:\n return `ResolveEnd(id: ${routerEvent.id}, url: '${routerEvent.url}', urlAfterRedirects: '${routerEvent.urlAfterRedirects}', state: ${routerEvent.state})`;\n case EventType.ResolveStart:\n return `ResolveStart(id: ${routerEvent.id}, url: '${routerEvent.url}', urlAfterRedirects: '${routerEvent.urlAfterRedirects}', state: ${routerEvent.state})`;\n case EventType.RouteConfigLoadEnd:\n return `RouteConfigLoadEnd(path: ${routerEvent.route.path})`;\n case EventType.RouteConfigLoadStart:\n return `RouteConfigLoadStart(path: ${routerEvent.route.path})`;\n case EventType.RoutesRecognized:\n return `RoutesRecognized(id: ${routerEvent.id}, url: '${routerEvent.url}', urlAfterRedirects: '${routerEvent.urlAfterRedirects}', state: ${routerEvent.state})`;\n case EventType.Scroll:\n const pos = routerEvent.position ? `${routerEvent.position[0]}, ${routerEvent.position[1]}` : null;\n return `Scroll(anchor: '${routerEvent.anchor}', position: '${pos}')`;\n }\n}\n\n/**\n * Creates an `EnvironmentInjector` if the `Route` has providers and one does not already exist\n * and returns the injector. Otherwise, if the `Route` does not have `providers`, returns the\n * `currentInjector`.\n *\n * @param route The route that might have providers\n * @param currentInjector The parent injector of the `Route`\n */\nfunction getOrCreateRouteInjectorIfNeeded(route, currentInjector) {\n if (route.providers && !route._injector) {\n route._injector = createEnvironmentInjector(route.providers, currentInjector, `Route: ${route.path}`);\n }\n return route._injector ?? currentInjector;\n}\nfunction getLoadedRoutes$1(route) {\n return route._loadedRoutes;\n}\nfunction getLoadedInjector(route) {\n return route._loadedInjector;\n}\nfunction getLoadedComponent(route) {\n return route._loadedComponent;\n}\nfunction getProvidersInjector(route) {\n return route._injector;\n}\nfunction validateConfig(config, parentPath = '', requireStandaloneComponents = false) {\n // forEach doesn't iterate undefined values\n for (let i = 0; i < config.length; i++) {\n const route = config[i];\n const fullPath = getFullPath(parentPath, route);\n validateNode(route, fullPath, requireStandaloneComponents);\n }\n}\nfunction assertStandalone(fullPath, component) {\n if (component && ɵisNgModule(component)) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}'. You are using 'loadComponent' with a module, ` + `but it must be used with standalone components. Use 'loadChildren' instead.`);\n } else if (component && !isStandalone(component)) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}'. The component must be standalone.`);\n }\n}\nfunction validateNode(route, fullPath, requireStandaloneComponents) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (!route) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `\n Invalid configuration of route '${fullPath}': Encountered undefined route.\n The reason might be an extra comma.\n\n Example:\n const routes: Routes = [\n { path: '', redirectTo: '/dashboard', pathMatch: 'full' },\n { path: 'dashboard', component: DashboardComponent },, << two commas\n { path: 'detail/:id', component: HeroDetailComponent }\n ];\n `);\n }\n if (Array.isArray(route)) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': Array cannot be specified`);\n }\n if (!route.redirectTo && !route.component && !route.loadComponent && !route.children && !route.loadChildren && route.outlet && route.outlet !== PRIMARY_OUTLET) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': a componentless route without children or loadChildren cannot have a named outlet set`);\n }\n if (route.redirectTo && route.children) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': redirectTo and children cannot be used together`);\n }\n if (route.redirectTo && route.loadChildren) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': redirectTo and loadChildren cannot be used together`);\n }\n if (route.children && route.loadChildren) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': children and loadChildren cannot be used together`);\n }\n if (route.redirectTo && (route.component || route.loadComponent)) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': redirectTo and component/loadComponent cannot be used together`);\n }\n if (route.component && route.loadComponent) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': component and loadComponent cannot be used together`);\n }\n if (route.redirectTo && route.canActivate) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': redirectTo and canActivate cannot be used together. Redirects happen before activation ` + `so canActivate will never be executed.`);\n }\n if (route.path && route.matcher) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': path and matcher cannot be used together`);\n }\n if (route.redirectTo === void 0 && !route.component && !route.loadComponent && !route.children && !route.loadChildren) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}'. One of the following must be provided: component, loadComponent, redirectTo, children or loadChildren`);\n }\n if (route.path === void 0 && route.matcher === void 0) {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': routes must have either a path or a matcher specified`);\n }\n if (typeof route.path === 'string' && route.path.charAt(0) === '/') {\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '${fullPath}': path cannot start with a slash`);\n }\n if (route.path === '' && route.redirectTo !== void 0 && route.pathMatch === void 0) {\n const exp = `The default value of 'pathMatch' is 'prefix', but often the intent is to use 'full'.`;\n throw new ɵRuntimeError(4014 /* RuntimeErrorCode.INVALID_ROUTE_CONFIG */, `Invalid configuration of route '{path: \"${fullPath}\", redirectTo: \"${route.redirectTo}\"}': please provide 'pathMatch'. ${exp}`);\n }\n if (requireStandaloneComponents) {\n assertStandalone(fullPath, route.component);\n }\n }\n if (route.children) {\n validateConfig(route.children, fullPath, requireStandaloneComponents);\n }\n}\nfunction getFullPath(parentPath, currentRoute) {\n if (!currentRoute) {\n return parentPath;\n }\n if (!parentPath && !currentRoute.path) {\n return '';\n } else if (parentPath && !currentRoute.path) {\n return `${parentPath}/`;\n } else if (!parentPath && currentRoute.path) {\n return currentRoute.path;\n } else {\n return `${parentPath}/${currentRoute.path}`;\n }\n}\n/** Returns the `route.outlet` or PRIMARY_OUTLET if none exists. */\nfunction getOutlet(route) {\n return route.outlet || PRIMARY_OUTLET;\n}\n/**\n * Sorts the `routes` such that the ones with an outlet matching `outletName` come first.\n * The order of the configs is otherwise preserved.\n */\nfunction sortByMatchingOutlets(routes, outletName) {\n const sortedConfig = routes.filter(r => getOutlet(r) === outletName);\n sortedConfig.push(...routes.filter(r => getOutlet(r) !== outletName));\n return sortedConfig;\n}\n/**\n * Gets the first injector in the snapshot's parent tree.\n *\n * If the `Route` has a static list of providers, the returned injector will be the one created from\n * those. If it does not exist, the returned injector may come from the parents, which may be from a\n * loaded config or their static providers.\n *\n * Returns `null` if there is neither this nor any parents have a stored injector.\n *\n * Generally used for retrieving the injector to use for getting tokens for guards/resolvers and\n * also used for getting the correct injector to use for creating components.\n */\nfunction getClosestRouteInjector(snapshot) {\n if (!snapshot) return null;\n // If the current route has its own injector, which is created from the static providers on the\n // route itself, we should use that. Otherwise, we start at the parent since we do not want to\n // include the lazy loaded injector from this route.\n if (snapshot.routeConfig?._injector) {\n return snapshot.routeConfig._injector;\n }\n for (let s = snapshot.parent; s; s = s.parent) {\n const route = s.routeConfig;\n // Note that the order here is important. `_loadedInjector` stored on the route with\n // `loadChildren: () => NgModule` so it applies to child routes with priority. The `_injector`\n // is created from the static providers on that parent route, so it applies to the children as\n // well, but only if there is no lazy loaded NgModuleRef injector.\n if (route?._loadedInjector) return route._loadedInjector;\n if (route?._injector) return route._injector;\n }\n return null;\n}\n\n/**\n * Store contextual information about a `RouterOutlet`\n *\n * @publicApi\n */\nclass OutletContext {\n rootInjector;\n outlet = null;\n route = null;\n children;\n attachRef = null;\n get injector() {\n return getClosestRouteInjector(this.route?.snapshot) ?? this.rootInjector;\n }\n constructor(rootInjector) {\n this.rootInjector = rootInjector;\n this.children = new ChildrenOutletContexts(this.rootInjector);\n }\n}\n/**\n * Store contextual information about the children (= nested) `RouterOutlet`\n *\n * @publicApi\n */\nclass ChildrenOutletContexts {\n rootInjector;\n // contexts for child outlets, by name.\n contexts = new Map();\n /** @nodoc */\n constructor(rootInjector) {\n this.rootInjector = rootInjector;\n }\n /** Called when a `RouterOutlet` directive is instantiated */\n onChildOutletCreated(childName, outlet) {\n const context = this.getOrCreateContext(childName);\n context.outlet = outlet;\n this.contexts.set(childName, context);\n }\n /**\n * Called when a `RouterOutlet` directive is destroyed.\n * We need to keep the context as the outlet could be destroyed inside a NgIf and might be\n * re-created later.\n */\n onChildOutletDestroyed(childName) {\n const context = this.getContext(childName);\n if (context) {\n context.outlet = null;\n context.attachRef = null;\n }\n }\n /**\n * Called when the corresponding route is deactivated during navigation.\n * Because the component get destroyed, all children outlet are destroyed.\n */\n onOutletDeactivated() {\n const contexts = this.contexts;\n this.contexts = new Map();\n return contexts;\n }\n onOutletReAttached(contexts) {\n this.contexts = contexts;\n }\n getOrCreateContext(childName) {\n let context = this.getContext(childName);\n if (!context) {\n context = new OutletContext(this.rootInjector);\n this.contexts.set(childName, context);\n }\n return context;\n }\n getContext(childName) {\n return this.contexts.get(childName) || null;\n }\n static ɵfac = function ChildrenOutletContexts_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ChildrenOutletContexts)(i0.ɵɵinject(i0.EnvironmentInjector));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: ChildrenOutletContexts,\n factory: ChildrenOutletContexts.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(ChildrenOutletContexts, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [{\n type: i0.EnvironmentInjector\n }], null);\n})();\nclass Tree {\n /** @internal */\n _root;\n constructor(root) {\n this._root = root;\n }\n get root() {\n return this._root.value;\n }\n /**\n * @internal\n */\n parent(t) {\n const p = this.pathFromRoot(t);\n return p.length > 1 ? p[p.length - 2] : null;\n }\n /**\n * @internal\n */\n children(t) {\n const n = findNode(t, this._root);\n return n ? n.children.map(t => t.value) : [];\n }\n /**\n * @internal\n */\n firstChild(t) {\n const n = findNode(t, this._root);\n return n && n.children.length > 0 ? n.children[0].value : null;\n }\n /**\n * @internal\n */\n siblings(t) {\n const p = findPath(t, this._root);\n if (p.length < 2) return [];\n const c = p[p.length - 2].children.map(c => c.value);\n return c.filter(cc => cc !== t);\n }\n /**\n * @internal\n */\n pathFromRoot(t) {\n return findPath(t, this._root).map(s => s.value);\n }\n}\n// DFS for the node matching the value\nfunction findNode(value, node) {\n if (value === node.value) return node;\n for (const child of node.children) {\n const node = findNode(value, child);\n if (node) return node;\n }\n return null;\n}\n// Return the path to the node with the given value using DFS\nfunction findPath(value, node) {\n if (value === node.value) return [node];\n for (const child of node.children) {\n const path = findPath(value, child);\n if (path.length) {\n path.unshift(node);\n return path;\n }\n }\n return [];\n}\nclass TreeNode {\n value;\n children;\n constructor(value, children) {\n this.value = value;\n this.children = children;\n }\n toString() {\n return `TreeNode(${this.value})`;\n }\n}\n// Return the list of T indexed by outlet name\nfunction nodeChildrenAsMap(node) {\n const map = {};\n if (node) {\n node.children.forEach(child => map[child.value.outlet] = child);\n }\n return map;\n}\n\n/**\n * Represents the state of the router as a tree of activated routes.\n *\n * @usageNotes\n *\n * Every node in the route tree is an `ActivatedRoute` instance\n * that knows about the \"consumed\" URL segments, the extracted parameters,\n * and the resolved data.\n * Use the `ActivatedRoute` properties to traverse the tree from any node.\n *\n * The following fragment shows how a component gets the root node\n * of the current state to establish its own route tree:\n *\n * ```ts\n * @Component({templateUrl:'template.html'})\n * class MyComponent {\n * constructor(router: Router) {\n * const state: RouterState = router.routerState;\n * const root: ActivatedRoute = state.root;\n * const child = root.firstChild;\n * const id: Observable<string> = child.params.map(p => p.id);\n * //...\n * }\n * }\n * ```\n *\n * @see {@link ActivatedRoute}\n * @see [Getting route information](guide/routing/common-router-tasks#getting-route-information)\n *\n * @publicApi\n */\nclass RouterState extends Tree {\n snapshot;\n /** @internal */\n constructor(root, /** The current snapshot of the router state */\n snapshot) {\n super(root);\n this.snapshot = snapshot;\n setRouterState(this, root);\n }\n toString() {\n return this.snapshot.toString();\n }\n}\nfunction createEmptyState(rootComponent) {\n const snapshot = createEmptyStateSnapshot(rootComponent);\n const emptyUrl = new BehaviorSubject([new UrlSegment('', {})]);\n const emptyParams = new BehaviorSubject({});\n const emptyData = new BehaviorSubject({});\n const emptyQueryParams = new BehaviorSubject({});\n const fragment = new BehaviorSubject('');\n const activated = new ActivatedRoute(emptyUrl, emptyParams, emptyQueryParams, fragment, emptyData, PRIMARY_OUTLET, rootComponent, snapshot.root);\n activated.snapshot = snapshot.root;\n return new RouterState(new TreeNode(activated, []), snapshot);\n}\nfunction createEmptyStateSnapshot(rootComponent) {\n const emptyParams = {};\n const emptyData = {};\n const emptyQueryParams = {};\n const fragment = '';\n const activated = new ActivatedRouteSnapshot([], emptyParams, emptyQueryParams, fragment, emptyData, PRIMARY_OUTLET, rootComponent, null, {});\n return new RouterStateSnapshot('', new TreeNode(activated, []));\n}\n/**\n * Provides access to information about a route associated with a component\n * that is loaded in an outlet.\n * Use to traverse the `RouterState` tree and extract information from nodes.\n *\n * The following example shows how to construct a component using information from a\n * currently activated route.\n *\n * Note: the observables in this class only emit when the current and previous values differ based\n * on shallow equality. For example, changing deeply nested properties in resolved `data` will not\n * cause the `ActivatedRoute.data` `Observable` to emit a new value.\n *\n * {@example router/activated-route/module.ts region=\"activated-route\"\n * header=\"activated-route.component.ts\"}\n *\n * @see [Getting route information](guide/routing/common-router-tasks#getting-route-information)\n *\n * @publicApi\n */\nclass ActivatedRoute {\n urlSubject;\n paramsSubject;\n queryParamsSubject;\n fragmentSubject;\n dataSubject;\n outlet;\n component;\n /** The current snapshot of this route */\n snapshot;\n /** @internal */\n _futureSnapshot;\n /** @internal */\n _routerState;\n /** @internal */\n _paramMap;\n /** @internal */\n _queryParamMap;\n /** An Observable of the resolved route title */\n title;\n /** An observable of the URL segments matched by this route. */\n url;\n /** An observable of the matrix parameters scoped to this route. */\n params;\n /** An observable of the query parameters shared by all the routes. */\n queryParams;\n /** An observable of the URL fragment shared by all the routes. */\n fragment;\n /** An observable of the static and resolved data of this route. */\n data;\n /** @internal */\n constructor(/** @internal */\n urlSubject, /** @internal */\n paramsSubject, /** @internal */\n queryParamsSubject, /** @internal */\n fragmentSubject, /** @internal */\n dataSubject, /** The outlet name of the route, a constant. */\n outlet, /** The component of the route, a constant. */\n component, futureSnapshot) {\n this.urlSubject = urlSubject;\n this.paramsSubject = paramsSubject;\n this.queryParamsSubject = queryParamsSubject;\n this.fragmentSubject = fragmentSubject;\n this.dataSubject = dataSubject;\n this.outlet = outlet;\n this.component = component;\n this._futureSnapshot = futureSnapshot;\n this.title = this.dataSubject?.pipe(map(d => d[RouteTitleKey])) ?? of(undefined);\n // TODO(atscott): Verify that these can be changed to `.asObservable()` with TGP.\n this.url = urlSubject;\n this.params = paramsSubject;\n this.queryParams = queryParamsSubject;\n this.fragment = fragmentSubject;\n this.data = dataSubject;\n }\n /** The configuration used to match this route. */\n get routeConfig() {\n return this._futureSnapshot.routeConfig;\n }\n /** The root of the router state. */\n get root() {\n return this._routerState.root;\n }\n /** The parent of this route in the router state tree. */\n get parent() {\n return this._routerState.parent(this);\n }\n /** The first child of this route in the router state tree. */\n get firstChild() {\n return this._routerState.firstChild(this);\n }\n /** The children of this route in the router state tree. */\n get children() {\n return this._routerState.children(this);\n }\n /** The path from the root of the router state tree to this route. */\n get pathFromRoot() {\n return this._routerState.pathFromRoot(this);\n }\n /**\n * An Observable that contains a map of the required and optional parameters\n * specific to the route.\n * The map supports retrieving single and multiple values from the same parameter.\n */\n get paramMap() {\n this._paramMap ??= this.params.pipe(map(p => convertToParamMap(p)));\n return this._paramMap;\n }\n /**\n * An Observable that contains a map of the query parameters available to all routes.\n * The map supports retrieving single and multiple values from the query parameter.\n */\n get queryParamMap() {\n this._queryParamMap ??= this.queryParams.pipe(map(p => convertToParamMap(p)));\n return this._queryParamMap;\n }\n toString() {\n return this.snapshot ? this.snapshot.toString() : `Future(${this._futureSnapshot})`;\n }\n}\n/**\n * Returns the inherited params, data, and resolve for a given route.\n *\n * By default, we do not inherit parent data unless the current route is path-less or the parent\n * route is component-less.\n */\nfunction getInherited(route, parent, paramsInheritanceStrategy = 'emptyOnly') {\n let inherited;\n const {\n routeConfig\n } = route;\n if (parent !== null && (paramsInheritanceStrategy === 'always' ||\n // inherit parent data if route is empty path\n routeConfig?.path === '' ||\n // inherit parent data if parent was componentless\n !parent.component && !parent.routeConfig?.loadComponent)) {\n inherited = {\n params: {\n ...parent.params,\n ...route.params\n },\n data: {\n ...parent.data,\n ...route.data\n },\n resolve: {\n // Snapshots are created with data inherited from parent and guards (i.e. canActivate) can\n // change data because it's not frozen...\n // This first line could be deleted chose to break/disallow mutating the `data` object in\n // guards.\n // Note that data from parents still override this mutated data so anyone relying on this\n // might be surprised that it doesn't work if parent data is inherited but otherwise does.\n ...route.data,\n // Ensure inherited resolved data overrides inherited static data\n ...parent.data,\n // static data from the current route overrides any inherited data\n ...routeConfig?.data,\n // resolved data from current route overrides everything\n ...route._resolvedData\n }\n };\n } else {\n inherited = {\n params: {\n ...route.params\n },\n data: {\n ...route.data\n },\n resolve: {\n ...route.data,\n ...(route._resolvedData ?? {})\n }\n };\n }\n if (routeConfig && hasStaticTitle(routeConfig)) {\n inherited.resolve[RouteTitleKey] = routeConfig.title;\n }\n return inherited;\n}\n/**\n * @description\n *\n * Contains the information about a route associated with a component loaded in an\n * outlet at a particular moment in time. ActivatedRouteSnapshot can also be used to\n * traverse the router state tree.\n *\n * The following example initializes a component with route information extracted\n * from the snapshot of the root node at the time of creation.\n *\n * ```ts\n * @Component({templateUrl:'./my-component.html'})\n * class MyComponent {\n * constructor(route: ActivatedRoute) {\n * const id: string = route.snapshot.params.id;\n * const url: string = route.snapshot.url.join('');\n * const user = route.snapshot.data.user;\n * }\n * }\n * ```\n *\n * @publicApi\n */\nclass ActivatedRouteSnapshot {\n url;\n params;\n queryParams;\n fragment;\n data;\n outlet;\n component;\n /** The configuration used to match this route **/\n routeConfig;\n /** @internal */\n _resolve;\n /** @internal */\n _resolvedData;\n /** @internal */\n _routerState;\n /** @internal */\n _paramMap;\n /** @internal */\n _queryParamMap;\n /** The resolved route title */\n get title() {\n // Note: This _must_ be a getter because the data is mutated in the resolvers. Title will not be\n // available at the time of class instantiation.\n return this.data?.[RouteTitleKey];\n }\n /** @internal */\n constructor(/** The URL segments matched by this route */\n url,\n /**\n * The matrix parameters scoped to this route.\n *\n * You can compute all params (or data) in the router state or to get params outside\n * of an activated component by traversing the `RouterState` tree as in the following\n * example:\n * ```ts\n * collectRouteParams(router: Router) {\n * let params = {};\n * let stack: ActivatedRouteSnapshot[] = [router.routerState.snapshot.root];\n * while (stack.length > 0) {\n * const route = stack.pop()!;\n * params = {...params, ...route.params};\n * stack.push(...route.children);\n * }\n * return params;\n * }\n * ```\n */\n params, /** The query parameters shared by all the routes */\n queryParams, /** The URL fragment shared by all the routes */\n fragment, /** The static and resolved data of this route */\n data, /** The outlet name of the route */\n outlet, /** The component of the route */\n component, routeConfig, resolve) {\n this.url = url;\n this.params = params;\n this.queryParams = queryParams;\n this.fragment = fragment;\n this.data = data;\n this.outlet = outlet;\n this.component = component;\n this.routeConfig = routeConfig;\n this._resolve = resolve;\n }\n /** The root of the router state */\n get root() {\n return this._routerState.root;\n }\n /** The parent of this route in the router state tree */\n get parent() {\n return this._routerState.parent(this);\n }\n /** The first child of this route in the router state tree */\n get firstChild() {\n return this._routerState.firstChild(this);\n }\n /** The children of this route in the router state tree */\n get children() {\n return this._routerState.children(this);\n }\n /** The path from the root of the router state tree to this route */\n get pathFromRoot() {\n return this._routerState.pathFromRoot(this);\n }\n get paramMap() {\n this._paramMap ??= convertToParamMap(this.params);\n return this._paramMap;\n }\n get queryParamMap() {\n this._queryParamMap ??= convertToParamMap(this.queryParams);\n return this._queryParamMap;\n }\n toString() {\n const url = this.url.map(segment => segment.toString()).join('/');\n const matched = this.routeConfig ? this.routeConfig.path : '';\n return `Route(url:'${url}', path:'${matched}')`;\n }\n}\n/**\n * @description\n *\n * Represents the state of the router at a moment in time.\n *\n * This is a tree of activated route snapshots. Every node in this tree knows about\n * the \"consumed\" URL segments, the extracted parameters, and the resolved data.\n *\n * The following example shows how a component is initialized with information\n * from the snapshot of the root node's state at the time of creation.\n *\n * ```ts\n * @Component({templateUrl:'template.html'})\n * class MyComponent {\n * constructor(router: Router) {\n * const state: RouterState = router.routerState;\n * const snapshot: RouterStateSnapshot = state.snapshot;\n * const root: ActivatedRouteSnapshot = snapshot.root;\n * const child = root.firstChild;\n * const id: Observable<string> = child.params.map(p => p.id);\n * //...\n * }\n * }\n * ```\n *\n * @publicApi\n */\nclass RouterStateSnapshot extends Tree {\n url;\n /** @internal */\n constructor(/** The url from which this snapshot was created */\n url, root) {\n super(root);\n this.url = url;\n setRouterState(this, root);\n }\n toString() {\n return serializeNode(this._root);\n }\n}\nfunction setRouterState(state, node) {\n node.value._routerState = state;\n node.children.forEach(c => setRouterState(state, c));\n}\nfunction serializeNode(node) {\n const c = node.children.length > 0 ? ` { ${node.children.map(serializeNode).join(', ')} } ` : '';\n return `${node.value}${c}`;\n}\n/**\n * The expectation is that the activate route is created with the right set of parameters.\n * So we push new values into the observables only when they are not the initial values.\n * And we detect that by checking if the snapshot field is set.\n */\nfunction advanceActivatedRoute(route) {\n if (route.snapshot) {\n const currentSnapshot = route.snapshot;\n const nextSnapshot = route._futureSnapshot;\n route.snapshot = nextSnapshot;\n if (!shallowEqual(currentSnapshot.queryParams, nextSnapshot.queryParams)) {\n route.queryParamsSubject.next(nextSnapshot.queryParams);\n }\n if (currentSnapshot.fragment !== nextSnapshot.fragment) {\n route.fragmentSubject.next(nextSnapshot.fragment);\n }\n if (!shallowEqual(currentSnapshot.params, nextSnapshot.params)) {\n route.paramsSubject.next(nextSnapshot.params);\n }\n if (!shallowEqualArrays(currentSnapshot.url, nextSnapshot.url)) {\n route.urlSubject.next(nextSnapshot.url);\n }\n if (!shallowEqual(currentSnapshot.data, nextSnapshot.data)) {\n route.dataSubject.next(nextSnapshot.data);\n }\n } else {\n route.snapshot = route._futureSnapshot;\n // this is for resolved data\n route.dataSubject.next(route._futureSnapshot.data);\n }\n}\nfunction equalParamsAndUrlSegments(a, b) {\n const equalUrlParams = shallowEqual(a.params, b.params) && equalSegments(a.url, b.url);\n const parentsMismatch = !a.parent !== !b.parent;\n return equalUrlParams && !parentsMismatch && (!a.parent || equalParamsAndUrlSegments(a.parent, b.parent));\n}\nfunction hasStaticTitle(config) {\n return typeof config.title === 'string' || config.title === null;\n}\n\n/**\n * An `InjectionToken` provided by the `RouterOutlet` and can be set using the `routerOutletData`\n * input.\n *\n * When unset, this value is `null` by default.\n *\n * @usageNotes\n *\n * To set the data from the template of the component with `router-outlet`:\n * ```html\n * <router-outlet [routerOutletData]=\"{name: 'Angular'}\" />\n * ```\n *\n * To read the data in the routed component:\n * ```ts\n * data = inject(ROUTER_OUTLET_DATA) as Signal<{name: string}>;\n * ```\n *\n * @publicApi\n */\nconst ROUTER_OUTLET_DATA = new InjectionToken(ngDevMode ? 'RouterOutlet data' : '');\n/**\n * @description\n *\n * Acts as a placeholder that Angular dynamically fills based on the current router state.\n *\n * Each outlet can have a unique name, determined by the optional `name` attribute.\n * The name cannot be set or changed dynamically. If not set, default value is \"primary\".\n *\n * ```html\n * <router-outlet></router-outlet>\n * <router-outlet name='left'></router-outlet>\n * <router-outlet name='right'></router-outlet>\n * ```\n *\n * Named outlets can be the targets of secondary routes.\n * The `Route` object for a secondary route has an `outlet` property to identify the target outlet:\n *\n * `{path: <base-path>, component: <component>, outlet: <target_outlet_name>}`\n *\n * Using named outlets and secondary routes, you can target multiple outlets in\n * the same `RouterLink` directive.\n *\n * The router keeps track of separate branches in a navigation tree for each named outlet and\n * generates a representation of that tree in the URL.\n * The URL for a secondary route uses the following syntax to specify both the primary and secondary\n * routes at the same time:\n *\n * `http://base-path/primary-route-path(outlet-name:route-path)`\n *\n * A router outlet emits an activate event when a new component is instantiated,\n * deactivate event when a component is destroyed.\n * An attached event emits when the `RouteReuseStrategy` instructs the outlet to reattach the\n * subtree, and the detached event emits when the `RouteReuseStrategy` instructs the outlet to\n * detach the subtree.\n *\n * ```html\n * <router-outlet\n * (activate)='onActivate($event)'\n * (deactivate)='onDeactivate($event)'\n * (attach)='onAttach($event)'\n * (detach)='onDetach($event)'></router-outlet>\n * ```\n *\n * @see {@link RouterLink}\n * @see {@link Route}\n * @ngModule RouterModule\n *\n * @publicApi\n */\nclass RouterOutlet {\n activated = null;\n /** @internal */\n get activatedComponentRef() {\n return this.activated;\n }\n _activatedRoute = null;\n /**\n * The name of the outlet\n *\n */\n name = PRIMARY_OUTLET;\n activateEvents = new EventEmitter();\n deactivateEvents = new EventEmitter();\n /**\n * Emits an attached component instance when the `RouteReuseStrategy` instructs to re-attach a\n * previously detached subtree.\n **/\n attachEvents = new EventEmitter();\n /**\n * Emits a detached component instance when the `RouteReuseStrategy` instructs to detach the\n * subtree.\n */\n detachEvents = new EventEmitter();\n /**\n * Data that will be provided to the child injector through the `ROUTER_OUTLET_DATA` token.\n *\n * When unset, the value of the token is `undefined` by default.\n */\n routerOutletData = input(undefined);\n parentContexts = inject(ChildrenOutletContexts);\n location = inject(ViewContainerRef);\n changeDetector = inject(ChangeDetectorRef);\n inputBinder = inject(INPUT_BINDER, {\n optional: true\n });\n /** @nodoc */\n supportsBindingToComponentInputs = true;\n /** @nodoc */\n ngOnChanges(changes) {\n if (changes['name']) {\n const {\n firstChange,\n previousValue\n } = changes['name'];\n if (firstChange) {\n // The first change is handled by ngOnInit. Because ngOnChanges doesn't get called when no\n // input is set at all, we need to centrally handle the first change there.\n return;\n }\n // unregister with the old name\n if (this.isTrackedInParentContexts(previousValue)) {\n this.deactivate();\n this.parentContexts.onChildOutletDestroyed(previousValue);\n }\n // register the new name\n this.initializeOutletWithName();\n }\n }\n /** @nodoc */\n ngOnDestroy() {\n // Ensure that the registered outlet is this one before removing it on the context.\n if (this.isTrackedInParentContexts(this.name)) {\n this.parentContexts.onChildOutletDestroyed(this.name);\n }\n this.inputBinder?.unsubscribeFromRouteData(this);\n }\n isTrackedInParentContexts(outletName) {\n return this.parentContexts.getContext(outletName)?.outlet === this;\n }\n /** @nodoc */\n ngOnInit() {\n this.initializeOutletWithName();\n }\n initializeOutletWithName() {\n this.parentContexts.onChildOutletCreated(this.name, this);\n if (this.activated) {\n return;\n }\n // If the outlet was not instantiated at the time the route got activated we need to populate\n // the outlet when it is initialized (ie inside a NgIf)\n const context = this.parentContexts.getContext(this.name);\n if (context?.route) {\n if (context.attachRef) {\n // `attachRef` is populated when there is an existing component to mount\n this.attach(context.attachRef, context.route);\n } else {\n // otherwise the component defined in the configuration is created\n this.activateWith(context.route, context.injector);\n }\n }\n }\n get isActivated() {\n return !!this.activated;\n }\n /**\n * @returns The currently activated component instance.\n * @throws An error if the outlet is not activated.\n */\n get component() {\n if (!this.activated) throw new ɵRuntimeError(4012 /* RuntimeErrorCode.OUTLET_NOT_ACTIVATED */, (typeof ngDevMode === 'undefined' || ngDevMode) && 'Outlet is not activated');\n return this.activated.instance;\n }\n get activatedRoute() {\n if (!this.activated) throw new ɵRuntimeError(4012 /* RuntimeErrorCode.OUTLET_NOT_ACTIVATED */, (typeof ngDevMode === 'undefined' || ngDevMode) && 'Outlet is not activated');\n return this._activatedRoute;\n }\n get activatedRouteData() {\n if (this._activatedRoute) {\n return this._activatedRoute.snapshot.data;\n }\n return {};\n }\n /**\n * Called when the `RouteReuseStrategy` instructs to detach the subtree\n */\n detach() {\n if (!this.activated) throw new ɵRuntimeError(4012 /* RuntimeErrorCode.OUTLET_NOT_ACTIVATED */, (typeof ngDevMode === 'undefined' || ngDevMode) && 'Outlet is not activated');\n this.location.detach();\n const cmp = this.activated;\n this.activated = null;\n this._activatedRoute = null;\n this.detachEvents.emit(cmp.instance);\n return cmp;\n }\n /**\n * Called when the `RouteReuseStrategy` instructs to re-attach a previously detached subtree\n */\n attach(ref, activatedRoute) {\n this.activated = ref;\n this._activatedRoute = activatedRoute;\n this.location.insert(ref.hostView);\n this.inputBinder?.bindActivatedRouteToOutletComponent(this);\n this.attachEvents.emit(ref.instance);\n }\n deactivate() {\n if (this.activated) {\n const c = this.component;\n this.activated.destroy();\n this.activated = null;\n this._activatedRoute = null;\n this.deactivateEvents.emit(c);\n }\n }\n activateWith(activatedRoute, environmentInjector) {\n if (this.isActivated) {\n throw new ɵRuntimeError(4013 /* RuntimeErrorCode.OUTLET_ALREADY_ACTIVATED */, (typeof ngDevMode === 'undefined' || ngDevMode) && 'Cannot activate an already activated outlet');\n }\n this._activatedRoute = activatedRoute;\n const location = this.location;\n const snapshot = activatedRoute.snapshot;\n const component = snapshot.component;\n const childContexts = this.parentContexts.getOrCreateContext(this.name).children;\n const injector = new OutletInjector(activatedRoute, childContexts, location.injector, this.routerOutletData);\n this.activated = location.createComponent(component, {\n index: location.length,\n injector,\n environmentInjector: environmentInjector\n });\n // Calling `markForCheck` to make sure we will run the change detection when the\n // `RouterOutlet` is inside a `ChangeDetectionStrategy.OnPush` component.\n this.changeDetector.markForCheck();\n this.inputBinder?.bindActivatedRouteToOutletComponent(this);\n this.activateEvents.emit(this.activated.instance);\n }\n static ɵfac = function RouterOutlet_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RouterOutlet)();\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: RouterOutlet,\n selectors: [[\"router-outlet\"]],\n inputs: {\n name: \"name\",\n routerOutletData: [1, \"routerOutletData\"]\n },\n outputs: {\n activateEvents: \"activate\",\n deactivateEvents: \"deactivate\",\n attachEvents: \"attach\",\n detachEvents: \"detach\"\n },\n exportAs: [\"outlet\"],\n features: [i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouterOutlet, [{\n type: Directive,\n args: [{\n selector: 'router-outlet',\n exportAs: 'outlet'\n }]\n }], null, {\n name: [{\n type: Input\n }],\n activateEvents: [{\n type: Output,\n args: ['activate']\n }],\n deactivateEvents: [{\n type: Output,\n args: ['deactivate']\n }],\n attachEvents: [{\n type: Output,\n args: ['attach']\n }],\n detachEvents: [{\n type: Output,\n args: ['detach']\n }]\n });\n})();\nclass OutletInjector {\n route;\n childContexts;\n parent;\n outletData;\n /**\n * This injector has a special handing for the `ActivatedRoute` and\n * `ChildrenOutletContexts` tokens: it returns corresponding values for those\n * tokens dynamically. This behavior is different from the regular injector logic,\n * when we initialize and store a value, which is later returned for all inject\n * requests.\n *\n * In some cases (e.g. when using `@defer`), this dynamic behavior requires special\n * handling. This function allows to identify an instance of the `OutletInjector` and\n * create an instance of it without referring to the class itself (so this logic can\n * be invoked from the `core` package). This helps to retain dynamic behavior for the\n * mentioned tokens.\n *\n * Note: it's a temporary solution and we should explore how to support this case better.\n */\n __ngOutletInjector(parentInjector) {\n return new OutletInjector(this.route, this.childContexts, parentInjector, this.outletData);\n }\n constructor(route, childContexts, parent, outletData) {\n this.route = route;\n this.childContexts = childContexts;\n this.parent = parent;\n this.outletData = outletData;\n }\n get(token, notFoundValue) {\n if (token === ActivatedRoute) {\n return this.route;\n }\n if (token === ChildrenOutletContexts) {\n return this.childContexts;\n }\n if (token === ROUTER_OUTLET_DATA) {\n return this.outletData;\n }\n return this.parent.get(token, notFoundValue);\n }\n}\nconst INPUT_BINDER = new InjectionToken('');\n/**\n * Injectable used as a tree-shakable provider for opting in to binding router data to component\n * inputs.\n *\n * The RouterOutlet registers itself with this service when an `ActivatedRoute` is attached or\n * activated. When this happens, the service subscribes to the `ActivatedRoute` observables (params,\n * queryParams, data) and sets the inputs of the component using `ComponentRef.setInput`.\n * Importantly, when an input does not have an item in the route data with a matching key, this\n * input is set to `undefined`. If it were not done this way, the previous information would be\n * retained if the data got removed from the route (i.e. if a query parameter is removed).\n *\n * The `RouterOutlet` should unregister itself when destroyed via `unsubscribeFromRouteData` so that\n * the subscriptions are cleaned up.\n */\nclass RoutedComponentInputBinder {\n outletDataSubscriptions = new Map();\n bindActivatedRouteToOutletComponent(outlet) {\n this.unsubscribeFromRouteData(outlet);\n this.subscribeToRouteData(outlet);\n }\n unsubscribeFromRouteData(outlet) {\n this.outletDataSubscriptions.get(outlet)?.unsubscribe();\n this.outletDataSubscriptions.delete(outlet);\n }\n subscribeToRouteData(outlet) {\n const {\n activatedRoute\n } = outlet;\n const dataSubscription = combineLatest([activatedRoute.queryParams, activatedRoute.params, activatedRoute.data]).pipe(switchMap(([queryParams, params, data], index) => {\n data = {\n ...queryParams,\n ...params,\n ...data\n };\n // Get the first result from the data subscription synchronously so it's available to\n // the component as soon as possible (and doesn't require a second change detection).\n if (index === 0) {\n return of(data);\n }\n // Promise.resolve is used to avoid synchronously writing the wrong data when\n // two of the Observables in the `combineLatest` stream emit one after\n // another.\n return Promise.resolve(data);\n })).subscribe(data => {\n // Outlet may have been deactivated or changed names to be associated with a different\n // route\n if (!outlet.isActivated || !outlet.activatedComponentRef || outlet.activatedRoute !== activatedRoute || activatedRoute.component === null) {\n this.unsubscribeFromRouteData(outlet);\n return;\n }\n const mirror = reflectComponentType(activatedRoute.component);\n if (!mirror) {\n this.unsubscribeFromRouteData(outlet);\n return;\n }\n for (const {\n templateName\n } of mirror.inputs) {\n outlet.activatedComponentRef.setInput(templateName, data[templateName]);\n }\n });\n this.outletDataSubscriptions.set(outlet, dataSubscription);\n }\n static ɵfac = function RoutedComponentInputBinder_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RoutedComponentInputBinder)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: RoutedComponentInputBinder,\n factory: RoutedComponentInputBinder.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RoutedComponentInputBinder, [{\n type: Injectable\n }], null, null);\n})();\nfunction createRouterState(routeReuseStrategy, curr, prevState) {\n const root = createNode(routeReuseStrategy, curr._root, prevState ? prevState._root : undefined);\n return new RouterState(root, curr);\n}\nfunction createNode(routeReuseStrategy, curr, prevState) {\n // reuse an activated route that is currently displayed on the screen\n if (prevState && routeReuseStrategy.shouldReuseRoute(curr.value, prevState.value.snapshot)) {\n const value = prevState.value;\n value._futureSnapshot = curr.value;\n const children = createOrReuseChildren(routeReuseStrategy, curr, prevState);\n return new TreeNode(value, children);\n } else {\n if (routeReuseStrategy.shouldAttach(curr.value)) {\n // retrieve an activated route that is used to be displayed, but is not currently displayed\n const detachedRouteHandle = routeReuseStrategy.retrieve(curr.value);\n if (detachedRouteHandle !== null) {\n const tree = detachedRouteHandle.route;\n tree.value._futureSnapshot = curr.value;\n tree.children = curr.children.map(c => createNode(routeReuseStrategy, c));\n return tree;\n }\n }\n const value = createActivatedRoute(curr.value);\n const children = curr.children.map(c => createNode(routeReuseStrategy, c));\n return new TreeNode(value, children);\n }\n}\nfunction createOrReuseChildren(routeReuseStrategy, curr, prevState) {\n return curr.children.map(child => {\n for (const p of prevState.children) {\n if (routeReuseStrategy.shouldReuseRoute(child.value, p.value.snapshot)) {\n return createNode(routeReuseStrategy, child, p);\n }\n }\n return createNode(routeReuseStrategy, child);\n });\n}\nfunction createActivatedRoute(c) {\n return new ActivatedRoute(new BehaviorSubject(c.url), new BehaviorSubject(c.params), new BehaviorSubject(c.queryParams), new BehaviorSubject(c.fragment), new BehaviorSubject(c.data), c.outlet, c.component, c);\n}\n\n/**\n * Can be returned by a `Router` guard to instruct the `Router` to redirect rather than continue\n * processing the path of the in-flight navigation. The `redirectTo` indicates _where_ the new\n * navigation should go to and the optional `navigationBehaviorOptions` can provide more information\n * about _how_ to perform the navigation.\n *\n * ```ts\n * const route: Route = {\n * path: \"user/:userId\",\n * component: User,\n * canActivate: [\n * () => {\n * const router = inject(Router);\n * const authService = inject(AuthenticationService);\n *\n * if (!authService.isLoggedIn()) {\n * const loginPath = router.parseUrl(\"/login\");\n * return new RedirectCommand(loginPath, {\n * skipLocationChange: \"true\",\n * });\n * }\n *\n * return true;\n * },\n * ],\n * };\n * ```\n * @see [Routing guide](guide/routing/common-router-tasks#preventing-unauthorized-access)\n *\n * @publicApi\n */\nclass RedirectCommand {\n redirectTo;\n navigationBehaviorOptions;\n constructor(redirectTo, navigationBehaviorOptions) {\n this.redirectTo = redirectTo;\n this.navigationBehaviorOptions = navigationBehaviorOptions;\n }\n}\nconst NAVIGATION_CANCELING_ERROR = 'ngNavigationCancelingError';\nfunction redirectingNavigationError(urlSerializer, redirect) {\n const {\n redirectTo,\n navigationBehaviorOptions\n } = isUrlTree(redirect) ? {\n redirectTo: redirect,\n navigationBehaviorOptions: undefined\n } : redirect;\n const error = navigationCancelingError(ngDevMode && `Redirecting to \"${urlSerializer.serialize(redirectTo)}\"`, NavigationCancellationCode.Redirect);\n error.url = redirectTo;\n error.navigationBehaviorOptions = navigationBehaviorOptions;\n return error;\n}\nfunction navigationCancelingError(message, code) {\n const error = new Error(`NavigationCancelingError: ${message || ''}`);\n error[NAVIGATION_CANCELING_ERROR] = true;\n error.cancellationCode = code;\n return error;\n}\nfunction isRedirectingNavigationCancelingError(error) {\n return isNavigationCancelingError(error) && isUrlTree(error.url);\n}\nfunction isNavigationCancelingError(error) {\n return !!error && error[NAVIGATION_CANCELING_ERROR];\n}\nlet warnedAboutUnsupportedInputBinding = false;\nconst activateRoutes = (rootContexts, routeReuseStrategy, forwardEvent, inputBindingEnabled) => map(t => {\n new ActivateRoutes(routeReuseStrategy, t.targetRouterState, t.currentRouterState, forwardEvent, inputBindingEnabled).activate(rootContexts);\n return t;\n});\nclass ActivateRoutes {\n routeReuseStrategy;\n futureState;\n currState;\n forwardEvent;\n inputBindingEnabled;\n constructor(routeReuseStrategy, futureState, currState, forwardEvent, inputBindingEnabled) {\n this.routeReuseStrategy = routeReuseStrategy;\n this.futureState = futureState;\n this.currState = currState;\n this.forwardEvent = forwardEvent;\n this.inputBindingEnabled = inputBindingEnabled;\n }\n activate(parentContexts) {\n const futureRoot = this.futureState._root;\n const currRoot = this.currState ? this.currState._root : null;\n this.deactivateChildRoutes(futureRoot, currRoot, parentContexts);\n advanceActivatedRoute(this.futureState.root);\n this.activateChildRoutes(futureRoot, currRoot, parentContexts);\n }\n // De-activate the child route that are not re-used for the future state\n deactivateChildRoutes(futureNode, currNode, contexts) {\n const children = nodeChildrenAsMap(currNode);\n // Recurse on the routes active in the future state to de-activate deeper children\n futureNode.children.forEach(futureChild => {\n const childOutletName = futureChild.value.outlet;\n this.deactivateRoutes(futureChild, children[childOutletName], contexts);\n delete children[childOutletName];\n });\n // De-activate the routes that will not be re-used\n Object.values(children).forEach(v => {\n this.deactivateRouteAndItsChildren(v, contexts);\n });\n }\n deactivateRoutes(futureNode, currNode, parentContext) {\n const future = futureNode.value;\n const curr = currNode ? currNode.value : null;\n if (future === curr) {\n // Reusing the node, check to see if the children need to be de-activated\n if (future.component) {\n // If we have a normal route, we need to go through an outlet.\n const context = parentContext.getContext(future.outlet);\n if (context) {\n this.deactivateChildRoutes(futureNode, currNode, context.children);\n }\n } else {\n // if we have a componentless route, we recurse but keep the same outlet map.\n this.deactivateChildRoutes(futureNode, currNode, parentContext);\n }\n } else {\n if (curr) {\n // Deactivate the current route which will not be re-used\n this.deactivateRouteAndItsChildren(currNode, parentContext);\n }\n }\n }\n deactivateRouteAndItsChildren(route, parentContexts) {\n // If there is no component, the Route is never attached to an outlet (because there is no\n // component to attach).\n if (route.value.component && this.routeReuseStrategy.shouldDetach(route.value.snapshot)) {\n this.detachAndStoreRouteSubtree(route, parentContexts);\n } else {\n this.deactivateRouteAndOutlet(route, parentContexts);\n }\n }\n detachAndStoreRouteSubtree(route, parentContexts) {\n const context = parentContexts.getContext(route.value.outlet);\n const contexts = context && route.value.component ? context.children : parentContexts;\n const children = nodeChildrenAsMap(route);\n for (const treeNode of Object.values(children)) {\n this.deactivateRouteAndItsChildren(treeNode, contexts);\n }\n if (context && context.outlet) {\n const componentRef = context.outlet.detach();\n const contexts = context.children.onOutletDeactivated();\n this.routeReuseStrategy.store(route.value.snapshot, {\n componentRef,\n route,\n contexts\n });\n }\n }\n deactivateRouteAndOutlet(route, parentContexts) {\n const context = parentContexts.getContext(route.value.outlet);\n // The context could be `null` if we are on a componentless route but there may still be\n // children that need deactivating.\n const contexts = context && route.value.component ? context.children : parentContexts;\n const children = nodeChildrenAsMap(route);\n for (const treeNode of Object.values(children)) {\n this.deactivateRouteAndItsChildren(treeNode, contexts);\n }\n if (context) {\n if (context.outlet) {\n // Destroy the component\n context.outlet.deactivate();\n // Destroy the contexts for all the outlets that were in the component\n context.children.onOutletDeactivated();\n }\n // Clear the information about the attached component on the context but keep the reference to\n // the outlet. Clear even if outlet was not yet activated to avoid activating later with old\n // info\n context.attachRef = null;\n context.route = null;\n }\n }\n activateChildRoutes(futureNode, currNode, contexts) {\n const children = nodeChildrenAsMap(currNode);\n futureNode.children.forEach(c => {\n this.activateRoutes(c, children[c.value.outlet], contexts);\n this.forwardEvent(new ActivationEnd(c.value.snapshot));\n });\n if (futureNode.children.length) {\n this.forwardEvent(new ChildActivationEnd(futureNode.value.snapshot));\n }\n }\n activateRoutes(futureNode, currNode, parentContexts) {\n const future = futureNode.value;\n const curr = currNode ? currNode.value : null;\n advanceActivatedRoute(future);\n // reusing the node\n if (future === curr) {\n if (future.component) {\n // If we have a normal route, we need to go through an outlet.\n const context = parentContexts.getOrCreateContext(future.outlet);\n this.activateChildRoutes(futureNode, currNode, context.children);\n } else {\n // if we have a componentless route, we recurse but keep the same outlet map.\n this.activateChildRoutes(futureNode, currNode, parentContexts);\n }\n } else {\n if (future.component) {\n // if we have a normal route, we need to place the component into the outlet and recurse.\n const context = parentContexts.getOrCreateContext(future.outlet);\n if (this.routeReuseStrategy.shouldAttach(future.snapshot)) {\n const stored = this.routeReuseStrategy.retrieve(future.snapshot);\n this.routeReuseStrategy.store(future.snapshot, null);\n context.children.onOutletReAttached(stored.contexts);\n context.attachRef = stored.componentRef;\n context.route = stored.route.value;\n if (context.outlet) {\n // Attach right away when the outlet has already been instantiated\n // Otherwise attach from `RouterOutlet.ngOnInit` when it is instantiated\n context.outlet.attach(stored.componentRef, stored.route.value);\n }\n advanceActivatedRoute(stored.route.value);\n this.activateChildRoutes(futureNode, null, context.children);\n } else {\n context.attachRef = null;\n context.route = future;\n if (context.outlet) {\n // Activate the outlet when it has already been instantiated\n // Otherwise it will get activated from its `ngOnInit` when instantiated\n context.outlet.activateWith(future, context.injector);\n }\n this.activateChildRoutes(futureNode, null, context.children);\n }\n } else {\n // if we have a componentless route, we recurse but keep the same outlet map.\n this.activateChildRoutes(futureNode, null, parentContexts);\n }\n }\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n const context = parentContexts.getOrCreateContext(future.outlet);\n const outlet = context.outlet;\n if (outlet && this.inputBindingEnabled && !outlet.supportsBindingToComponentInputs && !warnedAboutUnsupportedInputBinding) {\n console.warn(`'withComponentInputBinding' feature is enabled but ` + `this application is using an outlet that may not support binding to component inputs.`);\n warnedAboutUnsupportedInputBinding = true;\n }\n }\n }\n}\nclass CanActivate {\n path;\n route;\n constructor(path) {\n this.path = path;\n this.route = this.path[this.path.length - 1];\n }\n}\nclass CanDeactivate {\n component;\n route;\n constructor(component, route) {\n this.component = component;\n this.route = route;\n }\n}\nfunction getAllRouteGuards(future, curr, parentContexts) {\n const futureRoot = future._root;\n const currRoot = curr ? curr._root : null;\n return getChildRouteGuards(futureRoot, currRoot, parentContexts, [futureRoot.value]);\n}\nfunction getCanActivateChild(p) {\n const canActivateChild = p.routeConfig ? p.routeConfig.canActivateChild : null;\n if (!canActivateChild || canActivateChild.length === 0) return null;\n return {\n node: p,\n guards: canActivateChild\n };\n}\nfunction getTokenOrFunctionIdentity(tokenOrFunction, injector) {\n const NOT_FOUND = Symbol();\n const result = injector.get(tokenOrFunction, NOT_FOUND);\n if (result === NOT_FOUND) {\n if (typeof tokenOrFunction === 'function' && !ɵisInjectable(tokenOrFunction)) {\n // We think the token is just a function so return it as-is\n return tokenOrFunction;\n } else {\n // This will throw the not found error\n return injector.get(tokenOrFunction);\n }\n }\n return result;\n}\nfunction getChildRouteGuards(futureNode, currNode, contexts, futurePath, checks = {\n canDeactivateChecks: [],\n canActivateChecks: []\n}) {\n const prevChildren = nodeChildrenAsMap(currNode);\n // Process the children of the future route\n futureNode.children.forEach(c => {\n getRouteGuards(c, prevChildren[c.value.outlet], contexts, futurePath.concat([c.value]), checks);\n delete prevChildren[c.value.outlet];\n });\n // Process any children left from the current route (not active for the future route)\n Object.entries(prevChildren).forEach(([k, v]) => deactivateRouteAndItsChildren(v, contexts.getContext(k), checks));\n return checks;\n}\nfunction getRouteGuards(futureNode, currNode, parentContexts, futurePath, checks = {\n canDeactivateChecks: [],\n canActivateChecks: []\n}) {\n const future = futureNode.value;\n const curr = currNode ? currNode.value : null;\n const context = parentContexts ? parentContexts.getContext(futureNode.value.outlet) : null;\n // reusing the node\n if (curr && future.routeConfig === curr.routeConfig) {\n const shouldRun = shouldRunGuardsAndResolvers(curr, future, future.routeConfig.runGuardsAndResolvers);\n if (shouldRun) {\n checks.canActivateChecks.push(new CanActivate(futurePath));\n } else {\n // we need to set the data\n future.data = curr.data;\n future._resolvedData = curr._resolvedData;\n }\n // If we have a component, we need to go through an outlet.\n if (future.component) {\n getChildRouteGuards(futureNode, currNode, context ? context.children : null, futurePath, checks);\n // if we have a componentless route, we recurse but keep the same outlet map.\n } else {\n getChildRouteGuards(futureNode, currNode, parentContexts, futurePath, checks);\n }\n if (shouldRun && context && context.outlet && context.outlet.isActivated) {\n checks.canDeactivateChecks.push(new CanDeactivate(context.outlet.component, curr));\n }\n } else {\n if (curr) {\n deactivateRouteAndItsChildren(currNode, context, checks);\n }\n checks.canActivateChecks.push(new CanActivate(futurePath));\n // If we have a component, we need to go through an outlet.\n if (future.component) {\n getChildRouteGuards(futureNode, null, context ? context.children : null, futurePath, checks);\n // if we have a componentless route, we recurse but keep the same outlet map.\n } else {\n getChildRouteGuards(futureNode, null, parentContexts, futurePath, checks);\n }\n }\n return checks;\n}\nfunction shouldRunGuardsAndResolvers(curr, future, mode) {\n if (typeof mode === 'function') {\n return mode(curr, future);\n }\n switch (mode) {\n case 'pathParamsChange':\n return !equalPath(curr.url, future.url);\n case 'pathParamsOrQueryParamsChange':\n return !equalPath(curr.url, future.url) || !shallowEqual(curr.queryParams, future.queryParams);\n case 'always':\n return true;\n case 'paramsOrQueryParamsChange':\n return !equalParamsAndUrlSegments(curr, future) || !shallowEqual(curr.queryParams, future.queryParams);\n case 'paramsChange':\n default:\n return !equalParamsAndUrlSegments(curr, future);\n }\n}\nfunction deactivateRouteAndItsChildren(route, context, checks) {\n const children = nodeChildrenAsMap(route);\n const r = route.value;\n Object.entries(children).forEach(([childName, node]) => {\n if (!r.component) {\n deactivateRouteAndItsChildren(node, context, checks);\n } else if (context) {\n deactivateRouteAndItsChildren(node, context.children.getContext(childName), checks);\n } else {\n deactivateRouteAndItsChildren(node, null, checks);\n }\n });\n if (!r.component) {\n checks.canDeactivateChecks.push(new CanDeactivate(null, r));\n } else if (context && context.outlet && context.outlet.isActivated) {\n checks.canDeactivateChecks.push(new CanDeactivate(context.outlet.component, r));\n } else {\n checks.canDeactivateChecks.push(new CanDeactivate(null, r));\n }\n}\n\n/**\n * Simple function check, but generic so type inference will flow. Example:\n *\n * function product(a: number, b: number) {\n * return a * b;\n * }\n *\n * if (isFunction<product>(fn)) {\n * return fn(1, 2);\n * } else {\n * throw \"Must provide the `product` function\";\n * }\n */\nfunction isFunction(v) {\n return typeof v === 'function';\n}\nfunction isBoolean(v) {\n return typeof v === 'boolean';\n}\nfunction isCanLoad(guard) {\n return guard && isFunction(guard.canLoad);\n}\nfunction isCanActivate(guard) {\n return guard && isFunction(guard.canActivate);\n}\nfunction isCanActivateChild(guard) {\n return guard && isFunction(guard.canActivateChild);\n}\nfunction isCanDeactivate(guard) {\n return guard && isFunction(guard.canDeactivate);\n}\nfunction isCanMatch(guard) {\n return guard && isFunction(guard.canMatch);\n}\nfunction isEmptyError(e) {\n return e instanceof EmptyError || e?.name === 'EmptyError';\n}\nconst INITIAL_VALUE = /* @__PURE__ */Symbol('INITIAL_VALUE');\nfunction prioritizedGuardValue() {\n return switchMap(obs => {\n return combineLatest(obs.map(o => o.pipe(take(1), startWith(INITIAL_VALUE)))).pipe(map(results => {\n for (const result of results) {\n if (result === true) {\n // If result is true, check the next one\n continue;\n } else if (result === INITIAL_VALUE) {\n // If guard has not finished, we need to stop processing.\n return INITIAL_VALUE;\n } else if (result === false || isRedirect(result)) {\n // Result finished and was not true. Return the result.\n // Note that we only allow false/UrlTree/RedirectCommand. Other values are considered invalid and\n // ignored.\n return result;\n }\n }\n // Everything resolved to true. Return true.\n return true;\n }), filter(item => item !== INITIAL_VALUE), take(1));\n });\n}\nfunction isRedirect(val) {\n return isUrlTree(val) || val instanceof RedirectCommand;\n}\nfunction checkGuards(injector, forwardEvent) {\n return mergeMap(t => {\n const {\n targetSnapshot,\n currentSnapshot,\n guards: {\n canActivateChecks,\n canDeactivateChecks\n }\n } = t;\n if (canDeactivateChecks.length === 0 && canActivateChecks.length === 0) {\n return of({\n ...t,\n guardsResult: true\n });\n }\n return runCanDeactivateChecks(canDeactivateChecks, targetSnapshot, currentSnapshot, injector).pipe(mergeMap(canDeactivate => {\n return canDeactivate && isBoolean(canDeactivate) ? runCanActivateChecks(targetSnapshot, canActivateChecks, injector, forwardEvent) : of(canDeactivate);\n }), map(guardsResult => ({\n ...t,\n guardsResult\n })));\n });\n}\nfunction runCanDeactivateChecks(checks, futureRSS, currRSS, injector) {\n return from(checks).pipe(mergeMap(check => runCanDeactivate(check.component, check.route, currRSS, futureRSS, injector)), first(result => {\n return result !== true;\n }, true));\n}\nfunction runCanActivateChecks(futureSnapshot, checks, injector, forwardEvent) {\n return from(checks).pipe(concatMap(check => {\n return concat(fireChildActivationStart(check.route.parent, forwardEvent), fireActivationStart(check.route, forwardEvent), runCanActivateChild(futureSnapshot, check.path, injector), runCanActivate(futureSnapshot, check.route, injector));\n }), first(result => {\n return result !== true;\n }, true));\n}\n/**\n * This should fire off `ActivationStart` events for each route being activated at this\n * level.\n * In other words, if you're activating `a` and `b` below, `path` will contain the\n * `ActivatedRouteSnapshot`s for both and we will fire `ActivationStart` for both. Always\n * return\n * `true` so checks continue to run.\n */\nfunction fireActivationStart(snapshot, forwardEvent) {\n if (snapshot !== null && forwardEvent) {\n forwardEvent(new ActivationStart(snapshot));\n }\n return of(true);\n}\n/**\n * This should fire off `ChildActivationStart` events for each route being activated at this\n * level.\n * In other words, if you're activating `a` and `b` below, `path` will contain the\n * `ActivatedRouteSnapshot`s for both and we will fire `ChildActivationStart` for both. Always\n * return\n * `true` so checks continue to run.\n */\nfunction fireChildActivationStart(snapshot, forwardEvent) {\n if (snapshot !== null && forwardEvent) {\n forwardEvent(new ChildActivationStart(snapshot));\n }\n return of(true);\n}\nfunction runCanActivate(futureRSS, futureARS, injector) {\n const canActivate = futureARS.routeConfig ? futureARS.routeConfig.canActivate : null;\n if (!canActivate || canActivate.length === 0) return of(true);\n const canActivateObservables = canActivate.map(canActivate => {\n return defer(() => {\n const closestInjector = getClosestRouteInjector(futureARS) ?? injector;\n const guard = getTokenOrFunctionIdentity(canActivate, closestInjector);\n const guardVal = isCanActivate(guard) ? guard.canActivate(futureARS, futureRSS) : runInInjectionContext(closestInjector, () => guard(futureARS, futureRSS));\n return wrapIntoObservable(guardVal).pipe(first());\n });\n });\n return of(canActivateObservables).pipe(prioritizedGuardValue());\n}\nfunction runCanActivateChild(futureRSS, path, injector) {\n const futureARS = path[path.length - 1];\n const canActivateChildGuards = path.slice(0, path.length - 1).reverse().map(p => getCanActivateChild(p)).filter(_ => _ !== null);\n const canActivateChildGuardsMapped = canActivateChildGuards.map(d => {\n return defer(() => {\n const guardsMapped = d.guards.map(canActivateChild => {\n const closestInjector = getClosestRouteInjector(d.node) ?? injector;\n const guard = getTokenOrFunctionIdentity(canActivateChild, closestInjector);\n const guardVal = isCanActivateChild(guard) ? guard.canActivateChild(futureARS, futureRSS) : runInInjectionContext(closestInjector, () => guard(futureARS, futureRSS));\n return wrapIntoObservable(guardVal).pipe(first());\n });\n return of(guardsMapped).pipe(prioritizedGuardValue());\n });\n });\n return of(canActivateChildGuardsMapped).pipe(prioritizedGuardValue());\n}\nfunction runCanDeactivate(component, currARS, currRSS, futureRSS, injector) {\n const canDeactivate = currARS && currARS.routeConfig ? currARS.routeConfig.canDeactivate : null;\n if (!canDeactivate || canDeactivate.length === 0) return of(true);\n const canDeactivateObservables = canDeactivate.map(c => {\n const closestInjector = getClosestRouteInjector(currARS) ?? injector;\n const guard = getTokenOrFunctionIdentity(c, closestInjector);\n const guardVal = isCanDeactivate(guard) ? guard.canDeactivate(component, currARS, currRSS, futureRSS) : runInInjectionContext(closestInjector, () => guard(component, currARS, currRSS, futureRSS));\n return wrapIntoObservable(guardVal).pipe(first());\n });\n return of(canDeactivateObservables).pipe(prioritizedGuardValue());\n}\nfunction runCanLoadGuards(injector, route, segments, urlSerializer) {\n const canLoad = route.canLoad;\n if (canLoad === undefined || canLoad.length === 0) {\n return of(true);\n }\n const canLoadObservables = canLoad.map(injectionToken => {\n const guard = getTokenOrFunctionIdentity(injectionToken, injector);\n const guardVal = isCanLoad(guard) ? guard.canLoad(route, segments) : runInInjectionContext(injector, () => guard(route, segments));\n return wrapIntoObservable(guardVal);\n });\n return of(canLoadObservables).pipe(prioritizedGuardValue(), redirectIfUrlTree(urlSerializer));\n}\nfunction redirectIfUrlTree(urlSerializer) {\n return pipe(tap(result => {\n if (typeof result === 'boolean') return;\n throw redirectingNavigationError(urlSerializer, result);\n }), map(result => result === true));\n}\nfunction runCanMatchGuards(injector, route, segments, urlSerializer) {\n const canMatch = route.canMatch;\n if (!canMatch || canMatch.length === 0) return of(true);\n const canMatchObservables = canMatch.map(injectionToken => {\n const guard = getTokenOrFunctionIdentity(injectionToken, injector);\n const guardVal = isCanMatch(guard) ? guard.canMatch(route, segments) : runInInjectionContext(injector, () => guard(route, segments));\n return wrapIntoObservable(guardVal);\n });\n return of(canMatchObservables).pipe(prioritizedGuardValue(), redirectIfUrlTree(urlSerializer));\n}\nclass NoMatch {\n segmentGroup;\n constructor(segmentGroup) {\n this.segmentGroup = segmentGroup || null;\n }\n}\nclass AbsoluteRedirect extends Error {\n urlTree;\n constructor(urlTree) {\n super();\n this.urlTree = urlTree;\n }\n}\nfunction noMatch$1(segmentGroup) {\n return throwError(new NoMatch(segmentGroup));\n}\nfunction absoluteRedirect(newTree) {\n return throwError(new AbsoluteRedirect(newTree));\n}\nfunction namedOutletsRedirect(redirectTo) {\n return throwError(new ɵRuntimeError(4000 /* RuntimeErrorCode.NAMED_OUTLET_REDIRECT */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Only absolute redirects can have named outlets. redirectTo: '${redirectTo}'`));\n}\nfunction canLoadFails(route) {\n return throwError(navigationCancelingError((typeof ngDevMode === 'undefined' || ngDevMode) && `Cannot load children because the guard of the route \"path: '${route.path}'\" returned false`, NavigationCancellationCode.GuardRejected));\n}\nclass ApplyRedirects {\n urlSerializer;\n urlTree;\n constructor(urlSerializer, urlTree) {\n this.urlSerializer = urlSerializer;\n this.urlTree = urlTree;\n }\n lineralizeSegments(route, urlTree) {\n let res = [];\n let c = urlTree.root;\n while (true) {\n res = res.concat(c.segments);\n if (c.numberOfChildren === 0) {\n return of(res);\n }\n if (c.numberOfChildren > 1 || !c.children[PRIMARY_OUTLET]) {\n return namedOutletsRedirect(`${route.redirectTo}`);\n }\n c = c.children[PRIMARY_OUTLET];\n }\n }\n applyRedirectCommands(segments, redirectTo, posParams, currentSnapshot, injector) {\n if (typeof redirectTo !== 'string') {\n const redirectToFn = redirectTo;\n const {\n queryParams,\n fragment,\n routeConfig,\n url,\n outlet,\n params,\n data,\n title\n } = currentSnapshot;\n const newRedirect = runInInjectionContext(injector, () => redirectToFn({\n params,\n data,\n queryParams,\n fragment,\n routeConfig,\n url,\n outlet,\n title\n }));\n if (newRedirect instanceof UrlTree) {\n throw new AbsoluteRedirect(newRedirect);\n }\n redirectTo = newRedirect;\n }\n const newTree = this.applyRedirectCreateUrlTree(redirectTo, this.urlSerializer.parse(redirectTo), segments, posParams);\n if (redirectTo[0] === '/') {\n throw new AbsoluteRedirect(newTree);\n }\n return newTree;\n }\n applyRedirectCreateUrlTree(redirectTo, urlTree, segments, posParams) {\n const newRoot = this.createSegmentGroup(redirectTo, urlTree.root, segments, posParams);\n return new UrlTree(newRoot, this.createQueryParams(urlTree.queryParams, this.urlTree.queryParams), urlTree.fragment);\n }\n createQueryParams(redirectToParams, actualParams) {\n const res = {};\n Object.entries(redirectToParams).forEach(([k, v]) => {\n const copySourceValue = typeof v === 'string' && v[0] === ':';\n if (copySourceValue) {\n const sourceName = v.substring(1);\n res[k] = actualParams[sourceName];\n } else {\n res[k] = v;\n }\n });\n return res;\n }\n createSegmentGroup(redirectTo, group, segments, posParams) {\n const updatedSegments = this.createSegments(redirectTo, group.segments, segments, posParams);\n let children = {};\n Object.entries(group.children).forEach(([name, child]) => {\n children[name] = this.createSegmentGroup(redirectTo, child, segments, posParams);\n });\n return new UrlSegmentGroup(updatedSegments, children);\n }\n createSegments(redirectTo, redirectToSegments, actualSegments, posParams) {\n return redirectToSegments.map(s => s.path[0] === ':' ? this.findPosParam(redirectTo, s, posParams) : this.findOrReturn(s, actualSegments));\n }\n findPosParam(redirectTo, redirectToUrlSegment, posParams) {\n const pos = posParams[redirectToUrlSegment.path.substring(1)];\n if (!pos) throw new ɵRuntimeError(4001 /* RuntimeErrorCode.MISSING_REDIRECT */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Cannot redirect to '${redirectTo}'. Cannot find '${redirectToUrlSegment.path}'.`);\n return pos;\n }\n findOrReturn(redirectToUrlSegment, actualSegments) {\n let idx = 0;\n for (const s of actualSegments) {\n if (s.path === redirectToUrlSegment.path) {\n actualSegments.splice(idx);\n return s;\n }\n idx++;\n }\n return redirectToUrlSegment;\n }\n}\nconst noMatch = {\n matched: false,\n consumedSegments: [],\n remainingSegments: [],\n parameters: {},\n positionalParamSegments: {}\n};\nfunction matchWithChecks(segmentGroup, route, segments, injector, urlSerializer) {\n const result = match(segmentGroup, route, segments);\n if (!result.matched) {\n return of(result);\n }\n // Only create the Route's `EnvironmentInjector` if it matches the attempted\n // navigation\n injector = getOrCreateRouteInjectorIfNeeded(route, injector);\n return runCanMatchGuards(injector, route, segments, urlSerializer).pipe(map(v => v === true ? result : {\n ...noMatch\n }));\n}\nfunction match(segmentGroup, route, segments) {\n if (route.path === '**') {\n return createWildcardMatchResult(segments);\n }\n if (route.path === '') {\n if (route.pathMatch === 'full' && (segmentGroup.hasChildren() || segments.length > 0)) {\n return {\n ...noMatch\n };\n }\n return {\n matched: true,\n consumedSegments: [],\n remainingSegments: segments,\n parameters: {},\n positionalParamSegments: {}\n };\n }\n const matcher = route.matcher || defaultUrlMatcher;\n const res = matcher(segments, segmentGroup, route);\n if (!res) return {\n ...noMatch\n };\n const posParams = {};\n Object.entries(res.posParams ?? {}).forEach(([k, v]) => {\n posParams[k] = v.path;\n });\n const parameters = res.consumed.length > 0 ? {\n ...posParams,\n ...res.consumed[res.consumed.length - 1].parameters\n } : posParams;\n return {\n matched: true,\n consumedSegments: res.consumed,\n remainingSegments: segments.slice(res.consumed.length),\n // TODO(atscott): investigate combining parameters and positionalParamSegments\n parameters,\n positionalParamSegments: res.posParams ?? {}\n };\n}\nfunction createWildcardMatchResult(segments) {\n return {\n matched: true,\n parameters: segments.length > 0 ? last(segments).parameters : {},\n consumedSegments: segments,\n remainingSegments: [],\n positionalParamSegments: {}\n };\n}\nfunction split(segmentGroup, consumedSegments, slicedSegments, config) {\n if (slicedSegments.length > 0 && containsEmptyPathMatchesWithNamedOutlets(segmentGroup, slicedSegments, config)) {\n const s = new UrlSegmentGroup(consumedSegments, createChildrenForEmptyPaths(config, new UrlSegmentGroup(slicedSegments, segmentGroup.children)));\n return {\n segmentGroup: s,\n slicedSegments: []\n };\n }\n if (slicedSegments.length === 0 && containsEmptyPathMatches(segmentGroup, slicedSegments, config)) {\n const s = new UrlSegmentGroup(segmentGroup.segments, addEmptyPathsToChildrenIfNeeded(segmentGroup, slicedSegments, config, segmentGroup.children));\n return {\n segmentGroup: s,\n slicedSegments\n };\n }\n const s = new UrlSegmentGroup(segmentGroup.segments, segmentGroup.children);\n return {\n segmentGroup: s,\n slicedSegments\n };\n}\nfunction addEmptyPathsToChildrenIfNeeded(segmentGroup, slicedSegments, routes, children) {\n const res = {};\n for (const r of routes) {\n if (emptyPathMatch(segmentGroup, slicedSegments, r) && !children[getOutlet(r)]) {\n const s = new UrlSegmentGroup([], {});\n res[getOutlet(r)] = s;\n }\n }\n return {\n ...children,\n ...res\n };\n}\nfunction createChildrenForEmptyPaths(routes, primarySegment) {\n const res = {};\n res[PRIMARY_OUTLET] = primarySegment;\n for (const r of routes) {\n if (r.path === '' && getOutlet(r) !== PRIMARY_OUTLET) {\n const s = new UrlSegmentGroup([], {});\n res[getOutlet(r)] = s;\n }\n }\n return res;\n}\nfunction containsEmptyPathMatchesWithNamedOutlets(segmentGroup, slicedSegments, routes) {\n return routes.some(r => emptyPathMatch(segmentGroup, slicedSegments, r) && getOutlet(r) !== PRIMARY_OUTLET);\n}\nfunction containsEmptyPathMatches(segmentGroup, slicedSegments, routes) {\n return routes.some(r => emptyPathMatch(segmentGroup, slicedSegments, r));\n}\nfunction emptyPathMatch(segmentGroup, slicedSegments, r) {\n if ((segmentGroup.hasChildren() || slicedSegments.length > 0) && r.pathMatch === 'full') {\n return false;\n }\n return r.path === '';\n}\nfunction noLeftoversInUrl(segmentGroup, segments, outlet) {\n return segments.length === 0 && !segmentGroup.children[outlet];\n}\n\n/**\n * Class used to indicate there were no additional route config matches but that all segments of\n * the URL were consumed during matching so the route was URL matched. When this happens, we still\n * try to match child configs in case there are empty path children.\n */\nclass NoLeftoversInUrl {}\nfunction recognize$1(injector, configLoader, rootComponentType, config, urlTree, urlSerializer, paramsInheritanceStrategy = 'emptyOnly') {\n return new Recognizer(injector, configLoader, rootComponentType, config, urlTree, paramsInheritanceStrategy, urlSerializer).recognize();\n}\nconst MAX_ALLOWED_REDIRECTS = 31;\nclass Recognizer {\n injector;\n configLoader;\n rootComponentType;\n config;\n urlTree;\n paramsInheritanceStrategy;\n urlSerializer;\n applyRedirects;\n absoluteRedirectCount = 0;\n allowRedirects = true;\n constructor(injector, configLoader, rootComponentType, config, urlTree, paramsInheritanceStrategy, urlSerializer) {\n this.injector = injector;\n this.configLoader = configLoader;\n this.rootComponentType = rootComponentType;\n this.config = config;\n this.urlTree = urlTree;\n this.paramsInheritanceStrategy = paramsInheritanceStrategy;\n this.urlSerializer = urlSerializer;\n this.applyRedirects = new ApplyRedirects(this.urlSerializer, this.urlTree);\n }\n noMatchError(e) {\n return new ɵRuntimeError(4002 /* RuntimeErrorCode.NO_MATCH */, typeof ngDevMode === 'undefined' || ngDevMode ? `Cannot match any routes. URL Segment: '${e.segmentGroup}'` : `'${e.segmentGroup}'`);\n }\n recognize() {\n const rootSegmentGroup = split(this.urlTree.root, [], [], this.config).segmentGroup;\n return this.match(rootSegmentGroup).pipe(map(({\n children,\n rootSnapshot\n }) => {\n const rootNode = new TreeNode(rootSnapshot, children);\n const routeState = new RouterStateSnapshot('', rootNode);\n const tree = createUrlTreeFromSnapshot(rootSnapshot, [], this.urlTree.queryParams, this.urlTree.fragment);\n // https://github.com/angular/angular/issues/47307\n // Creating the tree stringifies the query params\n // We don't want to do this here so reassign them to the original.\n tree.queryParams = this.urlTree.queryParams;\n routeState.url = this.urlSerializer.serialize(tree);\n return {\n state: routeState,\n tree\n };\n }));\n }\n match(rootSegmentGroup) {\n // Use Object.freeze to prevent readers of the Router state from modifying it outside\n // of a navigation, resulting in the router being out of sync with the browser.\n const rootSnapshot = new ActivatedRouteSnapshot([], Object.freeze({}), Object.freeze({\n ...this.urlTree.queryParams\n }), this.urlTree.fragment, Object.freeze({}), PRIMARY_OUTLET, this.rootComponentType, null, {});\n return this.processSegmentGroup(this.injector, this.config, rootSegmentGroup, PRIMARY_OUTLET, rootSnapshot).pipe(map(children => {\n return {\n children,\n rootSnapshot\n };\n }), catchError(e => {\n if (e instanceof AbsoluteRedirect) {\n this.urlTree = e.urlTree;\n return this.match(e.urlTree.root);\n }\n if (e instanceof NoMatch) {\n throw this.noMatchError(e);\n }\n throw e;\n }));\n }\n processSegmentGroup(injector, config, segmentGroup, outlet, parentRoute) {\n if (segmentGroup.segments.length === 0 && segmentGroup.hasChildren()) {\n return this.processChildren(injector, config, segmentGroup, parentRoute);\n }\n return this.processSegment(injector, config, segmentGroup, segmentGroup.segments, outlet, true, parentRoute).pipe(map(child => child instanceof TreeNode ? [child] : []));\n }\n /**\n * Matches every child outlet in the `segmentGroup` to a `Route` in the config. Returns `null` if\n * we cannot find a match for _any_ of the children.\n *\n * @param config - The `Routes` to match against\n * @param segmentGroup - The `UrlSegmentGroup` whose children need to be matched against the\n * config.\n */\n processChildren(injector, config, segmentGroup, parentRoute) {\n // Expand outlets one at a time, starting with the primary outlet. We need to do it this way\n // because an absolute redirect from the primary outlet takes precedence.\n const childOutlets = [];\n for (const child of Object.keys(segmentGroup.children)) {\n if (child === 'primary') {\n childOutlets.unshift(child);\n } else {\n childOutlets.push(child);\n }\n }\n return from(childOutlets).pipe(concatMap(childOutlet => {\n const child = segmentGroup.children[childOutlet];\n // Sort the config so that routes with outlets that match the one being activated\n // appear first, followed by routes for other outlets, which might match if they have\n // an empty path.\n const sortedConfig = sortByMatchingOutlets(config, childOutlet);\n return this.processSegmentGroup(injector, sortedConfig, child, childOutlet, parentRoute);\n }), scan((children, outletChildren) => {\n children.push(...outletChildren);\n return children;\n }), defaultIfEmpty(null), last$1(), mergeMap(children => {\n if (children === null) return noMatch$1(segmentGroup);\n // Because we may have matched two outlets to the same empty path segment, we can have\n // multiple activated results for the same outlet. We should merge the children of\n // these results so the final return value is only one `TreeNode` per outlet.\n const mergedChildren = mergeEmptyPathMatches(children);\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n // This should really never happen - we are only taking the first match for each\n // outlet and merge the empty path matches.\n checkOutletNameUniqueness(mergedChildren);\n }\n sortActivatedRouteSnapshots(mergedChildren);\n return of(mergedChildren);\n }));\n }\n processSegment(injector, routes, segmentGroup, segments, outlet, allowRedirects, parentRoute) {\n return from(routes).pipe(concatMap(r => {\n return this.processSegmentAgainstRoute(r._injector ?? injector, routes, r, segmentGroup, segments, outlet, allowRedirects, parentRoute).pipe(catchError(e => {\n if (e instanceof NoMatch) {\n return of(null);\n }\n throw e;\n }));\n }), first(x => !!x), catchError(e => {\n if (isEmptyError(e)) {\n if (noLeftoversInUrl(segmentGroup, segments, outlet)) {\n return of(new NoLeftoversInUrl());\n }\n return noMatch$1(segmentGroup);\n }\n throw e;\n }));\n }\n processSegmentAgainstRoute(injector, routes, route, rawSegment, segments, outlet, allowRedirects, parentRoute) {\n // We allow matches to empty paths when the outlets differ so we can match a url like `/(b:b)` to\n // a config like\n // * `{path: '', children: [{path: 'b', outlet: 'b'}]}`\n // or even\n // * `{path: '', outlet: 'a', children: [{path: 'b', outlet: 'b'}]`\n //\n // The exception here is when the segment outlet is for the primary outlet. This would\n // result in a match inside the named outlet because all children there are written as primary\n // outlets. So we need to prevent child named outlet matches in a url like `/b` in a config like\n // * `{path: '', outlet: 'x' children: [{path: 'b'}]}`\n // This should only match if the url is `/(x:b)`.\n if (getOutlet(route) !== outlet && (outlet === PRIMARY_OUTLET || !emptyPathMatch(rawSegment, segments, route))) {\n return noMatch$1(rawSegment);\n }\n if (route.redirectTo === undefined) {\n return this.matchSegmentAgainstRoute(injector, rawSegment, route, segments, outlet, parentRoute);\n }\n if (this.allowRedirects && allowRedirects) {\n return this.expandSegmentAgainstRouteUsingRedirect(injector, rawSegment, routes, route, segments, outlet, parentRoute);\n }\n return noMatch$1(rawSegment);\n }\n expandSegmentAgainstRouteUsingRedirect(injector, segmentGroup, routes, route, segments, outlet, parentRoute) {\n const {\n matched,\n parameters,\n consumedSegments,\n positionalParamSegments,\n remainingSegments\n } = match(segmentGroup, route, segments);\n if (!matched) return noMatch$1(segmentGroup);\n // TODO(atscott): Move all of this under an if(ngDevMode) as a breaking change and allow stack\n // size exceeded in production\n if (typeof route.redirectTo === 'string' && route.redirectTo[0] === '/') {\n this.absoluteRedirectCount++;\n if (this.absoluteRedirectCount > MAX_ALLOWED_REDIRECTS) {\n if (ngDevMode) {\n throw new ɵRuntimeError(4016 /* RuntimeErrorCode.INFINITE_REDIRECT */, `Detected possible infinite redirect when redirecting from '${this.urlTree}' to '${route.redirectTo}'.\\n` + `This is currently a dev mode only error but will become a` + ` call stack size exceeded error in production in a future major version.`);\n }\n this.allowRedirects = false;\n }\n }\n const currentSnapshot = new ActivatedRouteSnapshot(segments, parameters, Object.freeze({\n ...this.urlTree.queryParams\n }), this.urlTree.fragment, getData(route), getOutlet(route), route.component ?? route._loadedComponent ?? null, route, getResolve(route));\n const inherited = getInherited(currentSnapshot, parentRoute, this.paramsInheritanceStrategy);\n currentSnapshot.params = Object.freeze(inherited.params);\n currentSnapshot.data = Object.freeze(inherited.data);\n const newTree = this.applyRedirects.applyRedirectCommands(consumedSegments, route.redirectTo, positionalParamSegments, currentSnapshot, injector);\n return this.applyRedirects.lineralizeSegments(route, newTree).pipe(mergeMap(newSegments => {\n return this.processSegment(injector, routes, segmentGroup, newSegments.concat(remainingSegments), outlet, false, parentRoute);\n }));\n }\n matchSegmentAgainstRoute(injector, rawSegment, route, segments, outlet, parentRoute) {\n const matchResult = matchWithChecks(rawSegment, route, segments, injector, this.urlSerializer);\n if (route.path === '**') {\n // Prior versions of the route matching algorithm would stop matching at the wildcard route.\n // We should investigate a better strategy for any existing children. Otherwise, these\n // child segments are silently dropped from the navigation.\n // https://github.com/angular/angular/issues/40089\n rawSegment.children = {};\n }\n return matchResult.pipe(switchMap(result => {\n if (!result.matched) {\n return noMatch$1(rawSegment);\n }\n // If the route has an injector created from providers, we should start using that.\n injector = route._injector ?? injector;\n return this.getChildConfig(injector, route, segments).pipe(switchMap(({\n routes: childConfig\n }) => {\n const childInjector = route._loadedInjector ?? injector;\n const {\n parameters,\n consumedSegments,\n remainingSegments\n } = result;\n const snapshot = new ActivatedRouteSnapshot(consumedSegments, parameters, Object.freeze({\n ...this.urlTree.queryParams\n }), this.urlTree.fragment, getData(route), getOutlet(route), route.component ?? route._loadedComponent ?? null, route, getResolve(route));\n const inherited = getInherited(snapshot, parentRoute, this.paramsInheritanceStrategy);\n snapshot.params = Object.freeze(inherited.params);\n snapshot.data = Object.freeze(inherited.data);\n const {\n segmentGroup,\n slicedSegments\n } = split(rawSegment, consumedSegments, remainingSegments, childConfig);\n if (slicedSegments.length === 0 && segmentGroup.hasChildren()) {\n return this.processChildren(childInjector, childConfig, segmentGroup, snapshot).pipe(map(children => {\n return new TreeNode(snapshot, children);\n }));\n }\n if (childConfig.length === 0 && slicedSegments.length === 0) {\n return of(new TreeNode(snapshot, []));\n }\n const matchedOnOutlet = getOutlet(route) === outlet;\n // If we matched a config due to empty path match on a different outlet, we need to\n // continue passing the current outlet for the segment rather than switch to PRIMARY.\n // Note that we switch to primary when we have a match because outlet configs look like\n // this: {path: 'a', outlet: 'a', children: [\n // {path: 'b', component: B},\n // {path: 'c', component: C},\n // ]}\n // Notice that the children of the named outlet are configured with the primary outlet\n return this.processSegment(childInjector, childConfig, segmentGroup, slicedSegments, matchedOnOutlet ? PRIMARY_OUTLET : outlet, true, snapshot).pipe(map(child => {\n return new TreeNode(snapshot, child instanceof TreeNode ? [child] : []);\n }));\n }));\n }));\n }\n getChildConfig(injector, route, segments) {\n if (route.children) {\n // The children belong to the same module\n return of({\n routes: route.children,\n injector\n });\n }\n if (route.loadChildren) {\n // lazy children belong to the loaded module\n if (route._loadedRoutes !== undefined) {\n return of({\n routes: route._loadedRoutes,\n injector: route._loadedInjector\n });\n }\n return runCanLoadGuards(injector, route, segments, this.urlSerializer).pipe(mergeMap(shouldLoadResult => {\n if (shouldLoadResult) {\n return this.configLoader.loadChildren(injector, route).pipe(tap(cfg => {\n route._loadedRoutes = cfg.routes;\n route._loadedInjector = cfg.injector;\n }));\n }\n return canLoadFails(route);\n }));\n }\n return of({\n routes: [],\n injector\n });\n }\n}\nfunction sortActivatedRouteSnapshots(nodes) {\n nodes.sort((a, b) => {\n if (a.value.outlet === PRIMARY_OUTLET) return -1;\n if (b.value.outlet === PRIMARY_OUTLET) return 1;\n return a.value.outlet.localeCompare(b.value.outlet);\n });\n}\nfunction hasEmptyPathConfig(node) {\n const config = node.value.routeConfig;\n return config && config.path === '';\n}\n/**\n * Finds `TreeNode`s with matching empty path route configs and merges them into `TreeNode` with\n * the children from each duplicate. This is necessary because different outlets can match a\n * single empty path route config and the results need to then be merged.\n */\nfunction mergeEmptyPathMatches(nodes) {\n const result = [];\n // The set of nodes which contain children that were merged from two duplicate empty path nodes.\n const mergedNodes = new Set();\n for (const node of nodes) {\n if (!hasEmptyPathConfig(node)) {\n result.push(node);\n continue;\n }\n const duplicateEmptyPathNode = result.find(resultNode => node.value.routeConfig === resultNode.value.routeConfig);\n if (duplicateEmptyPathNode !== undefined) {\n duplicateEmptyPathNode.children.push(...node.children);\n mergedNodes.add(duplicateEmptyPathNode);\n } else {\n result.push(node);\n }\n }\n // For each node which has children from multiple sources, we need to recompute a new `TreeNode`\n // by also merging those children. This is necessary when there are multiple empty path configs\n // in a row. Put another way: whenever we combine children of two nodes, we need to also check\n // if any of those children can be combined into a single node as well.\n for (const mergedNode of mergedNodes) {\n const mergedChildren = mergeEmptyPathMatches(mergedNode.children);\n result.push(new TreeNode(mergedNode.value, mergedChildren));\n }\n return result.filter(n => !mergedNodes.has(n));\n}\nfunction checkOutletNameUniqueness(nodes) {\n const names = {};\n nodes.forEach(n => {\n const routeWithSameOutletName = names[n.value.outlet];\n if (routeWithSameOutletName) {\n const p = routeWithSameOutletName.url.map(s => s.toString()).join('/');\n const c = n.value.url.map(s => s.toString()).join('/');\n throw new ɵRuntimeError(4006 /* RuntimeErrorCode.TWO_SEGMENTS_WITH_SAME_OUTLET */, (typeof ngDevMode === 'undefined' || ngDevMode) && `Two segments cannot have the same outlet name: '${p}' and '${c}'.`);\n }\n names[n.value.outlet] = n.value;\n });\n}\nfunction getData(route) {\n return route.data || {};\n}\nfunction getResolve(route) {\n return route.resolve || {};\n}\nfunction recognize(injector, configLoader, rootComponentType, config, serializer, paramsInheritanceStrategy) {\n return mergeMap(t => recognize$1(injector, configLoader, rootComponentType, config, t.extractedUrl, serializer, paramsInheritanceStrategy).pipe(map(({\n state: targetSnapshot,\n tree: urlAfterRedirects\n }) => {\n return {\n ...t,\n targetSnapshot,\n urlAfterRedirects\n };\n })));\n}\nfunction resolveData(paramsInheritanceStrategy, injector) {\n return mergeMap(t => {\n const {\n targetSnapshot,\n guards: {\n canActivateChecks\n }\n } = t;\n if (!canActivateChecks.length) {\n return of(t);\n }\n // Iterating a Set in javascript happens in insertion order so it is safe to use a `Set` to\n // preserve the correct order that the resolvers should run in.\n // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set#description\n const routesWithResolversToRun = new Set(canActivateChecks.map(check => check.route));\n const routesNeedingDataUpdates = new Set();\n for (const route of routesWithResolversToRun) {\n if (routesNeedingDataUpdates.has(route)) {\n continue;\n }\n // All children under the route with a resolver to run need to recompute inherited data.\n for (const newRoute of flattenRouteTree(route)) {\n routesNeedingDataUpdates.add(newRoute);\n }\n }\n let routesProcessed = 0;\n return from(routesNeedingDataUpdates).pipe(concatMap(route => {\n if (routesWithResolversToRun.has(route)) {\n return runResolve(route, targetSnapshot, paramsInheritanceStrategy, injector);\n } else {\n route.data = getInherited(route, route.parent, paramsInheritanceStrategy).resolve;\n return of(void 0);\n }\n }), tap(() => routesProcessed++), takeLast(1), mergeMap(_ => routesProcessed === routesNeedingDataUpdates.size ? of(t) : EMPTY));\n });\n}\n/**\n * Returns the `ActivatedRouteSnapshot` tree as an array, using DFS to traverse the route tree.\n */\nfunction flattenRouteTree(route) {\n const descendants = route.children.map(child => flattenRouteTree(child)).flat();\n return [route, ...descendants];\n}\nfunction runResolve(futureARS, futureRSS, paramsInheritanceStrategy, injector) {\n const config = futureARS.routeConfig;\n const resolve = futureARS._resolve;\n if (config?.title !== undefined && !hasStaticTitle(config)) {\n resolve[RouteTitleKey] = config.title;\n }\n return resolveNode(resolve, futureARS, futureRSS, injector).pipe(map(resolvedData => {\n futureARS._resolvedData = resolvedData;\n futureARS.data = getInherited(futureARS, futureARS.parent, paramsInheritanceStrategy).resolve;\n return null;\n }));\n}\nfunction resolveNode(resolve, futureARS, futureRSS, injector) {\n const keys = getDataKeys(resolve);\n if (keys.length === 0) {\n return of({});\n }\n const data = {};\n return from(keys).pipe(mergeMap(key => getResolver(resolve[key], futureARS, futureRSS, injector).pipe(first(), tap(value => {\n if (value instanceof RedirectCommand) {\n throw redirectingNavigationError(new DefaultUrlSerializer(), value);\n }\n data[key] = value;\n }))), takeLast(1), map(() => data), catchError(e => isEmptyError(e) ? EMPTY : throwError(e)));\n}\nfunction getResolver(injectionToken, futureARS, futureRSS, injector) {\n const closestInjector = getClosestRouteInjector(futureARS) ?? injector;\n const resolver = getTokenOrFunctionIdentity(injectionToken, closestInjector);\n const resolverValue = resolver.resolve ? resolver.resolve(futureARS, futureRSS) : runInInjectionContext(closestInjector, () => resolver(futureARS, futureRSS));\n return wrapIntoObservable(resolverValue);\n}\n\n/**\n * Perform a side effect through a switchMap for every emission on the source Observable,\n * but return an Observable that is identical to the source. It's essentially the same as\n * the `tap` operator, but if the side effectful `next` function returns an ObservableInput,\n * it will wait before continuing with the original value.\n */\nfunction switchTap(next) {\n return switchMap(v => {\n const nextResult = next(v);\n if (nextResult) {\n return from(nextResult).pipe(map(() => v));\n }\n return of(v);\n });\n}\n\n/**\n * Provides a strategy for setting the page title after a router navigation.\n *\n * The built-in implementation traverses the router state snapshot and finds the deepest primary\n * outlet with `title` property. Given the `Routes` below, navigating to\n * `/base/child(popup:aux)` would result in the document title being set to \"child\".\n * ```ts\n * [\n * {path: 'base', title: 'base', children: [\n * {path: 'child', title: 'child'},\n * ],\n * {path: 'aux', outlet: 'popup', title: 'popupTitle'}\n * ]\n * ```\n *\n * This class can be used as a base class for custom title strategies. That is, you can create your\n * own class that extends the `TitleStrategy`. Note that in the above example, the `title`\n * from the named outlet is never used. However, a custom strategy might be implemented to\n * incorporate titles in named outlets.\n *\n * @publicApi\n * @see [Page title guide](guide/routing/common-router-tasks#setting-the-page-title)\n */\nclass TitleStrategy {\n /**\n * @returns The `title` of the deepest primary route.\n */\n buildTitle(snapshot) {\n let pageTitle;\n let route = snapshot.root;\n while (route !== undefined) {\n pageTitle = this.getResolvedTitleForRoute(route) ?? pageTitle;\n route = route.children.find(child => child.outlet === PRIMARY_OUTLET);\n }\n return pageTitle;\n }\n /**\n * Given an `ActivatedRouteSnapshot`, returns the final value of the\n * `Route.title` property, which can either be a static string or a resolved value.\n */\n getResolvedTitleForRoute(snapshot) {\n return snapshot.data[RouteTitleKey];\n }\n static ɵfac = function TitleStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || TitleStrategy)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: TitleStrategy,\n factory: () => (() => inject(DefaultTitleStrategy))(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TitleStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: () => inject(DefaultTitleStrategy)\n }]\n }], null, null);\n})();\n/**\n * The default `TitleStrategy` used by the router that updates the title using the `Title` service.\n */\nclass DefaultTitleStrategy extends TitleStrategy {\n title;\n constructor(title) {\n super();\n this.title = title;\n }\n /**\n * Sets the title of the browser to the given value.\n *\n * @param title The `pageTitle` from the deepest primary route.\n */\n updateTitle(snapshot) {\n const title = this.buildTitle(snapshot);\n if (title !== undefined) {\n this.title.setTitle(title);\n }\n }\n static ɵfac = function DefaultTitleStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DefaultTitleStrategy)(i0.ɵɵinject(i1.Title));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DefaultTitleStrategy,\n factory: DefaultTitleStrategy.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DefaultTitleStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [{\n type: i1.Title\n }], null);\n})();\n\n/**\n * A DI token for the router service.\n *\n * @publicApi\n */\nconst ROUTER_CONFIGURATION = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'router config' : '', {\n providedIn: 'root',\n factory: () => ({})\n});\n\n/**\n * This component is used internally within the router to be a placeholder when an empty\n * router-outlet is needed. For example, with a config such as:\n *\n * `{path: 'parent', outlet: 'nav', children: [...]}`\n *\n * In order to render, there needs to be a component on this config, which will default\n * to this `EmptyOutletComponent`.\n */\nclass ɵEmptyOutletComponent {\n static ɵfac = function ɵEmptyOutletComponent_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ɵEmptyOutletComponent)();\n };\n static ɵcmp = /* @__PURE__ */i0.ɵɵdefineComponent({\n type: ɵEmptyOutletComponent,\n selectors: [[\"ng-component\"]],\n exportAs: [\"emptyRouterOutlet\"],\n decls: 1,\n vars: 0,\n template: function _EmptyOutletComponent_Template(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵelement(0, \"router-outlet\");\n }\n },\n dependencies: [RouterOutlet],\n encapsulation: 2\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(ɵEmptyOutletComponent, [{\n type: Component,\n args: [{\n template: `<router-outlet/>`,\n imports: [RouterOutlet],\n // Used to avoid component ID collisions with user code.\n exportAs: 'emptyRouterOutlet'\n }]\n }], null, null);\n})();\n/**\n * Makes a copy of the config and adds any default required properties.\n */\nfunction standardizeConfig(r) {\n const children = r.children && r.children.map(standardizeConfig);\n const c = children ? {\n ...r,\n children\n } : {\n ...r\n };\n if (!c.component && !c.loadComponent && (children || c.loadChildren) && c.outlet && c.outlet !== PRIMARY_OUTLET) {\n c.component = ɵEmptyOutletComponent;\n }\n return c;\n}\n\n/**\n * The DI token for a router configuration.\n *\n * `ROUTES` is a low level API for router configuration via dependency injection.\n *\n * We recommend that in almost all cases to use higher level APIs such as `RouterModule.forRoot()`,\n * `provideRouter`, or `Router.resetConfig()`.\n *\n * @publicApi\n */\nconst ROUTES = new InjectionToken(ngDevMode ? 'ROUTES' : '');\nclass RouterConfigLoader {\n componentLoaders = new WeakMap();\n childrenLoaders = new WeakMap();\n onLoadStartListener;\n onLoadEndListener;\n compiler = inject(Compiler);\n loadComponent(route) {\n if (this.componentLoaders.get(route)) {\n return this.componentLoaders.get(route);\n } else if (route._loadedComponent) {\n return of(route._loadedComponent);\n }\n if (this.onLoadStartListener) {\n this.onLoadStartListener(route);\n }\n const loadRunner = wrapIntoObservable(route.loadComponent()).pipe(map(maybeUnwrapDefaultExport), tap(component => {\n if (this.onLoadEndListener) {\n this.onLoadEndListener(route);\n }\n (typeof ngDevMode === 'undefined' || ngDevMode) && assertStandalone(route.path ?? '', component);\n route._loadedComponent = component;\n }), finalize(() => {\n this.componentLoaders.delete(route);\n }));\n // Use custom ConnectableObservable as share in runners pipe increasing the bundle size too much\n const loader = new ConnectableObservable(loadRunner, () => new Subject()).pipe(refCount());\n this.componentLoaders.set(route, loader);\n return loader;\n }\n loadChildren(parentInjector, route) {\n if (this.childrenLoaders.get(route)) {\n return this.childrenLoaders.get(route);\n } else if (route._loadedRoutes) {\n return of({\n routes: route._loadedRoutes,\n injector: route._loadedInjector\n });\n }\n if (this.onLoadStartListener) {\n this.onLoadStartListener(route);\n }\n const moduleFactoryOrRoutes$ = loadChildren(route, this.compiler, parentInjector, this.onLoadEndListener);\n const loadRunner = moduleFactoryOrRoutes$.pipe(finalize(() => {\n this.childrenLoaders.delete(route);\n }));\n // Use custom ConnectableObservable as share in runners pipe increasing the bundle size too much\n const loader = new ConnectableObservable(loadRunner, () => new Subject()).pipe(refCount());\n this.childrenLoaders.set(route, loader);\n return loader;\n }\n static ɵfac = function RouterConfigLoader_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RouterConfigLoader)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: RouterConfigLoader,\n factory: RouterConfigLoader.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouterConfigLoader, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n/**\n * Executes a `route.loadChildren` callback and converts the result to an array of child routes and\n * an injector if that callback returned a module.\n *\n * This function is used for the route discovery during prerendering\n * in @angular-devkit/build-angular. If there are any updates to the contract here, it will require\n * an update to the extractor.\n */\nfunction loadChildren(route, compiler, parentInjector, onLoadEndListener) {\n return wrapIntoObservable(route.loadChildren()).pipe(map(maybeUnwrapDefaultExport), mergeMap(t => {\n if (t instanceof NgModuleFactory || Array.isArray(t)) {\n return of(t);\n } else {\n return from(compiler.compileModuleAsync(t));\n }\n }), map(factoryOrRoutes => {\n if (onLoadEndListener) {\n onLoadEndListener(route);\n }\n // This injector comes from the `NgModuleRef` when lazy loading an `NgModule`. There is\n // no injector associated with lazy loading a `Route` array.\n let injector;\n let rawRoutes;\n let requireStandaloneComponents = false;\n if (Array.isArray(factoryOrRoutes)) {\n rawRoutes = factoryOrRoutes;\n requireStandaloneComponents = true;\n } else {\n injector = factoryOrRoutes.create(parentInjector).injector;\n // When loading a module that doesn't provide `RouterModule.forChild()` preloader\n // will get stuck in an infinite loop. The child module's Injector will look to\n // its parent `Injector` when it doesn't find any ROUTES so it will return routes\n // for it's parent module instead.\n rawRoutes = injector.get(ROUTES, [], {\n optional: true,\n self: true\n }).flat();\n }\n const routes = rawRoutes.map(standardizeConfig);\n (typeof ngDevMode === 'undefined' || ngDevMode) && validateConfig(routes, route.path, requireStandaloneComponents);\n return {\n routes,\n injector\n };\n }));\n}\nfunction isWrappedDefaultExport(value) {\n // We use `in` here with a string key `'default'`, because we expect `DefaultExport` objects to be\n // dynamically imported ES modules with a spec-mandated `default` key. Thus we don't expect that\n // `default` will be a renamed property.\n return value && typeof value === 'object' && 'default' in value;\n}\nfunction maybeUnwrapDefaultExport(input) {\n // As per `isWrappedDefaultExport`, the `default` key here is generated by the browser and not\n // subject to property renaming, so we reference it with bracket access.\n return isWrappedDefaultExport(input) ? input['default'] : input;\n}\n\n/**\n * @description\n *\n * Provides a way to migrate AngularJS applications to Angular.\n *\n * @publicApi\n */\nclass UrlHandlingStrategy {\n static ɵfac = function UrlHandlingStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || UrlHandlingStrategy)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: UrlHandlingStrategy,\n factory: () => (() => inject(DefaultUrlHandlingStrategy))(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(UrlHandlingStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: () => inject(DefaultUrlHandlingStrategy)\n }]\n }], null, null);\n})();\n/**\n * @publicApi\n */\nclass DefaultUrlHandlingStrategy {\n shouldProcessUrl(url) {\n return true;\n }\n extract(url) {\n return url;\n }\n merge(newUrlPart, wholeUrl) {\n return newUrlPart;\n }\n static ɵfac = function DefaultUrlHandlingStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DefaultUrlHandlingStrategy)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DefaultUrlHandlingStrategy,\n factory: DefaultUrlHandlingStrategy.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DefaultUrlHandlingStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n\n/// <reference types=\"dom-view-transitions\" />\nconst CREATE_VIEW_TRANSITION = new InjectionToken(ngDevMode ? 'view transition helper' : '');\nconst VIEW_TRANSITION_OPTIONS = new InjectionToken(ngDevMode ? 'view transition options' : '');\n/**\n * A helper function for using browser view transitions. This function skips the call to\n * `startViewTransition` if the browser does not support it.\n *\n * @returns A Promise that resolves when the view transition callback begins.\n */\nfunction createViewTransition(injector, from, to) {\n const transitionOptions = injector.get(VIEW_TRANSITION_OPTIONS);\n const document = injector.get(DOCUMENT);\n // Create promises outside the Angular zone to avoid causing extra change detections\n return injector.get(NgZone).runOutsideAngular(() => {\n if (!document.startViewTransition || transitionOptions.skipNextTransition) {\n transitionOptions.skipNextTransition = false;\n // The timing of `startViewTransition` is closer to a macrotask. It won't be called\n // until the current event loop exits so we use a promise resolved in a timeout instead\n // of Promise.resolve().\n return new Promise(resolve => setTimeout(resolve));\n }\n let resolveViewTransitionStarted;\n const viewTransitionStarted = new Promise(resolve => {\n resolveViewTransitionStarted = resolve;\n });\n const transition = document.startViewTransition(() => {\n resolveViewTransitionStarted();\n // We don't actually update dom within the transition callback. The resolving of the above\n // promise unblocks the Router navigation, which synchronously activates and deactivates\n // routes (the DOM update). This view transition waits for the next change detection to\n // complete (below), which includes the update phase of the routed components.\n return createRenderPromise(injector);\n });\n const {\n onViewTransitionCreated\n } = transitionOptions;\n if (onViewTransitionCreated) {\n runInInjectionContext(injector, () => onViewTransitionCreated({\n transition,\n from,\n to\n }));\n }\n return viewTransitionStarted;\n });\n}\n/**\n * Creates a promise that resolves after next render.\n */\nfunction createRenderPromise(injector) {\n return new Promise(resolve => {\n // Wait for the microtask queue to empty after the next render happens (by waiting a macrotask).\n // This ensures any follow-up renders in the microtask queue are completed before the\n // view transition starts animating.\n afterNextRender({\n read: () => setTimeout(resolve)\n }, {\n injector\n });\n });\n}\nconst NAVIGATION_ERROR_HANDLER = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'navigation error handler' : '');\nclass NavigationTransitions {\n currentNavigation = null;\n currentTransition = null;\n lastSuccessfulNavigation = null;\n /**\n * These events are used to communicate back to the Router about the state of the transition. The\n * Router wants to respond to these events in various ways. Because the `NavigationTransition`\n * class is not public, this event subject is not publicly exposed.\n */\n events = new Subject();\n /**\n * Used to abort the current transition with an error.\n */\n transitionAbortSubject = new Subject();\n configLoader = inject(RouterConfigLoader);\n environmentInjector = inject(EnvironmentInjector);\n destroyRef = inject(DestroyRef);\n urlSerializer = inject(UrlSerializer);\n rootContexts = inject(ChildrenOutletContexts);\n location = inject(Location);\n inputBindingEnabled = inject(INPUT_BINDER, {\n optional: true\n }) !== null;\n titleStrategy = inject(TitleStrategy);\n options = inject(ROUTER_CONFIGURATION, {\n optional: true\n }) || {};\n paramsInheritanceStrategy = this.options.paramsInheritanceStrategy || 'emptyOnly';\n urlHandlingStrategy = inject(UrlHandlingStrategy);\n createViewTransition = inject(CREATE_VIEW_TRANSITION, {\n optional: true\n });\n navigationErrorHandler = inject(NAVIGATION_ERROR_HANDLER, {\n optional: true\n });\n navigationId = 0;\n get hasRequestedNavigation() {\n return this.navigationId !== 0;\n }\n transitions;\n /**\n * Hook that enables you to pause navigation after the preactivation phase.\n * Used by `RouterModule`.\n *\n * @internal\n */\n afterPreactivation = () => of(void 0);\n /** @internal */\n rootComponentType = null;\n destroyed = false;\n constructor() {\n const onLoadStart = r => this.events.next(new RouteConfigLoadStart(r));\n const onLoadEnd = r => this.events.next(new RouteConfigLoadEnd(r));\n this.configLoader.onLoadEndListener = onLoadEnd;\n this.configLoader.onLoadStartListener = onLoadStart;\n this.destroyRef.onDestroy(() => {\n this.destroyed = true;\n });\n }\n complete() {\n this.transitions?.complete();\n }\n handleNavigationRequest(request) {\n const id = ++this.navigationId;\n this.transitions?.next({\n ...this.transitions.value,\n ...request,\n id\n });\n }\n setupNavigations(router, initialUrlTree, initialRouterState) {\n this.transitions = new BehaviorSubject({\n id: 0,\n currentUrlTree: initialUrlTree,\n currentRawUrl: initialUrlTree,\n extractedUrl: this.urlHandlingStrategy.extract(initialUrlTree),\n urlAfterRedirects: this.urlHandlingStrategy.extract(initialUrlTree),\n rawUrl: initialUrlTree,\n extras: {},\n resolve: () => {},\n reject: () => {},\n promise: Promise.resolve(true),\n source: IMPERATIVE_NAVIGATION,\n restoredState: null,\n currentSnapshot: initialRouterState.snapshot,\n targetSnapshot: null,\n currentRouterState: initialRouterState,\n targetRouterState: null,\n guards: {\n canActivateChecks: [],\n canDeactivateChecks: []\n },\n guardsResult: null\n });\n return this.transitions.pipe(filter(t => t.id !== 0),\n // Extract URL\n map(t => ({\n ...t,\n extractedUrl: this.urlHandlingStrategy.extract(t.rawUrl)\n })),\n // Using switchMap so we cancel executing navigations when a new one comes in\n switchMap(overallTransitionState => {\n let completed = false;\n let errored = false;\n return of(overallTransitionState).pipe(switchMap(t => {\n // It is possible that `switchMap` fails to cancel previous navigations if a new one happens synchronously while the operator\n // is processing the `next` notification of that previous navigation. This can happen when a new navigation (say 2) cancels a\n // previous one (1) and yet another navigation (3) happens synchronously in response to the `NavigationCancel` event for (1).\n // https://github.com/ReactiveX/rxjs/issues/7455\n if (this.navigationId > overallTransitionState.id) {\n const cancellationReason = typeof ngDevMode === 'undefined' || ngDevMode ? `Navigation ID ${overallTransitionState.id} is not equal to the current navigation id ${this.navigationId}` : '';\n this.cancelNavigationTransition(overallTransitionState, cancellationReason, NavigationCancellationCode.SupersededByNewNavigation);\n return EMPTY;\n }\n this.currentTransition = overallTransitionState;\n // Store the Navigation object\n this.currentNavigation = {\n id: t.id,\n initialUrl: t.rawUrl,\n extractedUrl: t.extractedUrl,\n targetBrowserUrl: typeof t.extras.browserUrl === 'string' ? this.urlSerializer.parse(t.extras.browserUrl) : t.extras.browserUrl,\n trigger: t.source,\n extras: t.extras,\n previousNavigation: !this.lastSuccessfulNavigation ? null : {\n ...this.lastSuccessfulNavigation,\n previousNavigation: null\n }\n };\n const urlTransition = !router.navigated || this.isUpdatingInternalState() || this.isUpdatedBrowserUrl();\n const onSameUrlNavigation = t.extras.onSameUrlNavigation ?? router.onSameUrlNavigation;\n if (!urlTransition && onSameUrlNavigation !== 'reload') {\n const reason = typeof ngDevMode === 'undefined' || ngDevMode ? `Navigation to ${t.rawUrl} was ignored because it is the same as the current Router URL.` : '';\n this.events.next(new NavigationSkipped(t.id, this.urlSerializer.serialize(t.rawUrl), reason, NavigationSkippedCode.IgnoredSameUrlNavigation));\n t.resolve(false);\n return EMPTY;\n }\n if (this.urlHandlingStrategy.shouldProcessUrl(t.rawUrl)) {\n return of(t).pipe(\n // Fire NavigationStart event\n switchMap(t => {\n const transition = this.transitions?.getValue();\n this.events.next(new NavigationStart(t.id, this.urlSerializer.serialize(t.extractedUrl), t.source, t.restoredState));\n if (transition !== this.transitions?.getValue()) {\n return EMPTY;\n }\n // This delay is required to match old behavior that forced\n // navigation to always be async\n return Promise.resolve(t);\n }),\n // Recognize\n recognize(this.environmentInjector, this.configLoader, this.rootComponentType, router.config, this.urlSerializer, this.paramsInheritanceStrategy),\n // Update URL if in `eager` update mode\n tap(t => {\n overallTransitionState.targetSnapshot = t.targetSnapshot;\n overallTransitionState.urlAfterRedirects = t.urlAfterRedirects;\n this.currentNavigation = {\n ...this.currentNavigation,\n finalUrl: t.urlAfterRedirects\n };\n // Fire RoutesRecognized\n const routesRecognized = new RoutesRecognized(t.id, this.urlSerializer.serialize(t.extractedUrl), this.urlSerializer.serialize(t.urlAfterRedirects), t.targetSnapshot);\n this.events.next(routesRecognized);\n }));\n } else if (urlTransition && this.urlHandlingStrategy.shouldProcessUrl(t.currentRawUrl)) {\n /* When the current URL shouldn't be processed, but the previous one\n * was, we handle this \"error condition\" by navigating to the\n * previously successful URL, but leaving the URL intact.*/\n const {\n id,\n extractedUrl,\n source,\n restoredState,\n extras\n } = t;\n const navStart = new NavigationStart(id, this.urlSerializer.serialize(extractedUrl), source, restoredState);\n this.events.next(navStart);\n const targetSnapshot = createEmptyState(this.rootComponentType).snapshot;\n this.currentTransition = overallTransitionState = {\n ...t,\n targetSnapshot,\n urlAfterRedirects: extractedUrl,\n extras: {\n ...extras,\n skipLocationChange: false,\n replaceUrl: false\n }\n };\n this.currentNavigation.finalUrl = extractedUrl;\n return of(overallTransitionState);\n } else {\n /* When neither the current or previous URL can be processed, do\n * nothing other than update router's internal reference to the\n * current \"settled\" URL. This way the next navigation will be coming\n * from the current URL in the browser.\n */\n const reason = typeof ngDevMode === 'undefined' || ngDevMode ? `Navigation was ignored because the UrlHandlingStrategy` + ` indicated neither the current URL ${t.currentRawUrl} nor target URL ${t.rawUrl} should be processed.` : '';\n this.events.next(new NavigationSkipped(t.id, this.urlSerializer.serialize(t.extractedUrl), reason, NavigationSkippedCode.IgnoredByUrlHandlingStrategy));\n t.resolve(false);\n return EMPTY;\n }\n }),\n // --- GUARDS ---\n tap(t => {\n const guardsStart = new GuardsCheckStart(t.id, this.urlSerializer.serialize(t.extractedUrl), this.urlSerializer.serialize(t.urlAfterRedirects), t.targetSnapshot);\n this.events.next(guardsStart);\n }), map(t => {\n this.currentTransition = overallTransitionState = {\n ...t,\n guards: getAllRouteGuards(t.targetSnapshot, t.currentSnapshot, this.rootContexts)\n };\n return overallTransitionState;\n }), checkGuards(this.environmentInjector, evt => this.events.next(evt)), tap(t => {\n overallTransitionState.guardsResult = t.guardsResult;\n if (t.guardsResult && typeof t.guardsResult !== 'boolean') {\n throw redirectingNavigationError(this.urlSerializer, t.guardsResult);\n }\n const guardsEnd = new GuardsCheckEnd(t.id, this.urlSerializer.serialize(t.extractedUrl), this.urlSerializer.serialize(t.urlAfterRedirects), t.targetSnapshot, !!t.guardsResult);\n this.events.next(guardsEnd);\n }), filter(t => {\n if (!t.guardsResult) {\n this.cancelNavigationTransition(t, '', NavigationCancellationCode.GuardRejected);\n return false;\n }\n return true;\n }),\n // --- RESOLVE ---\n switchTap(t => {\n if (t.guards.canActivateChecks.length) {\n return of(t).pipe(tap(t => {\n const resolveStart = new ResolveStart(t.id, this.urlSerializer.serialize(t.extractedUrl), this.urlSerializer.serialize(t.urlAfterRedirects), t.targetSnapshot);\n this.events.next(resolveStart);\n }), switchMap(t => {\n let dataResolved = false;\n return of(t).pipe(resolveData(this.paramsInheritanceStrategy, this.environmentInjector), tap({\n next: () => dataResolved = true,\n complete: () => {\n if (!dataResolved) {\n this.cancelNavigationTransition(t, typeof ngDevMode === 'undefined' || ngDevMode ? `At least one route resolver didn't emit any value.` : '', NavigationCancellationCode.NoDataFromResolver);\n }\n }\n }));\n }), tap(t => {\n const resolveEnd = new ResolveEnd(t.id, this.urlSerializer.serialize(t.extractedUrl), this.urlSerializer.serialize(t.urlAfterRedirects), t.targetSnapshot);\n this.events.next(resolveEnd);\n }));\n }\n return undefined;\n }),\n // --- LOAD COMPONENTS ---\n switchTap(t => {\n const loadComponents = route => {\n const loaders = [];\n if (route.routeConfig?.loadComponent && !route.routeConfig._loadedComponent) {\n loaders.push(this.configLoader.loadComponent(route.routeConfig).pipe(tap(loadedComponent => {\n route.component = loadedComponent;\n }), map(() => void 0)));\n }\n for (const child of route.children) {\n loaders.push(...loadComponents(child));\n }\n return loaders;\n };\n return combineLatest(loadComponents(t.targetSnapshot.root)).pipe(defaultIfEmpty(null), take(1));\n }), switchTap(() => this.afterPreactivation()), switchMap(() => {\n const {\n currentSnapshot,\n targetSnapshot\n } = overallTransitionState;\n const viewTransitionStarted = this.createViewTransition?.(this.environmentInjector, currentSnapshot.root, targetSnapshot.root);\n // If view transitions are enabled, block the navigation until the view\n // transition callback starts. Otherwise, continue immediately.\n return viewTransitionStarted ? from(viewTransitionStarted).pipe(map(() => overallTransitionState)) : of(overallTransitionState);\n }), map(t => {\n const targetRouterState = createRouterState(router.routeReuseStrategy, t.targetSnapshot, t.currentRouterState);\n this.currentTransition = overallTransitionState = {\n ...t,\n targetRouterState\n };\n this.currentNavigation.targetRouterState = targetRouterState;\n return overallTransitionState;\n }), tap(() => {\n this.events.next(new BeforeActivateRoutes());\n }), activateRoutes(this.rootContexts, router.routeReuseStrategy, evt => this.events.next(evt), this.inputBindingEnabled),\n // Ensure that if some observable used to drive the transition doesn't\n // complete, the navigation still finalizes This should never happen, but\n // this is done as a safety measure to avoid surfacing this error (#49567).\n take(1), tap({\n next: t => {\n completed = true;\n this.lastSuccessfulNavigation = this.currentNavigation;\n this.events.next(new NavigationEnd(t.id, this.urlSerializer.serialize(t.extractedUrl), this.urlSerializer.serialize(t.urlAfterRedirects)));\n this.titleStrategy?.updateTitle(t.targetRouterState.snapshot);\n t.resolve(true);\n },\n complete: () => {\n completed = true;\n }\n }),\n // There used to be a lot more logic happening directly within the\n // transition Observable. Some of this logic has been refactored out to\n // other places but there may still be errors that happen there. This gives\n // us a way to cancel the transition from the outside. This may also be\n // required in the future to support something like the abort signal of the\n // Navigation API where the navigation gets aborted from outside the\n // transition.\n takeUntil(this.transitionAbortSubject.pipe(tap(err => {\n throw err;\n }))), finalize(() => {\n /* When the navigation stream finishes either through error or success,\n * we set the `completed` or `errored` flag. However, there are some\n * situations where we could get here without either of those being set.\n * For instance, a redirect during NavigationStart. Therefore, this is a\n * catch-all to make sure the NavigationCancel event is fired when a\n * navigation gets cancelled but not caught by other means. */\n if (!completed && !errored) {\n const cancelationReason = typeof ngDevMode === 'undefined' || ngDevMode ? `Navigation ID ${overallTransitionState.id} is not equal to the current navigation id ${this.navigationId}` : '';\n this.cancelNavigationTransition(overallTransitionState, cancelationReason, NavigationCancellationCode.SupersededByNewNavigation);\n }\n // Only clear current navigation if it is still set to the one that\n // finalized.\n if (this.currentTransition?.id === overallTransitionState.id) {\n this.currentNavigation = null;\n this.currentTransition = null;\n }\n }), catchError(e => {\n // If the application is already destroyed, the catch block should not\n // execute anything in practice because other resources have already\n // been released and destroyed.\n if (this.destroyed) {\n overallTransitionState.resolve(false);\n return EMPTY;\n }\n errored = true;\n /* This error type is issued during Redirect, and is handled as a\n * cancellation rather than an error. */\n if (isNavigationCancelingError(e)) {\n this.events.next(new NavigationCancel(overallTransitionState.id, this.urlSerializer.serialize(overallTransitionState.extractedUrl), e.message, e.cancellationCode));\n // When redirecting, we need to delay resolving the navigation\n // promise and push it to the redirect navigation\n if (!isRedirectingNavigationCancelingError(e)) {\n overallTransitionState.resolve(false);\n } else {\n this.events.next(new RedirectRequest(e.url, e.navigationBehaviorOptions));\n }\n /* All other errors should reset to the router's internal URL reference\n * to the pre-error state. */\n } else {\n const navigationError = new NavigationError(overallTransitionState.id, this.urlSerializer.serialize(overallTransitionState.extractedUrl), e, overallTransitionState.targetSnapshot ?? undefined);\n try {\n const navigationErrorHandlerResult = runInInjectionContext(this.environmentInjector, () => this.navigationErrorHandler?.(navigationError));\n if (navigationErrorHandlerResult instanceof RedirectCommand) {\n const {\n message,\n cancellationCode\n } = redirectingNavigationError(this.urlSerializer, navigationErrorHandlerResult);\n this.events.next(new NavigationCancel(overallTransitionState.id, this.urlSerializer.serialize(overallTransitionState.extractedUrl), message, cancellationCode));\n this.events.next(new RedirectRequest(navigationErrorHandlerResult.redirectTo, navigationErrorHandlerResult.navigationBehaviorOptions));\n } else {\n this.events.next(navigationError);\n throw e;\n }\n } catch (ee) {\n // TODO(atscott): consider flipping the default behavior of\n // resolveNavigationPromiseOnError to be `resolve(false)` when\n // undefined. This is the most sane thing to do given that\n // applications very rarely handle the promise rejection and, as a\n // result, would get \"unhandled promise rejection\" console logs.\n // The vast majority of applications would not be affected by this\n // change so omitting a migration seems reasonable. Instead,\n // applications that rely on rejection can specifically opt-in to the\n // old behavior.\n if (this.options.resolveNavigationPromiseOnError) {\n overallTransitionState.resolve(false);\n } else {\n overallTransitionState.reject(ee);\n }\n }\n }\n return EMPTY;\n }));\n // casting because `pipe` returns observable({}) when called with 8+ arguments\n }));\n }\n cancelNavigationTransition(t, reason, code) {\n const navCancel = new NavigationCancel(t.id, this.urlSerializer.serialize(t.extractedUrl), reason, code);\n this.events.next(navCancel);\n t.resolve(false);\n }\n /**\n * @returns Whether we're navigating to somewhere that is not what the Router is\n * currently set to.\n */\n isUpdatingInternalState() {\n // TODO(atscott): The serializer should likely be used instead of\n // `UrlTree.toString()`. Custom serializers are often written to handle\n // things better than the default one (objects, for example will be\n // [Object object] with the custom serializer and be \"the same\" when they\n // aren't).\n // (Same for isUpdatedBrowserUrl)\n return this.currentTransition?.extractedUrl.toString() !== this.currentTransition?.currentUrlTree.toString();\n }\n /**\n * @returns Whether we're updating the browser URL to something new (navigation is going\n * to somewhere not displayed in the URL bar and we will update the URL\n * bar if navigation succeeds).\n */\n isUpdatedBrowserUrl() {\n // The extracted URL is the part of the URL that this application cares about. `extract` may\n // return only part of the browser URL and that part may have not changed even if some other\n // portion of the URL did.\n const currentBrowserUrl = this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(true)));\n const targetBrowserUrl = this.currentNavigation?.targetBrowserUrl ?? this.currentNavigation?.extractedUrl;\n return currentBrowserUrl.toString() !== targetBrowserUrl?.toString() && !this.currentNavigation?.extras.skipLocationChange;\n }\n static ɵfac = function NavigationTransitions_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NavigationTransitions)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: NavigationTransitions,\n factory: NavigationTransitions.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NavigationTransitions, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [], null);\n})();\nfunction isBrowserTriggeredNavigation(source) {\n return source !== IMPERATIVE_NAVIGATION;\n}\n\n/**\n * @description\n *\n * Provides a way to customize when activated routes get reused.\n *\n * @publicApi\n */\nclass RouteReuseStrategy {\n static ɵfac = function RouteReuseStrategy_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RouteReuseStrategy)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: RouteReuseStrategy,\n factory: () => (() => inject(DefaultRouteReuseStrategy))(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouteReuseStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: () => inject(DefaultRouteReuseStrategy)\n }]\n }], null, null);\n})();\n/**\n * @description\n *\n * This base route reuse strategy only reuses routes when the matched router configs are\n * identical. This prevents components from being destroyed and recreated\n * when just the route parameters, query parameters or fragment change\n * (that is, the existing component is _reused_).\n *\n * This strategy does not store any routes for later reuse.\n *\n * Angular uses this strategy by default.\n *\n *\n * It can be used as a base class for custom route reuse strategies, i.e. you can create your own\n * class that extends the `BaseRouteReuseStrategy` one.\n * @publicApi\n */\nclass BaseRouteReuseStrategy {\n /**\n * Whether the given route should detach for later reuse.\n * Always returns false for `BaseRouteReuseStrategy`.\n * */\n shouldDetach(route) {\n return false;\n }\n /**\n * A no-op; the route is never stored since this strategy never detaches routes for later re-use.\n */\n store(route, detachedTree) {}\n /** Returns `false`, meaning the route (and its subtree) is never reattached */\n shouldAttach(route) {\n return false;\n }\n /** Returns `null` because this strategy does not store routes for later re-use. */\n retrieve(route) {\n return null;\n }\n /**\n * Determines if a route should be reused.\n * This strategy returns `true` when the future route config and current route config are\n * identical.\n */\n shouldReuseRoute(future, curr) {\n return future.routeConfig === curr.routeConfig;\n }\n}\nclass DefaultRouteReuseStrategy extends BaseRouteReuseStrategy {\n static ɵfac = /* @__PURE__ */(() => {\n let ɵDefaultRouteReuseStrategy_BaseFactory;\n return function DefaultRouteReuseStrategy_Factory(__ngFactoryType__) {\n return (ɵDefaultRouteReuseStrategy_BaseFactory || (ɵDefaultRouteReuseStrategy_BaseFactory = i0.ɵɵgetInheritedFactory(DefaultRouteReuseStrategy)))(__ngFactoryType__ || DefaultRouteReuseStrategy);\n };\n })();\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: DefaultRouteReuseStrategy,\n factory: DefaultRouteReuseStrategy.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DefaultRouteReuseStrategy, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\nclass StateManager {\n static ɵfac = function StateManager_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || StateManager)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: StateManager,\n factory: () => (() => inject(HistoryStateManager))(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(StateManager, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: () => inject(HistoryStateManager)\n }]\n }], null, null);\n})();\nclass HistoryStateManager extends StateManager {\n location = inject(Location);\n urlSerializer = inject(UrlSerializer);\n options = inject(ROUTER_CONFIGURATION, {\n optional: true\n }) || {};\n canceledNavigationResolution = this.options.canceledNavigationResolution || 'replace';\n urlHandlingStrategy = inject(UrlHandlingStrategy);\n urlUpdateStrategy = this.options.urlUpdateStrategy || 'deferred';\n currentUrlTree = new UrlTree();\n getCurrentUrlTree() {\n return this.currentUrlTree;\n }\n rawUrlTree = this.currentUrlTree;\n getRawUrlTree() {\n return this.rawUrlTree;\n }\n /**\n * The id of the currently active page in the router.\n * Updated to the transition's target id on a successful navigation.\n *\n * This is used to track what page the router last activated. When an attempted navigation fails,\n * the router can then use this to compute how to restore the state back to the previously active\n * page.\n */\n currentPageId = 0;\n lastSuccessfulId = -1;\n restoredState() {\n return this.location.getState();\n }\n /**\n * The ɵrouterPageId of whatever page is currently active in the browser history. This is\n * important for computing the target page id for new navigations because we need to ensure each\n * page id in the browser history is 1 more than the previous entry.\n */\n get browserPageId() {\n if (this.canceledNavigationResolution !== 'computed') {\n return this.currentPageId;\n }\n return this.restoredState()?.ɵrouterPageId ?? this.currentPageId;\n }\n routerState = createEmptyState(null);\n getRouterState() {\n return this.routerState;\n }\n stateMemento = this.createStateMemento();\n createStateMemento() {\n return {\n rawUrlTree: this.rawUrlTree,\n currentUrlTree: this.currentUrlTree,\n routerState: this.routerState\n };\n }\n registerNonRouterCurrentEntryChangeListener(listener) {\n return this.location.subscribe(event => {\n if (event['type'] === 'popstate') {\n listener(event['url'], event.state);\n }\n });\n }\n handleRouterEvent(e, currentTransition) {\n if (e instanceof NavigationStart) {\n this.stateMemento = this.createStateMemento();\n } else if (e instanceof NavigationSkipped) {\n this.rawUrlTree = currentTransition.initialUrl;\n } else if (e instanceof RoutesRecognized) {\n if (this.urlUpdateStrategy === 'eager') {\n if (!currentTransition.extras.skipLocationChange) {\n const rawUrl = this.urlHandlingStrategy.merge(currentTransition.finalUrl, currentTransition.initialUrl);\n this.setBrowserUrl(currentTransition.targetBrowserUrl ?? rawUrl, currentTransition);\n }\n }\n } else if (e instanceof BeforeActivateRoutes) {\n this.currentUrlTree = currentTransition.finalUrl;\n this.rawUrlTree = this.urlHandlingStrategy.merge(currentTransition.finalUrl, currentTransition.initialUrl);\n this.routerState = currentTransition.targetRouterState;\n if (this.urlUpdateStrategy === 'deferred' && !currentTransition.extras.skipLocationChange) {\n this.setBrowserUrl(currentTransition.targetBrowserUrl ?? this.rawUrlTree, currentTransition);\n }\n } else if (e instanceof NavigationCancel && (e.code === NavigationCancellationCode.GuardRejected || e.code === NavigationCancellationCode.NoDataFromResolver)) {\n this.restoreHistory(currentTransition);\n } else if (e instanceof NavigationError) {\n this.restoreHistory(currentTransition, true);\n } else if (e instanceof NavigationEnd) {\n this.lastSuccessfulId = e.id;\n this.currentPageId = this.browserPageId;\n }\n }\n setBrowserUrl(url, transition) {\n const path = url instanceof UrlTree ? this.urlSerializer.serialize(url) : url;\n if (this.location.isCurrentPathEqualTo(path) || !!transition.extras.replaceUrl) {\n // replacements do not update the target page\n const currentBrowserPageId = this.browserPageId;\n const state = {\n ...transition.extras.state,\n ...this.generateNgRouterState(transition.id, currentBrowserPageId)\n };\n this.location.replaceState(path, '', state);\n } else {\n const state = {\n ...transition.extras.state,\n ...this.generateNgRouterState(transition.id, this.browserPageId + 1)\n };\n this.location.go(path, '', state);\n }\n }\n /**\n * Performs the necessary rollback action to restore the browser URL to the\n * state before the transition.\n */\n restoreHistory(navigation, restoringFromCaughtError = false) {\n if (this.canceledNavigationResolution === 'computed') {\n const currentBrowserPageId = this.browserPageId;\n const targetPagePosition = this.currentPageId - currentBrowserPageId;\n if (targetPagePosition !== 0) {\n this.location.historyGo(targetPagePosition);\n } else if (this.currentUrlTree === navigation.finalUrl && targetPagePosition === 0) {\n // We got to the activation stage (where currentUrlTree is set to the navigation's\n // finalUrl), but we weren't moving anywhere in history (skipLocationChange or replaceUrl).\n // We still need to reset the router state back to what it was when the navigation started.\n this.resetState(navigation);\n this.resetUrlToCurrentUrlTree();\n } else {\n // The browser URL and router state was not updated before the navigation cancelled so\n // there's no restoration needed.\n }\n } else if (this.canceledNavigationResolution === 'replace') {\n // TODO(atscott): It seems like we should _always_ reset the state here. It would be a no-op\n // for `deferred` navigations that haven't change the internal state yet because guards\n // reject. For 'eager' navigations, it seems like we also really should reset the state\n // because the navigation was cancelled. Investigate if this can be done by running TGP.\n if (restoringFromCaughtError) {\n this.resetState(navigation);\n }\n this.resetUrlToCurrentUrlTree();\n }\n }\n resetState(navigation) {\n this.routerState = this.stateMemento.routerState;\n this.currentUrlTree = this.stateMemento.currentUrlTree;\n // Note here that we use the urlHandlingStrategy to get the reset `rawUrlTree` because it may be\n // configured to handle only part of the navigation URL. This means we would only want to reset\n // the part of the navigation handled by the Angular router rather than the whole URL. In\n // addition, the URLHandlingStrategy may be configured to specifically preserve parts of the URL\n // when merging, such as the query params so they are not lost on a refresh.\n this.rawUrlTree = this.urlHandlingStrategy.merge(this.currentUrlTree, navigation.finalUrl ?? this.rawUrlTree);\n }\n resetUrlToCurrentUrlTree() {\n this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree), '', this.generateNgRouterState(this.lastSuccessfulId, this.currentPageId));\n }\n generateNgRouterState(navigationId, routerPageId) {\n if (this.canceledNavigationResolution === 'computed') {\n return {\n navigationId,\n ɵrouterPageId: routerPageId\n };\n }\n return {\n navigationId\n };\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵHistoryStateManager_BaseFactory;\n return function HistoryStateManager_Factory(__ngFactoryType__) {\n return (ɵHistoryStateManager_BaseFactory || (ɵHistoryStateManager_BaseFactory = i0.ɵɵgetInheritedFactory(HistoryStateManager)))(__ngFactoryType__ || HistoryStateManager);\n };\n })();\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: HistoryStateManager,\n factory: HistoryStateManager.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(HistoryStateManager, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n\n/**\n * Performs the given action once the router finishes its next/current navigation.\n *\n * The navigation is considered complete under the following conditions:\n * - `NavigationCancel` event emits and the code is not `NavigationCancellationCode.Redirect` or\n * `NavigationCancellationCode.SupersededByNewNavigation`. In these cases, the\n * redirecting/superseding navigation must finish.\n * - `NavigationError`, `NavigationEnd`, or `NavigationSkipped` event emits\n */\nfunction afterNextNavigation(router, action) {\n router.events.pipe(filter(e => e instanceof NavigationEnd || e instanceof NavigationCancel || e instanceof NavigationError || e instanceof NavigationSkipped), map(e => {\n if (e instanceof NavigationEnd || e instanceof NavigationSkipped) {\n return 0 /* NavigationResult.COMPLETE */;\n }\n const redirecting = e instanceof NavigationCancel ? e.code === NavigationCancellationCode.Redirect || e.code === NavigationCancellationCode.SupersededByNewNavigation : false;\n return redirecting ? 2 /* NavigationResult.REDIRECTING */ : 1 /* NavigationResult.FAILED */;\n }), filter(result => result !== 2 /* NavigationResult.REDIRECTING */), take(1)).subscribe(() => {\n action();\n });\n}\n\n/**\n * The equivalent `IsActiveMatchOptions` options for `Router.isActive` is called with `true`\n * (exact = true).\n */\nconst exactMatchOptions = {\n paths: 'exact',\n fragment: 'ignored',\n matrixParams: 'ignored',\n queryParams: 'exact'\n};\n/**\n * The equivalent `IsActiveMatchOptions` options for `Router.isActive` is called with `false`\n * (exact = false).\n */\nconst subsetMatchOptions = {\n paths: 'subset',\n fragment: 'ignored',\n matrixParams: 'ignored',\n queryParams: 'subset'\n};\n/**\n * @description\n *\n * A service that facilitates navigation among views and URL manipulation capabilities.\n * This service is provided in the root scope and configured with [provideRouter](api/router/provideRouter).\n *\n * @see {@link Route}\n * @see {@link provideRouter}\n * @see [Routing and Navigation Guide](guide/routing/common-router-tasks).\n *\n * @ngModule RouterModule\n *\n * @publicApi\n */\nclass Router {\n get currentUrlTree() {\n return this.stateManager.getCurrentUrlTree();\n }\n get rawUrlTree() {\n return this.stateManager.getRawUrlTree();\n }\n disposed = false;\n nonRouterCurrentEntryChangeSubscription;\n console = inject(ɵConsole);\n stateManager = inject(StateManager);\n options = inject(ROUTER_CONFIGURATION, {\n optional: true\n }) || {};\n pendingTasks = inject(ɵPendingTasksInternal);\n urlUpdateStrategy = this.options.urlUpdateStrategy || 'deferred';\n navigationTransitions = inject(NavigationTransitions);\n urlSerializer = inject(UrlSerializer);\n location = inject(Location);\n urlHandlingStrategy = inject(UrlHandlingStrategy);\n /**\n * The private `Subject` type for the public events exposed in the getter. This is used internally\n * to push events to. The separate field allows us to expose separate types in the public API\n * (i.e., an Observable rather than the Subject).\n */\n _events = new Subject();\n /**\n * An event stream for routing events.\n */\n get events() {\n // TODO(atscott): This _should_ be events.asObservable(). However, this change requires internal\n // cleanup: tests are doing `(route.events as Subject<Event>).next(...)`. This isn't\n // allowed/supported but we still have to fix these or file bugs against the teams before making\n // the change.\n return this._events;\n }\n /**\n * The current state of routing in this NgModule.\n */\n get routerState() {\n return this.stateManager.getRouterState();\n }\n /**\n * True if at least one navigation event has occurred,\n * false otherwise.\n */\n navigated = false;\n /**\n * A strategy for re-using routes.\n *\n * @deprecated Configure using `providers` instead:\n * `{provide: RouteReuseStrategy, useClass: MyStrategy}`.\n */\n routeReuseStrategy = inject(RouteReuseStrategy);\n /**\n * How to handle a navigation request to the current URL.\n *\n *\n * @deprecated Configure this through `provideRouter` or `RouterModule.forRoot` instead.\n * @see {@link withRouterConfig}\n * @see {@link provideRouter}\n * @see {@link RouterModule}\n */\n onSameUrlNavigation = this.options.onSameUrlNavigation || 'ignore';\n config = inject(ROUTES, {\n optional: true\n })?.flat() ?? [];\n /**\n * Indicates whether the application has opted in to binding Router data to component inputs.\n *\n * This option is enabled by the `withComponentInputBinding` feature of `provideRouter` or\n * `bindToComponentInputs` in the `ExtraOptions` of `RouterModule.forRoot`.\n */\n componentInputBindingEnabled = !!inject(INPUT_BINDER, {\n optional: true\n });\n constructor() {\n this.resetConfig(this.config);\n this.navigationTransitions.setupNavigations(this, this.currentUrlTree, this.routerState).subscribe({\n error: e => {\n this.console.warn(ngDevMode ? `Unhandled Navigation Error: ${e}` : e);\n }\n });\n this.subscribeToNavigationEvents();\n }\n eventsSubscription = new Subscription();\n subscribeToNavigationEvents() {\n const subscription = this.navigationTransitions.events.subscribe(e => {\n try {\n const currentTransition = this.navigationTransitions.currentTransition;\n const currentNavigation = this.navigationTransitions.currentNavigation;\n if (currentTransition !== null && currentNavigation !== null) {\n this.stateManager.handleRouterEvent(e, currentNavigation);\n if (e instanceof NavigationCancel && e.code !== NavigationCancellationCode.Redirect && e.code !== NavigationCancellationCode.SupersededByNewNavigation) {\n // It seems weird that `navigated` is set to `true` when the navigation is rejected,\n // however it's how things were written initially. Investigation would need to be done\n // to determine if this can be removed.\n this.navigated = true;\n } else if (e instanceof NavigationEnd) {\n this.navigated = true;\n } else if (e instanceof RedirectRequest) {\n const opts = e.navigationBehaviorOptions;\n const mergedTree = this.urlHandlingStrategy.merge(e.url, currentTransition.currentRawUrl);\n const extras = {\n browserUrl: currentTransition.extras.browserUrl,\n info: currentTransition.extras.info,\n skipLocationChange: currentTransition.extras.skipLocationChange,\n // The URL is already updated at this point if we have 'eager' URL\n // updates or if the navigation was triggered by the browser (back\n // button, URL bar, etc). We want to replace that item in history\n // if the navigation is rejected.\n replaceUrl: currentTransition.extras.replaceUrl || this.urlUpdateStrategy === 'eager' || isBrowserTriggeredNavigation(currentTransition.source),\n // allow developer to override default options with RedirectCommand\n ...opts\n };\n this.scheduleNavigation(mergedTree, IMPERATIVE_NAVIGATION, null, extras, {\n resolve: currentTransition.resolve,\n reject: currentTransition.reject,\n promise: currentTransition.promise\n });\n }\n }\n // Note that it's important to have the Router process the events _before_ the event is\n // pushed through the public observable. This ensures the correct router state is in place\n // before applications observe the events.\n if (isPublicRouterEvent(e)) {\n this._events.next(e);\n }\n } catch (e) {\n this.navigationTransitions.transitionAbortSubject.next(e);\n }\n });\n this.eventsSubscription.add(subscription);\n }\n /** @internal */\n resetRootComponentType(rootComponentType) {\n // TODO: vsavkin router 4.0 should make the root component set to null\n // this will simplify the lifecycle of the router.\n this.routerState.root.component = rootComponentType;\n this.navigationTransitions.rootComponentType = rootComponentType;\n }\n /**\n * Sets up the location change listener and performs the initial navigation.\n */\n initialNavigation() {\n this.setUpLocationChangeListener();\n if (!this.navigationTransitions.hasRequestedNavigation) {\n this.navigateToSyncWithBrowser(this.location.path(true), IMPERATIVE_NAVIGATION, this.stateManager.restoredState());\n }\n }\n /**\n * Sets up the location change listener. This listener detects navigations triggered from outside\n * the Router (the browser back/forward buttons, for example) and schedules a corresponding Router\n * navigation so that the correct events, guards, etc. are triggered.\n */\n setUpLocationChangeListener() {\n // Don't need to use Zone.wrap any more, because zone.js\n // already patch onPopState, so location change callback will\n // run into ngZone\n this.nonRouterCurrentEntryChangeSubscription ??= this.stateManager.registerNonRouterCurrentEntryChangeListener((url, state) => {\n // The `setTimeout` was added in #12160 and is likely to support Angular/AngularJS\n // hybrid apps.\n setTimeout(() => {\n this.navigateToSyncWithBrowser(url, 'popstate', state);\n }, 0);\n });\n }\n /**\n * Schedules a router navigation to synchronize Router state with the browser state.\n *\n * This is done as a response to a popstate event and the initial navigation. These\n * two scenarios represent times when the browser URL/state has been updated and\n * the Router needs to respond to ensure its internal state matches.\n */\n navigateToSyncWithBrowser(url, source, state) {\n const extras = {\n replaceUrl: true\n };\n // TODO: restoredState should always include the entire state, regardless\n // of navigationId. This requires a breaking change to update the type on\n // NavigationStart’s restoredState, which currently requires navigationId\n // to always be present. The Router used to only restore history state if\n // a navigationId was present.\n // The stored navigationId is used by the RouterScroller to retrieve the scroll\n // position for the page.\n const restoredState = state?.navigationId ? state : null;\n // Separate to NavigationStart.restoredState, we must also restore the state to\n // history.state and generate a new navigationId, since it will be overwritten\n if (state) {\n const stateCopy = {\n ...state\n };\n delete stateCopy.navigationId;\n delete stateCopy.ɵrouterPageId;\n if (Object.keys(stateCopy).length !== 0) {\n extras.state = stateCopy;\n }\n }\n const urlTree = this.parseUrl(url);\n this.scheduleNavigation(urlTree, source, restoredState, extras);\n }\n /** The current URL. */\n get url() {\n return this.serializeUrl(this.currentUrlTree);\n }\n /**\n * Returns the current `Navigation` object when the router is navigating,\n * and `null` when idle.\n */\n getCurrentNavigation() {\n return this.navigationTransitions.currentNavigation;\n }\n /**\n * The `Navigation` object of the most recent navigation to succeed and `null` if there\n * has not been a successful navigation yet.\n */\n get lastSuccessfulNavigation() {\n return this.navigationTransitions.lastSuccessfulNavigation;\n }\n /**\n * Resets the route configuration used for navigation and generating links.\n *\n * @param config The route array for the new configuration.\n *\n * @usageNotes\n *\n * ```ts\n * router.resetConfig([\n * { path: 'team/:id', component: TeamCmp, children: [\n * { path: 'simple', component: SimpleCmp },\n * { path: 'user/:name', component: UserCmp }\n * ]}\n * ]);\n * ```\n */\n resetConfig(config) {\n (typeof ngDevMode === 'undefined' || ngDevMode) && validateConfig(config);\n this.config = config.map(standardizeConfig);\n this.navigated = false;\n }\n /** @nodoc */\n ngOnDestroy() {\n this.dispose();\n }\n /** Disposes of the router. */\n dispose() {\n // We call `unsubscribe()` to release observers, as users may forget to\n // unsubscribe manually when subscribing to `router.events`. We do not call\n // `complete()` because it is unsafe; if someone subscribes using the `first`\n // operator and the observable completes before emitting a value,\n // RxJS will throw an error.\n this._events.unsubscribe();\n this.navigationTransitions.complete();\n if (this.nonRouterCurrentEntryChangeSubscription) {\n this.nonRouterCurrentEntryChangeSubscription.unsubscribe();\n this.nonRouterCurrentEntryChangeSubscription = undefined;\n }\n this.disposed = true;\n this.eventsSubscription.unsubscribe();\n }\n /**\n * Appends URL segments to the current URL tree to create a new URL tree.\n *\n * @param commands An array of URL fragments with which to construct the new URL tree.\n * If the path is static, can be the literal URL string. For a dynamic path, pass an array of path\n * segments, followed by the parameters for each segment.\n * The fragments are applied to the current URL tree or the one provided in the `relativeTo`\n * property of the options object, if supplied.\n * @param navigationExtras Options that control the navigation strategy.\n * @returns The new URL tree.\n *\n * @usageNotes\n *\n * ```\n * // create /team/33/user/11\n * router.createUrlTree(['/team', 33, 'user', 11]);\n *\n * // create /team/33;expand=true/user/11\n * router.createUrlTree(['/team', 33, {expand: true}, 'user', 11]);\n *\n * // you can collapse static segments like this (this works only with the first passed-in value):\n * router.createUrlTree(['/team/33/user', userId]);\n *\n * // If the first segment can contain slashes, and you do not want the router to split it,\n * // you can do the following:\n * router.createUrlTree([{segmentPath: '/one/two'}]);\n *\n * // create /team/33/(user/11//right:chat)\n * router.createUrlTree(['/team', 33, {outlets: {primary: 'user/11', right: 'chat'}}]);\n *\n * // remove the right secondary node\n * router.createUrlTree(['/team', 33, {outlets: {primary: 'user/11', right: null}}]);\n *\n * // assuming the current url is `/team/33/user/11` and the route points to `user/11`\n *\n * // navigate to /team/33/user/11/details\n * router.createUrlTree(['details'], {relativeTo: route});\n *\n * // navigate to /team/33/user/22\n * router.createUrlTree(['../22'], {relativeTo: route});\n *\n * // navigate to /team/44/user/22\n * router.createUrlTree(['../../team/44/user/22'], {relativeTo: route});\n *\n * Note that a value of `null` or `undefined` for `relativeTo` indicates that the\n * tree should be created relative to the root.\n * ```\n */\n createUrlTree(commands, navigationExtras = {}) {\n const {\n relativeTo,\n queryParams,\n fragment,\n queryParamsHandling,\n preserveFragment\n } = navigationExtras;\n const f = preserveFragment ? this.currentUrlTree.fragment : fragment;\n let q = null;\n switch (queryParamsHandling ?? this.options.defaultQueryParamsHandling) {\n case 'merge':\n q = {\n ...this.currentUrlTree.queryParams,\n ...queryParams\n };\n break;\n case 'preserve':\n q = this.currentUrlTree.queryParams;\n break;\n default:\n q = queryParams || null;\n }\n if (q !== null) {\n q = this.removeEmptyProps(q);\n }\n let relativeToUrlSegmentGroup;\n try {\n const relativeToSnapshot = relativeTo ? relativeTo.snapshot : this.routerState.snapshot.root;\n relativeToUrlSegmentGroup = createSegmentGroupFromRoute(relativeToSnapshot);\n } catch (e) {\n // This is strictly for backwards compatibility with tests that create\n // invalid `ActivatedRoute` mocks.\n // Note: the difference between having this fallback for invalid `ActivatedRoute` setups and\n // just throwing is ~500 test failures. Fixing all of those tests by hand is not feasible at\n // the moment.\n if (typeof commands[0] !== 'string' || commands[0][0] !== '/') {\n // Navigations that were absolute in the old way of creating UrlTrees\n // would still work because they wouldn't attempt to match the\n // segments in the `ActivatedRoute` to the `currentUrlTree` but\n // instead just replace the root segment with the navigation result.\n // Non-absolute navigations would fail to apply the commands because\n // the logic could not find the segment to replace (so they'd act like there were no\n // commands).\n commands = [];\n }\n relativeToUrlSegmentGroup = this.currentUrlTree.root;\n }\n return createUrlTreeFromSegmentGroup(relativeToUrlSegmentGroup, commands, q, f ?? null);\n }\n /**\n * Navigates to a view using an absolute route path.\n *\n * @param url An absolute path for a defined route. The function does not apply any delta to the\n * current URL.\n * @param extras An object containing properties that modify the navigation strategy.\n *\n * @returns A Promise that resolves to 'true' when navigation succeeds,\n * to 'false' when navigation fails, or is rejected on error.\n *\n * @usageNotes\n *\n * The following calls request navigation to an absolute path.\n *\n * ```ts\n * router.navigateByUrl(\"/team/33/user/11\");\n *\n * // Navigate without updating the URL\n * router.navigateByUrl(\"/team/33/user/11\", { skipLocationChange: true });\n * ```\n *\n * @see [Routing and Navigation guide](guide/routing/common-router-tasks)\n *\n */\n navigateByUrl(url, extras = {\n skipLocationChange: false\n }) {\n const urlTree = isUrlTree(url) ? url : this.parseUrl(url);\n const mergedTree = this.urlHandlingStrategy.merge(urlTree, this.rawUrlTree);\n return this.scheduleNavigation(mergedTree, IMPERATIVE_NAVIGATION, null, extras);\n }\n /**\n * Navigate based on the provided array of commands and a starting point.\n * If no starting route is provided, the navigation is absolute.\n *\n * @param commands An array of URL fragments with which to construct the target URL.\n * If the path is static, can be the literal URL string. For a dynamic path, pass an array of path\n * segments, followed by the parameters for each segment.\n * The fragments are applied to the current URL or the one provided in the `relativeTo` property\n * of the options object, if supplied.\n * @param extras An options object that determines how the URL should be constructed or\n * interpreted.\n *\n * @returns A Promise that resolves to `true` when navigation succeeds, or `false` when navigation\n * fails. The Promise is rejected when an error occurs if `resolveNavigationPromiseOnError` is\n * not `true`.\n *\n * @usageNotes\n *\n * The following calls request navigation to a dynamic route path relative to the current URL.\n *\n * ```ts\n * router.navigate(['team', 33, 'user', 11], {relativeTo: route});\n *\n * // Navigate without updating the URL, overriding the default behavior\n * router.navigate(['team', 33, 'user', 11], {relativeTo: route, skipLocationChange: true});\n * ```\n *\n * @see [Routing and Navigation guide](guide/routing/common-router-tasks)\n *\n */\n navigate(commands, extras = {\n skipLocationChange: false\n }) {\n validateCommands(commands);\n return this.navigateByUrl(this.createUrlTree(commands, extras), extras);\n }\n /** Serializes a `UrlTree` into a string */\n serializeUrl(url) {\n return this.urlSerializer.serialize(url);\n }\n /** Parses a string into a `UrlTree` */\n parseUrl(url) {\n try {\n return this.urlSerializer.parse(url);\n } catch {\n return this.urlSerializer.parse('/');\n }\n }\n isActive(url, matchOptions) {\n let options;\n if (matchOptions === true) {\n options = {\n ...exactMatchOptions\n };\n } else if (matchOptions === false) {\n options = {\n ...subsetMatchOptions\n };\n } else {\n options = matchOptions;\n }\n if (isUrlTree(url)) {\n return containsTree(this.currentUrlTree, url, options);\n }\n const urlTree = this.parseUrl(url);\n return containsTree(this.currentUrlTree, urlTree, options);\n }\n removeEmptyProps(params) {\n return Object.entries(params).reduce((result, [key, value]) => {\n if (value !== null && value !== undefined) {\n result[key] = value;\n }\n return result;\n }, {});\n }\n scheduleNavigation(rawUrl, source, restoredState, extras, priorPromise) {\n if (this.disposed) {\n return Promise.resolve(false);\n }\n let resolve;\n let reject;\n let promise;\n if (priorPromise) {\n resolve = priorPromise.resolve;\n reject = priorPromise.reject;\n promise = priorPromise.promise;\n } else {\n promise = new Promise((res, rej) => {\n resolve = res;\n reject = rej;\n });\n }\n // Indicate that the navigation is happening.\n const taskId = this.pendingTasks.add();\n afterNextNavigation(this, () => {\n // Remove pending task in a microtask to allow for cancelled\n // initial navigations and redirects within the same task.\n queueMicrotask(() => this.pendingTasks.remove(taskId));\n });\n this.navigationTransitions.handleNavigationRequest({\n source,\n restoredState,\n currentUrlTree: this.currentUrlTree,\n currentRawUrl: this.currentUrlTree,\n rawUrl,\n extras,\n resolve: resolve,\n reject: reject,\n promise,\n currentSnapshot: this.routerState.snapshot,\n currentRouterState: this.routerState\n });\n // Make sure that the error is propagated even though `processNavigations` catch\n // handler does not rethrow\n return promise.catch(e => {\n return Promise.reject(e);\n });\n }\n static ɵfac = function Router_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || Router)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: Router,\n factory: Router.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(Router, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [], null);\n})();\nfunction validateCommands(commands) {\n for (let i = 0; i < commands.length; i++) {\n const cmd = commands[i];\n if (cmd == null) {\n throw new ɵRuntimeError(4008 /* RuntimeErrorCode.NULLISH_COMMAND */, (typeof ngDevMode === 'undefined' || ngDevMode) && `The requested path contains ${cmd} segment at index ${i}`);\n }\n }\n}\nfunction isPublicRouterEvent(e) {\n return !(e instanceof BeforeActivateRoutes) && !(e instanceof RedirectRequest);\n}\n\n/**\n * @description\n *\n * When applied to an element in a template, makes that element a link\n * that initiates navigation to a route. Navigation opens one or more routed components\n * in one or more `<router-outlet>` locations on the page.\n *\n * Given a route configuration `[{ path: 'user/:name', component: UserCmp }]`,\n * the following creates a static link to the route:\n * `<a routerLink=\"/user/bob\">link to user component</a>`\n *\n * You can use dynamic values to generate the link.\n * For a dynamic link, pass an array of path segments,\n * followed by the params for each segment.\n * For example, `['/team', teamId, 'user', userName, {details: true}]`\n * generates a link to `/team/11/user/bob;details=true`.\n *\n * Multiple static segments can be merged into one term and combined with dynamic segments.\n * For example, `['/team/11/user', userName, {details: true}]`\n *\n * The input that you provide to the link is treated as a delta to the current URL.\n * For instance, suppose the current URL is `/user/(box//aux:team)`.\n * The link `<a [routerLink]=\"['/user/jim']\">Jim</a>` creates the URL\n * `/user/(jim//aux:team)`.\n * See {@link Router#createUrlTree} for more information.\n *\n * @usageNotes\n *\n * You can use absolute or relative paths in a link, set query parameters,\n * control how parameters are handled, and keep a history of navigation states.\n *\n * ### Relative link paths\n *\n * The first segment name can be prepended with `/`, `./`, or `../`.\n * * If the first segment begins with `/`, the router looks up the route from the root of the\n * app.\n * * If the first segment begins with `./`, or doesn't begin with a slash, the router\n * looks in the children of the current activated route.\n * * If the first segment begins with `../`, the router goes up one level in the route tree.\n *\n * ### Setting and handling query params and fragments\n *\n * The following link adds a query parameter and a fragment to the generated URL:\n *\n * ```html\n * <a [routerLink]=\"['/user/bob']\" [queryParams]=\"{debug: true}\" fragment=\"education\">\n * link to user component\n * </a>\n * ```\n * By default, the directive constructs the new URL using the given query parameters.\n * The example generates the link: `/user/bob?debug=true#education`.\n *\n * You can instruct the directive to handle query parameters differently\n * by specifying the `queryParamsHandling` option in the link.\n * Allowed values are:\n *\n * - `'merge'`: Merge the given `queryParams` into the current query params.\n * - `'preserve'`: Preserve the current query params.\n *\n * For example:\n *\n * ```html\n * <a [routerLink]=\"['/user/bob']\" [queryParams]=\"{debug: true}\" queryParamsHandling=\"merge\">\n * link to user component\n * </a>\n * ```\n *\n * `queryParams`, `fragment`, `queryParamsHandling`, `preserveFragment`, and `relativeTo`\n * cannot be used when the `routerLink` input is a `UrlTree`.\n *\n * See {@link UrlCreationOptions#queryParamsHandling}.\n *\n * ### Preserving navigation history\n *\n * You can provide a `state` value to be persisted to the browser's\n * [`History.state` property](https://developer.mozilla.org/en-US/docs/Web/API/History#Properties).\n * For example:\n *\n * ```html\n * <a [routerLink]=\"['/user/bob']\" [state]=\"{tracingId: 123}\">\n * link to user component\n * </a>\n * ```\n *\n * Use {@link Router#getCurrentNavigation} to retrieve a saved\n * navigation-state value. For example, to capture the `tracingId` during the `NavigationStart`\n * event:\n *\n * ```ts\n * // Get NavigationStart events\n * router.events.pipe(filter(e => e instanceof NavigationStart)).subscribe(e => {\n * const navigation = router.getCurrentNavigation();\n * tracingService.trace({id: navigation.extras.state.tracingId});\n * });\n * ```\n *\n * @ngModule RouterModule\n *\n * @publicApi\n */\nclass RouterLink {\n router;\n route;\n tabIndexAttribute;\n renderer;\n el;\n locationStrategy;\n /**\n * Represents an `href` attribute value applied to a host element,\n * when a host element is `<a>`. For other tags, the value is `null`.\n */\n href = null;\n /**\n * Represents the `target` attribute on a host element.\n * This is only used when the host element is an `<a>` tag.\n */\n target;\n /**\n * Passed to {@link Router#createUrlTree} as part of the\n * `UrlCreationOptions`.\n * @see {@link UrlCreationOptions#queryParams}\n * @see {@link Router#createUrlTree}\n */\n queryParams;\n /**\n * Passed to {@link Router#createUrlTree} as part of the\n * `UrlCreationOptions`.\n * @see {@link UrlCreationOptions#fragment}\n * @see {@link Router#createUrlTree}\n */\n fragment;\n /**\n * Passed to {@link Router#createUrlTree} as part of the\n * `UrlCreationOptions`.\n * @see {@link UrlCreationOptions#queryParamsHandling}\n * @see {@link Router#createUrlTree}\n */\n queryParamsHandling;\n /**\n * Passed to {@link Router#navigateByUrl} as part of the\n * `NavigationBehaviorOptions`.\n * @see {@link NavigationBehaviorOptions#state}\n * @see {@link Router#navigateByUrl}\n */\n state;\n /**\n * Passed to {@link Router#navigateByUrl} as part of the\n * `NavigationBehaviorOptions`.\n * @see {@link NavigationBehaviorOptions#info}\n * @see {@link Router#navigateByUrl}\n */\n info;\n /**\n * Passed to {@link Router#createUrlTree} as part of the\n * `UrlCreationOptions`.\n * Specify a value here when you do not want to use the default value\n * for `routerLink`, which is the current activated route.\n * Note that a value of `undefined` here will use the `routerLink` default.\n * @see {@link UrlCreationOptions#relativeTo}\n * @see {@link Router#createUrlTree}\n */\n relativeTo;\n /** Whether a host element is an `<a>` tag. */\n isAnchorElement;\n subscription;\n /** @internal */\n onChanges = new Subject();\n constructor(router, route, tabIndexAttribute, renderer, el, locationStrategy) {\n this.router = router;\n this.route = route;\n this.tabIndexAttribute = tabIndexAttribute;\n this.renderer = renderer;\n this.el = el;\n this.locationStrategy = locationStrategy;\n const tagName = el.nativeElement.tagName?.toLowerCase();\n this.isAnchorElement = tagName === 'a' || tagName === 'area';\n if (this.isAnchorElement) {\n this.subscription = router.events.subscribe(s => {\n if (s instanceof NavigationEnd) {\n this.updateHref();\n }\n });\n } else {\n this.setTabIndexIfNotOnNativeEl('0');\n }\n }\n /**\n * Passed to {@link Router#createUrlTree} as part of the\n * `UrlCreationOptions`.\n * @see {@link UrlCreationOptions#preserveFragment}\n * @see {@link Router#createUrlTree}\n */\n preserveFragment = false;\n /**\n * Passed to {@link Router#navigateByUrl} as part of the\n * `NavigationBehaviorOptions`.\n * @see {@link NavigationBehaviorOptions#skipLocationChange}\n * @see {@link Router#navigateByUrl}\n */\n skipLocationChange = false;\n /**\n * Passed to {@link Router#navigateByUrl} as part of the\n * `NavigationBehaviorOptions`.\n * @see {@link NavigationBehaviorOptions#replaceUrl}\n * @see {@link Router#navigateByUrl}\n */\n replaceUrl = false;\n /**\n * Modifies the tab index if there was not a tabindex attribute on the element during\n * instantiation.\n */\n setTabIndexIfNotOnNativeEl(newTabIndex) {\n if (this.tabIndexAttribute != null /* both `null` and `undefined` */ || this.isAnchorElement) {\n return;\n }\n this.applyAttributeValue('tabindex', newTabIndex);\n }\n /** @nodoc */\n // TODO(atscott): Remove changes parameter in major version as a breaking change.\n ngOnChanges(changes) {\n if (ngDevMode && isUrlTree(this.routerLinkInput) && (this.fragment !== undefined || this.queryParams || this.queryParamsHandling || this.preserveFragment || this.relativeTo)) {\n throw new ɵRuntimeError(4016 /* RuntimeErrorCode.INVALID_ROUTER_LINK_INPUTS */, 'Cannot configure queryParams or fragment when using a UrlTree as the routerLink input value.');\n }\n if (this.isAnchorElement) {\n this.updateHref();\n }\n // This is subscribed to by `RouterLinkActive` so that it knows to update when there are changes\n // to the RouterLinks it's tracking.\n this.onChanges.next(this);\n }\n routerLinkInput = null;\n /**\n * Commands to pass to {@link Router#createUrlTree} or a `UrlTree`.\n * - **array**: commands to pass to {@link Router#createUrlTree}.\n * - **string**: shorthand for array of commands with just the string, i.e. `['/route']`\n * - **UrlTree**: a `UrlTree` for this link rather than creating one from the commands\n * and other inputs that correspond to properties of `UrlCreationOptions`.\n * - **null|undefined**: effectively disables the `routerLink`\n * @see {@link Router#createUrlTree}\n */\n set routerLink(commandsOrUrlTree) {\n if (commandsOrUrlTree == null) {\n this.routerLinkInput = null;\n this.setTabIndexIfNotOnNativeEl(null);\n } else {\n if (isUrlTree(commandsOrUrlTree)) {\n this.routerLinkInput = commandsOrUrlTree;\n } else {\n this.routerLinkInput = Array.isArray(commandsOrUrlTree) ? commandsOrUrlTree : [commandsOrUrlTree];\n }\n this.setTabIndexIfNotOnNativeEl('0');\n }\n }\n /** @nodoc */\n onClick(button, ctrlKey, shiftKey, altKey, metaKey) {\n const urlTree = this.urlTree;\n if (urlTree === null) {\n return true;\n }\n if (this.isAnchorElement) {\n if (button !== 0 || ctrlKey || shiftKey || altKey || metaKey) {\n return true;\n }\n if (typeof this.target === 'string' && this.target != '_self') {\n return true;\n }\n }\n const extras = {\n skipLocationChange: this.skipLocationChange,\n replaceUrl: this.replaceUrl,\n state: this.state,\n info: this.info\n };\n this.router.navigateByUrl(urlTree, extras);\n // Return `false` for `<a>` elements to prevent default action\n // and cancel the native behavior, since the navigation is handled\n // by the Router.\n return !this.isAnchorElement;\n }\n /** @nodoc */\n ngOnDestroy() {\n this.subscription?.unsubscribe();\n }\n updateHref() {\n const urlTree = this.urlTree;\n this.href = urlTree !== null && this.locationStrategy ? this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(urlTree)) : null;\n const sanitizedValue = this.href === null ? null :\n // This class represents a directive that can be added to both `<a>` elements,\n // as well as other elements. As a result, we can't define security context at\n // compile time. So the security context is deferred to runtime.\n // The `ɵɵsanitizeUrlOrResourceUrl` selects the necessary sanitizer function\n // based on the tag and property names. The logic mimics the one from\n // `packages/compiler/src/schema/dom_security_schema.ts`, which is used at compile time.\n //\n // Note: we should investigate whether we can switch to using `@HostBinding('attr.href')`\n // instead of applying a value via a renderer, after a final merge of the\n // `RouterLinkWithHref` directive.\n ɵɵsanitizeUrlOrResourceUrl(this.href, this.el.nativeElement.tagName.toLowerCase(), 'href');\n this.applyAttributeValue('href', sanitizedValue);\n }\n applyAttributeValue(attrName, attrValue) {\n const renderer = this.renderer;\n const nativeElement = this.el.nativeElement;\n if (attrValue !== null) {\n renderer.setAttribute(nativeElement, attrName, attrValue);\n } else {\n renderer.removeAttribute(nativeElement, attrName);\n }\n }\n get urlTree() {\n if (this.routerLinkInput === null) {\n return null;\n } else if (isUrlTree(this.routerLinkInput)) {\n return this.routerLinkInput;\n }\n return this.router.createUrlTree(this.routerLinkInput, {\n // If the `relativeTo` input is not defined, we want to use `this.route` by default.\n // Otherwise, we should use the value provided by the user in the input.\n relativeTo: this.relativeTo !== undefined ? this.relativeTo : this.route,\n queryParams: this.queryParams,\n fragment: this.fragment,\n queryParamsHandling: this.queryParamsHandling,\n preserveFragment: this.preserveFragment\n });\n }\n static ɵfac = function RouterLink_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RouterLink)(i0.ɵɵdirectiveInject(Router), i0.ɵɵdirectiveInject(ActivatedRoute), i0.ɵɵinjectAttribute('tabindex'), i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i3.LocationStrategy));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: RouterLink,\n selectors: [[\"\", \"routerLink\", \"\"]],\n hostVars: 1,\n hostBindings: function RouterLink_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"click\", function RouterLink_click_HostBindingHandler($event) {\n return ctx.onClick($event.button, $event.ctrlKey, $event.shiftKey, $event.altKey, $event.metaKey);\n });\n }\n if (rf & 2) {\n i0.ɵɵattribute(\"target\", ctx.target);\n }\n },\n inputs: {\n target: \"target\",\n queryParams: \"queryParams\",\n fragment: \"fragment\",\n queryParamsHandling: \"queryParamsHandling\",\n state: \"state\",\n info: \"info\",\n relativeTo: \"relativeTo\",\n preserveFragment: [2, \"preserveFragment\", \"preserveFragment\", booleanAttribute],\n skipLocationChange: [2, \"skipLocationChange\", \"skipLocationChange\", booleanAttribute],\n replaceUrl: [2, \"replaceUrl\", \"replaceUrl\", booleanAttribute],\n routerLink: \"routerLink\"\n },\n features: [i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouterLink, [{\n type: Directive,\n args: [{\n selector: '[routerLink]'\n }]\n }], () => [{\n type: Router\n }, {\n type: ActivatedRoute\n }, {\n type: undefined,\n decorators: [{\n type: Attribute,\n args: ['tabindex']\n }]\n }, {\n type: i0.Renderer2\n }, {\n type: i0.ElementRef\n }, {\n type: i3.LocationStrategy\n }], {\n target: [{\n type: HostBinding,\n args: ['attr.target']\n }, {\n type: Input\n }],\n queryParams: [{\n type: Input\n }],\n fragment: [{\n type: Input\n }],\n queryParamsHandling: [{\n type: Input\n }],\n state: [{\n type: Input\n }],\n info: [{\n type: Input\n }],\n relativeTo: [{\n type: Input\n }],\n preserveFragment: [{\n type: Input,\n args: [{\n transform: booleanAttribute\n }]\n }],\n skipLocationChange: [{\n type: Input,\n args: [{\n transform: booleanAttribute\n }]\n }],\n replaceUrl: [{\n type: Input,\n args: [{\n transform: booleanAttribute\n }]\n }],\n routerLink: [{\n type: Input\n }],\n onClick: [{\n type: HostListener,\n args: ['click', ['$event.button', '$event.ctrlKey', '$event.shiftKey', '$event.altKey', '$event.metaKey']]\n }]\n });\n})();\n\n/**\n *\n * @description\n *\n * Tracks whether the linked route of an element is currently active, and allows you\n * to specify one or more CSS classes to add to the element when the linked route\n * is active.\n *\n * Use this directive to create a visual distinction for elements associated with an active route.\n * For example, the following code highlights the word \"Bob\" when the router\n * activates the associated route:\n *\n * ```html\n * <a routerLink=\"/user/bob\" routerLinkActive=\"active-link\">Bob</a>\n * ```\n *\n * Whenever the URL is either '/user' or '/user/bob', the \"active-link\" class is\n * added to the anchor tag. If the URL changes, the class is removed.\n *\n * You can set more than one class using a space-separated string or an array.\n * For example:\n *\n * ```html\n * <a routerLink=\"/user/bob\" routerLinkActive=\"class1 class2\">Bob</a>\n * <a routerLink=\"/user/bob\" [routerLinkActive]=\"['class1', 'class2']\">Bob</a>\n * ```\n *\n * To add the classes only when the URL matches the link exactly, add the option `exact: true`:\n *\n * ```html\n * <a routerLink=\"/user/bob\" routerLinkActive=\"active-link\" [routerLinkActiveOptions]=\"{exact:\n * true}\">Bob</a>\n * ```\n *\n * To directly check the `isActive` status of the link, assign the `RouterLinkActive`\n * instance to a template variable.\n * For example, the following checks the status without assigning any CSS classes:\n *\n * ```html\n * <a routerLink=\"/user/bob\" routerLinkActive #rla=\"routerLinkActive\">\n * Bob {{ rla.isActive ? '(already open)' : ''}}\n * </a>\n * ```\n *\n * You can apply the `RouterLinkActive` directive to an ancestor of linked elements.\n * For example, the following sets the active-link class on the `<div>` parent tag\n * when the URL is either '/user/jim' or '/user/bob'.\n *\n * ```html\n * <div routerLinkActive=\"active-link\" [routerLinkActiveOptions]=\"{exact: true}\">\n * <a routerLink=\"/user/jim\">Jim</a>\n * <a routerLink=\"/user/bob\">Bob</a>\n * </div>\n * ```\n *\n * The `RouterLinkActive` directive can also be used to set the aria-current attribute\n * to provide an alternative distinction for active elements to visually impaired users.\n *\n * For example, the following code adds the 'active' class to the Home Page link when it is\n * indeed active and in such case also sets its aria-current attribute to 'page':\n *\n * ```html\n * <a routerLink=\"/\" routerLinkActive=\"active\" ariaCurrentWhenActive=\"page\">Home Page</a>\n * ```\n *\n * @ngModule RouterModule\n *\n * @publicApi\n */\nclass RouterLinkActive {\n router;\n element;\n renderer;\n cdr;\n link;\n links;\n classes = [];\n routerEventsSubscription;\n linkInputChangesSubscription;\n _isActive = false;\n get isActive() {\n return this._isActive;\n }\n /**\n * Options to configure how to determine if the router link is active.\n *\n * These options are passed to the `Router.isActive()` function.\n *\n * @see {@link Router#isActive}\n */\n routerLinkActiveOptions = {\n exact: false\n };\n /**\n * Aria-current attribute to apply when the router link is active.\n *\n * Possible values: `'page'` | `'step'` | `'location'` | `'date'` | `'time'` | `true` | `false`.\n *\n * @see {@link https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-current}\n */\n ariaCurrentWhenActive;\n /**\n *\n * You can use the output `isActiveChange` to get notified each time the link becomes\n * active or inactive.\n *\n * Emits:\n * true -> Route is active\n * false -> Route is inactive\n *\n * ```html\n * <a\n * routerLink=\"/user/bob\"\n * routerLinkActive=\"active-link\"\n * (isActiveChange)=\"this.onRouterLinkActive($event)\">Bob</a>\n * ```\n */\n isActiveChange = new EventEmitter();\n constructor(router, element, renderer, cdr, link) {\n this.router = router;\n this.element = element;\n this.renderer = renderer;\n this.cdr = cdr;\n this.link = link;\n this.routerEventsSubscription = router.events.subscribe(s => {\n if (s instanceof NavigationEnd) {\n this.update();\n }\n });\n }\n /** @nodoc */\n ngAfterContentInit() {\n // `of(null)` is used to force subscribe body to execute once immediately (like `startWith`).\n of(this.links.changes, of(null)).pipe(mergeAll()).subscribe(_ => {\n this.update();\n this.subscribeToEachLinkOnChanges();\n });\n }\n subscribeToEachLinkOnChanges() {\n this.linkInputChangesSubscription?.unsubscribe();\n const allLinkChanges = [...this.links.toArray(), this.link].filter(link => !!link).map(link => link.onChanges);\n this.linkInputChangesSubscription = from(allLinkChanges).pipe(mergeAll()).subscribe(link => {\n if (this._isActive !== this.isLinkActive(this.router)(link)) {\n this.update();\n }\n });\n }\n set routerLinkActive(data) {\n const classes = Array.isArray(data) ? data : data.split(' ');\n this.classes = classes.filter(c => !!c);\n }\n /** @nodoc */\n ngOnChanges(changes) {\n this.update();\n }\n /** @nodoc */\n ngOnDestroy() {\n this.routerEventsSubscription.unsubscribe();\n this.linkInputChangesSubscription?.unsubscribe();\n }\n update() {\n if (!this.links || !this.router.navigated) return;\n queueMicrotask(() => {\n const hasActiveLinks = this.hasActiveLinks();\n this.classes.forEach(c => {\n if (hasActiveLinks) {\n this.renderer.addClass(this.element.nativeElement, c);\n } else {\n this.renderer.removeClass(this.element.nativeElement, c);\n }\n });\n if (hasActiveLinks && this.ariaCurrentWhenActive !== undefined) {\n this.renderer.setAttribute(this.element.nativeElement, 'aria-current', this.ariaCurrentWhenActive.toString());\n } else {\n this.renderer.removeAttribute(this.element.nativeElement, 'aria-current');\n }\n // Only emit change if the active state changed.\n if (this._isActive !== hasActiveLinks) {\n this._isActive = hasActiveLinks;\n this.cdr.markForCheck();\n // Emit on isActiveChange after classes are updated\n this.isActiveChange.emit(hasActiveLinks);\n }\n });\n }\n isLinkActive(router) {\n const options = isActiveMatchOptions(this.routerLinkActiveOptions) ? this.routerLinkActiveOptions :\n // While the types should disallow `undefined` here, it's possible without strict inputs\n this.routerLinkActiveOptions.exact || false;\n return link => {\n const urlTree = link.urlTree;\n return urlTree ? router.isActive(urlTree, options) : false;\n };\n }\n hasActiveLinks() {\n const isActiveCheckFn = this.isLinkActive(this.router);\n return this.link && isActiveCheckFn(this.link) || this.links.some(isActiveCheckFn);\n }\n static ɵfac = function RouterLinkActive_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RouterLinkActive)(i0.ɵɵdirectiveInject(Router), i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef), i0.ɵɵdirectiveInject(RouterLink, 8));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: RouterLinkActive,\n selectors: [[\"\", \"routerLinkActive\", \"\"]],\n contentQueries: function RouterLinkActive_ContentQueries(rf, ctx, dirIndex) {\n if (rf & 1) {\n i0.ɵɵcontentQuery(dirIndex, RouterLink, 5);\n }\n if (rf & 2) {\n let _t;\n i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.links = _t);\n }\n },\n inputs: {\n routerLinkActiveOptions: \"routerLinkActiveOptions\",\n ariaCurrentWhenActive: \"ariaCurrentWhenActive\",\n routerLinkActive: \"routerLinkActive\"\n },\n outputs: {\n isActiveChange: \"isActiveChange\"\n },\n exportAs: [\"routerLinkActive\"],\n features: [i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouterLinkActive, [{\n type: Directive,\n args: [{\n selector: '[routerLinkActive]',\n exportAs: 'routerLinkActive'\n }]\n }], () => [{\n type: Router\n }, {\n type: i0.ElementRef\n }, {\n type: i0.Renderer2\n }, {\n type: i0.ChangeDetectorRef\n }, {\n type: RouterLink,\n decorators: [{\n type: Optional\n }]\n }], {\n links: [{\n type: ContentChildren,\n args: [RouterLink, {\n descendants: true\n }]\n }],\n routerLinkActiveOptions: [{\n type: Input\n }],\n ariaCurrentWhenActive: [{\n type: Input\n }],\n isActiveChange: [{\n type: Output\n }],\n routerLinkActive: [{\n type: Input\n }]\n });\n})();\n/**\n * Use instead of `'paths' in options` to be compatible with property renaming\n */\nfunction isActiveMatchOptions(options) {\n return !!options.paths;\n}\n\n/**\n * @description\n *\n * Provides a preloading strategy.\n *\n * @publicApi\n */\nclass PreloadingStrategy {}\n/**\n * @description\n *\n * Provides a preloading strategy that preloads all modules as quickly as possible.\n *\n * ```ts\n * RouterModule.forRoot(ROUTES, {preloadingStrategy: PreloadAllModules})\n * ```\n *\n * @publicApi\n */\nclass PreloadAllModules {\n preload(route, fn) {\n return fn().pipe(catchError(() => of(null)));\n }\n static ɵfac = function PreloadAllModules_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || PreloadAllModules)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: PreloadAllModules,\n factory: PreloadAllModules.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PreloadAllModules, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n/**\n * @description\n *\n * Provides a preloading strategy that does not preload any modules.\n *\n * This strategy is enabled by default.\n *\n * @publicApi\n */\nclass NoPreloading {\n preload(route, fn) {\n return of(null);\n }\n static ɵfac = function NoPreloading_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NoPreloading)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: NoPreloading,\n factory: NoPreloading.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NoPreloading, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n/**\n * The preloader optimistically loads all router configurations to\n * make navigations into lazily-loaded sections of the application faster.\n *\n * The preloader runs in the background. When the router bootstraps, the preloader\n * starts listening to all navigation events. After every such event, the preloader\n * will check if any configurations can be loaded lazily.\n *\n * If a route is protected by `canLoad` guards, the preloaded will not load it.\n *\n * @publicApi\n */\nclass RouterPreloader {\n router;\n injector;\n preloadingStrategy;\n loader;\n subscription;\n constructor(router, compiler, injector, preloadingStrategy, loader) {\n this.router = router;\n this.injector = injector;\n this.preloadingStrategy = preloadingStrategy;\n this.loader = loader;\n }\n setUpPreloading() {\n this.subscription = this.router.events.pipe(filter(e => e instanceof NavigationEnd), concatMap(() => this.preload())).subscribe(() => {});\n }\n preload() {\n return this.processRoutes(this.injector, this.router.config);\n }\n /** @nodoc */\n ngOnDestroy() {\n if (this.subscription) {\n this.subscription.unsubscribe();\n }\n }\n processRoutes(injector, routes) {\n const res = [];\n for (const route of routes) {\n if (route.providers && !route._injector) {\n route._injector = createEnvironmentInjector(route.providers, injector, `Route: ${route.path}`);\n }\n const injectorForCurrentRoute = route._injector ?? injector;\n const injectorForChildren = route._loadedInjector ?? injectorForCurrentRoute;\n // Note that `canLoad` is only checked as a condition that prevents `loadChildren` and not\n // `loadComponent`. `canLoad` guards only block loading of child routes by design. This\n // happens as a consequence of needing to descend into children for route matching immediately\n // while component loading is deferred until route activation. Because `canLoad` guards can\n // have side effects, we cannot execute them here so we instead skip preloading altogether\n // when present. Lastly, it remains to be decided whether `canLoad` should behave this way\n // at all. Code splitting and lazy loading is separate from client-side authorization checks\n // and should not be used as a security measure to prevent loading of code.\n if (route.loadChildren && !route._loadedRoutes && route.canLoad === undefined || route.loadComponent && !route._loadedComponent) {\n res.push(this.preloadConfig(injectorForCurrentRoute, route));\n }\n if (route.children || route._loadedRoutes) {\n res.push(this.processRoutes(injectorForChildren, route.children ?? route._loadedRoutes));\n }\n }\n return from(res).pipe(mergeAll());\n }\n preloadConfig(injector, route) {\n return this.preloadingStrategy.preload(route, () => {\n let loadedChildren$;\n if (route.loadChildren && route.canLoad === undefined) {\n loadedChildren$ = this.loader.loadChildren(injector, route);\n } else {\n loadedChildren$ = of(null);\n }\n const recursiveLoadChildren$ = loadedChildren$.pipe(mergeMap(config => {\n if (config === null) {\n return of(void 0);\n }\n route._loadedRoutes = config.routes;\n route._loadedInjector = config.injector;\n // If the loaded config was a module, use that as the module/module injector going\n // forward. Otherwise, continue using the current module/module injector.\n return this.processRoutes(config.injector ?? injector, config.routes);\n }));\n if (route.loadComponent && !route._loadedComponent) {\n const loadComponent$ = this.loader.loadComponent(route);\n return from([recursiveLoadChildren$, loadComponent$]).pipe(mergeAll());\n } else {\n return recursiveLoadChildren$;\n }\n });\n }\n static ɵfac = function RouterPreloader_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RouterPreloader)(i0.ɵɵinject(Router), i0.ɵɵinject(i0.Compiler), i0.ɵɵinject(i0.EnvironmentInjector), i0.ɵɵinject(PreloadingStrategy), i0.ɵɵinject(RouterConfigLoader));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: RouterPreloader,\n factory: RouterPreloader.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouterPreloader, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], () => [{\n type: Router\n }, {\n type: i0.Compiler\n }, {\n type: i0.EnvironmentInjector\n }, {\n type: PreloadingStrategy\n }, {\n type: RouterConfigLoader\n }], null);\n})();\nconst ROUTER_SCROLLER = new InjectionToken('');\nclass RouterScroller {\n urlSerializer;\n transitions;\n viewportScroller;\n zone;\n options;\n routerEventsSubscription;\n scrollEventsSubscription;\n lastId = 0;\n lastSource = 'imperative';\n restoredId = 0;\n store = {};\n /** @nodoc */\n constructor(urlSerializer, transitions, viewportScroller, zone, options = {}) {\n this.urlSerializer = urlSerializer;\n this.transitions = transitions;\n this.viewportScroller = viewportScroller;\n this.zone = zone;\n this.options = options;\n // Default both options to 'disabled'\n options.scrollPositionRestoration ||= 'disabled';\n options.anchorScrolling ||= 'disabled';\n }\n init() {\n // we want to disable the automatic scrolling because having two places\n // responsible for scrolling results race conditions, especially given\n // that browser don't implement this behavior consistently\n if (this.options.scrollPositionRestoration !== 'disabled') {\n this.viewportScroller.setHistoryScrollRestoration('manual');\n }\n this.routerEventsSubscription = this.createScrollEvents();\n this.scrollEventsSubscription = this.consumeScrollEvents();\n }\n createScrollEvents() {\n return this.transitions.events.subscribe(e => {\n if (e instanceof NavigationStart) {\n // store the scroll position of the current stable navigations.\n this.store[this.lastId] = this.viewportScroller.getScrollPosition();\n this.lastSource = e.navigationTrigger;\n this.restoredId = e.restoredState ? e.restoredState.navigationId : 0;\n } else if (e instanceof NavigationEnd) {\n this.lastId = e.id;\n this.scheduleScrollEvent(e, this.urlSerializer.parse(e.urlAfterRedirects).fragment);\n } else if (e instanceof NavigationSkipped && e.code === NavigationSkippedCode.IgnoredSameUrlNavigation) {\n this.lastSource = undefined;\n this.restoredId = 0;\n this.scheduleScrollEvent(e, this.urlSerializer.parse(e.url).fragment);\n }\n });\n }\n consumeScrollEvents() {\n return this.transitions.events.subscribe(e => {\n if (!(e instanceof Scroll)) return;\n // a popstate event. The pop state event will always ignore anchor scrolling.\n if (e.position) {\n if (this.options.scrollPositionRestoration === 'top') {\n this.viewportScroller.scrollToPosition([0, 0]);\n } else if (this.options.scrollPositionRestoration === 'enabled') {\n this.viewportScroller.scrollToPosition(e.position);\n }\n // imperative navigation \"forward\"\n } else {\n if (e.anchor && this.options.anchorScrolling === 'enabled') {\n this.viewportScroller.scrollToAnchor(e.anchor);\n } else if (this.options.scrollPositionRestoration !== 'disabled') {\n this.viewportScroller.scrollToPosition([0, 0]);\n }\n }\n });\n }\n scheduleScrollEvent(routerEvent, anchor) {\n this.zone.runOutsideAngular(() => {\n // The scroll event needs to be delayed until after change detection. Otherwise, we may\n // attempt to restore the scroll position before the router outlet has fully rendered the\n // component by executing its update block of the template function.\n setTimeout(() => {\n this.zone.run(() => {\n this.transitions.events.next(new Scroll(routerEvent, this.lastSource === 'popstate' ? this.store[this.restoredId] : null, anchor));\n });\n }, 0);\n });\n }\n /** @nodoc */\n ngOnDestroy() {\n this.routerEventsSubscription?.unsubscribe();\n this.scrollEventsSubscription?.unsubscribe();\n }\n static ɵfac = function RouterScroller_Factory(__ngFactoryType__) {\n i0.ɵɵinvalidFactory();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: RouterScroller,\n factory: RouterScroller.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouterScroller, [{\n type: Injectable\n }], () => [{\n type: UrlSerializer\n }, {\n type: NavigationTransitions\n }, {\n type: i3.ViewportScroller\n }, {\n type: i0.NgZone\n }, {\n type: undefined\n }], null);\n})();\n\n/**\n * Sets up providers necessary to enable `Router` functionality for the application.\n * Allows to configure a set of routes as well as extra features that should be enabled.\n *\n * @usageNotes\n *\n * Basic example of how you can add a Router to your application:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent, {\n * providers: [provideRouter(appRoutes)]\n * });\n * ```\n *\n * You can also enable optional features in the Router by adding functions from the `RouterFeatures`\n * type:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes,\n * withDebugTracing(),\n * withRouterConfig({paramsInheritanceStrategy: 'always'}))\n * ]\n * }\n * );\n * ```\n *\n * @see {@link RouterFeatures}\n *\n * @publicApi\n * @param routes A set of `Route`s to use for the application routing table.\n * @param features Optional features to configure additional router behaviors.\n * @returns A set of providers to setup a Router.\n */\nfunction provideRouter(routes, ...features) {\n return makeEnvironmentProviders([{\n provide: ROUTES,\n multi: true,\n useValue: routes\n }, typeof ngDevMode === 'undefined' || ngDevMode ? {\n provide: ROUTER_IS_PROVIDED,\n useValue: true\n } : [], {\n provide: ActivatedRoute,\n useFactory: rootRoute,\n deps: [Router]\n }, {\n provide: APP_BOOTSTRAP_LISTENER,\n multi: true,\n useFactory: getBootstrapListener\n }, features.map(feature => feature.ɵproviders)]);\n}\nfunction rootRoute(router) {\n return router.routerState.root;\n}\n/**\n * Helper function to create an object that represents a Router feature.\n */\nfunction routerFeature(kind, providers) {\n return {\n ɵkind: kind,\n ɵproviders: providers\n };\n}\n/**\n * An Injection token used to indicate whether `provideRouter` or `RouterModule.forRoot` was ever\n * called.\n */\nconst ROUTER_IS_PROVIDED = new InjectionToken('', {\n providedIn: 'root',\n factory: () => false\n});\nconst routerIsProvidedDevModeCheck = {\n provide: ENVIRONMENT_INITIALIZER,\n multi: true,\n useFactory() {\n return () => {\n if (!inject(ROUTER_IS_PROVIDED)) {\n console.warn('`provideRoutes` was called without `provideRouter` or `RouterModule.forRoot`. ' + 'This is likely a mistake.');\n }\n };\n }\n};\n/**\n * Registers a DI provider for a set of routes.\n * @param routes The route configuration to provide.\n *\n * @usageNotes\n *\n * ```ts\n * @NgModule({\n * providers: [provideRoutes(ROUTES)]\n * })\n * class LazyLoadedChildModule {}\n * ```\n *\n * @deprecated If necessary, provide routes using the `ROUTES` `InjectionToken`.\n * @see {@link ROUTES}\n * @publicApi\n */\nfunction provideRoutes(routes) {\n return [{\n provide: ROUTES,\n multi: true,\n useValue: routes\n }, typeof ngDevMode === 'undefined' || ngDevMode ? routerIsProvidedDevModeCheck : []];\n}\n/**\n * Enables customizable scrolling behavior for router navigations.\n *\n * @usageNotes\n *\n * Basic example of how you can enable scrolling feature:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withInMemoryScrolling())\n * ]\n * }\n * );\n * ```\n *\n * @see {@link provideRouter}\n * @see {@link ViewportScroller}\n *\n * @publicApi\n * @param options Set of configuration parameters to customize scrolling behavior, see\n * `InMemoryScrollingOptions` for additional information.\n * @returns A set of providers for use with `provideRouter`.\n */\nfunction withInMemoryScrolling(options = {}) {\n const providers = [{\n provide: ROUTER_SCROLLER,\n useFactory: () => {\n const viewportScroller = inject(ViewportScroller);\n const zone = inject(NgZone);\n const transitions = inject(NavigationTransitions);\n const urlSerializer = inject(UrlSerializer);\n return new RouterScroller(urlSerializer, transitions, viewportScroller, zone, options);\n }\n }];\n return routerFeature(4 /* RouterFeatureKind.InMemoryScrollingFeature */, providers);\n}\nfunction getBootstrapListener() {\n const injector = inject(Injector);\n return bootstrappedComponentRef => {\n const ref = injector.get(ApplicationRef);\n if (bootstrappedComponentRef !== ref.components[0]) {\n return;\n }\n const router = injector.get(Router);\n const bootstrapDone = injector.get(BOOTSTRAP_DONE);\n if (injector.get(INITIAL_NAVIGATION) === 1 /* InitialNavigation.EnabledNonBlocking */) {\n router.initialNavigation();\n }\n injector.get(ROUTER_PRELOADER, null, InjectFlags.Optional)?.setUpPreloading();\n injector.get(ROUTER_SCROLLER, null, InjectFlags.Optional)?.init();\n router.resetRootComponentType(ref.componentTypes[0]);\n if (!bootstrapDone.closed) {\n bootstrapDone.next();\n bootstrapDone.complete();\n bootstrapDone.unsubscribe();\n }\n };\n}\n/**\n * A subject used to indicate that the bootstrapping phase is done. When initial navigation is\n * `enabledBlocking`, the first navigation waits until bootstrapping is finished before continuing\n * to the activation phase.\n */\nconst BOOTSTRAP_DONE = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'bootstrap done indicator' : '', {\n factory: () => {\n return new Subject();\n }\n});\nconst INITIAL_NAVIGATION = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'initial navigation' : '', {\n providedIn: 'root',\n factory: () => 1 /* InitialNavigation.EnabledNonBlocking */\n});\n/**\n * Configures initial navigation to start before the root component is created.\n *\n * The bootstrap is blocked until the initial navigation is complete. This should be set in case\n * you use [server-side rendering](guide/ssr), but do not enable [hydration](guide/hydration) for\n * your application.\n *\n * @usageNotes\n *\n * Basic example of how you can enable this navigation behavior:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withEnabledBlockingInitialNavigation())\n * ]\n * }\n * );\n * ```\n *\n * @see {@link provideRouter}\n *\n * @publicApi\n * @returns A set of providers for use with `provideRouter`.\n */\nfunction withEnabledBlockingInitialNavigation() {\n const providers = [{\n provide: INITIAL_NAVIGATION,\n useValue: 0 /* InitialNavigation.EnabledBlocking */\n }, {\n provide: APP_INITIALIZER,\n multi: true,\n deps: [Injector],\n useFactory: injector => {\n const locationInitialized = injector.get(LOCATION_INITIALIZED, Promise.resolve());\n return () => {\n return locationInitialized.then(() => {\n return new Promise(resolve => {\n const router = injector.get(Router);\n const bootstrapDone = injector.get(BOOTSTRAP_DONE);\n afterNextNavigation(router, () => {\n // Unblock APP_INITIALIZER in case the initial navigation was canceled or errored\n // without a redirect.\n resolve(true);\n });\n injector.get(NavigationTransitions).afterPreactivation = () => {\n // Unblock APP_INITIALIZER once we get to `afterPreactivation`. At this point, we\n // assume activation will complete successfully (even though this is not\n // guaranteed).\n resolve(true);\n return bootstrapDone.closed ? of(void 0) : bootstrapDone;\n };\n router.initialNavigation();\n });\n });\n };\n }\n }];\n return routerFeature(2 /* RouterFeatureKind.EnabledBlockingInitialNavigationFeature */, providers);\n}\n/**\n * Disables initial navigation.\n *\n * Use if there is a reason to have more control over when the router starts its initial navigation\n * due to some complex initialization logic.\n *\n * @usageNotes\n *\n * Basic example of how you can disable initial navigation:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withDisabledInitialNavigation())\n * ]\n * }\n * );\n * ```\n *\n * @see {@link provideRouter}\n *\n * @returns A set of providers for use with `provideRouter`.\n *\n * @publicApi\n */\nfunction withDisabledInitialNavigation() {\n const providers = [{\n provide: APP_INITIALIZER,\n multi: true,\n useFactory: () => {\n const router = inject(Router);\n return () => {\n router.setUpLocationChangeListener();\n };\n }\n }, {\n provide: INITIAL_NAVIGATION,\n useValue: 2 /* InitialNavigation.Disabled */\n }];\n return routerFeature(3 /* RouterFeatureKind.DisabledInitialNavigationFeature */, providers);\n}\n/**\n * Enables logging of all internal navigation events to the console.\n * Extra logging might be useful for debugging purposes to inspect Router event sequence.\n *\n * @usageNotes\n *\n * Basic example of how you can enable debug tracing:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withDebugTracing())\n * ]\n * }\n * );\n * ```\n *\n * @see {@link provideRouter}\n *\n * @returns A set of providers for use with `provideRouter`.\n *\n * @publicApi\n */\nfunction withDebugTracing() {\n let providers = [];\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n providers = [{\n provide: ENVIRONMENT_INITIALIZER,\n multi: true,\n useFactory: () => {\n const router = inject(Router);\n return () => router.events.subscribe(e => {\n // tslint:disable:no-console\n console.group?.(`Router Event: ${e.constructor.name}`);\n console.log(stringifyEvent(e));\n console.log(e);\n console.groupEnd?.();\n // tslint:enable:no-console\n });\n }\n }];\n } else {\n providers = [];\n }\n return routerFeature(1 /* RouterFeatureKind.DebugTracingFeature */, providers);\n}\nconst ROUTER_PRELOADER = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'router preloader' : '');\n/**\n * Allows to configure a preloading strategy to use. The strategy is configured by providing a\n * reference to a class that implements a `PreloadingStrategy`.\n *\n * @usageNotes\n *\n * Basic example of how you can configure preloading:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withPreloading(PreloadAllModules))\n * ]\n * }\n * );\n * ```\n *\n * @see {@link provideRouter}\n *\n * @param preloadingStrategy A reference to a class that implements a `PreloadingStrategy` that\n * should be used.\n * @returns A set of providers for use with `provideRouter`.\n *\n * @publicApi\n */\nfunction withPreloading(preloadingStrategy) {\n const providers = [{\n provide: ROUTER_PRELOADER,\n useExisting: RouterPreloader\n }, {\n provide: PreloadingStrategy,\n useExisting: preloadingStrategy\n }];\n return routerFeature(0 /* RouterFeatureKind.PreloadingFeature */, providers);\n}\n/**\n * Allows to provide extra parameters to configure Router.\n *\n * @usageNotes\n *\n * Basic example of how you can provide extra configuration options:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withRouterConfig({\n * onSameUrlNavigation: 'reload'\n * }))\n * ]\n * }\n * );\n * ```\n *\n * @see {@link provideRouter}\n *\n * @param options A set of parameters to configure Router, see `RouterConfigOptions` for\n * additional information.\n * @returns A set of providers for use with `provideRouter`.\n *\n * @publicApi\n */\nfunction withRouterConfig(options) {\n const providers = [{\n provide: ROUTER_CONFIGURATION,\n useValue: options\n }];\n return routerFeature(5 /* RouterFeatureKind.RouterConfigurationFeature */, providers);\n}\n/**\n * Provides the location strategy that uses the URL fragment instead of the history API.\n *\n * @usageNotes\n *\n * Basic example of how you can use the hash location option:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withHashLocation())\n * ]\n * }\n * );\n * ```\n *\n * @see {@link provideRouter}\n * @see {@link /api/common/HashLocationStrategy HashLocationStrategy}\n *\n * @returns A set of providers for use with `provideRouter`.\n *\n * @publicApi\n */\nfunction withHashLocation() {\n const providers = [{\n provide: LocationStrategy,\n useClass: HashLocationStrategy\n }];\n return routerFeature(6 /* RouterFeatureKind.RouterHashLocationFeature */, providers);\n}\n/**\n * Provides a function which is called when a navigation error occurs.\n *\n * This function is run inside application's [injection context](guide/di/dependency-injection-context)\n * so you can use the [`inject`](api/core/inject) function.\n *\n * This function can return a `RedirectCommand` to convert the error to a redirect, similar to returning\n * a `UrlTree` or `RedirectCommand` from a guard. This will also prevent the `Router` from emitting\n * `NavigationError`; it will instead emit `NavigationCancel` with code NavigationCancellationCode.Redirect.\n * Return values other than `RedirectCommand` are ignored and do not change any behavior with respect to\n * how the `Router` handles the error.\n *\n * @usageNotes\n *\n * Basic example of how you can use the error handler option:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withNavigationErrorHandler((e: NavigationError) =>\n * inject(MyErrorTracker).trackError(e)))\n * ]\n * }\n * );\n * ```\n *\n * @see {@link NavigationError}\n * @see {@link /api/core/inject inject}\n * @see {@link runInInjectionContext}\n *\n * @returns A set of providers for use with `provideRouter`.\n *\n * @publicApi\n */\nfunction withNavigationErrorHandler(handler) {\n const providers = [{\n provide: NAVIGATION_ERROR_HANDLER,\n useValue: handler\n }];\n return routerFeature(7 /* RouterFeatureKind.NavigationErrorHandlerFeature */, providers);\n}\n/**\n * Enables binding information from the `Router` state directly to the inputs of the component in\n * `Route` configurations.\n *\n * @usageNotes\n *\n * Basic example of how you can enable the feature:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withComponentInputBinding())\n * ]\n * }\n * );\n * ```\n *\n * The router bindings information from any of the following sources:\n *\n * - query parameters\n * - path and matrix parameters\n * - static route data\n * - data from resolvers\n *\n * Duplicate keys are resolved in the same order from above, from least to greatest,\n * meaning that resolvers have the highest precedence and override any of the other information\n * from the route.\n *\n * Importantly, when an input does not have an item in the route data with a matching key, this\n * input is set to `undefined`. This prevents previous information from being\n * retained if the data got removed from the route (i.e. if a query parameter is removed).\n * Default values can be provided with a resolver on the route to ensure the value is always present\n * or an input and use an input transform in the component.\n *\n * @see {@link /guide/components/inputs#input-transforms Input Transforms}\n * @returns A set of providers for use with `provideRouter`.\n */\nfunction withComponentInputBinding() {\n const providers = [RoutedComponentInputBinder, {\n provide: INPUT_BINDER,\n useExisting: RoutedComponentInputBinder\n }];\n return routerFeature(8 /* RouterFeatureKind.ComponentInputBindingFeature */, providers);\n}\n/**\n * Enables view transitions in the Router by running the route activation and deactivation inside of\n * `document.startViewTransition`.\n *\n * Note: The View Transitions API is not available in all browsers. If the browser does not support\n * view transitions, the Router will not attempt to start a view transition and continue processing\n * the navigation as usual.\n *\n * @usageNotes\n *\n * Basic example of how you can enable the feature:\n * ```ts\n * const appRoutes: Routes = [];\n * bootstrapApplication(AppComponent,\n * {\n * providers: [\n * provideRouter(appRoutes, withViewTransitions())\n * ]\n * }\n * );\n * ```\n *\n * @returns A set of providers for use with `provideRouter`.\n * @see https://developer.chrome.com/docs/web-platform/view-transitions/\n * @see https://developer.mozilla.org/en-US/docs/Web/API/View_Transitions_API\n * @developerPreview\n */\nfunction withViewTransitions(options) {\n const providers = [{\n provide: CREATE_VIEW_TRANSITION,\n useValue: createViewTransition\n }, {\n provide: VIEW_TRANSITION_OPTIONS,\n useValue: {\n skipNextTransition: !!options?.skipInitialTransition,\n ...options\n }\n }];\n return routerFeature(9 /* RouterFeatureKind.ViewTransitionsFeature */, providers);\n}\n\n/**\n * The directives defined in the `RouterModule`.\n */\nconst ROUTER_DIRECTIVES = [RouterOutlet, RouterLink, RouterLinkActive, ɵEmptyOutletComponent];\n/**\n * @docsNotRequired\n */\nconst ROUTER_FORROOT_GUARD = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'router duplicate forRoot guard' : '');\n// TODO(atscott): All of these except `ActivatedRoute` are `providedIn: 'root'`. They are only kept\n// here to avoid a breaking change whereby the provider order matters based on where the\n// `RouterModule`/`RouterTestingModule` is imported. These can/should be removed as a \"breaking\"\n// change in a major version.\nconst ROUTER_PROVIDERS = [Location, {\n provide: UrlSerializer,\n useClass: DefaultUrlSerializer\n}, Router, ChildrenOutletContexts, {\n provide: ActivatedRoute,\n useFactory: rootRoute,\n deps: [Router]\n}, RouterConfigLoader,\n// Only used to warn when `provideRoutes` is used without `RouterModule` or `provideRouter`. Can\n// be removed when `provideRoutes` is removed.\ntypeof ngDevMode === 'undefined' || ngDevMode ? {\n provide: ROUTER_IS_PROVIDED,\n useValue: true\n} : []];\n/**\n * @description\n *\n * Adds directives and providers for in-app navigation among views defined in an application.\n * Use the Angular `Router` service to declaratively specify application states and manage state\n * transitions.\n *\n * You can import this NgModule multiple times, once for each lazy-loaded bundle.\n * However, only one `Router` service can be active.\n * To ensure this, there are two ways to register routes when importing this module:\n *\n * * The `forRoot()` method creates an `NgModule` that contains all the directives, the given\n * routes, and the `Router` service itself.\n * * The `forChild()` method creates an `NgModule` that contains all the directives and the given\n * routes, but does not include the `Router` service.\n *\n * @see [Routing and Navigation guide](guide/routing/common-router-tasks) for an\n * overview of how the `Router` service should be used.\n *\n * @publicApi\n */\nclass RouterModule {\n constructor() {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n inject(ROUTER_FORROOT_GUARD, {\n optional: true\n });\n }\n }\n /**\n * Creates and configures a module with all the router providers and directives.\n * Optionally sets up an application listener to perform an initial navigation.\n *\n * When registering the NgModule at the root, import as follows:\n *\n * ```ts\n * @NgModule({\n * imports: [RouterModule.forRoot(ROUTES)]\n * })\n * class MyNgModule {}\n * ```\n *\n * @param routes An array of `Route` objects that define the navigation paths for the application.\n * @param config An `ExtraOptions` configuration object that controls how navigation is performed.\n * @return The new `NgModule`.\n *\n */\n static forRoot(routes, config) {\n return {\n ngModule: RouterModule,\n providers: [ROUTER_PROVIDERS, typeof ngDevMode === 'undefined' || ngDevMode ? config?.enableTracing ? withDebugTracing().ɵproviders : [] : [], {\n provide: ROUTES,\n multi: true,\n useValue: routes\n }, typeof ngDevMode === 'undefined' || ngDevMode ? {\n provide: ROUTER_FORROOT_GUARD,\n useFactory: provideForRootGuard,\n deps: [[Router, new Optional(), new SkipSelf()]]\n } : [], config?.errorHandler ? {\n provide: NAVIGATION_ERROR_HANDLER,\n useValue: config.errorHandler\n } : [], {\n provide: ROUTER_CONFIGURATION,\n useValue: config ? config : {}\n }, config?.useHash ? provideHashLocationStrategy() : providePathLocationStrategy(), provideRouterScroller(), config?.preloadingStrategy ? withPreloading(config.preloadingStrategy).ɵproviders : [], config?.initialNavigation ? provideInitialNavigation(config) : [], config?.bindToComponentInputs ? withComponentInputBinding().ɵproviders : [], config?.enableViewTransitions ? withViewTransitions().ɵproviders : [], provideRouterInitializer()]\n };\n }\n /**\n * Creates a module with all the router directives and a provider registering routes,\n * without creating a new Router service.\n * When registering for submodules and lazy-loaded submodules, create the NgModule as follows:\n *\n * ```ts\n * @NgModule({\n * imports: [RouterModule.forChild(ROUTES)]\n * })\n * class MyNgModule {}\n * ```\n *\n * @param routes An array of `Route` objects that define the navigation paths for the submodule.\n * @return The new NgModule.\n *\n */\n static forChild(routes) {\n return {\n ngModule: RouterModule,\n providers: [{\n provide: ROUTES,\n multi: true,\n useValue: routes\n }]\n };\n }\n static ɵfac = function RouterModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RouterModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: RouterModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({});\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RouterModule, [{\n type: NgModule,\n args: [{\n imports: ROUTER_DIRECTIVES,\n exports: ROUTER_DIRECTIVES\n }]\n }], () => [], null);\n})();\n/**\n * For internal use by `RouterModule` only. Note that this differs from `withInMemoryRouterScroller`\n * because it reads from the `ExtraOptions` which should not be used in the standalone world.\n */\nfunction provideRouterScroller() {\n return {\n provide: ROUTER_SCROLLER,\n useFactory: () => {\n const viewportScroller = inject(ViewportScroller);\n const zone = inject(NgZone);\n const config = inject(ROUTER_CONFIGURATION);\n const transitions = inject(NavigationTransitions);\n const urlSerializer = inject(UrlSerializer);\n if (config.scrollOffset) {\n viewportScroller.setOffset(config.scrollOffset);\n }\n return new RouterScroller(urlSerializer, transitions, viewportScroller, zone, config);\n }\n };\n}\n// Note: For internal use only with `RouterModule`. Standalone setup via `provideRouter` should\n// provide hash location directly via `{provide: LocationStrategy, useClass: HashLocationStrategy}`.\nfunction provideHashLocationStrategy() {\n return {\n provide: LocationStrategy,\n useClass: HashLocationStrategy\n };\n}\n// Note: For internal use only with `RouterModule`. Standalone setup via `provideRouter` does not\n// need this at all because `PathLocationStrategy` is the default factory for `LocationStrategy`.\nfunction providePathLocationStrategy() {\n return {\n provide: LocationStrategy,\n useClass: PathLocationStrategy\n };\n}\nfunction provideForRootGuard(router) {\n if (router) {\n throw new ɵRuntimeError(4007 /* RuntimeErrorCode.FOR_ROOT_CALLED_TWICE */, `The Router was provided more than once. This can happen if 'forRoot' is used outside of the root injector.` + ` Lazy loaded modules should use RouterModule.forChild() instead.`);\n }\n return 'guarded';\n}\n// Note: For internal use only with `RouterModule`. Standalone router setup with `provideRouter`\n// users call `withXInitialNavigation` directly.\nfunction provideInitialNavigation(config) {\n return [config.initialNavigation === 'disabled' ? withDisabledInitialNavigation().ɵproviders : [], config.initialNavigation === 'enabledBlocking' ? withEnabledBlockingInitialNavigation().ɵproviders : []];\n}\n// TODO(atscott): This should not be in the public API\n/**\n * A DI token for the router initializer that\n * is called after the app is bootstrapped.\n *\n * @publicApi\n */\nconst ROUTER_INITIALIZER = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'Router Initializer' : '');\nfunction provideRouterInitializer() {\n return [\n // ROUTER_INITIALIZER token should be removed. It's public API but shouldn't be. We can just\n // have `getBootstrapListener` directly attached to APP_BOOTSTRAP_LISTENER.\n {\n provide: ROUTER_INITIALIZER,\n useFactory: getBootstrapListener\n }, {\n provide: APP_BOOTSTRAP_LISTENER,\n multi: true,\n useExisting: ROUTER_INITIALIZER\n }];\n}\n\n/**\n * Maps an array of injectable classes with canMatch functions to an array of equivalent\n * `CanMatchFn` for use in a `Route` definition.\n *\n * Usage {@example router/utils/functional_guards.ts region='CanActivate'}\n *\n * @publicApi\n * @see {@link Route}\n */\nfunction mapToCanMatch(providers) {\n return providers.map(provider => (...params) => inject(provider).canMatch(...params));\n}\n/**\n * Maps an array of injectable classes with canActivate functions to an array of equivalent\n * `CanActivateFn` for use in a `Route` definition.\n *\n * Usage {@example router/utils/functional_guards.ts region='CanActivate'}\n *\n * @publicApi\n * @see {@link Route}\n */\nfunction mapToCanActivate(providers) {\n return providers.map(provider => (...params) => inject(provider).canActivate(...params));\n}\n/**\n * Maps an array of injectable classes with canActivateChild functions to an array of equivalent\n * `CanActivateChildFn` for use in a `Route` definition.\n *\n * Usage {@example router/utils/functional_guards.ts region='CanActivate'}\n *\n * @publicApi\n * @see {@link Route}\n */\nfunction mapToCanActivateChild(providers) {\n return providers.map(provider => (...params) => inject(provider).canActivateChild(...params));\n}\n/**\n * Maps an array of injectable classes with canDeactivate functions to an array of equivalent\n * `CanDeactivateFn` for use in a `Route` definition.\n *\n * Usage {@example router/utils/functional_guards.ts region='CanActivate'}\n *\n * @publicApi\n * @see {@link Route}\n */\nfunction mapToCanDeactivate(providers) {\n return providers.map(provider => (...params) => inject(provider).canDeactivate(...params));\n}\n/**\n * Maps an injectable class with a resolve function to an equivalent `ResolveFn`\n * for use in a `Route` definition.\n *\n * Usage {@example router/utils/functional_guards.ts region='Resolve'}\n *\n * @publicApi\n * @see {@link Route}\n */\nfunction mapToResolve(provider) {\n return (...params) => inject(provider).resolve(...params);\n}\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the router package.\n */\n/**\n * @publicApi\n */\nconst VERSION = new Version('19.2.1');\nfunction getLoadedRoutes(route) {\n return route._loadedRoutes;\n}\nɵpublishExternalGlobalUtil('ɵgetLoadedRoutes', getLoadedRoutes);\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of this package.\n */\n// This file only reexports content of the `src` folder. Keep it that way.\n\n// This file is not used to build this module. It is only used during editing\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { ActivatedRoute, ActivatedRouteSnapshot, ActivationEnd, ActivationStart, BaseRouteReuseStrategy, ChildActivationEnd, ChildActivationStart, ChildrenOutletContexts, DefaultTitleStrategy, DefaultUrlSerializer, EventType, GuardsCheckEnd, GuardsCheckStart, NavigationCancel, NavigationCancellationCode, NavigationEnd, NavigationError, NavigationSkipped, NavigationSkippedCode, NavigationStart, NoPreloading, OutletContext, PRIMARY_OUTLET, PreloadAllModules, PreloadingStrategy, ROUTER_CONFIGURATION, ROUTER_INITIALIZER, ROUTER_OUTLET_DATA, ROUTES, RedirectCommand, ResolveEnd, ResolveStart, RouteConfigLoadEnd, RouteConfigLoadStart, RouteReuseStrategy, Router, RouterEvent, RouterLink, RouterLinkActive, RouterLink as RouterLinkWithHref, RouterModule, RouterOutlet, RouterPreloader, RouterState, RouterStateSnapshot, RoutesRecognized, Scroll, TitleStrategy, UrlHandlingStrategy, UrlSegment, UrlSegmentGroup, UrlSerializer, UrlTree, VERSION, convertToParamMap, createUrlTreeFromSnapshot, defaultUrlMatcher, mapToCanActivate, mapToCanActivateChild, mapToCanDeactivate, mapToCanMatch, mapToResolve, provideRouter, provideRoutes, withComponentInputBinding, withDebugTracing, withDisabledInitialNavigation, withEnabledBlockingInitialNavigation, withHashLocation, withInMemoryScrolling, withNavigationErrorHandler, withPreloading, withRouterConfig, withViewTransitions, ɵEmptyOutletComponent, ROUTER_PROVIDERS as ɵROUTER_PROVIDERS, afterNextNavigation as ɵafterNextNavigation, loadChildren as ɵloadChildren };\n","import * as i0 from '@angular/core';\nimport { Injectable, EventEmitter, InjectionToken, Inject, Directive, Input, Pipe, NgModule } from '@angular/core';\nimport { of, isObservable, forkJoin, concat, defer } from 'rxjs';\nimport { take, shareReplay, map, concatMap, switchMap } from 'rxjs/operators';\nclass TranslateLoader {}\n/**\n * This loader is just a placeholder that does nothing, in case you don't need a loader at all\n */\nclass TranslateFakeLoader extends TranslateLoader {\n getTranslation(lang) {\n return of({});\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵTranslateFakeLoader_BaseFactory;\n return function TranslateFakeLoader_Factory(__ngFactoryType__) {\n return (ɵTranslateFakeLoader_BaseFactory || (ɵTranslateFakeLoader_BaseFactory = i0.ɵɵgetInheritedFactory(TranslateFakeLoader)))(__ngFactoryType__ || TranslateFakeLoader);\n };\n })();\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: TranslateFakeLoader,\n factory: TranslateFakeLoader.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TranslateFakeLoader, [{\n type: Injectable\n }], null, null);\n})();\nclass MissingTranslationHandler {}\n/**\n * This handler is just a placeholder that does nothing, in case you don't need a missing translation handler at all\n */\nclass FakeMissingTranslationHandler {\n handle(params) {\n return params.key;\n }\n static ɵfac = function FakeMissingTranslationHandler_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FakeMissingTranslationHandler)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: FakeMissingTranslationHandler,\n factory: FakeMissingTranslationHandler.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FakeMissingTranslationHandler, [{\n type: Injectable\n }], null, null);\n})();\n\n/* tslint:disable */\n/**\n * Determines if two objects or two values are equivalent.\n *\n * Two objects or values are considered equivalent if at least one of the following is true:\n *\n * * Both objects or values pass `===` comparison.\n * * Both objects or values are of the same type and all of their properties are equal by\n * comparing them with `equals`.\n *\n * @param o1 Object or value to compare.\n * @param o2 Object or value to compare.\n * @returns true if arguments are equal.\n */\nfunction equals(o1, o2) {\n if (o1 === o2) return true;\n if (o1 === null || o2 === null) return false;\n if (o1 !== o1 && o2 !== o2) return true; // NaN === NaN\n let t1 = typeof o1,\n t2 = typeof o2,\n length,\n key,\n keySet;\n if (t1 == t2 && t1 == 'object') {\n if (Array.isArray(o1)) {\n if (!Array.isArray(o2)) return false;\n if ((length = o1.length) == o2.length) {\n for (key = 0; key < length; key++) {\n if (!equals(o1[key], o2[key])) return false;\n }\n return true;\n }\n } else {\n if (Array.isArray(o2)) {\n return false;\n }\n keySet = Object.create(null);\n for (key in o1) {\n if (!equals(o1[key], o2[key])) {\n return false;\n }\n keySet[key] = true;\n }\n for (key in o2) {\n if (!(key in keySet) && typeof o2[key] !== 'undefined') {\n return false;\n }\n }\n return true;\n }\n }\n return false;\n}\n/* tslint:enable */\nfunction isDefined(value) {\n return typeof value !== 'undefined' && value !== null;\n}\nfunction isObject(item) {\n return item && typeof item === 'object' && !Array.isArray(item);\n}\nfunction mergeDeep(target, source) {\n let output = Object.assign({}, target);\n if (isObject(target) && isObject(source)) {\n Object.keys(source).forEach(key => {\n if (isObject(source[key])) {\n if (!(key in target)) {\n Object.assign(output, {\n [key]: source[key]\n });\n } else {\n output[key] = mergeDeep(target[key], source[key]);\n }\n } else {\n Object.assign(output, {\n [key]: source[key]\n });\n }\n });\n }\n return output;\n}\nclass TranslateParser {}\nclass TranslateDefaultParser extends TranslateParser {\n templateMatcher = /{{\\s?([^{}\\s]*)\\s?}}/g;\n interpolate(expr, params) {\n let result;\n if (typeof expr === 'string') {\n result = this.interpolateString(expr, params);\n } else if (typeof expr === 'function') {\n result = this.interpolateFunction(expr, params);\n } else {\n // this should not happen, but an unrelated TranslateService test depends on it\n result = expr;\n }\n return result;\n }\n getValue(target, key) {\n let keys = typeof key === 'string' ? key.split('.') : [key];\n key = '';\n do {\n key += keys.shift();\n if (isDefined(target) && isDefined(target[key]) && (typeof target[key] === 'object' || !keys.length)) {\n target = target[key];\n key = '';\n } else if (!keys.length) {\n target = undefined;\n } else {\n key += '.';\n }\n } while (keys.length);\n return target;\n }\n interpolateFunction(fn, params) {\n return fn(params);\n }\n interpolateString(expr, params) {\n if (!params) {\n return expr;\n }\n return expr.replace(this.templateMatcher, (substring, b) => {\n let r = this.getValue(params, b);\n return isDefined(r) ? r : substring;\n });\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵTranslateDefaultParser_BaseFactory;\n return function TranslateDefaultParser_Factory(__ngFactoryType__) {\n return (ɵTranslateDefaultParser_BaseFactory || (ɵTranslateDefaultParser_BaseFactory = i0.ɵɵgetInheritedFactory(TranslateDefaultParser)))(__ngFactoryType__ || TranslateDefaultParser);\n };\n })();\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: TranslateDefaultParser,\n factory: TranslateDefaultParser.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TranslateDefaultParser, [{\n type: Injectable\n }], null, null);\n})();\nclass TranslateCompiler {}\n/**\n * This compiler is just a placeholder that does nothing, in case you don't need a compiler at all\n */\nclass TranslateFakeCompiler extends TranslateCompiler {\n compile(value, lang) {\n return value;\n }\n compileTranslations(translations, lang) {\n return translations;\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵTranslateFakeCompiler_BaseFactory;\n return function TranslateFakeCompiler_Factory(__ngFactoryType__) {\n return (ɵTranslateFakeCompiler_BaseFactory || (ɵTranslateFakeCompiler_BaseFactory = i0.ɵɵgetInheritedFactory(TranslateFakeCompiler)))(__ngFactoryType__ || TranslateFakeCompiler);\n };\n })();\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: TranslateFakeCompiler,\n factory: TranslateFakeCompiler.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TranslateFakeCompiler, [{\n type: Injectable\n }], null, null);\n})();\nclass TranslateStore {\n /**\n * The default lang to fallback when translations are missing on the current lang\n */\n defaultLang;\n /**\n * The lang currently used\n */\n currentLang = this.defaultLang;\n /**\n * a list of translations per lang\n */\n translations = {};\n /**\n * an array of langs\n */\n langs = [];\n /**\n * An EventEmitter to listen to translation change events\n * onTranslationChange.subscribe((params: TranslationChangeEvent) => {\n * // do something\n * });\n */\n onTranslationChange = new EventEmitter();\n /**\n * An EventEmitter to listen to lang change events\n * onLangChange.subscribe((params: LangChangeEvent) => {\n * // do something\n * });\n */\n onLangChange = new EventEmitter();\n /**\n * An EventEmitter to listen to default lang change events\n * onDefaultLangChange.subscribe((params: DefaultLangChangeEvent) => {\n * // do something\n * });\n */\n onDefaultLangChange = new EventEmitter();\n}\nconst USE_STORE = new InjectionToken('USE_STORE');\nconst USE_DEFAULT_LANG = new InjectionToken('USE_DEFAULT_LANG');\nconst DEFAULT_LANGUAGE = new InjectionToken('DEFAULT_LANGUAGE');\nconst USE_EXTEND = new InjectionToken('USE_EXTEND');\nclass TranslateService {\n store;\n currentLoader;\n compiler;\n parser;\n missingTranslationHandler;\n useDefaultLang;\n isolate;\n extend;\n loadingTranslations;\n pending = false;\n _onTranslationChange = new EventEmitter();\n _onLangChange = new EventEmitter();\n _onDefaultLangChange = new EventEmitter();\n _defaultLang;\n _currentLang;\n _langs = [];\n _translations = {};\n _translationRequests = {};\n /**\n * An EventEmitter to listen to translation change events\n * onTranslationChange.subscribe((params: TranslationChangeEvent) => {\n * // do something\n * });\n */\n get onTranslationChange() {\n return this.isolate ? this._onTranslationChange : this.store.onTranslationChange;\n }\n /**\n * An EventEmitter to listen to lang change events\n * onLangChange.subscribe((params: LangChangeEvent) => {\n * // do something\n * });\n */\n get onLangChange() {\n return this.isolate ? this._onLangChange : this.store.onLangChange;\n }\n /**\n * An EventEmitter to listen to default lang change events\n * onDefaultLangChange.subscribe((params: DefaultLangChangeEvent) => {\n * // do something\n * });\n */\n get onDefaultLangChange() {\n return this.isolate ? this._onDefaultLangChange : this.store.onDefaultLangChange;\n }\n /**\n * The default lang to fallback when translations are missing on the current lang\n */\n get defaultLang() {\n return this.isolate ? this._defaultLang : this.store.defaultLang;\n }\n set defaultLang(defaultLang) {\n if (this.isolate) {\n this._defaultLang = defaultLang;\n } else {\n this.store.defaultLang = defaultLang;\n }\n }\n /**\n * The lang currently used\n */\n get currentLang() {\n return this.isolate ? this._currentLang : this.store.currentLang;\n }\n set currentLang(currentLang) {\n if (this.isolate) {\n this._currentLang = currentLang;\n } else {\n this.store.currentLang = currentLang;\n }\n }\n /**\n * an array of langs\n */\n get langs() {\n return this.isolate ? this._langs : this.store.langs;\n }\n set langs(langs) {\n if (this.isolate) {\n this._langs = langs;\n } else {\n this.store.langs = langs;\n }\n }\n /**\n * a list of translations per lang\n */\n get translations() {\n return this.isolate ? this._translations : this.store.translations;\n }\n set translations(translations) {\n if (this.isolate) {\n this._translations = translations;\n } else {\n this.store.translations = translations;\n }\n }\n /**\n *\n * @param store an instance of the store (that is supposed to be unique)\n * @param currentLoader An instance of the loader currently used\n * @param compiler An instance of the compiler currently used\n * @param parser An instance of the parser currently used\n * @param missingTranslationHandler A handler for missing translations.\n * @param useDefaultLang whether we should use default language translation when current language translation is missing.\n * @param isolate whether this service should use the store or not\n * @param extend To make a child module extend (and use) translations from parent modules.\n * @param defaultLanguage Set the default language using configuration\n */\n constructor(store, currentLoader, compiler, parser, missingTranslationHandler, useDefaultLang = true, isolate = false, extend = false, defaultLanguage) {\n this.store = store;\n this.currentLoader = currentLoader;\n this.compiler = compiler;\n this.parser = parser;\n this.missingTranslationHandler = missingTranslationHandler;\n this.useDefaultLang = useDefaultLang;\n this.isolate = isolate;\n this.extend = extend;\n /** set the default language from configuration */\n if (defaultLanguage) {\n this.setDefaultLang(defaultLanguage);\n }\n }\n /**\n * Sets the default language to use as a fallback\n */\n setDefaultLang(lang) {\n if (lang === this.defaultLang) {\n return;\n }\n let pending = this.retrieveTranslations(lang);\n if (typeof pending !== \"undefined\") {\n // on init set the defaultLang immediately\n if (this.defaultLang == null) {\n this.defaultLang = lang;\n }\n pending.pipe(take(1)).subscribe(res => {\n this.changeDefaultLang(lang);\n });\n } else {\n // we already have this language\n this.changeDefaultLang(lang);\n }\n }\n /**\n * Gets the default language used\n */\n getDefaultLang() {\n return this.defaultLang;\n }\n /**\n * Changes the lang currently used\n */\n use(lang) {\n // don't change the language if the language given is already selected\n if (lang === this.currentLang) {\n return of(this.translations[lang]);\n }\n let pending = this.retrieveTranslations(lang);\n if (typeof pending !== \"undefined\") {\n // on init set the currentLang immediately\n if (!this.currentLang) {\n this.currentLang = lang;\n }\n pending.pipe(take(1)).subscribe(res => {\n this.changeLang(lang);\n });\n return pending;\n } else {\n // we have this language, return an Observable\n this.changeLang(lang);\n return of(this.translations[lang]);\n }\n }\n /**\n * Retrieves the given translations\n */\n retrieveTranslations(lang) {\n let pending;\n // if this language is unavailable or extend is true, ask for it\n if (typeof this.translations[lang] === \"undefined\" || this.extend) {\n this._translationRequests[lang] = this._translationRequests[lang] || this.getTranslation(lang);\n pending = this._translationRequests[lang];\n }\n return pending;\n }\n /**\n * Gets an object of translations for a given language with the current loader\n * and passes it through the compiler\n */\n getTranslation(lang) {\n this.pending = true;\n const loadingTranslations = this.currentLoader.getTranslation(lang).pipe(shareReplay(1), take(1));\n this.loadingTranslations = loadingTranslations.pipe(map(res => this.compiler.compileTranslations(res, lang)), shareReplay(1), take(1));\n this.loadingTranslations.subscribe({\n next: res => {\n this.translations[lang] = this.extend && this.translations[lang] ? {\n ...res,\n ...this.translations[lang]\n } : res;\n this.updateLangs();\n this.pending = false;\n },\n error: err => {\n this.pending = false;\n }\n });\n return loadingTranslations;\n }\n /**\n * Manually sets an object of translations for a given language\n * after passing it through the compiler\n */\n setTranslation(lang, translations, shouldMerge = false) {\n translations = this.compiler.compileTranslations(translations, lang);\n if ((shouldMerge || this.extend) && this.translations[lang]) {\n this.translations[lang] = mergeDeep(this.translations[lang], translations);\n } else {\n this.translations[lang] = translations;\n }\n this.updateLangs();\n this.onTranslationChange.emit({\n lang: lang,\n translations: this.translations[lang]\n });\n }\n /**\n * Returns an array of currently available langs\n */\n getLangs() {\n return this.langs;\n }\n /**\n * Add available langs\n */\n addLangs(langs) {\n langs.forEach(lang => {\n if (this.langs.indexOf(lang) === -1) {\n this.langs.push(lang);\n }\n });\n }\n /**\n * Update the list of available langs\n */\n updateLangs() {\n this.addLangs(Object.keys(this.translations));\n }\n /**\n * Returns the parsed result of the translations\n */\n getParsedResult(translations, key, interpolateParams) {\n let res;\n if (key instanceof Array) {\n let result = {},\n observables = false;\n for (let k of key) {\n result[k] = this.getParsedResult(translations, k, interpolateParams);\n if (isObservable(result[k])) {\n observables = true;\n }\n }\n if (observables) {\n const sources = key.map(k => isObservable(result[k]) ? result[k] : of(result[k]));\n return forkJoin(sources).pipe(map(arr => {\n let obj = {};\n arr.forEach((value, index) => {\n obj[key[index]] = value;\n });\n return obj;\n }));\n }\n return result;\n }\n if (translations) {\n res = this.parser.interpolate(this.parser.getValue(translations, key), interpolateParams);\n }\n if (typeof res === \"undefined\" && this.defaultLang != null && this.defaultLang !== this.currentLang && this.useDefaultLang) {\n res = this.parser.interpolate(this.parser.getValue(this.translations[this.defaultLang], key), interpolateParams);\n }\n if (typeof res === \"undefined\") {\n let params = {\n key,\n translateService: this\n };\n if (typeof interpolateParams !== 'undefined') {\n params.interpolateParams = interpolateParams;\n }\n res = this.missingTranslationHandler.handle(params);\n }\n return typeof res !== \"undefined\" ? res : key;\n }\n /**\n * Gets the translated value of a key (or an array of keys)\n * @returns the translated key, or an object of translated keys\n */\n get(key, interpolateParams) {\n if (!isDefined(key) || !key.length) {\n throw new Error(`Parameter \"key\" required`);\n }\n // check if we are loading a new translation to use\n if (this.pending) {\n return this.loadingTranslations.pipe(concatMap(res => {\n res = this.getParsedResult(res, key, interpolateParams);\n return isObservable(res) ? res : of(res);\n }));\n } else {\n let res = this.getParsedResult(this.translations[this.currentLang], key, interpolateParams);\n return isObservable(res) ? res : of(res);\n }\n }\n /**\n * Returns a stream of translated values of a key (or an array of keys) which updates\n * whenever the translation changes.\n * @returns A stream of the translated key, or an object of translated keys\n */\n getStreamOnTranslationChange(key, interpolateParams) {\n if (!isDefined(key) || !key.length) {\n throw new Error(`Parameter \"key\" required`);\n }\n return concat(defer(() => this.get(key, interpolateParams)), this.onTranslationChange.pipe(switchMap(event => {\n const res = this.getParsedResult(event.translations, key, interpolateParams);\n if (typeof res.subscribe === 'function') {\n return res;\n } else {\n return of(res);\n }\n })));\n }\n /**\n * Returns a stream of translated values of a key (or an array of keys) which updates\n * whenever the language changes.\n * @returns A stream of the translated key, or an object of translated keys\n */\n stream(key, interpolateParams) {\n if (!isDefined(key) || !key.length) {\n throw new Error(`Parameter \"key\" required`);\n }\n return concat(defer(() => this.get(key, interpolateParams)), this.onLangChange.pipe(switchMap(event => {\n const res = this.getParsedResult(event.translations, key, interpolateParams);\n return isObservable(res) ? res : of(res);\n })));\n }\n /**\n * Returns a translation instantly from the internal state of loaded translation.\n * All rules regarding the current language, the preferred language of even fallback languages will be used except any promise handling.\n */\n instant(key, interpolateParams) {\n if (!isDefined(key) || !key.length) {\n throw new Error(`Parameter \"key\" required`);\n }\n let res = this.getParsedResult(this.translations[this.currentLang], key, interpolateParams);\n if (isObservable(res)) {\n if (key instanceof Array) {\n let obj = {};\n key.forEach((value, index) => {\n obj[key[index]] = key[index];\n });\n return obj;\n }\n return key;\n } else {\n return res;\n }\n }\n /**\n * Sets the translated value of a key, after compiling it\n */\n set(key, value, lang = this.currentLang) {\n this.translations[lang][key] = this.compiler.compile(value, lang);\n this.updateLangs();\n this.onTranslationChange.emit({\n lang: lang,\n translations: this.translations[lang]\n });\n }\n /**\n * Changes the current lang\n */\n changeLang(lang) {\n this.currentLang = lang;\n this.onLangChange.emit({\n lang: lang,\n translations: this.translations[lang]\n });\n // if there is no default lang, use the one that we just set\n if (this.defaultLang == null) {\n this.changeDefaultLang(lang);\n }\n }\n /**\n * Changes the default lang\n */\n changeDefaultLang(lang) {\n this.defaultLang = lang;\n this.onDefaultLangChange.emit({\n lang: lang,\n translations: this.translations[lang]\n });\n }\n /**\n * Allows to reload the lang file from the file\n */\n reloadLang(lang) {\n this.resetLang(lang);\n return this.getTranslation(lang);\n }\n /**\n * Deletes inner translation\n */\n resetLang(lang) {\n this._translationRequests[lang] = undefined;\n this.translations[lang] = undefined;\n }\n /**\n * Returns the language code name from the browser, e.g. \"de\"\n */\n getBrowserLang() {\n if (typeof window === 'undefined' || typeof window.navigator === 'undefined') {\n return undefined;\n }\n let browserLang = window.navigator.languages ? window.navigator.languages[0] : null;\n browserLang = browserLang || window.navigator.language || window.navigator.browserLanguage || window.navigator.userLanguage;\n if (typeof browserLang === 'undefined') {\n return undefined;\n }\n if (browserLang.indexOf('-') !== -1) {\n browserLang = browserLang.split('-')[0];\n }\n if (browserLang.indexOf('_') !== -1) {\n browserLang = browserLang.split('_')[0];\n }\n return browserLang;\n }\n /**\n * Returns the culture language code name from the browser, e.g. \"de-DE\"\n */\n getBrowserCultureLang() {\n if (typeof window === 'undefined' || typeof window.navigator === 'undefined') {\n return undefined;\n }\n let browserCultureLang = window.navigator.languages ? window.navigator.languages[0] : null;\n browserCultureLang = browserCultureLang || window.navigator.language || window.navigator.browserLanguage || window.navigator.userLanguage;\n return browserCultureLang;\n }\n static ɵfac = function TranslateService_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || TranslateService)(i0.ɵɵinject(TranslateStore), i0.ɵɵinject(TranslateLoader), i0.ɵɵinject(TranslateCompiler), i0.ɵɵinject(TranslateParser), i0.ɵɵinject(MissingTranslationHandler), i0.ɵɵinject(USE_DEFAULT_LANG), i0.ɵɵinject(USE_STORE), i0.ɵɵinject(USE_EXTEND), i0.ɵɵinject(DEFAULT_LANGUAGE));\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: TranslateService,\n factory: TranslateService.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TranslateService, [{\n type: Injectable\n }], function () {\n return [{\n type: TranslateStore\n }, {\n type: TranslateLoader\n }, {\n type: TranslateCompiler\n }, {\n type: TranslateParser\n }, {\n type: MissingTranslationHandler\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [USE_DEFAULT_LANG]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [USE_STORE]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [USE_EXTEND]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Inject,\n args: [DEFAULT_LANGUAGE]\n }]\n }];\n }, null);\n})();\nclass TranslateDirective {\n translateService;\n element;\n _ref;\n key;\n lastParams;\n currentParams;\n onLangChangeSub;\n onDefaultLangChangeSub;\n onTranslationChangeSub;\n set translate(key) {\n if (key) {\n this.key = key;\n this.checkNodes();\n }\n }\n set translateParams(params) {\n if (!equals(this.currentParams, params)) {\n this.currentParams = params;\n this.checkNodes(true);\n }\n }\n constructor(translateService, element, _ref) {\n this.translateService = translateService;\n this.element = element;\n this._ref = _ref;\n // subscribe to onTranslationChange event, in case the translations of the current lang change\n if (!this.onTranslationChangeSub) {\n this.onTranslationChangeSub = this.translateService.onTranslationChange.subscribe(event => {\n if (event.lang === this.translateService.currentLang) {\n this.checkNodes(true, event.translations);\n }\n });\n }\n // subscribe to onLangChange event, in case the language changes\n if (!this.onLangChangeSub) {\n this.onLangChangeSub = this.translateService.onLangChange.subscribe(event => {\n this.checkNodes(true, event.translations);\n });\n }\n // subscribe to onDefaultLangChange event, in case the default language changes\n if (!this.onDefaultLangChangeSub) {\n this.onDefaultLangChangeSub = this.translateService.onDefaultLangChange.subscribe(event => {\n this.checkNodes(true);\n });\n }\n }\n ngAfterViewChecked() {\n this.checkNodes();\n }\n checkNodes(forceUpdate = false, translations) {\n let nodes = this.element.nativeElement.childNodes;\n // if the element is empty\n if (!nodes.length) {\n // we add the key as content\n this.setContent(this.element.nativeElement, this.key);\n nodes = this.element.nativeElement.childNodes;\n }\n for (let i = 0; i < nodes.length; ++i) {\n let node = nodes[i];\n if (node.nodeType === 3) {\n // node type 3 is a text node\n let key;\n if (forceUpdate) {\n node.lastKey = null;\n }\n if (isDefined(node.lookupKey)) {\n key = node.lookupKey;\n } else if (this.key) {\n key = this.key;\n } else {\n let content = this.getContent(node);\n let trimmedContent = content.trim();\n if (trimmedContent.length) {\n node.lookupKey = trimmedContent;\n // we want to use the content as a key, not the translation value\n if (content !== node.currentValue) {\n key = trimmedContent;\n // the content was changed from the user, we'll use it as a reference if needed\n node.originalContent = content || node.originalContent;\n } else if (node.originalContent) {\n // the content seems ok, but the lang has changed\n // the current content is the translation, not the key, use the last real content as key\n key = node.originalContent.trim();\n } else if (content !== node.currentValue) {\n // we want to use the content as a key, not the translation value\n key = trimmedContent;\n // the content was changed from the user, we'll use it as a reference if needed\n node.originalContent = content || node.originalContent;\n }\n }\n }\n this.updateValue(key, node, translations);\n }\n }\n }\n updateValue(key, node, translations) {\n if (key) {\n if (node.lastKey === key && this.lastParams === this.currentParams) {\n return;\n }\n this.lastParams = this.currentParams;\n let onTranslation = res => {\n if (res !== key) {\n node.lastKey = key;\n }\n if (!node.originalContent) {\n node.originalContent = this.getContent(node);\n }\n node.currentValue = isDefined(res) ? res : node.originalContent || key;\n // we replace in the original content to preserve spaces that we might have trimmed\n this.setContent(node, this.key ? node.currentValue : node.originalContent.replace(key, node.currentValue));\n this._ref.markForCheck();\n };\n if (isDefined(translations)) {\n let res = this.translateService.getParsedResult(translations, key, this.currentParams);\n if (isObservable(res)) {\n res.subscribe({\n next: onTranslation\n });\n } else {\n onTranslation(res);\n }\n } else {\n this.translateService.get(key, this.currentParams).subscribe(onTranslation);\n }\n }\n }\n getContent(node) {\n return isDefined(node.textContent) ? node.textContent : node.data;\n }\n setContent(node, content) {\n if (isDefined(node.textContent)) {\n node.textContent = content;\n } else {\n node.data = content;\n }\n }\n ngOnDestroy() {\n if (this.onLangChangeSub) {\n this.onLangChangeSub.unsubscribe();\n }\n if (this.onDefaultLangChangeSub) {\n this.onDefaultLangChangeSub.unsubscribe();\n }\n if (this.onTranslationChangeSub) {\n this.onTranslationChangeSub.unsubscribe();\n }\n }\n static ɵfac = function TranslateDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || TranslateDirective)(i0.ɵɵdirectiveInject(TranslateService), i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: TranslateDirective,\n selectors: [[\"\", \"translate\", \"\"], [\"\", \"ngx-translate\", \"\"]],\n inputs: {\n translate: \"translate\",\n translateParams: \"translateParams\"\n },\n standalone: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TranslateDirective, [{\n type: Directive,\n args: [{\n selector: '[translate],[ngx-translate]'\n }]\n }], function () {\n return [{\n type: TranslateService\n }, {\n type: i0.ElementRef\n }, {\n type: i0.ChangeDetectorRef\n }];\n }, {\n translate: [{\n type: Input\n }],\n translateParams: [{\n type: Input\n }]\n });\n})();\nclass TranslatePipe {\n translate;\n _ref;\n value = '';\n lastKey = null;\n lastParams = [];\n onTranslationChange;\n onLangChange;\n onDefaultLangChange;\n constructor(translate, _ref) {\n this.translate = translate;\n this._ref = _ref;\n }\n updateValue(key, interpolateParams, translations) {\n let onTranslation = res => {\n this.value = res !== undefined ? res : key;\n this.lastKey = key;\n this._ref.markForCheck();\n };\n if (translations) {\n let res = this.translate.getParsedResult(translations, key, interpolateParams);\n if (isObservable(res.subscribe)) {\n res.subscribe(onTranslation);\n } else {\n onTranslation(res);\n }\n }\n this.translate.get(key, interpolateParams).subscribe(onTranslation);\n }\n transform(query, ...args) {\n if (!query || !query.length) {\n return query;\n }\n // if we ask another time for the same key, return the last value\n if (equals(query, this.lastKey) && equals(args, this.lastParams)) {\n return this.value;\n }\n let interpolateParams = undefined;\n if (isDefined(args[0]) && args.length) {\n if (typeof args[0] === 'string' && args[0].length) {\n // we accept objects written in the template such as {n:1}, {'n':1}, {n:'v'}\n // which is why we might need to change it to real JSON objects such as {\"n\":1} or {\"n\":\"v\"}\n let validArgs = args[0].replace(/(\\')?([a-zA-Z0-9_]+)(\\')?(\\s)?:/g, '\"$2\":').replace(/:(\\s)?(\\')(.*?)(\\')/g, ':\"$3\"');\n try {\n interpolateParams = JSON.parse(validArgs);\n } catch (e) {\n throw new SyntaxError(`Wrong parameter in TranslatePipe. Expected a valid Object, received: ${args[0]}`);\n }\n } else if (typeof args[0] === 'object' && !Array.isArray(args[0])) {\n interpolateParams = args[0];\n }\n }\n // store the query, in case it changes\n this.lastKey = query;\n // store the params, in case they change\n this.lastParams = args;\n // set the value\n this.updateValue(query, interpolateParams);\n // if there is a subscription to onLangChange, clean it\n this._dispose();\n // subscribe to onTranslationChange event, in case the translations change\n if (!this.onTranslationChange) {\n this.onTranslationChange = this.translate.onTranslationChange.subscribe(event => {\n if (this.lastKey && event.lang === this.translate.currentLang) {\n this.lastKey = null;\n this.updateValue(query, interpolateParams, event.translations);\n }\n });\n }\n // subscribe to onLangChange event, in case the language changes\n if (!this.onLangChange) {\n this.onLangChange = this.translate.onLangChange.subscribe(event => {\n if (this.lastKey) {\n this.lastKey = null; // we want to make sure it doesn't return the same value until it's been updated\n this.updateValue(query, interpolateParams, event.translations);\n }\n });\n }\n // subscribe to onDefaultLangChange event, in case the default language changes\n if (!this.onDefaultLangChange) {\n this.onDefaultLangChange = this.translate.onDefaultLangChange.subscribe(() => {\n if (this.lastKey) {\n this.lastKey = null; // we want to make sure it doesn't return the same value until it's been updated\n this.updateValue(query, interpolateParams);\n }\n });\n }\n return this.value;\n }\n /**\n * Clean any existing subscription to change events\n */\n _dispose() {\n if (typeof this.onTranslationChange !== 'undefined') {\n this.onTranslationChange.unsubscribe();\n this.onTranslationChange = undefined;\n }\n if (typeof this.onLangChange !== 'undefined') {\n this.onLangChange.unsubscribe();\n this.onLangChange = undefined;\n }\n if (typeof this.onDefaultLangChange !== 'undefined') {\n this.onDefaultLangChange.unsubscribe();\n this.onDefaultLangChange = undefined;\n }\n }\n ngOnDestroy() {\n this._dispose();\n }\n static ɵfac = function TranslatePipe_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || TranslatePipe)(i0.ɵɵdirectiveInject(TranslateService, 16), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef, 16));\n };\n static ɵpipe = /* @__PURE__ */i0.ɵɵdefinePipe({\n name: \"translate\",\n type: TranslatePipe,\n pure: false,\n standalone: false\n });\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: TranslatePipe,\n factory: TranslatePipe.ɵfac\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TranslatePipe, [{\n type: Injectable\n }, {\n type: Pipe,\n args: [{\n name: 'translate',\n pure: false // required to update the value when the promise is resolved\n }]\n }], function () {\n return [{\n type: TranslateService\n }, {\n type: i0.ChangeDetectorRef\n }];\n }, null);\n})();\nclass TranslateModule {\n /**\n * Use this method in your root module to provide the TranslateService\n */\n static forRoot(config = {}) {\n return {\n ngModule: TranslateModule,\n providers: [config.loader || {\n provide: TranslateLoader,\n useClass: TranslateFakeLoader\n }, config.compiler || {\n provide: TranslateCompiler,\n useClass: TranslateFakeCompiler\n }, config.parser || {\n provide: TranslateParser,\n useClass: TranslateDefaultParser\n }, config.missingTranslationHandler || {\n provide: MissingTranslationHandler,\n useClass: FakeMissingTranslationHandler\n }, TranslateStore, {\n provide: USE_STORE,\n useValue: config.isolate\n }, {\n provide: USE_DEFAULT_LANG,\n useValue: config.useDefaultLang\n }, {\n provide: USE_EXTEND,\n useValue: config.extend\n }, {\n provide: DEFAULT_LANGUAGE,\n useValue: config.defaultLanguage\n }, TranslateService]\n };\n }\n /**\n * Use this method in your other (non root) modules to import the directive/pipe\n */\n static forChild(config = {}) {\n return {\n ngModule: TranslateModule,\n providers: [config.loader || {\n provide: TranslateLoader,\n useClass: TranslateFakeLoader\n }, config.compiler || {\n provide: TranslateCompiler,\n useClass: TranslateFakeCompiler\n }, config.parser || {\n provide: TranslateParser,\n useClass: TranslateDefaultParser\n }, config.missingTranslationHandler || {\n provide: MissingTranslationHandler,\n useClass: FakeMissingTranslationHandler\n }, {\n provide: USE_STORE,\n useValue: config.isolate\n }, {\n provide: USE_DEFAULT_LANG,\n useValue: config.useDefaultLang\n }, {\n provide: USE_EXTEND,\n useValue: config.extend\n }, {\n provide: DEFAULT_LANGUAGE,\n useValue: config.defaultLanguage\n }, TranslateService]\n };\n }\n static ɵfac = function TranslateModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || TranslateModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: TranslateModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({});\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(TranslateModule, [{\n type: NgModule,\n args: [{\n declarations: [TranslatePipe, TranslateDirective],\n exports: [TranslatePipe, TranslateDirective]\n }]\n }], null, null);\n})();\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { DEFAULT_LANGUAGE, FakeMissingTranslationHandler, MissingTranslationHandler, TranslateCompiler, TranslateDefaultParser, TranslateDirective, TranslateFakeCompiler, TranslateFakeLoader, TranslateLoader, TranslateModule, TranslateParser, TranslatePipe, TranslateService, TranslateStore, USE_DEFAULT_LANG, USE_EXTEND, USE_STORE };\n","import { Injectable } from '@angular/core';\r\nimport { NavigationEnd, Router } from '@angular/router';\r\nimport { BehaviorSubject } from 'rxjs';\r\nimport { filter } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DefaultTabService {\r\n private itemAvailableSubject = new BehaviorSubject<boolean>(false);\r\n private itemsSubject = new BehaviorSubject<string[]>([]);\r\n private itemSelectedSubject = new BehaviorSubject<string>(\"\");\r\n\r\n public itemAvailable$ = this.itemAvailableSubject.asObservable();\r\n public items$ = this.itemsSubject.asObservable();\r\n public item$ = this.itemSelectedSubject.asObservable();\r\n public lengthOfData = 0;\r\n\r\n constructor(\r\n private router: Router\r\n ) {\r\n this.router.events.pipe(filter(e => e instanceof NavigationEnd))\r\n .subscribe(() => this.deleteAllItems());\r\n }\r\n\r\n deleteAllItems(): void {\r\n this.addItems([]);\r\n }\r\n\r\n public addItems(items: string[]) {\r\n this.lengthOfData = items.length;\r\n\r\n if (this.lengthOfData === 0) {\r\n this.itemAvailableSubject.next(false);\r\n this.itemSelectedSubject.next(\"\");\r\n }\r\n else {\r\n this.itemAvailableSubject.next(true);\r\n this.itemSelectedSubject.next(items[0]);\r\n }\r\n\r\n this.itemsSubject.next(items);\r\n }\r\n\r\n public choseCurrentItem(item: string) {\r\n this.itemSelectedSubject.next(item);\r\n }\r\n\r\n}\r\n","import { Component, OnDestroy, OnInit } from '@angular/core';\r\nimport { DefaultTabService } from '../tabs/default-tab.service';\r\nimport { TranslateService } from '@ngx-translate/core';\r\nimport { Subscription } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-default-tabbar',\r\n templateUrl: './default-tabbar.component.html',\r\n styleUrls: ['./default-tabbar.component.scss'],\r\n standalone: false\r\n})\r\nexport class DefaultTabbarComponent implements OnInit, OnDestroy {\r\n items: string[];\r\n currentItem: string;\r\n itemsSub: Subscription;\r\n itemSub: Subscription;\r\n\r\n constructor(\r\n public tabService: DefaultTabService,\r\n private translateService: TranslateService\r\n ) {}\r\n\r\n ngOnInit(): void {\r\n this.itemsSub = this.tabService.items$.subscribe(\r\n (i: string[]) => (this.items = i)\r\n );\r\n this.itemSub = this.tabService.item$.subscribe(\r\n (i: string) => (this.currentItem = i)\r\n );\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.itemsSub.unsubscribe();\r\n this.itemSub.unsubscribe();\r\n }\r\n\r\n onItemSelected(item: string) {\r\n this.tabService.choseCurrentItem(item);\r\n }\r\n\r\n protected translateItem(item: string): string {\r\n return this.translateService.instant(item);\r\n }\r\n}\r\n","<div *ngIf=\"tabService.itemAvailable$ | async\" id=\"topnav\">\r\n <dl>\r\n <dd *ngFor=\"let item of items\">\r\n <a [ngClass]=\"item === currentItem ? 'active' : ''\" title={{translateItem(item)}}\r\n class=\"navigationLink\" href=\"javascript:;\" (click)=\"onItemSelected(item)\">{{translateItem(item)}}</a>\r\n </dd>\r\n </dl>\r\n</div>","import { Component, OnInit } from '@angular/core';\r\nimport { ActivatedRoute } from '@angular/router';\r\nimport { LangChangeEvent, TranslateService } from '@ngx-translate/core';\r\n\r\n@Component({\r\n selector: 'app-default-layout',\r\n templateUrl: './default-layout.component.html',\r\n styleUrls: ['./default-layout.component.scss'],\r\n standalone: false\r\n})\r\nexport class DefaultLayoutComponent implements OnInit {\r\n title: string; \r\n currentLanguage: string;\r\n\r\n constructor(\r\n private translate: TranslateService,\r\n private route: ActivatedRoute\r\n ) { \r\n translate.addLangs([\"de\", \"en\"]);\r\n translate.setDefaultLang(\"de\");\r\n //translate.use(this.getDefaultLanguage());\r\n translate.use(\"de\");\r\n this.currentLanguage = translate.currentLang; \r\n }\r\n\r\n ngOnInit(): void {\r\n this.route.data.subscribe((data) => {\r\n this.title = data.title;\r\n });\r\n \r\n this.translate.onLangChange.subscribe((languageChange: LangChangeEvent) => {\r\n localStorage.setItem(\"language\", languageChange.lang);\r\n this.currentLanguage = this.translate.currentLang;\r\n }); \r\n }\r\n\r\n print(): void {\r\n window.print();\r\n }\r\n\r\n /**\r\n * Gets the default language of the current user\r\n * @returns the default language of the current user\r\n */\r\n getDefaultLanguage(): string {\r\n const savedLanguage = localStorage.getItem(\"language\");\r\n return savedLanguage ? savedLanguage : this.translate.getBrowserLang();\r\n }\r\n\r\n /** switch language */\r\n changeLang(): void {\r\n if (this.translate.currentLang === \"de\") {\r\n this.translate.use(\"en\");\r\n }\r\n else {\r\n this.translate.use(\"de\");\r\n } \r\n } \r\n\r\n}\r\n","<div id=\"page\">\r\n <div id=\"header\"><BR>\r\n <div id=\"logo\"><A title=\"IFA - HomePage\" href=\"http://www.dguv.de/ifa/index.jsp\" target=_blank><IMG class=\"logo\"\r\n alt=\"Institute for Occupational Safety and Health of the German Social Accident Insurance\"\r\n src=\"assets/Logo-IFA.gif\"> </A></div>\r\n <div id=\"funktionsleiste\">\r\n <ng-container *ngIf=\"currentLanguage === 'de'\">\r\n <A title=\"HomePage DGUV\" href=\"http://www.dguv.de/de/index.jsp\" target=_blank>DGUV</A>\r\n | \r\n <A title=\"{{ 'LAYOUT.EMAIL' | translate }}\" href=\"mailto:EMF-LIT@DGUV.DE\" target=_blank>\r\n {{ \"LAYOUT.CONTACT\" | translate }}</A>\r\n | \r\n <A title=\"Englisch\" (click)=\"changeLang()\">English</A>\r\n </ng-container>\r\n <ng-container *ngIf=\"currentLanguage !== 'de'\">\r\n <A title=\"HomePage DGUV\" href=\"https://www.dguv.de/en/index.jsp\" target=_blank>DGUV</A>\r\n | \r\n <A title=\"{{ 'LAYOUT.EMAIL' | translate }}\" href=\"mailto:EMF-LIT@DGUV.DE\" target=_blank>\r\n {{ \"LAYOUT.CONTACT\" | translate }}</A>\r\n | \r\n <A title=\"Deutsch\" (click)=\"changeLang()\">Deutsch</A>\r\n </ng-container>\r\n </div>\r\n <div id=\"titel\">\r\n <div id=\"funktionsleiste2\">\r\n <p id=\"title\">{{ \"LAYOUT.TITLE\" | translate }}</p>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <!--\r\n Please chose one of the following bars! \r\n Navbar uses the file _nav.ts for routing between components and modules. Usefull for strong separated modules.\r\n Tabbar uses the <app-tabs> component It should be used for a tab based application. \r\n You can only use one instance of tabbar in the application!\r\n -->\r\n <!--<app-default-navbar></app-default-navbar>-->\r\n <app-default-tabbar></app-default-tabbar>\r\n\r\n <div id=\"page\">\r\n <div id=\"main\">\r\n <div id=\"col2\">\r\n <br><br>\r\n <div id=\"contentCol2\">\r\n\r\n <router-outlet></router-outlet>\r\n\r\n </div>\r\n\r\n </div>\r\n\r\n <div id=\"footer\">\r\n <dl>\r\n <dd>\r\n <span id=\"lb_11\"><button class=\"linkbutton\" (click)=\"print()\"><img title=\"Seite drucken\"\r\n height=\"13\" src=\"assets/drucker.gif\" width=\"16\">{{ \"LAYOUT.PRINT\" | translate}}</button></span>\r\n </dd>\r\n </dl>\r\n <div class=\"imprint\">\r\n <!-- <span><a href=\"https://www.dguv.de/de/wir-ueber-uns/impressum/datenschutzerklaerung/index.jsp\" -->\r\n <!-- target=\"_blank\">Datenschutzerklärung</a> </span> <span id=\"lb_12\"><a -->\r\n <!-- href=\"http://www.dguv.de/de/wir-ueber-uns/impressum/index.jsp\" target=\"_blank\">Impressum</a> -->\r\n <!-- </span> -->\r\n <ng-container *ngIf=\"currentLanguage === 'de'\">\r\n <span>\r\n <a href=\"https://www.dguv.de/de/wir-ueber-uns/impressum/datenschutzerklaerung/index.jsp\"\r\n target=\"_blank\">{{ \"LAYOUT.POLICY\" | translate }}</a>\r\n </span> \r\n <span id=\"lb_12\">\r\n <a href=\"http://www.dguv.de/de/wir-ueber-uns/impressum/index.jsp\" target=\"_blank\"\r\n rel=“noreferrer“>\r\n {{ \"LAYOUT.IMPRESSUM\" | translate }}</a>\r\n </span> \r\n <span id=\"lb_12\">\r\n <a href=\"https://www.dguv.de/ifa/praxishilfen/elektromagnetische-felder/software-emf-lit/emf-lit_barrierefreiheit.jsp\" target=\"_blank\">{{ \"LAYOUT.ACCESSIBILITY\" | translate }}</a>\r\n </span>\r\n </ng-container>\r\n <ng-container *ngIf=\"currentLanguage !== 'de'\">\r\n <span>\r\n <a href=\"https://www.dguv.de/de/wir-ueber-uns/impressum/datenschutzerklaerung/index.jsp\"\r\n target=\"_blank\">{{ \"LAYOUT.POLICY\" | translate }}</a>\r\n </span> \r\n <span id=\"lb_12\">\r\n <a href=\"https://www.dguv.de/en/about-us/legal-information/index.jsp\" target=\"_blank\">\r\n {{ \"LAYOUT.IMPRESSUM\" | translate }}</a>\r\n </span> \r\n <span id=\"lb_12\">\r\n <a href=\"https://www.dguv.de/ifa/praxishilfen/elektromagnetische-felder/software-emf-lit/emf-lit_barrierefreiheit-2.jsp\" target=\"_blank\">{{ \"LAYOUT.ACCESSIBILITY\" | translate }}</a>\r\n </span>\r\n </ng-container> \r\n </div> \r\n </div>\r\n </div>\r\n </div>\r\n</div>","import { Component, OnInit } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-error404',\r\n templateUrl: './error404.component.html',\r\n styleUrls: ['./error404.component.scss'],\r\n standalone: false\r\n})\r\nexport class Error404Component implements OnInit {\r\n\r\n constructor() { }\r\n\r\n ngOnInit(): void {\r\n }\r\n\r\n}\r\n","<p><b>404 Seite wurde nicht gefunden.</b></p>\r\n<a href=\"https://www.dguv.de/ifa/index.jsp\">Zurück zum IFA</a>","import { Component, OnInit } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-error500',\r\n templateUrl: './error500.component.html',\r\n styleUrls: ['./error500.component.scss'],\r\n standalone: false\r\n})\r\nexport class Error500Component implements OnInit {\r\n\r\n constructor() { }\r\n\r\n ngOnInit(): void {\r\n }\r\n\r\n}\r\n","<p><b>500 Es ist ein unerwarteter Fehler aufgetreten. Bitte versuchen Sie es später erneut.</b></p>\r\n<a href=\"https://www.dguv.de/ifa/index.jsp\">Zurück zum IFA</a>\r\n","import { Component, AfterViewInit, ViewChild, ElementRef } from '@angular/core';\r\nimport { DefaultTabService } from 'src/app/containers/tabs/default-tab.service';\r\nimport { Chart } from 'chart.js';\r\n// Functions for EU1999 limits\r\nimport { updateEU1999_B_Frequenz, updateEU1999_E_Frequenz, updateEU1999_B_Regelwerk, updateEU1999_E_Regelwerk, EU1999_B, EU1999_E, EU1999_B_Spitze, EU1999_E_Spitze, Schwellen_EU1999_B, Schwellen_EU1999_E, Schwellen_EU1999_B_Spitze, Schwellen_EU1999_E_Spitze } from \"./emf-lit.component.EU1999\";\r\n// Functions for FB451 limits\r\nimport { updateFB451_B_Regelwerk, updateFB451_E_Regelwerk, updateFB451_B_Frequenz, updateFB451_E_Frequenz, FB451_Passiv_B, FB451_Aktiv_B, FB451_Passiv_E, FB451_Aktiv_E, Schwellen_FB451_Aktiv_B, Schwellen_FB451_Passiv_B, Schwellen_FB451_Aktiv_E, Schwellen_FB451_Passiv_E } from \"./emf-lit.component.FB451\";\r\n// Functions & tables for EMFV limits\r\nimport { updateEMFV_B_Frequenz, updateEMFV_E_Frequenz, updateEMFV_B_Regelwerk, updateEMFV_E_Regelwerk, EMFV_Gliedmassen_B, EMFV_OAS_B, EMFV_UAS_B, EMFV_Thermisch_B, EMFV_Thermisch_Spitze_B, EMFV_OAS_E, EMFV_UAS_E, EMFV_Thermisch_E, EMFV_Thermisch_Spitze_E, Schwellen_EMFV_UAS_B, Schwellen_EMFV_OAS_B, Schwellen_EMFV_Gliedmassen_B, Schwellen_EMFV_Therm_B, Schwellen_EMFV_Therm_B_Spitze, Schwellen_EMFV_UAS_E, Schwellen_EMFV_OAS_E, Schwellen_EMFV_Therm_E, Schwellen_EMFV_Therm_E_Spitze } from \"./emf-lit.component.EMFV\";\r\n// Functions for BImSchV limits\r\nimport { updateBImSchV_B_Regelwerk, updateBImSchV_E_Regelwerk, updateBImSchV_B_Frequenz, updateBImSchV_E_Frequenz, BImSchV_B_NF, BImSchV_E_NF, BImSchV_B_HF, BImSchV_E_HF, BImSchV_B_Spitze, BImSchV_E_Spitze, Schwellen_BImSchV_NF_B, Schwellen_BImSchV_HF_B, Schwellen_BImSchV_Spitze_B, Schwellen_BImSchV_NF_E, Schwellen_BImSchV_HF_E, Schwellen_BImSchV_Spitze_E } from \"./emf-lit.component.BImSchV\";\r\n// Functions for DGUV limits\r\nimport { updateDGUVV15_B_Regelwerk, updateDGUVV15_E_Regelwerk, updateDGUVV15_B_Frequenz, updateDGUVV15_E_Frequenz, V15_Expo2_E, V15_Expo2_B, V15_Expo1_E, V15_Expo1_B, V15_ExpoEr_E, V15_ExpoEr_B, V15_ExpoEr_Spitze_E, V15_ExpoEr_Spitze_B, Schwellen_DGUVV15_Expo2_B, Schwellen_DGUVV15_Expo1_B, Schwellen_DGUVV15_ExpoEr_B, Schwellen_DGUVV15_ExpoEr_Spitze_B, Schwellen_DGUVV15_Expo2_E, Schwellen_DGUVV15_Expo1_E, Schwellen_DGUVV15_ExpoEr_E, Schwellen_DGUVV15_ExpoEr_Spitze_E } from \"./emf-lit.component.DGUVV15\";\r\n// Functions & tables for EU2013 limits\r\nimport { updateEU2013_B_Frequenz, updateEU2013_E_Frequenz, updateEU2013_B_Regelwerk, updateEU2013_E_Regelwerk, EU2013_Gliedmassen_B, EU2013_OAS_B, EU2013_UAS_B, EU2013_Thermisch_B, EU2013_OAS_E, EU2013_UAS_E, EU2013_Thermisch_E, Schwellen_EU2013_UAS_B, Schwellen_EU2013_OAS_B, Schwellen_EU2013_Gliedmassen_B, Schwellen_EU2013_Therm_B, Schwellen_EU2013_UAS_E, Schwellen_EU2013_OAS_E, Schwellen_EU2013_Therm_E } from \"./emf-lit.component.EU2013\";\r\nimport { LangChangeEvent, TranslateService } from '@ngx-translate/core';\r\n\r\nconst GREY = \"#bebebe\";\r\nconst RED = \"#ff0000\";\r\nconst GREEN = \"#5eff01\";\r\n\r\n@Component({\r\n selector: 'app-emf-lit',\r\n templateUrl: './emf-lit.component.html',\r\n styleUrls: ['./emf-lit.component.scss'],\r\n standalone: false\r\n})\r\n\r\nexport class EmfLitComponent implements AfterViewInit {\r\n EU2013: boolean = false;\r\n EMFV: boolean = true;\r\n FB451: boolean = false;\r\n EU1999: boolean = false;\r\n BImSchV: boolean = false;\r\n DGUVV15: boolean = false;\r\n minSucheCheck: boolean = false;\r\n UnsicherheitCheck: boolean = false;\r\n BewertungCheck: boolean = false;\r\n Frequenz: number;\r\n Frequenz_min: number;\r\n Frequenz_max: number;\r\n Frequenz_input: number = 50;\r\n Frequenz_input_min: number = 50;\r\n Frequenz_input_max: number = 500;\r\n multiplier: number = 1;\r\n eval_unit: number = 1;\r\n FaktorU: number = 1;\r\n B_Effektiv: number = 0;\r\n B_Spitze: number = 0;\r\n E_Effektiv: number = 0;\r\n E_Spitze: number = 0;\r\n BFeldChart: Chart;\r\n EFeldChart: Chart;\r\n currentLanguage: string;\r\n\r\n // Frequencies for limit values. Can be different for each limit due to the minimum search. And colors depending on evaluation\r\n EU2013_UAS_B_Freq: number = this.Frequenz_input;\r\n EU2013_UAS_B_Color_mT: string = \"\";\r\n EU2013_UAS_B_Color_Am: string = \"\";\r\n EU2013_UAS_B_Color_mT_Uncert: string = \"\";\r\n EU2013_UAS_B_Color_Am_Uncert: string = \"\";\r\n EU2013_UAS_E_Freq: number = this.Frequenz_input;\r\n EU2013_UAS_E_Color: string = \"\";\r\n EU2013_UAS_E_Color_Uncert: string = \"\";\r\n EU2013_OAS_B_Freq: number = this.Frequenz_input;\r\n EU2013_OAS_B_Color_mT: string = \"\";\r\n EU2013_OAS_B_Color_Am: string = \"\";\r\n EU2013_OAS_B_Color_mT_Uncert: string = \"\";\r\n EU2013_OAS_B_Color_Am_Uncert: string = \"\";\r\n EU2013_OAS_E_Freq: number = this.Frequenz_input;\r\n EU2013_OAS_E_Color: string = \"\";\r\n EU2013_OAS_E_Color_Uncert: string = \"\";\r\n EU2013_Gliedmassen_B_Freq: number = this.Frequenz_input;\r\n EU2013_Gliedmassen_B_Color_mT: string = \"\";\r\n EU2013_Gliedmassen_B_Color_Am: string = \"\";\r\n EU2013_Gliedmassen_B_Color_mT_Uncert: string = \"\";\r\n EU2013_Gliedmassen_B_Color_Am_Uncert: string = \"\";\r\n EU2013_Therm_B_Freq: number = this.Frequenz_input;\r\n EU2013_Therm_B_Color_mT: string = \"\";\r\n EU2013_Therm_B_Color_mT_Uncert: string = \"\";\r\n EU2013_Therm_B_Color_Am: string = \"\";\r\n EU2013_Therm_B_Color_Am_Uncert: string = \"\";\r\n EU2013_Therm_E_Freq: number = this.Frequenz_input;\r\n EU2013_Therm_E_Color: string = \"\";\r\n EU2013_Therm_E_Color_Uncert: string = \"\";\r\n EMFV_UAS_B_Freq: number = this.Frequenz_input;\r\n EMFV_UAS_B_Color_mT: string = \"\";\r\n EMFV_UAS_B_Color_Am: string = \"\";\r\n EMFV_UAS_B_Color_mT_Uncert: string = \"\";\r\n EMFV_UAS_B_Color_Am_Uncert: string = \"\";\r\n EMFV_UAS_E_Freq: number = this.Frequenz_input;\r\n EMFV_UAS_E_Color: string = \"\";\r\n EMFV_UAS_E_Color_Uncert: string = \"\";\r\n EMFV_OAS_B_Freq: number = this.Frequenz_input;\r\n EMFV_OAS_B_Color_mT: string = \"\";\r\n EMFV_OAS_B_Color_Am: string = \"\";\r\n EMFV_OAS_B_Color_mT_Uncert: string = \"\";\r\n EMFV_OAS_B_Color_Am_Uncert: string = \"\";\r\n EMFV_OAS_E_Freq: number = this.Frequenz_input;\r\n EMFV_OAS_E_Color: string = \"\";\r\n EMFV_OAS_E_Color_Uncert: string = \"\";\r\n EMFV_Gliedmassen_B_Freq: number = this.Frequenz_input;\r\n EMFV_Gliedmassen_B_Color_mT: string = \"\";\r\n EMFV_Gliedmassen_B_Color_Am: string = \"\";\r\n EMFV_Gliedmassen_B_Color_mT_Uncert: string = \"\";\r\n EMFV_Gliedmassen_B_Color_Am_Uncert: string = \"\";\r\n EMFV_Therm_B_Freq: number = this.Frequenz_input;\r\n EMFV_Therm_B_Color_mT: string = \"\";\r\n EMFV_Therm_B_Color_mT_Uncert: string = \"\";\r\n EMFV_Therm_B_Color_Am: string = \"\";\r\n EMFV_Therm_B_Color_Am_Uncert: string = \"\";\r\n EMFV_Therm_E_Freq: number = this.Frequenz_input;\r\n EMFV_Therm_E_Color: string = \"\";\r\n EMFV_Therm_E_Color_Uncert: string = \"\";\r\n EMFV_Therm_B_Spitze_Freq: number = this.Frequenz_input;\r\n EMFV_Therm_B_Spitze_Color_mT: string = \"\";\r\n EMFV_Therm_B_Spitze_Color_mT_Uncert: string = \"\";\r\n EMFV_Therm_B_Spitze_Color_Am: string = \"\";\r\n EMFV_Therm_B_Spitze_Color_Am_Uncert: string = \"\";\r\n EMFV_Therm_E_Spitze_Freq: number = this.Frequenz_input;\r\n EMFV_Therm_E_Spitze_Color: string = \"\";\r\n EMFV_Therm_E_Spitze_Color_Uncert: string = \"\";\r\n FB451_Aktiv_B_Freq: number = this.Frequenz_input;\r\n FB451_Aktiv_B_Color_mT: string = \"\";\r\n FB451_Aktiv_B_Color_Am: string = \"\";\r\n FB451_Aktiv_B_Color_mT_Uncert: string = \"\";\r\n FB451_Aktiv_B_Color_Am_Uncert: string = \"\";\r\n FB451_Aktiv_E_Freq: number = this.Frequenz_input;\r\n FB451_Aktiv_E_Color: string = \"\";\r\n FB451_Aktiv_E_Color_Uncert: string = \"\";\r\n FB451_Passiv_B_Freq: number = this.Frequenz_input;\r\n FB451_Passiv_B_Color_mT: string = \"\";\r\n FB451_Passiv_B_Color_Am: string = \"\";\r\n FB451_Passiv_B_Color_mT_Uncert: string = \"\";\r\n FB451_Passiv_B_Color_Am_Uncert: string = \"\";\r\n FB451_Passiv_E_Freq: number = this.Frequenz_input;\r\n FB451_Passiv_E_Color: string = \"\";\r\n FB451_Passiv_E_Color_Uncert: string = \"\";\r\n EU1999_B_Freq: number = this.Frequenz_input;\r\n EU1999_B_Color_mT: string = \"\";\r\n EU1999_B_Color_Am: string = \"\";\r\n EU1999_B_Color_mT_Uncert: string = \"\";\r\n EU1999_B_Color_Am_Uncert: string = \"\";\r\n EU1999_E_Freq: number = this.Frequenz_input;\r\n EU1999_E_Color: string = \"\";\r\n EU1999_E_Color_Uncert: string = \"\";\r\n EU1999_Spitze_B_Freq: number = this.Frequenz_input;\r\n EU1999_Spitze_B_Color_mT: string = \"\";\r\n EU1999_Spitze_B_Color_Am: string = \"\";\r\n EU1999_Spitze_B_Color_mT_Uncert: string = \"\";\r\n EU1999_Spitze_B_Color_Am_Uncert: string = \"\"; \r\n EU1999_Spitze_E_Freq: number = this.Frequenz_input;\r\n EU1999_Spitze_E_Color: string = \"\";\r\n EU1999_Spitze_E_Color_Uncert: string = \"\";\r\n BImSchV_NF_B_Freq: number = this.Frequenz_input;\r\n BImSchV_NF_B_Color_mT: string = \"\";\r\n BImSchV_NF_B_Color_Am: string = \"\";\r\n BImSchV_NF_B_Color_mT_Uncert: string = \"\";\r\n BImSchV_NF_B_Color_Am_Uncert: string = \"\";\r\n BImSchV_NF_E_Freq: number = this.Frequenz_input;\r\n BImSchV_NF_E_Color: string = \"\";\r\n BImSchV_NF_E_Color_Uncert: string = \"\";\r\n BImSchV_HF_B_Freq: number = this.Frequenz_input;\r\n BImSchV_HF_B_Color_mT: string = \"\";\r\n BImSchV_HF_B_Color_Am: string = \"\";\r\n BImSchV_HF_B_Color_mT_Uncert: string = \"\";\r\n BImSchV_HF_B_Color_Am_Uncert: string = \"\";\r\n BImSchV_HF_E_Freq: number = this.Frequenz_input;\r\n BImSchV_HF_E_Color: string = \"\";\r\n BImSchV_HF_E_Color_Uncert: string = \"\"; \r\n BImSchV_Spitze_B_Freq: number = this.Frequenz_input;\r\n BImSchV_Spitze_B_Color_mT: string = \"\"; \r\n BImSchV_Spitze_B_Color_Am: string = \"\"; \r\n BImSchV_Spitze_B_Color_mT_Uncert: string = \"\"; \r\n BImSchV_Spitze_B_Color_Am_Uncert: string = \"\"; \r\n BImSchV_Spitze_E_Freq: number = this.Frequenz_input;\r\n BImSchV_Spitze_E_Color: string = \"\"; \r\n BImSchV_Spitze_E_Color_Uncert: string = \"\"; \r\n DGUVV15_Expo2_B_Freq: number = this.Frequenz_input;\r\n DGUVV15_Expo2_B_Color_mT: string = \"\";\r\n DGUVV15_Expo2_B_Color_Am: string = \"\";\r\n DGUVV15_Expo2_B_Color_mT_Uncert: string = \"\";\r\n DGUVV15_Expo2_B_Color_Am_Uncert: string = \"\";\r\n DGUVV15_Expo1_B_Freq: number = this.Frequenz_input;\r\n DGUVV15_Expo1_B_Color_mT: string = \"\";\r\n DGUVV15_Expo1_B_Color_Am: string = \"\";\r\n DGUVV15_Expo1_B_Color_mT_Uncert: string = \"\";\r\n DGUVV15_Expo1_B_Color_Am_Uncert: string = \"\";\r\n DGUVV15_ExpoEr_B_Freq: number = this.Frequenz_input;\r\n DGUVV15_ExpoEr_B_Color_mT: string = \"\";\r\n DGUVV15_ExpoEr_B_Color_Am: string = \"\";\r\n DGUVV15_ExpoEr_B_Color_mT_Uncert: string = \"\";\r\n DGUVV15_ExpoEr_B_Color_Am_Uncert: string = \"\";\r\n DGUVV15_ExpoEr_Spitze_B_Freq: number = this.Frequenz_input;\r\n DGUVV15_ExpoEr_Spitze_B_Color_mT: string = \"\";\r\n DGUVV15_ExpoEr_Spitze_B_Color_Am: string = \"\";\r\n DGUVV15_ExpoEr_Spitze_B_Color_mT_Uncert: string = \"\";\r\n DGUVV15_ExpoEr_Spitze_B_Color_Am_Uncert: string = \"\";\r\n DGUVV15_Expo2_E_Freq: number = this.Frequenz_input;\r\n DGUVV15_Expo2_E_Color: string = \"\";\r\n DGUVV15_Expo2_E_Color_Uncert: string = \"\"; \r\n DGUVV15_Expo1_E_Freq: number = this.Frequenz_input;\r\n DGUVV15_Expo1_E_Color: string = \"\";\r\n DGUVV15_Expo1_E_Color_Uncert: string = \"\"; \r\n DGUVV15_ExpoEr_E_Freq: number = this.Frequenz_input;\r\n DGUVV15_ExpoEr_E_Color: string = \"\";\r\n DGUVV15_ExpoEr_E_Color_Uncert: string = \"\"; \r\n DGUVV15_ExpoEr_Spitze_E_Freq: number = this.Frequenz_input;\r\n DGUVV15_ExpoEr_Spitze_E_Color: string = \"\";\r\n DGUVV15_ExpoEr_Spitze_E_Color_Uncert: string = \"\"; \r\n\r\n // Functions for EU2013 limits\r\n public EU2013_Gliedmassen_B = EU2013_Gliedmassen_B;\r\n public EU2013_OAS_B = EU2013_OAS_B;\r\n public EU2013_UAS_B = EU2013_UAS_B;\r\n public EU2013_Thermisch_B = EU2013_Thermisch_B;\r\n public EU2013_OAS_E = EU2013_OAS_E;\r\n public EU2013_UAS_E = EU2013_UAS_E;\r\n public EU2013_Thermisch_E = EU2013_Thermisch_E;\r\n public updateEU2013_B_Regelwerk = updateEU2013_B_Regelwerk;\r\n public updateEU2013_E_Regelwerk = updateEU2013_E_Regelwerk;\r\n public updateEU2013_B_Frequenz = updateEU2013_B_Frequenz;\r\n public updateEU2013_E_Frequenz = updateEU2013_E_Frequenz;\r\n\r\n // Functions for EMFV limits\r\n public EMFV_Gliedmassen_B = EMFV_Gliedmassen_B;\r\n public EMFV_OAS_B = EMFV_OAS_B;\r\n public EMFV_UAS_B = EMFV_UAS_B;\r\n public EMFV_Thermisch_B = EMFV_Thermisch_B;\r\n public EMFV_Thermisch_Spitze_B = EMFV_Thermisch_Spitze_B;\r\n public EMFV_OAS_E = EMFV_OAS_E;\r\n public EMFV_UAS_E = EMFV_UAS_E;\r\n public EMFV_Thermisch_E = EMFV_Thermisch_E;\r\n public EMFV_Thermisch_Spitze_E = EMFV_Thermisch_Spitze_E;\r\n public updateEMFV_B_Regelwerk = updateEMFV_B_Regelwerk;\r\n public updateEMFV_E_Regelwerk = updateEMFV_E_Regelwerk;\r\n public updateEMFV_B_Frequenz = updateEMFV_B_Frequenz;\r\n public updateEMFV_E_Frequenz = updateEMFV_E_Frequenz;\r\n\r\n // Functions for FB451 limits\r\n public FB451_Passiv_B = FB451_Passiv_B;\r\n public FB451_Passiv_E = FB451_Passiv_E;\r\n public FB451_Aktiv_B = FB451_Aktiv_B;\r\n public FB451_Aktiv_E = FB451_Aktiv_E;\r\n public updateFB451_B_Frequenz = updateFB451_B_Frequenz;\r\n public updateFB451_E_Frequenz = updateFB451_E_Frequenz;\r\n public updateFB451_B_Regelwerk = updateFB451_B_Regelwerk;\r\n public updateFB451_E_Regelwerk = updateFB451_E_Regelwerk;\r\n\r\n // Functions for EU1999 limits\r\n public EU1999_B = EU1999_B;\r\n public EU1999_E = EU1999_E;\r\n public EU1999_B_Spitze = EU1999_B_Spitze;\r\n public EU1999_E_Spitze = EU1999_E_Spitze;\r\n public updateEU1999_B_Frequenz = updateEU1999_B_Frequenz;\r\n public updateEU1999_E_Frequenz = updateEU1999_E_Frequenz;\r\n public updateEU1999_B_Regelwerk = updateEU1999_B_Regelwerk;\r\n public updateEU1999_E_Regelwerk = updateEU1999_E_Regelwerk;\r\n\r\n // Functions for BImSchV limits\r\n public BImSchV_B_NF = BImSchV_B_NF;\r\n public BImSchV_E_NF = BImSchV_E_NF;\r\n public BImSchV_B_HF = BImSchV_B_HF;\r\n public BImSchV_E_HF = BImSchV_E_HF;\r\n public BImSchV_B_Spitze = BImSchV_B_Spitze;\r\n public BImSchV_E_Spitze = BImSchV_E_Spitze;\r\n public updateBImSchV_B_Frequenz = updateBImSchV_B_Frequenz;\r\n public updateBImSchV_E_Frequenz = updateBImSchV_E_Frequenz;\r\n public updateBImSchV_B_Regelwerk = updateBImSchV_B_Regelwerk;\r\n public updateBImSchV_E_Regelwerk = updateBImSchV_E_Regelwerk;\r\n\r\n // Functions for DGUV V15 limits\r\n public V15_Expo2_E = V15_Expo2_E;\r\n public V15_Expo2_B = V15_Expo2_B;\r\n public V15_Expo1_E = V15_Expo1_E;\r\n public V15_Expo1_B = V15_Expo1_B;\r\n public V15_ExpoEr_E = V15_ExpoEr_E;\r\n public V15_ExpoEr_B = V15_ExpoEr_B;\r\n public V15_ExpoEr_Spitze_E = V15_ExpoEr_Spitze_E;\r\n public V15_ExpoEr_Spitze_B = V15_ExpoEr_Spitze_B;\r\n public updateDGUVV15_B_Regelwerk = updateDGUVV15_B_Regelwerk;\r\n public updateDGUVV15_E_Regelwerk = updateDGUVV15_E_Regelwerk;\r\n public updateDGUVV15_B_Frequenz = updateDGUVV15_B_Frequenz;\r\n public updateDGUVV15_E_Frequenz = updateDGUVV15_E_Frequenz;\r\n\r\n /** Element reference to bfeld canvas */\r\n @ViewChild('BFeldChart') bFeldRef: ElementRef;\r\n @ViewChild('EFeldChart') eFeldRef: ElementRef;\r\n\r\n constructor(\r\n public translate: TranslateService,\r\n public tabService: DefaultTabService\r\n ) {\r\n this.currentLanguage = translate.currentLang;\r\n }\r\n\r\n ngOnInit() {\r\n this.Frequenz = this.multiplier * this.Frequenz_input;\r\n this.Frequenz_min = this.multiplier * this.Frequenz_input_min;\r\n this.Frequenz_max = this.multiplier * this.Frequenz_input_max;\r\n\r\n }\r\n\r\n ngAfterViewInit() {\r\n // Charts erstellen\r\n this.drawChartB();\r\n this.drawChartE();\r\n\r\n // Chart updaten\r\n this.updateAll();\r\n\r\n this.translate.onLangChange.subscribe((languageChange: LangChangeEvent) => {\r\n // Chart updaten\r\n this.currentLanguage = this.translate.currentLang;\r\n this.BFeldChart.destroy();\r\n this.EFeldChart.destroy();\r\n this.drawChartB();\r\n this.drawChartE();\r\n this.updateAll();\r\n });\r\n\r\n }\r\n\r\n switchToHelpTab() {\r\n this.tabService.choseCurrentItem('HELP.NAME');\r\n }\r\n\r\n calculateFrequencies() {\r\n if (this.minSucheCheck) {\r\n //use multiplier and swap if necessary \r\n if (this.Frequenz_input_min <= this.Frequenz_input_max) {\r\n this.Frequenz_min = this.multiplier * this.Frequenz_input_min;\r\n this.Frequenz_max = this.multiplier * this.Frequenz_input_max;\r\n }\r\n else {\r\n this.Frequenz_min = this.multiplier * this.Frequenz_input_max;\r\n this.Frequenz_max = this.multiplier * this.Frequenz_input_min;\r\n }\r\n\r\n //Einzeichnen von grauem Band zwischen min/max \r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 1].backgroundColor = 'rgba(200, 200, 200, 0.4)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 1].data = [{ x: this.Frequenz_min, y: Infinity }, { x: this.Frequenz_max, y: Infinity }];\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 1].backgroundColor = 'rgba(200, 200, 200, 0.4)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 1].data = [{ x: this.Frequenz_min, y: Infinity }, { x: this.Frequenz_max, y: Infinity }];\r\n\r\n // Welche Regelwerke?\r\n // B Schwellen (2. Spalte) mal 1000 um von T nach mT zu kommen\r\n if (this.EU2013) {\r\n this.EU2013_UAS_B_Freq = this.minFromTable(Schwellen_EU2013_UAS_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EU2013_UAS_B);\r\n this.EU2013_OAS_B_Freq = this.minFromTable(Schwellen_EU2013_OAS_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EU2013_OAS_B);\r\n this.EU2013_Gliedmassen_B_Freq = this.minFromTable(Schwellen_EU2013_Gliedmassen_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EU2013_Gliedmassen_B);\r\n this.EU2013_Therm_B_Freq = this.minFromTable(Schwellen_EU2013_Therm_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EU2013_Thermisch_B);\r\n this.EU2013_UAS_E_Freq = this.minFromTable(Schwellen_EU2013_UAS_E, this.EU2013_UAS_E);\r\n this.EU2013_OAS_E_Freq = this.minFromTable(Schwellen_EU2013_OAS_E, this.EU2013_OAS_E);\r\n this.EU2013_Therm_E_Freq = this.minFromTable(Schwellen_EU2013_Therm_E, this.EU2013_Thermisch_E);\r\n }\r\n\r\n if (this.EMFV) {\r\n this.EMFV_UAS_B_Freq = this.minFromTable(Schwellen_EMFV_UAS_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EMFV_UAS_B);\r\n this.EMFV_OAS_B_Freq = this.minFromTable(Schwellen_EMFV_OAS_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EMFV_OAS_B);\r\n this.EMFV_Gliedmassen_B_Freq = this.minFromTable(Schwellen_EMFV_Gliedmassen_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EMFV_Gliedmassen_B);\r\n this.EMFV_Therm_B_Freq = this.minFromTable(Schwellen_EMFV_Therm_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EMFV_Thermisch_B);\r\n this.EMFV_Therm_B_Spitze_Freq = this.minFromTable(Schwellen_EMFV_Therm_B_Spitze.map(function (value) { return [value[0], value[1] * 1000]; }), this.EMFV_Thermisch_Spitze_B);\r\n this.EMFV_UAS_E_Freq = this.minFromTable(Schwellen_EMFV_UAS_E, this.EMFV_UAS_E);\r\n this.EMFV_OAS_E_Freq = this.minFromTable(Schwellen_EMFV_OAS_E, this.EMFV_OAS_E);\r\n this.EMFV_Therm_E_Freq = this.minFromTable(Schwellen_EMFV_Therm_E, this.EMFV_Thermisch_E);\r\n this.EMFV_Therm_E_Spitze_Freq = this.minFromTable(Schwellen_EMFV_Therm_E_Spitze, this.EMFV_Thermisch_Spitze_E);\r\n }\r\n\r\n if (this.FB451) {\r\n this.FB451_Aktiv_B_Freq = this.minFromTable(Schwellen_FB451_Aktiv_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.FB451_Aktiv_B);\r\n this.FB451_Aktiv_E_Freq = this.minFromTable(Schwellen_FB451_Aktiv_E, this.FB451_Aktiv_E);\r\n this.FB451_Passiv_B_Freq = this.minFromTable(Schwellen_FB451_Passiv_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.FB451_Passiv_B);\r\n this.FB451_Passiv_E_Freq = this.minFromTable(Schwellen_FB451_Passiv_E, this.FB451_Passiv_E);\r\n }\r\n\r\n if (this.EU1999) {\r\n this.EU1999_B_Freq = this.minFromTable(Schwellen_EU1999_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.EU1999_B);\r\n this.EU1999_E_Freq = this.minFromTable(Schwellen_EU1999_E, this.EU1999_E);\r\n this.EU1999_Spitze_B_Freq = this.minFromTable(Schwellen_EU1999_B_Spitze.map(function (value) { return [value[0], value[1] * 1000]; }), this.EU1999_B_Spitze);\r\n this.EU1999_Spitze_E_Freq = this.minFromTable(Schwellen_EU1999_E_Spitze, this.EU1999_E_Spitze);\r\n }\r\n\r\n if (this.BImSchV) {\r\n this.BImSchV_NF_B_Freq = this.minFromTable(Schwellen_BImSchV_NF_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.BImSchV_B_NF);\r\n this.BImSchV_HF_B_Freq = this.minFromTable(Schwellen_BImSchV_HF_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.BImSchV_B_HF);\r\n this.BImSchV_Spitze_B_Freq = this.minFromTable(Schwellen_BImSchV_Spitze_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.BImSchV_B_Spitze);\r\n this.BImSchV_NF_E_Freq = this.minFromTable(Schwellen_BImSchV_NF_E, this.BImSchV_E_NF);\r\n this.BImSchV_HF_E_Freq = this.minFromTable(Schwellen_BImSchV_HF_E, this.BImSchV_E_HF);\r\n this.BImSchV_Spitze_E_Freq = this.minFromTable(Schwellen_BImSchV_Spitze_E, this.BImSchV_E_Spitze);\r\n }\r\n\r\n if (this.DGUVV15) {\r\n this.DGUVV15_Expo2_B_Freq = this.minFromTable(Schwellen_DGUVV15_Expo2_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.V15_Expo2_B);\r\n this.DGUVV15_Expo1_B_Freq = this.minFromTable(Schwellen_DGUVV15_Expo1_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.V15_Expo1_B);\r\n this.DGUVV15_Expo2_E_Freq = this.minFromTable(Schwellen_DGUVV15_Expo2_E, this.V15_Expo2_E);\r\n this.DGUVV15_Expo1_E_Freq = this.minFromTable(Schwellen_DGUVV15_Expo1_E, this.V15_Expo1_E);\r\n this.DGUVV15_ExpoEr_B_Freq = this.minFromTable(Schwellen_DGUVV15_ExpoEr_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.V15_ExpoEr_B);\r\n this.DGUVV15_ExpoEr_E_Freq = this.minFromTable(Schwellen_DGUVV15_ExpoEr_E, this.V15_ExpoEr_E);\r\n this.DGUVV15_ExpoEr_Spitze_B_Freq = this.minFromTable(Schwellen_DGUVV15_ExpoEr_Spitze_B.map(function (value) { return [value[0], value[1] * 1000]; }), this.V15_ExpoEr_Spitze_B);\r\n this.DGUVV15_ExpoEr_Spitze_E_Freq = this.minFromTable(Schwellen_DGUVV15_ExpoEr_Spitze_E, this.V15_ExpoEr_Spitze_E);\r\n }\r\n }\r\n else {\r\n // Frequenz mit Multiplier berechnen\r\n this.Frequenz = this.multiplier * this.Frequenz_input;\r\n\r\n // Frequenzband ausblenden\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 1].backgroundColor = 'rgba(200, 200, 200, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 1].backgroundColor = 'rgba(200, 200, 200, 0)';\r\n\r\n // Welche Regelwerke?\r\n if (this.EU2013) {\r\n this.EU2013_UAS_B_Freq = this.Frequenz;\r\n this.EU2013_UAS_E_Freq = this.Frequenz;\r\n this.EU2013_OAS_B_Freq = this.Frequenz;\r\n this.EU2013_OAS_E_Freq = this.Frequenz;\r\n this.EU2013_Gliedmassen_B_Freq = this.Frequenz;\r\n this.EU2013_Therm_B_Freq = this.Frequenz;\r\n this.EU2013_Therm_E_Freq = this.Frequenz;\r\n }\r\n\r\n if (this.EMFV) {\r\n this.EMFV_UAS_B_Freq = this.Frequenz;\r\n this.EMFV_UAS_E_Freq = this.Frequenz;\r\n this.EMFV_OAS_B_Freq = this.Frequenz;\r\n this.EMFV_OAS_E_Freq = this.Frequenz;\r\n this.EMFV_Gliedmassen_B_Freq = this.Frequenz;\r\n this.EMFV_Therm_B_Freq = this.Frequenz;\r\n this.EMFV_Therm_B_Spitze_Freq = this.Frequenz;\r\n this.EMFV_Therm_E_Freq = this.Frequenz;\r\n this.EMFV_Therm_E_Spitze_Freq = this.Frequenz;\r\n }\r\n\r\n if (this.FB451) {\r\n this.FB451_Aktiv_B_Freq = this.Frequenz;\r\n this.FB451_Aktiv_E_Freq = this.Frequenz;\r\n this.FB451_Passiv_B_Freq = this.Frequenz;\r\n this.FB451_Passiv_E_Freq = this.Frequenz;\r\n }\r\n\r\n if (this.EU1999) {\r\n this.EU1999_B_Freq = this.Frequenz;\r\n this.EU1999_E_Freq = this.Frequenz;\r\n this.EU1999_Spitze_B_Freq = this.Frequenz;\r\n this.EU1999_Spitze_E_Freq = this.Frequenz;\r\n }\r\n\r\n if (this.BImSchV) {\r\n this.BImSchV_NF_B_Freq = this.Frequenz;\r\n this.BImSchV_HF_B_Freq = this.Frequenz;\r\n this.BImSchV_Spitze_B_Freq = this.Frequenz;\r\n this.BImSchV_NF_E_Freq = this.Frequenz;\r\n this.BImSchV_HF_E_Freq = this.Frequenz;\r\n this.BImSchV_Spitze_E_Freq = this.Frequenz;\r\n }\r\n\r\n if (this.DGUVV15) {\r\n this.DGUVV15_Expo2_B_Freq = this.Frequenz;\r\n this.DGUVV15_Expo1_B_Freq = this.Frequenz;\r\n this.DGUVV15_Expo2_E_Freq = this.Frequenz;\r\n this.DGUVV15_Expo1_E_Freq = this.Frequenz;\r\n this.DGUVV15_ExpoEr_B_Freq = this.Frequenz;\r\n this.DGUVV15_ExpoEr_E_Freq = this.Frequenz;\r\n this.DGUVV15_ExpoEr_Spitze_B_Freq = this.Frequenz;\r\n this.DGUVV15_ExpoEr_Spitze_E_Freq = this.Frequenz;\r\n }\r\n }\r\n }\r\n\r\n minFromTable(limits, limit_func: (number) => number) {\r\n let limit_frequency: number = 100;\r\n // add boundary values to array\r\n limits = [...limits, [this.Frequenz_min, limit_func(this.Frequenz_min)], [this.Frequenz_max, limit_func(this.Frequenz_max)]];\r\n\r\n //sort by first column in ascending order\r\n limits.sort(function (a, b) { return a[0] - b[0] });\r\n\r\n //remove entries with frequencies smaller and larger to the boundary frequencies\r\n //maps to first column: limits.map(x=> x[0])\r\n let index_start = (limits.map(x => x[0])).findIndex(element => element == this.Frequenz_min);\r\n let index_stop = (limits.map(x => x[0])).findIndex(element => element == this.Frequenz_max);\r\n\r\n //remove the last elements\r\n limits.splice(index_stop + 1, limits.length - index_stop - 1);\r\n //remove the first elements\r\n limits.splice(0, index_start);\r\n\r\n //sort by 2nd column in ascending order to find the minimum (takes care of multiple same values)\r\n //limits.sort(function (a, b) {return a[1] - b[1]});\r\n //sort by 2nd column in ascending order to find the minimum (takes care of NaN values and multiple same values)\r\n //https://stackoverflow.com/questions/17557807/javascript-how-do-you-sort-an-array-that-includes-nans\r\n limits.sort(function (a, b) {\r\n if (isFinite(a[1] - b[1])) {\r\n return a[1] - b[1];\r\n } else {\r\n return isFinite(a[1]) ? -1 : 1;\r\n }\r\n });\r\n\r\n //first row, first entry is the frequency we're looking for\r\n limit_frequency = limits[0][0];\r\n\r\n //console.log(limits);\r\n return limit_frequency;\r\n }\r\n\r\n updateAll() {\r\n // Chart Höhe anpassen - zwischen 500 & 700 je nach Anzahl der Regelwerke\r\n let count = 0;\r\n if (this.EU2013) count++;\r\n if (this.EMFV) count++;\r\n if (this.FB451) count++;\r\n if (this.EU1999) count++;\r\n if (this.BImSchV) count++;\r\n if (this.DGUVV15) count++;\r\n let height = 500;\r\n let height_px = '500px';\r\n if (count == 2) {\r\n height = 600;\r\n height_px = '600px';\r\n }\r\n if (count > 2) {\r\n height = 700;\r\n height_px = '700px';\r\n }\r\n this.BFeldChart.canvas.parentNode.style.height = height_px;\r\n this.BFeldChart.canvas.height = height;\r\n this.EFeldChart.canvas.parentNode.style.height = height_px;\r\n this.EFeldChart.canvas.height = height;\r\n\r\n this.EFeldChart.canvas.width = 900;\r\n this.EFeldChart.canvas.parentNode.style.width = '900px';\r\n this.BFeldChart.canvas.width = 900;\r\n this.BFeldChart.canvas.parentNode.style.width = '900px';\r\n\r\n // Datasets löschen\r\n this.BFeldChart.data.datasets = [];\r\n this.EFeldChart.data.datasets = [];\r\n\r\n // Welche Regelwerke?\r\n if (this.EU2013) {\r\n this.updateEU2013_B_Regelwerk();\r\n this.updateEU2013_E_Regelwerk();\r\n }\r\n\r\n if (this.EMFV) {\r\n this.updateEMFV_B_Regelwerk();\r\n this.updateEMFV_E_Regelwerk();\r\n }\r\n\r\n if (this.FB451) {\r\n this.updateFB451_B_Regelwerk();\r\n this.updateFB451_E_Regelwerk();\r\n }\r\n\r\n if (this.DGUVV15) {\r\n this.updateDGUVV15_B_Regelwerk();\r\n this.updateDGUVV15_E_Regelwerk();\r\n }\r\n\r\n if (this.EU1999) {\r\n this.updateEU1999_B_Regelwerk();\r\n this.updateEU1999_E_Regelwerk();\r\n }\r\n\r\n if (this.BImSchV) {\r\n this.updateBImSchV_B_Regelwerk();\r\n this.updateBImSchV_E_Regelwerk();\r\n }\r\n\r\n // Unsicherheitsfaktor mit einberechnen \r\n if(this.UnsicherheitCheck) \r\n {\r\n this.BFeldChart.data.datasets.forEach(element => {\r\n element.data.forEach(element => {\r\n element.y = element.y / this.FaktorU;\r\n });\r\n });\r\n this.EFeldChart.data.datasets.forEach(element => {\r\n element.data.forEach(element => {\r\n element.y = element.y / this.FaktorU;\r\n });\r\n }); \r\n }\r\n \r\n // Effektiv- und Spitzenwert für Bewertung anhängen. Wichtig: E&B trennen, da eine Speicherreferenz weitergegeben wird und keine Kopie\r\n let Evaluation_data_B = [\r\n {\r\n label: '', //makes it disappear in the legend \r\n data: [\r\n {\r\n x: 50,\r\n y: 0\r\n }\r\n ],\r\n type: 'line',\r\n borderColor: 'rgba(0, 0, 0, 0)',\r\n pointBackgroundColor: 'rgba(0, 0, 0, 0)',\r\n fill: false,\r\n pointRadius: 4,\r\n pointStyle: 'circle',\r\n borderWidth: 2\r\n },\r\n {\r\n label: '', //makes it disappear in the legend \r\n data: [\r\n {\r\n x: 50,\r\n y: 0\r\n }\r\n ],\r\n type: 'line',\r\n borderColor: 'rgba(0, 0, 0, 0)',\r\n pointBackgroundColor: 'rgba(0, 0, 0, 0)',\r\n fill: false,\r\n pointRadius: 5,\r\n pointStyle: 'triangle',\r\n borderWidth: 2\r\n }\r\n ];\r\n\r\n // Effektiv- und Spitzenwert für Bewertung anhängen. Wichtig: E&B trennen, da eine Speicherreferenz weitergegeben wird und keine Kopie\r\n let Evaluation_data_E = [\r\n {\r\n label: '', //makes it disappear in the legend \r\n data: [\r\n {\r\n x: 50,\r\n y: 0\r\n }\r\n ],\r\n type: 'line',\r\n borderColor: 'rgba(0, 0, 0, 0)',\r\n pointBackgroundColor: 'rgba(0, 0, 0, 0)',\r\n fill: false,\r\n pointRadius: 4,\r\n pointStyle: 'circle',\r\n borderWidth: 2\r\n },\r\n {\r\n label: '', //makes it disappear in the legend \r\n data: [\r\n {\r\n x: 50,\r\n y: 0\r\n }\r\n ],\r\n type: 'line',\r\n borderColor: 'rgba(0, 0, 0, 0)',\r\n pointBackgroundColor: 'rgba(0, 0, 0, 0)',\r\n fill: false,\r\n pointRadius: 5,\r\n pointStyle: 'triangle',\r\n borderWidth: 2\r\n }\r\n ];\r\n\r\n // An die Chart Datasets hinten dran hängen.\r\n this.BFeldChart.data.datasets = [...this.BFeldChart.data.datasets, ...Evaluation_data_B];\r\n this.EFeldChart.data.datasets = [...this.EFeldChart.data.datasets, ...Evaluation_data_E];\r\n\r\n // Frequenzband in grau hinzufügen\r\n //https://www.chartjs.org/docs/next/samples/area/line-boundaries.html#fill:-start\r\n let Band_data = [\r\n {\r\n label: '', //makes it disappear in the legend\r\n lineTension: 0,\r\n data: [\r\n { x: 10, y: Infinity },\r\n { x: 100, y: Infinity }\r\n ],\r\n fill: 'end',\r\n borderColor: 'rgba(200, 200, 200, 0)', //makes the line transparent\r\n backgroundColor: 'rgba(200, 200, 200, 0)', //0 for transparent, 0.4 for gray\r\n pointRadius: 0\r\n }\r\n ];\r\n // An die Chart Datasets hinten dran hängen\r\n this.BFeldChart.data.datasets = [...this.BFeldChart.data.datasets, ...Band_data];\r\n this.EFeldChart.data.datasets = [...this.EFeldChart.data.datasets, ...Band_data];\r\n\r\n // Frequenz Update für Frequenz Marker Punkte\r\n this.updateFrequenz();\r\n\r\n this.BFeldChart.update();\r\n this.EFeldChart.update();\r\n }\r\n\r\n updateFrequenz() {\r\n this.calculateFrequencies();\r\n this.updateFrequenzB();\r\n this.updateFrequenzE();\r\n this.evaluateB();\r\n this.evaluateE();\r\n }\r\n\r\n updateFrequenzB() {\r\n // Index wird benötigt damit die richtigen Elemente im Chart Dataset indiziert werden können\r\n let index: number = 1;\r\n\r\n // Welche Regelwerke?\r\n if (this.EU2013) {\r\n this.updateEU2013_B_Frequenz(index);\r\n // erhöhe index\r\n index = index + 8;\r\n }\r\n\r\n if (this.EMFV) {\r\n this.updateEMFV_B_Frequenz(index);\r\n // erhöhe index\r\n index = index + 10;\r\n }\r\n\r\n if (this.FB451) {\r\n this.updateFB451_B_Frequenz(index);\r\n // erhöhe index\r\n index = index + 4;\r\n }\r\n\r\n if (this.DGUVV15) {\r\n this.updateDGUVV15_B_Frequenz(index);\r\n // erhöhe index\r\n index = index + 8;\r\n }\r\n\r\n if (this.EU1999) {\r\n this.updateEU1999_B_Frequenz(index);\r\n // erhöhe index\r\n index = index + 4;\r\n }\r\n\r\n if (this.BImSchV) {\r\n this.updateBImSchV_B_Frequenz(index);\r\n // erhöhe index\r\n index = index + 6;\r\n }\r\n\r\n this.BFeldChart.update();\r\n }\r\n\r\n updateFrequenzE() {\r\n // Index wird benötigt damit die richtigen Elemente im Chart Dataset indiziert werden können\r\n let index: number = 1;\r\n\r\n // Welche Regelwerke?\r\n if (this.EU2013) {\r\n this.updateEU2013_E_Frequenz(index);\r\n // erhöhe index\r\n index = index + 6;\r\n }\r\n\r\n if (this.EMFV) {\r\n this.updateEMFV_E_Frequenz(index);\r\n // erhöhe index\r\n index = index + 8;\r\n }\r\n\r\n if (this.FB451) {\r\n this.updateFB451_E_Frequenz(index);\r\n // erhöhe index\r\n index = index + 4;\r\n }\r\n\r\n if (this.DGUVV15) {\r\n this.updateDGUVV15_E_Frequenz(index);\r\n // erhöhe index\r\n index = index + 8;\r\n }\r\n\r\n if (this.EU1999) {\r\n this.updateEU1999_E_Frequenz(index);\r\n // erhöhe index\r\n index = index + 4;\r\n }\r\n\r\n if (this.BImSchV) {\r\n this.updateBImSchV_E_Frequenz(index);\r\n // erhöhe index\r\n index = index + 6;\r\n }\r\n\r\n this.EFeldChart.update();\r\n }\r\n\r\n drawChartB() {\r\n if (this.translate.currentLang === \"de\") {\r\n // Pass native element via element ref\r\n this.BFeldChart = new Chart(this.bFeldRef.nativeElement, {\r\n type: 'line',\r\n data: {\r\n datasets: []\r\n },\r\n options: {\r\n // do not react to events and do not show tooltips\r\n tooltips: { enabled: false },\r\n maintainAspectRatio: false,\r\n // animation: { duration: 0 }, //turns off all animations\r\n events: [],\r\n legend: {\r\n display: true,\r\n labels: {\r\n filter: function (item, chart) {\r\n // Logic to remove a particular legend item goes here\r\n return !(item.text.includes('Wert') || item.text === '');\r\n },\r\n usePointStyle: true\r\n },\r\n // Standardverhalten für onClick ändern - es soll nichts passieren\r\n onClick: function (e, legendItem, legend) { }\r\n },\r\n layout: {\r\n padding: {\r\n left: 0,\r\n right: 0,\r\n top: 50,\r\n bottom: 0\r\n }\r\n },\r\n scales: {\r\n xAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Frequenz'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [0.01, 1, 1e3, 1e6, 1e9, 3e11];\r\n return [0.01, 0.1, 1, 10, 100, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11, 3e11];\r\n },\r\n ticks: {\r\n min: 0.01,\r\n max: 3e11,\r\n\r\n userCallback: function (tick) {\r\n if (tick === 1e-2) {\r\n return '0,01 Hz';\r\n }\r\n if (tick === 1) {\r\n return '1 Hz';\r\n }\r\n if (tick === 1e3) {\r\n return '1 kHz';\r\n }\r\n if (tick === 1e6) {\r\n return '1 MHz';\r\n }\r\n if (tick === 1e9) {\r\n return '1 GHz';\r\n }\r\n if (tick === 3e11) {\r\n return '300 GHz';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n }\r\n ],\r\n yAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Magnetische Flussdichte B'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [1e-8, 1e-6, 1e-3, 1, 10];\r\n return [1e-8, 1e-7, 1e-6, 1e-5, 1e-4, 1e-3, 1e-2, 1e-1, 1, 10];\r\n },\r\n\r\n ticks: {\r\n min: 1e-8,\r\n max: 10,\r\n userCallback: function (tick) {\r\n if (tick === 10) {\r\n return '10 T';\r\n }\r\n if (tick === 1) {\r\n return '1 T';\r\n }\r\n if (tick === 1e-3) {\r\n return '1 mT';\r\n }\r\n if (tick === 1e-6) {\r\n return '1 µT';\r\n }\r\n if (tick === 1e-8) {\r\n return '10 nT';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n },\r\n // Zweite Achse für A/m \r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Magnetische Feldstärke H'\r\n },\r\n position: 'right',\r\n display: true,\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [1e-8, 1e-6, 1e-3, 1, 10];\r\n return [1e-8, 1e-7, 1e-6, 1e-5, 1e-4, 1e-3, 1e-2, 1e-1, 1, 10];\r\n },\r\n ticks: {\r\n min: 1e-8,\r\n max: 10,\r\n userCallback: function (tick) {\r\n if (tick === 10) {\r\n return '7 958 kA/m';\r\n }\r\n if (tick === 1) {\r\n return '796 kA/m';\r\n }\r\n if (tick === 1e-3) {\r\n return '796 A/m';\r\n }\r\n if (tick === 1e-6) {\r\n return '796 mA/m';\r\n }\r\n if (tick === 1e-8) {\r\n return '7,96 mA/m';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n }\r\n ],\r\n }\r\n }\r\n });\r\n }\r\n else {\r\n // Pass native element via element ref\r\n this.BFeldChart = new Chart(this.bFeldRef.nativeElement, {\r\n type: 'line',\r\n data: {\r\n datasets: []\r\n },\r\n options: {\r\n // do not react to events and do not show tooltips\r\n tooltips: { enabled: false },\r\n maintainAspectRatio: false,\r\n events: [],\r\n legend: {\r\n display: true,\r\n labels: {\r\n filter: function (item, chart) {\r\n // Logic to remove a particular legend item goes here\r\n return !(item.text.includes('Wert') || item.text === '');\r\n },\r\n usePointStyle: true\r\n },\r\n // Standardverhalten für onClick ändern - es soll nichts passieren\r\n onClick: function (e, legendItem, legend) { }\r\n },\r\n layout: {\r\n padding: {\r\n left: 0,\r\n right: 0,\r\n top: 50,\r\n bottom: 0\r\n }\r\n },\r\n scales: {\r\n xAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Frequency'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [0.01, 1, 1e3, 1e6, 1e9, 3e11];\r\n return [0.01, 0.1, 1, 10, 100, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11, 3e11];\r\n },\r\n ticks: {\r\n min: 0.01,\r\n max: 3e11,\r\n\r\n userCallback: function (tick) {\r\n if (tick === 1e-2) {\r\n return '0.01 Hz';\r\n }\r\n if (tick === 1) {\r\n return '1 Hz';\r\n }\r\n if (tick === 1e3) {\r\n return '1 kHz';\r\n }\r\n if (tick === 1e6) {\r\n return '1 MHz';\r\n }\r\n if (tick === 1e9) {\r\n return '1 GHz';\r\n }\r\n if (tick === 3e11) {\r\n return '300 GHz';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n }\r\n ],\r\n yAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Magnetic Flux Density B'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [1e-8, 1e-6, 1e-3, 1, 10];\r\n return [1e-8, 1e-7, 1e-6, 1e-5, 1e-4, 1e-3, 1e-2, 1e-1, 1, 10];\r\n },\r\n\r\n ticks: {\r\n min: 1e-8,\r\n max: 10,\r\n userCallback: function (tick) {\r\n if (tick === 10) {\r\n return '10 T';\r\n }\r\n if (tick === 1) {\r\n return '1 T';\r\n }\r\n if (tick === 1e-3) {\r\n return '1 mT';\r\n }\r\n if (tick === 1e-6) {\r\n return '1 µT';\r\n }\r\n if (tick === 1e-8) {\r\n return '10 nT';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n },\r\n // Zweite Achse für A/m \r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Magnetic Field Strength H'\r\n },\r\n position: 'right',\r\n display: true,\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [1e-8, 1e-6, 1e-3, 1, 10];\r\n return [1e-8, 1e-7, 1e-6, 1e-5, 1e-4, 1e-3, 1e-2, 1e-1, 1, 10];\r\n },\r\n ticks: {\r\n min: 1e-8,\r\n max: 10,\r\n userCallback: function (tick) {\r\n if (tick === 10) {\r\n return '7 958 kA/m';\r\n }\r\n if (tick === 1) {\r\n return '796 kA/m';\r\n }\r\n if (tick === 1e-3) {\r\n return '796 A/m';\r\n }\r\n if (tick === 1e-6) {\r\n return '796 mA/m';\r\n }\r\n if (tick === 1e-8) {\r\n return '7.96 mA/m';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n }\r\n ]\r\n }\r\n }\r\n });\r\n }\r\n\r\n }\r\n\r\n drawChartE() {\r\n if (this.translate.currentLang === \"de\") {\r\n // Pass native element via element ref\r\n this.EFeldChart = new Chart(this.eFeldRef.nativeElement, {\r\n type: 'line',\r\n data: {\r\n datasets: []\r\n },\r\n options: {\r\n // do not react to events and do not show tooltips\r\n tooltips: { enabled: false },\r\n events: [],\r\n maintainAspectRatio: false,\r\n legend: {\r\n display: true,\r\n labels: {\r\n filter: function (item, chart) {\r\n // Logic to remove a particular legend item goes here\r\n return !(item.text.includes('Wert') || item.text === '');\r\n },\r\n usePointStyle: true\r\n },\r\n // Standardverhalten für onClick ändern - es soll nichts passieren\r\n onClick: function (e, legendItem, legend) { }\r\n },\r\n layout: {\r\n padding: {\r\n left: 0,\r\n right: 0,\r\n top: 50,\r\n bottom: 0\r\n }\r\n },\r\n scales: {\r\n xAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Frequenz'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [0.01, 1, 1e3, 1e6, 1e9, 3e11];\r\n return [0.01, 0.1, 1, 10, 100, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11, 3e11];\r\n },\r\n ticks: {\r\n min: 0.01,\r\n max: 3e11,\r\n\r\n userCallback: function (tick) {\r\n if (tick === 1e-2) {\r\n return '0,01 Hz';\r\n }\r\n if (tick === 1) {\r\n return '1 Hz';\r\n }\r\n if (tick === 1e3) {\r\n return '1 kHz';\r\n }\r\n if (tick === 1e6) {\r\n return '1 MHz';\r\n }\r\n if (tick === 1e9) {\r\n return '1 GHz';\r\n }\r\n if (tick === 3e11) {\r\n return '300 GHz';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n }\r\n ],\r\n yAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Elektrische Feldstärke E'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n return [10, 100, 1e3, 1e4, 1e5];\r\n },\r\n\r\n ticks: {\r\n min: 10,\r\n max: 1e5,\r\n userCallback: function (tick) {\r\n if (tick === 10) {\r\n return '10 V/m';\r\n }\r\n if (tick === 100) {\r\n return '100 V/m';\r\n }\r\n if (tick === 1e3) {\r\n return '1 kV/m';\r\n }\r\n if (tick === 1e4) {\r\n return '10 kV/m';\r\n }\r\n if (tick === 1e5) {\r\n return '100 kV/m';\r\n }\r\n\r\n return tick;\r\n }\r\n }\r\n }\r\n ]\r\n }\r\n }\r\n });\r\n }\r\n else {\r\n // Pass native element via element ref\r\n this.EFeldChart = new Chart(this.eFeldRef.nativeElement, {\r\n type: 'line',\r\n data: {\r\n datasets: []\r\n },\r\n options: {\r\n // do not react to events and do not show tooltips\r\n tooltips: { enabled: false },\r\n events: [],\r\n maintainAspectRatio: false,\r\n legend: {\r\n display: true,\r\n labels: {\r\n filter: function (item, chart) {\r\n // Logic to remove a particular legend item goes here\r\n return !(item.text.includes('Wert') || item.text === '');\r\n },\r\n usePointStyle: true\r\n },\r\n // Standardverhalten für onClick ändern - es soll nichts passieren\r\n onClick: function (e, legendItem, legend) { }\r\n },\r\n layout: {\r\n padding: {\r\n left: 0,\r\n right: 0,\r\n top: 50,\r\n bottom: 0\r\n }\r\n },\r\n scales: {\r\n xAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Frequency'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n //return [0.01, 1, 1e3, 1e6, 1e9, 3e11];\r\n return [0.01, 0.1, 1, 10, 100, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11, 3e11];\r\n },\r\n ticks: {\r\n min: 0.01,\r\n max: 3e11,\r\n\r\n userCallback: function (tick) {\r\n if (tick === 1e-2) {\r\n return '0.01 Hz';\r\n }\r\n if (tick === 1) {\r\n return '1 Hz';\r\n }\r\n if (tick === 1e3) {\r\n return '1 kHz';\r\n }\r\n if (tick === 1e6) {\r\n return '1 MHz';\r\n }\r\n if (tick === 1e9) {\r\n return '1 GHz';\r\n }\r\n if (tick === 3e11) {\r\n return '300 GHz';\r\n }\r\n\r\n //return tick;\r\n return '';\r\n }\r\n }\r\n }\r\n ],\r\n yAxes: [\r\n {\r\n type: 'logarithmic',\r\n scaleLabel: {\r\n display: true,\r\n labelString: 'Electric Field Strength E'\r\n },\r\n afterBuildTicks: function (axis, ticks) {\r\n return [10, 100, 1e3, 1e4, 1e5];\r\n },\r\n\r\n ticks: {\r\n min: 10,\r\n max: 1e5,\r\n userCallback: function (tick) {\r\n if (tick === 10) {\r\n return '10 V/m';\r\n }\r\n if (tick === 100) {\r\n return '100 V/m';\r\n }\r\n if (tick === 1e3) {\r\n return '1 kV/m';\r\n }\r\n if (tick === 1e4) {\r\n return '10 kV/m';\r\n }\r\n if (tick === 1e5) {\r\n return '100 kV/m';\r\n }\r\n\r\n return tick;\r\n }\r\n }\r\n }\r\n ]\r\n }\r\n }\r\n });\r\n }\r\n }\r\n\r\n RoundDownStringComma(value: number, decimals: number) {\r\n let temp = value;\r\n let temp_str: string = \"\";\r\n if (decimals >= 0)\r\n temp = Math.floor(value * Math.pow(10, decimals)) / Math.pow(10, decimals);\r\n\r\n temp_str = temp.toString();\r\n\r\n let pre: string = \"\";\r\n let sub: string = \"\";\r\n\r\n if(temp_str.includes(\".\")) {\r\n pre = temp_str.split(\".\")[0];\r\n sub = temp_str.split(\".\")[1]; \r\n } else if (temp_str.includes(\",\")) {\r\n pre = temp_str.split(\",\")[0];\r\n sub = temp_str.split(\",\")[1]; \r\n } else {\r\n pre = temp_str;\r\n }\r\n // console.log(pre + \" \" + sub );\r\n\r\n let formattedValue: string = \"\";\r\n for (var i = 0; i < pre.length; i++) {\r\n if (i % 3 == 0 && i > 0) {\r\n formattedValue = \" \" + formattedValue;\r\n }\r\n formattedValue = pre[pre.length-1 - i] + formattedValue;\r\n } \r\n pre = formattedValue;\r\n\r\n formattedValue = \"\";\r\n for (var i = 0; i < sub.length; i++) {\r\n if (i % 3 == 0 && i > 0) {\r\n formattedValue += \" \";\r\n }\r\n formattedValue += sub[i];\r\n } \r\n sub = formattedValue;\r\n\r\n if(sub != \"\")\r\n temp_str = pre + \".\" + sub;\r\n else\r\n temp_str = pre;\r\n\r\n if (this.translate.currentLang === \"de\") {\r\n temp_str = temp_str.replace(\".\", \",\");\r\n }\r\n\r\n return temp_str;\r\n }\r\n\r\n convert_to_H(B_in_mT: number) {\r\n // hier muss Math großgeschrieben werden, in HTML über die Class property klein \r\n let H_number = B_in_mT / 1000.0 / (4.0 * Math.PI * Math.pow(10, -7));\r\n //round down to be conservative (3 decimals)\r\n return this.RoundDownStringComma(H_number, 3);\r\n }\r\n\r\n evaluateB() {\r\n if (this.BewertungCheck == true) {\r\n\r\n // Werte zur Bewertung in Grafik einblenden wenn die Werte größer Null sind\r\n // Effektivwert\r\n if (this.B_Effektiv > 0) {\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].borderColor = 'rgba(0, 0, 0, 1)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].label = this.translate.instant(\"GENERAL.RMS-LEGEND\");\r\n }\r\n else {\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].borderColor = 'rgba(0, 0, 0, 0)'\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].label = '';\r\n }\r\n // Spitzenwert\r\n if (this.B_Spitze > 0) {\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].borderColor = 'rgba(0, 0, 0, 1)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].label = this.translate.instant(\"GENERAL.PEAK-LEGEND\");\r\n }\r\n else {\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].borderColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].label = '';\r\n }\r\n\r\n // Grafik: Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // In Grafik ändern, abhängig von MinSuche\r\n let data_eff;\r\n let data_spitze;\r\n if (this.minSucheCheck == false) {\r\n data_eff = [\r\n {\r\n x: this.Frequenz,\r\n y: this.B_Effektiv / 1000,\r\n }\r\n ];\r\n data_spitze = [\r\n {\r\n x: this.Frequenz,\r\n y: this.B_Spitze / 1000,\r\n }\r\n ];\r\n }\r\n else {\r\n data_eff = [\r\n {\r\n x: this.Frequenz_min,\r\n y: this.B_Effektiv / 1000,\r\n },\r\n {\r\n x: this.Frequenz_max,\r\n y: this.B_Effektiv / 1000,\r\n }\r\n ];\r\n data_spitze = [\r\n {\r\n x: this.Frequenz_min,\r\n y: this.B_Spitze / 1000,\r\n },\r\n {\r\n x: this.Frequenz_max,\r\n y: this.B_Spitze / 1000,\r\n }\r\n ];\r\n }\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].data = data_eff;\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].data = data_spitze;\r\n }\r\n else {\r\n // In Grafik ändern, abhängig von MinSuche\r\n let data_eff;\r\n let data_spitze;\r\n if (this.minSucheCheck == false) {\r\n data_eff = [\r\n {\r\n x: this.Frequenz,\r\n y: this.B_Effektiv * (4.0 * Math.PI * Math.pow(10, -7)),\r\n }\r\n ];\r\n data_spitze = [\r\n {\r\n x: this.Frequenz,\r\n y: this.B_Spitze * (4.0 * Math.PI * Math.pow(10, -7)),\r\n }\r\n ];\r\n }\r\n else {\r\n data_eff = [\r\n {\r\n x: this.Frequenz_min,\r\n y: this.B_Effektiv * (4.0 * Math.PI * Math.pow(10, -7)),\r\n },\r\n {\r\n x: this.Frequenz_max,\r\n y: this.B_Effektiv * (4.0 * Math.PI * Math.pow(10, -7)),\r\n }\r\n ];\r\n data_spitze = [\r\n {\r\n x: this.Frequenz_min,\r\n y: this.B_Spitze * (4.0 * Math.PI * Math.pow(10, -7)),\r\n },\r\n {\r\n x: this.Frequenz_max,\r\n y: this.B_Spitze * (4.0 * Math.PI * Math.pow(10, -7)),\r\n }\r\n ];\r\n }\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].data = data_eff;\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].data = data_spitze;\r\n }\r\n\r\n // Berechne Farbe für jede angezeigte Zelle \r\n\r\n // Nur ausgewählte Werke berechnen\r\n\r\n // EU2013\r\n if (this.EU2013) {\r\n this.evaluateB_EU2013();\r\n }\r\n\r\n // EMFV\r\n if (this.EMFV) {\r\n this.evaluateB_EMFV();\r\n }\r\n\r\n // FB451\r\n if (this.FB451) {\r\n this.evaluateB_FB451();\r\n }\r\n\r\n // DGUV V15\r\n if (this.DGUVV15) {\r\n this.evaluateB_DGUVV15();\r\n }\r\n\r\n // EU1999\r\n if (this.EU1999) {\r\n this.evaluateB_EU1999();\r\n }\r\n\r\n // BImSchV\r\n if (this.BImSchV) {\r\n this.evaluateB_BImSchV();\r\n }\r\n\r\n }\r\n else {\r\n // Keine Bewertung also keine Hintergrundfarbe bzw. transparent\r\n\r\n // EU2013\r\n this.EU2013_UAS_B_Color_mT = \"\";\r\n this.EU2013_UAS_B_Color_Am = \"\";\r\n this.EU2013_UAS_B_Color_mT_Uncert = \"\";\r\n this.EU2013_UAS_B_Color_Am_Uncert = \"\";\r\n this.EU2013_OAS_B_Color_mT = \"\";\r\n this.EU2013_OAS_B_Color_Am = \"\";\r\n this.EU2013_OAS_B_Color_mT_Uncert = \"\";\r\n this.EU2013_OAS_B_Color_Am_Uncert = \"\";\r\n this.EU2013_Gliedmassen_B_Color_mT = \"\";\r\n this.EU2013_Gliedmassen_B_Color_Am = \"\";\r\n this.EU2013_Gliedmassen_B_Color_mT_Uncert = \"\";\r\n this.EU2013_Gliedmassen_B_Color_Am_Uncert = \"\";\r\n this.EU2013_Therm_B_Color_mT = \"\";\r\n this.EU2013_Therm_B_Color_Am = \"\";\r\n this.EU2013_Therm_B_Color_mT_Uncert = \"\";\r\n this.EU2013_Therm_B_Color_Am_Uncert = \"\";\r\n\r\n // EMFV\r\n this.EMFV_UAS_B_Color_mT = \"\";\r\n this.EMFV_UAS_B_Color_Am = \"\";\r\n this.EMFV_UAS_B_Color_mT_Uncert = \"\";\r\n this.EMFV_UAS_B_Color_Am_Uncert = \"\";\r\n this.EMFV_OAS_B_Color_mT = \"\";\r\n this.EMFV_OAS_B_Color_Am = \"\";\r\n this.EMFV_OAS_B_Color_mT_Uncert = \"\";\r\n this.EMFV_OAS_B_Color_Am_Uncert = \"\";\r\n this.EMFV_Gliedmassen_B_Color_mT = \"\";\r\n this.EMFV_Gliedmassen_B_Color_Am = \"\";\r\n this.EMFV_Gliedmassen_B_Color_mT_Uncert = \"\";\r\n this.EMFV_Gliedmassen_B_Color_Am_Uncert = \"\";\r\n this.EMFV_Therm_B_Color_mT = \"\";\r\n this.EMFV_Therm_B_Color_Am = \"\";\r\n this.EMFV_Therm_B_Color_mT_Uncert = \"\";\r\n this.EMFV_Therm_B_Color_Am_Uncert = \"\";\r\n this.EMFV_Therm_B_Spitze_Color_mT = \"\";\r\n this.EMFV_Therm_B_Spitze_Color_Am = \"\";\r\n this.EMFV_Therm_B_Spitze_Color_mT_Uncert = \"\";\r\n this.EMFV_Therm_B_Spitze_Color_Am_Uncert = \"\";\r\n\r\n // FB451\r\n this.FB451_Aktiv_B_Color_mT = \"\";\r\n this.FB451_Aktiv_B_Color_Am = \"\"; \r\n this.FB451_Aktiv_B_Color_mT_Uncert = \"\";\r\n this.FB451_Aktiv_B_Color_Am_Uncert = \"\"; \r\n this.FB451_Passiv_B_Color_mT = \"\";\r\n this.FB451_Passiv_B_Color_Am = \"\"; \r\n this.FB451_Passiv_B_Color_mT_Uncert = \"\";\r\n this.FB451_Passiv_B_Color_Am_Uncert = \"\"; \r\n\r\n // DGUV V15\r\n this.DGUVV15_Expo2_B_Color_mT = \"\";\r\n this.DGUVV15_Expo2_B_Color_Am = \"\"; \r\n this.DGUVV15_Expo2_B_Color_mT_Uncert = \"\";\r\n this.DGUVV15_Expo2_B_Color_Am_Uncert = \"\"; \r\n this.DGUVV15_Expo1_B_Color_mT = \"\";\r\n this.DGUVV15_Expo1_B_Color_Am = \"\"; \r\n this.DGUVV15_Expo1_B_Color_mT_Uncert = \"\";\r\n this.DGUVV15_Expo1_B_Color_Am_Uncert = \"\"; \r\n this.DGUVV15_ExpoEr_B_Color_mT = \"\";\r\n this.DGUVV15_ExpoEr_B_Color_Am = \"\"; \r\n this.DGUVV15_ExpoEr_B_Color_mT_Uncert = \"\";\r\n this.DGUVV15_ExpoEr_B_Color_Am_Uncert = \"\"; \r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT = \"\";\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am = \"\"; \r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT_Uncert = \"\";\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am_Uncert = \"\"; \r\n \r\n // EU1999\r\n this.EU1999_B_Color_mT = \"\";\r\n this.EU1999_B_Color_Am = \"\";\r\n this.EU1999_B_Color_mT_Uncert = \"\";\r\n this.EU1999_B_Color_Am_Uncert = \"\";\r\n this.EU1999_Spitze_B_Color_mT = \"\";\r\n this.EU1999_Spitze_B_Color_Am = \"\";\r\n this.EU1999_Spitze_B_Color_mT_Uncert = \"\";\r\n this.EU1999_Spitze_B_Color_Am_Uncert = \"\"; \r\n\r\n // BImSchV\r\n this.BImSchV_NF_B_Color_mT = \"\";\r\n this.BImSchV_NF_B_Color_Am = \"\"; \r\n this.BImSchV_NF_B_Color_mT_Uncert = \"\";\r\n this.BImSchV_NF_B_Color_Am_Uncert = \"\"; \r\n this.BImSchV_HF_B_Color_mT = \"\";\r\n this.BImSchV_HF_B_Color_Am = \"\"; \r\n this.BImSchV_HF_B_Color_mT_Uncert = \"\";\r\n this.BImSchV_HF_B_Color_Am_Uncert = \"\"; \r\n this.BImSchV_Spitze_B_Color_mT = \"\";\r\n this.BImSchV_Spitze_B_Color_Am = \"\"; \r\n this.BImSchV_Spitze_B_Color_mT_Uncert = \"\";\r\n this.BImSchV_Spitze_B_Color_Am_Uncert = \"\"; \r\n\r\n // Werte in der Grafik ausblenden\r\n // Effektivwert\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].borderColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].pointBackgroundColor = 'rgba(0, 0, 0, )';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 3].label = '';\r\n // Spitzenwert\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].borderColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.BFeldChart.data.datasets[this.BFeldChart.data.datasets.length - 2].label = '';\r\n }\r\n\r\n // Muss 2x aufgerufen werden, sonst wird die Legende nicht richtig angezeigt. \r\n this.BFeldChart.update();\r\n this.BFeldChart.update();\r\n }\r\n\r\n evaluateB_EU2013() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! \r\n\r\n // EU2013_UAS \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EU2013_UAS_B_Color_Am = \"\";\r\n this.EU2013_UAS_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_UAS_B_Color_mT = GREY;\r\n this.EU2013_UAS_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_UAS_B(this.EU2013_UAS_B_Freq) / this.FaktorU, 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_UAS_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_UAS_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_UAS_B(this.EU2013_UAS_B_Freq), 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_UAS_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EU2013_UAS_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EU2013_UAS_B_Color_mT = \"\";\r\n this.EU2013_UAS_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_UAS_B_Color_Am = GREY;\r\n this.EU2013_UAS_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_UAS_B(this.EU2013_UAS_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_UAS_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_UAS_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_UAS_B(this.EU2013_UAS_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_UAS_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EU2013_UAS_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EU2013_OAS \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EU2013_OAS_B_Color_Am = \"\";\r\n this.EU2013_OAS_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_OAS_B_Color_mT = GREY;\r\n this.EU2013_OAS_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_OAS_B(this.EU2013_OAS_B_Freq) / this.FaktorU, 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_OAS_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_OAS_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_OAS_B(this.EU2013_OAS_B_Freq), 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_OAS_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EU2013_OAS_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EU2013_OAS_B_Color_mT = \"\";\r\n this.EU2013_OAS_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_OAS_B_Color_Am = GREY;\r\n this.EU2013_OAS_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_OAS_B(this.EU2013_OAS_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_OAS_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_OAS_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_OAS_B(this.EU2013_OAS_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_OAS_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EU2013_OAS_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EU2013_Gliedmassen \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EU2013_Gliedmassen_B_Color_Am = \"\";\r\n this.EU2013_Gliedmassen_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_Gliedmassen_B_Color_mT = GREY;\r\n this.EU2013_Gliedmassen_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_Gliedmassen_B(this.EU2013_Gliedmassen_B_Freq) / this.FaktorU, 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Gliedmassen_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_Gliedmassen_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_Gliedmassen_B(this.EU2013_Gliedmassen_B_Freq), 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Gliedmassen_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EU2013_Gliedmassen_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EU2013_Gliedmassen_B_Color_mT = \"\";\r\n this.EU2013_Gliedmassen_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_Gliedmassen_B_Color_Am = GREY;\r\n this.EU2013_Gliedmassen_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_Gliedmassen_B(this.EU2013_Gliedmassen_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Gliedmassen_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_Gliedmassen_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_Gliedmassen_B(this.EU2013_Gliedmassen_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Gliedmassen_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EU2013_Gliedmassen_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EU2013_Therm \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EU2013_Therm_B_Color_Am = \"\";\r\n this.EU2013_Therm_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_Therm_B_Color_mT = GREY;\r\n this.EU2013_Therm_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_Thermisch_B(this.EU2013_Therm_B_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Therm_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_Therm_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU2013_Thermisch_B(this.EU2013_Therm_B_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Therm_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EU2013_Therm_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EU2013_Therm_B_Color_mT = \"\";\r\n this.EU2013_Therm_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU2013_Therm_B_Color_Am = GREY;\r\n this.EU2013_Therm_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_Thermisch_B(this.EU2013_Therm_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Therm_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_Therm_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU2013_Thermisch_B(this.EU2013_Therm_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Therm_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EU2013_Therm_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n }\r\n\r\n evaluateB_EMFV() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! \r\n\r\n // EMFV_UAS \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EMFV_UAS_B_Color_Am = \"\";\r\n this.EMFV_UAS_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_UAS_B_Color_mT = GREY;\r\n this.EMFV_UAS_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_UAS_B(this.EMFV_UAS_B_Freq) / this.FaktorU, 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_UAS_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_UAS_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_UAS_B(this.EMFV_UAS_B_Freq), 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_UAS_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EMFV_UAS_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EMFV_UAS_B_Color_mT = \"\";\r\n this.EMFV_UAS_B_Color_mT_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_UAS_B_Color_Am = GREY;\r\n this.EMFV_UAS_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_UAS_B(this.EMFV_UAS_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_UAS_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_UAS_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_UAS_B(this.EMFV_UAS_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_UAS_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EMFV_UAS_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EMFV_OAS \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EMFV_OAS_B_Color_Am = \"\";\r\n this.EMFV_OAS_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_OAS_B_Color_mT = GREY;\r\n this.EMFV_OAS_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_OAS_B(this.EMFV_OAS_B_Freq) / this.FaktorU, 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_OAS_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_OAS_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_OAS_B(this.EMFV_OAS_B_Freq), 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_OAS_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EMFV_OAS_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EMFV_OAS_B_Color_mT = \"\";\r\n this.EMFV_OAS_B_Color_mT_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_OAS_B_Color_Am = GREY;\r\n this.EMFV_OAS_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_OAS_B(this.EMFV_OAS_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_OAS_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_OAS_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_OAS_B(this.EMFV_OAS_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_OAS_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EMFV_OAS_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EMFV_Gliedmassen \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EMFV_Gliedmassen_B_Color_Am = \"\";\r\n this.EMFV_Gliedmassen_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_Gliedmassen_B_Color_mT = GREY;\r\n this.EMFV_Gliedmassen_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_Gliedmassen_B(this.EMFV_Gliedmassen_B_Freq) / this.FaktorU, 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Gliedmassen_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Gliedmassen_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_Gliedmassen_B(this.EMFV_Gliedmassen_B_Freq), 3).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Gliedmassen_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EMFV_Gliedmassen_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EMFV_Gliedmassen_B_Color_mT = \"\";\r\n this.EMFV_Gliedmassen_B_Color_mT_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_Gliedmassen_B_Color_Am = GREY;\r\n this.EMFV_Gliedmassen_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_Gliedmassen_B(this.EMFV_Gliedmassen_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Gliedmassen_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Gliedmassen_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_Gliedmassen_B(this.EMFV_Gliedmassen_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Gliedmassen_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EMFV_Gliedmassen_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EMFV_Therm \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EMFV_Therm_B_Color_Am = \"\";\r\n this.EMFV_Therm_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EMFV_Therm_B_Color_mT = GREY;\r\n this.EMFV_Therm_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EMFV_Thermisch_B(this.EMFV_Therm_B_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EMFV_Thermisch_B(this.EMFV_Therm_B_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EMFV_Therm_B_Color_mT = \"\";\r\n this.EMFV_Therm_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EMFV_Therm_B_Color_Am = GREY;\r\n this.EMFV_Therm_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EMFV_Thermisch_B(this.EMFV_Therm_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EMFV_Thermisch_B(this.EMFV_Therm_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EMFV_Therm_Spitze \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EMFV_Therm_B_Spitze_Color_Am = \"\";\r\n this.EMFV_Therm_B_Spitze_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_Therm_B_Spitze_Color_mT = GREY;\r\n this.EMFV_Therm_B_Spitze_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_Thermisch_Spitze_B(this.EMFV_Therm_B_Spitze_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Spitze_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Spitze_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EMFV_Thermisch_Spitze_B(this.EMFV_Therm_B_Spitze_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Spitze_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Spitze_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EMFV_Therm_B_Spitze_Color_mT = \"\";\r\n this.EMFV_Therm_B_Spitze_Color_mT_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EMFV_Therm_B_Spitze_Color_Am = GREY;\r\n this.EMFV_Therm_B_Spitze_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_Thermisch_Spitze_B(this.EMFV_Therm_B_Spitze_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Spitze_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Spitze_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EMFV_Thermisch_Spitze_B(this.EMFV_Therm_B_Spitze_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_B_Spitze_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_B_Spitze_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n }\r\n\r\n evaluateB_FB451() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! \r\n\r\n // FB451_Aktiv \r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.FB451_Aktiv_B_Color_Am = \"\";\r\n this.FB451_Aktiv_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.FB451_Aktiv_B_Color_mT = GREY;\r\n this.FB451_Aktiv_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(FB451_Aktiv_B(this.FB451_Aktiv_B_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Aktiv_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.FB451_Aktiv_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(FB451_Aktiv_B(this.FB451_Aktiv_B_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Aktiv_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.FB451_Aktiv_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.FB451_Aktiv_B_Color_mT = \"\";\r\n this.FB451_Aktiv_B_Color_mT_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.FB451_Aktiv_B_Color_Am = GREY;\r\n this.FB451_Aktiv_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(FB451_Aktiv_B(this.FB451_Aktiv_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Aktiv_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.FB451_Aktiv_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(FB451_Aktiv_B(this.FB451_Aktiv_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Aktiv_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.FB451_Aktiv_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // FB451_Passiv\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.FB451_Passiv_B_Color_Am = \"\";\r\n this.FB451_Passiv_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.FB451_Passiv_B_Color_mT = GREY;\r\n this.FB451_Passiv_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(FB451_Passiv_B(this.FB451_Passiv_B_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Passiv_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.FB451_Passiv_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(FB451_Passiv_B(this.FB451_Passiv_B_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Passiv_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.FB451_Passiv_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.FB451_Passiv_B_Color_mT = \"\";\r\n this.FB451_Passiv_B_Color_mT_Uncert = \"\";\r\n // Spitzewert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.FB451_Passiv_B_Color_Am = GREY;\r\n this.FB451_Passiv_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(FB451_Passiv_B(this.FB451_Passiv_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Passiv_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.FB451_Passiv_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(FB451_Passiv_B(this.FB451_Passiv_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Passiv_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.FB451_Passiv_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n evaluateB_DGUVV15() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! \r\n\r\n // DGUVV15 Expo2\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.DGUVV15_Expo2_B_Color_Am = \"\";\r\n this.DGUVV15_Expo2_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.DGUVV15_Expo2_B_Color_mT = GREY;\r\n this.DGUVV15_Expo2_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(V15_Expo2_B(this.DGUVV15_Expo2_B_Freq) / this.FaktorU, 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo2_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo2_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(V15_Expo2_B(this.DGUVV15_Expo2_B_Freq), 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo2_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo2_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.DGUVV15_Expo2_B_Color_mT = \"\";\r\n this.DGUVV15_Expo2_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.DGUVV15_Expo2_B_Color_Am = GREY;\r\n this.DGUVV15_Expo2_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(V15_Expo2_B(this.DGUVV15_Expo2_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo2_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo2_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(V15_Expo2_B(this.DGUVV15_Expo2_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo2_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo2_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // DGUVV15 Expo1\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.DGUVV15_Expo1_B_Color_Am = \"\";\r\n this.DGUVV15_Expo1_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.DGUVV15_Expo1_B_Color_mT = GREY;\r\n this.DGUVV15_Expo1_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(V15_Expo1_B(this.DGUVV15_Expo1_B_Freq) / this.FaktorU, 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo1_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo1_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(V15_Expo1_B(this.DGUVV15_Expo1_B_Freq), 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo1_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo1_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.DGUVV15_Expo1_B_Color_mT = \"\";\r\n this.DGUVV15_Expo1_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.DGUVV15_Expo1_B_Color_Am = GREY;\r\n this.DGUVV15_Expo1_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(V15_Expo1_B(this.DGUVV15_Expo1_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo1_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo1_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(V15_Expo1_B(this.DGUVV15_Expo1_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo1_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo1_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // DGUVV15 ExpoEr\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.DGUVV15_ExpoEr_B_Color_Am = \"\";\r\n this.DGUVV15_ExpoEr_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.DGUVV15_ExpoEr_B_Color_mT = GREY;\r\n this.DGUVV15_ExpoEr_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(V15_ExpoEr_B(this.DGUVV15_ExpoEr_B_Freq) / this.FaktorU, 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(V15_ExpoEr_B(this.DGUVV15_ExpoEr_B_Freq), 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.DGUVV15_ExpoEr_B_Color_mT = \"\";\r\n this.DGUVV15_ExpoEr_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.DGUVV15_ExpoEr_B_Color_Am = GREY;\r\n this.DGUVV15_ExpoEr_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(V15_ExpoEr_B(this.DGUVV15_ExpoEr_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(V15_ExpoEr_B(this.DGUVV15_ExpoEr_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // DGUV V15 Er Spitze\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am = \"\";\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT = GREY;\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(V15_ExpoEr_Spitze_B(this.DGUVV15_ExpoEr_Spitze_B_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(V15_ExpoEr_Spitze_B(this.DGUVV15_ExpoEr_Spitze_B_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT = \"\";\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_mT_Uncert = \"\";\r\n // Spitzewert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am = GREY;\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(V15_ExpoEr_Spitze_B(this.DGUVV15_ExpoEr_Spitze_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(V15_ExpoEr_Spitze_B(this.DGUVV15_ExpoEr_Spitze_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_Spitze_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n evaluateB_EU1999() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! \r\n\r\n // EU1999\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EU1999_B_Color_Am = \"\";\r\n this.EU1999_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU1999_B_Color_mT = GREY;\r\n this.EU1999_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU1999_B(this.EU1999_B_Freq) / this.FaktorU, 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU1999_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(EU1999_B(this.EU1999_B_Freq), 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EU1999_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EU1999_B_Color_mT = \"\";\r\n this.EU1999_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.EU1999_B_Color_Am = GREY;\r\n this.EU1999_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU1999_B(this.EU1999_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU1999_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(EU1999_B(this.EU1999_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EU1999_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // EU1999_Spitze\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.EU1999_Spitze_B_Color_Am = \"\";\r\n this.EU1999_Spitze_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EU1999_Spitze_B_Color_mT = GREY;\r\n this.EU1999_Spitze_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EU1999_B_Spitze(this.EU1999_Spitze_B_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_Spitze_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU1999_Spitze_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(EU1999_B_Spitze(this.EU1999_Spitze_B_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_Spitze_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.EU1999_Spitze_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.EU1999_Spitze_B_Color_mT = \"\";\r\n this.EU1999_Spitze_B_Color_mT_Uncert = \"\";\r\n // Spitzewert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.EU1999_Spitze_B_Color_Am = GREY;\r\n this.EU1999_Spitze_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EU1999_B_Spitze(this.EU1999_Spitze_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_Spitze_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU1999_Spitze_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(EU1999_B_Spitze(this.EU1999_Spitze_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_Spitze_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.EU1999_Spitze_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n evaluateB_BImSchV() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! \r\n\r\n // BImSchV NF\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.BImSchV_NF_B_Color_Am = \"\";\r\n this.BImSchV_NF_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.BImSchV_NF_B_Color_mT = GREY;\r\n this.BImSchV_NF_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(BImSchV_B_NF(this.BImSchV_NF_B_Freq) / this.FaktorU, 4).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_NF_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_NF_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(BImSchV_B_NF(this.BImSchV_NF_B_Freq), 4).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_NF_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.BImSchV_NF_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.BImSchV_NF_B_Color_mT = \"\";\r\n this.BImSchV_NF_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.BImSchV_NF_B_Color_Am = GREY;\r\n this.BImSchV_NF_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(BImSchV_B_NF(this.BImSchV_NF_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_NF_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_NF_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(BImSchV_B_NF(this.BImSchV_NF_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_NF_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.BImSchV_NF_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // BImSchV HF\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.BImSchV_HF_B_Color_Am = \"\";\r\n this.BImSchV_HF_B_Color_Am_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.BImSchV_HF_B_Color_mT = GREY;\r\n this.BImSchV_HF_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(BImSchV_B_HF(this.BImSchV_HF_B_Freq) / this.FaktorU, 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_HF_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_HF_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.RoundDownStringComma(BImSchV_B_HF(this.BImSchV_HF_B_Freq), 6).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_HF_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.BImSchV_HF_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.BImSchV_HF_B_Color_mT = \"\";\r\n this.BImSchV_HF_B_Color_mT_Uncert = \"\";\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Effektiv <= 0) {\r\n this.BImSchV_HF_B_Color_Am = GREY;\r\n this.BImSchV_HF_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(BImSchV_B_HF(this.BImSchV_HF_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_HF_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_HF_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Effektiv <= Number(this.convert_to_H(BImSchV_B_HF(this.BImSchV_HF_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_HF_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.BImSchV_HF_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n // BImSchV_Spitze\r\n // Müssen wir mT (1) oder A/m (0) berechnen?\r\n if (this.eval_unit == 1) {\r\n // Am in original Farbe\r\n this.BImSchV_Spitze_B_Color_Am = \"\";\r\n this.BImSchV_Spitze_B_Color_Am_Uncert = \"\";\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.BImSchV_Spitze_B_Color_mT = GREY;\r\n this.BImSchV_Spitze_B_Color_mT_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(BImSchV_B_Spitze(this.BImSchV_Spitze_B_Freq) / this.FaktorU, 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_Spitze_B_Color_mT_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_Spitze_B_Color_mT_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.RoundDownStringComma(BImSchV_B_Spitze(this.BImSchV_Spitze_B_Freq), 5).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_Spitze_B_Color_mT = GREEN;\r\n }\r\n else {\r\n this.BImSchV_Spitze_B_Color_mT = RED;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // für A/m rechnen\r\n // mT in original Farbe\r\n this.BImSchV_Spitze_B_Color_mT = \"\";\r\n this.BImSchV_Spitze_B_Color_mT_Uncert = \"\";\r\n // Spitzewert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.B_Spitze <= 0) {\r\n this.BImSchV_Spitze_B_Color_Am = GREY;\r\n this.BImSchV_Spitze_B_Color_Am_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.B_Spitze <= Number(this.convert_to_H(BImSchV_B_Spitze(this.BImSchV_Spitze_B_Freq) / this.FaktorU).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_Spitze_B_Color_Am_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_Spitze_B_Color_Am_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.B_Spitze <= Number(this.convert_to_H(BImSchV_B_Spitze(this.BImSchV_Spitze_B_Freq)).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_Spitze_B_Color_Am = GREEN;\r\n }\r\n else {\r\n this.BImSchV_Spitze_B_Color_Am = RED;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n evaluateE() {\r\n if (this.BewertungCheck == true) {\r\n\r\n // Werte zur Bewertung in Grafik einblenden wenn die Werte größer Null sind\r\n // Effektivwert\r\n if (this.E_Effektiv > 0) {\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].borderColor = 'rgba(0, 0, 0, 1)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].label = this.translate.instant(\"GENERAL.RMS-LEGEND\");\r\n }\r\n else {\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].borderColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].label = '';\r\n }\r\n // Spitzenwert\r\n if (this.E_Spitze > 0) {\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].borderColor = 'rgba(0, 0, 0, 1)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].label = this.translate.instant(\"GENERAL.PEAK-LEGEND\");\r\n }\r\n else {\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].borderColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].label = '';\r\n }\r\n\r\n // In Grafik ändern, abhängig von MinSuche\r\n let data_eff;\r\n let data_spitze;\r\n if (this.minSucheCheck == false) {\r\n data_eff = [\r\n {\r\n x: this.Frequenz,\r\n y: this.E_Effektiv,\r\n }\r\n ];\r\n data_spitze = [\r\n {\r\n x: this.Frequenz,\r\n y: this.E_Spitze,\r\n }\r\n ];\r\n }\r\n else {\r\n data_eff = [\r\n {\r\n x: this.Frequenz_min,\r\n y: this.E_Effektiv,\r\n },\r\n {\r\n x: this.Frequenz_max,\r\n y: this.E_Effektiv,\r\n }\r\n ];\r\n data_spitze = [\r\n {\r\n x: this.Frequenz_min,\r\n y: this.E_Spitze,\r\n },\r\n {\r\n x: this.Frequenz_max,\r\n y: this.E_Spitze,\r\n }\r\n ];\r\n }\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].data = data_eff;\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].data = data_spitze;\r\n\r\n // Berechne Farbe für jede angezeigte Zelle \r\n\r\n // Nur ausgewählte Werke berechnen\r\n\r\n // EU2013\r\n if (this.EU2013) {\r\n this.evaluateE_EU2013();\r\n }\r\n\r\n // EMFV\r\n if (this.EMFV) {\r\n this.evaluateE_EMFV();\r\n }\r\n\r\n // FB451\r\n if (this.FB451) {\r\n this.evaluateE_FB451();\r\n }\r\n\r\n // DGUV V15\r\n if (this.DGUVV15) {\r\n this.evaluateE_DGUVV15();\r\n }\r\n\r\n // EU1999\r\n if (this.EU1999) {\r\n this.evaluateE_EU1999();\r\n }\r\n\r\n // BImSchV\r\n if (this.BImSchV) {\r\n this.evaluateE_BImSchV();\r\n }\r\n\r\n }\r\n else {\r\n // Keine Bewertung also keine Hintergrundfarbe bzw. transparent\r\n\r\n // EU2013\r\n this.EU2013_UAS_E_Color = \"\";\r\n this.EU2013_UAS_E_Color_Uncert = \"\";\r\n this.EU2013_OAS_E_Color = \"\";\r\n this.EU2013_OAS_E_Color_Uncert = \"\";\r\n this.EU2013_Therm_E_Color = \"\";\r\n this.EU2013_Therm_E_Color_Uncert = \"\";\r\n\r\n // EMFV\r\n this.EMFV_UAS_E_Color = \"\";\r\n this.EMFV_UAS_E_Color_Uncert = \"\";\r\n this.EMFV_OAS_E_Color = \"\";\r\n this.EMFV_OAS_E_Color_Uncert = \"\";\r\n this.EMFV_Therm_E_Color = \"\";\r\n this.EMFV_Therm_E_Color_Uncert = \"\";\r\n this.EMFV_Therm_E_Spitze_Color = \"\";\r\n this.EMFV_Therm_E_Spitze_Color_Uncert = \"\";\r\n\r\n // FB451\r\n this.FB451_Aktiv_E_Color = \"\";\r\n this.FB451_Aktiv_E_Color_Uncert = \"\";\r\n this.FB451_Passiv_E_Color = \"\";\r\n this.FB451_Passiv_E_Color_Uncert = \"\";\r\n\r\n // DGUV V15\r\n this.DGUVV15_Expo2_E_Color = \"\";\r\n this.DGUVV15_Expo2_E_Color_Uncert = \"\";\r\n this.DGUVV15_Expo1_E_Color = \"\";\r\n this.DGUVV15_Expo1_E_Color_Uncert = \"\";\r\n this.DGUVV15_ExpoEr_E_Color = \"\";\r\n this.DGUVV15_ExpoEr_E_Color_Uncert = \"\";\r\n this.DGUVV15_ExpoEr_Spitze_E_Color = \"\";\r\n this.DGUVV15_ExpoEr_Spitze_E_Color_Uncert = \"\";\r\n\r\n // EU1999\r\n this.EU1999_E_Color = \"\";\r\n this.EU1999_E_Color_Uncert = \"\";\r\n this.EU1999_Spitze_E_Color = \"\";\r\n this.EU1999_Spitze_E_Color_Uncert = \"\";\r\n\r\n // BImSchV\r\n this.BImSchV_NF_E_Color = \"\";\r\n this.BImSchV_NF_E_Color_Uncert = \"\";\r\n this.BImSchV_HF_E_Color = \"\";\r\n this.BImSchV_HF_E_Color_Uncert = \"\";\r\n this.BImSchV_Spitze_E_Color = \"\";\r\n this.BImSchV_Spitze_E_Color_Uncert = \"\";\r\n\r\n // Werte in der Grafik ausblenden\r\n // Effektivwert\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].borderColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 3].label = '';\r\n // Spitzenwert\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].borderColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].pointBackgroundColor = 'rgba(0, 0, 0, 0)';\r\n this.EFeldChart.data.datasets[this.EFeldChart.data.datasets.length - 2].label = '';\r\n }\r\n\r\n // Muss 2x aufgerufen werden, sonst wird die Legende nicht richtig angezeigt. \r\n this.EFeldChart.update();\r\n this.EFeldChart.update();\r\n }\r\n\r\n evaluateE_EU2013() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! Bei E-Feld immer = 1\r\n\r\n // EU2013_UAS \r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.EU2013_UAS_E_Color = GREY;\r\n this.EU2013_UAS_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU2013_UAS_E(this.EU2013_UAS_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_UAS_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_UAS_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU2013_UAS_E(this.EU2013_UAS_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_UAS_E_Color = GREEN;\r\n }\r\n else {\r\n this.EU2013_UAS_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // EU2013_OAS \r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.EU2013_OAS_E_Color = GREY;\r\n this.EU2013_OAS_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU2013_OAS_E(this.EU2013_OAS_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_OAS_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_OAS_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU2013_OAS_E(this.EU2013_OAS_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_OAS_E_Color = GREEN;\r\n }\r\n else {\r\n this.EU2013_OAS_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // EU2013_Therm \r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.EU2013_Therm_E_Color = GREY;\r\n this.EU2013_Therm_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU2013_Thermisch_E(this.EU2013_Therm_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Therm_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU2013_Therm_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU2013_Thermisch_E(this.EU2013_Therm_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU2013_Therm_E_Color = GREEN;\r\n }\r\n else {\r\n this.EU2013_Therm_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n }\r\n\r\n evaluateE_EMFV() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! Bei E-Feld immer = 1\r\n\r\n // EMFV_UAS \r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.EMFV_UAS_E_Color = GREY;\r\n this.EMFV_UAS_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EMFV_UAS_E(this.EMFV_UAS_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_UAS_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_UAS_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EMFV_UAS_E(this.EMFV_UAS_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_UAS_E_Color = GREEN;\r\n }\r\n else {\r\n this.EMFV_UAS_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // EMFV_OAS \r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.EMFV_OAS_E_Color = GREY;\r\n this.EMFV_OAS_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EMFV_OAS_E(this.EMFV_OAS_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_OAS_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_OAS_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EMFV_OAS_E(this.EMFV_OAS_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_OAS_E_Color = GREEN;\r\n }\r\n else {\r\n this.EMFV_OAS_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // EMFV_Therm \r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.EMFV_Therm_E_Color = GREY;\r\n this.EMFV_Therm_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EMFV_Thermisch_E(this.EMFV_Therm_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EMFV_Thermisch_E(this.EMFV_Therm_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_E_Color = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // EMFV_Therm_Spitze \r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.EMFV_Therm_E_Spitze_Color = GREY;\r\n this.EMFV_Therm_E_Spitze_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EMFV_Thermisch_Spitze_E(this.EMFV_Therm_E_Spitze_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_E_Spitze_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_E_Spitze_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EMFV_Thermisch_Spitze_E(this.EMFV_Therm_E_Spitze_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EMFV_Therm_E_Spitze_Color = GREEN;\r\n }\r\n else {\r\n this.EMFV_Therm_E_Spitze_Color = RED;\r\n }\r\n }\r\n }\r\n }\r\n\r\n evaluateE_FB451() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! Bei E-Feld immer = 1\r\n\r\n // FB451 Aktiv\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.FB451_Aktiv_E_Color = GREY;\r\n this.FB451_Aktiv_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(FB451_Aktiv_E(this.FB451_Aktiv_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Aktiv_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.FB451_Aktiv_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(FB451_Aktiv_E(this.FB451_Aktiv_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Aktiv_E_Color = GREEN;\r\n }\r\n else {\r\n this.FB451_Aktiv_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // FB451 Passiv\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.FB451_Passiv_E_Color = GREY;\r\n this.FB451_Passiv_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(FB451_Passiv_E(this.FB451_Passiv_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Passiv_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.FB451_Passiv_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(FB451_Passiv_E(this.FB451_Passiv_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.FB451_Passiv_E_Color = GREEN;\r\n }\r\n else {\r\n this.FB451_Passiv_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n }\r\n\r\n evaluateE_DGUVV15() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! Bei E-Feld immer = 1\r\n\r\n // DGUV V15 Expo2\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.DGUVV15_Expo2_E_Color = GREY;\r\n this.DGUVV15_Expo2_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(V15_Expo2_E(this.DGUVV15_Expo2_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo2_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo2_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(V15_Expo2_E(this.DGUVV15_Expo2_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo2_E_Color = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo2_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // DGUV V15 Expo1\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.DGUVV15_Expo1_E_Color = GREY;\r\n this.DGUVV15_Expo1_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(V15_Expo1_E(this.DGUVV15_Expo1_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo1_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo1_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(V15_Expo1_E(this.DGUVV15_Expo1_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_Expo1_E_Color = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_Expo1_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // DGUV V15 ExpoEr\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.DGUVV15_ExpoEr_E_Color = GREY;\r\n this.DGUVV15_ExpoEr_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(V15_ExpoEr_E(this.DGUVV15_ExpoEr_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(V15_ExpoEr_E(this.DGUVV15_ExpoEr_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_E_Color = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_E_Color = RED;\r\n }\r\n }\r\n } \r\n \r\n // DGUV V15 Er Spitze\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.DGUVV15_ExpoEr_Spitze_E_Color = GREY;\r\n this.DGUVV15_ExpoEr_Spitze_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(V15_ExpoEr_Spitze_E(this.DGUVV15_ExpoEr_Spitze_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_Spitze_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_Spitze_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(V15_ExpoEr_Spitze_E(this.DGUVV15_ExpoEr_Spitze_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.DGUVV15_ExpoEr_Spitze_E_Color = GREEN;\r\n }\r\n else {\r\n this.DGUVV15_ExpoEr_Spitze_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n }\r\n\r\n evaluateE_EU1999() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! Bei E-Feld immer = 1\r\n\r\n // EU1999\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.EU1999_E_Color = GREY;\r\n this.EU1999_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU1999_E(this.EU1999_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU1999_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(EU1999_E(this.EU1999_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_E_Color = GREEN;\r\n }\r\n else {\r\n this.EU1999_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // EU1999_Spitze\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.EU1999_Spitze_E_Color = GREY;\r\n this.EU1999_Spitze_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EU1999_E_Spitze(this.EU1999_Spitze_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_Spitze_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.EU1999_Spitze_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(EU1999_E_Spitze(this.EU1999_Spitze_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.EU1999_Spitze_E_Color = GREEN;\r\n }\r\n else {\r\n this.EU1999_Spitze_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n }\r\n\r\n evaluateE_BImSchV() {\r\n // Achtung: Anzahl der Nachkommastellen bei RoundDown beachten! Bei E-Feld immer = 1\r\n\r\n // BImSchV NF\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.BImSchV_NF_E_Color = GREY;\r\n this.BImSchV_NF_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(BImSchV_E_NF(this.BImSchV_NF_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_NF_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_NF_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(BImSchV_E_NF(this.BImSchV_NF_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_NF_E_Color = GREEN;\r\n }\r\n else {\r\n this.BImSchV_NF_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // BImSchV HF\r\n // Effektivwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Effektiv <= 0) {\r\n this.BImSchV_HF_E_Color = GREY;\r\n this.BImSchV_HF_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(BImSchV_E_HF(this.BImSchV_HF_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_HF_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_HF_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Effektiv <= Number(this.RoundDownStringComma(BImSchV_E_HF(this.BImSchV_HF_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_HF_E_Color = GREEN;\r\n }\r\n else {\r\n this.BImSchV_HF_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n // BImSchV Spitze\r\n // Spitzenwert <= 0 dann GREY -> wir haben nichts zum Vergleichen \r\n if (this.E_Spitze <= 0) {\r\n this.BImSchV_Spitze_E_Color = GREY;\r\n this.BImSchV_Spitze_E_Color_Uncert = GREY;\r\n }\r\n else {\r\n // Mit oder ohne Unsicherheit rechnen?\r\n if (this.UnsicherheitCheck) {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(BImSchV_E_Spitze(this.BImSchV_Spitze_E_Freq) / this.FaktorU, 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_Spitze_E_Color_Uncert = GREEN;\r\n }\r\n else {\r\n this.BImSchV_Spitze_E_Color_Uncert = RED;\r\n }\r\n }\r\n else {\r\n if (this.E_Spitze <= Number(this.RoundDownStringComma(BImSchV_E_Spitze(this.BImSchV_Spitze_E_Freq), 1).replace(\",\", \".\").replaceAll(\" \", \"\"))) {\r\n this.BImSchV_Spitze_E_Color = GREEN;\r\n }\r\n else {\r\n this.BImSchV_Spitze_E_Color = RED;\r\n }\r\n }\r\n }\r\n\r\n }\r\n \r\n}","<app-tabs>\r\n <app-tab-item label=\"FIELDS.NAME-B\">\r\n <app-tab-body>\r\n <div>\r\n <div> \r\n {{\"GENERAL.HELP\" | translate}}\r\n <a (click)=\"switchToHelpTab()\"> {{\"GENERAL.HERE\" | translate}}</a>.\r\n </div>\r\n <div> \r\n {{\"GENERAL.SELECT\" | translate}}<br />\r\n <table>\r\n <tr>\r\n <th style=\"text-align:center\">{{\"GENERAL.OCCUPATIONAL\" | translate}}</th>\r\n <th style=\"text-align:center\">{{\"GENERAL.G-PUBLIC\" | translate}}</th>\r\n </tr>\r\n <tr>\r\n <td>\r\n \r\n <label [tooltip]='\"GENERAL.EU2013\" | translate'> EU 2013 \r\n <input type=\"checkbox\" [(ngModel)]=\"EU2013\" (change)=\"updateAll()\" />\r\n </label> \r\n , \r\n <label [tooltip]='\"GENERAL.EMFV\" | translate'> EMFV\r\n <input type=\"checkbox\" [(ngModel)]=\"EMFV\" (change)=\"updateAll()\" />\r\n </label>\r\n , \r\n <label [tooltip]='\"GENERAL.TREMF\" | translate'>\r\n TREMF ({{\"GENERAL.IMPLANTS\" | translate}}) <input type=\"checkbox\" [(ngModel)]=\"FB451\" (change)=\"updateAll()\" />\r\n </label>\r\n , \r\n <label [tooltip]='\"GENERAL.DGUV-V15\" | translate'>\r\n DGUV V15 <input type=\"checkbox\" [(ngModel)]=\"DGUVV15\" (change)=\"updateAll()\" />\r\n </label> \r\n \r\n </td> \r\n <td>\r\n \r\n <label [tooltip]='\"GENERAL.EU99\" | translate'>\r\n EU 1999 <input type=\"checkbox\" [(ngModel)]=\"EU1999\" (change)=\"updateAll()\" />\r\n </label>\r\n , \r\n <label [tooltip]='\"GENERAL.BIMSCHV\" | translate'>\r\n 26. BImSchV <input type=\"checkbox\" [(ngModel)]=\"BImSchV\" (change)=\"updateAll()\" />\r\n </label>\r\n \r\n </td>\r\n </tr>\r\n </table>\r\n </div>\r\n <div>\r\n {{\"GENERAL.ENTER-FREQ\" | translate}}:<br>\r\n <label>{{\"GENERAL.UNIT\" | translate}}:\r\n <select [(ngModel)]=\"multiplier\" (change)=\"updateFrequenz()\">\r\n <option [ngValue]=\"1\">Hz</option>\r\n <option [ngValue]=\"1e3\">kHz</option>\r\n <option [ngValue]=\"1e6\">MHz</option>\r\n <option [ngValue]=\"1e9\">GHz</option>\r\n </select>\r\n </label>\r\n \r\n <label>{{\"GENERAL.FREQUENCY\" | translate}}: \r\n <input (input)=\"updateFrequenz()\" [(ngModel)]=\"Frequenz_input\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"minSucheCheck\" />\r\n </label>\r\n \r\n <label>\r\n {{\"GENERAL.MIN-SEARCH\" | translate}} <input type=\"checkbox\" [(ngModel)]=\"minSucheCheck\"\r\n [ngModelOptions]=\"{standalone: true}\" (change)=\"updateFrequenz()\" />\r\n </label>\r\n \r\n <label>Min. {{\"GENERAL.FREQUENCY\" | translate}}:\r\n <input (input)=\"updateFrequenz()\" [(ngModel)]=\"Frequenz_input_min\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!minSucheCheck\" />\r\n </label>\r\n \r\n <label>Max. {{\"GENERAL.FREQUENCY\" | translate}}:\r\n <input (input)=\"updateFrequenz()\" [(ngModel)]=\"Frequenz_input_max\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!minSucheCheck\" />\r\n </label>\r\n <br>\r\n <div> \r\n <label [tooltip]='\"GENERAL.UNCERT-TOOLTIP\" | translate'>\r\n {{\"GENERAL.UNCERTAINTY\" | translate}} <input type=\"checkbox\" [(ngModel)]=\"UnsicherheitCheck\"\r\n [ngModelOptions]=\"{standalone: true}\" (change)=\"updateAll()\" />\r\n </label>\r\n \r\n <input (input)=\"updateAll()\" [(ngModel)]=\"FaktorU\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!UnsicherheitCheck\" [tooltip]='\"GENERAL.UNCERT-TOOLTIP\" | translate'/>\r\n </div> \r\n <div>\r\n <br>\r\n {{\"GENERAL.PRE-EVAL\" | translate}}\r\n <br>\r\n <label [tooltip]='\"GENERAL.EVAL-TOOLTIP\" | translate'>\r\n {{\"GENERAL.EVAL\" | translate}} <input type=\"checkbox\" [(ngModel)]=\"BewertungCheck\"\r\n [ngModelOptions]=\"{standalone: true}\" (change)=\"updateFrequenz()\" />\r\n </label> \r\n \r\n <label>{{\"GENERAL.UNIT\" | translate}}:\r\n <select [(ngModel)]=\"eval_unit\" (change)=\"evaluateB()\" [disabled]=\"!BewertungCheck\">\r\n <option [ngValue]=\"1\">mT</option>\r\n <option [ngValue]=\"0\">A/m</option>\r\n </select>\r\n </label>\r\n \r\n <label [tooltip]='\"GENERAL.RMS-TOOLTIP\" | translate'> {{\"GENERAL.RMS\" | translate}}:\r\n <input (input)=\"evaluateB()\" [(ngModel)]=\"B_Effektiv\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!BewertungCheck\" />\r\n </label>\r\n \r\n <label [tooltip]='\"GENERAL.PEAK-TOOLTIP\" | translate'> {{\"GENERAL.PEAK\" | translate}}:\r\n <input (input)=\"evaluateB()\" [(ngModel)]=\"B_Spitze\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!BewertungCheck\" />\r\n </label>\r\n </div> \r\n <br> \r\n </div>\r\n <div *ngIf=\"(Frequenz < 0) || (Frequenz_min < 0) || (Frequenz_max < 0)\">\r\n <b>{{\"GENERAL.FREQ-G-0\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"(Frequenz > 300e9) || (Frequenz_min > 300e9) || (Frequenz_max > 300e9)\">\r\n <b>{{\"GENERAL.FREQ-L-300\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"UnsicherheitCheck && (FaktorU<1)\">\r\n <b>{{\"GENERAL.UNCERT-G-1\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"BewertungCheck && ((B_Effektiv<0) || (B_Spitze<0))\">\r\n <b>{{\"GENERAL.VALUE-L-0\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"BewertungCheck && (B_Effektiv > B_Spitze) && (B_Spitze > 0)\">\r\n <b>{{\"GENERAL.RMS-L-PEAK\" | translate}}.</b>\r\n </div>\r\n </div>\r\n\r\n <h2>{{\"VALUES.PERMISSIBLE-B\" | translate}}</h2>\r\n <!-- Tabelle nur anzeigen wenn die Bedingungen passen -->\r\n <div\r\n *ngIf=\"(Frequenz >= 0 && Frequenz <= 300e9) && (Frequenz_min >= 0 && Frequenz_min <= 300e9) && (Frequenz_max >= 0 && Frequenz_max <= 300e9) && (!UnsicherheitCheck || (UnsicherheitCheck && FaktorU>=1)) && (!BewertungCheck || (BewertungCheck && B_Spitze>=0 && B_Effektiv>=0))\">\r\n <table style=\"width:100%\">\r\n <tr>\r\n <th>{{\"VALUES.REGULATION\" | translate}}</th>\r\n <th>{{\"GENERAL.FREQUENCY\" | translate}} / Hz</th>\r\n <th>{{\"VALUES.THRESH-TYPE\" | translate}}</th> \r\n <th *ngIf=\"!UnsicherheitCheck\">{{\"VALUES.FLUX-DENSITY\" | translate}}</th>\r\n <th *ngIf=\"UnsicherheitCheck\">{{\"VALUES.FLUX-DENSITY-U\" | translate}}</th>\r\n <th *ngIf=\"!UnsicherheitCheck\">{{\"VALUES.FIELD-STRENGTH\" | translate}}</th>\r\n <th *ngIf=\"UnsicherheitCheck\">{{\"VALUES.FIELD-STRENGTH-U\" | translate}}</th>\r\n </tr>\r\n <tr *ngIf=\"EU2013\">\r\n <td>EU 2013</td>\r\n <td>{{RoundDownStringComma(EU2013_UAS_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU2013-LAL-B\" | translate}}</td>\r\n <td *ngIf=\"EU2013_UAS_B_Freq<1 || EU2013_UAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_UAS_B_Freq<1 || EU2013_UAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_UAS_B_Freq>=1 && EU2013_UAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_UAS_B_Color_mT}\">\r\n {{RoundDownStringComma(EU2013_UAS_B(EU2013_UAS_B_Freq),3)}} mT</td>\r\n <td *ngIf=\"EU2013_UAS_B_Freq>=1 && EU2013_UAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_UAS_B_Color_Am}\">\r\n {{convert_to_H(EU2013_UAS_B(EU2013_UAS_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EU2013_UAS_B_Freq>=1 && EU2013_UAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_UAS_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EU2013_UAS_B(EU2013_UAS_B_Freq),3)}} mT ({{RoundDownStringComma(EU2013_UAS_B(EU2013_UAS_B_Freq)/FaktorU,3)}} mT)</td>\r\n <td *ngIf=\"EU2013_UAS_B_Freq>=1 && EU2013_UAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_UAS_B_Color_Am_Uncert}\">\r\n {{convert_to_H(EU2013_UAS_B(EU2013_UAS_B_Freq))}} A/m ({{convert_to_H(EU2013_UAS_B(EU2013_UAS_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EU2013\">\r\n <td>EU 2013</td>\r\n <td>{{RoundDownStringComma(EU2013_OAS_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU2013-UAL-B\" | translate}}</td>\r\n <td *ngIf=\"EU2013_OAS_B_Freq<1 || EU2013_OAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_OAS_B_Freq<1 || EU2013_OAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_OAS_B_Freq>=1 && EU2013_OAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_OAS_B_Color_mT}\"> \r\n {{RoundDownStringComma(EU2013_OAS_B(EU2013_OAS_B_Freq),3)}} mT</td>\r\n <td *ngIf=\"EU2013_OAS_B_Freq>=1 && EU2013_OAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_OAS_B_Color_Am}\">\r\n {{convert_to_H(EU2013_OAS_B(EU2013_OAS_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EU2013_OAS_B_Freq>=1 && EU2013_OAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_OAS_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EU2013_OAS_B(EU2013_OAS_B_Freq),3)}} mT ({{RoundDownStringComma(EU2013_OAS_B(EU2013_OAS_B_Freq)/FaktorU,3)}} mT)</td>\r\n <td *ngIf=\"EU2013_OAS_B_Freq>=1 && EU2013_OAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_OAS_B_Color_Am_Uncert}\">\r\n {{convert_to_H(EU2013_OAS_B(EU2013_OAS_B_Freq))}} A/m ({{convert_to_H(EU2013_OAS_B(EU2013_OAS_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EU2013\">\r\n <td>EU 2013</td>\r\n <td>{{RoundDownStringComma(EU2013_Gliedmassen_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU2013-ALL-B\" | translate}}</td>\r\n <td *ngIf=\"EU2013_Gliedmassen_B_Freq<1 || EU2013_Gliedmassen_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_Gliedmassen_B_Freq<1 || EU2013_Gliedmassen_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_Gliedmassen_B_Freq>=1 && EU2013_Gliedmassen_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Gliedmassen_B_Color_mT}\"> \r\n {{RoundDownStringComma(EU2013_Gliedmassen_B(EU2013_Gliedmassen_B_Freq),3)}} mT</td>\r\n <td *ngIf=\"EU2013_Gliedmassen_B_Freq>=1 && EU2013_Gliedmassen_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Gliedmassen_B_Color_Am}\"> \r\n {{convert_to_H(EU2013_Gliedmassen_B(EU2013_Gliedmassen_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EU2013_Gliedmassen_B_Freq>=1 && EU2013_Gliedmassen_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Gliedmassen_B_Color_mT_Uncert}\"> \r\n {{RoundDownStringComma(EU2013_Gliedmassen_B(EU2013_Gliedmassen_B_Freq),3)}} mT ({{RoundDownStringComma(EU2013_Gliedmassen_B(EU2013_Gliedmassen_B_Freq)/FaktorU,3)}} mT)</td>\r\n <td *ngIf=\"EU2013_Gliedmassen_B_Freq>=1 && EU2013_Gliedmassen_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Gliedmassen_B_Color_Am_Uncert}\"> \r\n {{convert_to_H(EU2013_Gliedmassen_B(EU2013_Gliedmassen_B_Freq))}} A/m ({{convert_to_H(EU2013_Gliedmassen_B(EU2013_Gliedmassen_B_Freq)/FaktorU)}} A/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EU2013\">\r\n <td>EU 2013</td>\r\n <td>{{RoundDownStringComma(EU2013_Therm_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU2013-THERMAL\" | translate}}</td>\r\n <td *ngIf=\"EU2013_Therm_B_Freq<1e5\">-</td>\r\n <td *ngIf=\"EU2013_Therm_B_Freq<1e5\">-</td>\r\n <td *ngIf=\"EU2013_Therm_B_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Therm_B_Color_mT}\">\r\n {{RoundDownStringComma(EU2013_Thermisch_B(EU2013_Therm_B_Freq),5)}} mT</td>\r\n <td *ngIf=\"EU2013_Therm_B_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Therm_B_Color_Am}\">\r\n {{convert_to_H(EU2013_Thermisch_B(EU2013_Therm_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EU2013_Therm_B_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Therm_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EU2013_Thermisch_B(EU2013_Therm_B_Freq),5)}} mT ({{RoundDownStringComma(EU2013_Thermisch_B(EU2013_Therm_B_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"EU2013_Therm_B_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Therm_B_Color_Am_Uncert}\"> \r\n {{convert_to_H(EU2013_Thermisch_B(EU2013_Therm_B_Freq))}} A/m ({{convert_to_H(EU2013_Thermisch_B(EU2013_Therm_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_UAS_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-LAL-B\" | translate}}</td>\r\n <td *ngIf=\"EMFV_UAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_UAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_UAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_UAS_B_Color_mT}\">\r\n {{RoundDownStringComma(EMFV_UAS_B(EMFV_UAS_B_Freq),3)}} mT</td>\r\n <td *ngIf=\"EMFV_UAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_UAS_B_Color_Am}\">\r\n {{convert_to_H(EMFV_UAS_B(EMFV_UAS_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EMFV_UAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_UAS_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EMFV_UAS_B(EMFV_UAS_B_Freq),3)}} mT ({{RoundDownStringComma(EMFV_UAS_B(EMFV_UAS_B_Freq)/FaktorU,3)}} mT)</td>\r\n <td *ngIf=\"EMFV_UAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_UAS_B_Color_Am_Uncert}\">\r\n {{convert_to_H(EMFV_UAS_B(EMFV_UAS_B_Freq))}} A/m ({{convert_to_H(EMFV_UAS_B(EMFV_UAS_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_OAS_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-UAL-B\" | translate}}</td>\r\n <td *ngIf=\"EMFV_OAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_OAS_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_OAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_OAS_B_Color_mT}\"> \r\n {{RoundDownStringComma(EMFV_OAS_B(EMFV_OAS_B_Freq),3)}} mT</td>\r\n <td *ngIf=\"EMFV_OAS_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_OAS_B_Color_Am}\">\r\n {{convert_to_H(EMFV_OAS_B(EMFV_OAS_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EMFV_OAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_OAS_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EMFV_OAS_B(EMFV_OAS_B_Freq),3)}} mT ({{RoundDownStringComma(EMFV_OAS_B(EMFV_OAS_B_Freq)/FaktorU,3)}} mT)</td>\r\n <td *ngIf=\"EMFV_OAS_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_OAS_B_Color_Am_Uncert}\">\r\n {{convert_to_H(EMFV_OAS_B(EMFV_OAS_B_Freq))}} A/m ({{convert_to_H(EMFV_OAS_B(EMFV_OAS_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_Gliedmassen_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-ALL-B\" | translate}}</td>\r\n <td *ngIf=\"EMFV_Gliedmassen_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_Gliedmassen_B_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_Gliedmassen_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Gliedmassen_B_Color_mT}\"> \r\n {{RoundDownStringComma(EMFV_Gliedmassen_B(EMFV_Gliedmassen_B_Freq),3)}} mT</td>\r\n <td *ngIf=\"EMFV_Gliedmassen_B_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Gliedmassen_B_Color_Am}\"> \r\n {{convert_to_H(EMFV_Gliedmassen_B(EMFV_Gliedmassen_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EMFV_Gliedmassen_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Gliedmassen_B_Color_mT_Uncert}\"> \r\n {{RoundDownStringComma(EMFV_Gliedmassen_B(EMFV_Gliedmassen_B_Freq),3)}} mT ({{RoundDownStringComma(EMFV_Gliedmassen_B(EMFV_Gliedmassen_B_Freq)/FaktorU,3)}} mT)</td>\r\n <td *ngIf=\"EMFV_Gliedmassen_B_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Gliedmassen_B_Color_Am_Uncert}\"> \r\n {{convert_to_H(EMFV_Gliedmassen_B(EMFV_Gliedmassen_B_Freq))}} A/m ({{convert_to_H(EMFV_Gliedmassen_B(EMFV_Gliedmassen_B_Freq)/FaktorU)}} A/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_Therm_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-THERMAL\" | translate}}</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq<1e5\">-</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq<1e5\">-</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Color_mT}\">\r\n {{RoundDownStringComma(EMFV_Thermisch_B(EMFV_Therm_B_Freq),5)}} mT</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Color_Am}\">\r\n {{convert_to_H(EMFV_Thermisch_B(EMFV_Therm_B_Freq))}} A/m</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EMFV_Thermisch_B(EMFV_Therm_B_Freq),5)}} mT ({{RoundDownStringComma(EMFV_Thermisch_B(EMFV_Therm_B_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Color_Am_Uncert}\"> \r\n {{convert_to_H(EMFV_Thermisch_B(EMFV_Therm_B_Freq))}} A/m ({{convert_to_H(EMFV_Thermisch_B(EMFV_Therm_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_Therm_B_Spitze_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-THERMAL-PEAK\" | translate}}</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq<1e5\">-</td>\r\n <td *ngIf=\"EMFV_Therm_B_Freq<1e5\">-</td>\r\n <td *ngIf=\"EMFV_Therm_B_Spitze_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Spitze_Color_mT}\">\r\n {{RoundDownStringComma(EMFV_Thermisch_Spitze_B(EMFV_Therm_B_Spitze_Freq),5)}} mT</td>\r\n <td *ngIf=\"EMFV_Therm_B_Spitze_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Spitze_Color_Am}\">\r\n {{convert_to_H(EMFV_Thermisch_Spitze_B(EMFV_Therm_B_Spitze_Freq))}} A/m</td>\r\n <td *ngIf=\"EMFV_Therm_B_Spitze_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Spitze_Color_mT_Uncert}\"> \r\n {{RoundDownStringComma(EMFV_Thermisch_Spitze_B(EMFV_Therm_B_Spitze_Freq),5)}} mT ({{RoundDownStringComma(EMFV_Thermisch_Spitze_B(EMFV_Therm_B_Spitze_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"EMFV_Therm_B_Spitze_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_B_Spitze_Color_Am_Uncert}\">\r\n {{convert_to_H(EMFV_Thermisch_Spitze_B(EMFV_Therm_B_Spitze_Freq))}} A/m ({{convert_to_H(EMFV_Thermisch_Spitze_B(EMFV_Therm_B_Spitze_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"FB451\">\r\n <td>TREMF ({{\"GENERAL.IMPLANTS\" | translate}})</td>\r\n <td>{{RoundDownStringComma(FB451_Aktiv_B_Freq,-1)}}</td>\r\n <td *ngIf=\"FB451_Aktiv_B_Freq > 0\">{{\"VALUES.FB451-ACTIVE-B\" | translate}}</td> \r\n <td *ngIf=\"FB451_Aktiv_B_Freq == 0\">{{\"VALUES.FB451-ACTIVE-B-0\" | translate}}</td> \r\n <td *ngIf=\"FB451_Aktiv_B_Freq>2.5e9\">-</td>\r\n <td *ngIf=\"FB451_Aktiv_B_Freq>2.5e9\">-</td> \r\n <td *ngIf=\"FB451_Aktiv_B_Freq<=2.5e9 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Aktiv_B_Color_mT}\">\r\n {{RoundDownStringComma(FB451_Aktiv_B(FB451_Aktiv_B_Freq),5)}} mT</td>\r\n <td *ngIf=\"FB451_Aktiv_B_Freq<=2.5e9 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Aktiv_B_Color_Am}\">\r\n {{convert_to_H(FB451_Aktiv_B(FB451_Aktiv_B_Freq))}} A/m</td>\r\n <td *ngIf=\"FB451_Aktiv_B_Freq<=2.5e9 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Aktiv_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(FB451_Aktiv_B(FB451_Aktiv_B_Freq),5)}} mT ({{RoundDownStringComma(FB451_Aktiv_B(FB451_Aktiv_B_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"FB451_Aktiv_B_Freq<=2.5e9 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Aktiv_B_Color_Am_Uncert}\"> \r\n {{convert_to_H(FB451_Aktiv_B(FB451_Aktiv_B_Freq))}} A/m ({{convert_to_H(FB451_Aktiv_B(FB451_Aktiv_B_Freq)/FaktorU)}} A/m)</td>\r\n </tr>\r\n <tr *ngIf=\"FB451\">\r\n <td>TREMF ({{\"GENERAL.IMPLANTS\" | translate}})</td>\r\n <td>{{RoundDownStringComma(FB451_Passiv_B_Freq,-1)}}</td>\r\n <td *ngIf=\"FB451_Passiv_B_Freq > 0\">{{\"VALUES.FB451-PASSIVE-B\" | translate}}</td> \r\n <td *ngIf=\"FB451_Passiv_B_Freq == 0\">{{\"VALUES.FB451-PASSIVE-B-0\" | translate}}</td> \r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Passiv_B_Color_mT}\">\r\n {{RoundDownStringComma(FB451_Passiv_B(FB451_Passiv_B_Freq),5)}} mT</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Passiv_B_Color_Am}\">\r\n {{convert_to_H(FB451_Passiv_B(FB451_Passiv_B_Freq))}} A/m</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Passiv_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(FB451_Passiv_B(FB451_Passiv_B_Freq),5)}} mT ({{RoundDownStringComma(FB451_Passiv_B(FB451_Passiv_B_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Passiv_B_Color_Am_Uncert}\">\r\n {{convert_to_H(FB451_Passiv_B(FB451_Passiv_B_Freq))}} A/m ({{convert_to_H(FB451_Passiv_B(FB451_Passiv_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_Expo2_B_Freq, -1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-EXPO2-B\" | translate}}</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo2_B_Color_mT}\">\r\n {{RoundDownStringComma(V15_Expo2_B(DGUVV15_Expo2_B_Freq),6)}} mT</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo2_B_Color_Am}\">\r\n {{convert_to_H(V15_Expo2_B(DGUVV15_Expo2_B_Freq))}} A/m</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo2_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(V15_Expo2_B(DGUVV15_Expo2_B_Freq),6)}} mT ({{RoundDownStringComma(V15_Expo2_B(DGUVV15_Expo2_B_Freq)/FaktorU,6)}} mT)</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo2_B_Color_Am_Uncert}\">\r\n {{convert_to_H(V15_Expo2_B(DGUVV15_Expo2_B_Freq))}} A/m ({{convert_to_H(V15_Expo2_B(DGUVV15_Expo2_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_Expo1_B_Freq, -1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-EXPO1-B\" | translate}}</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo1_B_Color_mT}\">\r\n {{RoundDownStringComma(V15_Expo1_B(DGUVV15_Expo1_B_Freq),6)}} mT</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo1_B_Color_Am}\">\r\n {{convert_to_H(V15_Expo1_B(DGUVV15_Expo1_B_Freq))}} A/m</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo1_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(V15_Expo1_B(DGUVV15_Expo1_B_Freq),6)}} mT ({{RoundDownStringComma(V15_Expo1_B(DGUVV15_Expo1_B_Freq)/FaktorU,6)}} mT)</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo1_B_Color_Am_Uncert}\">\r\n {{convert_to_H(V15_Expo1_B(DGUVV15_Expo1_B_Freq))}} A/m ({{convert_to_H(V15_Expo1_B(DGUVV15_Expo1_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_ExpoEr_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-HIGH-B\" | translate}}</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_B_Freq>91e3\">-</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_B_Freq>91e3\">-</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_B_Freq<=91e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_B_Color_mT}\">\r\n {{RoundDownStringComma(V15_ExpoEr_B(DGUVV15_ExpoEr_B_Freq),6)}} mT</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_B_Freq<=91e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_B_Color_Am}\">\r\n {{convert_to_H(V15_ExpoEr_B(DGUVV15_ExpoEr_B_Freq))}} A/m</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_B_Freq<=91e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(V15_ExpoEr_B(DGUVV15_ExpoEr_B_Freq),6)}} mT ({{RoundDownStringComma(V15_ExpoEr_B(DGUVV15_ExpoEr_B_Freq)/FaktorU,6)}} mT)</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_B_Freq<=91e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_B_Color_Am_Uncert}\">\r\n {{convert_to_H(V15_ExpoEr_B(DGUVV15_ExpoEr_B_Freq))}} A/m ({{convert_to_H(V15_ExpoEr_B(DGUVV15_ExpoEr_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_ExpoEr_Spitze_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-PEAK-B\" | translate}}</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_B_Freq<91e3\">-</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_B_Freq<91e3\">-</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_B_Freq>=91e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_Spitze_B_Color_mT}\">\r\n {{RoundDownStringComma(V15_ExpoEr_Spitze_B(DGUVV15_ExpoEr_Spitze_B_Freq),5)}} mT</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_B_Freq>=91e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_Spitze_B_Color_Am}\">\r\n {{convert_to_H(V15_ExpoEr_Spitze_B(DGUVV15_ExpoEr_Spitze_B_Freq))}} A/m</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_B_Freq>=91e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_Spitze_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(V15_ExpoEr_Spitze_B(DGUVV15_ExpoEr_Spitze_B_Freq),5)}} mT ({{RoundDownStringComma(V15_ExpoEr_Spitze_B(DGUVV15_ExpoEr_Spitze_B_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_B_Freq>=91e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_Spitze_B_Color_Am_Uncert}\">\r\n {{convert_to_H(V15_ExpoEr_Spitze_B(DGUVV15_ExpoEr_Spitze_B_Freq))}} A/m ({{convert_to_H(V15_ExpoEr_Spitze_B(DGUVV15_ExpoEr_Spitze_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr> \r\n <tr *ngIf=\"EU1999\">\r\n <td>EU 1999</td>\r\n <td>{{RoundDownStringComma(EU1999_B_Freq.toString(),-1)}}</td>\r\n <td>{{\"VALUES.EU99-REF-TAB\" | translate}}</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_B_Color_mT}\">\r\n {{RoundDownStringComma(EU1999_B(EU1999_B_Freq),6)}} mT</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_B_Color_Am}\">\r\n {{convert_to_H(EU1999_B(EU1999_B_Freq))}} A/m</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EU1999_B(EU1999_B_Freq),6)}} mT ({{RoundDownStringComma(EU1999_B(EU1999_B_Freq)/FaktorU,6)}} mT)</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_B_Color_Am_Uncert}\">\r\n {{convert_to_H(EU1999_B(EU1999_B_Freq))}} A/m ({{convert_to_H(EU1999_B(EU1999_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EU1999\">\r\n <td>EU 1999</td>\r\n <td>{{RoundDownStringComma(EU1999_Spitze_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU99-PEAK-TAB\" | translate}}</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_Spitze_B_Color_mT}\">\r\n {{RoundDownStringComma(EU1999_B_Spitze(EU1999_Spitze_B_Freq),5)}} mT</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_Spitze_B_Color_Am}\">\r\n {{convert_to_H(EU1999_B_Spitze(EU1999_Spitze_B_Freq))}} A/m</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_Spitze_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(EU1999_B_Spitze(EU1999_Spitze_B_Freq),5)}} mT ({{RoundDownStringComma(EU1999_B_Spitze(EU1999_Spitze_B_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_Spitze_B_Color_Am_Uncert}\">\r\n {{convert_to_H(EU1999_B_Spitze(EU1999_Spitze_B_Freq))}} A/m ({{convert_to_H(EU1999_B_Spitze(EU1999_Spitze_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"BImSchV\">\r\n <td>26. BImSchV</td>\r\n <td>{{RoundDownStringComma(BImSchV_NF_B_Freq, -1)}}</td>\r\n <td *ngIf=\"!(BImSchV_NF_B_Freq == 50)\">{{\"VALUES.BIMSCHV-LF-TAB\" | translate}}</td>\r\n <td *ngIf=\"BImSchV_NF_B_Freq == 50\">{{\"VALUES.BIMSCHV-LF-TAB-50\" | translate}}</td>\r\n <td *ngIf=\"!(!(BImSchV_NF_B_Freq > 0 && BImSchV_NF_B_Freq < 1) && BImSchV_NF_B_Freq<=10e6)\">-</td>\r\n <td *ngIf=\"!(!(BImSchV_NF_B_Freq > 0 && BImSchV_NF_B_Freq < 1) && BImSchV_NF_B_Freq<=10e6)\">-</td>\r\n <td *ngIf=\"!(BImSchV_NF_B_Freq > 0 && BImSchV_NF_B_Freq < 1) && BImSchV_NF_B_Freq<=10e6 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_NF_B_Color_mT}\">\r\n {{RoundDownStringComma(BImSchV_B_NF(BImSchV_NF_B_Freq),4)}} mT</td>\r\n <td *ngIf=\"!(BImSchV_NF_B_Freq > 0 && BImSchV_NF_B_Freq < 1) && BImSchV_NF_B_Freq<=10e6 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_NF_B_Color_Am}\">\r\n {{convert_to_H(BImSchV_B_NF(BImSchV_NF_B_Freq))}} A/m</td>\r\n <td *ngIf=\"!(BImSchV_NF_B_Freq > 0 && BImSchV_NF_B_Freq < 1) && BImSchV_NF_B_Freq<=10e6 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_NF_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(BImSchV_B_NF(BImSchV_NF_B_Freq),4)}} mT ({{RoundDownStringComma(BImSchV_B_NF(BImSchV_NF_B_Freq)/FaktorU,4)}} mT)</td>\r\n <td *ngIf=\"!(BImSchV_NF_B_Freq > 0 && BImSchV_NF_B_Freq < 1) && BImSchV_NF_B_Freq<=10e6 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_NF_B_Color_Am_Uncert}\">\r\n {{convert_to_H(BImSchV_B_NF(BImSchV_NF_B_Freq))}} A/m ({{convert_to_H(BImSchV_B_NF(BImSchV_NF_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"BImSchV\">\r\n <td>26. BImSchV</td>\r\n <td>{{RoundDownStringComma(BImSchV_HF_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.BIMSCHV-HF-TAB\" | translate}}</td>\r\n <td *ngIf=\"BImSchV_HF_B_Freq<100e3\">-</td>\r\n <td *ngIf=\"BImSchV_HF_B_Freq<100e3\">-</td>\r\n <td *ngIf=\"BImSchV_HF_B_Freq>=100e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_HF_B_Color_mT}\">\r\n {{RoundDownStringComma(BImSchV_B_HF(BImSchV_HF_B_Freq),6)}} mT</td>\r\n <td *ngIf=\"BImSchV_HF_B_Freq>=100e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_HF_B_Color_Am}\">\r\n {{convert_to_H(BImSchV_B_HF(BImSchV_HF_B_Freq))}} A/m</td>\r\n <td *ngIf=\"BImSchV_HF_B_Freq>=100e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_HF_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(BImSchV_B_HF(BImSchV_HF_B_Freq),6)}} mT ({{RoundDownStringComma(BImSchV_B_HF(BImSchV_HF_B_Freq)/FaktorU,6)}} mT)</td>\r\n <td *ngIf=\"BImSchV_HF_B_Freq>=100e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_HF_B_Color_Am_Uncert}\">\r\n {{convert_to_H(BImSchV_B_HF(BImSchV_HF_B_Freq))}} A/m ({{convert_to_H(BImSchV_B_HF(BImSchV_HF_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n <tr *ngIf=\"BImSchV\">\r\n <td>26. BImSchV</td>\r\n <td>{{RoundDownStringComma(BImSchV_Spitze_B_Freq,-1)}}</td>\r\n <td>{{\"VALUES.BIMSCHV-PEAK-TAB\" | translate}}</td>\r\n <td *ngIf=\"BImSchV_Spitze_B_Freq<9e3\">-</td>\r\n <td *ngIf=\"BImSchV_Spitze_B_Freq<9e3\">-</td>\r\n <td *ngIf=\"BImSchV_Spitze_B_Freq>=9e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_Spitze_B_Color_mT}\">\r\n {{RoundDownStringComma(BImSchV_B_Spitze(BImSchV_Spitze_B_Freq),5)}} mT</td>\r\n <td *ngIf=\"BImSchV_Spitze_B_Freq>=9e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_Spitze_B_Color_Am}\">\r\n {{convert_to_H(BImSchV_B_Spitze(BImSchV_Spitze_B_Freq))}} A/m</td>\r\n <td *ngIf=\"BImSchV_Spitze_B_Freq>=9e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_Spitze_B_Color_mT_Uncert}\">\r\n {{RoundDownStringComma(BImSchV_B_Spitze(BImSchV_Spitze_B_Freq),5)}} mT ({{RoundDownStringComma(BImSchV_B_Spitze(BImSchV_Spitze_B_Freq)/FaktorU,5)}} mT)</td>\r\n <td *ngIf=\"BImSchV_Spitze_B_Freq>=9e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_Spitze_B_Color_Am_Uncert}\">\r\n {{convert_to_H(BImSchV_B_Spitze(BImSchV_Spitze_B_Freq))}} A/m ({{convert_to_H(BImSchV_B_Spitze(BImSchV_Spitze_B_Freq)/FaktorU)}} A/m)</td> \r\n </tr>\r\n </table>\r\n </div>\r\n\r\n <!-- Hinweis nur für FB451 und 0 Hz anzeigen -->\r\n <div *ngIf=\"Frequenz == 0 && FB451\">\r\n <b>{{\"GENERAL.NOTE\" | translate}} TREMF:</b> {{\"VALUES.FB451-NOTE\" | translate}}.\r\n </div>\r\n\r\n <!-- Hinweis nur für DGUV V15 und 91e3 <= f <= 300e9 Hz anzeigen -->\r\n <div *ngIf=\"Frequenz >= 91e3 && Frequenz <= 300e9 && DGUVV15\">\r\n <b>{{\"GENERAL.NOTE\" | translate}} DGUV V15:</b> {{\"VALUES.DGUVV15-NOTE\" | translate}}.\r\n </div>\r\n \r\n <div style=\"width:900px; height:500px\"> \r\n <canvas id=\"BFeldChart\" width=\"900\" height=\"500\" aria-label=\"Zulässige Werte für die magnetische Flussdichte\" role=\"img\"\r\n #BFeldChart></canvas>\r\n </div>\r\n </app-tab-body>\r\n </app-tab-item>\r\n <app-tab-item label=\"FIELDS.NAME-E\"> \r\n <app-tab-body>\r\n <div>\r\n <div> \r\n {{\"GENERAL.HELP\" | translate}}\r\n <a (click)=\"switchToHelpTab()\"> {{\"GENERAL.HERE\" | translate}}</a>. \r\n </div>\r\n <div> \r\n {{\"GENERAL.SELECT\" | translate}}<br />\r\n <table>\r\n <tr>\r\n <th style=\"text-align:center\">{{\"GENERAL.OCCUPATIONAL\" | translate}}</th>\r\n <th style=\"text-align:center\">{{\"GENERAL.G-PUBLIC\" | translate}}</th>\r\n </tr>\r\n <tr>\r\n <td>\r\n \r\n <label [tooltip]='\"GENERAL.EU2013\" | translate'> EU 2013 \r\n <input type=\"checkbox\" [(ngModel)]=\"EU2013\" (change)=\"updateAll()\" />\r\n </label> \r\n , \r\n <label [tooltip]='\"GENERAL.EMFV\" | translate'> EMFV\r\n <input type=\"checkbox\" [(ngModel)]=\"EMFV\" (change)=\"updateAll()\" />\r\n </label>\r\n , \r\n <label [tooltip]='\"GENERAL.TREMF\" | translate'>\r\n TREMF ({{\"GENERAL.IMPLANTS\" | translate}}) <input type=\"checkbox\" [(ngModel)]=\"FB451\" (change)=\"updateAll()\" />\r\n </label>\r\n , \r\n <label [tooltip]='\"GENERAL.DGUV-V15\" | translate'>\r\n DGUV V15 <input type=\"checkbox\" [(ngModel)]=\"DGUVV15\" (change)=\"updateAll()\" />\r\n </label> \r\n \r\n </td> \r\n <td>\r\n \r\n <label [tooltip]='\"GENERAL.EU99\" | translate'>\r\n EU 1999 <input type=\"checkbox\" [(ngModel)]=\"EU1999\" (change)=\"updateAll()\" />\r\n </label>\r\n , \r\n <label [tooltip]='\"GENERAL.BIMSCHV\" | translate'>\r\n 26. BImSchV <input type=\"checkbox\" [(ngModel)]=\"BImSchV\" (change)=\"updateAll()\" />\r\n </label>\r\n \r\n </td>\r\n </tr>\r\n </table>\r\n </div>\r\n <div>\r\n {{\"GENERAL.ENTER-FREQ\" | translate}}:<br>\r\n <label>{{\"GENERAL.UNIT\" | translate}}:\r\n <select [(ngModel)]=\"multiplier\" (change)=\"updateFrequenz()\">\r\n <option [ngValue]=\"1\">Hz</option>\r\n <option [ngValue]=\"1e3\">kHz</option>\r\n <option [ngValue]=\"1e6\">MHz</option>\r\n <option [ngValue]=\"1e9\">GHz</option>\r\n </select>\r\n </label>\r\n \r\n <label>{{\"GENERAL.FREQUENCY\" | translate}}: \r\n <input (input)=\"updateFrequenz()\" [(ngModel)]=\"Frequenz_input\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"minSucheCheck\" />\r\n </label>\r\n \r\n <label>\r\n {{\"GENERAL.MIN-SEARCH\" | translate}} <input type=\"checkbox\" [(ngModel)]=\"minSucheCheck\"\r\n [ngModelOptions]=\"{standalone: true}\" (change)=\"updateFrequenz()\" />\r\n </label>\r\n \r\n <label>Min. {{\"GENERAL.FREQUENCY\" | translate}}:\r\n <input (input)=\"updateFrequenz()\" [(ngModel)]=\"Frequenz_input_min\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!minSucheCheck\" />\r\n </label>\r\n \r\n <label>Max. {{\"GENERAL.FREQUENCY\" | translate}}:\r\n <input (input)=\"updateFrequenz()\" [(ngModel)]=\"Frequenz_input_max\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!minSucheCheck\" />\r\n </label>\r\n <br>\r\n <div>\r\n <label [tooltip]='\"GENERAL.UNCERT-TOOLTIP\" | translate'>\r\n {{\"GENERAL.UNCERTAINTY\" | translate}} <input type=\"checkbox\" [(ngModel)]=\"UnsicherheitCheck\"\r\n [ngModelOptions]=\"{standalone: true}\" (change)=\"updateAll()\" />\r\n </label>\r\n \r\n <input (input)=\"updateAll()\" [(ngModel)]=\"FaktorU\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!UnsicherheitCheck\" [tooltip]='\"GENERAL.UNCERT-TOOLTIP\" | translate'/>\r\n </div>\r\n <br>\r\n {{\"GENERAL.PRE-EVAL\" | translate}}\r\n <br>\r\n <div>\r\n <label [tooltip]='\"GENERAL.EVAL-TOOLTIP\" | translate'>\r\n {{\"GENERAL.EVAL\" | translate}} <input type=\"checkbox\" [(ngModel)]=\"BewertungCheck\"\r\n [ngModelOptions]=\"{standalone: true}\" (change)=\"updateFrequenz()\" />\r\n </label> \r\n \r\n <label>{{\"GENERAL.UNIT\" | translate}}: V/m </label>\r\n \r\n <label [tooltip]='\"GENERAL.RMS-TOOLTIP\" | translate'> {{\"GENERAL.RMS\" | translate}}:\r\n <input (input)=\"evaluateE()\" [(ngModel)]=\"E_Effektiv\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!BewertungCheck\" />\r\n </label>\r\n \r\n <label [tooltip]='\"GENERAL.PEAK-TOOLTIP\" | translate'> {{\"GENERAL.PEAK\" | translate}}:\r\n <input (input)=\"evaluateE()\" [(ngModel)]=\"E_Spitze\" type=\"number\" step=\"0.00000001\"\r\n [disabled]=\"!BewertungCheck\" />\r\n </label>\r\n </div> \r\n <br>\r\n </div>\r\n <div *ngIf=\"(Frequenz < 0) || (Frequenz_min < 0) || (Frequenz_max < 0)\">\r\n <b>{{\"GENERAL.FREQ-G-0\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"(Frequenz > 300e9) || (Frequenz_min > 300e9) || (Frequenz_max > 300e9)\">\r\n <b>{{\"GENERAL.FREQ-L-300\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"UnsicherheitCheck && (FaktorU<1)\">\r\n <b>{{\"GENERAL.UNCERT-G-1\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"BewertungCheck && ((E_Effektiv<0) || (E_Spitze<0))\">\r\n <b>{{\"GENERAL.VALUE-L-0\" | translate}}.</b>\r\n </div>\r\n <div *ngIf=\"BewertungCheck && (E_Effektiv > E_Spitze) && (E_Spitze > 0)\">\r\n <b>{{\"GENERAL.RMS-L-PEAK\" | translate}}.</b>\r\n </div>\r\n </div>\r\n\r\n <h2>{{\"VALUES.PERMISSIBLE-E\" | translate}}</h2>\r\n <div\r\n *ngIf=\"(Frequenz >= 0 && Frequenz <= 300e9) && (Frequenz_min >= 0 && Frequenz_min <= 300e9) && (Frequenz_max >= 0 && Frequenz_max <= 300e9) && (!UnsicherheitCheck || (UnsicherheitCheck && FaktorU>=1)) && (!BewertungCheck || (BewertungCheck && E_Spitze>=0 && E_Effektiv>=0))\">\r\n <table style=\"width:100%\">\r\n <tr>\r\n <th>{{\"VALUES.REGULATION\" | translate}}</th>\r\n <th>{{\"GENERAL.FREQUENCY\" | translate}} / Hz</th>\r\n <th>{{\"VALUES.THRESH-TYPE\" | translate}}</th>\r\n <th *ngIf=\"!UnsicherheitCheck\">{{\"VALUES.FIELD-STRENGTH-E\" | translate}}</th>\r\n <th *ngIf=\"UnsicherheitCheck\">{{\"VALUES.FIELD-STRENGTH-E-U\" | translate}}</th>\r\n </tr>\r\n <tr *ngIf=\"EU2013\">\r\n <td>EU 2013</td>\r\n <td>{{RoundDownStringComma(EU2013_UAS_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU2013-LAL-E\" | translate}}</td>\r\n <td *ngIf=\"EU2013_UAS_E_Freq<1 || EU2013_UAS_E_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_UAS_E_Freq>=1 && EU2013_UAS_E_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_UAS_E_Color}\">\r\n {{RoundDownStringComma(EU2013_UAS_E(EU2013_UAS_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EU2013_UAS_E_Freq>=1 && EU2013_UAS_E_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_UAS_E_Color_Uncert}\">\r\n {{RoundDownStringComma(EU2013_UAS_E(EU2013_UAS_E_Freq),1)}} V/m ({{RoundDownStringComma(EU2013_UAS_E(EU2013_UAS_E_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EU2013\">\r\n <td>EU 2013</td>\r\n <td>{{RoundDownStringComma(EU2013_OAS_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU2013-UAL-E\" | translate}}</td>\r\n <td *ngIf=\"EU2013_OAS_E_Freq<1 || EU2013_OAS_E_Freq>1e7\">-</td>\r\n <td *ngIf=\"EU2013_OAS_E_Freq>=1 && EU2013_OAS_E_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_OAS_E_Color}\">\r\n {{RoundDownStringComma(EU2013_OAS_E(EU2013_OAS_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EU2013_OAS_E_Freq>=1 && EU2013_OAS_E_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_OAS_E_Color_Uncert}\"> \r\n {{RoundDownStringComma(EU2013_OAS_E(EU2013_OAS_E_Freq),1)}} V/m ({{RoundDownStringComma(EU2013_OAS_E(EU2013_OAS_E_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EU2013\">\r\n <td>EU 2013</td>\r\n <td>{{RoundDownStringComma(EU2013_Therm_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU2013-THERMAL\" | translate}}</td>\r\n <td *ngIf=\"EU2013_Therm_E_Freq<1e5\">-</td>\r\n <td *ngIf=\"EU2013_Therm_E_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Therm_E_Color}\">\r\n {{RoundDownStringComma(EU2013_Thermisch_E(EU2013_Therm_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EU2013_Therm_E_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU2013_Therm_E_Color_Uncert}\"> \r\n {{RoundDownStringComma(EU2013_Thermisch_E(EU2013_Therm_E_Freq),1)}} V/m ({{RoundDownStringComma(EU2013_Thermisch_E(EU2013_Therm_E_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_UAS_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-LAL-E\" | translate}}</td>\r\n <td *ngIf=\"EMFV_UAS_E_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_UAS_E_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_UAS_E_Color}\">\r\n {{RoundDownStringComma(EMFV_UAS_E(EMFV_UAS_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EMFV_UAS_E_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_UAS_E_Color_Uncert}\">\r\n {{RoundDownStringComma(EMFV_UAS_E(EMFV_UAS_E_Freq),1)}} V/m ({{RoundDownStringComma(EMFV_UAS_E(EMFV_UAS_E_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_OAS_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-UAL-E\" | translate}}</td>\r\n <td *ngIf=\"EMFV_OAS_E_Freq>1e7\">-</td>\r\n <td *ngIf=\"EMFV_OAS_E_Freq<=1e7 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_OAS_E_Color}\">\r\n {{RoundDownStringComma(EMFV_OAS_E(EMFV_OAS_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EMFV_OAS_E_Freq<=1e7 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_OAS_E_Color_Uncert}\"> \r\n {{RoundDownStringComma(EMFV_OAS_E(EMFV_OAS_E_Freq),1)}} V/m ({{RoundDownStringComma(EMFV_OAS_E(EMFV_OAS_E_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_Therm_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-THERMAL\" | translate}}</td>\r\n <td *ngIf=\"EMFV_Therm_E_Freq<1e5\">-</td>\r\n <td *ngIf=\"EMFV_Therm_E_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_E_Color}\">\r\n {{RoundDownStringComma(EMFV_Thermisch_E(EMFV_Therm_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EMFV_Therm_E_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_E_Color_Uncert}\"> \r\n {{RoundDownStringComma(EMFV_Thermisch_E(EMFV_Therm_E_Freq),1)}} V/m ({{RoundDownStringComma(EMFV_Thermisch_E(EMFV_Therm_E_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n <tr *ngIf=\"EMFV\">\r\n <td>EMFV</td>\r\n <td>{{RoundDownStringComma(EMFV_Therm_E_Spitze_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EMFV-THERMAL-PEAK\" | translate}}</td>\r\n <td *ngIf=\"EMFV_Therm_E_Spitze_Freq<1e5\">-</td>\r\n <td *ngIf=\"EMFV_Therm_E_Spitze_Freq>=1e5 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_E_Spitze_Color}\">\r\n {{RoundDownStringComma(EMFV_Thermisch_Spitze_E(EMFV_Therm_E_Spitze_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EMFV_Therm_E_Spitze_Freq>=1e5 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EMFV_Therm_E_Spitze_Color_Uncert}\"> \r\n {{RoundDownStringComma(EMFV_Thermisch_Spitze_E(EMFV_Therm_E_Spitze_Freq),1)}} V/m ({{RoundDownStringComma(EMFV_Thermisch_Spitze_E(EMFV_Therm_E_Spitze_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n <tr *ngIf=\"FB451\">\r\n <td>TREMF ({{\"GENERAL.IMPLANTS\" | translate}})</td>\r\n <td>{{RoundDownStringComma(FB451_Aktiv_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.FB451-ACTIVE-E\" | translate}}</td>\r\n <td *ngIf=\"FB451_Aktiv_E_Freq==0 || FB451_Aktiv_E_Freq>2.5e9\">-</td>\r\n <td *ngIf=\"FB451_Aktiv_E_Freq>0 && FB451_Aktiv_E_Freq<=2.5e9 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Aktiv_E_Color}\">\r\n {{RoundDownStringComma(FB451_Aktiv_E(FB451_Aktiv_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"FB451_Aktiv_E_Freq>0 && FB451_Aktiv_E_Freq<=2.5e9 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Aktiv_E_Color_Uncert}\">\r\n {{RoundDownStringComma(FB451_Aktiv_E(FB451_Aktiv_E_Freq),1)}} V/m ({{RoundDownStringComma(FB451_Aktiv_E(FB451_Aktiv_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"FB451\">\r\n <td>TREMF ({{\"GENERAL.IMPLANTS\" | translate}})</td>\r\n <td>{{RoundDownStringComma(FB451_Passiv_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.FB451-PASSIVE-E\" | translate}}</td>\r\n <td *ngIf=\"FB451_Passiv_E_Freq==0\">-</td>\r\n <td *ngIf=\"FB451_Passiv_E_Freq>0 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Passiv_E_Color}\">\r\n {{RoundDownStringComma(FB451_Passiv_E(FB451_Passiv_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"FB451_Passiv_E_Freq>0 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': FB451_Passiv_E_Color_Uncert}\">\r\n {{RoundDownStringComma(FB451_Passiv_E(FB451_Passiv_E_Freq),1)}} V/m ({{RoundDownStringComma(FB451_Passiv_E(FB451_Passiv_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_Expo2_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-EXPO2-E\" | translate}}</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo2_E_Color}\">\r\n {{RoundDownStringComma(V15_Expo2_E(DGUVV15_Expo2_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo2_E_Color_Uncert}\">\r\n {{RoundDownStringComma(V15_Expo2_E(DGUVV15_Expo2_E_Freq),1)}} V/m ({{RoundDownStringComma(V15_Expo2_E(DGUVV15_Expo2_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_Expo1_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-EXPO1-E\" | translate}}</td>\r\n <td *ngIf=\"!UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo1_E_Color}\">\r\n {{RoundDownStringComma(V15_Expo1_E(DGUVV15_Expo1_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_Expo1_E_Color_Uncert}\">\r\n {{RoundDownStringComma(V15_Expo1_E(DGUVV15_Expo1_E_Freq),1)}} V/m ({{RoundDownStringComma(V15_Expo1_E(DGUVV15_Expo1_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_ExpoEr_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-HIGH-E\" | translate}}</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_E_Freq>91e3\">-</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_E_Freq<=91e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_E_Color}\">\r\n {{RoundDownStringComma(V15_ExpoEr_E(DGUVV15_ExpoEr_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_E_Freq<=91e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_E_Color_Uncert}\">\r\n {{RoundDownStringComma(V15_ExpoEr_E(DGUVV15_ExpoEr_E_Freq),1)}} V/m ({{RoundDownStringComma(V15_ExpoEr_E(DGUVV15_ExpoEr_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"DGUVV15\">\r\n <td>DGUV V15</td>\r\n <td>{{RoundDownStringComma(DGUVV15_ExpoEr_Spitze_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.DGUVV15-PEAK-E\" | translate}}</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_E_Freq<91e3\">-</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_E_Freq>=91e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_Spitze_E_Color}\">\r\n {{RoundDownStringComma(V15_ExpoEr_Spitze_E(DGUVV15_ExpoEr_Spitze_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"DGUVV15_ExpoEr_Spitze_E_Freq>=91e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': DGUVV15_ExpoEr_Spitze_E_Color_Uncert}\">\r\n {{RoundDownStringComma(V15_ExpoEr_Spitze_E(DGUVV15_ExpoEr_Spitze_E_Freq),1)}} V/m ({{RoundDownStringComma(V15_ExpoEr_Spitze_E(DGUVV15_ExpoEr_Spitze_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr> \r\n <tr *ngIf=\"EU1999\">\r\n <td>EU 1999</td>\r\n <td>{{RoundDownStringComma(EU1999_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU99-REF-TAB\" | translate}}</td>\r\n <td *ngIf=\"EU1999_E_Freq<1\">-</td>\r\n <td *ngIf=\"EU1999_E_Freq>=1 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_E_Color}\">\r\n {{RoundDownStringComma(EU1999_E(EU1999_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EU1999_E_Freq>=1 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_E_Color_Uncert}\">\r\n {{RoundDownStringComma(EU1999_E(EU1999_E_Freq),1)}} V/m ({{RoundDownStringComma(EU1999_E(EU1999_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"EU1999\">\r\n <td>EU 1999</td>\r\n <td>{{RoundDownStringComma(EU1999_Spitze_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.EU99-PEAK-TAB\" | translate}}</td>\r\n <td *ngIf=\"EU1999_Spitze_E_Freq<1\">-</td>\r\n <td *ngIf=\"EU1999_Spitze_E_Freq>=1 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_Spitze_E_Color}\">\r\n {{RoundDownStringComma(EU1999_E_Spitze(EU1999_Spitze_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"EU1999_Spitze_E_Freq>=1 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': EU1999_Spitze_E_Color_Uncert}\">\r\n {{RoundDownStringComma(EU1999_E_Spitze(EU1999_Spitze_E_Freq),1)}} V/m ({{RoundDownStringComma(EU1999_E_Spitze(EU1999_Spitze_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"BImSchV\">\r\n <td>26. BImSchV</td>\r\n <td>{{RoundDownStringComma(BImSchV_NF_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.BIMSCHV-LF-TAB\" | translate}}</td>\r\n <td *ngIf=\"!(BImSchV_NF_E_Freq >= 1 && BImSchV_NF_E_Freq<=10e6)\">-</td>\r\n <td *ngIf=\"(BImSchV_NF_E_Freq >= 1 && BImSchV_NF_E_Freq<=10e6) && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_NF_E_Color}\">\r\n {{RoundDownStringComma(BImSchV_E_NF(BImSchV_NF_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"(BImSchV_NF_E_Freq >= 1 && BImSchV_NF_E_Freq<=10e6) && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_NF_E_Color_Uncert}\">\r\n {{RoundDownStringComma(BImSchV_E_NF(BImSchV_NF_E_Freq),1)}} V/m ({{RoundDownStringComma(BImSchV_E_NF(BImSchV_NF_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"BImSchV\">\r\n <td>26. BImSchV</td>\r\n <td>{{RoundDownStringComma(BImSchV_HF_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.BIMSCHV-HF-TAB\" | translate}}</td>\r\n <td *ngIf=\"BImSchV_HF_E_Freq<100e3\">-</td>\r\n <td *ngIf=\"BImSchV_HF_E_Freq>=100e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_HF_E_Color}\">\r\n {{RoundDownStringComma(BImSchV_E_HF(BImSchV_HF_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"BImSchV_HF_E_Freq>=100e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_HF_E_Color_Uncert}\">\r\n {{RoundDownStringComma(BImSchV_E_HF(BImSchV_HF_E_Freq),1)}} V/m ({{RoundDownStringComma(BImSchV_E_HF(BImSchV_HF_E_Freq)/FaktorU,1)}} V/m)</td> \r\n </tr>\r\n <tr *ngIf=\"BImSchV\">\r\n <td>26. BImSchV</td>\r\n <td>{{RoundDownStringComma(BImSchV_Spitze_E_Freq,-1)}}</td>\r\n <td>{{\"VALUES.BIMSCHV-PEAK-TAB\" | translate}}</td>\r\n <td *ngIf=\"BImSchV_Spitze_E_Freq<9e3\">-</td>\r\n <td *ngIf=\"BImSchV_Spitze_E_Freq>=9e3 && !UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_Spitze_E_Color}\">\r\n {{RoundDownStringComma(BImSchV_E_Spitze(BImSchV_Spitze_E_Freq),1)}} V/m</td>\r\n <td *ngIf=\"BImSchV_Spitze_E_Freq>=9e3 && UnsicherheitCheck\" [ngStyle]=\"{'background-color': BImSchV_Spitze_E_Color_Uncert}\">\r\n {{RoundDownStringComma(BImSchV_E_Spitze(BImSchV_Spitze_E_Freq),1)}} V/m ({{RoundDownStringComma(BImSchV_E_Spitze(BImSchV_Spitze_E_Freq)/FaktorU,1)}} V/m)</td>\r\n </tr>\r\n </table>\r\n </div>\r\n\r\n <!-- Hinweis nur für DGUV V15 und 91e3 <= f <= 300e9 Hz anzeigen -->\r\n <div *ngIf=\"Frequenz >= 91e3 && Frequenz <= 300e9 && DGUVV15\">\r\n <b>{{\"GENERAL.NOTE\" | translate}} DGUV V15:</b> {{\"VALUES.DGUVV15-NOTE\" | translate}}.\r\n </div>\r\n\r\n <div style=\"width:900px; height:500px\">\r\n <canvas id=\"EFeldChart\" width=\"900\" height=\"500\" aria-label=\"Zulässige Werte für das elektrische Feld\"\r\n role=\"img\" #EFeldChart></canvas>\r\n </div>\r\n </app-tab-body>\r\n </app-tab-item>\r\n <app-tab-item label=\"HELP.NAME\"> \r\n <app-tab-body> \r\n {{\"HELP.P1_1\" | translate}} <b>EMF-LIT</b> {{\"HELP.P1_2\" | translate}}. {{\"HELP.P1_3\" | translate}}.<br />\r\n <br />\r\n {{\"HELP.P2_1\" | translate}}. {{\"HELP.P2_2\" | translate}}. {{\"HELP.P2_3\" | translate}}. {{\"HELP.P2_4\" | translate}}.<br />\r\n <br /> \r\n <b>{{\"HELP.P3_1\" | translate}}.</b> <br />\r\n {{\"HELP.P3_2\" | translate}}. <br />\r\n <br /> \r\n {{\"HELP.P4_1\" | translate}} <b>{{\"HELP.P4_2\" | translate}}</b>:<br />\r\n <ul>\r\n <li>\r\n <ng-container *ngIf=\"currentLanguage === 'de'\">\r\n <b>EU 2013</b>: <a href=\"https://eur-lex.europa.eu/legal-content/DE/TXT/PDF/?uri=CELEX:32013L0035\" target=\"_blank\">{{\"HELP.EU2013\" | translate}}</a>\r\n </ng-container>\r\n <ng-container *ngIf=\"currentLanguage !== 'de'\">\r\n <b>EU 2013</b>: <a href=\"https://eur-lex.europa.eu/legal-content/EN/TXT/PDF/?uri=CELEX:32013L0035\" target=\"_blank\">{{\"HELP.EU2013\" | translate}}</a>\r\n </ng-container>\r\n </li>\r\n <li>\r\n <b>EMFV</b>: <a href=\"http://www.gesetze-im-internet.de/emfv/\" target=\"_blank\">{{\"HELP.EMFV\" | translate}}</a>\r\n </li>\r\n <li>\r\n <b>TREMF ({{\"GENERAL.IMPLANTS\" | translate}})</b>: <a href=\"https://www.baua.de/DE/Angebote/Regelwerk/TREMF/TREMF.html\" target=\"_blank\">{{\"HELP.TREMF\" | translate}}</a> <br />\r\n {{\"HELP.TREMF_1\" | translate}}. {{\"HELP.TREMF_2\" | translate}} <a href=\"https://www.bmas.de/DE/Service/Publikationen/Forschungsberichte/forschungsbericht-fb451.html\" target=\"_blank\">{{\"HELP.TREMF_3\" | translate}}</a> {{\"HELP.TREMF_4\" | translate}}.\r\n </li>\r\n <li>\r\n <b>DGUV V15</b>: <a href=\"http://publikationen.dguv.de/dguv/udt_dguv_main.aspx?FDOCUID=24185\" target=\"_blank\">{{\"HELP.DGUV-V15\" | translate}}</a> <br />\r\n {{\"HELP.DGUV-V15_1\" | translate}}. {{\"HELP.DGUV-V15_2\" | translate}}.\r\n </li>\r\n </ul>\r\n\r\n {{\"HELP.P5_1\" | translate}} <b>{{\"HELP.P5_2\" | translate}}</b>:<br />\r\n <ul>\r\n <ng-container *ngIf=\"currentLanguage === 'de'\">\r\n <li>\r\n <b>EU 1999</b>: <a href=\"https://eur-lex.europa.eu/legal-content/DE/TXT/PDF/?uri=CELEX:31999H0519&from=DE\" target=\"_blank\">{{\"HELP.EU99\" | translate}}</a>\r\n </li>\r\n <li>\r\n <b>26. BImSchV</b>: <a href=\"https://www.gesetze-im-internet.de/bimschv_26/\" target=\"_blank\">{{\"HELP.BIMSCHV\" | translate}}</a>\r\n </li>\r\n </ng-container>\r\n <ng-container *ngIf=\"currentLanguage !== 'de'\">\r\n <li>\r\n <b>EU 1999</b>: <a href=\"https://eur-lex.europa.eu/legal-content/EN/TXT/PDF/?uri=CELEX:31999H0519\" target=\"_blank\">{{\"HELP.EU99\" | translate}}</a>\r\n </li>\r\n <li>\r\n <b>26. BImSchV</b>: <a href=\"https://www.bmuv.de/fileadmin/Daten_BMU/Download_PDF/Luft/26_bimschv_en_bf.pdf\" target=\"_blank\">{{\"HELP.BIMSCHV\" | translate}}</a>\r\n </li>\r\n </ng-container>\r\n </ul>\r\n <b>{{\"HELP.NOTES\" | translate}}</b> <br /> \r\n <ul> \r\n <li>\r\n {{\"HELP.P6_1\" | translate}}.\r\n </li>\r\n <li>\r\n {{\"HELP.P6_7\" | translate}}.\r\n </li>\r\n <li>\r\n {{\"HELP.P6_2\" | translate}}.\r\n </li>\r\n <li> \r\n {{\"HELP.P6_3\" | translate}}<br /> \r\n - {{\"HELP.P6_3_2\" | translate}}<br /> \r\n - {{\"HELP.P6_3_3\" | translate}}<br /> \r\n - {{\"HELP.P6_3_4\" | translate}}<br /> \r\n {{\"HELP.P6_3_5\" | translate}}\r\n </li>\r\n <li>\r\n {{\"HELP.P6_4\" | translate}}\r\n </li> \r\n <li>\r\n {{\"HELP.P6_8_1\" | translate}}\r\n <span style=\"background-color:rgba(0, 255, 0, 0.507)\">{{\"HELP.P6_8_2\" | translate}}</span>{{\"HELP.P6_8_3\" | translate}}\r\n <span style=\"background-color:rgba(255, 0, 0, 0.514)\">{{\"HELP.P6_8_4\" | translate}}</span>{{\"HELP.P6_8_5\" | translate}}\r\n <span style=\"background-color:rgba(161, 161, 161, 0.534)\">{{\"HELP.P6_8_6\" | translate}}</span>.\r\n </li> \r\n <li>\r\n {{\"HELP.P6_9\" | translate}}.\r\n </li> \r\n <li>\r\n {{\"HELP.P6_5\" | translate}} <a href=\"https://www.baua.de/DE/Angebote/Rechtstexte-und-Technische-Regeln/Regelwerk/TREMF/TREMF.html\" target=\"_blank\">{{\"HELP.P6_6\" | translate}}</a>.\r\n </li>\r\n </ul>\r\n <b>{{\"HELP.P7_1\" | translate}}</b> <br />\r\n {{\"HELP.P7_2\" | translate}}.<br />\r\n <br />\r\n <b>{{\"HELP.P8_1\" | translate}}</b> <br />\r\n <ul>\r\n <li>\r\n {{\"HELP.P8_2\" | translate}}.\r\n </li>\r\n <li>\r\n {{\"HELP.P8_3\" | translate}}: <br /> \r\n {{\"HELP.P8_4\" | translate}}<br />\r\n {{\"HELP.P8_5\" | translate}}.\r\n </li>\r\n <li>\r\n {{\"HELP.P8_6\" | translate}}.\r\n </li> \r\n </ul> \r\n {{\"HELP.P9_0\" | translate}}<br />\r\n <ng-container *ngIf=\"currentLanguage === 'de'\">\r\n {{\"HELP.P9_1\" | translate}} <a href=\"mailto:EMF-LIT@DGUV.DE\">EMF-LIT@DGUV.DE</a> {{\"HELP.P9_2\" | translate}} <a href=\"https://www.dguv.de/ifa/fachinfos/elektromagnetische-felder/index.jsp\"\r\n target=\"_blank\">{{\"HELP.P9_3\" | translate}}</a>. <br />\r\n </ng-container>\r\n <ng-container *ngIf=\"currentLanguage !== 'de'\">\r\n {{\"HELP.P9_1\" | translate}} <a href=\"mailto:EMF-LIT@DGUV.DE\">EMF-LIT@DGUV.DE</a> {{\"HELP.P9_2\" | translate}} <a href=\"https://www.dguv.de/ifa/fachinfos/elektromagnetische-felder/index-2.jsp\"\r\n target=\"_blank\">{{\"HELP.P9_3\" | translate}}</a>. <br />\r\n </ng-container> \r\n </app-tab-body>\r\n </app-tab-item>\r\n</app-tabs>","import { EmfLitComponent } from \"./emf-lit.component\";\r\n\r\nexport const Schwellen_EU1999_B = [[0.01, 40], [1, 40], [8, 0.625], [25, 0.2], [0.8e3, 6.25e-3], [150e3, 6.25e-3], [10e6, 0.092e-3], [400e6, 0.092e-3], [2e9, 0.2e-3], [3e11, 0.2e-3]].map(function(value){return [value[0], value[1] / 1000];});\r\nexport const Schwellen_EU1999_B_Spitze = [[0.01, 40*Math.SQRT2], [1, 40*Math.SQRT2], [8, 0.625*Math.SQRT2], [25, 0.2*Math.SQRT2], [0.8e3, 6.25e-3*Math.SQRT2], [100e3, 6.25e-3*Math.SQRT2], [150e3, 6.25e-3*1.96], [10e6, 0.092e-3*31.99], [400e6, 0.092e-3*32], [2e9, 0.2e-3*32], [3e11, 0.2e-3*32]].map(function(value){return [value[0], value[1] / 1000];});\r\nexport const Schwellen_EU1999_E = [[1, 10e3], [25, 10e3], [3e3, 87], [1e6, 87], [10e6, 28], [400e6, 28], [2e9, 61], [3e11, 61]];\r\nexport const Schwellen_EU1999_E_Spitze = [[1, 10e3*Math.SQRT2], [25, 10e3*Math.SQRT2], [3e3, 87*Math.SQRT2], [100e3, 87*Math.SQRT2], [1e6, 87*6.93], [10e6, 28*31.99], [400e6, 28*32], [2e9, 61*32], [3e11, 61*32]];\r\n\r\nexport function updateEU1999_B_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // EU 1999 B-Feld\r\n // Range Check\r\n if (this.EU1999_B_Freq < 0 || this.EU1999_B_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index].data = [];\r\n this.BFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU1999_B_Freq,\r\n y: (this.EU1999_B(this.EU1999_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ];\r\n }\r\n else {\r\n data = [\r\n {\r\n x: this.EU1999_B_Freq,\r\n y: (this.EU1999_B(this.EU1999_B_Freq) / 1000)\r\n }\r\n ];\r\n }\r\n this.BFeldChart.data.datasets[index].data = data;\r\n this.BFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.EU1999_B_Freq + ' Hz (in T)';\r\n }\r\n // EU 1999 Spitzenwerte B-Feld\r\n // Range Check\r\n if (this.EU1999_Spitze_B_Freq < 0 || this.EU1999_Spitze_B_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index+2].data = [];\r\n this.BFeldChart.data.datasets[index+2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU1999_Spitze_B_Freq,\r\n y: (this.EU1999_B_Spitze(this.EU1999_Spitze_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n }\r\n else {\r\n data = [\r\n {\r\n x: this.EU1999_Spitze_B_Freq,\r\n y: (this.EU1999_B_Spitze(this.EU1999_Spitze_B_Freq) / 1000)\r\n }\r\n ]; \r\n }\r\n this.BFeldChart.data.datasets[index+2].data = data;\r\n this.BFeldChart.data.datasets[index+2].label =\r\n 'Wert bei ' + this.EU1999_Spitze_B_Freq + ' Hz (in T)';\r\n }\r\n}\r\n\r\nexport function updateEU1999_E_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // EU 1999 E-Feld\r\n // Range Check\r\n if (this.EU1999_E_Freq < 1 || this.EU1999_E_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index].data = [];\r\n this.EFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU1999_E_Freq,\r\n y: this.EU1999_E(this.EU1999_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n }\r\n else {\r\n data = [\r\n {\r\n x: this.EU1999_E_Freq,\r\n y: this.EU1999_E(this.EU1999_E_Freq)\r\n }\r\n ]; \r\n }\r\n this.EFeldChart.data.datasets[index].data = data;\r\n this.EFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.EU1999_E_Freq + ' Hz (in V/m)';\r\n }\r\n // EU 1999 Spitzenwerte E-Feld\r\n // Range Check\r\n if (this.EU1999_Spitze_E_Freq < 1 || this.EU1999_Spitze_E_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index+2].data = [];\r\n this.EFeldChart.data.datasets[index+2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU1999_Spitze_E_Freq,\r\n y: this.EU1999_E_Spitze(this.EU1999_Spitze_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } \r\n else {\r\n data = [\r\n {\r\n x: this.EU1999_Spitze_E_Freq,\r\n y: this.EU1999_E_Spitze(this.EU1999_Spitze_E_Freq)\r\n }\r\n ]; \r\n }\r\n this.EFeldChart.data.datasets[index+2].data = data;\r\n this.EFeldChart.data.datasets[index+2].label =\r\n 'Wert bei ' + this.EU1999_Spitze_E_Freq + ' Hz (in V/m)';\r\n }\r\n}\r\n\r\nexport function updateEU1999_B_Regelwerk(this: EmfLitComponent) {\r\n let EU1999_B_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.EU99-REF\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU1999_B[0][0], y: Schwellen_EU1999_B[0][1] }, \r\n { x: Schwellen_EU1999_B[1][0], y: Schwellen_EU1999_B[1][1] },\r\n { x: Schwellen_EU1999_B[2][0], y: Schwellen_EU1999_B[2][1] },\r\n { x: Schwellen_EU1999_B[3][0], y: Schwellen_EU1999_B[3][1] },\r\n { x: Schwellen_EU1999_B[4][0], y: Schwellen_EU1999_B[4][1] },\r\n { x: Schwellen_EU1999_B[5][0], y: Schwellen_EU1999_B[5][1] },\r\n { x: Schwellen_EU1999_B[6][0], y: Schwellen_EU1999_B[6][1] },\r\n { x: Schwellen_EU1999_B[7][0], y: Schwellen_EU1999_B[7][1] },\r\n { x: Schwellen_EU1999_B[8][0], y: Schwellen_EU1999_B[8][1] },\r\n { x: Schwellen_EU1999_B[9][0], y: Schwellen_EU1999_B[9][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU1999_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EU1999_B_Freq,\r\n y: this.EU1999_B(this.EU1999_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EU99-PEAK\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU1999_B_Spitze[0][0], y: Schwellen_EU1999_B_Spitze[0][1] }, \r\n { x: Schwellen_EU1999_B_Spitze[1][0], y: Schwellen_EU1999_B_Spitze[1][1] },\r\n { x: Schwellen_EU1999_B_Spitze[2][0], y: Schwellen_EU1999_B_Spitze[2][1] },\r\n { x: Schwellen_EU1999_B_Spitze[3][0], y: Schwellen_EU1999_B_Spitze[3][1] },\r\n { x: Schwellen_EU1999_B_Spitze[4][0], y: Schwellen_EU1999_B_Spitze[4][1] },\r\n { x: Schwellen_EU1999_B_Spitze[5][0], y: Schwellen_EU1999_B_Spitze[5][1] },\r\n { x: Schwellen_EU1999_B_Spitze[6][0], y: Schwellen_EU1999_B_Spitze[6][1] },\r\n { x: Schwellen_EU1999_B_Spitze[7][0], y: Schwellen_EU1999_B_Spitze[7][1] },\r\n { x: Schwellen_EU1999_B_Spitze[8][0], y: Schwellen_EU1999_B_Spitze[8][1] },\r\n { x: Schwellen_EU1999_B_Spitze[9][0], y: Schwellen_EU1999_B_Spitze[9][1] },\r\n { x: Schwellen_EU1999_B_Spitze[10][0], y: Schwellen_EU1999_B_Spitze[10][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n pointStyle: 'triangle',\r\n borderDash: [10, 6],\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU1999_Spitze_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EU1999_Spitze_B_Freq,\r\n y: this.EU1999_B_Spitze(this.EU1999_Spitze_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n this.BFeldChart.data.datasets = [\r\n ...this.BFeldChart.data.datasets,\r\n ...EU1999_B_data\r\n ];\r\n}\r\n\r\nexport function updateEU1999_E_Regelwerk(this: EmfLitComponent) {\r\n let EU1999_E_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.EU99-REF\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU1999_E[0][0], y: Schwellen_EU1999_E[0][1] }, \r\n { x: Schwellen_EU1999_E[1][0], y: Schwellen_EU1999_E[1][1] },\r\n { x: Schwellen_EU1999_E[2][0], y: Schwellen_EU1999_E[2][1] },\r\n { x: Schwellen_EU1999_E[3][0], y: Schwellen_EU1999_E[3][1] },\r\n { x: Schwellen_EU1999_E[4][0], y: Schwellen_EU1999_E[4][1] },\r\n { x: Schwellen_EU1999_E[5][0], y: Schwellen_EU1999_E[5][1] },\r\n { x: Schwellen_EU1999_E[6][0], y: Schwellen_EU1999_E[6][1] },\r\n { x: Schwellen_EU1999_E[7][0], y: Schwellen_EU1999_E[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU1999_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EU1999_E_Freq,\r\n y: this.EU1999_E(this.EU1999_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EU99-PEAK\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU1999_E_Spitze[0][0], y: Schwellen_EU1999_E_Spitze[0][1] }, \r\n { x: Schwellen_EU1999_E_Spitze[1][0], y: Schwellen_EU1999_E_Spitze[1][1] },\r\n { x: Schwellen_EU1999_E_Spitze[2][0], y: Schwellen_EU1999_E_Spitze[2][1] },\r\n { x: Schwellen_EU1999_E_Spitze[3][0], y: Schwellen_EU1999_E_Spitze[3][1] },\r\n { x: Schwellen_EU1999_E_Spitze[4][0], y: Schwellen_EU1999_E_Spitze[4][1] },\r\n { x: Schwellen_EU1999_E_Spitze[5][0], y: Schwellen_EU1999_E_Spitze[5][1] },\r\n { x: Schwellen_EU1999_E_Spitze[6][0], y: Schwellen_EU1999_E_Spitze[6][1] },\r\n { x: Schwellen_EU1999_E_Spitze[7][0], y: Schwellen_EU1999_E_Spitze[7][1] },\r\n { x: Schwellen_EU1999_E_Spitze[8][0], y: Schwellen_EU1999_E_Spitze[8][1] } \r\n ],\r\n fill: false,\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n pointStyle: 'triangle',\r\n borderDash: [10, 6],\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU1999_Spitze_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EU1999_Spitze_E_Freq,\r\n y: this.EU1999_E_Spitze(this.EU1999_Spitze_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(217, 159, 25, 1)',\r\n pointBackgroundColor: 'rgba(217, 159, 25, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n this.EFeldChart.data.datasets = [\r\n ...this.EFeldChart.data.datasets,\r\n ...EU1999_E_data\r\n ];\r\n}\r\n\r\nexport function EU1999_B(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // EU 1999 Referenzwert - B-Field\r\n Schwelle = 40; //in mT\r\n if (Frequenz > 1) {\r\n if (Frequenz < 8) {\r\n Schwelle = 40 / Math.pow(Frequenz, 2);\r\n } else {\r\n if (Frequenz < 0.8e3) {\r\n Schwelle = 5 / Frequenz;\r\n } else {\r\n if (Frequenz < 0.15e6) {\r\n Schwelle = 6.25e-3;\r\n } else {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 0.92e-3 / (Frequenz / 1e6);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 0.092e-3;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 0.0046e-3 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n Schwelle = 0.2e-3;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function EU1999_E(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // EU 1999 Referenzwert - E-Field\r\n Schwelle = NaN; //in V/m\r\n if (Frequenz >= 1) {\r\n if (Frequenz < 25) {\r\n Schwelle = 10e3;\r\n } else {\r\n if (Frequenz <= 3e3) { // use <= to get the conservative value of 250/3 instead of 87\r\n Schwelle = 250 / (Frequenz / 1e3);\r\n } else {\r\n if (Frequenz < 1e6) {\r\n Schwelle = 87;\r\n } else {\r\n if (Frequenz <= 10e6) { // use <= to get the conservative value of 87/sqrt(10) instead of 28\r\n Schwelle = 87 / Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 28;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 1.375 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n Schwelle = 61;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n} \r\n\r\nexport function EU1999_E_Spitze(Frequenz: number) {\r\n if (Frequenz < 1 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // EU1999 Referenzwert - E-Field (Spitzenwert)\r\n Schwelle = NaN; //in V/m, NaN up to 1 Hz\r\n\r\n if (Frequenz >= 1) {\r\n if (Frequenz <= 100e3) {\r\n Schwelle = EU1999_E(Frequenz) * Math.SQRT2;\r\n } else {\r\n if (Frequenz < 10e6) { // use < instead of <= to be conservative\r\n Schwelle = EU1999_E(Frequenz) * Math.pow(10, 0.665 * Math.log10(Frequenz / 1e5) + 0.176);\r\n } else {\r\n if (Frequenz <= 300e9) {\r\n Schwelle = EU1999_E(Frequenz) * 32;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function EU1999_B_Spitze(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // EU1999 Referenzwert - B-Field (Spitzenwert)\r\n Schwelle = NaN; //in mT, NaN up to 0 Hz\r\n\r\n if (Frequenz >= 0) {\r\n if (Frequenz <= 100e3) {\r\n Schwelle = EU1999_B(Frequenz) * Math.SQRT2;\r\n } else {\r\n if (Frequenz < 10e6) { // use < instead of <= to be conservative\r\n Schwelle = EU1999_B(Frequenz) * Math.pow(10, 0.665 * Math.log10(Frequenz / 1e5) + 0.176);\r\n } else {\r\n if (Frequenz <= 300e9) {\r\n Schwelle = EU1999_B(Frequenz) * 32;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n","import { EmfLitComponent } from \"./emf-lit.component\";\r\n\r\n// Schwellen B\r\nexport const Schwellen_FB451_Aktiv_B = [[0.01, 555], [9.97, 555], [1e3, 5.55], [3e3, 16.7], [167e3, 16.7], [1e6, 2778/1e3], [5.33e6, 2.78], [10e6, 1.48], [16.9e6, 0.52], [200e6, 0.52], [400e6, 4], [1.5e9, 4], [2.5e9, 1.18*Math.pow(2.5, 3)]].map(function(value){return [value[0], value[1] * 4.0 * Math.PI * Math.pow(10, -7)];});\r\nexport const Schwellen_FB451_Passiv_B = [[0.01, 47750], [1.6, 47750], [1e3, 76.4], [91e3, 76.43], [30e6, 0.231], [400e6, 0.231], [2e9, 0.515], [3e11, 0.515]].map(function(value){return [value[0], value[1] * 4.0 * Math.PI * Math.pow(10, -7)];});\r\nexport const Schwellen_FB451_Aktiv_E = [[0.01, 28300], [15.9, 28300], [1e3, 450], [3e3, 1350], [25e3, 1350], [167e3, 9185], [300e3, 9185], [1e6, 2770], [5.33e6, 2770], [10e6, 870.12], [16.9e6, 195], [200e6, 195], [400e6, 1500], [1.5e9, 1500], [2.5e9, 446*Math.pow(2.5, 3)]];\r\nexport const Schwellen_FB451_Passiv_E = [[0.01, 28300], [53.3, 28300], [1e3, 1510], [576e3, 1510], [10e6, 86.8], [400e6, 86.8], [2e9, 194], [3e11, 194]];\r\n\r\n\r\nexport function updateFB451_B_Regelwerk(this: EmfLitComponent) {\r\n let FB451_B_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.FB451-ACTIVE\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_FB451_Aktiv_B[0][0], y: Schwellen_FB451_Aktiv_B[0][1] }, \r\n { x: Schwellen_FB451_Aktiv_B[1][0], y: Schwellen_FB451_Aktiv_B[1][1] },\r\n { x: Schwellen_FB451_Aktiv_B[2][0], y: Schwellen_FB451_Aktiv_B[2][1] },\r\n { x: Schwellen_FB451_Aktiv_B[3][0], y: Schwellen_FB451_Aktiv_B[3][1] },\r\n { x: Schwellen_FB451_Aktiv_B[4][0], y: Schwellen_FB451_Aktiv_B[4][1] },\r\n { x: Schwellen_FB451_Aktiv_B[5][0], y: Schwellen_FB451_Aktiv_B[5][1] },\r\n { x: Schwellen_FB451_Aktiv_B[6][0], y: Schwellen_FB451_Aktiv_B[6][1] },\r\n { x: Schwellen_FB451_Aktiv_B[7][0], y: Schwellen_FB451_Aktiv_B[7][1] },\r\n { x: Schwellen_FB451_Aktiv_B[8][0], y: Schwellen_FB451_Aktiv_B[8][1] },\r\n { x: Schwellen_FB451_Aktiv_B[9][0], y: Schwellen_FB451_Aktiv_B[9][1] },\r\n { x: Schwellen_FB451_Aktiv_B[10][0], y: Schwellen_FB451_Aktiv_B[10][1] },\r\n { x: Schwellen_FB451_Aktiv_B[11][0], y: Schwellen_FB451_Aktiv_B[11][1] },\r\n { x: Schwellen_FB451_Aktiv_B[12][0], y: Schwellen_FB451_Aktiv_B[12][1] } \r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 0, 0, 1)',\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(255, 0, 0, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.FB451_Aktiv_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.FB451_Aktiv_B_Freq,\r\n y: this.FB451_Aktiv_B(this.FB451_Aktiv_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(255, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(255, 0, 0, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.FB451-PASSIVE\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_FB451_Passiv_B[0][0], y: Schwellen_FB451_Passiv_B[0][1] }, \r\n { x: Schwellen_FB451_Passiv_B[1][0], y: Schwellen_FB451_Passiv_B[1][1] },\r\n { x: Schwellen_FB451_Passiv_B[2][0], y: Schwellen_FB451_Passiv_B[2][1] },\r\n { x: Schwellen_FB451_Passiv_B[3][0], y: Schwellen_FB451_Passiv_B[3][1] },\r\n { x: Schwellen_FB451_Passiv_B[4][0], y: Schwellen_FB451_Passiv_B[4][1] },\r\n { x: Schwellen_FB451_Passiv_B[5][0], y: Schwellen_FB451_Passiv_B[5][1] },\r\n { x: Schwellen_FB451_Passiv_B[6][0], y: Schwellen_FB451_Passiv_B[6][1] },\r\n { x: Schwellen_FB451_Passiv_B[7][0], y: Schwellen_FB451_Passiv_B[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(10, 200, 10, 1)',\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(10, 200, 10, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.FB451_Passiv_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.FB451_Passiv_B_Freq,\r\n y: this.FB451_Passiv_B(this.FB451_Passiv_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(10, 200, 10, 1)',\r\n pointBackgroundColor: 'rgba(10, 200, 10, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n this.BFeldChart.data.datasets = [\r\n ...this.BFeldChart.data.datasets,\r\n ...FB451_B_data\r\n ];\r\n}\r\n\r\nexport function updateFB451_E_Regelwerk(this: EmfLitComponent) {\r\n let FB451_E_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.FB451-ACTIVE\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_FB451_Aktiv_E[0][0], y: Schwellen_FB451_Aktiv_E[0][1] }, \r\n { x: Schwellen_FB451_Aktiv_E[1][0], y: Schwellen_FB451_Aktiv_E[1][1] },\r\n { x: Schwellen_FB451_Aktiv_E[2][0], y: Schwellen_FB451_Aktiv_E[2][1] },\r\n { x: Schwellen_FB451_Aktiv_E[3][0], y: Schwellen_FB451_Aktiv_E[3][1] },\r\n { x: Schwellen_FB451_Aktiv_E[4][0], y: Schwellen_FB451_Aktiv_E[4][1] },\r\n { x: Schwellen_FB451_Aktiv_E[5][0], y: Schwellen_FB451_Aktiv_E[5][1] },\r\n { x: Schwellen_FB451_Aktiv_E[6][0], y: Schwellen_FB451_Aktiv_E[6][1] },\r\n { x: Schwellen_FB451_Aktiv_E[7][0], y: Schwellen_FB451_Aktiv_E[7][1] },\r\n { x: Schwellen_FB451_Aktiv_E[8][0], y: Schwellen_FB451_Aktiv_E[8][1] },\r\n { x: Schwellen_FB451_Aktiv_E[9][0], y: Schwellen_FB451_Aktiv_E[9][1] },\r\n { x: Schwellen_FB451_Aktiv_E[10][0], y: Schwellen_FB451_Aktiv_E[10][1] },\r\n { x: Schwellen_FB451_Aktiv_E[11][0], y: Schwellen_FB451_Aktiv_E[11][1] },\r\n { x: Schwellen_FB451_Aktiv_E[12][0], y: Schwellen_FB451_Aktiv_E[12][1] }, \r\n { x: Schwellen_FB451_Aktiv_E[13][0], y: Schwellen_FB451_Aktiv_E[13][1] }, \r\n { x: Schwellen_FB451_Aktiv_E[14][0], y: Schwellen_FB451_Aktiv_E[14][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 0, 0, 1)',\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(255, 0, 0, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.FB451_Aktiv_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.FB451_Aktiv_E_Freq,\r\n y: this.FB451_Aktiv_E(this.FB451_Aktiv_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(255, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(255, 0, 0, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.FB451-PASSIVE\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_FB451_Passiv_E[0][0], y: Schwellen_FB451_Passiv_E[0][1] }, \r\n { x: Schwellen_FB451_Passiv_E[1][0], y: Schwellen_FB451_Passiv_E[1][1] },\r\n { x: Schwellen_FB451_Passiv_E[2][0], y: Schwellen_FB451_Passiv_E[2][1] },\r\n { x: Schwellen_FB451_Passiv_E[3][0], y: Schwellen_FB451_Passiv_E[3][1] },\r\n { x: Schwellen_FB451_Passiv_E[4][0], y: Schwellen_FB451_Passiv_E[4][1] },\r\n { x: Schwellen_FB451_Passiv_E[5][0], y: Schwellen_FB451_Passiv_E[5][1] },\r\n { x: Schwellen_FB451_Passiv_E[6][0], y: Schwellen_FB451_Passiv_E[6][1] },\r\n { x: Schwellen_FB451_Passiv_E[7][0], y: Schwellen_FB451_Passiv_E[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(10, 200, 10, 1)',\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(10, 200, 10, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.FB451_Passiv_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.FB451_Passiv_E_Freq,\r\n y: this.FB451_Passiv_E(this.FB451_Passiv_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(10, 200, 10, 1)',\r\n pointBackgroundColor: 'rgba(10, 200, 10, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n this.EFeldChart.data.datasets = [\r\n ...this.EFeldChart.data.datasets,\r\n ...FB451_E_data\r\n ];\r\n}\r\n\r\nexport function updateFB451_B_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // FB 451 Aktive Körperhilfsmittel\r\n // Range Check \r\n if (this.FB451_Aktiv_B_Freq < 0 || this.FB451_Aktiv_B_Freq > 2.5e9) {\r\n this.BFeldChart.data.datasets[index].data = [];\r\n this.BFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.FB451_Aktiv_B_Freq,\r\n y: (this.FB451_Aktiv_B(this.FB451_Aktiv_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.FB451_Aktiv_B_Freq,\r\n y: (this.FB451_Aktiv_B(this.FB451_Aktiv_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index].data = data;\r\n this.BFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.FB451_Aktiv_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // FB 451 Passive Körperhilfsmittel\r\n // Range Check\r\n if (this.FB451_Passiv_B_Freq < 0 || this.FB451_Passiv_B_Freq > 3e11) {\r\n this.BFeldChart.data.datasets[index + 2].data = [];\r\n this.BFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.FB451_Passiv_B_Freq,\r\n y: (this.FB451_Passiv_B(this.FB451_Passiv_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.FB451_Passiv_B_Freq,\r\n y: (this.FB451_Passiv_B(this.FB451_Passiv_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 2].data = data;\r\n this.BFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.FB451_Passiv_B_Freq + ' Hz (in T)';\r\n }\r\n}\r\n\r\nexport function updateFB451_E_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // FB 451 Aktive Körperhilfsmittel\r\n // Range Check\r\n // In der TREMF ist 0 Hz nicht definiert\r\n if (this.FB451_Aktiv_E_Freq <= 0 || this.FB451_Aktiv_E_Freq > 2.5e9) {\r\n this.EFeldChart.data.datasets[index].data = [];\r\n this.EFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.FB451_Aktiv_E_Freq,\r\n y: this.FB451_Aktiv_E(this.FB451_Aktiv_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.FB451_Aktiv_E_Freq,\r\n y: this.FB451_Aktiv_E(this.FB451_Aktiv_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index].data = data;\r\n this.EFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.FB451_Aktiv_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // FB 451 Passive Körperhilfsmittel\r\n // Range Check\r\n // In der TREMF ist 0 Hz nicht definiert\r\n if (this.FB451_Passiv_E_Freq <= 0 || this.FB451_Passiv_E_Freq > 3e11) {\r\n this.EFeldChart.data.datasets[index + 2].data = [];\r\n this.EFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.FB451_Passiv_E_Freq,\r\n y: this.FB451_Passiv_E(this.FB451_Passiv_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.FB451_Passiv_E_Freq,\r\n y: this.FB451_Passiv_E(this.FB451_Passiv_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 2].data = data;\r\n this.EFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.FB451_Passiv_E_Freq + ' Hz (in V/m)';\r\n }\r\n}\r\n\r\nexport function FB451_Passiv_B(Frequenz: number) {\r\n // In der TREMF ist 0 Hz über Tab. A1.17 definiert (siehe Ende der Funktion)\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Schwelle für passive Implantate\r\n Schwelle = 47750; //in A/m\r\n if (Frequenz > 1.6) {\r\n if (Frequenz <= 1000) {\r\n Schwelle = 76400 / Frequenz;\r\n } else {\r\n if (Frequenz <= 91e3) {\r\n Schwelle = 76.4;\r\n } else {\r\n if (Frequenz <= 30e6) {\r\n Schwelle = 6.93 / (Frequenz / 1e6);\r\n } else {\r\n if (Frequenz <= 400e6) {\r\n Schwelle = 0.231;\r\n } else {\r\n if (Frequenz <= 2e9) {\r\n Schwelle = 11.5e-3 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n Schwelle = 0.515;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n //A/m -> mT\r\n Schwelle = Schwelle * (4 * Math.PI * 1e-4);\r\n\r\n if (Frequenz === 0) {\r\n Schwelle = 60; //bereits in mT\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function FB451_Aktiv_B(Frequenz: number) {\r\n // In der TREMF ist 0 Hz über Tab. A1.16 definiert (siehe Ende der Funktion)\r\n if (Frequenz < 0 || Frequenz > 2.5e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Schwelle für aktive Implantate\r\n Schwelle = 555; //in A/m\r\n if (Frequenz > 9.97) {\r\n if (Frequenz <= 1000) {\r\n Schwelle = 5555 / Frequenz;\r\n } else {\r\n if (Frequenz <= 3000) {\r\n Schwelle = 5.55 * (Frequenz / 1000);\r\n } else {\r\n if (Frequenz <= 167e3) {\r\n Schwelle = 16.7;\r\n } else {\r\n if (Frequenz <= 1e6) {\r\n Schwelle = 2778 / (Frequenz / 1000);\r\n } else {\r\n if (Frequenz <= 5.33e6) {\r\n Schwelle = 2.78;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = 14.8 / (Frequenz / 1e6);\r\n } else {\r\n if (Frequenz <= 16.9e6) {\r\n Schwelle = 148 / Math.pow(Frequenz / 1e6, 2);\r\n } else {\r\n if (Frequenz <= 200e6) {\r\n Schwelle = 0.52;\r\n } else {\r\n if (Frequenz <= 400e6) {\r\n Schwelle = 8.9e-8 * Math.pow(Frequenz / 1e6, 2.94);\r\n } else {\r\n if (Frequenz <= 1.5e9) {\r\n Schwelle = 4;\r\n } else {\r\n if (Frequenz <= 2.5e9) {\r\n Schwelle = 1.18 * Math.pow(Frequenz / 1e9, 3);\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n //A/m -> mT\r\n Schwelle = Schwelle * (4 * Math.PI * 1e-4);\r\n\r\n if (Frequenz === 0) {\r\n Schwelle = 1; //bereits in mT\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function FB451_Passiv_E(Frequenz: number) {\r\n // In der TREMF ist 0 Hz nicht definiert\r\n if (Frequenz <= 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Schwelle für passive Implantate\r\n Schwelle = 28300; //in V/m\r\n if (Frequenz > 53.3) {\r\n if (Frequenz <= 1000) {\r\n Schwelle = 1.51e6 / Frequenz;\r\n } else {\r\n if (Frequenz <= 576e3) {\r\n Schwelle = 1510;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = 8.68e5 / (Frequenz / 1e3);\r\n } else {\r\n if (Frequenz <= 400e6) {\r\n Schwelle = 86.8;\r\n } else {\r\n if (Frequenz <= 2e9) {\r\n Schwelle = 4.34 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n Schwelle = 194;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function FB451_Aktiv_E(Frequenz: number) {\r\n // In der TREMF ist 0 Hz nicht definiert\r\n if (Frequenz <= 0 || Frequenz > 2.5e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Schwelle für aktive Implantate\r\n Schwelle = 28300; //in V/m\r\n if (Frequenz > 15.9) {\r\n if (Frequenz <= 1000) {\r\n Schwelle = 4.5e5 / Frequenz;\r\n } else {\r\n if (Frequenz <= 3000) {\r\n Schwelle = 450 * (Frequenz / 1000);\r\n } else {\r\n if (Frequenz <= 25e3) {\r\n Schwelle = 1350;\r\n } else {\r\n if (Frequenz <= 167e3) {\r\n Schwelle = 55 * (Frequenz / 1000);\r\n } else {\r\n if (Frequenz <= 300e3) {\r\n Schwelle = 9185;\r\n } else {\r\n if (Frequenz <= 1e6) {\r\n Schwelle = 2.77e6 / (Frequenz / 1000);\r\n } else {\r\n if (Frequenz <= 5.33e6) {\r\n Schwelle = 2770;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = 6.16e4 / Math.pow(Frequenz / 1e6, 1.85);\r\n } else {\r\n if (Frequenz <= 16.9e6) {\r\n Schwelle = 6.16e5 / Math.pow(Frequenz / 1e6, 2.85);\r\n } else {\r\n if (Frequenz <= 200e6) {\r\n Schwelle = 195;\r\n } else {\r\n if (Frequenz <= 400e6) {\r\n Schwelle = 3.36e-5 * Math.pow(Frequenz / 1e6, 2.94);\r\n } else {\r\n if (Frequenz <= 1.5e9) {\r\n Schwelle = 1500;\r\n } else {\r\n if (Frequenz <= 2.5e9) {\r\n Schwelle = 446 * Math.pow(Frequenz / 1e9, 3);\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return Schwelle;\r\n}\r\n","import { EmfLitComponent } from \"./emf-lit.component\";\r\n\r\n// Schwellen B\r\nexport const Schwellen_EMFV_UAS_B = [[0.01, 2], [0.0175, 2], [25, 1.4e-3], [300, 1.4e-3], [3e3, 0.14e-3], [10e6, 0.14e-3]];\r\nexport const Schwellen_EMFV_OAS_B = [[0.01, 2], [0.21, 2], [3e3, 0.14e-3], [10e6, 0.14e-3]];\r\nexport const Schwellen_EMFV_Gliedmassen_B = [[0.01, 8], [0.1575, 8], [3e3, 0.42e-3], [10e6, 0.42e-3]];\r\n// 2. Spalte von A/m nach Tesla umrechnen\r\nexport const Schwellen_EMFV_Therm_B = [[100e3, 16.3], [10e6, 0.163], [400e6, 0.163], [2e9, 0.364], [3e11, 0.364]].map(function (value) { return [value[0], value[1] * 4.0 * Math.PI * Math.pow(10, -7)]; });\r\nexport const Schwellen_EMFV_Therm_B_Spitze = [[100e3, 24.45], [10e6, 0.163 * 32], [400e6, 0.163 * 32], [2e9, 0.364 * 32], [3e11, 0.364 * 32]].map(function (value) { return [value[0], value[1] * 4.0 * Math.PI * Math.pow(10, -7)]; });\r\n\r\n// Schwellen E\r\nexport const Schwellen_EMFV_UAS_E = [[0.01, 2.82e4], [25, 2.82e4], [3e3, 236], [10e6, 236]];\r\nexport const Schwellen_EMFV_OAS_E = [[0.01, 2.82e4], [50, 2.82e4], [1635, 862], [10e6, 862]];\r\nexport const Schwellen_EMFV_Therm_E = [[100e3, 614], [1e6, 614], [10e6, 61.4], [400e6, 61.4], [2e9, 137.3], [3e11, 137.3]];\r\nexport const Schwellen_EMFV_Therm_E_Spitze = [[100e3, 921], [1e6, 4261], [10e6, 61.4 * 32], [400e6, 61.4 * 32], [2e9, 137.3 * 32], [3e11, 137.3 * 32]];\r\n\r\n\r\nexport function updateEMFV_B_Regelwerk(this: EmfLitComponent) {\r\n let EMFV_B_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-LAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_UAS_B[0][0], y: Schwellen_EMFV_UAS_B[0][1] },\r\n { x: Schwellen_EMFV_UAS_B[1][0], y: Schwellen_EMFV_UAS_B[1][1] },\r\n { x: Schwellen_EMFV_UAS_B[2][0], y: Schwellen_EMFV_UAS_B[2][1] },\r\n { x: Schwellen_EMFV_UAS_B[3][0], y: Schwellen_EMFV_UAS_B[3][1] },\r\n { x: Schwellen_EMFV_UAS_B[4][0], y: Schwellen_EMFV_UAS_B[4][1] },\r\n { x: Schwellen_EMFV_UAS_B[5][0], y: Schwellen_EMFV_UAS_B[5][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(153, 204, 255, 1)', \r\n borderWidth: 2,\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(153, 204, 255, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_UAS_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EMFV_UAS_B_Freq,\r\n y: this.EMFV_UAS_B(this.EMFV_UAS_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(153, 204, 255, 1)',\r\n pointBackgroundColor: 'rgba(153, 204, 255, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-UAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_OAS_B[0][0], y: Schwellen_EMFV_OAS_B[0][1] },\r\n { x: Schwellen_EMFV_OAS_B[1][0], y: Schwellen_EMFV_OAS_B[1][1] },\r\n { x: Schwellen_EMFV_OAS_B[2][0], y: Schwellen_EMFV_OAS_B[2][1] },\r\n { x: Schwellen_EMFV_OAS_B[3][0], y: Schwellen_EMFV_OAS_B[3][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(0, 0, 255, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(0, 0, 255, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_OAS_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EMFV_OAS_B_Freq,\r\n y: this.EMFV_OAS_B(this.EMFV_OAS_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(0, 0, 255, 1)',\r\n pointBackgroundColor: 'rgba(0, 0, 255, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-ALL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_Gliedmassen_B[0][0], y: Schwellen_EMFV_Gliedmassen_B[0][1] },\r\n { x: Schwellen_EMFV_Gliedmassen_B[1][0], y: Schwellen_EMFV_Gliedmassen_B[1][1] },\r\n { x: Schwellen_EMFV_Gliedmassen_B[2][0], y: Schwellen_EMFV_Gliedmassen_B[2][1] },\r\n { x: Schwellen_EMFV_Gliedmassen_B[3][0], y: Schwellen_EMFV_Gliedmassen_B[3][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(0, 190, 190, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(0, 190, 190, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_Gliedmassen_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EMFV_Gliedmassen_B_Freq,\r\n y: this.EMFV_Gliedmassen_B(this.EMFV_Gliedmassen_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(0, 190, 190, 1)',\r\n pointBackgroundColor: 'rgba(0, 190, 190, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-THERM\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_Therm_B[0][0], y: Schwellen_EMFV_Therm_B[0][1] },\r\n { x: Schwellen_EMFV_Therm_B[1][0], y: Schwellen_EMFV_Therm_B[1][1] },\r\n { x: Schwellen_EMFV_Therm_B[2][0], y: Schwellen_EMFV_Therm_B[2][1] },\r\n { x: Schwellen_EMFV_Therm_B[3][0], y: Schwellen_EMFV_Therm_B[3][1] },\r\n { x: Schwellen_EMFV_Therm_B[4][0], y: Schwellen_EMFV_Therm_B[4][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_Therm_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EMFV_Therm_B_Freq,\r\n y: this.EMFV_Thermisch_B(this.EMFV_Therm_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-THERM-PEAK\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_Therm_B_Spitze[0][0], y: Schwellen_EMFV_Therm_B_Spitze[0][1] },\r\n { x: Schwellen_EMFV_Therm_B_Spitze[1][0], y: Schwellen_EMFV_Therm_B_Spitze[1][1] },\r\n { x: Schwellen_EMFV_Therm_B_Spitze[2][0], y: Schwellen_EMFV_Therm_B_Spitze[2][1] },\r\n { x: Schwellen_EMFV_Therm_B_Spitze[3][0], y: Schwellen_EMFV_Therm_B_Spitze[3][1] },\r\n { x: Schwellen_EMFV_Therm_B_Spitze[4][0], y: Schwellen_EMFV_Therm_B_Spitze[4][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointStyle: 'triangle',\r\n borderWidth: 2,\r\n borderDash: [10, 6],\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_Therm_B_Spitze_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EMFV_Therm_B_Spitze_Freq,\r\n y: this.EMFV_Thermisch_Spitze_B(this.EMFV_Therm_B_Spitze_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n // An das Chart Dataset hinten dran hängen\r\n this.BFeldChart.data.datasets = [\r\n ...this.BFeldChart.data.datasets,\r\n ...EMFV_B_data\r\n ];\r\n}\r\n\r\nexport function updateEMFV_E_Regelwerk(this: EmfLitComponent) {\r\n let EMFV_E_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-LAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_UAS_E[0][0], y: Schwellen_EMFV_UAS_E[0][1] },\r\n { x: Schwellen_EMFV_UAS_E[1][0], y: Schwellen_EMFV_UAS_E[1][1] },\r\n { x: Schwellen_EMFV_UAS_E[2][0], y: Schwellen_EMFV_UAS_E[2][1] },\r\n { x: Schwellen_EMFV_UAS_E[3][0], y: Schwellen_EMFV_UAS_E[3][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(153, 204, 255, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(153, 204, 255, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_UAS_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EMFV_UAS_E_Freq,\r\n y: this.EMFV_UAS_E(this.EMFV_UAS_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(153, 204, 255, 1)',\r\n pointBackgroundColor: 'rgba(153, 204, 255, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-UAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_OAS_E[0][0], y: Schwellen_EMFV_OAS_E[0][1] },\r\n { x: Schwellen_EMFV_OAS_E[1][0], y: Schwellen_EMFV_OAS_E[1][1] },\r\n { x: Schwellen_EMFV_OAS_E[2][0], y: Schwellen_EMFV_OAS_E[2][1] },\r\n { x: Schwellen_EMFV_OAS_E[3][0], y: Schwellen_EMFV_OAS_E[3][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(0, 0, 255, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'triangle',\r\n pointBackgroundColor: 'rgba(0, 0, 255, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_OAS_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EMFV_OAS_E_Freq,\r\n y: this.EMFV_OAS_E(this.EMFV_OAS_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(0, 0, 255, 1)',\r\n pointBackgroundColor: 'rgba(0, 0, 255, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-THERM\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_Therm_E[0][0], y: Schwellen_EMFV_Therm_E[0][1] },\r\n { x: Schwellen_EMFV_Therm_E[1][0], y: Schwellen_EMFV_Therm_E[1][1] },\r\n { x: Schwellen_EMFV_Therm_E[2][0], y: Schwellen_EMFV_Therm_E[2][1] },\r\n { x: Schwellen_EMFV_Therm_E[3][0], y: Schwellen_EMFV_Therm_E[3][1] },\r\n { x: Schwellen_EMFV_Therm_E[4][0], y: Schwellen_EMFV_Therm_E[4][1] },\r\n { x: Schwellen_EMFV_Therm_E[5][0], y: Schwellen_EMFV_Therm_E[5][1] },\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_Therm_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EMFV_Therm_E_Freq,\r\n y: this.EMFV_Thermisch_E(this.EMFV_Therm_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EMFV-THERM-PEAK\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EMFV_Therm_E_Spitze[0][0], y: Schwellen_EMFV_Therm_E_Spitze[0][1] },\r\n { x: Schwellen_EMFV_Therm_E_Spitze[1][0], y: Schwellen_EMFV_Therm_E_Spitze[1][1] },\r\n { x: Schwellen_EMFV_Therm_E_Spitze[2][0], y: Schwellen_EMFV_Therm_E_Spitze[2][1] },\r\n { x: Schwellen_EMFV_Therm_E_Spitze[3][0], y: Schwellen_EMFV_Therm_E_Spitze[3][1] },\r\n { x: Schwellen_EMFV_Therm_E_Spitze[4][0], y: Schwellen_EMFV_Therm_E_Spitze[4][1] },\r\n { x: Schwellen_EMFV_Therm_E_Spitze[5][0], y: Schwellen_EMFV_Therm_E_Spitze[5][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointStyle: 'triangle',\r\n borderWidth: 2,\r\n borderDash: [10, 6],\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EMFV_Therm_E_Spitze_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EMFV_Therm_E_Spitze_Freq,\r\n y: this.EMFV_Thermisch_Spitze_E(this.EMFV_Therm_E_Spitze_Freq)\r\n }\r\n ],\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(255, 0, 255, 1)',\r\n pointBackgroundColor: 'rgba(255, 0, 255, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n // An das Chart Dataset hinten dran hängen\r\n this.EFeldChart.data.datasets = [\r\n ...this.EFeldChart.data.datasets,\r\n ...EMFV_E_data\r\n ];\r\n}\r\n\r\nexport function updateEMFV_B_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // EMFV UAS\r\n // Range Check\r\n if (this.EMFV_UAS_B_Freq < 0 || this.EMFV_UAS_B_Freq > 1e7) {\r\n this.BFeldChart.data.datasets[index].data = [];\r\n this.BFeldChart.data.datasets[index].label = '';\r\n } else { \r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_UAS_B_Freq,\r\n y: (this.EMFV_UAS_B(this.EMFV_UAS_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n }\r\n else {\r\n data = [\r\n {\r\n x: this.EMFV_UAS_B_Freq,\r\n y: (this.EMFV_UAS_B(this.EMFV_UAS_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index].data = data;\r\n this.BFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.EMFV_UAS_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // EMFV OAS\r\n // Range Check\r\n if (this.EMFV_OAS_B_Freq < 0 || this.EMFV_OAS_B_Freq > 1e7) {\r\n this.BFeldChart.data.datasets[index + 2].data = [];\r\n this.BFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_OAS_B_Freq,\r\n y: (this.EMFV_OAS_B(this.EMFV_OAS_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_OAS_B_Freq,\r\n y: (this.EMFV_OAS_B(this.EMFV_OAS_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 2].data = data;\r\n this.BFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.EMFV_OAS_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // EMFV Gliedmassen\r\n // Range Check\r\n if (this.EMFV_Gliedmassen_B_Freq < 0 || this.EMFV_Gliedmassen_B_Freq > 1e7) {\r\n this.BFeldChart.data.datasets[index + 4].data = [];\r\n this.BFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_Gliedmassen_B_Freq,\r\n y: (this.EMFV_Gliedmassen_B(this.EMFV_Gliedmassen_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_Gliedmassen_B_Freq,\r\n y: (this.EMFV_Gliedmassen_B(this.EMFV_Gliedmassen_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 4].data = data;\r\n this.BFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.EMFV_Gliedmassen_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // EMFV Thermische Auslöseschwelle\r\n // Range Check\r\n if (this.EMFV_Therm_B_Freq < 100e3 || this.EMFV_Therm_B_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index + 6].data = [];\r\n this.BFeldChart.data.datasets[index + 6].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_B_Freq,\r\n y: (this.EMFV_Thermisch_B(this.EMFV_Therm_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_B_Freq,\r\n y: (this.EMFV_Thermisch_B(this.EMFV_Therm_B_Freq) / 1000)\r\n }\r\n ]; \r\n }\r\n this.BFeldChart.data.datasets[index + 6].data = data;\r\n this.BFeldChart.data.datasets[index + 6].label =\r\n 'Wert bei ' + this.EMFV_Therm_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // EMFV Thermische Wirkungen: Spitzenwertbegrenzung\r\n // Range Check\r\n if (this.EMFV_Therm_B_Spitze_Freq < 100e3 || this.EMFV_Therm_B_Spitze_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index + 8].data = [];\r\n this.BFeldChart.data.datasets[index + 8].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_B_Spitze_Freq,\r\n y: (this.EMFV_Thermisch_Spitze_B(this.EMFV_Therm_B_Spitze_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_B_Spitze_Freq,\r\n y: (this.EMFV_Thermisch_Spitze_B(this.EMFV_Therm_B_Spitze_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 8].data = data;\r\n this.BFeldChart.data.datasets[index + 8].label =\r\n 'Wert bei ' + this.EMFV_Therm_B_Spitze_Freq + ' Hz (in T)';\r\n }\r\n}\r\n\r\nexport function updateEMFV_E_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // Range Check\r\n if (this.EMFV_UAS_E_Freq < 0 || this.EMFV_UAS_E_Freq > 1e7) {\r\n this.EFeldChart.data.datasets[index].data = [];\r\n this.EFeldChart.data.datasets[index].label = '';\r\n } else {\r\n // EMFV UAS\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_UAS_E_Freq,\r\n y: this.EMFV_UAS_E(this.EMFV_UAS_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_UAS_E_Freq,\r\n y: this.EMFV_UAS_E(this.EMFV_UAS_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index].data = data;\r\n this.EFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.EMFV_UAS_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // EMFV OAS\r\n // Range Check\r\n if (this.EMFV_OAS_E_Freq < 0 || this.EMFV_OAS_E_Freq > 1e7) {\r\n this.EFeldChart.data.datasets[index + 2].data = [];\r\n this.EFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_OAS_E_Freq,\r\n y: this.EMFV_OAS_E(this.EMFV_OAS_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_OAS_E_Freq,\r\n y: this.EMFV_OAS_E(this.EMFV_OAS_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 2].data = data;\r\n this.EFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.EMFV_OAS_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // EMFV Thermische Auslöseschwelle\r\n // Range Check\r\n if (this.EMFV_Therm_E_Freq < 100e3 || this.EMFV_Therm_E_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index + 4].data = [];\r\n this.EFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_E_Freq,\r\n y: this.EMFV_Thermisch_E(this.EMFV_Therm_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_E_Freq,\r\n y: this.EMFV_Thermisch_E(this.EMFV_Therm_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 4].data = data;\r\n this.EFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.EMFV_Therm_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // EMFV Thermische Wirkungen: Spitzenwertbegrenzung\r\n // Range Check\r\n if (this.EMFV_Therm_E_Spitze_Freq < 100e3 || this.EMFV_Therm_E_Spitze_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index + 6].data = [];\r\n this.EFeldChart.data.datasets[index + 6].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_E_Spitze_Freq,\r\n y: this.EMFV_Thermisch_Spitze_E(this.EMFV_Therm_E_Spitze_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EMFV_Therm_E_Spitze_Freq,\r\n y: this.EMFV_Thermisch_Spitze_E(this.EMFV_Therm_E_Spitze_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 6].data = data;\r\n this.EFeldChart.data.datasets[index + 6].label =\r\n 'Wert bei ' + this.EMFV_Therm_E_Spitze_Freq + ' Hz (in V/m)';\r\n }\r\n}\r\n\r\nexport function EMFV_Gliedmassen_B(Frequenz: number) {\r\n //NaN für <0 und größer 10 MHz\r\n if (Frequenz < 0 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let GAS: number; // Auslöseschwelle für Gliedmassen\r\n GAS = 8000; //in mT\r\n if (Frequenz >= 0.1575) {\r\n if (Frequenz < 3000) {\r\n GAS = 1260 / Frequenz;\r\n } else {\r\n GAS = 0.42;\r\n }\r\n }\r\n\r\n return GAS;\r\n}\r\n\r\nexport function EMFV_OAS_B(Frequenz: number) {\r\n //NaN für <0 und größer 10 MHz\r\n if (Frequenz < 0 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let OAS: number; // Obere Auslöseschwelle\r\n OAS = 2000; //in mT\r\n if (Frequenz >= 0.21) {\r\n if (Frequenz < 3000) {\r\n OAS = 420 / Frequenz;\r\n } else {\r\n OAS = 0.14;\r\n }\r\n }\r\n\r\n return OAS;\r\n}\r\n\r\nexport function EMFV_UAS_B(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let UAS: number; // Untere Auslöseschwelle\r\n UAS = 2000; //in mT\r\n if (Frequenz >= 0.0175) {\r\n if (Frequenz < 25) {\r\n UAS = 35 / Frequenz;\r\n } else {\r\n if (Frequenz < 300) {\r\n UAS = 1.4;\r\n } else {\r\n if (Frequenz < 3000) {\r\n UAS = 420 / Frequenz;\r\n } else {\r\n UAS = 0.14;\r\n }\r\n }\r\n }\r\n }\r\n return UAS;\r\n}\r\n\r\nexport function EMFV_Thermisch_B(Frequenz: number) {\r\n if (Frequenz < 100e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Auslöseschwelle für thermische Wirkungen\r\n Schwelle = 16.3; //in A/m RMS\r\n\r\n if (Frequenz < 10e6) {\r\n Schwelle = 1.63e6 / Frequenz;\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 0.163;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 8.14e-6 * Math.sqrt(Frequenz);\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 0.364;\r\n }\r\n }\r\n }\r\n }\r\n\r\n //A/m -> mT\r\n Schwelle = Schwelle * (4 * Math.PI * 1e-4);\r\n return Schwelle;\r\n}\r\n\r\nexport function EMFV_Thermisch_Spitze_B(Frequenz: number) {\r\n if (Frequenz < 100e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Spitzenwertbegrenzung für thermische Wirkungen\r\n Schwelle = 24.45001; // in A/m RMS; ist 24.45 - aufgrund von Rundungsfehlern kommt sonst aber 24.44 raus \r\n\r\n if (Frequenz > 1e5) {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 1156.6 * Math.pow(Frequenz, -0.335);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 0.163 * 32;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 8.14e-6 * Math.sqrt(Frequenz) * 32;\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 0.364 * 32;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n //A/m -> mT\r\n Schwelle = Schwelle * (4 * Math.PI * 1e-4);\r\n return Schwelle;\r\n}\r\n\r\nexport function EMFV_OAS_E(Frequenz: number) {\r\n //NaN für <0 und größer 10 MHz\r\n if (Frequenz < 0 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let OAS: number; // Obere Auslöseschwelle\r\n OAS = 2.82e4; //in V/m\r\n if (Frequenz >= 50) {\r\n if (Frequenz < 1635) {\r\n OAS = 1.41e6 / Frequenz;\r\n } else {\r\n OAS = 862;\r\n }\r\n }\r\n\r\n return OAS;\r\n}\r\n\r\nexport function EMFV_UAS_E(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let UAS: number; // Untere Auslöseschwelle\r\n UAS = 2.82e4; //in V/m\r\n if (Frequenz >= 25) {\r\n if (Frequenz < 3000) {\r\n UAS = 7.07e5 / Frequenz;\r\n } else {\r\n UAS = 236;\r\n }\r\n }\r\n return UAS;\r\n}\r\n\r\nexport function EMFV_Thermisch_E(Frequenz: number) {\r\n if (Frequenz < 100e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Auslöseschwelle für thermische Wirkungen\r\n Schwelle = 614; //in V/m RMS\r\n\r\n if (Frequenz >= 1e6) {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 614e6 / Frequenz;\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 61.4;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 3.07e-3 * Math.sqrt(Frequenz);\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 137.3;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function EMFV_Thermisch_Spitze_E(Frequenz: number) {\r\n if (Frequenz < 100e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Spitzenwertbegrenzung für thermische Wirkungen\r\n Schwelle = 921; //in V/m RMS\r\n\r\n if (Frequenz > 1e5) {\r\n if (Frequenz < 1e6) {\r\n Schwelle = 0.436 * Math.pow(Frequenz, 0.665);\r\n } else {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 0.436e6 * Math.pow(Frequenz, -0.335);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 61.4 * 32;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 3.07e-3 * Math.sqrt(Frequenz) * 32;\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 137.3 * 32;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n","import { EmfLitComponent } from \"./emf-lit.component\";\r\n\r\nexport const Schwellen_BImSchV_NF_B = [[1, 40], [8, 0.625], [25, 0.2], [49, 0.2], [50, 0.1], [51, 0.2], [0.4e3, 0.2], [3e3, 0.027], [10e6, 0.027]].map(function (value) { return [value[0], value[1] / 1000]; });\r\nexport const Schwellen_BImSchV_HF_B = [[0.1e6, 7.3], [10e6, 0.073], [400e6, 0.073], [2e9, 0.16], [3e11, 0.16]].map(function (value) { return [value[0], value[1] * 4.0 * Math.PI * Math.pow(10, -7)]; });\r\nexport const Schwellen_BImSchV_Spitze_B = [[9e3, 0.027e-3*1.5 / 4.0 / Math.PI / Math.pow(10, -7)], [100e3, 0.027e-3*1.5 / 4.0 / Math.PI / Math.pow(10, -7)],[100.001e3, 7.3*1.502], [10e6, 0.073*31.97], [10.000001e6, 0.073*32], [400e6, 0.073*32], [2e9, 0.16*32], [3e11, 0.16*32]].map(function (value) { return [value[0], value[1] * 4.0 * Math.PI * Math.pow(10, -7)]; });\r\n\r\nexport const Schwellen_BImSchV_NF_E = [[1, 5000], [50, 5000], [3e3, 83], [10e6, 83]];\r\nexport const Schwellen_BImSchV_HF_E = [[100e3, 87], [1e6, 87], [10e6, 28], [400e6, 28], [2e9, 61], [300e9, 61]];\r\nexport const Schwellen_BImSchV_Spitze_E = [[9e3, 83*1.5], [100e3, 83*1.5], [100.001e3, 87*1.502], [1e6, 87*6.93], [10e6, 28*31.97], [10.000001e6, 28*32], [400e6, 28*32], [2e9, 61*32], [300e9, 61*32]];\r\n\r\nexport function updateBImSchV_B_Regelwerk(this: EmfLitComponent) {\r\n let BImSchV_B_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.BIMSCHV-LF\"), //NF\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_BImSchV_NF_B[0][0], y: Schwellen_BImSchV_NF_B[0][1] },\r\n { x: Schwellen_BImSchV_NF_B[1][0], y: Schwellen_BImSchV_NF_B[1][1] },\r\n { x: Schwellen_BImSchV_NF_B[2][0], y: Schwellen_BImSchV_NF_B[2][1] },\r\n { x: Schwellen_BImSchV_NF_B[3][0], y: Schwellen_BImSchV_NF_B[3][1] },\r\n { x: Schwellen_BImSchV_NF_B[4][0], y: Schwellen_BImSchV_NF_B[4][1] },\r\n { x: Schwellen_BImSchV_NF_B[5][0], y: Schwellen_BImSchV_NF_B[5][1] },\r\n { x: Schwellen_BImSchV_NF_B[6][0], y: Schwellen_BImSchV_NF_B[6][1] },\r\n { x: Schwellen_BImSchV_NF_B[7][0], y: Schwellen_BImSchV_NF_B[7][1] },\r\n { x: Schwellen_BImSchV_NF_B[8][0], y: Schwellen_BImSchV_NF_B[8][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(126, 47, 142, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(126, 47, 142, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.BImSchV_NF_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.BImSchV_NF_B_Freq,\r\n y: this.BImSchV_B_NF(this.BImSchV_NF_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(126, 47, 142, 1)',\r\n pointBackgroundColor: 'rgba(126, 47, 142, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.BIMSCHV-HF\"), //HF\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_BImSchV_HF_B[0][0], y: Schwellen_BImSchV_HF_B[0][1] },\r\n { x: Schwellen_BImSchV_HF_B[1][0], y: Schwellen_BImSchV_HF_B[1][1] },\r\n { x: Schwellen_BImSchV_HF_B[2][0], y: Schwellen_BImSchV_HF_B[2][1] },\r\n { x: Schwellen_BImSchV_HF_B[3][0], y: Schwellen_BImSchV_HF_B[3][1] },\r\n { x: Schwellen_BImSchV_HF_B[4][0], y: Schwellen_BImSchV_HF_B[4][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.BImSchV_HF_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.BImSchV_HF_B_Freq,\r\n y: this.BImSchV_B_HF(this.BImSchV_HF_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.BIMSCHV-PEAK\"), //Spitze\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_BImSchV_Spitze_B[0][0], y: Schwellen_BImSchV_Spitze_B[0][1] },\r\n { x: Schwellen_BImSchV_Spitze_B[1][0], y: Schwellen_BImSchV_Spitze_B[1][1] },\r\n { x: Schwellen_BImSchV_Spitze_B[2][0], y: Schwellen_BImSchV_Spitze_B[2][1] },\r\n { x: Schwellen_BImSchV_Spitze_B[3][0], y: Schwellen_BImSchV_Spitze_B[3][1] },\r\n { x: Schwellen_BImSchV_Spitze_B[4][0], y: Schwellen_BImSchV_Spitze_B[4][1] },\r\n { x: Schwellen_BImSchV_Spitze_B[5][0], y: Schwellen_BImSchV_Spitze_B[5][1] },\r\n { x: Schwellen_BImSchV_Spitze_B[6][0], y: Schwellen_BImSchV_Spitze_B[6][1] },\r\n { x: Schwellen_BImSchV_Spitze_B[7][0], y: Schwellen_BImSchV_Spitze_B[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n pointStyle: 'triangle',\r\n borderDash: [10, 6],\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.BImSchV_Spitze_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.BImSchV_Spitze_B_Freq,\r\n y: this.BImSchV_B_Spitze(this.BImSchV_Spitze_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n } \r\n ];\r\n\r\n this.BFeldChart.data.datasets = [\r\n ...this.BFeldChart.data.datasets,\r\n ...BImSchV_B_data\r\n ];\r\n}\r\n\r\nexport function updateBImSchV_E_Regelwerk(this: EmfLitComponent) {\r\n let BImSchV_E_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.BIMSCHV-LF\"), // NF\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_BImSchV_NF_E[0][0], y: Schwellen_BImSchV_NF_E[0][1] },\r\n { x: Schwellen_BImSchV_NF_E[1][0], y: Schwellen_BImSchV_NF_E[1][1] },\r\n { x: Schwellen_BImSchV_NF_E[2][0], y: Schwellen_BImSchV_NF_E[2][1] },\r\n { x: Schwellen_BImSchV_NF_E[3][0], y: Schwellen_BImSchV_NF_E[3][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(126, 47, 142, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(126, 47, 142, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.BImSchV_NF_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.BImSchV_NF_E_Freq,\r\n y: this.BImSchV_E_NF(this.BImSchV_NF_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(126, 47, 142, 1)',\r\n pointBackgroundColor: 'rgba(126, 47, 142, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.BIMSCHV-HF\"), //HF\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_BImSchV_HF_E[0][0], y: Schwellen_BImSchV_HF_E[0][1] },\r\n { x: Schwellen_BImSchV_HF_E[1][0], y: Schwellen_BImSchV_HF_E[1][1] },\r\n { x: Schwellen_BImSchV_HF_E[2][0], y: Schwellen_BImSchV_HF_E[2][1] },\r\n { x: Schwellen_BImSchV_HF_E[3][0], y: Schwellen_BImSchV_HF_E[3][1] },\r\n { x: Schwellen_BImSchV_HF_E[4][0], y: Schwellen_BImSchV_HF_E[4][1] },\r\n { x: Schwellen_BImSchV_HF_E[5][0], y: Schwellen_BImSchV_HF_E[5][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.BImSchV_HF_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.BImSchV_HF_E_Freq,\r\n y: this.BImSchV_E_HF(this.BImSchV_HF_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.BIMSCHV-PEAK\"), //Spitze\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_BImSchV_Spitze_E[0][0], y: Schwellen_BImSchV_Spitze_E[0][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[1][0], y: Schwellen_BImSchV_Spitze_E[1][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[2][0], y: Schwellen_BImSchV_Spitze_E[2][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[3][0], y: Schwellen_BImSchV_Spitze_E[3][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[4][0], y: Schwellen_BImSchV_Spitze_E[4][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[5][0], y: Schwellen_BImSchV_Spitze_E[5][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[6][0], y: Schwellen_BImSchV_Spitze_E[6][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[7][0], y: Schwellen_BImSchV_Spitze_E[7][1] },\r\n { x: Schwellen_BImSchV_Spitze_E[8][0], y: Schwellen_BImSchV_Spitze_E[8][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n pointStyle: 'triangle',\r\n borderDash: [10, 6],\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.BImSchV_Spitze_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.BImSchV_Spitze_E_Freq,\r\n y: this.BImSchV_E_Spitze(this.BImSchV_Spitze_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(126, 98, 244, 1)',\r\n pointBackgroundColor: 'rgba(126, 98, 244, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n } \r\n ];\r\n\r\n this.EFeldChart.data.datasets = [\r\n ...this.EFeldChart.data.datasets,\r\n ...BImSchV_E_data\r\n ];\r\n}\r\n\r\nexport function updateBImSchV_B_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // BImSchV - B-NF\r\n // Range Check\r\n if ((this.BImSchV_NF_B_Freq < 0 || this.BImSchV_NF_B_Freq > 10e6) || (this.BImSchV_NF_B_Freq > 0 && this.BImSchV_NF_B_Freq < 1)) {\r\n this.BFeldChart.data.datasets[index].data = [];\r\n this.BFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.BImSchV_NF_B_Freq,\r\n y: (this.BImSchV_B_NF(this.BImSchV_NF_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.BImSchV_NF_B_Freq,\r\n y: (this.BImSchV_B_NF(this.BImSchV_NF_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index].data = data;\r\n this.BFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.BImSchV_NF_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // BImSchV - B-HF\r\n // Range Check\r\n if (this.BImSchV_HF_B_Freq < 100e3 || this.BImSchV_HF_B_Freq > 3e11) {\r\n this.BFeldChart.data.datasets[index + 2].data = [];\r\n this.BFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.BImSchV_HF_B_Freq,\r\n y: (this.BImSchV_B_HF(this.BImSchV_HF_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.BImSchV_HF_B_Freq,\r\n y: (this.BImSchV_B_HF(this.BImSchV_HF_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 2].data = data;\r\n this.BFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.BImSchV_HF_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // BImSchV - B-Spitze\r\n // Range Check\r\n if (this.BImSchV_Spitze_B_Freq < 9e3 || this.BImSchV_Spitze_B_Freq > 3e11) {\r\n this.BFeldChart.data.datasets[index + 4].data = [];\r\n this.BFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.BImSchV_Spitze_B_Freq,\r\n y: (this.BImSchV_B_Spitze(this.BImSchV_Spitze_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.BImSchV_Spitze_B_Freq,\r\n y: (this.BImSchV_B_Spitze(this.BImSchV_Spitze_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 4].data = data;\r\n this.BFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.BImSchV_Spitze_B_Freq + ' Hz (in T)';\r\n }\r\n}\r\n\r\nexport function updateBImSchV_E_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // BImSchV - E-NF\r\n // Range Check\r\n if (this.BImSchV_NF_E_Freq < 1 || this.BImSchV_NF_E_Freq > 10e6) {\r\n this.EFeldChart.data.datasets[index].data = [];\r\n this.EFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.BImSchV_NF_E_Freq,\r\n y: this.BImSchV_E_NF(this.BImSchV_NF_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.BImSchV_NF_E_Freq,\r\n y: this.BImSchV_E_NF(this.BImSchV_NF_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index].data = data;\r\n this.EFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.BImSchV_NF_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // BImSchV - E-HF\r\n // Range Check\r\n if (this.BImSchV_HF_E_Freq < 100e3 || this.BImSchV_HF_E_Freq > 3e11) {\r\n this.EFeldChart.data.datasets[index + 2].data = [];\r\n this.EFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.BImSchV_HF_E_Freq,\r\n y: this.BImSchV_E_HF(this.BImSchV_HF_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.BImSchV_HF_E_Freq,\r\n y: this.BImSchV_E_HF(this.BImSchV_HF_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 2].data = data;\r\n this.EFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.BImSchV_HF_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // BImSchV - E-Spitze\r\n // Range Check\r\n if (this.BImSchV_Spitze_E_Freq < 9e3 || this.BImSchV_Spitze_E_Freq > 3e11) {\r\n this.EFeldChart.data.datasets[index + 4].data = [];\r\n this.EFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.BImSchV_Spitze_E_Freq,\r\n y: this.BImSchV_E_Spitze(this.BImSchV_Spitze_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.BImSchV_Spitze_E_Freq,\r\n y: this.BImSchV_E_Spitze(this.BImSchV_Spitze_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 4].data = data;\r\n this.EFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.BImSchV_Spitze_E_Freq + ' Hz (in V/m)';\r\n }\r\n}\r\n\r\nexport function BImSchV_B_NF(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // BImSchV Grenzwerte - B-Field\r\n Schwelle = NaN; //in mT, NaN between 0 and 1 Hz\r\n\r\n if (Frequenz == 0) {\r\n Schwelle = 0.5; // in mT for 0 Hz\r\n return Schwelle;\r\n }\r\n\r\n if (Frequenz == 50) {\r\n Schwelle = 0.1; // in mT special case for 50 Hz; see regulation text §3(1,2)\r\n return Schwelle;\r\n }\r\n\r\n if (Frequenz >= 1) {\r\n if (Frequenz < 8) {\r\n Schwelle = 40 / Math.pow(Frequenz, 2);\r\n } else {\r\n if (Frequenz < 25) {\r\n Schwelle = 5 / Frequenz;\r\n } else {\r\n if (Frequenz < 400) {\r\n Schwelle = 0.2;\r\n } else {\r\n if (Frequenz <= 3e3) {\r\n Schwelle = 80 / Frequenz;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = 27e-3;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function BImSchV_B_HF(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // BImSchV Grenzwerte - B-Field\r\n Schwelle = NaN; //in mT, NaN up to 100 kHz\r\n\r\n if (Frequenz >= 100e3) {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 0.73 / (Frequenz / 1e6); // in A/m\r\n } else {\r\n if (Frequenz <= 400e6) {\r\n Schwelle = 0.073;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 0.0037 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n if (Frequenz <= 300e9) {\r\n Schwelle = 0.16;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return (Schwelle * (4 * Math.PI * 1e-4)); // convert to mT\r\n}\r\n\r\nexport function BImSchV_E_NF(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // BImSchV Grenzwerte - E-Field\r\n Schwelle = NaN; //in V/m, NaN for f < 1 Hz\r\n\r\n if (Frequenz >= 1) {\r\n if (Frequenz < 50) {\r\n Schwelle = 5000;\r\n } else {\r\n if (Frequenz < 3e3) {\r\n Schwelle = 250e3 / Frequenz;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = 83;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function BImSchV_E_HF(Frequenz: number) {\r\n if (Frequenz < 0 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // BImSchV Grenzwerte - E-Field\r\n Schwelle = NaN; //in V/m, NaN up to 100 kHz\r\n\r\n if (Frequenz >= 100e3) {\r\n if (Frequenz < 1e6) {\r\n Schwelle = 87;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = 87 / Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 28;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 1.375 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n if (Frequenz <= 300e9) {\r\n Schwelle = 61;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function BImSchV_E_Spitze(Frequenz: number) {\r\n if (Frequenz < 9e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // BImSchV Grenzwerte - E-Field (Spitzenwert)\r\n Schwelle = NaN; //in V/m, NaN up to 9 kHz\r\n\r\n if (Frequenz >= 9e3) {\r\n if (Frequenz <= 100e3) {\r\n Schwelle = BImSchV_E_NF(Frequenz) * 1.5;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = BImSchV_E_HF(Frequenz) * 6.93 * Math.pow(Frequenz / 1e6, 0.664);\r\n } else {\r\n if (Frequenz <= 300e9) {\r\n Schwelle = BImSchV_E_HF(Frequenz) * 32;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function BImSchV_B_Spitze(Frequenz: number) {\r\n if (Frequenz < 9e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // BImSchV Grenzwerte - B-Field (Spitzenwert)\r\n Schwelle = NaN; //in mT, NaN up to 9 kHz\r\n\r\n if (Frequenz >= 9e3) {\r\n if (Frequenz <= 100e3) {\r\n Schwelle = BImSchV_B_NF(Frequenz) * 1.5;\r\n } else {\r\n if (Frequenz <= 10e6) {\r\n Schwelle = BImSchV_B_HF(Frequenz) * 6.93 * Math.pow(Frequenz / 1e6, 0.664);\r\n } else {\r\n if (Frequenz <= 300e9) {\r\n Schwelle = BImSchV_B_HF(Frequenz) * 32;\r\n } else {\r\n Schwelle = NaN;\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}","import { EmfLitComponent } from \"./emf-lit.component\";\r\n\r\nexport const Schwellen_DGUVV15_Expo2_B = [[0.01, 21.22e-3], [1, 21.22e-3], [1e3, 21.22e-6], [140e3, 21.22e-6], [30e6, 0.073 * 4e-7 * Math.PI], [400e6, 0.073 * 4e-7 * Math.PI], [2e9, 0.163 * 4e-7 * Math.PI], [3e11, 0.163 * 4e-7 * Math.PI]];\r\nexport const Schwellen_DGUVV15_Expo1_B = [[0.01, 67.9e-3], [1, 67.9e-3], [1e3, 67.9e-6], [91e3, 67.9e-6], [30e6, 0.163 * 4e-7 * Math.PI], [400e6, 0.163 * 4e-7 * Math.PI], [2e9, 0.364 * 4e-7 * Math.PI], [3e11, 0.364 * 4e-7 * Math.PI]];\r\nexport const Schwellen_DGUVV15_ExpoEr_B = [[0.01, 127.3e-3], [1, 127.3e-3], [1e3, 127.3e-6], [48.5e3, 127.3e-6], [91e3, (6176e-6) / 91]];\r\nexport const Schwellen_DGUVV15_ExpoEr_Spitze_B = [[91e3, 10 / 0.091 * 4e-7 * Math.PI], [200e3, 50 * 4e-7 * Math.PI], [3e6, 50 * 4e-7 * Math.PI], [30e6, 5 * 4e-7 * Math.PI], [400e6, 5 * 4e-7 * Math.PI], [2e9, 11.2 * 4e-7 * Math.PI], [300e9, 11.2 * 4e-7 * Math.PI]];\r\n\r\nexport const Schwellen_DGUVV15_Expo2_E = [[0.01, 20e3], [16.67, 20e3], [1e3, 333.3], [826e3, 333.3], [10e6, 27.5], [400e6, 27.5], [2e9, 61.5], [3e11, 61.5]];\r\nexport const Schwellen_DGUVV15_Expo1_E = [[0.01, 30e3], [35.53, 30e3], [1e3, 1066], [576e3, 1066], [10e6, 61.4], [400e6, 61.4], [2e9, 137.3], [3e11, 137.3]];\r\nexport const Schwellen_DGUVV15_ExpoEr_E = [[0.01, 30e3], [66.67, 30e3], [1e3, 2000], [48.5e3, 2000], [91e3, 97e3 / 91]];\r\nexport const Schwellen_DGUVV15_ExpoEr_Spitze_E = [[91e3, 2222], [100e3, 2222], [0.3e6, 6667], [3e6, 6667], [10e6, 2000], [400e6, 2000], [2e9, 4472], [3e11, 4472]];\r\n\r\nexport function updateDGUVV15_B_Regelwerk(this: EmfLitComponent) {\r\n let DGUVV15_B_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-EXPO2\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_Expo2_B[0][0], y: Schwellen_DGUVV15_Expo2_B[0][1] },\r\n { x: Schwellen_DGUVV15_Expo2_B[1][0], y: Schwellen_DGUVV15_Expo2_B[1][1] },\r\n { x: Schwellen_DGUVV15_Expo2_B[2][0], y: Schwellen_DGUVV15_Expo2_B[2][1] },\r\n { x: Schwellen_DGUVV15_Expo2_B[3][0], y: Schwellen_DGUVV15_Expo2_B[3][1] },\r\n { x: Schwellen_DGUVV15_Expo2_B[4][0], y: Schwellen_DGUVV15_Expo2_B[4][1] },\r\n { x: Schwellen_DGUVV15_Expo2_B[5][0], y: Schwellen_DGUVV15_Expo2_B[5][1] },\r\n { x: Schwellen_DGUVV15_Expo2_B[6][0], y: Schwellen_DGUVV15_Expo2_B[6][1] },\r\n { x: Schwellen_DGUVV15_Expo2_B[7][0], y: Schwellen_DGUVV15_Expo2_B[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(0, 127, 0, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(0, 127, 0, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_Expo2_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.DGUVV15_Expo2_B_Freq,\r\n y: this.V15_Expo2_B(this.DGUVV15_Expo2_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(0, 127, 0, 1)',\r\n pointBackgroundColor: 'rgba(0, 127, 0, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-EXPO1\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_Expo1_B[0][0], y: Schwellen_DGUVV15_Expo1_B[0][1] },\r\n { x: Schwellen_DGUVV15_Expo1_B[1][0], y: Schwellen_DGUVV15_Expo1_B[1][1] },\r\n { x: Schwellen_DGUVV15_Expo1_B[2][0], y: Schwellen_DGUVV15_Expo1_B[2][1] },\r\n { x: Schwellen_DGUVV15_Expo1_B[3][0], y: Schwellen_DGUVV15_Expo1_B[3][1] },\r\n { x: Schwellen_DGUVV15_Expo1_B[4][0], y: Schwellen_DGUVV15_Expo1_B[4][1] },\r\n { x: Schwellen_DGUVV15_Expo1_B[5][0], y: Schwellen_DGUVV15_Expo1_B[5][1] },\r\n { x: Schwellen_DGUVV15_Expo1_B[6][0], y: Schwellen_DGUVV15_Expo1_B[6][1] },\r\n { x: Schwellen_DGUVV15_Expo1_B[7][0], y: Schwellen_DGUVV15_Expo1_B[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(0, 0, 204, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(0, 0, 204, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_Expo1_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.DGUVV15_Expo1_B_Freq,\r\n y: this.V15_Expo1_B(this.DGUVV15_Expo1_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(0, 0, 204, 1)',\r\n pointBackgroundColor: 'rgba(0, 0, 204, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-HIGH\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_ExpoEr_B[0][0], y: Schwellen_DGUVV15_ExpoEr_B[0][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_B[1][0], y: Schwellen_DGUVV15_ExpoEr_B[1][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_B[2][0], y: Schwellen_DGUVV15_ExpoEr_B[2][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_B[3][0], y: Schwellen_DGUVV15_ExpoEr_B[3][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_B[4][0], y: Schwellen_DGUVV15_ExpoEr_B[4][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_ExpoEr_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.DGUVV15_ExpoEr_B_Freq,\r\n y: this.V15_ExpoEr_B(this.DGUVV15_ExpoEr_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-PEAK\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_B[0][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_B[0][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_B[1][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_B[1][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_B[2][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_B[2][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_B[3][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_B[3][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_B[4][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_B[4][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_B[5][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_B[5][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_B[6][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_B[6][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n pointStyle: 'triangle',\r\n borderDash: [10, 6],\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_ExpoEr_Spitze_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.DGUVV15_ExpoEr_Spitze_B_Freq,\r\n y: this.V15_ExpoEr_Spitze_B(this.DGUVV15_ExpoEr_Spitze_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n this.BFeldChart.data.datasets = [\r\n ...this.BFeldChart.data.datasets,\r\n ...DGUVV15_B_data\r\n ];\r\n}\r\n\r\nexport function updateDGUVV15_E_Regelwerk(this: EmfLitComponent) {\r\n let BImSchV_E_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-EXPO2\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_Expo2_E[0][0], y: Schwellen_DGUVV15_Expo2_E[0][1] },\r\n { x: Schwellen_DGUVV15_Expo2_E[1][0], y: Schwellen_DGUVV15_Expo2_E[1][1] },\r\n { x: Schwellen_DGUVV15_Expo2_E[2][0], y: Schwellen_DGUVV15_Expo2_E[2][1] },\r\n { x: Schwellen_DGUVV15_Expo2_E[3][0], y: Schwellen_DGUVV15_Expo2_E[3][1] },\r\n { x: Schwellen_DGUVV15_Expo2_E[4][0], y: Schwellen_DGUVV15_Expo2_E[4][1] },\r\n { x: Schwellen_DGUVV15_Expo2_E[5][0], y: Schwellen_DGUVV15_Expo2_E[5][1] },\r\n { x: Schwellen_DGUVV15_Expo2_E[6][0], y: Schwellen_DGUVV15_Expo2_E[6][1] },\r\n { x: Schwellen_DGUVV15_Expo2_E[7][0], y: Schwellen_DGUVV15_Expo2_E[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(0, 127, 0, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(0, 127, 0, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_Expo2_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.DGUVV15_Expo2_E_Freq,\r\n y: this.V15_Expo2_E(this.DGUVV15_Expo2_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(0, 127, 0, 1)',\r\n pointBackgroundColor: 'rgba(0, 127, 0, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-EXPO1\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_Expo1_E[0][0], y: Schwellen_DGUVV15_Expo1_E[0][1] },\r\n { x: Schwellen_DGUVV15_Expo1_E[1][0], y: Schwellen_DGUVV15_Expo1_E[1][1] },\r\n { x: Schwellen_DGUVV15_Expo1_E[2][0], y: Schwellen_DGUVV15_Expo1_E[2][1] },\r\n { x: Schwellen_DGUVV15_Expo1_E[3][0], y: Schwellen_DGUVV15_Expo1_E[3][1] },\r\n { x: Schwellen_DGUVV15_Expo1_E[4][0], y: Schwellen_DGUVV15_Expo1_E[4][1] },\r\n { x: Schwellen_DGUVV15_Expo1_E[5][0], y: Schwellen_DGUVV15_Expo1_E[5][1] },\r\n { x: Schwellen_DGUVV15_Expo1_E[6][0], y: Schwellen_DGUVV15_Expo1_E[6][1] },\r\n { x: Schwellen_DGUVV15_Expo1_E[7][0], y: Schwellen_DGUVV15_Expo1_E[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(0, 0, 204, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(0, 0, 204, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_Expo1_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.DGUVV15_Expo1_E_Freq,\r\n y: this.V15_Expo1_E(this.DGUVV15_Expo1_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(0, 0, 204, 1)',\r\n pointBackgroundColor: 'rgba(0, 0, 204, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-HIGH\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_ExpoEr_E[0][0], y: Schwellen_DGUVV15_ExpoEr_E[0][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_E[1][0], y: Schwellen_DGUVV15_ExpoEr_E[1][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_E[2][0], y: Schwellen_DGUVV15_ExpoEr_E[2][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_E[3][0], y: Schwellen_DGUVV15_ExpoEr_E[3][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_E[4][0], y: Schwellen_DGUVV15_ExpoEr_E[4][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_ExpoEr_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.DGUVV15_ExpoEr_E_Freq,\r\n y: this.V15_ExpoEr_E(this.DGUVV15_ExpoEr_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.DGUVV15-PEAK\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[0][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[0][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[1][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[1][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[2][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[2][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[3][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[3][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[4][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[4][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[5][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[5][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[6][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[6][1] },\r\n { x: Schwellen_DGUVV15_ExpoEr_Spitze_E[7][0], y: Schwellen_DGUVV15_ExpoEr_Spitze_E[7][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n pointStyle: 'triangle',\r\n borderDash: [10, 6],\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.DGUVV15_ExpoEr_Spitze_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.DGUVV15_ExpoEr_Spitze_E_Freq,\r\n y: this.V15_ExpoEr_Spitze_E(this.DGUVV15_ExpoEr_Spitze_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'triangle',\r\n borderColor: 'rgba(204, 0, 0, 1)',\r\n pointBackgroundColor: 'rgba(204, 0, 0, 1)',\r\n fill: false,\r\n pointRadius: 5\r\n }\r\n ];\r\n\r\n this.EFeldChart.data.datasets = [\r\n ...this.EFeldChart.data.datasets,\r\n ...BImSchV_E_data\r\n ];\r\n}\r\n\r\nexport function updateDGUVV15_B_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // DGUV V15 - Expo 2\r\n // Range Check\r\n if (this.DGUVV15_Expo2_B_Freq < 0 || this.DGUVV15_Expo2_B_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index].data = [];\r\n this.BFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo2_B_Freq,\r\n y: (this.V15_Expo2_B(this.DGUVV15_Expo2_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo2_B_Freq,\r\n y: (this.V15_Expo2_B(this.DGUVV15_Expo2_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index].data = data;\r\n this.BFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.DGUVV15_Expo2_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // DGUV V15 - Expo 1\r\n // Range Check\r\n if (this.DGUVV15_Expo1_B_Freq < 0 || this.DGUVV15_Expo1_B_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index + 2].data = [];\r\n this.BFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo1_B_Freq,\r\n y: (this.V15_Expo1_B(this.DGUVV15_Expo1_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo1_B_Freq,\r\n y: (this.V15_Expo1_B(this.DGUVV15_Expo1_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 2].data = data;\r\n this.BFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.DGUVV15_Expo1_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // DGUV V15 - Bereich erhöhter Exposition\r\n // Range Check\r\n if (this.DGUVV15_ExpoEr_B_Freq < 0 || this.DGUVV15_ExpoEr_B_Freq > 91e3) {\r\n this.BFeldChart.data.datasets[index + 4].data = [];\r\n this.BFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_B_Freq,\r\n y: (this.V15_ExpoEr_B(this.DGUVV15_ExpoEr_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_B_Freq,\r\n y: (this.V15_ExpoEr_B(this.DGUVV15_ExpoEr_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 4].data = data;\r\n this.BFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.DGUVV15_ExpoEr_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // DGUV V15 - Spitzenwerte im Bereich erhöhter Exposition\r\n // Range Check\r\n if (this.DGUVV15_ExpoEr_Spitze_B_Freq < 91e3 || this.DGUVV15_ExpoEr_Spitze_B_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index + 6].data = [];\r\n this.BFeldChart.data.datasets[index + 6].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_Spitze_B_Freq,\r\n y: (this.V15_ExpoEr_Spitze_B(this.DGUVV15_ExpoEr_Spitze_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_Spitze_B_Freq,\r\n y: (this.V15_ExpoEr_Spitze_B(this.DGUVV15_ExpoEr_Spitze_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 6].data = data;\r\n this.BFeldChart.data.datasets[index + 6].label =\r\n 'Wert bei ' + this.DGUVV15_ExpoEr_Spitze_B_Freq + ' Hz (in T)';\r\n }\r\n}\r\n\r\nexport function updateDGUVV15_E_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // DGUV V15 - Expo 2\r\n // Range Check\r\n if (this.DGUVV15_Expo2_E_Freq < 0 || this.DGUVV15_Expo2_E_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index].data = [];\r\n this.EFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo2_E_Freq,\r\n y: this.V15_Expo2_E(this.DGUVV15_Expo2_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo2_E_Freq,\r\n y: this.V15_Expo2_E(this.DGUVV15_Expo2_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index].data = data;\r\n this.EFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.DGUVV15_Expo2_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // DGUV V15 - Expo 1\r\n // Range Check\r\n if (this.DGUVV15_Expo1_E_Freq < 0 || this.DGUVV15_Expo1_E_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index + 2].data = [];\r\n this.EFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo1_E_Freq,\r\n y: this.V15_Expo1_E(this.DGUVV15_Expo1_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_Expo1_E_Freq,\r\n y: this.V15_Expo1_E(this.DGUVV15_Expo1_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 2].data = data;\r\n this.EFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.DGUVV15_Expo1_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // DGUV V15 - Bereich erhöhter Exposition\r\n // Range Check\r\n if (this.DGUVV15_ExpoEr_E_Freq < 0 || this.DGUVV15_ExpoEr_E_Freq > 91e3) {\r\n this.EFeldChart.data.datasets[index + 4].data = [];\r\n this.EFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_E_Freq,\r\n y: this.V15_ExpoEr_E(this.DGUVV15_ExpoEr_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_E_Freq,\r\n y: this.V15_ExpoEr_E(this.DGUVV15_ExpoEr_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 4].data = data;\r\n this.EFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.DGUVV15_ExpoEr_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // DGUV V15 - Spitzenwerte im Bereich erhöhter Exposition\r\n // Range Check\r\n if (this.DGUVV15_ExpoEr_Spitze_E_Freq < 91e3 || this.DGUVV15_ExpoEr_Spitze_E_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index + 6].data = [];\r\n this.EFeldChart.data.datasets[index + 6].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_Spitze_E_Freq,\r\n y: this.V15_ExpoEr_Spitze_E(this.DGUVV15_ExpoEr_Spitze_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.DGUVV15_ExpoEr_Spitze_E_Freq,\r\n y: this.V15_ExpoEr_Spitze_E(this.DGUVV15_ExpoEr_Spitze_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 6].data = data;\r\n this.EFeldChart.data.datasets[index + 6].label =\r\n 'Wert bei ' + this.DGUVV15_ExpoEr_Spitze_E_Freq + ' Hz (in V/m)';\r\n }\r\n}\r\n\r\nexport function V15_Expo2_E(Frequenz: number) {\r\n if (Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Expo 2 DGUV V15 - E-Field\r\n Schwelle = 20e3; //in V/m RMS\r\n\r\n if (Frequenz >= 16.67) {\r\n if (Frequenz < 1000) {\r\n Schwelle = 333.3e3 / Frequenz;\r\n } else {\r\n if (Frequenz < 826e3) {\r\n Schwelle = 333.3;\r\n } else {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 275 / (Frequenz / 1e6);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 27.5;\r\n } else {\r\n if (Frequenz <= 2e9) {\r\n Schwelle = 1.375 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 61.5;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function V15_Expo1_E(Frequenz: number) {\r\n if (Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Expo 1 DGUV V15 - E-Field\r\n Schwelle = 30e3; //in V/m RMS\r\n\r\n if (Frequenz > 35.53) {\r\n if (Frequenz < 1000) {\r\n Schwelle = 1066e3 / Frequenz;\r\n } else {\r\n if (Frequenz < 576e3) {\r\n Schwelle = 1066;\r\n } else {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 614 / (Frequenz / 1e6);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 61.4;\r\n } else {\r\n if (Frequenz <= 2e9) {\r\n Schwelle = 3.07 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 137.3;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function V15_ExpoEr_E(Frequenz: number) {\r\n if (Frequenz > 91e3) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Bereich erhöhter Expo DGUV V15 - E-Field\r\n Schwelle = 30e3; //in V/m RMS\r\n\r\n if (Frequenz >= 66.67) {\r\n if (Frequenz < 1000) {\r\n Schwelle = 2000e3 / Frequenz;\r\n } else {\r\n if (Frequenz < 48.5e3) {\r\n Schwelle = 2000;\r\n } else {\r\n if (Frequenz <= 91e3) {\r\n Schwelle = 97e3 / (Frequenz / 1e3);\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function V15_ExpoEr_Spitze_E(Frequenz: number) {\r\n if (Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Spitzenwerte im Bereich erhöhter Exposition DGUV V15 - E-Field\r\n Schwelle = NaN; //in V/m \r\n\r\n if (Frequenz >= 91e3) {\r\n if (Frequenz < 100e3) {\r\n Schwelle = 2222;\r\n } else {\r\n if (Frequenz <= 0.3e6) {\r\n Schwelle = 22222 * (Frequenz / 1e6);\r\n } else {\r\n if (Frequenz < 3e6) {\r\n Schwelle = 6667;\r\n } else {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 20000 / (Frequenz / 1e6);\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 2000;\r\n } else {\r\n\r\n if (Frequenz < 2e9) {\r\n Schwelle = 100 * Math.sqrt(Frequenz / 1e6);\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 4472;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function V15_Expo2_B(Frequenz: number) {\r\n if (Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Expo 2 DGUV V15 - B-Field\r\n Schwelle = 21.22; //in mT RMS\r\n\r\n if (Frequenz > 1) {\r\n if (Frequenz < 1000) {\r\n Schwelle = 21.22 / Frequenz;\r\n } else {\r\n if (Frequenz < 91e3) {\r\n Schwelle = 21.22e-3;\r\n } else {\r\n if (Frequenz < 140e3) {\r\n Schwelle = 16.8 * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz < 30e6) {\r\n Schwelle = 2.35 / (Frequenz / 1e6) * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 0.073 * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz <= 2e9) {\r\n Schwelle = 3.64e-3 * Math.sqrt(Frequenz / 1e6) * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 0.163 * 4 * Math.PI * 1e-4;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function V15_Expo1_B(Frequenz: number) {\r\n if (Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Expo 1 DGUV V15 - B-Field\r\n Schwelle = 67.9; //in mT RMS\r\n\r\n if (Frequenz > 1) {\r\n if (Frequenz < 1000) {\r\n Schwelle = 67.9 / Frequenz;\r\n } else {\r\n if (Frequenz < 91e3) {\r\n Schwelle = 67.9e-3;\r\n } else {\r\n if (Frequenz < 30e6) {\r\n Schwelle = 4.9 / (Frequenz / 1e6) * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 0.163 * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 8.14e-3 * Math.sqrt(Frequenz / 1e6) * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 0.364 * 4 * Math.PI * 1e-4;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function V15_ExpoEr_B(Frequenz: number) {\r\n if (Frequenz > 91e3) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Bereich erhöhter Expo DGUV V15 - B-Field\r\n Schwelle = 127.3; //in mT RMS\r\n\r\n if (Frequenz > 1) {\r\n if (Frequenz < 1000) {\r\n Schwelle = 127.3 / Frequenz;\r\n } else {\r\n if (Frequenz <= 48.5e3) {\r\n Schwelle = 127.3e-3;\r\n } else {\r\n if (Frequenz <= 91e3) {\r\n Schwelle = 6176e-3 / (Frequenz / 1e3);\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\nexport function V15_ExpoEr_Spitze_B(Frequenz: number) {\r\n if (Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; //Spitzenwerte im Bereich erhöhter Exposition DGUV V15 - B-Field\r\n Schwelle = NaN; //in mT\r\n\r\n if (Frequenz >= 91e3) {\r\n if (Frequenz < 200e3) {\r\n Schwelle = 10 / (Frequenz / 1e6) * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz < 3e6) {\r\n Schwelle = 50 * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz < 30e6) {\r\n Schwelle = 150 / (Frequenz / 1e6) * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 5 * 4 * Math.PI * 1e-4;\r\n } else {\r\n\r\n if (Frequenz <= 2e9) {\r\n Schwelle = 0.25 * Math.sqrt(Frequenz / 1e6) * 4 * Math.PI * 1e-4;\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 11.2 * 4 * Math.PI * 1e-4;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}","import { EmfLitComponent } from \"./emf-lit.component\";\r\n\r\n// Schwellen B\r\nexport const Schwellen_EU2013_UAS_B = [[1, 0.2], [8, 3.125e-3], [25, 1e-3], [300, 1e-3], [3e3, 0.1e-3], [10e6, 0.1e-3]];\r\nexport const Schwellen_EU2013_OAS_B = [[1, 0.3], [3e3, 0.1e-3], [10e6, 0.1e-3]];\r\nexport const Schwellen_EU2013_Gliedmassen_B = [[1, 0.9], [3e3, 0.3e-3], [10e6, 0.3e-3]];\r\nexport const Schwellen_EU2013_Therm_B = [[100e3, 2e-5], [10e6, 0.2e-6], [400e6, 0.2e-6], [2e9, 0.45e-6], [3e11, 0.45e-6]];\r\n\r\n// Schwellen E\r\nexport const Schwellen_EU2013_UAS_E = [[1, 2e4], [25, 2e4], [3e3, 170], [10e6, 170]];\r\nexport const Schwellen_EU2013_OAS_E = [[1, 2e4], [50, 2e4], [1640, 610], [10e6, 610]];\r\nexport const Schwellen_EU2013_Therm_E = [[100e3, 610], [1e6, 610], [10e6, 61], [400e6, 60], [2e9, 140], [3e11, 140]];\r\n\r\n\r\nexport function updateEU2013_B_Regelwerk(this: EmfLitComponent) {\r\n\r\n let EU2013_B_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.EU2013-LAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU2013_UAS_B[0][0], y: Schwellen_EU2013_UAS_B[0][1] },\r\n { x: Schwellen_EU2013_UAS_B[1][0], y: Schwellen_EU2013_UAS_B[1][1] },\r\n { x: Schwellen_EU2013_UAS_B[2][0], y: Schwellen_EU2013_UAS_B[2][1] },\r\n { x: Schwellen_EU2013_UAS_B[3][0], y: Schwellen_EU2013_UAS_B[3][1] },\r\n { x: Schwellen_EU2013_UAS_B[4][0], y: Schwellen_EU2013_UAS_B[4][1] },\r\n { x: Schwellen_EU2013_UAS_B[5][0], y: Schwellen_EU2013_UAS_B[5][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 130, 0, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(255, 130, 0, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU2013_UAS_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EU2013_UAS_B_Freq,\r\n y: this.EU2013_UAS_B(this.EU2013_UAS_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(255, 130, 0, 1)',\r\n pointBackgroundColor: 'rgba(255, 130, 0, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EU2013-UAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU2013_OAS_B[0][0], y: Schwellen_EU2013_OAS_B[0][1] },\r\n { x: Schwellen_EU2013_OAS_B[1][0], y: Schwellen_EU2013_OAS_B[1][1] },\r\n { x: Schwellen_EU2013_OAS_B[2][0], y: Schwellen_EU2013_OAS_B[2][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(124, 103, 74, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(124, 103, 74, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU2013_OAS_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EU2013_OAS_B_Freq,\r\n y: this.EU2013_OAS_B(this.EU2013_OAS_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(124, 103, 74, 1)',\r\n pointBackgroundColor: 'rgba(124, 103, 74, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EU2013-ALL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU2013_Gliedmassen_B[0][0], y: Schwellen_EU2013_Gliedmassen_B[0][1] },\r\n { x: Schwellen_EU2013_Gliedmassen_B[1][0], y: Schwellen_EU2013_Gliedmassen_B[1][1] },\r\n { x: Schwellen_EU2013_Gliedmassen_B[2][0], y: Schwellen_EU2013_Gliedmassen_B[2][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(245, 116, 97, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(245, 116, 97, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU2013_Gliedmassen_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EU2013_Gliedmassen_B_Freq,\r\n y: this.EU2013_Gliedmassen_B(this.EU2013_Gliedmassen_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(245, 116, 97, 1)',\r\n pointBackgroundColor: 'rgba(245, 116, 97, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EU2013-THERM\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU2013_Therm_B[0][0], y: Schwellen_EU2013_Therm_B[0][1] },\r\n { x: Schwellen_EU2013_Therm_B[1][0], y: Schwellen_EU2013_Therm_B[1][1] },\r\n { x: Schwellen_EU2013_Therm_B[2][0], y: Schwellen_EU2013_Therm_B[2][1] },\r\n { x: Schwellen_EU2013_Therm_B[3][0], y: Schwellen_EU2013_Therm_B[3][1] },\r\n { x: Schwellen_EU2013_Therm_B[4][0], y: Schwellen_EU2013_Therm_B[4][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 241, 82, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(255, 241, 82, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU2013_Therm_B_Freq + ' Hz (in T)',\r\n data: [\r\n {\r\n x: this.EU2013_Therm_B_Freq,\r\n y: this.EU2013_Thermisch_B(this.EU2013_Therm_B_Freq) / 1000\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(255, 241, 82, 1)',\r\n pointBackgroundColor: 'rgba(255, 241, 82, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n }\r\n ];\r\n \r\n // An das Chart Dataset hinten dran hängen\r\n this.BFeldChart.data.datasets = [\r\n ...this.BFeldChart.data.datasets,\r\n ...EU2013_B_data\r\n ];\r\n}\r\n\r\nexport function updateEU2013_E_Regelwerk(this: EmfLitComponent) {\r\n let EU2013_E_data = [\r\n {\r\n label: this.translate.instant(\"VALUES.EU2013-LAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU2013_UAS_E[0][0], y: Schwellen_EU2013_UAS_E[0][1] },\r\n { x: Schwellen_EU2013_UAS_E[1][0], y: Schwellen_EU2013_UAS_E[1][1] },\r\n { x: Schwellen_EU2013_UAS_E[2][0], y: Schwellen_EU2013_UAS_E[2][1] },\r\n { x: Schwellen_EU2013_UAS_E[3][0], y: Schwellen_EU2013_UAS_E[3][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 130, 0, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(255, 130, 0, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU2013_UAS_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EU2013_UAS_E_Freq,\r\n y: this.EU2013_UAS_E(this.EU2013_UAS_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(255, 130, 0, 1)',\r\n pointBackgroundColor: 'rgba(255, 130, 0, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EU2013-UAL\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU2013_OAS_E[0][0], y: Schwellen_EU2013_OAS_E[0][1] },\r\n { x: Schwellen_EU2013_OAS_E[1][0], y: Schwellen_EU2013_OAS_E[1][1] },\r\n { x: Schwellen_EU2013_OAS_E[2][0], y: Schwellen_EU2013_OAS_E[2][1] },\r\n { x: Schwellen_EU2013_OAS_E[3][0], y: Schwellen_EU2013_OAS_E[3][1] }\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(124, 103, 74, 1)',\r\n borderWidth: 2,\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(124, 103, 74, 1)',\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU2013_OAS_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EU2013_OAS_E_Freq,\r\n y: this.EU2013_OAS_E(this.EU2013_OAS_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(124, 103, 74, 1)',\r\n pointBackgroundColor: 'rgba(124, 103, 74, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n },\r\n {\r\n label: this.translate.instant(\"VALUES.EU2013-THERM\"),\r\n lineTension: 0,\r\n data: [\r\n { x: Schwellen_EU2013_Therm_E[0][0], y: Schwellen_EU2013_Therm_E[0][1] },\r\n { x: Schwellen_EU2013_Therm_E[1][0], y: Schwellen_EU2013_Therm_E[1][1] },\r\n { x: Schwellen_EU2013_Therm_E[2][0], y: Schwellen_EU2013_Therm_E[2][1] },\r\n { x: Schwellen_EU2013_Therm_E[3][0], y: Schwellen_EU2013_Therm_E[3][1] },\r\n { x: Schwellen_EU2013_Therm_E[4][0], y: Schwellen_EU2013_Therm_E[4][1] },\r\n { x: Schwellen_EU2013_Therm_E[5][0], y: Schwellen_EU2013_Therm_E[5][1] },\r\n ],\r\n fill: false,\r\n borderColor: 'rgba(255, 241, 82, 1)',\r\n pointStyle: 'circle',\r\n pointBackgroundColor: 'rgba(255, 241, 82, 1)',\r\n borderWidth: 2,\r\n pointRadius: 0\r\n },\r\n {\r\n label: 'Wert bei ' + this.EU2013_Therm_E_Freq + ' Hz (in V/m)',\r\n data: [\r\n {\r\n x: this.EU2013_Therm_E_Freq,\r\n y: this.EU2013_Thermisch_E(this.EU2013_Therm_E_Freq)\r\n }\r\n ],\r\n type: 'scatter',\r\n pointStyle: 'circle',\r\n borderColor: 'rgba(255, 241, 82, 1)',\r\n pointBackgroundColor: 'rgba(255, 241, 82, 1)',\r\n fill: false,\r\n pointRadius: 4\r\n }\r\n ];\r\n\r\n // An das Chart Dataset hinten dran hängen\r\n this.EFeldChart.data.datasets = [\r\n ...this.EFeldChart.data.datasets,\r\n ...EU2013_E_data\r\n ];\r\n}\r\n\r\nexport function updateEU2013_B_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // EU2013 UAS\r\n // Range Check\r\n if (this.EU2013_UAS_B_Freq < 1 || this.EU2013_UAS_B_Freq > 1e7) {\r\n this.BFeldChart.data.datasets[index].data = [];\r\n this.BFeldChart.data.datasets[index].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU2013_UAS_B_Freq,\r\n y: (this.EU2013_UAS_B(this.EU2013_UAS_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EU2013_UAS_B_Freq,\r\n y: (this.EU2013_UAS_B(this.EU2013_UAS_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index].data = data;\r\n this.BFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.EU2013_UAS_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // EU2013 OAS\r\n // Range Check\r\n if (this.EU2013_OAS_B_Freq < 1 || this.EU2013_OAS_B_Freq > 1e7) {\r\n this.BFeldChart.data.datasets[index + 2].data = [];\r\n this.BFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU2013_OAS_B_Freq,\r\n y: (this.EU2013_OAS_B(this.EU2013_OAS_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EU2013_OAS_B_Freq,\r\n y: (this.EU2013_OAS_B(this.EU2013_OAS_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 2].data = data;\r\n this.BFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.EU2013_OAS_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // EU2013 Gliedmassen\r\n // Range Check\r\n if (this.EU2013_Gliedmassen_B_Freq < 1 || this.EU2013_Gliedmassen_B_Freq > 1e7) {\r\n this.BFeldChart.data.datasets[index + 4].data = [];\r\n this.BFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU2013_Gliedmassen_B_Freq,\r\n y: (this.EU2013_Gliedmassen_B(this.EU2013_Gliedmassen_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EU2013_Gliedmassen_B_Freq,\r\n y: (this.EU2013_Gliedmassen_B(this.EU2013_Gliedmassen_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 4].data = data;\r\n this.BFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.EU2013_Gliedmassen_B_Freq + ' Hz (in T)';\r\n }\r\n\r\n // EU2013 Thermische Auslöseschwelle\r\n // Range Check\r\n if (this.EU2013_Therm_B_Freq < 100e3 || this.EU2013_Therm_B_Freq > 300e9) {\r\n this.BFeldChart.data.datasets[index + 6].data = [];\r\n this.BFeldChart.data.datasets[index + 6].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU2013_Therm_B_Freq,\r\n y: (this.EU2013_Thermisch_B(this.EU2013_Therm_B_Freq) / 1000) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EU2013_Therm_B_Freq,\r\n y: (this.EU2013_Thermisch_B(this.EU2013_Therm_B_Freq) / 1000)\r\n }\r\n ]; \r\n } \r\n this.BFeldChart.data.datasets[index + 6].data = data;\r\n this.BFeldChart.data.datasets[index + 6].label =\r\n 'Wert bei ' + this.EU2013_Therm_B_Freq + ' Hz (in T)';\r\n }\r\n}\r\n\r\nexport function updateEU2013_E_Frequenz(this: EmfLitComponent, index: number) {\r\n let data = [];\r\n // Range Check\r\n if (this.EU2013_UAS_E_Freq < 1 || this.EU2013_UAS_E_Freq > 1e7) {\r\n this.EFeldChart.data.datasets[index].data = [];\r\n this.EFeldChart.data.datasets[index].label = '';\r\n } else {\r\n // EU2013 UAS\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU2013_UAS_E_Freq,\r\n y: this.EU2013_UAS_E(this.EU2013_UAS_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EU2013_UAS_E_Freq,\r\n y: this.EU2013_UAS_E(this.EU2013_UAS_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index].data = data;\r\n this.EFeldChart.data.datasets[index].label =\r\n 'Wert bei ' + this.EU2013_UAS_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // EU2013 OAS\r\n // Range Check\r\n if (this.EU2013_OAS_E_Freq < 1 || this.EU2013_OAS_E_Freq > 1e7) {\r\n this.EFeldChart.data.datasets[index + 2].data = [];\r\n this.EFeldChart.data.datasets[index + 2].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU2013_OAS_E_Freq,\r\n y: this.EU2013_OAS_E(this.EU2013_OAS_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EU2013_OAS_E_Freq,\r\n y: this.EU2013_OAS_E(this.EU2013_OAS_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 2].data = data;\r\n this.EFeldChart.data.datasets[index + 2].label =\r\n 'Wert bei ' + this.EU2013_OAS_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n // EU2013 Thermische Auslöseschwelle\r\n // Range Check\r\n if (this.EU2013_Therm_E_Freq < 100e3 || this.EU2013_Therm_E_Freq > 300e9) {\r\n this.EFeldChart.data.datasets[index + 4].data = [];\r\n this.EFeldChart.data.datasets[index + 4].label = '';\r\n } else {\r\n if(this.UnsicherheitCheck) {\r\n data = [\r\n {\r\n x: this.EU2013_Therm_E_Freq,\r\n y: this.EU2013_Thermisch_E(this.EU2013_Therm_E_Freq) / this.FaktorU\r\n }\r\n ]; \r\n } else {\r\n data = [\r\n {\r\n x: this.EU2013_Therm_E_Freq,\r\n y: this.EU2013_Thermisch_E(this.EU2013_Therm_E_Freq)\r\n }\r\n ]; \r\n } \r\n this.EFeldChart.data.datasets[index + 4].data = data;\r\n this.EFeldChart.data.datasets[index + 4].label =\r\n 'Wert bei ' + this.EU2013_Therm_E_Freq + ' Hz (in V/m)';\r\n }\r\n\r\n}\r\n\r\nexport function EU2013_Gliedmassen_B(Frequenz: number) {\r\n //NaN für <1 und größer 10 MHz\r\n if (Frequenz < 1 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let GAS: number; // Auslöseschwelle für Gliedmassen\r\n GAS = 900; //in mT\r\n \r\n if (Frequenz < 3000) {\r\n GAS = 900 / Frequenz;\r\n } else {\r\n GAS = 0.3;\r\n } \r\n\r\n return GAS;\r\n}\r\n\r\nexport function EU2013_OAS_B(Frequenz: number) {\r\n //NaN für <1 und größer 10 MHz\r\n if (Frequenz < 1 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let OAS: number; // Hohe Auslöseschwelle\r\n OAS = 300; //in mT\r\n\r\n if (Frequenz < 3000) {\r\n OAS = 300 / Frequenz;\r\n } else {\r\n OAS = 0.1;\r\n }\r\n\r\n return OAS;\r\n}\r\n\r\nexport function EU2013_UAS_B(Frequenz: number) {\r\n if (Frequenz < 1 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let UAS: number; // Niedrige Auslöseschwelle\r\n UAS = 200; //in mT\r\n if (Frequenz < 8) {\r\n UAS = 200 / Math.pow(Frequenz,2);\r\n } else {\r\n if (Frequenz < 25) {\r\n UAS = 25 / Frequenz;\r\n } else {\r\n if (Frequenz < 300) {\r\n UAS = 1;\r\n } else {\r\n if (Frequenz < 3000) {\r\n UAS = 300 / Frequenz;\r\n } else {\r\n UAS = 0.1;\r\n }\r\n }\r\n }\r\n }\r\n return UAS;\r\n}\r\n\r\nexport function EU2013_Thermisch_B(Frequenz: number) {\r\n if (Frequenz < 100e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Auslöseschwelle für thermische Wirkungen\r\n Schwelle = 2e-5; //in T RMS\r\n\r\n if (Frequenz < 10e6) {\r\n Schwelle = 2 / Frequenz;\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 0.2e-6;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 1e-11 * Math.sqrt(Frequenz);\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 0.45e-6;\r\n }\r\n }\r\n }\r\n }\r\n\r\n //T -> mT\r\n Schwelle = Schwelle * 1000; \r\n return Schwelle;\r\n}\r\n\r\n\r\nexport function EU2013_OAS_E(Frequenz: number) {\r\n //NaN für <1 und größer 10 MHz\r\n if (Frequenz < 1 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let OAS: number; // Hohe Auslöseschwelle\r\n OAS = 2e4; //in V/m\r\n if (Frequenz >= 50) {\r\n if (Frequenz < 1640) {\r\n OAS = 1e6 / Frequenz;\r\n } else {\r\n OAS = 610;\r\n }\r\n }\r\n\r\n return OAS;\r\n}\r\n\r\nexport function EU2013_UAS_E(Frequenz: number) {\r\n if (Frequenz < 1 || Frequenz > 10e6) {\r\n return NaN;\r\n }\r\n\r\n let UAS: number; // Niedrige Auslöseschwelle\r\n UAS = 2e4; //in V/m\r\n if (Frequenz >= 25) {\r\n if (Frequenz < 3000) {\r\n UAS = 5e5 / Frequenz;\r\n } else {\r\n UAS = 170;\r\n }\r\n }\r\n return UAS;\r\n}\r\n\r\nexport function EU2013_Thermisch_E(Frequenz: number) {\r\n if (Frequenz < 100e3 || Frequenz > 300e9) {\r\n return NaN;\r\n }\r\n\r\n let Schwelle: number; // Auslöseschwelle für thermische Wirkungen\r\n Schwelle = 610; //in V/m RMS\r\n\r\n if (Frequenz >= 1e6) {\r\n if (Frequenz < 10e6) {\r\n Schwelle = 610e6 / Frequenz;\r\n } else {\r\n if (Frequenz < 400e6) {\r\n Schwelle = 61;\r\n } else {\r\n if (Frequenz < 2e9) {\r\n Schwelle = 3e-3 * Math.sqrt(Frequenz);\r\n } else {\r\n if (Frequenz <= 3e11) {\r\n Schwelle = 140;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n\r\n return Schwelle;\r\n}\r\n\r\n","/**\n * @license Angular v19.2.1\n * (c) 2010-2025 Google LLC. https://angular.io/\n * License: MIT\n */\n\nimport * as i0 from '@angular/core';\nimport { Directive, InjectionToken, forwardRef, Optional, Inject, ɵisPromise, ɵisSubscribable, ɵRuntimeError, Self, untracked, computed, signal, EventEmitter, Input, Host, SkipSelf, booleanAttribute, ChangeDetectorRef, Output, Injectable, inject, NgModule, Version } from '@angular/core';\nimport { ɵgetDOM } from '@angular/common';\nimport { from, forkJoin, Subject } from 'rxjs';\nimport { map } from 'rxjs/operators';\n\n/**\n * Base class for all ControlValueAccessor classes defined in Forms package.\n * Contains common logic and utility functions.\n *\n * Note: this is an *internal-only* class and should not be extended or used directly in\n * applications code.\n */\nclass BaseControlValueAccessor {\n _renderer;\n _elementRef;\n /**\n * The registered callback function called when a change or input event occurs on the input\n * element.\n * @nodoc\n */\n onChange = _ => {};\n /**\n * The registered callback function called when a blur event occurs on the input element.\n * @nodoc\n */\n onTouched = () => {};\n constructor(_renderer, _elementRef) {\n this._renderer = _renderer;\n this._elementRef = _elementRef;\n }\n /**\n * Helper method that sets a property on a target element using the current Renderer\n * implementation.\n * @nodoc\n */\n setProperty(key, value) {\n this._renderer.setProperty(this._elementRef.nativeElement, key, value);\n }\n /**\n * Registers a function called when the control is touched.\n * @nodoc\n */\n registerOnTouched(fn) {\n this.onTouched = fn;\n }\n /**\n * Registers a function called when the control value changes.\n * @nodoc\n */\n registerOnChange(fn) {\n this.onChange = fn;\n }\n /**\n * Sets the \"disabled\" property on the range input element.\n * @nodoc\n */\n setDisabledState(isDisabled) {\n this.setProperty('disabled', isDisabled);\n }\n static ɵfac = function BaseControlValueAccessor_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || BaseControlValueAccessor)(i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(i0.ElementRef));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: BaseControlValueAccessor\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(BaseControlValueAccessor, [{\n type: Directive\n }], () => [{\n type: i0.Renderer2\n }, {\n type: i0.ElementRef\n }], null);\n})();\n/**\n * Base class for all built-in ControlValueAccessor classes (except DefaultValueAccessor, which is\n * used in case no other CVAs can be found). We use this class to distinguish between default CVA,\n * built-in CVAs and custom CVAs, so that Forms logic can recognize built-in CVAs and treat custom\n * ones with higher priority (when both built-in and custom CVAs are present).\n *\n * Note: this is an *internal-only* class and should not be extended or used directly in\n * applications code.\n */\nclass BuiltInControlValueAccessor extends BaseControlValueAccessor {\n static ɵfac = /* @__PURE__ */(() => {\n let ɵBuiltInControlValueAccessor_BaseFactory;\n return function BuiltInControlValueAccessor_Factory(__ngFactoryType__) {\n return (ɵBuiltInControlValueAccessor_BaseFactory || (ɵBuiltInControlValueAccessor_BaseFactory = i0.ɵɵgetInheritedFactory(BuiltInControlValueAccessor)))(__ngFactoryType__ || BuiltInControlValueAccessor);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: BuiltInControlValueAccessor,\n features: [i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(BuiltInControlValueAccessor, [{\n type: Directive\n }], null, null);\n})();\n/**\n * Used to provide a `ControlValueAccessor` for form controls.\n *\n * See `DefaultValueAccessor` for how to implement one.\n *\n * @publicApi\n */\nconst NG_VALUE_ACCESSOR = new InjectionToken(ngDevMode ? 'NgValueAccessor' : '');\nconst CHECKBOX_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => CheckboxControlValueAccessor),\n multi: true\n};\n/**\n * @description\n * A `ControlValueAccessor` for writing a value and listening to changes on a checkbox input\n * element.\n *\n * @usageNotes\n *\n * ### Using a checkbox with a reactive form.\n *\n * The following example shows how to use a checkbox with a reactive form.\n *\n * ```ts\n * const rememberLoginControl = new FormControl();\n * ```\n *\n * ```html\n * <input type=\"checkbox\" [formControl]=\"rememberLoginControl\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass CheckboxControlValueAccessor extends BuiltInControlValueAccessor {\n /**\n * Sets the \"checked\" property on the input element.\n * @nodoc\n */\n writeValue(value) {\n this.setProperty('checked', value);\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵCheckboxControlValueAccessor_BaseFactory;\n return function CheckboxControlValueAccessor_Factory(__ngFactoryType__) {\n return (ɵCheckboxControlValueAccessor_BaseFactory || (ɵCheckboxControlValueAccessor_BaseFactory = i0.ɵɵgetInheritedFactory(CheckboxControlValueAccessor)))(__ngFactoryType__ || CheckboxControlValueAccessor);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: CheckboxControlValueAccessor,\n selectors: [[\"input\", \"type\", \"checkbox\", \"formControlName\", \"\"], [\"input\", \"type\", \"checkbox\", \"formControl\", \"\"], [\"input\", \"type\", \"checkbox\", \"ngModel\", \"\"]],\n hostBindings: function CheckboxControlValueAccessor_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"change\", function CheckboxControlValueAccessor_change_HostBindingHandler($event) {\n return ctx.onChange($event.target.checked);\n })(\"blur\", function CheckboxControlValueAccessor_blur_HostBindingHandler() {\n return ctx.onTouched();\n });\n }\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([CHECKBOX_VALUE_ACCESSOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(CheckboxControlValueAccessor, [{\n type: Directive,\n args: [{\n selector: 'input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]',\n host: {\n '(change)': 'onChange($event.target.checked)',\n '(blur)': 'onTouched()'\n },\n providers: [CHECKBOX_VALUE_ACCESSOR],\n standalone: false\n }]\n }], null, null);\n})();\nconst DEFAULT_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => DefaultValueAccessor),\n multi: true\n};\n/**\n * We must check whether the agent is Android because composition events\n * behave differently between iOS and Android.\n */\nfunction _isAndroid() {\n const userAgent = ɵgetDOM() ? ɵgetDOM().getUserAgent() : '';\n return /android (\\d+)/.test(userAgent.toLowerCase());\n}\n/**\n * @description\n * Provide this token to control if form directives buffer IME input until\n * the \"compositionend\" event occurs.\n * @publicApi\n */\nconst COMPOSITION_BUFFER_MODE = new InjectionToken(ngDevMode ? 'CompositionEventMode' : '');\n/**\n * The default `ControlValueAccessor` for writing a value and listening to changes on input\n * elements. The accessor is used by the `FormControlDirective`, `FormControlName`, and\n * `NgModel` directives.\n *\n *\n * @usageNotes\n *\n * ### Using the default value accessor\n *\n * The following example shows how to use an input element that activates the default value accessor\n * (in this case, a text field).\n *\n * ```ts\n * const firstNameControl = new FormControl();\n * ```\n *\n * ```html\n * <input type=\"text\" [formControl]=\"firstNameControl\">\n * ```\n *\n * This value accessor is used by default for `<input type=\"text\">` and `<textarea>` elements, but\n * you could also use it for custom components that have similar behavior and do not require special\n * processing. In order to attach the default value accessor to a custom element, add the\n * `ngDefaultControl` attribute as shown below.\n *\n * ```html\n * <custom-input-component ngDefaultControl [(ngModel)]=\"value\"></custom-input-component>\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass DefaultValueAccessor extends BaseControlValueAccessor {\n _compositionMode;\n /** Whether the user is creating a composition string (IME events). */\n _composing = false;\n constructor(renderer, elementRef, _compositionMode) {\n super(renderer, elementRef);\n this._compositionMode = _compositionMode;\n if (this._compositionMode == null) {\n this._compositionMode = !_isAndroid();\n }\n }\n /**\n * Sets the \"value\" property on the input element.\n * @nodoc\n */\n writeValue(value) {\n const normalizedValue = value == null ? '' : value;\n this.setProperty('value', normalizedValue);\n }\n /** @internal */\n _handleInput(value) {\n if (!this._compositionMode || this._compositionMode && !this._composing) {\n this.onChange(value);\n }\n }\n /** @internal */\n _compositionStart() {\n this._composing = true;\n }\n /** @internal */\n _compositionEnd(value) {\n this._composing = false;\n this._compositionMode && this.onChange(value);\n }\n static ɵfac = function DefaultValueAccessor_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || DefaultValueAccessor)(i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(COMPOSITION_BUFFER_MODE, 8));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: DefaultValueAccessor,\n selectors: [[\"input\", \"formControlName\", \"\", 3, \"type\", \"checkbox\"], [\"textarea\", \"formControlName\", \"\"], [\"input\", \"formControl\", \"\", 3, \"type\", \"checkbox\"], [\"textarea\", \"formControl\", \"\"], [\"input\", \"ngModel\", \"\", 3, \"type\", \"checkbox\"], [\"textarea\", \"ngModel\", \"\"], [\"\", \"ngDefaultControl\", \"\"]],\n hostBindings: function DefaultValueAccessor_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"input\", function DefaultValueAccessor_input_HostBindingHandler($event) {\n return ctx._handleInput($event.target.value);\n })(\"blur\", function DefaultValueAccessor_blur_HostBindingHandler() {\n return ctx.onTouched();\n })(\"compositionstart\", function DefaultValueAccessor_compositionstart_HostBindingHandler() {\n return ctx._compositionStart();\n })(\"compositionend\", function DefaultValueAccessor_compositionend_HostBindingHandler($event) {\n return ctx._compositionEnd($event.target.value);\n });\n }\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([DEFAULT_VALUE_ACCESSOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(DefaultValueAccessor, [{\n type: Directive,\n args: [{\n selector: 'input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]',\n // TODO: vsavkin replace the above selector with the one below it once\n // https://github.com/angular/angular/issues/3011 is implemented\n // selector: '[ngModel],[formControl],[formControlName]',\n host: {\n '(input)': '$any(this)._handleInput($event.target.value)',\n '(blur)': 'onTouched()',\n '(compositionstart)': '$any(this)._compositionStart()',\n '(compositionend)': '$any(this)._compositionEnd($event.target.value)'\n },\n providers: [DEFAULT_VALUE_ACCESSOR],\n standalone: false\n }]\n }], () => [{\n type: i0.Renderer2\n }, {\n type: i0.ElementRef\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [COMPOSITION_BUFFER_MODE]\n }]\n }], null);\n})();\nfunction isEmptyInputValue(value) {\n return value == null || lengthOrSize(value) === 0;\n}\n/**\n * Extract the length property in case it's an array or a string.\n * Extract the size property in case it's a set.\n * Return null else.\n * @param value Either an array, set or undefined.\n */\nfunction lengthOrSize(value) {\n // non-strict comparison is intentional, to check for both `null` and `undefined` values\n if (value == null) {\n return null;\n } else if (Array.isArray(value) || typeof value === 'string') {\n return value.length;\n } else if (value instanceof Set) {\n return value.size;\n }\n return null;\n}\n/**\n * @description\n * An `InjectionToken` for registering additional synchronous validators used with\n * `AbstractControl`s.\n *\n * @see {@link NG_ASYNC_VALIDATORS}\n *\n * @usageNotes\n *\n * ### Providing a custom validator\n *\n * The following example registers a custom validator directive. Adding the validator to the\n * existing collection of validators requires the `multi: true` option.\n *\n * ```ts\n * @Directive({\n * selector: '[customValidator]',\n * providers: [{provide: NG_VALIDATORS, useExisting: CustomValidatorDirective, multi: true}]\n * })\n * class CustomValidatorDirective implements Validator {\n * validate(control: AbstractControl): ValidationErrors | null {\n * return { 'custom': true };\n * }\n * }\n * ```\n *\n * @publicApi\n */\nconst NG_VALIDATORS = new InjectionToken(ngDevMode ? 'NgValidators' : '');\n/**\n * @description\n * An `InjectionToken` for registering additional asynchronous validators used with\n * `AbstractControl`s.\n *\n * @see {@link NG_VALIDATORS}\n *\n * @usageNotes\n *\n * ### Provide a custom async validator directive\n *\n * The following example implements the `AsyncValidator` interface to create an\n * async validator directive with a custom error key.\n *\n * ```ts\n * @Directive({\n * selector: '[customAsyncValidator]',\n * providers: [{provide: NG_ASYNC_VALIDATORS, useExisting: CustomAsyncValidatorDirective, multi:\n * true}]\n * })\n * class CustomAsyncValidatorDirective implements AsyncValidator {\n * validate(control: AbstractControl): Promise<ValidationErrors|null> {\n * return Promise.resolve({'custom': true});\n * }\n * }\n * ```\n *\n * @publicApi\n */\nconst NG_ASYNC_VALIDATORS = new InjectionToken(ngDevMode ? 'NgAsyncValidators' : '');\n/**\n * A regular expression that matches valid e-mail addresses.\n *\n * At a high level, this regexp matches e-mail addresses of the format `local-part@tld`, where:\n * - `local-part` consists of one or more of the allowed characters (alphanumeric and some\n * punctuation symbols).\n * - `local-part` cannot begin or end with a period (`.`).\n * - `local-part` cannot be longer than 64 characters.\n * - `tld` consists of one or more `labels` separated by periods (`.`). For example `localhost` or\n * `foo.com`.\n * - A `label` consists of one or more of the allowed characters (alphanumeric, dashes (`-`) and\n * periods (`.`)).\n * - A `label` cannot begin or end with a dash (`-`) or a period (`.`).\n * - A `label` cannot be longer than 63 characters.\n * - The whole address cannot be longer than 254 characters.\n *\n * ## Implementation background\n *\n * This regexp was ported over from AngularJS (see there for git history):\n * https://github.com/angular/angular.js/blob/c133ef836/src/ng/directive/input.js#L27\n * It is based on the\n * [WHATWG version](https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address) with\n * some enhancements to incorporate more RFC rules (such as rules related to domain names and the\n * lengths of different parts of the address). The main differences from the WHATWG version are:\n * - Disallow `local-part` to begin or end with a period (`.`).\n * - Disallow `local-part` length to exceed 64 characters.\n * - Disallow total address length to exceed 254 characters.\n *\n * See [this commit](https://github.com/angular/angular.js/commit/f3f5cf72e) for more details.\n */\nconst 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])?)*$/;\n/**\n * @description\n * Provides a set of built-in validators that can be used by form controls.\n *\n * A validator is a function that processes a `FormControl` or collection of\n * controls and returns an error map or null. A null map means that validation has passed.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @publicApi\n */\nclass Validators {\n /**\n * @description\n * Validator that requires the control's value to be greater than or equal to the provided number.\n *\n * @usageNotes\n *\n * ### Validate against a minimum of 3\n *\n * ```ts\n * const control = new FormControl(2, Validators.min(3));\n *\n * console.log(control.errors); // {min: {min: 3, actual: 2}}\n * ```\n *\n * @returns A validator function that returns an error map with the\n * `min` property if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static min(min) {\n return minValidator(min);\n }\n /**\n * @description\n * Validator that requires the control's value to be less than or equal to the provided number.\n *\n * @usageNotes\n *\n * ### Validate against a maximum of 15\n *\n * ```ts\n * const control = new FormControl(16, Validators.max(15));\n *\n * console.log(control.errors); // {max: {max: 15, actual: 16}}\n * ```\n *\n * @returns A validator function that returns an error map with the\n * `max` property if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static max(max) {\n return maxValidator(max);\n }\n /**\n * @description\n * Validator that requires the control have a non-empty value.\n *\n * @usageNotes\n *\n * ### Validate that the field is non-empty\n *\n * ```ts\n * const control = new FormControl('', Validators.required);\n *\n * console.log(control.errors); // {required: true}\n * ```\n *\n * @returns An error map with the `required` property\n * if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static required(control) {\n return requiredValidator(control);\n }\n /**\n * @description\n * Validator that requires the control's value be true. This validator is commonly\n * used for required checkboxes.\n *\n * @usageNotes\n *\n * ### Validate that the field value is true\n *\n * ```ts\n * const control = new FormControl('some value', Validators.requiredTrue);\n *\n * console.log(control.errors); // {required: true}\n * ```\n *\n * @returns An error map that contains the `required` property\n * set to `true` if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static requiredTrue(control) {\n return requiredTrueValidator(control);\n }\n /**\n * @description\n * Validator that requires the control's value pass an email validation test.\n *\n * Tests the value using a [regular\n * expression](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions)\n * pattern suitable for common use cases. The pattern is based on the definition of a valid email\n * address in the [WHATWG HTML\n * specification](https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address) with\n * some enhancements to incorporate more RFC rules (such as rules related to domain names and the\n * lengths of different parts of the address).\n *\n * The differences from the WHATWG version include:\n * - Disallow `local-part` (the part before the `@` symbol) to begin or end with a period (`.`).\n * - Disallow `local-part` to be longer than 64 characters.\n * - Disallow the whole address to be longer than 254 characters.\n *\n * If this pattern does not satisfy your business needs, you can use `Validators.pattern()` to\n * validate the value against a different pattern.\n *\n * @usageNotes\n *\n * ### Validate that the field matches a valid email pattern\n *\n * ```ts\n * const control = new FormControl('bad@', Validators.email);\n *\n * console.log(control.errors); // {email: true}\n * ```\n *\n * @returns An error map with the `email` property\n * if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static email(control) {\n return emailValidator(control);\n }\n /**\n * @description\n * Validator that requires the number of items in the control's value to be greater than or equal\n * to the provided minimum length. This validator is also provided by default if you use\n * the HTML5 `minlength` attribute. Note that the `minLength` validator is intended to be used\n * only for types that have a numeric `length` or `size` property, such as strings, arrays or\n * sets. The `minLength` validator logic is also not invoked for values when their `length` or\n * `size` property is 0 (for example in case of an empty string or an empty array), to support\n * optional controls. You can use the standard `required` validator if empty values should not be\n * considered valid.\n *\n * @usageNotes\n *\n * ### Validate that the field has a minimum of 3 characters\n *\n * ```ts\n * const control = new FormControl('ng', Validators.minLength(3));\n *\n * console.log(control.errors); // {minlength: {requiredLength: 3, actualLength: 2}}\n * ```\n *\n * ```html\n * <input minlength=\"5\">\n * ```\n *\n * @returns A validator function that returns an error map with the\n * `minlength` property if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static minLength(minLength) {\n return minLengthValidator(minLength);\n }\n /**\n * @description\n * Validator that requires the number of items in the control's value to be less than or equal\n * to the provided maximum length. This validator is also provided by default if you use\n * the HTML5 `maxlength` attribute. Note that the `maxLength` validator is intended to be used\n * only for types that have a numeric `length` or `size` property, such as strings, arrays or\n * sets.\n *\n * @usageNotes\n *\n * ### Validate that the field has maximum of 5 characters\n *\n * ```ts\n * const control = new FormControl('Angular', Validators.maxLength(5));\n *\n * console.log(control.errors); // {maxlength: {requiredLength: 5, actualLength: 7}}\n * ```\n *\n * ```html\n * <input maxlength=\"5\">\n * ```\n *\n * @returns A validator function that returns an error map with the\n * `maxlength` property if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static maxLength(maxLength) {\n return maxLengthValidator(maxLength);\n }\n /**\n * @description\n * Validator that requires the control's value to match a regex pattern. This validator is also\n * provided by default if you use the HTML5 `pattern` attribute.\n *\n * @usageNotes\n *\n * ### Validate that the field only contains letters or spaces\n *\n * ```ts\n * const control = new FormControl('1', Validators.pattern('[a-zA-Z ]*'));\n *\n * console.log(control.errors); // {pattern: {requiredPattern: '^[a-zA-Z ]*$', actualValue: '1'}}\n * ```\n *\n * ```html\n * <input pattern=\"[a-zA-Z ]*\">\n * ```\n *\n * ### Pattern matching with the global or sticky flag\n *\n * `RegExp` objects created with the `g` or `y` flags that are passed into `Validators.pattern`\n * can produce different results on the same input when validations are run consecutively. This is\n * due to how the behavior of `RegExp.prototype.test` is\n * specified in [ECMA-262](https://tc39.es/ecma262/#sec-regexpbuiltinexec)\n * (`RegExp` preserves the index of the last match when the global or sticky flag is used).\n * Due to this behavior, it is recommended that when using\n * `Validators.pattern` you **do not** pass in a `RegExp` object with either the global or sticky\n * flag enabled.\n *\n * ```ts\n * // Not recommended (since the `g` flag is used)\n * const controlOne = new FormControl('1', Validators.pattern(/foo/g));\n *\n * // Good\n * const controlTwo = new FormControl('1', Validators.pattern(/foo/));\n * ```\n *\n * @param pattern A regular expression to be used as is to test the values, or a string.\n * If a string is passed, the `^` character is prepended and the `$` character is\n * appended to the provided string (if not already present), and the resulting regular\n * expression is used to test the values.\n *\n * @returns A validator function that returns an error map with the\n * `pattern` property if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static pattern(pattern) {\n return patternValidator(pattern);\n }\n /**\n * @description\n * Validator that performs no operation.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static nullValidator(control) {\n return nullValidator(control);\n }\n static compose(validators) {\n return compose(validators);\n }\n /**\n * @description\n * Compose multiple async validators into a single function that returns the union\n * of the individual error objects for the provided control.\n *\n * @returns A validator function that returns an error map with the\n * merged error objects of the async validators if the validation check fails, otherwise `null`.\n *\n * @see {@link /api/forms/AbstractControl#updateValueAndValidity updateValueAndValidity}\n *\n */\n static composeAsync(validators) {\n return composeAsync(validators);\n }\n}\n/**\n * Validator that requires the control's value to be greater than or equal to the provided number.\n * See `Validators.min` for additional information.\n */\nfunction minValidator(min) {\n return control => {\n if (control.value == null || min == null) {\n return null; // don't validate empty values to allow optional controls\n }\n const value = parseFloat(control.value);\n // Controls with NaN values after parsing should be treated as not having a\n // minimum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-min\n return !isNaN(value) && value < min ? {\n 'min': {\n 'min': min,\n 'actual': control.value\n }\n } : null;\n };\n}\n/**\n * Validator that requires the control's value to be less than or equal to the provided number.\n * See `Validators.max` for additional information.\n */\nfunction maxValidator(max) {\n return control => {\n if (control.value == null || max == null) {\n return null; // don't validate empty values to allow optional controls\n }\n const value = parseFloat(control.value);\n // Controls with NaN values after parsing should be treated as not having a\n // maximum, per the HTML forms spec: https://www.w3.org/TR/html5/forms.html#attr-input-max\n return !isNaN(value) && value > max ? {\n 'max': {\n 'max': max,\n 'actual': control.value\n }\n } : null;\n };\n}\n/**\n * Validator that requires the control have a non-empty value.\n * See `Validators.required` for additional information.\n */\nfunction requiredValidator(control) {\n return isEmptyInputValue(control.value) ? {\n 'required': true\n } : null;\n}\n/**\n * Validator that requires the control's value be true. This validator is commonly\n * used for required checkboxes.\n * See `Validators.requiredTrue` for additional information.\n */\nfunction requiredTrueValidator(control) {\n return control.value === true ? null : {\n 'required': true\n };\n}\n/**\n * Validator that requires the control's value pass an email validation test.\n * See `Validators.email` for additional information.\n */\nfunction emailValidator(control) {\n if (isEmptyInputValue(control.value)) {\n return null; // don't validate empty values to allow optional controls\n }\n return EMAIL_REGEXP.test(control.value) ? null : {\n 'email': true\n };\n}\n/**\n * Validator that requires the number of items in the control's value to be greater than or equal\n * to the provided minimum length. See `Validators.minLength` for additional information.\n *\n * The minLengthValidator respects every length property in an object, regardless of whether it's an array.\n * For example, the object {id: 1, length: 0, width: 0} should be validated.\n */\nfunction minLengthValidator(minLength) {\n return control => {\n const length = control.value?.length ?? lengthOrSize(control.value);\n if (length === null || length === 0) {\n // don't validate empty values to allow optional controls\n // don't validate values without `length` or `size` property\n return null;\n }\n return length < minLength ? {\n 'minlength': {\n 'requiredLength': minLength,\n 'actualLength': length\n }\n } : null;\n };\n}\n/**\n * Validator that requires the number of items in the control's value to be less than or equal\n * to the provided maximum length. See `Validators.maxLength` for additional information.\n *\n * The maxLengthValidator respects every length property in an object, regardless of whether it's an array.\n * For example, the object {id: 1, length: 0, width: 0} should be validated.\n */\nfunction maxLengthValidator(maxLength) {\n return control => {\n const length = control.value?.length ?? lengthOrSize(control.value);\n if (length !== null && length > maxLength) {\n return {\n 'maxlength': {\n 'requiredLength': maxLength,\n 'actualLength': length\n }\n };\n }\n return null;\n };\n}\n/**\n * Validator that requires the control's value to match a regex pattern.\n * See `Validators.pattern` for additional information.\n */\nfunction patternValidator(pattern) {\n if (!pattern) return nullValidator;\n let regex;\n let regexStr;\n if (typeof pattern === 'string') {\n regexStr = '';\n if (pattern.charAt(0) !== '^') regexStr += '^';\n regexStr += pattern;\n if (pattern.charAt(pattern.length - 1) !== '$') regexStr += '$';\n regex = new RegExp(regexStr);\n } else {\n regexStr = pattern.toString();\n regex = pattern;\n }\n return control => {\n if (isEmptyInputValue(control.value)) {\n return null; // don't validate empty values to allow optional controls\n }\n const value = control.value;\n return regex.test(value) ? null : {\n 'pattern': {\n 'requiredPattern': regexStr,\n 'actualValue': value\n }\n };\n };\n}\n/**\n * Function that has `ValidatorFn` shape, but performs no operation.\n */\nfunction nullValidator(control) {\n return null;\n}\nfunction isPresent(o) {\n return o != null;\n}\nfunction toObservable(value) {\n const obs = ɵisPromise(value) ? from(value) : value;\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !ɵisSubscribable(obs)) {\n let errorMessage = `Expected async validator to return Promise or Observable.`;\n // A synchronous validator will return object or null.\n if (typeof value === 'object') {\n errorMessage += ' Are you using a synchronous validator where an async validator is expected?';\n }\n throw new ɵRuntimeError(-1101 /* RuntimeErrorCode.WRONG_VALIDATOR_RETURN_TYPE */, errorMessage);\n }\n return obs;\n}\nfunction mergeErrors(arrayOfErrors) {\n let res = {};\n arrayOfErrors.forEach(errors => {\n res = errors != null ? {\n ...res,\n ...errors\n } : res;\n });\n return Object.keys(res).length === 0 ? null : res;\n}\nfunction executeValidators(control, validators) {\n return validators.map(validator => validator(control));\n}\nfunction isValidatorFn(validator) {\n return !validator.validate;\n}\n/**\n * Given the list of validators that may contain both functions as well as classes, return the list\n * of validator functions (convert validator classes into validator functions). This is needed to\n * have consistent structure in validators list before composing them.\n *\n * @param validators The set of validators that may contain validators both in plain function form\n * as well as represented as a validator class.\n */\nfunction normalizeValidators(validators) {\n return validators.map(validator => {\n return isValidatorFn(validator) ? validator : c => validator.validate(c);\n });\n}\n/**\n * Merges synchronous validators into a single validator function.\n * See `Validators.compose` for additional information.\n */\nfunction compose(validators) {\n if (!validators) return null;\n const presentValidators = validators.filter(isPresent);\n if (presentValidators.length == 0) return null;\n return function (control) {\n return mergeErrors(executeValidators(control, presentValidators));\n };\n}\n/**\n * Accepts a list of validators of different possible shapes (`Validator` and `ValidatorFn`),\n * normalizes the list (converts everything to `ValidatorFn`) and merges them into a single\n * validator function.\n */\nfunction composeValidators(validators) {\n return validators != null ? compose(normalizeValidators(validators)) : null;\n}\n/**\n * Merges asynchronous validators into a single validator function.\n * See `Validators.composeAsync` for additional information.\n */\nfunction composeAsync(validators) {\n if (!validators) return null;\n const presentValidators = validators.filter(isPresent);\n if (presentValidators.length == 0) return null;\n return function (control) {\n const observables = executeValidators(control, presentValidators).map(toObservable);\n return forkJoin(observables).pipe(map(mergeErrors));\n };\n}\n/**\n * Accepts a list of async validators of different possible shapes (`AsyncValidator` and\n * `AsyncValidatorFn`), normalizes the list (converts everything to `AsyncValidatorFn`) and merges\n * them into a single validator function.\n */\nfunction composeAsyncValidators(validators) {\n return validators != null ? composeAsync(normalizeValidators(validators)) : null;\n}\n/**\n * Merges raw control validators with a given directive validator and returns the combined list of\n * validators as an array.\n */\nfunction mergeValidators(controlValidators, dirValidator) {\n if (controlValidators === null) return [dirValidator];\n return Array.isArray(controlValidators) ? [...controlValidators, dirValidator] : [controlValidators, dirValidator];\n}\n/**\n * Retrieves the list of raw synchronous validators attached to a given control.\n */\nfunction getControlValidators(control) {\n return control._rawValidators;\n}\n/**\n * Retrieves the list of raw asynchronous validators attached to a given control.\n */\nfunction getControlAsyncValidators(control) {\n return control._rawAsyncValidators;\n}\n/**\n * Accepts a singleton validator, an array, or null, and returns an array type with the provided\n * validators.\n *\n * @param validators A validator, validators, or null.\n * @returns A validators array.\n */\nfunction makeValidatorsArray(validators) {\n if (!validators) return [];\n return Array.isArray(validators) ? validators : [validators];\n}\n/**\n * Determines whether a validator or validators array has a given validator.\n *\n * @param validators The validator or validators to compare against.\n * @param validator The validator to check.\n * @returns Whether the validator is present.\n */\nfunction hasValidator(validators, validator) {\n return Array.isArray(validators) ? validators.includes(validator) : validators === validator;\n}\n/**\n * Combines two arrays of validators into one. If duplicates are provided, only one will be added.\n *\n * @param validators The new validators.\n * @param currentValidators The base array of current validators.\n * @returns An array of validators.\n */\nfunction addValidators(validators, currentValidators) {\n const current = makeValidatorsArray(currentValidators);\n const validatorsToAdd = makeValidatorsArray(validators);\n validatorsToAdd.forEach(v => {\n // Note: if there are duplicate entries in the new validators array,\n // only the first one would be added to the current list of validators.\n // Duplicate ones would be ignored since `hasValidator` would detect\n // the presence of a validator function and we update the current list in place.\n if (!hasValidator(current, v)) {\n current.push(v);\n }\n });\n return current;\n}\nfunction removeValidators(validators, currentValidators) {\n return makeValidatorsArray(currentValidators).filter(v => !hasValidator(validators, v));\n}\n\n/**\n * @description\n * Base class for control directives.\n *\n * This class is only used internally in the `ReactiveFormsModule` and the `FormsModule`.\n *\n * @publicApi\n */\nclass AbstractControlDirective {\n /**\n * @description\n * Reports the value of the control if it is present, otherwise null.\n */\n get value() {\n return this.control ? this.control.value : null;\n }\n /**\n * @description\n * Reports whether the control is valid. A control is considered valid if no\n * validation errors exist with the current value.\n * If the control is not present, null is returned.\n */\n get valid() {\n return this.control ? this.control.valid : null;\n }\n /**\n * @description\n * Reports whether the control is invalid, meaning that an error exists in the input value.\n * If the control is not present, null is returned.\n */\n get invalid() {\n return this.control ? this.control.invalid : null;\n }\n /**\n * @description\n * Reports whether a control is pending, meaning that async validation is occurring and\n * errors are not yet available for the input value. If the control is not present, null is\n * returned.\n */\n get pending() {\n return this.control ? this.control.pending : null;\n }\n /**\n * @description\n * Reports whether the control is disabled, meaning that the control is disabled\n * in the UI and is exempt from validation checks and excluded from aggregate\n * values of ancestor controls. If the control is not present, null is returned.\n */\n get disabled() {\n return this.control ? this.control.disabled : null;\n }\n /**\n * @description\n * Reports whether the control is enabled, meaning that the control is included in ancestor\n * calculations of validity or value. If the control is not present, null is returned.\n */\n get enabled() {\n return this.control ? this.control.enabled : null;\n }\n /**\n * @description\n * Reports the control's validation errors. If the control is not present, null is returned.\n */\n get errors() {\n return this.control ? this.control.errors : null;\n }\n /**\n * @description\n * Reports whether the control is pristine, meaning that the user has not yet changed\n * the value in the UI. If the control is not present, null is returned.\n */\n get pristine() {\n return this.control ? this.control.pristine : null;\n }\n /**\n * @description\n * Reports whether the control is dirty, meaning that the user has changed\n * the value in the UI. If the control is not present, null is returned.\n */\n get dirty() {\n return this.control ? this.control.dirty : null;\n }\n /**\n * @description\n * Reports whether the control is touched, meaning that the user has triggered\n * a `blur` event on it. If the control is not present, null is returned.\n */\n get touched() {\n return this.control ? this.control.touched : null;\n }\n /**\n * @description\n * Reports the validation status of the control. Possible values include:\n * 'VALID', 'INVALID', 'DISABLED', and 'PENDING'.\n * If the control is not present, null is returned.\n */\n get status() {\n return this.control ? this.control.status : null;\n }\n /**\n * @description\n * Reports whether the control is untouched, meaning that the user has not yet triggered\n * a `blur` event on it. If the control is not present, null is returned.\n */\n get untouched() {\n return this.control ? this.control.untouched : null;\n }\n /**\n * @description\n * Returns a multicasting observable that emits a validation status whenever it is\n * calculated for the control. If the control is not present, null is returned.\n */\n get statusChanges() {\n return this.control ? this.control.statusChanges : null;\n }\n /**\n * @description\n * Returns a multicasting observable of value changes for the control that emits every time the\n * value of the control changes in the UI or programmatically.\n * If the control is not present, null is returned.\n */\n get valueChanges() {\n return this.control ? this.control.valueChanges : null;\n }\n /**\n * @description\n * Returns an array that represents the path from the top-level form to this control.\n * Each index is the string name of the control on that level.\n */\n get path() {\n return null;\n }\n /**\n * Contains the result of merging synchronous validators into a single validator function\n * (combined using `Validators.compose`).\n */\n _composedValidatorFn;\n /**\n * Contains the result of merging asynchronous validators into a single validator function\n * (combined using `Validators.composeAsync`).\n */\n _composedAsyncValidatorFn;\n /**\n * Set of synchronous validators as they were provided while calling `setValidators` function.\n * @internal\n */\n _rawValidators = [];\n /**\n * Set of asynchronous validators as they were provided while calling `setAsyncValidators`\n * function.\n * @internal\n */\n _rawAsyncValidators = [];\n /**\n * Sets synchronous validators for this directive.\n * @internal\n */\n _setValidators(validators) {\n this._rawValidators = validators || [];\n this._composedValidatorFn = composeValidators(this._rawValidators);\n }\n /**\n * Sets asynchronous validators for this directive.\n * @internal\n */\n _setAsyncValidators(validators) {\n this._rawAsyncValidators = validators || [];\n this._composedAsyncValidatorFn = composeAsyncValidators(this._rawAsyncValidators);\n }\n /**\n * @description\n * Synchronous validator function composed of all the synchronous validators registered with this\n * directive.\n */\n get validator() {\n return this._composedValidatorFn || null;\n }\n /**\n * @description\n * Asynchronous validator function composed of all the asynchronous validators registered with\n * this directive.\n */\n get asyncValidator() {\n return this._composedAsyncValidatorFn || null;\n }\n /*\n * The set of callbacks to be invoked when directive instance is being destroyed.\n */\n _onDestroyCallbacks = [];\n /**\n * Internal function to register callbacks that should be invoked\n * when directive instance is being destroyed.\n * @internal\n */\n _registerOnDestroy(fn) {\n this._onDestroyCallbacks.push(fn);\n }\n /**\n * Internal function to invoke all registered \"on destroy\" callbacks.\n * Note: calling this function also clears the list of callbacks.\n * @internal\n */\n _invokeOnDestroyCallbacks() {\n this._onDestroyCallbacks.forEach(fn => fn());\n this._onDestroyCallbacks = [];\n }\n /**\n * @description\n * Resets the control with the provided value if the control is present.\n */\n reset(value = undefined) {\n if (this.control) this.control.reset(value);\n }\n /**\n * @description\n * Reports whether the control with the given path has the error specified.\n *\n * @param errorCode The code of the error to check\n * @param path A list of control names that designates how to move from the current control\n * to the control that should be queried for errors.\n *\n * @usageNotes\n * For example, for the following `FormGroup`:\n *\n * ```ts\n * form = new FormGroup({\n * address: new FormGroup({ street: new FormControl() })\n * });\n * ```\n *\n * The path to the 'street' control from the root form would be 'address' -> 'street'.\n *\n * It can be provided to this method in one of two formats:\n *\n * 1. An array of string control names, e.g. `['address', 'street']`\n * 1. A period-delimited list of control names in one string, e.g. `'address.street'`\n *\n * If no path is given, this method checks for the error on the current control.\n *\n * @returns whether the given error is present in the control at the given path.\n *\n * If the control is not present, false is returned.\n */\n hasError(errorCode, path) {\n return this.control ? this.control.hasError(errorCode, path) : false;\n }\n /**\n * @description\n * Reports error data for the control with the given path.\n *\n * @param errorCode The code of the error to check\n * @param path A list of control names that designates how to move from the current control\n * to the control that should be queried for errors.\n *\n * @usageNotes\n * For example, for the following `FormGroup`:\n *\n * ```ts\n * form = new FormGroup({\n * address: new FormGroup({ street: new FormControl() })\n * });\n * ```\n *\n * The path to the 'street' control from the root form would be 'address' -> 'street'.\n *\n * It can be provided to this method in one of two formats:\n *\n * 1. An array of string control names, e.g. `['address', 'street']`\n * 1. A period-delimited list of control names in one string, e.g. `'address.street'`\n *\n * @returns error data for that particular error. If the control or error is not present,\n * null is returned.\n */\n getError(errorCode, path) {\n return this.control ? this.control.getError(errorCode, path) : null;\n }\n}\n\n/**\n * @description\n * A base class for directives that contain multiple registered instances of `NgControl`.\n * Only used by the forms module.\n *\n * @publicApi\n */\nclass ControlContainer extends AbstractControlDirective {\n /**\n * @description\n * The name for the control\n */\n // TODO(issue/24571): remove '!'.\n name;\n /**\n * @description\n * The top-level form directive for the control.\n */\n get formDirective() {\n return null;\n }\n /**\n * @description\n * The path to this group.\n */\n get path() {\n return null;\n }\n}\n\n/**\n * @description\n * A base class that all `FormControl`-based directives extend. It binds a `FormControl`\n * object to a DOM element.\n *\n * @publicApi\n */\nclass NgControl extends AbstractControlDirective {\n /**\n * @description\n * The parent form for the control.\n *\n * @internal\n */\n _parent = null;\n /**\n * @description\n * The name for the control\n */\n name = null;\n /**\n * @description\n * The value accessor for the control\n */\n valueAccessor = null;\n}\n\n// DO NOT REFACTOR!\n// Each status is represented by a separate function to make sure that\n// advanced Closure Compiler optimizations related to property renaming\n// can work correctly.\nclass AbstractControlStatus {\n _cd;\n constructor(cd) {\n this._cd = cd;\n }\n get isTouched() {\n // track the touched signal\n this._cd?.control?._touched?.();\n return !!this._cd?.control?.touched;\n }\n get isUntouched() {\n return !!this._cd?.control?.untouched;\n }\n get isPristine() {\n // track the pristine signal\n this._cd?.control?._pristine?.();\n return !!this._cd?.control?.pristine;\n }\n get isDirty() {\n // pristine signal already tracked above\n return !!this._cd?.control?.dirty;\n }\n get isValid() {\n // track the status signal\n this._cd?.control?._status?.();\n return !!this._cd?.control?.valid;\n }\n get isInvalid() {\n // status signal already tracked above\n return !!this._cd?.control?.invalid;\n }\n get isPending() {\n // status signal already tracked above\n return !!this._cd?.control?.pending;\n }\n get isSubmitted() {\n // track the submitted signal\n this._cd?._submitted?.();\n // We check for the `submitted` field from `NgForm` and `FormGroupDirective` classes, but\n // we avoid instanceof checks to prevent non-tree-shakable references to those types.\n return !!this._cd?.submitted;\n }\n}\nconst ngControlStatusHost = {\n '[class.ng-untouched]': 'isUntouched',\n '[class.ng-touched]': 'isTouched',\n '[class.ng-pristine]': 'isPristine',\n '[class.ng-dirty]': 'isDirty',\n '[class.ng-valid]': 'isValid',\n '[class.ng-invalid]': 'isInvalid',\n '[class.ng-pending]': 'isPending'\n};\nconst ngGroupStatusHost = {\n ...ngControlStatusHost,\n '[class.ng-submitted]': 'isSubmitted'\n};\n/**\n * @description\n * Directive automatically applied to Angular form controls that sets CSS classes\n * based on control status.\n *\n * @usageNotes\n *\n * ### CSS classes applied\n *\n * The following classes are applied as the properties become true:\n *\n * * ng-valid\n * * ng-invalid\n * * ng-pending\n * * ng-pristine\n * * ng-dirty\n * * ng-untouched\n * * ng-touched\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass NgControlStatus extends AbstractControlStatus {\n constructor(cd) {\n super(cd);\n }\n static ɵfac = function NgControlStatus_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgControlStatus)(i0.ɵɵdirectiveInject(NgControl, 2));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgControlStatus,\n selectors: [[\"\", \"formControlName\", \"\"], [\"\", \"ngModel\", \"\"], [\"\", \"formControl\", \"\"]],\n hostVars: 14,\n hostBindings: function NgControlStatus_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵclassProp(\"ng-untouched\", ctx.isUntouched)(\"ng-touched\", ctx.isTouched)(\"ng-pristine\", ctx.isPristine)(\"ng-dirty\", ctx.isDirty)(\"ng-valid\", ctx.isValid)(\"ng-invalid\", ctx.isInvalid)(\"ng-pending\", ctx.isPending);\n }\n },\n standalone: false,\n features: [i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgControlStatus, [{\n type: Directive,\n args: [{\n selector: '[formControlName],[ngModel],[formControl]',\n host: ngControlStatusHost,\n standalone: false\n }]\n }], () => [{\n type: NgControl,\n decorators: [{\n type: Self\n }]\n }], null);\n})();\n/**\n * @description\n * Directive automatically applied to Angular form groups that sets CSS classes\n * based on control status (valid/invalid/dirty/etc). On groups, this includes the additional\n * class ng-submitted.\n *\n * @see {@link NgControlStatus}\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass NgControlStatusGroup extends AbstractControlStatus {\n constructor(cd) {\n super(cd);\n }\n static ɵfac = function NgControlStatusGroup_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgControlStatusGroup)(i0.ɵɵdirectiveInject(ControlContainer, 10));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgControlStatusGroup,\n selectors: [[\"\", \"formGroupName\", \"\"], [\"\", \"formArrayName\", \"\"], [\"\", \"ngModelGroup\", \"\"], [\"\", \"formGroup\", \"\"], [\"form\", 3, \"ngNoForm\", \"\"], [\"\", \"ngForm\", \"\"]],\n hostVars: 16,\n hostBindings: function NgControlStatusGroup_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵclassProp(\"ng-untouched\", ctx.isUntouched)(\"ng-touched\", ctx.isTouched)(\"ng-pristine\", ctx.isPristine)(\"ng-dirty\", ctx.isDirty)(\"ng-valid\", ctx.isValid)(\"ng-invalid\", ctx.isInvalid)(\"ng-pending\", ctx.isPending)(\"ng-submitted\", ctx.isSubmitted);\n }\n },\n standalone: false,\n features: [i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgControlStatusGroup, [{\n type: Directive,\n args: [{\n selector: '[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]',\n host: ngGroupStatusHost,\n standalone: false\n }]\n }], () => [{\n type: ControlContainer,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }]\n }], null);\n})();\nconst formControlNameExample = `\n <div [formGroup]=\"myGroup\">\n <input formControlName=\"firstName\">\n </div>\n\n In your class:\n\n this.myGroup = new FormGroup({\n firstName: new FormControl()\n });`;\nconst formGroupNameExample = `\n <div [formGroup]=\"myGroup\">\n <div formGroupName=\"person\">\n <input formControlName=\"firstName\">\n </div>\n </div>\n\n In your class:\n\n this.myGroup = new FormGroup({\n person: new FormGroup({ firstName: new FormControl() })\n });`;\nconst formArrayNameExample = `\n <div [formGroup]=\"myGroup\">\n <div formArrayName=\"cities\">\n <div *ngFor=\"let city of cityArray.controls; index as i\">\n <input [formControlName]=\"i\">\n </div>\n </div>\n </div>\n\n In your class:\n\n this.cityArray = new FormArray([new FormControl('SF')]);\n this.myGroup = new FormGroup({\n cities: this.cityArray\n });`;\nconst ngModelGroupExample = `\n <form>\n <div ngModelGroup=\"person\">\n <input [(ngModel)]=\"person.name\" name=\"firstName\">\n </div>\n </form>`;\nconst ngModelWithFormGroupExample = `\n <div [formGroup]=\"myGroup\">\n <input formControlName=\"firstName\">\n <input [(ngModel)]=\"showMoreControls\" [ngModelOptions]=\"{standalone: true}\">\n </div>\n`;\nfunction controlParentException(nameOrIndex) {\n return new ɵRuntimeError(1050 /* RuntimeErrorCode.FORM_CONTROL_NAME_MISSING_PARENT */, `formControlName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n ${describeFormControl(nameOrIndex)}\n\n Example:\n\n ${formControlNameExample}`);\n}\nfunction describeFormControl(nameOrIndex) {\n if (nameOrIndex == null || nameOrIndex === '') {\n return '';\n }\n const valueType = typeof nameOrIndex === 'string' ? 'name' : 'index';\n return `Affected Form Control ${valueType}: \"${nameOrIndex}\"`;\n}\nfunction ngModelGroupException() {\n return new ɵRuntimeError(1051 /* RuntimeErrorCode.FORM_CONTROL_NAME_INSIDE_MODEL_GROUP */, `formControlName cannot be used with an ngModelGroup parent. It is only compatible with parents\n that also have a \"form\" prefix: formGroupName, formArrayName, or formGroup.\n\n Option 1: Update the parent to be formGroupName (reactive form strategy)\n\n ${formGroupNameExample}\n\n Option 2: Use ngModel instead of formControlName (template-driven strategy)\n\n ${ngModelGroupExample}`);\n}\nfunction missingFormException() {\n return new ɵRuntimeError(1052 /* RuntimeErrorCode.FORM_GROUP_MISSING_INSTANCE */, `formGroup expects a FormGroup instance. Please pass one in.\n\n Example:\n\n ${formControlNameExample}`);\n}\nfunction groupParentException() {\n return new ɵRuntimeError(1053 /* RuntimeErrorCode.FORM_GROUP_NAME_MISSING_PARENT */, `formGroupName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n ${formGroupNameExample}`);\n}\nfunction arrayParentException() {\n return new ɵRuntimeError(1054 /* RuntimeErrorCode.FORM_ARRAY_NAME_MISSING_PARENT */, `formArrayName must be used with a parent formGroup directive. You'll want to add a formGroup\n directive and pass it an existing FormGroup instance (you can create one in your class).\n\n Example:\n\n ${formArrayNameExample}`);\n}\nconst disabledAttrWarning = `\n It looks like you're using the disabled attribute with a reactive form directive. If you set disabled to true\n when you set up this control in your component class, the disabled attribute will actually be set in the DOM for\n you. We recommend using this approach to avoid 'changed after checked' errors.\n\n Example:\n // Specify the \\`disabled\\` property at control creation time:\n form = new FormGroup({\n first: new FormControl({value: 'Nancy', disabled: true}, Validators.required),\n last: new FormControl('Drew', Validators.required)\n });\n\n // Controls can also be enabled/disabled after creation:\n form.get('first')?.enable();\n form.get('last')?.disable();\n`;\nconst asyncValidatorsDroppedWithOptsWarning = `\n It looks like you're constructing using a FormControl with both an options argument and an\n async validators argument. Mixing these arguments will cause your async validators to be dropped.\n You should either put all your validators in the options object, or in separate validators\n arguments. For example:\n\n // Using validators arguments\n fc = new FormControl(42, Validators.required, myAsyncValidator);\n\n // Using AbstractControlOptions\n fc = new FormControl(42, {validators: Validators.required, asyncValidators: myAV});\n\n // Do NOT mix them: async validators will be dropped!\n fc = new FormControl(42, {validators: Validators.required}, /* Oops! */ myAsyncValidator);\n`;\nfunction ngModelWarning(directiveName) {\n return `\n It looks like you're using ngModel on the same form field as ${directiveName}.\n Support for using the ngModel input property and ngModelChange event with\n reactive form directives has been deprecated in Angular v6 and will be removed\n in a future version of Angular.\n\n For more information on this, see our API docs here:\n https://angular.io/api/forms/${directiveName === 'formControl' ? 'FormControlDirective' : 'FormControlName'}#use-with-ngmodel\n `;\n}\nfunction describeKey(isFormGroup, key) {\n return isFormGroup ? `with name: '${key}'` : `at index: ${key}`;\n}\nfunction noControlsError(isFormGroup) {\n return `\n There are no form controls registered with this ${isFormGroup ? 'group' : 'array'} yet. If you're using ngModel,\n you may want to check next tick (e.g. use setTimeout).\n `;\n}\nfunction missingControlError(isFormGroup, key) {\n return `Cannot find form control ${describeKey(isFormGroup, key)}`;\n}\nfunction missingControlValueError(isFormGroup, key) {\n return `Must supply a value for form control ${describeKey(isFormGroup, key)}`;\n}\n\n/**\n * Reports that a control is valid, meaning that no errors exist in the input value.\n *\n * @see {@link status}\n */\nconst VALID = 'VALID';\n/**\n * Reports that a control is invalid, meaning that an error exists in the input value.\n *\n * @see {@link status}\n */\nconst INVALID = 'INVALID';\n/**\n * Reports that a control is pending, meaning that async validation is occurring and\n * errors are not yet available for the input value.\n *\n * @see {@link markAsPending}\n * @see {@link status}\n */\nconst PENDING = 'PENDING';\n/**\n * Reports that a control is disabled, meaning that the control is exempt from ancestor\n * calculations of validity or value.\n *\n * @see {@link markAsDisabled}\n * @see {@link status}\n */\nconst DISABLED = 'DISABLED';\n/**\n * Base class for every event sent by `AbstractControl.events()`\n *\n * @publicApi\n */\nclass ControlEvent {}\n/**\n * Event fired when the value of a control changes.\n *\n * @publicApi\n */\nclass ValueChangeEvent extends ControlEvent {\n value;\n source;\n constructor(value, source) {\n super();\n this.value = value;\n this.source = source;\n }\n}\n/**\n * Event fired when the control's pristine state changes (pristine <=> dirty).\n *\n * @publicApi */\nclass PristineChangeEvent extends ControlEvent {\n pristine;\n source;\n constructor(pristine, source) {\n super();\n this.pristine = pristine;\n this.source = source;\n }\n}\n/**\n * Event fired when the control's touched status changes (touched <=> untouched).\n *\n * @publicApi\n */\nclass TouchedChangeEvent extends ControlEvent {\n touched;\n source;\n constructor(touched, source) {\n super();\n this.touched = touched;\n this.source = source;\n }\n}\n/**\n * Event fired when the control's status changes.\n *\n * @publicApi\n */\nclass StatusChangeEvent extends ControlEvent {\n status;\n source;\n constructor(status, source) {\n super();\n this.status = status;\n this.source = source;\n }\n}\n/**\n * Event fired when a form is submitted\n *\n * @publicApi\n */\nclass FormSubmittedEvent extends ControlEvent {\n source;\n constructor(source) {\n super();\n this.source = source;\n }\n}\n/**\n * Event fired when a form is reset.\n *\n * @publicApi\n */\nclass FormResetEvent extends ControlEvent {\n source;\n constructor(source) {\n super();\n this.source = source;\n }\n}\n/**\n * Gets validators from either an options object or given validators.\n */\nfunction pickValidators(validatorOrOpts) {\n return (isOptionsObj(validatorOrOpts) ? validatorOrOpts.validators : validatorOrOpts) || null;\n}\n/**\n * Creates validator function by combining provided validators.\n */\nfunction coerceToValidator(validator) {\n return Array.isArray(validator) ? composeValidators(validator) : validator || null;\n}\n/**\n * Gets async validators from either an options object or given validators.\n */\nfunction pickAsyncValidators(asyncValidator, validatorOrOpts) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (isOptionsObj(validatorOrOpts) && asyncValidator) {\n console.warn(asyncValidatorsDroppedWithOptsWarning);\n }\n }\n return (isOptionsObj(validatorOrOpts) ? validatorOrOpts.asyncValidators : asyncValidator) || null;\n}\n/**\n * Creates async validator function by combining provided async validators.\n */\nfunction coerceToAsyncValidator(asyncValidator) {\n return Array.isArray(asyncValidator) ? composeAsyncValidators(asyncValidator) : asyncValidator || null;\n}\nfunction isOptionsObj(validatorOrOpts) {\n return validatorOrOpts != null && !Array.isArray(validatorOrOpts) && typeof validatorOrOpts === 'object';\n}\nfunction assertControlPresent(parent, isGroup, key) {\n const controls = parent.controls;\n const collection = isGroup ? Object.keys(controls) : controls;\n if (!collection.length) {\n throw new ɵRuntimeError(1000 /* RuntimeErrorCode.NO_CONTROLS */, typeof ngDevMode === 'undefined' || ngDevMode ? noControlsError(isGroup) : '');\n }\n if (!controls[key]) {\n throw new ɵRuntimeError(1001 /* RuntimeErrorCode.MISSING_CONTROL */, typeof ngDevMode === 'undefined' || ngDevMode ? missingControlError(isGroup, key) : '');\n }\n}\nfunction assertAllValuesPresent(control, isGroup, value) {\n control._forEachChild((_, key) => {\n if (value[key] === undefined) {\n throw new ɵRuntimeError(1002 /* RuntimeErrorCode.MISSING_CONTROL_VALUE */, typeof ngDevMode === 'undefined' || ngDevMode ? missingControlValueError(isGroup, key) : '');\n }\n });\n}\n/**\n * This is the base class for `FormControl`, `FormGroup`, and `FormArray`.\n *\n * It provides some of the shared behavior that all controls and groups of controls have, like\n * running validators, calculating status, and resetting state. It also defines the properties\n * that are shared between all sub-classes, like `value`, `valid`, and `dirty`. It shouldn't be\n * instantiated directly.\n *\n * The first type parameter TValue represents the value type of the control (`control.value`).\n * The optional type parameter TRawValue represents the raw value type (`control.getRawValue()`).\n *\n * @see [Forms Guide](guide/forms)\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n * @see [Dynamic Forms Guide](guide/forms/dynamic-forms)\n *\n * @publicApi\n */\nclass AbstractControl {\n /** @internal */\n _pendingDirty = false;\n /**\n * Indicates that a control has its own pending asynchronous validation in progress.\n * It also stores if the control should emit events when the validation status changes.\n *\n * @internal\n */\n _hasOwnPendingAsyncValidator = null;\n /** @internal */\n _pendingTouched = false;\n /** @internal */\n _onCollectionChange = () => {};\n /** @internal */\n _updateOn;\n _parent = null;\n _asyncValidationSubscription;\n /**\n * Contains the result of merging synchronous validators into a single validator function\n * (combined using `Validators.compose`).\n *\n * @internal\n */\n _composedValidatorFn;\n /**\n * Contains the result of merging asynchronous validators into a single validator function\n * (combined using `Validators.composeAsync`).\n *\n * @internal\n */\n _composedAsyncValidatorFn;\n /**\n * Synchronous validators as they were provided:\n * - in `AbstractControl` constructor\n * - as an argument while calling `setValidators` function\n * - while calling the setter on the `validator` field (e.g. `control.validator = validatorFn`)\n *\n * @internal\n */\n _rawValidators;\n /**\n * Asynchronous validators as they were provided:\n * - in `AbstractControl` constructor\n * - as an argument while calling `setAsyncValidators` function\n * - while calling the setter on the `asyncValidator` field (e.g. `control.asyncValidator =\n * asyncValidatorFn`)\n *\n * @internal\n */\n _rawAsyncValidators;\n /**\n * The current value of the control.\n *\n * * For a `FormControl`, the current value.\n * * For an enabled `FormGroup`, the values of enabled controls as an object\n * with a key-value pair for each member of the group.\n * * For a disabled `FormGroup`, the values of all controls as an object\n * with a key-value pair for each member of the group.\n * * For a `FormArray`, the values of enabled controls as an array.\n *\n */\n value;\n /**\n * Initialize the AbstractControl instance.\n *\n * @param validators The function or array of functions that is used to determine the validity of\n * this control synchronously.\n * @param asyncValidators The function or array of functions that is used to determine validity of\n * this control asynchronously.\n */\n constructor(validators, asyncValidators) {\n this._assignValidators(validators);\n this._assignAsyncValidators(asyncValidators);\n }\n /**\n * Returns the function that is used to determine the validity of this control synchronously.\n * If multiple validators have been added, this will be a single composed function.\n * See `Validators.compose()` for additional information.\n */\n get validator() {\n return this._composedValidatorFn;\n }\n set validator(validatorFn) {\n this._rawValidators = this._composedValidatorFn = validatorFn;\n }\n /**\n * Returns the function that is used to determine the validity of this control asynchronously.\n * If multiple validators have been added, this will be a single composed function.\n * See `Validators.compose()` for additional information.\n */\n get asyncValidator() {\n return this._composedAsyncValidatorFn;\n }\n set asyncValidator(asyncValidatorFn) {\n this._rawAsyncValidators = this._composedAsyncValidatorFn = asyncValidatorFn;\n }\n /**\n * The parent control.\n */\n get parent() {\n return this._parent;\n }\n /**\n * The validation status of the control.\n *\n * @see {@link FormControlStatus}\n *\n * These status values are mutually exclusive, so a control cannot be\n * both valid AND invalid or invalid AND disabled.\n */\n get status() {\n return untracked(this.statusReactive);\n }\n set status(v) {\n untracked(() => this.statusReactive.set(v));\n }\n /** @internal */\n _status = computed(() => this.statusReactive());\n statusReactive = signal(undefined);\n /**\n * A control is `valid` when its `status` is `VALID`.\n *\n * @see {@link AbstractControl.status}\n *\n * @returns True if the control has passed all of its validation tests,\n * false otherwise.\n */\n get valid() {\n return this.status === VALID;\n }\n /**\n * A control is `invalid` when its `status` is `INVALID`.\n *\n * @see {@link AbstractControl.status}\n *\n * @returns True if this control has failed one or more of its validation checks,\n * false otherwise.\n */\n get invalid() {\n return this.status === INVALID;\n }\n /**\n * A control is `pending` when its `status` is `PENDING`.\n *\n * @see {@link AbstractControl.status}\n *\n * @returns True if this control is in the process of conducting a validation check,\n * false otherwise.\n */\n get pending() {\n return this.status == PENDING;\n }\n /**\n * A control is `disabled` when its `status` is `DISABLED`.\n *\n * Disabled controls are exempt from validation checks and\n * are not included in the aggregate value of their ancestor\n * controls.\n *\n * @see {@link AbstractControl.status}\n *\n * @returns True if the control is disabled, false otherwise.\n */\n get disabled() {\n return this.status === DISABLED;\n }\n /**\n * A control is `enabled` as long as its `status` is not `DISABLED`.\n *\n * @returns True if the control has any status other than 'DISABLED',\n * false if the status is 'DISABLED'.\n *\n * @see {@link AbstractControl.status}\n *\n */\n get enabled() {\n return this.status !== DISABLED;\n }\n /**\n * An object containing any errors generated by failing validation,\n * or null if there are no errors.\n */\n errors;\n /**\n * A control is `pristine` if the user has not yet changed\n * the value in the UI.\n *\n * @returns True if the user has not yet changed the value in the UI; compare `dirty`.\n * Programmatic changes to a control's value do not mark it dirty.\n */\n get pristine() {\n return untracked(this.pristineReactive);\n }\n set pristine(v) {\n untracked(() => this.pristineReactive.set(v));\n }\n /** @internal */\n _pristine = computed(() => this.pristineReactive());\n pristineReactive = signal(true);\n /**\n * A control is `dirty` if the user has changed the value\n * in the UI.\n *\n * @returns True if the user has changed the value of this control in the UI; compare `pristine`.\n * Programmatic changes to a control's value do not mark it dirty.\n */\n get dirty() {\n return !this.pristine;\n }\n /**\n * True if the control is marked as `touched`.\n *\n * A control is marked `touched` once the user has triggered\n * a `blur` event on it.\n */\n get touched() {\n return untracked(this.touchedReactive);\n }\n set touched(v) {\n untracked(() => this.touchedReactive.set(v));\n }\n /** @internal */\n _touched = computed(() => this.touchedReactive());\n touchedReactive = signal(false);\n /**\n * True if the control has not been marked as touched\n *\n * A control is `untouched` if the user has not yet triggered\n * a `blur` event on it.\n */\n get untouched() {\n return !this.touched;\n }\n /**\n * Exposed as observable, see below.\n *\n * @internal\n */\n _events = new Subject();\n /**\n * A multicasting observable that emits an event every time the state of the control changes.\n * It emits for value, status, pristine or touched changes.\n *\n * **Note**: On value change, the emit happens right after a value of this control is updated. The\n * value of a parent control (for example if this FormControl is a part of a FormGroup) is updated\n * later, so accessing a value of a parent control (using the `value` property) from the callback\n * of this event might result in getting a value that has not been updated yet. Subscribe to the\n * `events` of the parent control instead.\n * For other event types, the events are emitted after the parent control has been updated.\n *\n */\n events = this._events.asObservable();\n /**\n * A multicasting observable that emits an event every time the value of the control changes, in\n * the UI or programmatically. It also emits an event each time you call enable() or disable()\n * without passing along {emitEvent: false} as a function argument.\n *\n * **Note**: the emit happens right after a value of this control is updated. The value of a\n * parent control (for example if this FormControl is a part of a FormGroup) is updated later, so\n * accessing a value of a parent control (using the `value` property) from the callback of this\n * event might result in getting a value that has not been updated yet. Subscribe to the\n * `valueChanges` event of the parent control instead.\n */\n valueChanges;\n /**\n * A multicasting observable that emits an event every time the validation `status` of the control\n * recalculates.\n *\n * @see {@link FormControlStatus}\n * @see {@link AbstractControl.status}\n */\n statusChanges;\n /**\n * Reports the update strategy of the `AbstractControl` (meaning\n * the event on which the control updates itself).\n * Possible values: `'change'` | `'blur'` | `'submit'`\n * Default value: `'change'`\n */\n get updateOn() {\n return this._updateOn ? this._updateOn : this.parent ? this.parent.updateOn : 'change';\n }\n /**\n * Sets the synchronous validators that are active on this control. Calling\n * this overwrites any existing synchronous validators.\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n * If you want to add a new validator without affecting existing ones, consider\n * using `addValidators()` method instead.\n */\n setValidators(validators) {\n this._assignValidators(validators);\n }\n /**\n * Sets the asynchronous validators that are active on this control. Calling this\n * overwrites any existing asynchronous validators.\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n * If you want to add a new validator without affecting existing ones, consider\n * using `addAsyncValidators()` method instead.\n */\n setAsyncValidators(validators) {\n this._assignAsyncValidators(validators);\n }\n /**\n * Add a synchronous validator or validators to this control, without affecting other validators.\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n * Adding a validator that already exists will have no effect. If duplicate validator functions\n * are present in the `validators` array, only the first instance would be added to a form\n * control.\n *\n * @param validators The new validator function or functions to add to this control.\n */\n addValidators(validators) {\n this.setValidators(addValidators(validators, this._rawValidators));\n }\n /**\n * Add an asynchronous validator or validators to this control, without affecting other\n * validators.\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n * Adding a validator that already exists will have no effect.\n *\n * @param validators The new asynchronous validator function or functions to add to this control.\n */\n addAsyncValidators(validators) {\n this.setAsyncValidators(addValidators(validators, this._rawAsyncValidators));\n }\n /**\n * Remove a synchronous validator from this control, without affecting other validators.\n * Validators are compared by function reference; you must pass a reference to the exact same\n * validator function as the one that was originally set. If a provided validator is not found,\n * it is ignored.\n *\n * @usageNotes\n *\n * ### Reference to a ValidatorFn\n *\n * ```\n * // Reference to the RequiredValidator\n * const ctrl = new FormControl<string | null>('', Validators.required);\n * ctrl.removeValidators(Validators.required);\n *\n * // Reference to anonymous function inside MinValidator\n * const minValidator = Validators.min(3);\n * const ctrl = new FormControl<string | null>('', minValidator);\n * expect(ctrl.hasValidator(minValidator)).toEqual(true)\n * expect(ctrl.hasValidator(Validators.min(3))).toEqual(false)\n *\n * ctrl.removeValidators(minValidator);\n * ```\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n * @param validators The validator or validators to remove.\n */\n removeValidators(validators) {\n this.setValidators(removeValidators(validators, this._rawValidators));\n }\n /**\n * Remove an asynchronous validator from this control, without affecting other validators.\n * Validators are compared by function reference; you must pass a reference to the exact same\n * validator function as the one that was originally set. If a provided validator is not found, it\n * is ignored.\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n * @param validators The asynchronous validator or validators to remove.\n */\n removeAsyncValidators(validators) {\n this.setAsyncValidators(removeValidators(validators, this._rawAsyncValidators));\n }\n /**\n * Check whether a synchronous validator function is present on this control. The provided\n * validator must be a reference to the exact same function that was provided.\n *\n * @usageNotes\n *\n * ### Reference to a ValidatorFn\n *\n * ```\n * // Reference to the RequiredValidator\n * const ctrl = new FormControl<number | null>(0, Validators.required);\n * expect(ctrl.hasValidator(Validators.required)).toEqual(true)\n *\n * // Reference to anonymous function inside MinValidator\n * const minValidator = Validators.min(3);\n * const ctrl = new FormControl<number | null>(0, minValidator);\n * expect(ctrl.hasValidator(minValidator)).toEqual(true)\n * expect(ctrl.hasValidator(Validators.min(3))).toEqual(false)\n * ```\n *\n * @param validator The validator to check for presence. Compared by function reference.\n * @returns Whether the provided validator was found on this control.\n */\n hasValidator(validator) {\n return hasValidator(this._rawValidators, validator);\n }\n /**\n * Check whether an asynchronous validator function is present on this control. The provided\n * validator must be a reference to the exact same function that was provided.\n *\n * @param validator The asynchronous validator to check for presence. Compared by function\n * reference.\n * @returns Whether the provided asynchronous validator was found on this control.\n */\n hasAsyncValidator(validator) {\n return hasValidator(this._rawAsyncValidators, validator);\n }\n /**\n * Empties out the synchronous validator list.\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n */\n clearValidators() {\n this.validator = null;\n }\n /**\n * Empties out the async validator list.\n *\n * When you add or remove a validator at run time, you must call\n * `updateValueAndValidity()` for the new validation to take effect.\n *\n */\n clearAsyncValidators() {\n this.asyncValidator = null;\n }\n markAsTouched(opts = {}) {\n const changed = this.touched === false;\n this.touched = true;\n const sourceControl = opts.sourceControl ?? this;\n if (this._parent && !opts.onlySelf) {\n this._parent.markAsTouched({\n ...opts,\n sourceControl\n });\n }\n if (changed && opts.emitEvent !== false) {\n this._events.next(new TouchedChangeEvent(true, sourceControl));\n }\n }\n /**\n * Marks the control and all its descendant controls as `touched`.\n * @see {@link markAsTouched()}\n *\n * @param opts Configuration options that determine how the control propagates changes\n * and emits events after marking is applied.\n * * `emitEvent`: When true or not supplied (the default), the `events`\n * observable emits a `TouchedChangeEvent` with the `touched` property being `true`.\n * When false, no events are emitted.\n */\n markAllAsTouched(opts = {}) {\n this.markAsTouched({\n onlySelf: true,\n emitEvent: opts.emitEvent,\n sourceControl: this\n });\n this._forEachChild(control => control.markAllAsTouched(opts));\n }\n markAsUntouched(opts = {}) {\n const changed = this.touched === true;\n this.touched = false;\n this._pendingTouched = false;\n const sourceControl = opts.sourceControl ?? this;\n this._forEachChild(control => {\n control.markAsUntouched({\n onlySelf: true,\n emitEvent: opts.emitEvent,\n sourceControl\n });\n });\n if (this._parent && !opts.onlySelf) {\n this._parent._updateTouched(opts, sourceControl);\n }\n if (changed && opts.emitEvent !== false) {\n this._events.next(new TouchedChangeEvent(false, sourceControl));\n }\n }\n markAsDirty(opts = {}) {\n const changed = this.pristine === true;\n this.pristine = false;\n const sourceControl = opts.sourceControl ?? this;\n if (this._parent && !opts.onlySelf) {\n this._parent.markAsDirty({\n ...opts,\n sourceControl\n });\n }\n if (changed && opts.emitEvent !== false) {\n this._events.next(new PristineChangeEvent(false, sourceControl));\n }\n }\n markAsPristine(opts = {}) {\n const changed = this.pristine === false;\n this.pristine = true;\n this._pendingDirty = false;\n const sourceControl = opts.sourceControl ?? this;\n this._forEachChild(control => {\n /** We don't propagate the source control downwards */\n control.markAsPristine({\n onlySelf: true,\n emitEvent: opts.emitEvent\n });\n });\n if (this._parent && !opts.onlySelf) {\n this._parent._updatePristine(opts, sourceControl);\n }\n if (changed && opts.emitEvent !== false) {\n this._events.next(new PristineChangeEvent(true, sourceControl));\n }\n }\n markAsPending(opts = {}) {\n this.status = PENDING;\n const sourceControl = opts.sourceControl ?? this;\n if (opts.emitEvent !== false) {\n this._events.next(new StatusChangeEvent(this.status, sourceControl));\n this.statusChanges.emit(this.status);\n }\n if (this._parent && !opts.onlySelf) {\n this._parent.markAsPending({\n ...opts,\n sourceControl\n });\n }\n }\n disable(opts = {}) {\n // If parent has been marked artificially dirty we don't want to re-calculate the\n // parent's dirtiness based on the children.\n const skipPristineCheck = this._parentMarkedDirty(opts.onlySelf);\n this.status = DISABLED;\n this.errors = null;\n this._forEachChild(control => {\n /** We don't propagate the source control downwards */\n control.disable({\n ...opts,\n onlySelf: true\n });\n });\n this._updateValue();\n const sourceControl = opts.sourceControl ?? this;\n if (opts.emitEvent !== false) {\n this._events.next(new ValueChangeEvent(this.value, sourceControl));\n this._events.next(new StatusChangeEvent(this.status, sourceControl));\n this.valueChanges.emit(this.value);\n this.statusChanges.emit(this.status);\n }\n this._updateAncestors({\n ...opts,\n skipPristineCheck\n }, this);\n this._onDisabledChange.forEach(changeFn => changeFn(true));\n }\n /**\n * Enables the control. This means the control is included in validation checks and\n * the aggregate value of its parent. Its status recalculates based on its value and\n * its validators.\n *\n * By default, if the control has children, all children are enabled.\n *\n * @see {@link AbstractControl.status}\n *\n * @param opts Configure options that control how the control propagates changes and\n * emits events when marked as untouched\n * * `onlySelf`: When true, mark only this control. When false or not supplied,\n * marks all direct ancestors. Default is false.\n * * `emitEvent`: When true or not supplied (the default), the `statusChanges`,\n * `valueChanges` and `events`\n * observables emit events with the latest status and value when the control is enabled.\n * When false, no events are emitted.\n */\n enable(opts = {}) {\n // If parent has been marked artificially dirty we don't want to re-calculate the\n // parent's dirtiness based on the children.\n const skipPristineCheck = this._parentMarkedDirty(opts.onlySelf);\n this.status = VALID;\n this._forEachChild(control => {\n control.enable({\n ...opts,\n onlySelf: true\n });\n });\n this.updateValueAndValidity({\n onlySelf: true,\n emitEvent: opts.emitEvent\n });\n this._updateAncestors({\n ...opts,\n skipPristineCheck\n }, this);\n this._onDisabledChange.forEach(changeFn => changeFn(false));\n }\n _updateAncestors(opts, sourceControl) {\n if (this._parent && !opts.onlySelf) {\n this._parent.updateValueAndValidity(opts);\n if (!opts.skipPristineCheck) {\n this._parent._updatePristine({}, sourceControl);\n }\n this._parent._updateTouched({}, sourceControl);\n }\n }\n /**\n * Sets the parent of the control\n *\n * @param parent The new parent.\n */\n setParent(parent) {\n this._parent = parent;\n }\n /**\n * The raw value of this control. For most control implementations, the raw value will include\n * disabled children.\n */\n getRawValue() {\n return this.value;\n }\n updateValueAndValidity(opts = {}) {\n this._setInitialStatus();\n this._updateValue();\n if (this.enabled) {\n const shouldHaveEmitted = this._cancelExistingSubscription();\n this.errors = this._runValidator();\n this.status = this._calculateStatus();\n if (this.status === VALID || this.status === PENDING) {\n // If the canceled subscription should have emitted\n // we make sure the async validator emits the status change on completion\n this._runAsyncValidator(shouldHaveEmitted, opts.emitEvent);\n }\n }\n const sourceControl = opts.sourceControl ?? this;\n if (opts.emitEvent !== false) {\n this._events.next(new ValueChangeEvent(this.value, sourceControl));\n this._events.next(new StatusChangeEvent(this.status, sourceControl));\n this.valueChanges.emit(this.value);\n this.statusChanges.emit(this.status);\n }\n if (this._parent && !opts.onlySelf) {\n this._parent.updateValueAndValidity({\n ...opts,\n sourceControl\n });\n }\n }\n /** @internal */\n _updateTreeValidity(opts = {\n emitEvent: true\n }) {\n this._forEachChild(ctrl => ctrl._updateTreeValidity(opts));\n this.updateValueAndValidity({\n onlySelf: true,\n emitEvent: opts.emitEvent\n });\n }\n _setInitialStatus() {\n this.status = this._allControlsDisabled() ? DISABLED : VALID;\n }\n _runValidator() {\n return this.validator ? this.validator(this) : null;\n }\n _runAsyncValidator(shouldHaveEmitted, emitEvent) {\n if (this.asyncValidator) {\n this.status = PENDING;\n this._hasOwnPendingAsyncValidator = {\n emitEvent: emitEvent !== false\n };\n const obs = toObservable(this.asyncValidator(this));\n this._asyncValidationSubscription = obs.subscribe(errors => {\n this._hasOwnPendingAsyncValidator = null;\n // This will trigger the recalculation of the validation status, which depends on\n // the state of the asynchronous validation (whether it is in progress or not). So, it is\n // necessary that we have updated the `_hasOwnPendingAsyncValidator` boolean flag first.\n this.setErrors(errors, {\n emitEvent,\n shouldHaveEmitted\n });\n });\n }\n }\n _cancelExistingSubscription() {\n if (this._asyncValidationSubscription) {\n this._asyncValidationSubscription.unsubscribe();\n // we're cancelling the validator subscribtion, we keep if it should have emitted\n // because we want to emit eventually if it was required at least once.\n const shouldHaveEmitted = this._hasOwnPendingAsyncValidator?.emitEvent ?? false;\n this._hasOwnPendingAsyncValidator = null;\n return shouldHaveEmitted;\n }\n return false;\n }\n setErrors(errors, opts = {}) {\n this.errors = errors;\n this._updateControlsErrors(opts.emitEvent !== false, this, opts.shouldHaveEmitted);\n }\n /**\n * Retrieves a child control given the control's name or path.\n *\n * @param path A dot-delimited string or array of string/number values that define the path to the\n * control. If a string is provided, passing it as a string literal will result in improved type\n * information. Likewise, if an array is provided, passing it `as const` will cause improved type\n * information to be available.\n *\n * @usageNotes\n * ### Retrieve a nested control\n *\n * For example, to get a `name` control nested within a `person` sub-group:\n *\n * * `this.form.get('person.name');`\n *\n * -OR-\n *\n * * `this.form.get(['person', 'name'] as const);` // `as const` gives improved typings\n *\n * ### Retrieve a control in a FormArray\n *\n * When accessing an element inside a FormArray, you can use an element index.\n * For example, to get a `price` control from the first element in an `items` array you can use:\n *\n * * `this.form.get('items.0.price');`\n *\n * -OR-\n *\n * * `this.form.get(['items', 0, 'price']);`\n */\n get(path) {\n let currPath = path;\n if (currPath == null) return null;\n if (!Array.isArray(currPath)) currPath = currPath.split('.');\n if (currPath.length === 0) return null;\n return currPath.reduce((control, name) => control && control._find(name), this);\n }\n /**\n * @description\n * Reports error data for the control with the given path.\n *\n * @param errorCode The code of the error to check\n * @param path A list of control names that designates how to move from the current control\n * to the control that should be queried for errors.\n *\n * @usageNotes\n * For example, for the following `FormGroup`:\n *\n * ```ts\n * form = new FormGroup({\n * address: new FormGroup({ street: new FormControl() })\n * });\n * ```\n *\n * The path to the 'street' control from the root form would be 'address' -> 'street'.\n *\n * It can be provided to this method in one of two formats:\n *\n * 1. An array of string control names, e.g. `['address', 'street']`\n * 1. A period-delimited list of control names in one string, e.g. `'address.street'`\n *\n * @returns error data for that particular error. If the control or error is not present,\n * null is returned.\n */\n getError(errorCode, path) {\n const control = path ? this.get(path) : this;\n return control && control.errors ? control.errors[errorCode] : null;\n }\n /**\n * @description\n * Reports whether the control with the given path has the error specified.\n *\n * @param errorCode The code of the error to check\n * @param path A list of control names that designates how to move from the current control\n * to the control that should be queried for errors.\n *\n * @usageNotes\n * For example, for the following `FormGroup`:\n *\n * ```ts\n * form = new FormGroup({\n * address: new FormGroup({ street: new FormControl() })\n * });\n * ```\n *\n * The path to the 'street' control from the root form would be 'address' -> 'street'.\n *\n * It can be provided to this method in one of two formats:\n *\n * 1. An array of string control names, e.g. `['address', 'street']`\n * 1. A period-delimited list of control names in one string, e.g. `'address.street'`\n *\n * If no path is given, this method checks for the error on the current control.\n *\n * @returns whether the given error is present in the control at the given path.\n *\n * If the control is not present, false is returned.\n */\n hasError(errorCode, path) {\n return !!this.getError(errorCode, path);\n }\n /**\n * Retrieves the top-level ancestor of this control.\n */\n get root() {\n let x = this;\n while (x._parent) {\n x = x._parent;\n }\n return x;\n }\n /** @internal */\n _updateControlsErrors(emitEvent, changedControl, shouldHaveEmitted) {\n this.status = this._calculateStatus();\n if (emitEvent) {\n this.statusChanges.emit(this.status);\n }\n // The Events Observable expose a slight different bevahior than the statusChanges obs\n // An async validator will still emit a StatusChangeEvent is a previously cancelled\n // async validator has emitEvent set to true\n if (emitEvent || shouldHaveEmitted) {\n this._events.next(new StatusChangeEvent(this.status, changedControl));\n }\n if (this._parent) {\n this._parent._updateControlsErrors(emitEvent, changedControl, shouldHaveEmitted);\n }\n }\n /** @internal */\n _initObservables() {\n // TODO: this should be piped from events() but is breaking in G3\n this.valueChanges = new EventEmitter();\n this.statusChanges = new EventEmitter();\n }\n _calculateStatus() {\n if (this._allControlsDisabled()) return DISABLED;\n if (this.errors) return INVALID;\n if (this._hasOwnPendingAsyncValidator || this._anyControlsHaveStatus(PENDING)) return PENDING;\n if (this._anyControlsHaveStatus(INVALID)) return INVALID;\n return VALID;\n }\n /** @internal */\n _anyControlsHaveStatus(status) {\n return this._anyControls(control => control.status === status);\n }\n /** @internal */\n _anyControlsDirty() {\n return this._anyControls(control => control.dirty);\n }\n /** @internal */\n _anyControlsTouched() {\n return this._anyControls(control => control.touched);\n }\n /** @internal */\n _updatePristine(opts, changedControl) {\n const newPristine = !this._anyControlsDirty();\n const changed = this.pristine !== newPristine;\n this.pristine = newPristine;\n if (this._parent && !opts.onlySelf) {\n this._parent._updatePristine(opts, changedControl);\n }\n if (changed) {\n this._events.next(new PristineChangeEvent(this.pristine, changedControl));\n }\n }\n /** @internal */\n _updateTouched(opts = {}, changedControl) {\n this.touched = this._anyControlsTouched();\n this._events.next(new TouchedChangeEvent(this.touched, changedControl));\n if (this._parent && !opts.onlySelf) {\n this._parent._updateTouched(opts, changedControl);\n }\n }\n /** @internal */\n _onDisabledChange = [];\n /** @internal */\n _registerOnCollectionChange(fn) {\n this._onCollectionChange = fn;\n }\n /** @internal */\n _setUpdateStrategy(opts) {\n if (isOptionsObj(opts) && opts.updateOn != null) {\n this._updateOn = opts.updateOn;\n }\n }\n /**\n * Check to see if parent has been marked artificially dirty.\n *\n * @internal\n */\n _parentMarkedDirty(onlySelf) {\n const parentDirty = this._parent && this._parent.dirty;\n return !onlySelf && !!parentDirty && !this._parent._anyControlsDirty();\n }\n /** @internal */\n _find(name) {\n return null;\n }\n /**\n * Internal implementation of the `setValidators` method. Needs to be separated out into a\n * different method, because it is called in the constructor and it can break cases where\n * a control is extended.\n */\n _assignValidators(validators) {\n this._rawValidators = Array.isArray(validators) ? validators.slice() : validators;\n this._composedValidatorFn = coerceToValidator(this._rawValidators);\n }\n /**\n * Internal implementation of the `setAsyncValidators` method. Needs to be separated out into a\n * different method, because it is called in the constructor and it can break cases where\n * a control is extended.\n */\n _assignAsyncValidators(validators) {\n this._rawAsyncValidators = Array.isArray(validators) ? validators.slice() : validators;\n this._composedAsyncValidatorFn = coerceToAsyncValidator(this._rawAsyncValidators);\n }\n}\n\n/**\n * Tracks the value and validity state of a group of `FormControl` instances.\n *\n * A `FormGroup` aggregates the values of each child `FormControl` into one object,\n * with each control name as the key. It calculates its status by reducing the status values\n * of its children. For example, if one of the controls in a group is invalid, the entire\n * group becomes invalid.\n *\n * `FormGroup` is one of the four fundamental building blocks used to define forms in Angular,\n * along with `FormControl`, `FormArray`, and `FormRecord`.\n *\n * When instantiating a `FormGroup`, pass in a collection of child controls as the first\n * argument. The key for each child registers the name for the control.\n *\n * `FormGroup` is intended for use cases where the keys are known ahead of time.\n * If you need to dynamically add and remove controls, use {@link FormRecord} instead.\n *\n * `FormGroup` accepts an optional type parameter `TControl`, which is an object type with inner\n * control types as values.\n *\n * @usageNotes\n *\n * ### Create a form group with 2 controls\n *\n * ```ts\n * const form = new FormGroup({\n * first: new FormControl('Nancy', Validators.minLength(2)),\n * last: new FormControl('Drew'),\n * });\n *\n * console.log(form.value); // {first: 'Nancy', last; 'Drew'}\n * console.log(form.status); // 'VALID'\n * ```\n *\n * ### The type argument, and optional controls\n *\n * `FormGroup` accepts one generic argument, which is an object containing its inner controls.\n * This type will usually be inferred automatically, but you can always specify it explicitly if you\n * wish.\n *\n * If you have controls that are optional (i.e. they can be removed, you can use the `?` in the\n * type):\n *\n * ```ts\n * const form = new FormGroup<{\n * first: FormControl<string|null>,\n * middle?: FormControl<string|null>, // Middle name is optional.\n * last: FormControl<string|null>,\n * }>({\n * first: new FormControl('Nancy'),\n * last: new FormControl('Drew'),\n * });\n * ```\n *\n * ### Create a form group with a group-level validator\n *\n * You include group-level validators as the second arg, or group-level async\n * validators as the third arg. These come in handy when you want to perform validation\n * that considers the value of more than one child control.\n *\n * ```ts\n * const form = new FormGroup({\n * password: new FormControl('', Validators.minLength(2)),\n * passwordConfirm: new FormControl('', Validators.minLength(2)),\n * }, passwordMatchValidator);\n *\n *\n * function passwordMatchValidator(g: FormGroup) {\n * return g.get('password').value === g.get('passwordConfirm').value\n * ? null : {'mismatch': true};\n * }\n * ```\n *\n * Like `FormControl` instances, you choose to pass in\n * validators and async validators as part of an options object.\n *\n * ```ts\n * const form = new FormGroup({\n * password: new FormControl('')\n * passwordConfirm: new FormControl('')\n * }, { validators: passwordMatchValidator, asyncValidators: otherValidator });\n * ```\n *\n * ### Set the updateOn property for all controls in a form group\n *\n * The options object is used to set a default value for each child\n * control's `updateOn` property. If you set `updateOn` to `'blur'` at the\n * group level, all child controls default to 'blur', unless the child\n * has explicitly specified a different `updateOn` value.\n *\n * ```ts\n * const c = new FormGroup({\n * one: new FormControl()\n * }, { updateOn: 'blur' });\n * ```\n *\n * ### Using a FormGroup with optional controls\n *\n * It is possible to have optional controls in a FormGroup. An optional control can be removed later\n * using `removeControl`, and can be omitted when calling `reset`. Optional controls must be\n * declared optional in the group's type.\n *\n * ```ts\n * const c = new FormGroup<{one?: FormControl<string>}>({\n * one: new FormControl('')\n * });\n * ```\n *\n * Notice that `c.value.one` has type `string|null|undefined`. This is because calling `c.reset({})`\n * without providing the optional key `one` will cause it to become `null`.\n *\n * @publicApi\n */\nclass FormGroup extends AbstractControl {\n /**\n * Creates a new `FormGroup` instance.\n *\n * @param controls A collection of child controls. The key for each child is the name\n * under which it is registered.\n *\n * @param validatorOrOpts A synchronous validator function, or an array of\n * such functions, or an `AbstractControlOptions` object that contains validation functions\n * and a validation trigger.\n *\n * @param asyncValidator A single async validator or array of async validator functions\n *\n */\n constructor(controls, validatorOrOpts, asyncValidator) {\n super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts));\n (typeof ngDevMode === 'undefined' || ngDevMode) && validateFormGroupControls(controls);\n this.controls = controls;\n this._initObservables();\n this._setUpdateStrategy(validatorOrOpts);\n this._setUpControls();\n this.updateValueAndValidity({\n onlySelf: true,\n // If `asyncValidator` is present, it will trigger control status change from `PENDING` to\n // `VALID` or `INVALID`. The status should be broadcasted via the `statusChanges` observable,\n // so we set `emitEvent` to `true` to allow that during the control creation process.\n emitEvent: !!this.asyncValidator\n });\n }\n controls;\n registerControl(name, control) {\n if (this.controls[name]) return this.controls[name];\n this.controls[name] = control;\n control.setParent(this);\n control._registerOnCollectionChange(this._onCollectionChange);\n return control;\n }\n addControl(name, control, options = {}) {\n this.registerControl(name, control);\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n this._onCollectionChange();\n }\n /**\n * Remove a control from this group. In a strongly-typed group, required controls cannot be\n * removed.\n *\n * This method also updates the value and validity of the control.\n *\n * @param name The control name to remove from the collection\n * @param options Specifies whether this FormGroup instance should emit events after a\n * control is removed.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when the control is\n * removed. When false, no events are emitted.\n */\n removeControl(name, options = {}) {\n if (this.controls[name]) this.controls[name]._registerOnCollectionChange(() => {});\n delete this.controls[name];\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n this._onCollectionChange();\n }\n setControl(name, control, options = {}) {\n if (this.controls[name]) this.controls[name]._registerOnCollectionChange(() => {});\n delete this.controls[name];\n if (control) this.registerControl(name, control);\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n this._onCollectionChange();\n }\n contains(controlName) {\n return this.controls.hasOwnProperty(controlName) && this.controls[controlName].enabled;\n }\n /**\n * Sets the value of the `FormGroup`. It accepts an object that matches\n * the structure of the group, with control names as keys.\n *\n * @usageNotes\n * ### Set the complete value for the form group\n *\n * ```ts\n * const form = new FormGroup({\n * first: new FormControl(),\n * last: new FormControl()\n * });\n *\n * console.log(form.value); // {first: null, last: null}\n *\n * form.setValue({first: 'Nancy', last: 'Drew'});\n * console.log(form.value); // {first: 'Nancy', last: 'Drew'}\n * ```\n *\n * @throws When strict checks fail, such as setting the value of a control\n * that doesn't exist or if you exclude a value of a control that does exist.\n *\n * @param value The new value for the control that matches the structure of the group.\n * @param options Configuration options that determine how the control propagates changes\n * and emits events after the value changes.\n * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity\n * updateValueAndValidity} method.\n *\n * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is\n * false.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges`\n * observables emit events with the latest status and value when the control value is updated.\n * When false, no events are emitted.\n */\n setValue(value, options = {}) {\n assertAllValuesPresent(this, true, value);\n Object.keys(value).forEach(name => {\n assertControlPresent(this, true, name);\n this.controls[name].setValue(value[name], {\n onlySelf: true,\n emitEvent: options.emitEvent\n });\n });\n this.updateValueAndValidity(options);\n }\n /**\n * Patches the value of the `FormGroup`. It accepts an object with control\n * names as keys, and does its best to match the values to the correct controls\n * in the group.\n *\n * It accepts both super-sets and sub-sets of the group without throwing an error.\n *\n * @usageNotes\n * ### Patch the value for a form group\n *\n * ```ts\n * const form = new FormGroup({\n * first: new FormControl(),\n * last: new FormControl()\n * });\n * console.log(form.value); // {first: null, last: null}\n *\n * form.patchValue({first: 'Nancy'});\n * console.log(form.value); // {first: 'Nancy', last: null}\n * ```\n *\n * @param value The object that matches the structure of the group.\n * @param options Configuration options that determine how the control propagates changes and\n * emits events after the value is patched.\n * * `onlySelf`: When true, each change only affects this control and not its parent. Default is\n * true.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when the control value\n * is updated. When false, no events are emitted. The configuration options are passed to\n * the {@link AbstractControl#updateValueAndValidity updateValueAndValidity} method.\n */\n patchValue(value, options = {}) {\n // Even though the `value` argument type doesn't allow `null` and `undefined` values, the\n // `patchValue` can be called recursively and inner data structures might have these values, so\n // we just ignore such cases when a field containing FormGroup instance receives `null` or\n // `undefined` as a value.\n if (value == null /* both `null` and `undefined` */) return;\n Object.keys(value).forEach(name => {\n // The compiler cannot see through the uninstantiated conditional type of `this.controls`, so\n // `as any` is required.\n const control = this.controls[name];\n if (control) {\n control.patchValue(/* Guaranteed to be present, due to the outer forEach. */value[name], {\n onlySelf: true,\n emitEvent: options.emitEvent\n });\n }\n });\n this.updateValueAndValidity(options);\n }\n /**\n * Resets the `FormGroup`, marks all descendants `pristine` and `untouched` and sets\n * the value of all descendants to their default values, or null if no defaults were provided.\n *\n * You reset to a specific form state by passing in a map of states\n * that matches the structure of your form, with control names as keys. The state\n * is a standalone value or a form state object with both a value and a disabled\n * status.\n *\n * @param value Resets the control with an initial value,\n * or an object that defines the initial value and disabled state.\n *\n * @param options Configuration options that determine how the control propagates changes\n * and emits events when the group is reset.\n * * `onlySelf`: When true, each change only affects this control, and not its parent. Default is\n * false.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges`\n * observables emit events with the latest status and value when the control is reset.\n * When false, no events are emitted.\n * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity\n * updateValueAndValidity} method.\n *\n * @usageNotes\n *\n * ### Reset the form group values\n *\n * ```ts\n * const form = new FormGroup({\n * first: new FormControl('first name'),\n * last: new FormControl('last name')\n * });\n *\n * console.log(form.value); // {first: 'first name', last: 'last name'}\n *\n * form.reset({ first: 'name', last: 'last name' });\n *\n * console.log(form.value); // {first: 'name', last: 'last name'}\n * ```\n *\n * ### Reset the form group values and disabled status\n *\n * ```ts\n * const form = new FormGroup({\n * first: new FormControl('first name'),\n * last: new FormControl('last name')\n * });\n *\n * form.reset({\n * first: {value: 'name', disabled: true},\n * last: 'last'\n * });\n *\n * console.log(form.value); // {last: 'last'}\n * console.log(form.get('first').status); // 'DISABLED'\n * ```\n */\n reset(value = {}, options = {}) {\n this._forEachChild((control, name) => {\n control.reset(value ? value[name] : null, {\n onlySelf: true,\n emitEvent: options.emitEvent\n });\n });\n this._updatePristine(options, this);\n this._updateTouched(options, this);\n this.updateValueAndValidity(options);\n }\n /**\n * The aggregate value of the `FormGroup`, including any disabled controls.\n *\n * Retrieves all values regardless of disabled status.\n */\n getRawValue() {\n return this._reduceChildren({}, (acc, control, name) => {\n acc[name] = control.getRawValue();\n return acc;\n });\n }\n /** @internal */\n _syncPendingControls() {\n let subtreeUpdated = this._reduceChildren(false, (updated, child) => {\n return child._syncPendingControls() ? true : updated;\n });\n if (subtreeUpdated) this.updateValueAndValidity({\n onlySelf: true\n });\n return subtreeUpdated;\n }\n /** @internal */\n _forEachChild(cb) {\n Object.keys(this.controls).forEach(key => {\n // The list of controls can change (for ex. controls might be removed) while the loop\n // is running (as a result of invoking Forms API in `valueChanges` subscription), so we\n // have to null check before invoking the callback.\n const control = this.controls[key];\n control && cb(control, key);\n });\n }\n /** @internal */\n _setUpControls() {\n this._forEachChild(control => {\n control.setParent(this);\n control._registerOnCollectionChange(this._onCollectionChange);\n });\n }\n /** @internal */\n _updateValue() {\n this.value = this._reduceValue();\n }\n /** @internal */\n _anyControls(condition) {\n for (const [controlName, control] of Object.entries(this.controls)) {\n if (this.contains(controlName) && condition(control)) {\n return true;\n }\n }\n return false;\n }\n /** @internal */\n _reduceValue() {\n let acc = {};\n return this._reduceChildren(acc, (acc, control, name) => {\n if (control.enabled || this.disabled) {\n acc[name] = control.value;\n }\n return acc;\n });\n }\n /** @internal */\n _reduceChildren(initValue, fn) {\n let res = initValue;\n this._forEachChild((control, name) => {\n res = fn(res, control, name);\n });\n return res;\n }\n /** @internal */\n _allControlsDisabled() {\n for (const controlName of Object.keys(this.controls)) {\n if (this.controls[controlName].enabled) {\n return false;\n }\n }\n return Object.keys(this.controls).length > 0 || this.disabled;\n }\n /** @internal */\n _find(name) {\n return this.controls.hasOwnProperty(name) ? this.controls[name] : null;\n }\n}\n/**\n * Will validate that none of the controls has a key with a dot\n * Throws other wise\n */\nfunction validateFormGroupControls(controls) {\n const invalidKeys = Object.keys(controls).filter(key => key.includes('.'));\n if (invalidKeys.length > 0) {\n // TODO: make this an error once there are no more uses in G3\n console.warn(`FormGroup keys cannot include \\`.\\`, please replace the keys for: ${invalidKeys.join(',')}.`);\n }\n}\nconst UntypedFormGroup = FormGroup;\n/**\n * @description\n * Asserts that the given control is an instance of `FormGroup`\n *\n * @publicApi\n */\nconst isFormGroup = control => control instanceof FormGroup;\n/**\n * Tracks the value and validity state of a collection of `FormControl` instances, each of which has\n * the same value type.\n *\n * `FormRecord` is very similar to {@link FormGroup}, except it can be used with a dynamic keys,\n * with controls added and removed as needed.\n *\n * `FormRecord` accepts one generic argument, which describes the type of the controls it contains.\n *\n * @usageNotes\n *\n * ```ts\n * let numbers = new FormRecord({bill: new FormControl('415-123-456')});\n * numbers.addControl('bob', new FormControl('415-234-567'));\n * numbers.removeControl('bill');\n * ```\n *\n * @publicApi\n */\nclass FormRecord extends FormGroup {}\n/**\n * @description\n * Asserts that the given control is an instance of `FormRecord`\n *\n * @publicApi\n */\nconst isFormRecord = control => control instanceof FormRecord;\n\n/**\n * Token to provide to allow SetDisabledState to always be called when a CVA is added, regardless of\n * whether the control is disabled or enabled.\n *\n * @see {@link FormsModule#withconfig}\n */\nconst CALL_SET_DISABLED_STATE = new InjectionToken(typeof ngDevMode === 'undefined' || ngDevMode ? 'CallSetDisabledState' : '', {\n providedIn: 'root',\n factory: () => setDisabledStateDefault\n});\n/**\n * Whether to use the fixed setDisabledState behavior by default.\n */\nconst setDisabledStateDefault = 'always';\nfunction controlPath(name, parent) {\n return [...parent.path, name];\n}\n/**\n * Links a Form control and a Form directive by setting up callbacks (such as `onChange`) on both\n * instances. This function is typically invoked when form directive is being initialized.\n *\n * @param control Form control instance that should be linked.\n * @param dir Directive that should be linked with a given control.\n */\nfunction setUpControl(control, dir, callSetDisabledState = setDisabledStateDefault) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (!control) _throwError(dir, 'Cannot find control with');\n if (!dir.valueAccessor) _throwMissingValueAccessorError(dir);\n }\n setUpValidators(control, dir);\n dir.valueAccessor.writeValue(control.value);\n // The legacy behavior only calls the CVA's `setDisabledState` if the control is disabled.\n // If the `callSetDisabledState` option is set to `always`, then this bug is fixed and\n // the method is always called.\n if (control.disabled || callSetDisabledState === 'always') {\n dir.valueAccessor.setDisabledState?.(control.disabled);\n }\n setUpViewChangePipeline(control, dir);\n setUpModelChangePipeline(control, dir);\n setUpBlurPipeline(control, dir);\n setUpDisabledChangeHandler(control, dir);\n}\n/**\n * Reverts configuration performed by the `setUpControl` control function.\n * Effectively disconnects form control with a given form directive.\n * This function is typically invoked when corresponding form directive is being destroyed.\n *\n * @param control Form control which should be cleaned up.\n * @param dir Directive that should be disconnected from a given control.\n * @param validateControlPresenceOnChange Flag that indicates whether onChange handler should\n * contain asserts to verify that it's not called once directive is destroyed. We need this flag\n * to avoid potentially breaking changes caused by better control cleanup introduced in #39235.\n */\nfunction cleanUpControl(control, dir, validateControlPresenceOnChange = true) {\n const noop = () => {\n if (validateControlPresenceOnChange && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n _noControlError(dir);\n }\n };\n // The `valueAccessor` field is typically defined on FromControl and FormControlName directive\n // instances and there is a logic in `selectValueAccessor` function that throws if it's not the\n // case. We still check the presence of `valueAccessor` before invoking its methods to make sure\n // that cleanup works correctly if app code or tests are setup to ignore the error thrown from\n // `selectValueAccessor`. See https://github.com/angular/angular/issues/40521.\n if (dir.valueAccessor) {\n dir.valueAccessor.registerOnChange(noop);\n dir.valueAccessor.registerOnTouched(noop);\n }\n cleanUpValidators(control, dir);\n if (control) {\n dir._invokeOnDestroyCallbacks();\n control._registerOnCollectionChange(() => {});\n }\n}\nfunction registerOnValidatorChange(validators, onChange) {\n validators.forEach(validator => {\n if (validator.registerOnValidatorChange) validator.registerOnValidatorChange(onChange);\n });\n}\n/**\n * Sets up disabled change handler function on a given form control if ControlValueAccessor\n * associated with a given directive instance supports the `setDisabledState` call.\n *\n * @param control Form control where disabled change handler should be setup.\n * @param dir Corresponding directive instance associated with this control.\n */\nfunction setUpDisabledChangeHandler(control, dir) {\n if (dir.valueAccessor.setDisabledState) {\n const onDisabledChange = isDisabled => {\n dir.valueAccessor.setDisabledState(isDisabled);\n };\n control.registerOnDisabledChange(onDisabledChange);\n // Register a callback function to cleanup disabled change handler\n // from a control instance when a directive is destroyed.\n dir._registerOnDestroy(() => {\n control._unregisterOnDisabledChange(onDisabledChange);\n });\n }\n}\n/**\n * Sets up sync and async directive validators on provided form control.\n * This function merges validators from the directive into the validators of the control.\n *\n * @param control Form control where directive validators should be setup.\n * @param dir Directive instance that contains validators to be setup.\n */\nfunction setUpValidators(control, dir) {\n const validators = getControlValidators(control);\n if (dir.validator !== null) {\n control.setValidators(mergeValidators(validators, dir.validator));\n } else if (typeof validators === 'function') {\n // If sync validators are represented by a single validator function, we force the\n // `Validators.compose` call to happen by executing the `setValidators` function with\n // an array that contains that function. We need this to avoid possible discrepancies in\n // validators behavior, so sync validators are always processed by the `Validators.compose`.\n // Note: we should consider moving this logic inside the `setValidators` function itself, so we\n // have consistent behavior on AbstractControl API level. The same applies to the async\n // validators logic below.\n control.setValidators([validators]);\n }\n const asyncValidators = getControlAsyncValidators(control);\n if (dir.asyncValidator !== null) {\n control.setAsyncValidators(mergeValidators(asyncValidators, dir.asyncValidator));\n } else if (typeof asyncValidators === 'function') {\n control.setAsyncValidators([asyncValidators]);\n }\n // Re-run validation when validator binding changes, e.g. minlength=3 -> minlength=4\n const onValidatorChange = () => control.updateValueAndValidity();\n registerOnValidatorChange(dir._rawValidators, onValidatorChange);\n registerOnValidatorChange(dir._rawAsyncValidators, onValidatorChange);\n}\n/**\n * Cleans up sync and async directive validators on provided form control.\n * This function reverts the setup performed by the `setUpValidators` function, i.e.\n * removes directive-specific validators from a given control instance.\n *\n * @param control Form control from where directive validators should be removed.\n * @param dir Directive instance that contains validators to be removed.\n * @returns true if a control was updated as a result of this action.\n */\nfunction cleanUpValidators(control, dir) {\n let isControlUpdated = false;\n if (control !== null) {\n if (dir.validator !== null) {\n const validators = getControlValidators(control);\n if (Array.isArray(validators) && validators.length > 0) {\n // Filter out directive validator function.\n const updatedValidators = validators.filter(validator => validator !== dir.validator);\n if (updatedValidators.length !== validators.length) {\n isControlUpdated = true;\n control.setValidators(updatedValidators);\n }\n }\n }\n if (dir.asyncValidator !== null) {\n const asyncValidators = getControlAsyncValidators(control);\n if (Array.isArray(asyncValidators) && asyncValidators.length > 0) {\n // Filter out directive async validator function.\n const updatedAsyncValidators = asyncValidators.filter(asyncValidator => asyncValidator !== dir.asyncValidator);\n if (updatedAsyncValidators.length !== asyncValidators.length) {\n isControlUpdated = true;\n control.setAsyncValidators(updatedAsyncValidators);\n }\n }\n }\n }\n // Clear onValidatorChange callbacks by providing a noop function.\n const noop = () => {};\n registerOnValidatorChange(dir._rawValidators, noop);\n registerOnValidatorChange(dir._rawAsyncValidators, noop);\n return isControlUpdated;\n}\nfunction setUpViewChangePipeline(control, dir) {\n dir.valueAccessor.registerOnChange(newValue => {\n control._pendingValue = newValue;\n control._pendingChange = true;\n control._pendingDirty = true;\n if (control.updateOn === 'change') updateControl(control, dir);\n });\n}\nfunction setUpBlurPipeline(control, dir) {\n dir.valueAccessor.registerOnTouched(() => {\n control._pendingTouched = true;\n if (control.updateOn === 'blur' && control._pendingChange) updateControl(control, dir);\n if (control.updateOn !== 'submit') control.markAsTouched();\n });\n}\nfunction updateControl(control, dir) {\n if (control._pendingDirty) control.markAsDirty();\n control.setValue(control._pendingValue, {\n emitModelToViewChange: false\n });\n dir.viewToModelUpdate(control._pendingValue);\n control._pendingChange = false;\n}\nfunction setUpModelChangePipeline(control, dir) {\n const onChange = (newValue, emitModelEvent) => {\n // control -> view\n dir.valueAccessor.writeValue(newValue);\n // control -> ngModel\n if (emitModelEvent) dir.viewToModelUpdate(newValue);\n };\n control.registerOnChange(onChange);\n // Register a callback function to cleanup onChange handler\n // from a control instance when a directive is destroyed.\n dir._registerOnDestroy(() => {\n control._unregisterOnChange(onChange);\n });\n}\n/**\n * Links a FormGroup or FormArray instance and corresponding Form directive by setting up validators\n * present in the view.\n *\n * @param control FormGroup or FormArray instance that should be linked.\n * @param dir Directive that provides view validators.\n */\nfunction setUpFormContainer(control, dir) {\n if (control == null && (typeof ngDevMode === 'undefined' || ngDevMode)) _throwError(dir, 'Cannot find control with');\n setUpValidators(control, dir);\n}\n/**\n * Reverts the setup performed by the `setUpFormContainer` function.\n *\n * @param control FormGroup or FormArray instance that should be cleaned up.\n * @param dir Directive that provided view validators.\n * @returns true if a control was updated as a result of this action.\n */\nfunction cleanUpFormContainer(control, dir) {\n return cleanUpValidators(control, dir);\n}\nfunction _noControlError(dir) {\n return _throwError(dir, 'There is no FormControl instance attached to form control element with');\n}\nfunction _throwError(dir, message) {\n const messageEnd = _describeControlLocation(dir);\n throw new Error(`${message} ${messageEnd}`);\n}\nfunction _describeControlLocation(dir) {\n const path = dir.path;\n if (path && path.length > 1) return `path: '${path.join(' -> ')}'`;\n if (path?.[0]) return `name: '${path}'`;\n return 'unspecified name attribute';\n}\nfunction _throwMissingValueAccessorError(dir) {\n const loc = _describeControlLocation(dir);\n throw new ɵRuntimeError(-1203 /* RuntimeErrorCode.NG_MISSING_VALUE_ACCESSOR */, `No value accessor for form control ${loc}.`);\n}\nfunction _throwInvalidValueAccessorError(dir) {\n const loc = _describeControlLocation(dir);\n throw new ɵRuntimeError(1200 /* RuntimeErrorCode.NG_VALUE_ACCESSOR_NOT_PROVIDED */, `Value accessor was not provided as an array for form control with ${loc}. ` + `Check that the \\`NG_VALUE_ACCESSOR\\` token is configured as a \\`multi: true\\` provider.`);\n}\nfunction isPropertyUpdated(changes, viewModel) {\n if (!changes.hasOwnProperty('model')) return false;\n const change = changes['model'];\n if (change.isFirstChange()) return true;\n return !Object.is(viewModel, change.currentValue);\n}\nfunction isBuiltInAccessor(valueAccessor) {\n // Check if a given value accessor is an instance of a class that directly extends\n // `BuiltInControlValueAccessor` one.\n return Object.getPrototypeOf(valueAccessor.constructor) === BuiltInControlValueAccessor;\n}\nfunction syncPendingControls(form, directives) {\n form._syncPendingControls();\n directives.forEach(dir => {\n const control = dir.control;\n if (control.updateOn === 'submit' && control._pendingChange) {\n dir.viewToModelUpdate(control._pendingValue);\n control._pendingChange = false;\n }\n });\n}\n// TODO: vsavkin remove it once https://github.com/angular/angular/issues/3011 is implemented\nfunction selectValueAccessor(dir, valueAccessors) {\n if (!valueAccessors) return null;\n if (!Array.isArray(valueAccessors) && (typeof ngDevMode === 'undefined' || ngDevMode)) _throwInvalidValueAccessorError(dir);\n let defaultAccessor = undefined;\n let builtinAccessor = undefined;\n let customAccessor = undefined;\n valueAccessors.forEach(v => {\n if (v.constructor === DefaultValueAccessor) {\n defaultAccessor = v;\n } else if (isBuiltInAccessor(v)) {\n if (builtinAccessor && (typeof ngDevMode === 'undefined' || ngDevMode)) _throwError(dir, 'More than one built-in value accessor matches form control with');\n builtinAccessor = v;\n } else {\n if (customAccessor && (typeof ngDevMode === 'undefined' || ngDevMode)) _throwError(dir, 'More than one custom value accessor matches form control with');\n customAccessor = v;\n }\n });\n if (customAccessor) return customAccessor;\n if (builtinAccessor) return builtinAccessor;\n if (defaultAccessor) return defaultAccessor;\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n _throwError(dir, 'No valid value accessor for form control with');\n }\n return null;\n}\nfunction removeListItem$1(list, el) {\n const index = list.indexOf(el);\n if (index > -1) list.splice(index, 1);\n}\n// TODO(kara): remove after deprecation period\nfunction _ngModelWarning(name, type, instance, warningConfig) {\n if (warningConfig === 'never') return;\n if ((warningConfig === null || warningConfig === 'once') && !type._ngModelWarningSentOnce || warningConfig === 'always' && !instance._ngModelWarningSent) {\n console.warn(ngModelWarning(name));\n type._ngModelWarningSentOnce = true;\n instance._ngModelWarningSent = true;\n }\n}\nconst formDirectiveProvider$1 = {\n provide: ControlContainer,\n useExisting: forwardRef(() => NgForm)\n};\nconst resolvedPromise$1 = (() => Promise.resolve())();\n/**\n * @description\n * Creates a top-level `FormGroup` instance and binds it to a form\n * to track aggregate form value and validation status.\n *\n * As soon as you import the `FormsModule`, this directive becomes active by default on\n * all `<form>` tags. You don't need to add a special selector.\n *\n * You optionally export the directive into a local template variable using `ngForm` as the key\n * (ex: `#myForm=\"ngForm\"`). This is optional, but useful. Many properties from the underlying\n * `FormGroup` instance are duplicated on the directive itself, so a reference to it\n * gives you access to the aggregate value and validity status of the form, as well as\n * user interaction properties like `dirty` and `touched`.\n *\n * To register child controls with the form, use `NgModel` with a `name`\n * attribute. You may use `NgModelGroup` to create sub-groups within the form.\n *\n * If necessary, listen to the directive's `ngSubmit` event to be notified when the user has\n * triggered a form submission. The `ngSubmit` event emits the original form\n * submission event.\n *\n * In template driven forms, all `<form>` tags are automatically tagged as `NgForm`.\n * To import the `FormsModule` but skip its usage in some forms,\n * for example, to use native HTML5 validation, add the `ngNoForm` and the `<form>`\n * tags won't create an `NgForm` directive. In reactive forms, using `ngNoForm` is\n * unnecessary because the `<form>` tags are inert. In that case, you would\n * refrain from using the `formGroup` directive.\n *\n * @usageNotes\n *\n * ### Listening for form submission\n *\n * The following example shows how to capture the form values from the \"ngSubmit\" event.\n *\n * {@example forms/ts/simpleForm/simple_form_example.ts region='Component'}\n *\n * ### Setting the update options\n *\n * The following example shows you how to change the \"updateOn\" option from its default using\n * ngFormOptions.\n *\n * ```html\n * <form [ngFormOptions]=\"{updateOn: 'blur'}\">\n * <input name=\"one\" ngModel> <!-- this ngModel will update on blur -->\n * </form>\n * ```\n *\n * ### Native DOM validation UI\n *\n * In order to prevent the native DOM form validation UI from interfering with Angular's form\n * validation, Angular automatically adds the `novalidate` attribute on any `<form>` whenever\n * `FormModule` or `ReactiveFormModule` are imported into the application.\n * If you want to explicitly enable native DOM validation UI with Angular forms, you can add the\n * `ngNativeValidate` attribute to the `<form>` element:\n *\n * ```html\n * <form ngNativeValidate>\n * ...\n * </form>\n * ```\n *\n * @ngModule FormsModule\n * @publicApi\n */\nclass NgForm extends ControlContainer {\n callSetDisabledState;\n /**\n * @description\n * Returns whether the form submission has been triggered.\n */\n get submitted() {\n return untracked(this.submittedReactive);\n }\n /** @internal */\n _submitted = computed(() => this.submittedReactive());\n submittedReactive = signal(false);\n _directives = new Set();\n /**\n * @description\n * The `FormGroup` instance created for this form.\n */\n form;\n /**\n * @description\n * Event emitter for the \"ngSubmit\" event\n */\n ngSubmit = new EventEmitter();\n /**\n * @description\n * Tracks options for the `NgForm` instance.\n *\n * **updateOn**: Sets the default `updateOn` value for all child `NgModels` below it\n * unless explicitly set by a child `NgModel` using `ngModelOptions`). Defaults to 'change'.\n * Possible values: `'change'` | `'blur'` | `'submit'`.\n *\n */\n // TODO(issue/24571): remove '!'.\n options;\n constructor(validators, asyncValidators, callSetDisabledState) {\n super();\n this.callSetDisabledState = callSetDisabledState;\n this.form = new FormGroup({}, composeValidators(validators), composeAsyncValidators(asyncValidators));\n }\n /** @nodoc */\n ngAfterViewInit() {\n this._setUpdateStrategy();\n }\n /**\n * @description\n * The directive instance.\n */\n get formDirective() {\n return this;\n }\n /**\n * @description\n * The internal `FormGroup` instance.\n */\n get control() {\n return this.form;\n }\n /**\n * @description\n * Returns an array representing the path to this group. Because this directive\n * always lives at the top level of a form, it is always an empty array.\n */\n get path() {\n return [];\n }\n /**\n * @description\n * Returns a map of the controls in this group.\n */\n get controls() {\n return this.form.controls;\n }\n /**\n * @description\n * Method that sets up the control directive in this group, re-calculates its value\n * and validity, and adds the instance to the internal list of directives.\n *\n * @param dir The `NgModel` directive instance.\n */\n addControl(dir) {\n resolvedPromise$1.then(() => {\n const container = this._findContainer(dir.path);\n dir.control = container.registerControl(dir.name, dir.control);\n setUpControl(dir.control, dir, this.callSetDisabledState);\n dir.control.updateValueAndValidity({\n emitEvent: false\n });\n this._directives.add(dir);\n });\n }\n /**\n * @description\n * Retrieves the `FormControl` instance from the provided `NgModel` directive.\n *\n * @param dir The `NgModel` directive instance.\n */\n getControl(dir) {\n return this.form.get(dir.path);\n }\n /**\n * @description\n * Removes the `NgModel` instance from the internal list of directives\n *\n * @param dir The `NgModel` directive instance.\n */\n removeControl(dir) {\n resolvedPromise$1.then(() => {\n const container = this._findContainer(dir.path);\n if (container) {\n container.removeControl(dir.name);\n }\n this._directives.delete(dir);\n });\n }\n /**\n * @description\n * Adds a new `NgModelGroup` directive instance to the form.\n *\n * @param dir The `NgModelGroup` directive instance.\n */\n addFormGroup(dir) {\n resolvedPromise$1.then(() => {\n const container = this._findContainer(dir.path);\n const group = new FormGroup({});\n setUpFormContainer(group, dir);\n container.registerControl(dir.name, group);\n group.updateValueAndValidity({\n emitEvent: false\n });\n });\n }\n /**\n * @description\n * Removes the `NgModelGroup` directive instance from the form.\n *\n * @param dir The `NgModelGroup` directive instance.\n */\n removeFormGroup(dir) {\n resolvedPromise$1.then(() => {\n const container = this._findContainer(dir.path);\n if (container) {\n container.removeControl(dir.name);\n }\n });\n }\n /**\n * @description\n * Retrieves the `FormGroup` for a provided `NgModelGroup` directive instance\n *\n * @param dir The `NgModelGroup` directive instance.\n */\n getFormGroup(dir) {\n return this.form.get(dir.path);\n }\n /**\n * Sets the new value for the provided `NgControl` directive.\n *\n * @param dir The `NgControl` directive instance.\n * @param value The new value for the directive's control.\n */\n updateModel(dir, value) {\n resolvedPromise$1.then(() => {\n const ctrl = this.form.get(dir.path);\n ctrl.setValue(value);\n });\n }\n /**\n * @description\n * Sets the value for this `FormGroup`.\n *\n * @param value The new value\n */\n setValue(value) {\n this.control.setValue(value);\n }\n /**\n * @description\n * Method called when the \"submit\" event is triggered on the form.\n * Triggers the `ngSubmit` emitter to emit the \"submit\" event as its payload.\n *\n * @param $event The \"submit\" event object\n */\n onSubmit($event) {\n this.submittedReactive.set(true);\n syncPendingControls(this.form, this._directives);\n this.ngSubmit.emit($event);\n // Forms with `method=\"dialog\"` have some special behavior\n // that won't reload the page and that shouldn't be prevented.\n return $event?.target?.method === 'dialog';\n }\n /**\n * @description\n * Method called when the \"reset\" event is triggered on the form.\n */\n onReset() {\n this.resetForm();\n }\n /**\n * @description\n * Resets the form to an initial value and resets its submitted status.\n *\n * @param value The new value for the form.\n */\n resetForm(value = undefined) {\n this.form.reset(value);\n this.submittedReactive.set(false);\n }\n _setUpdateStrategy() {\n if (this.options && this.options.updateOn != null) {\n this.form._updateOn = this.options.updateOn;\n }\n }\n _findContainer(path) {\n path.pop();\n return path.length ? this.form.get(path) : this.form;\n }\n static ɵfac = function NgForm_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgForm)(i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10), i0.ɵɵdirectiveInject(CALL_SET_DISABLED_STATE, 8));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgForm,\n selectors: [[\"form\", 3, \"ngNoForm\", \"\", 3, \"formGroup\", \"\"], [\"ng-form\"], [\"\", \"ngForm\", \"\"]],\n hostBindings: function NgForm_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"submit\", function NgForm_submit_HostBindingHandler($event) {\n return ctx.onSubmit($event);\n })(\"reset\", function NgForm_reset_HostBindingHandler() {\n return ctx.onReset();\n });\n }\n },\n inputs: {\n options: [0, \"ngFormOptions\", \"options\"]\n },\n outputs: {\n ngSubmit: \"ngSubmit\"\n },\n exportAs: [\"ngForm\"],\n standalone: false,\n features: [i0.ɵɵProvidersFeature([formDirectiveProvider$1]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgForm, [{\n type: Directive,\n args: [{\n selector: 'form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]',\n providers: [formDirectiveProvider$1],\n host: {\n '(submit)': 'onSubmit($event)',\n '(reset)': 'onReset()'\n },\n outputs: ['ngSubmit'],\n exportAs: 'ngForm',\n standalone: false\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [CALL_SET_DISABLED_STATE]\n }]\n }], {\n options: [{\n type: Input,\n args: ['ngFormOptions']\n }]\n });\n})();\nfunction removeListItem(list, el) {\n const index = list.indexOf(el);\n if (index > -1) list.splice(index, 1);\n}\nfunction isFormControlState(formState) {\n return typeof formState === 'object' && formState !== null && Object.keys(formState).length === 2 && 'value' in formState && 'disabled' in formState;\n}\nconst FormControl = class FormControl extends AbstractControl {\n /** @publicApi */\n defaultValue = null;\n /** @internal */\n _onChange = [];\n /** @internal */\n _pendingValue;\n /** @internal */\n _pendingChange = false;\n constructor(\n // formState and defaultValue will only be null if T is nullable\n formState = null, validatorOrOpts, asyncValidator) {\n super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts));\n this._applyFormState(formState);\n this._setUpdateStrategy(validatorOrOpts);\n this._initObservables();\n this.updateValueAndValidity({\n onlySelf: true,\n // If `asyncValidator` is present, it will trigger control status change from `PENDING` to\n // `VALID` or `INVALID`.\n // The status should be broadcasted via the `statusChanges` observable, so we set\n // `emitEvent` to `true` to allow that during the control creation process.\n emitEvent: !!this.asyncValidator\n });\n if (isOptionsObj(validatorOrOpts) && (validatorOrOpts.nonNullable || validatorOrOpts.initialValueIsDefault)) {\n if (isFormControlState(formState)) {\n this.defaultValue = formState.value;\n } else {\n this.defaultValue = formState;\n }\n }\n }\n setValue(value, options = {}) {\n this.value = this._pendingValue = value;\n if (this._onChange.length && options.emitModelToViewChange !== false) {\n this._onChange.forEach(changeFn => changeFn(this.value, options.emitViewToModelChange !== false));\n }\n this.updateValueAndValidity(options);\n }\n patchValue(value, options = {}) {\n this.setValue(value, options);\n }\n reset(formState = this.defaultValue, options = {}) {\n this._applyFormState(formState);\n this.markAsPristine(options);\n this.markAsUntouched(options);\n this.setValue(this.value, options);\n this._pendingChange = false;\n }\n /** @internal */\n _updateValue() {}\n /** @internal */\n _anyControls(condition) {\n return false;\n }\n /** @internal */\n _allControlsDisabled() {\n return this.disabled;\n }\n registerOnChange(fn) {\n this._onChange.push(fn);\n }\n /** @internal */\n _unregisterOnChange(fn) {\n removeListItem(this._onChange, fn);\n }\n registerOnDisabledChange(fn) {\n this._onDisabledChange.push(fn);\n }\n /** @internal */\n _unregisterOnDisabledChange(fn) {\n removeListItem(this._onDisabledChange, fn);\n }\n /** @internal */\n _forEachChild(cb) {}\n /** @internal */\n _syncPendingControls() {\n if (this.updateOn === 'submit') {\n if (this._pendingDirty) this.markAsDirty();\n if (this._pendingTouched) this.markAsTouched();\n if (this._pendingChange) {\n this.setValue(this._pendingValue, {\n onlySelf: true,\n emitModelToViewChange: false\n });\n return true;\n }\n }\n return false;\n }\n _applyFormState(formState) {\n if (isFormControlState(formState)) {\n this.value = this._pendingValue = formState.value;\n formState.disabled ? this.disable({\n onlySelf: true,\n emitEvent: false\n }) : this.enable({\n onlySelf: true,\n emitEvent: false\n });\n } else {\n this.value = this._pendingValue = formState;\n }\n }\n};\nconst UntypedFormControl = FormControl;\n/**\n * @description\n * Asserts that the given control is an instance of `FormControl`\n *\n * @publicApi\n */\nconst isFormControl = control => control instanceof FormControl;\n\n/**\n * @description\n * A base class for code shared between the `NgModelGroup` and `FormGroupName` directives.\n *\n * @publicApi\n */\nclass AbstractFormGroupDirective extends ControlContainer {\n /**\n * @description\n * The parent control for the group\n *\n * @internal\n */\n // TODO(issue/24571): remove '!'.\n _parent;\n /** @nodoc */\n ngOnInit() {\n this._checkParentType();\n // Register the group with its parent group.\n this.formDirective.addFormGroup(this);\n }\n /** @nodoc */\n ngOnDestroy() {\n if (this.formDirective) {\n // Remove the group from its parent group.\n this.formDirective.removeFormGroup(this);\n }\n }\n /**\n * @description\n * The `FormGroup` bound to this directive.\n */\n get control() {\n return this.formDirective.getFormGroup(this);\n }\n /**\n * @description\n * The path to this group from the top-level directive.\n */\n get path() {\n return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);\n }\n /**\n * @description\n * The top-level directive for this group if present, otherwise null.\n */\n get formDirective() {\n return this._parent ? this._parent.formDirective : null;\n }\n /** @internal */\n _checkParentType() {}\n static ɵfac = /* @__PURE__ */(() => {\n let ɵAbstractFormGroupDirective_BaseFactory;\n return function AbstractFormGroupDirective_Factory(__ngFactoryType__) {\n return (ɵAbstractFormGroupDirective_BaseFactory || (ɵAbstractFormGroupDirective_BaseFactory = i0.ɵɵgetInheritedFactory(AbstractFormGroupDirective)))(__ngFactoryType__ || AbstractFormGroupDirective);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: AbstractFormGroupDirective,\n standalone: false,\n features: [i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(AbstractFormGroupDirective, [{\n type: Directive,\n args: [{\n standalone: false\n }]\n }], null, null);\n})();\nfunction modelParentException() {\n return new ɵRuntimeError(1350 /* RuntimeErrorCode.NGMODEL_IN_FORM_GROUP */, `\n ngModel cannot be used to register form controls with a parent formGroup directive. Try using\n formGroup's partner directive \"formControlName\" instead. Example:\n\n ${formControlNameExample}\n\n Or, if you'd like to avoid registering this form control, indicate that it's standalone in ngModelOptions:\n\n Example:\n\n ${ngModelWithFormGroupExample}`);\n}\nfunction formGroupNameException() {\n return new ɵRuntimeError(1351 /* RuntimeErrorCode.NGMODEL_IN_FORM_GROUP_NAME */, `\n ngModel cannot be used to register form controls with a parent formGroupName or formArrayName directive.\n\n Option 1: Use formControlName instead of ngModel (reactive strategy):\n\n ${formGroupNameExample}\n\n Option 2: Update ngModel's parent be ngModelGroup (template-driven strategy):\n\n ${ngModelGroupExample}`);\n}\nfunction missingNameException() {\n return new ɵRuntimeError(1352 /* RuntimeErrorCode.NGMODEL_WITHOUT_NAME */, `If ngModel is used within a form tag, either the name attribute must be set or the form\n control must be defined as 'standalone' in ngModelOptions.\n\n Example 1: <input [(ngModel)]=\"person.firstName\" name=\"first\">\n Example 2: <input [(ngModel)]=\"person.firstName\" [ngModelOptions]=\"{standalone: true}\">`);\n}\nfunction modelGroupParentException() {\n return new ɵRuntimeError(1353 /* RuntimeErrorCode.NGMODELGROUP_IN_FORM_GROUP */, `\n ngModelGroup cannot be used with a parent formGroup directive.\n\n Option 1: Use formGroupName instead of ngModelGroup (reactive strategy):\n\n ${formGroupNameExample}\n\n Option 2: Use a regular form tag instead of the formGroup directive (template-driven strategy):\n\n ${ngModelGroupExample}`);\n}\nconst modelGroupProvider = {\n provide: ControlContainer,\n useExisting: forwardRef(() => NgModelGroup)\n};\n/**\n * @description\n * Creates and binds a `FormGroup` instance to a DOM element.\n *\n * This directive can only be used as a child of `NgForm` (within `<form>` tags).\n *\n * Use this directive to validate a sub-group of your form separately from the\n * rest of your form, or if some values in your domain model make more sense\n * to consume together in a nested object.\n *\n * Provide a name for the sub-group and it will become the key\n * for the sub-group in the form's full value. If you need direct access, export the directive into\n * a local template variable using `ngModelGroup` (ex: `#myGroup=\"ngModelGroup\"`).\n *\n * @usageNotes\n *\n * ### Consuming controls in a grouping\n *\n * The following example shows you how to combine controls together in a sub-group\n * of the form.\n *\n * {@example forms/ts/ngModelGroup/ng_model_group_example.ts region='Component'}\n *\n * @ngModule FormsModule\n * @publicApi\n */\nclass NgModelGroup extends AbstractFormGroupDirective {\n /**\n * @description\n * Tracks the name of the `NgModelGroup` bound to the directive. The name corresponds\n * to a key in the parent `NgForm`.\n */\n name = '';\n constructor(parent, validators, asyncValidators) {\n super();\n this._parent = parent;\n this._setValidators(validators);\n this._setAsyncValidators(asyncValidators);\n }\n /** @internal */\n _checkParentType() {\n if (!(this._parent instanceof NgModelGroup) && !(this._parent instanceof NgForm) && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw modelGroupParentException();\n }\n }\n static ɵfac = function NgModelGroup_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgModelGroup)(i0.ɵɵdirectiveInject(ControlContainer, 5), i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgModelGroup,\n selectors: [[\"\", \"ngModelGroup\", \"\"]],\n inputs: {\n name: [0, \"ngModelGroup\", \"name\"]\n },\n exportAs: [\"ngModelGroup\"],\n standalone: false,\n features: [i0.ɵɵProvidersFeature([modelGroupProvider]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgModelGroup, [{\n type: Directive,\n args: [{\n selector: '[ngModelGroup]',\n providers: [modelGroupProvider],\n exportAs: 'ngModelGroup',\n standalone: false\n }]\n }], () => [{\n type: ControlContainer,\n decorators: [{\n type: Host\n }, {\n type: SkipSelf\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }], {\n name: [{\n type: Input,\n args: ['ngModelGroup']\n }]\n });\n})();\nconst formControlBinding$1 = {\n provide: NgControl,\n useExisting: forwardRef(() => NgModel)\n};\n/**\n * `ngModel` forces an additional change detection run when its inputs change:\n * E.g.:\n * ```html\n * <div>{{myModel.valid}}</div>\n * <input [(ngModel)]=\"myValue\" #myModel=\"ngModel\">\n * ```\n * I.e. `ngModel` can export itself on the element and then be used in the template.\n * Normally, this would result in expressions before the `input` that use the exported directive\n * to have an old value as they have been\n * dirty checked before. As this is a very common case for `ngModel`, we added this second change\n * detection run.\n *\n * Notes:\n * - this is just one extra run no matter how many `ngModel`s have been changed.\n * - this is a general problem when using `exportAs` for directives!\n */\nconst resolvedPromise = (() => Promise.resolve())();\n/**\n * @description\n * Creates a `FormControl` instance from a [domain\n * model](https://en.wikipedia.org/wiki/Domain_model) and binds it to a form control element.\n *\n * The `FormControl` instance tracks the value, user interaction, and\n * validation status of the control and keeps the view synced with the model. If used\n * within a parent form, the directive also registers itself with the form as a child\n * control.\n *\n * This directive is used by itself or as part of a larger form. Use the\n * `ngModel` selector to activate it.\n *\n * It accepts a domain model as an optional `Input`. If you have a one-way binding\n * to `ngModel` with `[]` syntax, changing the domain model's value in the component\n * class sets the value in the view. If you have a two-way binding with `[()]` syntax\n * (also known as 'banana-in-a-box syntax'), the value in the UI always syncs back to\n * the domain model in your class.\n *\n * To inspect the properties of the associated `FormControl` (like the validity state),\n * export the directive into a local template variable using `ngModel` as the key (ex:\n * `#myVar=\"ngModel\"`). You can then access the control using the directive's `control` property.\n * However, the most commonly used properties (like `valid` and `dirty`) also exist on the control\n * for direct access. See a full list of properties directly available in\n * `AbstractControlDirective`.\n *\n * @see {@link RadioControlValueAccessor}\n * @see {@link SelectControlValueAccessor}\n *\n * @usageNotes\n *\n * ### Using ngModel on a standalone control\n *\n * The following examples show a simple standalone control using `ngModel`:\n *\n * {@example forms/ts/simpleNgModel/simple_ng_model_example.ts region='Component'}\n *\n * When using the `ngModel` within `<form>` tags, you'll also need to supply a `name` attribute\n * so that the control can be registered with the parent form under that name.\n *\n * In the context of a parent form, it's often unnecessary to include one-way or two-way binding,\n * as the parent form syncs the value for you. You access its properties by exporting it into a\n * local template variable using `ngForm` such as (`#f=\"ngForm\"`). Use the variable where\n * needed on form submission.\n *\n * If you do need to populate initial values into your form, using a one-way binding for\n * `ngModel` tends to be sufficient as long as you use the exported form's value rather\n * than the domain model's value on submit.\n *\n * ### Using ngModel within a form\n *\n * The following example shows controls using `ngModel` within a form:\n *\n * {@example forms/ts/simpleForm/simple_form_example.ts region='Component'}\n *\n * ### Using a standalone ngModel within a group\n *\n * The following example shows you how to use a standalone ngModel control\n * within a form. This controls the display of the form, but doesn't contain form data.\n *\n * ```html\n * <form>\n * <input name=\"login\" ngModel placeholder=\"Login\">\n * <input type=\"checkbox\" ngModel [ngModelOptions]=\"{standalone: true}\"> Show more options?\n * </form>\n * <!-- form value: {login: ''} -->\n * ```\n *\n * ### Setting the ngModel `name` attribute through options\n *\n * The following example shows you an alternate way to set the name attribute. Here,\n * an attribute identified as name is used within a custom form control component. To still be able\n * to specify the NgModel's name, you must specify it using the `ngModelOptions` input instead.\n *\n * ```html\n * <form>\n * <my-custom-form-control name=\"Nancy\" ngModel [ngModelOptions]=\"{name: 'user'}\">\n * </my-custom-form-control>\n * </form>\n * <!-- form value: {user: ''} -->\n * ```\n *\n * @ngModule FormsModule\n * @publicApi\n */\nclass NgModel extends NgControl {\n _changeDetectorRef;\n callSetDisabledState;\n control = new FormControl();\n // At runtime we coerce arbitrary values assigned to the \"disabled\" input to a \"boolean\".\n // This is not reflected in the type of the property because outside of templates, consumers\n // should only deal with booleans. In templates, a string is allowed for convenience and to\n // match the native \"disabled attribute\" semantics which can be observed on input elements.\n // This static member tells the compiler that values of type \"string\" can also be assigned\n // to the input in a template.\n /** @nodoc */\n static ngAcceptInputType_isDisabled;\n /** @internal */\n _registered = false;\n /**\n * Internal reference to the view model value.\n * @nodoc\n */\n viewModel;\n /**\n * @description\n * Tracks the name bound to the directive. If a parent form exists, it\n * uses this name as a key to retrieve this control's value.\n */\n name = '';\n /**\n * @description\n * Tracks whether the control is disabled.\n */\n // TODO(issue/24571): remove '!'.\n isDisabled;\n /**\n * @description\n * Tracks the value bound to this directive.\n */\n model;\n /**\n * @description\n * Tracks the configuration options for this `ngModel` instance.\n *\n * **name**: An alternative to setting the name attribute on the form control element. See\n * the [example](api/forms/NgModel#using-ngmodel-on-a-standalone-control) for using `NgModel`\n * as a standalone control.\n *\n * **standalone**: When set to true, the `ngModel` will not register itself with its parent form,\n * and acts as if it's not in the form. Defaults to false. If no parent form exists, this option\n * has no effect.\n *\n * **updateOn**: Defines the event upon which the form control value and validity update.\n * Defaults to 'change'. Possible values: `'change'` | `'blur'` | `'submit'`.\n *\n */\n // TODO(issue/24571): remove '!'.\n options;\n /**\n * @description\n * Event emitter for producing the `ngModelChange` event after\n * the view model updates.\n */\n update = new EventEmitter();\n constructor(parent, validators, asyncValidators, valueAccessors, _changeDetectorRef, callSetDisabledState) {\n super();\n this._changeDetectorRef = _changeDetectorRef;\n this.callSetDisabledState = callSetDisabledState;\n this._parent = parent;\n this._setValidators(validators);\n this._setAsyncValidators(asyncValidators);\n this.valueAccessor = selectValueAccessor(this, valueAccessors);\n }\n /** @nodoc */\n ngOnChanges(changes) {\n this._checkForErrors();\n if (!this._registered || 'name' in changes) {\n if (this._registered) {\n this._checkName();\n if (this.formDirective) {\n // We can't call `formDirective.removeControl(this)`, because the `name` has already been\n // changed. We also can't reset the name temporarily since the logic in `removeControl`\n // is inside a promise and it won't run immediately. We work around it by giving it an\n // object with the same shape instead.\n const oldName = changes['name'].previousValue;\n this.formDirective.removeControl({\n name: oldName,\n path: this._getPath(oldName)\n });\n }\n }\n this._setUpControl();\n }\n if ('isDisabled' in changes) {\n this._updateDisabled(changes);\n }\n if (isPropertyUpdated(changes, this.viewModel)) {\n this._updateValue(this.model);\n this.viewModel = this.model;\n }\n }\n /** @nodoc */\n ngOnDestroy() {\n this.formDirective && this.formDirective.removeControl(this);\n }\n /**\n * @description\n * Returns an array that represents the path from the top-level form to this control.\n * Each index is the string name of the control on that level.\n */\n get path() {\n return this._getPath(this.name);\n }\n /**\n * @description\n * The top-level directive for this control if present, otherwise null.\n */\n get formDirective() {\n return this._parent ? this._parent.formDirective : null;\n }\n /**\n * @description\n * Sets the new value for the view model and emits an `ngModelChange` event.\n *\n * @param newValue The new value emitted by `ngModelChange`.\n */\n viewToModelUpdate(newValue) {\n this.viewModel = newValue;\n this.update.emit(newValue);\n }\n _setUpControl() {\n this._setUpdateStrategy();\n this._isStandalone() ? this._setUpStandalone() : this.formDirective.addControl(this);\n this._registered = true;\n }\n _setUpdateStrategy() {\n if (this.options && this.options.updateOn != null) {\n this.control._updateOn = this.options.updateOn;\n }\n }\n _isStandalone() {\n return !this._parent || !!(this.options && this.options.standalone);\n }\n _setUpStandalone() {\n setUpControl(this.control, this, this.callSetDisabledState);\n this.control.updateValueAndValidity({\n emitEvent: false\n });\n }\n _checkForErrors() {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !this._isStandalone()) {\n checkParentType$1(this._parent);\n }\n this._checkName();\n }\n _checkName() {\n if (this.options && this.options.name) this.name = this.options.name;\n if (!this._isStandalone() && !this.name && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw missingNameException();\n }\n }\n _updateValue(value) {\n resolvedPromise.then(() => {\n this.control.setValue(value, {\n emitViewToModelChange: false\n });\n this._changeDetectorRef?.markForCheck();\n });\n }\n _updateDisabled(changes) {\n const disabledValue = changes['isDisabled'].currentValue;\n // checking for 0 to avoid breaking change\n const isDisabled = disabledValue !== 0 && booleanAttribute(disabledValue);\n resolvedPromise.then(() => {\n if (isDisabled && !this.control.disabled) {\n this.control.disable();\n } else if (!isDisabled && this.control.disabled) {\n this.control.enable();\n }\n this._changeDetectorRef?.markForCheck();\n });\n }\n _getPath(controlName) {\n return this._parent ? controlPath(controlName, this._parent) : [controlName];\n }\n static ɵfac = function NgModel_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgModel)(i0.ɵɵdirectiveInject(ControlContainer, 9), i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_VALUE_ACCESSOR, 10), i0.ɵɵdirectiveInject(ChangeDetectorRef, 8), i0.ɵɵdirectiveInject(CALL_SET_DISABLED_STATE, 8));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgModel,\n selectors: [[\"\", \"ngModel\", \"\", 3, \"formControlName\", \"\", 3, \"formControl\", \"\"]],\n inputs: {\n name: \"name\",\n isDisabled: [0, \"disabled\", \"isDisabled\"],\n model: [0, \"ngModel\", \"model\"],\n options: [0, \"ngModelOptions\", \"options\"]\n },\n outputs: {\n update: \"ngModelChange\"\n },\n exportAs: [\"ngModel\"],\n standalone: false,\n features: [i0.ɵɵProvidersFeature([formControlBinding$1]), i0.ɵɵInheritDefinitionFeature, i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgModel, [{\n type: Directive,\n args: [{\n selector: '[ngModel]:not([formControlName]):not([formControl])',\n providers: [formControlBinding$1],\n exportAs: 'ngModel',\n standalone: false\n }]\n }], () => [{\n type: ControlContainer,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALUE_ACCESSOR]\n }]\n }, {\n type: i0.ChangeDetectorRef,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [ChangeDetectorRef]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [CALL_SET_DISABLED_STATE]\n }]\n }], {\n name: [{\n type: Input\n }],\n isDisabled: [{\n type: Input,\n args: ['disabled']\n }],\n model: [{\n type: Input,\n args: ['ngModel']\n }],\n options: [{\n type: Input,\n args: ['ngModelOptions']\n }],\n update: [{\n type: Output,\n args: ['ngModelChange']\n }]\n });\n})();\nfunction checkParentType$1(parent) {\n if (!(parent instanceof NgModelGroup) && parent instanceof AbstractFormGroupDirective) {\n throw formGroupNameException();\n } else if (!(parent instanceof NgModelGroup) && !(parent instanceof NgForm)) {\n throw modelParentException();\n }\n}\n\n/**\n * @description\n *\n * Adds `novalidate` attribute to all forms by default.\n *\n * `novalidate` is used to disable browser's native form validation.\n *\n * If you want to use native validation with Angular forms, just add `ngNativeValidate` attribute:\n *\n * ```html\n * <form ngNativeValidate></form>\n * ```\n *\n * @publicApi\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n */\nclass ɵNgNoValidate {\n static ɵfac = function ɵNgNoValidate_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ɵNgNoValidate)();\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: ɵNgNoValidate,\n selectors: [[\"form\", 3, \"ngNoForm\", \"\", 3, \"ngNativeValidate\", \"\"]],\n hostAttrs: [\"novalidate\", \"\"],\n standalone: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(ɵNgNoValidate, [{\n type: Directive,\n args: [{\n selector: 'form:not([ngNoForm]):not([ngNativeValidate])',\n host: {\n 'novalidate': ''\n },\n standalone: false\n }]\n }], null, null);\n})();\nconst NUMBER_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => NumberValueAccessor),\n multi: true\n};\n/**\n * @description\n * The `ControlValueAccessor` for writing a number value and listening to number input changes.\n * The value accessor is used by the `FormControlDirective`, `FormControlName`, and `NgModel`\n * directives.\n *\n * @usageNotes\n *\n * ### Using a number input with a reactive form.\n *\n * The following example shows how to use a number input with a reactive form.\n *\n * ```ts\n * const totalCountControl = new FormControl();\n * ```\n *\n * ```html\n * <input type=\"number\" [formControl]=\"totalCountControl\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass NumberValueAccessor extends BuiltInControlValueAccessor {\n /**\n * Sets the \"value\" property on the input element.\n * @nodoc\n */\n writeValue(value) {\n // The value needs to be normalized for IE9, otherwise it is set to 'null' when null\n const normalizedValue = value == null ? '' : value;\n this.setProperty('value', normalizedValue);\n }\n /**\n * Registers a function called when the control value changes.\n * @nodoc\n */\n registerOnChange(fn) {\n this.onChange = value => {\n fn(value == '' ? null : parseFloat(value));\n };\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵNumberValueAccessor_BaseFactory;\n return function NumberValueAccessor_Factory(__ngFactoryType__) {\n return (ɵNumberValueAccessor_BaseFactory || (ɵNumberValueAccessor_BaseFactory = i0.ɵɵgetInheritedFactory(NumberValueAccessor)))(__ngFactoryType__ || NumberValueAccessor);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NumberValueAccessor,\n selectors: [[\"input\", \"type\", \"number\", \"formControlName\", \"\"], [\"input\", \"type\", \"number\", \"formControl\", \"\"], [\"input\", \"type\", \"number\", \"ngModel\", \"\"]],\n hostBindings: function NumberValueAccessor_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"input\", function NumberValueAccessor_input_HostBindingHandler($event) {\n return ctx.onChange($event.target.value);\n })(\"blur\", function NumberValueAccessor_blur_HostBindingHandler() {\n return ctx.onTouched();\n });\n }\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([NUMBER_VALUE_ACCESSOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NumberValueAccessor, [{\n type: Directive,\n args: [{\n selector: 'input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]',\n host: {\n '(input)': 'onChange($event.target.value)',\n '(blur)': 'onTouched()'\n },\n providers: [NUMBER_VALUE_ACCESSOR],\n standalone: false\n }]\n }], null, null);\n})();\nconst RADIO_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => RadioControlValueAccessor),\n multi: true\n};\nfunction throwNameError() {\n throw new ɵRuntimeError(1202 /* RuntimeErrorCode.NAME_AND_FORM_CONTROL_NAME_MUST_MATCH */, `\n If you define both a name and a formControlName attribute on your radio button, their values\n must match. Ex: <input type=\"radio\" formControlName=\"food\" name=\"food\">\n `);\n}\n/**\n * @description\n * Class used by Angular to track radio buttons. For internal use only.\n */\nclass RadioControlRegistry {\n _accessors = [];\n /**\n * @description\n * Adds a control to the internal registry. For internal use only.\n */\n add(control, accessor) {\n this._accessors.push([control, accessor]);\n }\n /**\n * @description\n * Removes a control from the internal registry. For internal use only.\n */\n remove(accessor) {\n for (let i = this._accessors.length - 1; i >= 0; --i) {\n if (this._accessors[i][1] === accessor) {\n this._accessors.splice(i, 1);\n return;\n }\n }\n }\n /**\n * @description\n * Selects a radio button. For internal use only.\n */\n select(accessor) {\n this._accessors.forEach(c => {\n if (this._isSameGroup(c, accessor) && c[1] !== accessor) {\n c[1].fireUncheck(accessor.value);\n }\n });\n }\n _isSameGroup(controlPair, accessor) {\n if (!controlPair[0].control) return false;\n return controlPair[0]._parent === accessor._control._parent && controlPair[1].name === accessor.name;\n }\n static ɵfac = function RadioControlRegistry_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RadioControlRegistry)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: RadioControlRegistry,\n factory: RadioControlRegistry.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RadioControlRegistry, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n/**\n * @description\n * The `ControlValueAccessor` for writing radio control values and listening to radio control\n * changes. The value accessor is used by the `FormControlDirective`, `FormControlName`, and\n * `NgModel` directives.\n *\n * @usageNotes\n *\n * ### Using radio buttons with reactive form directives\n *\n * The follow example shows how to use radio buttons in a reactive form. When using radio buttons in\n * a reactive form, radio buttons in the same group should have the same `formControlName`.\n * Providing a `name` attribute is optional.\n *\n * {@example forms/ts/reactiveRadioButtons/reactive_radio_button_example.ts region='Reactive'}\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass RadioControlValueAccessor extends BuiltInControlValueAccessor {\n _registry;\n _injector;\n /** @internal */\n // TODO(issue/24571): remove '!'.\n _state;\n /** @internal */\n // TODO(issue/24571): remove '!'.\n _control;\n /** @internal */\n // TODO(issue/24571): remove '!'.\n _fn;\n setDisabledStateFired = false;\n /**\n * The registered callback function called when a change event occurs on the input element.\n * Note: we declare `onChange` here (also used as host listener) as a function with no arguments\n * to override the `onChange` function (which expects 1 argument) in the parent\n * `BaseControlValueAccessor` class.\n * @nodoc\n */\n onChange = () => {};\n /**\n * @description\n * Tracks the name of the radio input element.\n */\n // TODO(issue/24571): remove '!'.\n name;\n /**\n * @description\n * Tracks the name of the `FormControl` bound to the directive. The name corresponds\n * to a key in the parent `FormGroup` or `FormArray`.\n */\n // TODO(issue/24571): remove '!'.\n formControlName;\n /**\n * @description\n * Tracks the value of the radio input element\n */\n value;\n callSetDisabledState = inject(CALL_SET_DISABLED_STATE, {\n optional: true\n }) ?? setDisabledStateDefault;\n constructor(renderer, elementRef, _registry, _injector) {\n super(renderer, elementRef);\n this._registry = _registry;\n this._injector = _injector;\n }\n /** @nodoc */\n ngOnInit() {\n this._control = this._injector.get(NgControl);\n this._checkName();\n this._registry.add(this._control, this);\n }\n /** @nodoc */\n ngOnDestroy() {\n this._registry.remove(this);\n }\n /**\n * Sets the \"checked\" property value on the radio input element.\n * @nodoc\n */\n writeValue(value) {\n this._state = value === this.value;\n this.setProperty('checked', this._state);\n }\n /**\n * Registers a function called when the control value changes.\n * @nodoc\n */\n registerOnChange(fn) {\n this._fn = fn;\n this.onChange = () => {\n fn(this.value);\n this._registry.select(this);\n };\n }\n /** @nodoc */\n setDisabledState(isDisabled) {\n /**\n * `setDisabledState` is supposed to be called whenever the disabled state of a control changes,\n * including upon control creation. However, a longstanding bug caused the method to not fire\n * when an *enabled* control was attached. This bug was fixed in v15 in #47576.\n *\n * This had a side effect: previously, it was possible to instantiate a reactive form control\n * with `[attr.disabled]=true`, even though the corresponding control was enabled in the\n * model. This resulted in a mismatch between the model and the DOM. Now, because\n * `setDisabledState` is always called, the value in the DOM will be immediately overwritten\n * with the \"correct\" enabled value.\n *\n * However, the fix also created an exceptional case: radio buttons. Because Reactive Forms\n * models the entire group of radio buttons as a single `FormControl`, there is no way to\n * control the disabled state for individual radios, so they can no longer be configured as\n * disabled. Thus, we keep the old behavior for radio buttons, so that `[attr.disabled]`\n * continues to work. Specifically, we drop the first call to `setDisabledState` if `disabled`\n * is `false`, and we are not in legacy mode.\n */\n if (this.setDisabledStateFired || isDisabled || this.callSetDisabledState === 'whenDisabledForLegacyCode') {\n this.setProperty('disabled', isDisabled);\n }\n this.setDisabledStateFired = true;\n }\n /**\n * Sets the \"value\" on the radio input element and unchecks it.\n *\n * @param value\n */\n fireUncheck(value) {\n this.writeValue(value);\n }\n _checkName() {\n if (this.name && this.formControlName && this.name !== this.formControlName && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throwNameError();\n }\n if (!this.name && this.formControlName) this.name = this.formControlName;\n }\n static ɵfac = function RadioControlValueAccessor_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || RadioControlValueAccessor)(i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(RadioControlRegistry), i0.ɵɵdirectiveInject(i0.Injector));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: RadioControlValueAccessor,\n selectors: [[\"input\", \"type\", \"radio\", \"formControlName\", \"\"], [\"input\", \"type\", \"radio\", \"formControl\", \"\"], [\"input\", \"type\", \"radio\", \"ngModel\", \"\"]],\n hostBindings: function RadioControlValueAccessor_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"change\", function RadioControlValueAccessor_change_HostBindingHandler() {\n return ctx.onChange();\n })(\"blur\", function RadioControlValueAccessor_blur_HostBindingHandler() {\n return ctx.onTouched();\n });\n }\n },\n inputs: {\n name: \"name\",\n formControlName: \"formControlName\",\n value: \"value\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([RADIO_VALUE_ACCESSOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RadioControlValueAccessor, [{\n type: Directive,\n args: [{\n selector: 'input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]',\n host: {\n '(change)': 'onChange()',\n '(blur)': 'onTouched()'\n },\n providers: [RADIO_VALUE_ACCESSOR],\n standalone: false\n }]\n }], () => [{\n type: i0.Renderer2\n }, {\n type: i0.ElementRef\n }, {\n type: RadioControlRegistry\n }, {\n type: i0.Injector\n }], {\n name: [{\n type: Input\n }],\n formControlName: [{\n type: Input\n }],\n value: [{\n type: Input\n }]\n });\n})();\nconst RANGE_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => RangeValueAccessor),\n multi: true\n};\n/**\n * @description\n * The `ControlValueAccessor` for writing a range value and listening to range input changes.\n * The value accessor is used by the `FormControlDirective`, `FormControlName`, and `NgModel`\n * directives.\n *\n * @usageNotes\n *\n * ### Using a range input with a reactive form\n *\n * The following example shows how to use a range input with a reactive form.\n *\n * ```ts\n * const ageControl = new FormControl();\n * ```\n *\n * ```html\n * <input type=\"range\" [formControl]=\"ageControl\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass RangeValueAccessor extends BuiltInControlValueAccessor {\n /**\n * Sets the \"value\" property on the input element.\n * @nodoc\n */\n writeValue(value) {\n this.setProperty('value', parseFloat(value));\n }\n /**\n * Registers a function called when the control value changes.\n * @nodoc\n */\n registerOnChange(fn) {\n this.onChange = value => {\n fn(value == '' ? null : parseFloat(value));\n };\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵRangeValueAccessor_BaseFactory;\n return function RangeValueAccessor_Factory(__ngFactoryType__) {\n return (ɵRangeValueAccessor_BaseFactory || (ɵRangeValueAccessor_BaseFactory = i0.ɵɵgetInheritedFactory(RangeValueAccessor)))(__ngFactoryType__ || RangeValueAccessor);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: RangeValueAccessor,\n selectors: [[\"input\", \"type\", \"range\", \"formControlName\", \"\"], [\"input\", \"type\", \"range\", \"formControl\", \"\"], [\"input\", \"type\", \"range\", \"ngModel\", \"\"]],\n hostBindings: function RangeValueAccessor_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"change\", function RangeValueAccessor_change_HostBindingHandler($event) {\n return ctx.onChange($event.target.value);\n })(\"input\", function RangeValueAccessor_input_HostBindingHandler($event) {\n return ctx.onChange($event.target.value);\n })(\"blur\", function RangeValueAccessor_blur_HostBindingHandler() {\n return ctx.onTouched();\n });\n }\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([RANGE_VALUE_ACCESSOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RangeValueAccessor, [{\n type: Directive,\n args: [{\n selector: 'input[type=range][formControlName],input[type=range][formControl],input[type=range][ngModel]',\n host: {\n '(change)': 'onChange($event.target.value)',\n '(input)': 'onChange($event.target.value)',\n '(blur)': 'onTouched()'\n },\n providers: [RANGE_VALUE_ACCESSOR],\n standalone: false\n }]\n }], null, null);\n})();\n\n/**\n * Token to provide to turn off the ngModel warning on formControl and formControlName.\n */\nconst NG_MODEL_WITH_FORM_CONTROL_WARNING = new InjectionToken(ngDevMode ? 'NgModelWithFormControlWarning' : '');\nconst formControlBinding = {\n provide: NgControl,\n useExisting: forwardRef(() => FormControlDirective)\n};\n/**\n * @description\n * Synchronizes a standalone `FormControl` instance to a form control element.\n *\n * Note that support for using the `ngModel` input property and `ngModelChange` event with reactive\n * form directives was deprecated in Angular v6 and is scheduled for removal in\n * a future version of Angular.\n *\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n * @see {@link FormControl}\n * @see {@link AbstractControl}\n *\n * @usageNotes\n *\n * The following example shows how to register a standalone control and set its value.\n *\n * {@example forms/ts/simpleFormControl/simple_form_control_example.ts region='Component'}\n *\n * @ngModule ReactiveFormsModule\n * @publicApi\n */\nclass FormControlDirective extends NgControl {\n _ngModelWarningConfig;\n callSetDisabledState;\n /**\n * Internal reference to the view model value.\n * @nodoc\n */\n viewModel;\n /**\n * @description\n * Tracks the `FormControl` instance bound to the directive.\n */\n // TODO(issue/24571): remove '!'.\n form;\n /**\n * @description\n * Triggers a warning in dev mode that this input should not be used with reactive forms.\n */\n set isDisabled(isDisabled) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n console.warn(disabledAttrWarning);\n }\n }\n // TODO(kara): remove next 4 properties once deprecation period is over\n /** @deprecated as of v6 */\n model;\n /** @deprecated as of v6 */\n update = new EventEmitter();\n /**\n * @description\n * Static property used to track whether any ngModel warnings have been sent across\n * all instances of FormControlDirective. Used to support warning config of \"once\".\n *\n * @internal\n */\n static _ngModelWarningSentOnce = false;\n /**\n * @description\n * Instance property used to track whether an ngModel warning has been sent out for this\n * particular `FormControlDirective` instance. Used to support warning config of \"always\".\n *\n * @internal\n */\n _ngModelWarningSent = false;\n constructor(validators, asyncValidators, valueAccessors, _ngModelWarningConfig, callSetDisabledState) {\n super();\n this._ngModelWarningConfig = _ngModelWarningConfig;\n this.callSetDisabledState = callSetDisabledState;\n this._setValidators(validators);\n this._setAsyncValidators(asyncValidators);\n this.valueAccessor = selectValueAccessor(this, valueAccessors);\n }\n /** @nodoc */\n ngOnChanges(changes) {\n if (this._isControlChanged(changes)) {\n const previousForm = changes['form'].previousValue;\n if (previousForm) {\n cleanUpControl(previousForm, this, /* validateControlPresenceOnChange */false);\n }\n setUpControl(this.form, this, this.callSetDisabledState);\n this.form.updateValueAndValidity({\n emitEvent: false\n });\n }\n if (isPropertyUpdated(changes, this.viewModel)) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n _ngModelWarning('formControl', FormControlDirective, this, this._ngModelWarningConfig);\n }\n this.form.setValue(this.model);\n this.viewModel = this.model;\n }\n }\n /** @nodoc */\n ngOnDestroy() {\n if (this.form) {\n cleanUpControl(this.form, this, /* validateControlPresenceOnChange */false);\n }\n }\n /**\n * @description\n * Returns an array that represents the path from the top-level form to this control.\n * Each index is the string name of the control on that level.\n */\n get path() {\n return [];\n }\n /**\n * @description\n * The `FormControl` bound to this directive.\n */\n get control() {\n return this.form;\n }\n /**\n * @description\n * Sets the new value for the view model and emits an `ngModelChange` event.\n *\n * @param newValue The new value for the view model.\n */\n viewToModelUpdate(newValue) {\n this.viewModel = newValue;\n this.update.emit(newValue);\n }\n _isControlChanged(changes) {\n return changes.hasOwnProperty('form');\n }\n static ɵfac = function FormControlDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FormControlDirective)(i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_VALUE_ACCESSOR, 10), i0.ɵɵdirectiveInject(NG_MODEL_WITH_FORM_CONTROL_WARNING, 8), i0.ɵɵdirectiveInject(CALL_SET_DISABLED_STATE, 8));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: FormControlDirective,\n selectors: [[\"\", \"formControl\", \"\"]],\n inputs: {\n form: [0, \"formControl\", \"form\"],\n isDisabled: [0, \"disabled\", \"isDisabled\"],\n model: [0, \"ngModel\", \"model\"]\n },\n outputs: {\n update: \"ngModelChange\"\n },\n exportAs: [\"ngForm\"],\n standalone: false,\n features: [i0.ɵɵProvidersFeature([formControlBinding]), i0.ɵɵInheritDefinitionFeature, i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FormControlDirective, [{\n type: Directive,\n args: [{\n selector: '[formControl]',\n providers: [formControlBinding],\n exportAs: 'ngForm',\n standalone: false\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALUE_ACCESSOR]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [CALL_SET_DISABLED_STATE]\n }]\n }], {\n form: [{\n type: Input,\n args: ['formControl']\n }],\n isDisabled: [{\n type: Input,\n args: ['disabled']\n }],\n model: [{\n type: Input,\n args: ['ngModel']\n }],\n update: [{\n type: Output,\n args: ['ngModelChange']\n }]\n });\n})();\nconst formDirectiveProvider = {\n provide: ControlContainer,\n useExisting: forwardRef(() => FormGroupDirective)\n};\n/**\n * @description\n *\n * Binds an existing `FormGroup` or `FormRecord` to a DOM element.\n *\n * This directive accepts an existing `FormGroup` instance. It will then use this\n * `FormGroup` instance to match any child `FormControl`, `FormGroup`/`FormRecord`,\n * and `FormArray` instances to child `FormControlName`, `FormGroupName`,\n * and `FormArrayName` directives.\n *\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n * @see {@link AbstractControl}\n *\n * @usageNotes\n * ### Register Form Group\n *\n * The following example registers a `FormGroup` with first name and last name controls,\n * and listens for the *ngSubmit* event when the button is clicked.\n *\n * {@example forms/ts/simpleFormGroup/simple_form_group_example.ts region='Component'}\n *\n * @ngModule ReactiveFormsModule\n * @publicApi\n */\nclass FormGroupDirective extends ControlContainer {\n callSetDisabledState;\n /**\n * @description\n * Reports whether the form submission has been triggered.\n */\n get submitted() {\n return untracked(this._submittedReactive);\n }\n // TODO(atscott): Remove once invalid API usage is cleaned up internally\n set submitted(value) {\n this._submittedReactive.set(value);\n }\n /** @internal */\n _submitted = computed(() => this._submittedReactive());\n _submittedReactive = signal(false);\n /**\n * Reference to an old form group input value, which is needed to cleanup\n * old instance in case it was replaced with a new one.\n */\n _oldForm;\n /**\n * Callback that should be invoked when controls in FormGroup or FormArray collection change\n * (added or removed). This callback triggers corresponding DOM updates.\n */\n _onCollectionChange = () => this._updateDomValue();\n /**\n * @description\n * Tracks the list of added `FormControlName` instances\n */\n directives = [];\n /**\n * @description\n * Tracks the `FormGroup` bound to this directive.\n */\n form = null;\n /**\n * @description\n * Emits an event when the form submission has been triggered.\n */\n ngSubmit = new EventEmitter();\n constructor(validators, asyncValidators, callSetDisabledState) {\n super();\n this.callSetDisabledState = callSetDisabledState;\n this._setValidators(validators);\n this._setAsyncValidators(asyncValidators);\n }\n /** @nodoc */\n ngOnChanges(changes) {\n if ((typeof ngDevMode === 'undefined' || ngDevMode) && !this.form) {\n throw missingFormException();\n }\n if (changes.hasOwnProperty('form')) {\n this._updateValidators();\n this._updateDomValue();\n this._updateRegistrations();\n this._oldForm = this.form;\n }\n }\n /** @nodoc */\n ngOnDestroy() {\n if (this.form) {\n cleanUpValidators(this.form, this);\n // Currently the `onCollectionChange` callback is rewritten each time the\n // `_registerOnCollectionChange` function is invoked. The implication is that cleanup should\n // happen *only* when the `onCollectionChange` callback was set by this directive instance.\n // Otherwise it might cause overriding a callback of some other directive instances. We should\n // consider updating this logic later to make it similar to how `onChange` callbacks are\n // handled, see https://github.com/angular/angular/issues/39732 for additional info.\n if (this.form._onCollectionChange === this._onCollectionChange) {\n this.form._registerOnCollectionChange(() => {});\n }\n }\n }\n /**\n * @description\n * Returns this directive's instance.\n */\n get formDirective() {\n return this;\n }\n /**\n * @description\n * Returns the `FormGroup` bound to this directive.\n */\n get control() {\n return this.form;\n }\n /**\n * @description\n * Returns an array representing the path to this group. Because this directive\n * always lives at the top level of a form, it always an empty array.\n */\n get path() {\n return [];\n }\n /**\n * @description\n * Method that sets up the control directive in this group, re-calculates its value\n * and validity, and adds the instance to the internal list of directives.\n *\n * @param dir The `FormControlName` directive instance.\n */\n addControl(dir) {\n const ctrl = this.form.get(dir.path);\n setUpControl(ctrl, dir, this.callSetDisabledState);\n ctrl.updateValueAndValidity({\n emitEvent: false\n });\n this.directives.push(dir);\n return ctrl;\n }\n /**\n * @description\n * Retrieves the `FormControl` instance from the provided `FormControlName` directive\n *\n * @param dir The `FormControlName` directive instance.\n */\n getControl(dir) {\n return this.form.get(dir.path);\n }\n /**\n * @description\n * Removes the `FormControlName` instance from the internal list of directives\n *\n * @param dir The `FormControlName` directive instance.\n */\n removeControl(dir) {\n cleanUpControl(dir.control || null, dir, /* validateControlPresenceOnChange */false);\n removeListItem$1(this.directives, dir);\n }\n /**\n * Adds a new `FormGroupName` directive instance to the form.\n *\n * @param dir The `FormGroupName` directive instance.\n */\n addFormGroup(dir) {\n this._setUpFormContainer(dir);\n }\n /**\n * Performs the necessary cleanup when a `FormGroupName` directive instance is removed from the\n * view.\n *\n * @param dir The `FormGroupName` directive instance.\n */\n removeFormGroup(dir) {\n this._cleanUpFormContainer(dir);\n }\n /**\n * @description\n * Retrieves the `FormGroup` for a provided `FormGroupName` directive instance\n *\n * @param dir The `FormGroupName` directive instance.\n */\n getFormGroup(dir) {\n return this.form.get(dir.path);\n }\n /**\n * Performs the necessary setup when a `FormArrayName` directive instance is added to the view.\n *\n * @param dir The `FormArrayName` directive instance.\n */\n addFormArray(dir) {\n this._setUpFormContainer(dir);\n }\n /**\n * Performs the necessary cleanup when a `FormArrayName` directive instance is removed from the\n * view.\n *\n * @param dir The `FormArrayName` directive instance.\n */\n removeFormArray(dir) {\n this._cleanUpFormContainer(dir);\n }\n /**\n * @description\n * Retrieves the `FormArray` for a provided `FormArrayName` directive instance.\n *\n * @param dir The `FormArrayName` directive instance.\n */\n getFormArray(dir) {\n return this.form.get(dir.path);\n }\n /**\n * Sets the new value for the provided `FormControlName` directive.\n *\n * @param dir The `FormControlName` directive instance.\n * @param value The new value for the directive's control.\n */\n updateModel(dir, value) {\n const ctrl = this.form.get(dir.path);\n ctrl.setValue(value);\n }\n /**\n * @description\n * Method called with the \"submit\" event is triggered on the form.\n * Triggers the `ngSubmit` emitter to emit the \"submit\" event as its payload.\n *\n * @param $event The \"submit\" event object\n */\n onSubmit($event) {\n this._submittedReactive.set(true);\n syncPendingControls(this.form, this.directives);\n this.ngSubmit.emit($event);\n this.form._events.next(new FormSubmittedEvent(this.control));\n // Forms with `method=\"dialog\"` have some special behavior that won't reload the page and that\n // shouldn't be prevented. Note that we need to null check the `event` and the `target`, because\n // some internal apps call this method directly with the wrong arguments.\n return $event?.target?.method === 'dialog';\n }\n /**\n * @description\n * Method called when the \"reset\" event is triggered on the form.\n */\n onReset() {\n this.resetForm();\n }\n /**\n * @description\n * Resets the form to an initial value and resets its submitted status.\n *\n * @param value The new value for the form.\n */\n resetForm(value = undefined) {\n this.form.reset(value);\n this._submittedReactive.set(false);\n this.form._events.next(new FormResetEvent(this.form));\n }\n /** @internal */\n _updateDomValue() {\n this.directives.forEach(dir => {\n const oldCtrl = dir.control;\n const newCtrl = this.form.get(dir.path);\n if (oldCtrl !== newCtrl) {\n // Note: the value of the `dir.control` may not be defined, for example when it's a first\n // `FormControl` that is added to a `FormGroup` instance (via `addControl` call).\n cleanUpControl(oldCtrl || null, dir);\n // Check whether new control at the same location inside the corresponding `FormGroup` is an\n // instance of `FormControl` and perform control setup only if that's the case.\n // Note: we don't need to clear the list of directives (`this.directives`) here, it would be\n // taken care of in the `removeControl` method invoked when corresponding `formControlName`\n // directive instance is being removed (invoked from `FormControlName.ngOnDestroy`).\n if (isFormControl(newCtrl)) {\n setUpControl(newCtrl, dir, this.callSetDisabledState);\n dir.control = newCtrl;\n }\n }\n });\n this.form._updateTreeValidity({\n emitEvent: false\n });\n }\n _setUpFormContainer(dir) {\n const ctrl = this.form.get(dir.path);\n setUpFormContainer(ctrl, dir);\n // NOTE: this operation looks unnecessary in case no new validators were added in\n // `setUpFormContainer` call. Consider updating this code to match the logic in\n // `_cleanUpFormContainer` function.\n ctrl.updateValueAndValidity({\n emitEvent: false\n });\n }\n _cleanUpFormContainer(dir) {\n if (this.form) {\n const ctrl = this.form.get(dir.path);\n if (ctrl) {\n const isControlUpdated = cleanUpFormContainer(ctrl, dir);\n if (isControlUpdated) {\n // Run validity check only in case a control was updated (i.e. view validators were\n // removed) as removing view validators might cause validity to change.\n ctrl.updateValueAndValidity({\n emitEvent: false\n });\n }\n }\n }\n }\n _updateRegistrations() {\n this.form._registerOnCollectionChange(this._onCollectionChange);\n if (this._oldForm) {\n this._oldForm._registerOnCollectionChange(() => {});\n }\n }\n _updateValidators() {\n setUpValidators(this.form, this);\n if (this._oldForm) {\n cleanUpValidators(this._oldForm, this);\n }\n }\n static ɵfac = function FormGroupDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FormGroupDirective)(i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10), i0.ɵɵdirectiveInject(CALL_SET_DISABLED_STATE, 8));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: FormGroupDirective,\n selectors: [[\"\", \"formGroup\", \"\"]],\n hostBindings: function FormGroupDirective_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"submit\", function FormGroupDirective_submit_HostBindingHandler($event) {\n return ctx.onSubmit($event);\n })(\"reset\", function FormGroupDirective_reset_HostBindingHandler() {\n return ctx.onReset();\n });\n }\n },\n inputs: {\n form: [0, \"formGroup\", \"form\"]\n },\n outputs: {\n ngSubmit: \"ngSubmit\"\n },\n exportAs: [\"ngForm\"],\n standalone: false,\n features: [i0.ɵɵProvidersFeature([formDirectiveProvider]), i0.ɵɵInheritDefinitionFeature, i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FormGroupDirective, [{\n type: Directive,\n args: [{\n selector: '[formGroup]',\n providers: [formDirectiveProvider],\n host: {\n '(submit)': 'onSubmit($event)',\n '(reset)': 'onReset()'\n },\n exportAs: 'ngForm',\n standalone: false\n }]\n }], () => [{\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [CALL_SET_DISABLED_STATE]\n }]\n }], {\n form: [{\n type: Input,\n args: ['formGroup']\n }],\n ngSubmit: [{\n type: Output\n }]\n });\n})();\nconst formGroupNameProvider = {\n provide: ControlContainer,\n useExisting: forwardRef(() => FormGroupName)\n};\n/**\n * @description\n *\n * Syncs a nested `FormGroup` or `FormRecord` to a DOM element.\n *\n * This directive can only be used with a parent `FormGroupDirective`.\n *\n * It accepts the string name of the nested `FormGroup` or `FormRecord` to link, and\n * looks for a `FormGroup` or `FormRecord` registered with that name in the parent\n * `FormGroup` instance you passed into `FormGroupDirective`.\n *\n * Use nested form groups to validate a sub-group of a\n * form separately from the rest or to group the values of certain\n * controls into their own nested object.\n *\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n *\n * @usageNotes\n *\n * ### Access the group by name\n *\n * The following example uses the `AbstractControl.get` method to access the\n * associated `FormGroup`\n *\n * ```ts\n * this.form.get('name');\n * ```\n *\n * ### Access individual controls in the group\n *\n * The following example uses the `AbstractControl.get` method to access\n * individual controls within the group using dot syntax.\n *\n * ```ts\n * this.form.get('name.first');\n * ```\n *\n * ### Register a nested `FormGroup`.\n *\n * The following example registers a nested *name* `FormGroup` within an existing `FormGroup`,\n * and provides methods to retrieve the nested `FormGroup` and individual controls.\n *\n * {@example forms/ts/nestedFormGroup/nested_form_group_example.ts region='Component'}\n *\n * @ngModule ReactiveFormsModule\n * @publicApi\n */\nclass FormGroupName extends AbstractFormGroupDirective {\n /**\n * @description\n * Tracks the name of the `FormGroup` bound to the directive. The name corresponds\n * to a key in the parent `FormGroup` or `FormArray`.\n * Accepts a name as a string or a number.\n * The name in the form of a string is useful for individual forms,\n * while the numerical form allows for form groups to be bound\n * to indices when iterating over groups in a `FormArray`.\n */\n name = null;\n constructor(parent, validators, asyncValidators) {\n super();\n this._parent = parent;\n this._setValidators(validators);\n this._setAsyncValidators(asyncValidators);\n }\n /** @internal */\n _checkParentType() {\n if (hasInvalidParent(this._parent) && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw groupParentException();\n }\n }\n static ɵfac = function FormGroupName_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FormGroupName)(i0.ɵɵdirectiveInject(ControlContainer, 13), i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: FormGroupName,\n selectors: [[\"\", \"formGroupName\", \"\"]],\n inputs: {\n name: [0, \"formGroupName\", \"name\"]\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([formGroupNameProvider]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FormGroupName, [{\n type: Directive,\n args: [{\n selector: '[formGroupName]',\n providers: [formGroupNameProvider],\n standalone: false\n }]\n }], () => [{\n type: ControlContainer,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }, {\n type: SkipSelf\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }], {\n name: [{\n type: Input,\n args: ['formGroupName']\n }]\n });\n})();\nconst formArrayNameProvider = {\n provide: ControlContainer,\n useExisting: forwardRef(() => FormArrayName)\n};\n/**\n * @description\n *\n * Syncs a nested `FormArray` to a DOM element.\n *\n * This directive is designed to be used with a parent `FormGroupDirective` (selector:\n * `[formGroup]`).\n *\n * It accepts the string name of the nested `FormArray` you want to link, and\n * will look for a `FormArray` registered with that name in the parent\n * `FormGroup` instance you passed into `FormGroupDirective`.\n *\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n * @see {@link AbstractControl}\n *\n * @usageNotes\n *\n * ### Example\n *\n * {@example forms/ts/nestedFormArray/nested_form_array_example.ts region='Component'}\n *\n * @ngModule ReactiveFormsModule\n * @publicApi\n */\nclass FormArrayName extends ControlContainer {\n /** @internal */\n _parent;\n /**\n * @description\n * Tracks the name of the `FormArray` bound to the directive. The name corresponds\n * to a key in the parent `FormGroup` or `FormArray`.\n * Accepts a name as a string or a number.\n * The name in the form of a string is useful for individual forms,\n * while the numerical form allows for form arrays to be bound\n * to indices when iterating over arrays in a `FormArray`.\n */\n name = null;\n constructor(parent, validators, asyncValidators) {\n super();\n this._parent = parent;\n this._setValidators(validators);\n this._setAsyncValidators(asyncValidators);\n }\n /**\n * A lifecycle method called when the directive's inputs are initialized. For internal use only.\n * @throws If the directive does not have a valid parent.\n * @nodoc\n */\n ngOnInit() {\n if (hasInvalidParent(this._parent) && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw arrayParentException();\n }\n this.formDirective.addFormArray(this);\n }\n /**\n * A lifecycle method called before the directive's instance is destroyed. For internal use only.\n * @nodoc\n */\n ngOnDestroy() {\n this.formDirective?.removeFormArray(this);\n }\n /**\n * @description\n * The `FormArray` bound to this directive.\n */\n get control() {\n return this.formDirective.getFormArray(this);\n }\n /**\n * @description\n * The top-level directive for this group if present, otherwise null.\n */\n get formDirective() {\n return this._parent ? this._parent.formDirective : null;\n }\n /**\n * @description\n * Returns an array that represents the path from the top-level form to this control.\n * Each index is the string name of the control on that level.\n */\n get path() {\n return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);\n }\n static ɵfac = function FormArrayName_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FormArrayName)(i0.ɵɵdirectiveInject(ControlContainer, 13), i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: FormArrayName,\n selectors: [[\"\", \"formArrayName\", \"\"]],\n inputs: {\n name: [0, \"formArrayName\", \"name\"]\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([formArrayNameProvider]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FormArrayName, [{\n type: Directive,\n args: [{\n selector: '[formArrayName]',\n providers: [formArrayNameProvider],\n standalone: false\n }]\n }], () => [{\n type: ControlContainer,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }, {\n type: SkipSelf\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }], {\n name: [{\n type: Input,\n args: ['formArrayName']\n }]\n });\n})();\nfunction hasInvalidParent(parent) {\n return !(parent instanceof FormGroupName) && !(parent instanceof FormGroupDirective) && !(parent instanceof FormArrayName);\n}\nconst controlNameBinding = {\n provide: NgControl,\n useExisting: forwardRef(() => FormControlName)\n};\n/**\n * @description\n * Syncs a `FormControl` in an existing `FormGroup` to a form control\n * element by name.\n *\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n * @see {@link FormControl}\n * @see {@link AbstractControl}\n *\n * @usageNotes\n *\n * ### Register `FormControl` within a group\n *\n * The following example shows how to register multiple form controls within a form group\n * and set their value.\n *\n * {@example forms/ts/simpleFormGroup/simple_form_group_example.ts region='Component'}\n *\n * To see `formControlName` examples with different form control types, see:\n *\n * * Radio buttons: `RadioControlValueAccessor`\n * * Selects: `SelectControlValueAccessor`\n *\n * ### Use with ngModel is deprecated\n *\n * Support for using the `ngModel` input property and `ngModelChange` event with reactive\n * form directives has been deprecated in Angular v6 and is scheduled for removal in\n * a future version of Angular.\n *\n * @ngModule ReactiveFormsModule\n * @publicApi\n */\nclass FormControlName extends NgControl {\n _ngModelWarningConfig;\n _added = false;\n /**\n * Internal reference to the view model value.\n * @internal\n */\n viewModel;\n /**\n * @description\n * Tracks the `FormControl` instance bound to the directive.\n */\n // TODO(issue/24571): remove '!'.\n control;\n /**\n * @description\n * Tracks the name of the `FormControl` bound to the directive. The name corresponds\n * to a key in the parent `FormGroup` or `FormArray`.\n * Accepts a name as a string or a number.\n * The name in the form of a string is useful for individual forms,\n * while the numerical form allows for form controls to be bound\n * to indices when iterating over controls in a `FormArray`.\n */\n name = null;\n /**\n * @description\n * Triggers a warning in dev mode that this input should not be used with reactive forms.\n */\n set isDisabled(isDisabled) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n console.warn(disabledAttrWarning);\n }\n }\n // TODO(kara): remove next 4 properties once deprecation period is over\n /** @deprecated as of v6 */\n model;\n /** @deprecated as of v6 */\n update = new EventEmitter();\n /**\n * @description\n * Static property used to track whether any ngModel warnings have been sent across\n * all instances of FormControlName. Used to support warning config of \"once\".\n *\n * @internal\n */\n static _ngModelWarningSentOnce = false;\n /**\n * @description\n * Instance property used to track whether an ngModel warning has been sent out for this\n * particular FormControlName instance. Used to support warning config of \"always\".\n *\n * @internal\n */\n _ngModelWarningSent = false;\n constructor(parent, validators, asyncValidators, valueAccessors, _ngModelWarningConfig) {\n super();\n this._ngModelWarningConfig = _ngModelWarningConfig;\n this._parent = parent;\n this._setValidators(validators);\n this._setAsyncValidators(asyncValidators);\n this.valueAccessor = selectValueAccessor(this, valueAccessors);\n }\n /** @nodoc */\n ngOnChanges(changes) {\n if (!this._added) this._setUpControl();\n if (isPropertyUpdated(changes, this.viewModel)) {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n _ngModelWarning('formControlName', FormControlName, this, this._ngModelWarningConfig);\n }\n this.viewModel = this.model;\n this.formDirective.updateModel(this, this.model);\n }\n }\n /** @nodoc */\n ngOnDestroy() {\n if (this.formDirective) {\n this.formDirective.removeControl(this);\n }\n }\n /**\n * @description\n * Sets the new value for the view model and emits an `ngModelChange` event.\n *\n * @param newValue The new value for the view model.\n */\n viewToModelUpdate(newValue) {\n this.viewModel = newValue;\n this.update.emit(newValue);\n }\n /**\n * @description\n * Returns an array that represents the path from the top-level form to this control.\n * Each index is the string name of the control on that level.\n */\n get path() {\n return controlPath(this.name == null ? this.name : this.name.toString(), this._parent);\n }\n /**\n * @description\n * The top-level directive for this group if present, otherwise null.\n */\n get formDirective() {\n return this._parent ? this._parent.formDirective : null;\n }\n _setUpControl() {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n checkParentType(this._parent, this.name);\n }\n this.control = this.formDirective.addControl(this);\n this._added = true;\n }\n static ɵfac = function FormControlName_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FormControlName)(i0.ɵɵdirectiveInject(ControlContainer, 13), i0.ɵɵdirectiveInject(NG_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_ASYNC_VALIDATORS, 10), i0.ɵɵdirectiveInject(NG_VALUE_ACCESSOR, 10), i0.ɵɵdirectiveInject(NG_MODEL_WITH_FORM_CONTROL_WARNING, 8));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: FormControlName,\n selectors: [[\"\", \"formControlName\", \"\"]],\n inputs: {\n name: [0, \"formControlName\", \"name\"],\n isDisabled: [0, \"disabled\", \"isDisabled\"],\n model: [0, \"ngModel\", \"model\"]\n },\n outputs: {\n update: \"ngModelChange\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([controlNameBinding]), i0.ɵɵInheritDefinitionFeature, i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FormControlName, [{\n type: Directive,\n args: [{\n selector: '[formControlName]',\n providers: [controlNameBinding],\n standalone: false\n }]\n }], () => [{\n type: ControlContainer,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }, {\n type: SkipSelf\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_ASYNC_VALIDATORS]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Self\n }, {\n type: Inject,\n args: [NG_VALUE_ACCESSOR]\n }]\n }, {\n type: undefined,\n decorators: [{\n type: Optional\n }, {\n type: Inject,\n args: [NG_MODEL_WITH_FORM_CONTROL_WARNING]\n }]\n }], {\n name: [{\n type: Input,\n args: ['formControlName']\n }],\n isDisabled: [{\n type: Input,\n args: ['disabled']\n }],\n model: [{\n type: Input,\n args: ['ngModel']\n }],\n update: [{\n type: Output,\n args: ['ngModelChange']\n }]\n });\n})();\nfunction checkParentType(parent, name) {\n if (!(parent instanceof FormGroupName) && parent instanceof AbstractFormGroupDirective) {\n throw ngModelGroupException();\n } else if (!(parent instanceof FormGroupName) && !(parent instanceof FormGroupDirective) && !(parent instanceof FormArrayName)) {\n throw controlParentException(name);\n }\n}\nconst SELECT_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => SelectControlValueAccessor),\n multi: true\n};\nfunction _buildValueString$1(id, value) {\n if (id == null) return `${value}`;\n if (value && typeof value === 'object') value = 'Object';\n return `${id}: ${value}`.slice(0, 50);\n}\nfunction _extractId$1(valueString) {\n return valueString.split(':')[0];\n}\n/**\n * @description\n * The `ControlValueAccessor` for writing select control values and listening to select control\n * changes. The value accessor is used by the `FormControlDirective`, `FormControlName`, and\n * `NgModel` directives.\n *\n * @usageNotes\n *\n * ### Using select controls in a reactive form\n *\n * The following examples show how to use a select control in a reactive form.\n *\n * {@example forms/ts/reactiveSelectControl/reactive_select_control_example.ts region='Component'}\n *\n * ### Using select controls in a template-driven form\n *\n * To use a select in a template-driven form, simply add an `ngModel` and a `name`\n * attribute to the main `<select>` tag.\n *\n * {@example forms/ts/selectControl/select_control_example.ts region='Component'}\n *\n * ### Customizing option selection\n *\n * Angular uses object identity to select option. It's possible for the identities of items\n * to change while the data does not. This can happen, for example, if the items are produced\n * from an RPC to the server, and that RPC is re-run. Even if the data hasn't changed, the\n * second response will produce objects with different identities.\n *\n * To customize the default option comparison algorithm, `<select>` supports `compareWith` input.\n * `compareWith` takes a **function** which has two arguments: `option1` and `option2`.\n * If `compareWith` is given, Angular selects option by the return value of the function.\n *\n * ```ts\n * const selectedCountriesControl = new FormControl();\n * ```\n *\n * ```html\n * <select [compareWith]=\"compareFn\" [formControl]=\"selectedCountriesControl\">\n * <option *ngFor=\"let country of countries\" [ngValue]=\"country\">\n * {{country.name}}\n * </option>\n * </select>\n *\n * compareFn(c1: Country, c2: Country): boolean {\n * return c1 && c2 ? c1.id === c2.id : c1 === c2;\n * }\n * ```\n *\n * **Note:** We listen to the 'change' event because 'input' events aren't fired\n * for selects in IE, see:\n * https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/input_event#browser_compatibility\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass SelectControlValueAccessor extends BuiltInControlValueAccessor {\n /** @nodoc */\n value;\n /** @internal */\n _optionMap = new Map();\n /** @internal */\n _idCounter = 0;\n /**\n * @description\n * Tracks the option comparison algorithm for tracking identities when\n * checking for changes.\n */\n set compareWith(fn) {\n if (typeof fn !== 'function' && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw new ɵRuntimeError(1201 /* RuntimeErrorCode.COMPAREWITH_NOT_A_FN */, `compareWith must be a function, but received ${JSON.stringify(fn)}`);\n }\n this._compareWith = fn;\n }\n _compareWith = Object.is;\n /**\n * Sets the \"value\" property on the select element.\n * @nodoc\n */\n writeValue(value) {\n this.value = value;\n const id = this._getOptionId(value);\n const valueString = _buildValueString$1(id, value);\n this.setProperty('value', valueString);\n }\n /**\n * Registers a function called when the control value changes.\n * @nodoc\n */\n registerOnChange(fn) {\n this.onChange = valueString => {\n this.value = this._getOptionValue(valueString);\n fn(this.value);\n };\n }\n /** @internal */\n _registerOption() {\n return (this._idCounter++).toString();\n }\n /** @internal */\n _getOptionId(value) {\n for (const id of this._optionMap.keys()) {\n if (this._compareWith(this._optionMap.get(id), value)) return id;\n }\n return null;\n }\n /** @internal */\n _getOptionValue(valueString) {\n const id = _extractId$1(valueString);\n return this._optionMap.has(id) ? this._optionMap.get(id) : valueString;\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵSelectControlValueAccessor_BaseFactory;\n return function SelectControlValueAccessor_Factory(__ngFactoryType__) {\n return (ɵSelectControlValueAccessor_BaseFactory || (ɵSelectControlValueAccessor_BaseFactory = i0.ɵɵgetInheritedFactory(SelectControlValueAccessor)))(__ngFactoryType__ || SelectControlValueAccessor);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: SelectControlValueAccessor,\n selectors: [[\"select\", \"formControlName\", \"\", 3, \"multiple\", \"\"], [\"select\", \"formControl\", \"\", 3, \"multiple\", \"\"], [\"select\", \"ngModel\", \"\", 3, \"multiple\", \"\"]],\n hostBindings: function SelectControlValueAccessor_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"change\", function SelectControlValueAccessor_change_HostBindingHandler($event) {\n return ctx.onChange($event.target.value);\n })(\"blur\", function SelectControlValueAccessor_blur_HostBindingHandler() {\n return ctx.onTouched();\n });\n }\n },\n inputs: {\n compareWith: \"compareWith\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([SELECT_VALUE_ACCESSOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(SelectControlValueAccessor, [{\n type: Directive,\n args: [{\n selector: 'select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]',\n host: {\n '(change)': 'onChange($event.target.value)',\n '(blur)': 'onTouched()'\n },\n providers: [SELECT_VALUE_ACCESSOR],\n standalone: false\n }]\n }], null, {\n compareWith: [{\n type: Input\n }]\n });\n})();\n/**\n * @description\n * Marks `<option>` as dynamic, so Angular can be notified when options change.\n *\n * @see {@link SelectControlValueAccessor}\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass NgSelectOption {\n _element;\n _renderer;\n _select;\n /**\n * @description\n * ID of the option element\n */\n // TODO(issue/24571): remove '!'.\n id;\n constructor(_element, _renderer, _select) {\n this._element = _element;\n this._renderer = _renderer;\n this._select = _select;\n if (this._select) this.id = this._select._registerOption();\n }\n /**\n * @description\n * Tracks the value bound to the option element. Unlike the value binding,\n * ngValue supports binding to objects.\n */\n set ngValue(value) {\n if (this._select == null) return;\n this._select._optionMap.set(this.id, value);\n this._setElementValue(_buildValueString$1(this.id, value));\n this._select.writeValue(this._select.value);\n }\n /**\n * @description\n * Tracks simple string values bound to the option element.\n * For objects, use the `ngValue` input binding.\n */\n set value(value) {\n this._setElementValue(value);\n if (this._select) this._select.writeValue(this._select.value);\n }\n /** @internal */\n _setElementValue(value) {\n this._renderer.setProperty(this._element.nativeElement, 'value', value);\n }\n /** @nodoc */\n ngOnDestroy() {\n if (this._select) {\n this._select._optionMap.delete(this.id);\n this._select.writeValue(this._select.value);\n }\n }\n static ɵfac = function NgSelectOption_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NgSelectOption)(i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(SelectControlValueAccessor, 9));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: NgSelectOption,\n selectors: [[\"option\"]],\n inputs: {\n ngValue: \"ngValue\",\n value: \"value\"\n },\n standalone: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NgSelectOption, [{\n type: Directive,\n args: [{\n selector: 'option',\n standalone: false\n }]\n }], () => [{\n type: i0.ElementRef\n }, {\n type: i0.Renderer2\n }, {\n type: SelectControlValueAccessor,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }]\n }], {\n ngValue: [{\n type: Input,\n args: ['ngValue']\n }],\n value: [{\n type: Input,\n args: ['value']\n }]\n });\n})();\nconst SELECT_MULTIPLE_VALUE_ACCESSOR = {\n provide: NG_VALUE_ACCESSOR,\n useExisting: forwardRef(() => SelectMultipleControlValueAccessor),\n multi: true\n};\nfunction _buildValueString(id, value) {\n if (id == null) return `${value}`;\n if (typeof value === 'string') value = `'${value}'`;\n if (value && typeof value === 'object') value = 'Object';\n return `${id}: ${value}`.slice(0, 50);\n}\nfunction _extractId(valueString) {\n return valueString.split(':')[0];\n}\n/** Mock interface for HTMLCollection */\nclass HTMLCollection {\n // TODO(issue/24571): remove '!'.\n length;\n}\n/**\n * @description\n * The `ControlValueAccessor` for writing multi-select control values and listening to multi-select\n * control changes. The value accessor is used by the `FormControlDirective`, `FormControlName`, and\n * `NgModel` directives.\n *\n * @see {@link SelectControlValueAccessor}\n *\n * @usageNotes\n *\n * ### Using a multi-select control\n *\n * The follow example shows you how to use a multi-select control with a reactive form.\n *\n * ```ts\n * const countryControl = new FormControl();\n * ```\n *\n * ```html\n * <select multiple name=\"countries\" [formControl]=\"countryControl\">\n * <option *ngFor=\"let country of countries\" [ngValue]=\"country\">\n * {{ country.name }}\n * </option>\n * </select>\n * ```\n *\n * ### Customizing option selection\n *\n * To customize the default option comparison algorithm, `<select>` supports `compareWith` input.\n * See the `SelectControlValueAccessor` for usage.\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass SelectMultipleControlValueAccessor extends BuiltInControlValueAccessor {\n /**\n * The current value.\n * @nodoc\n */\n value;\n /** @internal */\n _optionMap = new Map();\n /** @internal */\n _idCounter = 0;\n /**\n * @description\n * Tracks the option comparison algorithm for tracking identities when\n * checking for changes.\n */\n set compareWith(fn) {\n if (typeof fn !== 'function' && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw new ɵRuntimeError(1201 /* RuntimeErrorCode.COMPAREWITH_NOT_A_FN */, `compareWith must be a function, but received ${JSON.stringify(fn)}`);\n }\n this._compareWith = fn;\n }\n _compareWith = Object.is;\n /**\n * Sets the \"value\" property on one or of more of the select's options.\n * @nodoc\n */\n writeValue(value) {\n this.value = value;\n let optionSelectedStateSetter;\n if (Array.isArray(value)) {\n // convert values to ids\n const ids = value.map(v => this._getOptionId(v));\n optionSelectedStateSetter = (opt, o) => {\n opt._setSelected(ids.indexOf(o.toString()) > -1);\n };\n } else {\n optionSelectedStateSetter = (opt, o) => {\n opt._setSelected(false);\n };\n }\n this._optionMap.forEach(optionSelectedStateSetter);\n }\n /**\n * Registers a function called when the control value changes\n * and writes an array of the selected options.\n * @nodoc\n */\n registerOnChange(fn) {\n this.onChange = element => {\n const selected = [];\n const selectedOptions = element.selectedOptions;\n if (selectedOptions !== undefined) {\n const options = selectedOptions;\n for (let i = 0; i < options.length; i++) {\n const opt = options[i];\n const val = this._getOptionValue(opt.value);\n selected.push(val);\n }\n }\n // Degrade to use `options` when `selectedOptions` property is not available.\n // Note: the `selectedOptions` is available in all supported browsers, but the Domino lib\n // doesn't have it currently, see https://github.com/fgnass/domino/issues/177.\n else {\n const options = element.options;\n for (let i = 0; i < options.length; i++) {\n const opt = options[i];\n if (opt.selected) {\n const val = this._getOptionValue(opt.value);\n selected.push(val);\n }\n }\n }\n this.value = selected;\n fn(selected);\n };\n }\n /** @internal */\n _registerOption(value) {\n const id = (this._idCounter++).toString();\n this._optionMap.set(id, value);\n return id;\n }\n /** @internal */\n _getOptionId(value) {\n for (const id of this._optionMap.keys()) {\n if (this._compareWith(this._optionMap.get(id)._value, value)) return id;\n }\n return null;\n }\n /** @internal */\n _getOptionValue(valueString) {\n const id = _extractId(valueString);\n return this._optionMap.has(id) ? this._optionMap.get(id)._value : valueString;\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵSelectMultipleControlValueAccessor_BaseFactory;\n return function SelectMultipleControlValueAccessor_Factory(__ngFactoryType__) {\n return (ɵSelectMultipleControlValueAccessor_BaseFactory || (ɵSelectMultipleControlValueAccessor_BaseFactory = i0.ɵɵgetInheritedFactory(SelectMultipleControlValueAccessor)))(__ngFactoryType__ || SelectMultipleControlValueAccessor);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: SelectMultipleControlValueAccessor,\n selectors: [[\"select\", \"multiple\", \"\", \"formControlName\", \"\"], [\"select\", \"multiple\", \"\", \"formControl\", \"\"], [\"select\", \"multiple\", \"\", \"ngModel\", \"\"]],\n hostBindings: function SelectMultipleControlValueAccessor_HostBindings(rf, ctx) {\n if (rf & 1) {\n i0.ɵɵlistener(\"change\", function SelectMultipleControlValueAccessor_change_HostBindingHandler($event) {\n return ctx.onChange($event.target);\n })(\"blur\", function SelectMultipleControlValueAccessor_blur_HostBindingHandler() {\n return ctx.onTouched();\n });\n }\n },\n inputs: {\n compareWith: \"compareWith\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([SELECT_MULTIPLE_VALUE_ACCESSOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(SelectMultipleControlValueAccessor, [{\n type: Directive,\n args: [{\n selector: 'select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]',\n host: {\n '(change)': 'onChange($event.target)',\n '(blur)': 'onTouched()'\n },\n providers: [SELECT_MULTIPLE_VALUE_ACCESSOR],\n standalone: false\n }]\n }], null, {\n compareWith: [{\n type: Input\n }]\n });\n})();\n/**\n * @description\n * Marks `<option>` as dynamic, so Angular can be notified when options change.\n *\n * @see {@link SelectMultipleControlValueAccessor}\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass ɵNgSelectMultipleOption {\n _element;\n _renderer;\n _select;\n // TODO(issue/24571): remove '!'.\n id;\n /** @internal */\n _value;\n constructor(_element, _renderer, _select) {\n this._element = _element;\n this._renderer = _renderer;\n this._select = _select;\n if (this._select) {\n this.id = this._select._registerOption(this);\n }\n }\n /**\n * @description\n * Tracks the value bound to the option element. Unlike the value binding,\n * ngValue supports binding to objects.\n */\n set ngValue(value) {\n if (this._select == null) return;\n this._value = value;\n this._setElementValue(_buildValueString(this.id, value));\n this._select.writeValue(this._select.value);\n }\n /**\n * @description\n * Tracks simple string values bound to the option element.\n * For objects, use the `ngValue` input binding.\n */\n set value(value) {\n if (this._select) {\n this._value = value;\n this._setElementValue(_buildValueString(this.id, value));\n this._select.writeValue(this._select.value);\n } else {\n this._setElementValue(value);\n }\n }\n /** @internal */\n _setElementValue(value) {\n this._renderer.setProperty(this._element.nativeElement, 'value', value);\n }\n /** @internal */\n _setSelected(selected) {\n this._renderer.setProperty(this._element.nativeElement, 'selected', selected);\n }\n /** @nodoc */\n ngOnDestroy() {\n if (this._select) {\n this._select._optionMap.delete(this.id);\n this._select.writeValue(this._select.value);\n }\n }\n static ɵfac = function ɵNgSelectMultipleOption_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ɵNgSelectMultipleOption)(i0.ɵɵdirectiveInject(i0.ElementRef), i0.ɵɵdirectiveInject(i0.Renderer2), i0.ɵɵdirectiveInject(SelectMultipleControlValueAccessor, 9));\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: ɵNgSelectMultipleOption,\n selectors: [[\"option\"]],\n inputs: {\n ngValue: \"ngValue\",\n value: \"value\"\n },\n standalone: false\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(ɵNgSelectMultipleOption, [{\n type: Directive,\n args: [{\n selector: 'option',\n standalone: false\n }]\n }], () => [{\n type: i0.ElementRef\n }, {\n type: i0.Renderer2\n }, {\n type: SelectMultipleControlValueAccessor,\n decorators: [{\n type: Optional\n }, {\n type: Host\n }]\n }], {\n ngValue: [{\n type: Input,\n args: ['ngValue']\n }],\n value: [{\n type: Input,\n args: ['value']\n }]\n });\n})();\n\n/**\n * Method that updates string to integer if not already a number\n *\n * @param value The value to convert to integer.\n * @returns value of parameter converted to number or integer.\n */\nfunction toInteger(value) {\n return typeof value === 'number' ? value : parseInt(value, 10);\n}\n/**\n * Method that ensures that provided value is a float (and converts it to float if needed).\n *\n * @param value The value to convert to float.\n * @returns value of parameter converted to number or float.\n */\nfunction toFloat(value) {\n return typeof value === 'number' ? value : parseFloat(value);\n}\n/**\n * A base class for Validator-based Directives. The class contains common logic shared across such\n * Directives.\n *\n * For internal use only, this class is not intended for use outside of the Forms package.\n */\nclass AbstractValidatorDirective {\n _validator = nullValidator;\n _onChange;\n /**\n * A flag that tracks whether this validator is enabled.\n *\n * Marking it `internal` (vs `protected`), so that this flag can be used in host bindings of\n * directive classes that extend this base class.\n * @internal\n */\n _enabled;\n /** @nodoc */\n ngOnChanges(changes) {\n if (this.inputName in changes) {\n const input = this.normalizeInput(changes[this.inputName].currentValue);\n this._enabled = this.enabled(input);\n this._validator = this._enabled ? this.createValidator(input) : nullValidator;\n if (this._onChange) {\n this._onChange();\n }\n }\n }\n /** @nodoc */\n validate(control) {\n return this._validator(control);\n }\n /** @nodoc */\n registerOnValidatorChange(fn) {\n this._onChange = fn;\n }\n /**\n * @description\n * Determines whether this validator should be active or not based on an input.\n * Base class implementation checks whether an input is defined (if the value is different from\n * `null` and `undefined`). Validator classes that extend this base class can override this\n * function with the logic specific to a particular validator directive.\n */\n enabled(input) {\n return input != null /* both `null` and `undefined` */;\n }\n static ɵfac = function AbstractValidatorDirective_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || AbstractValidatorDirective)();\n };\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: AbstractValidatorDirective,\n features: [i0.ɵɵNgOnChangesFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(AbstractValidatorDirective, [{\n type: Directive\n }], null, null);\n})();\n/**\n * @description\n * Provider which adds `MaxValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst MAX_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => MaxValidator),\n multi: true\n};\n/**\n * A directive which installs the {@link MaxValidator} for any `formControlName`,\n * `formControl`, or control with `ngModel` that also has a `max` attribute.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding a max validator\n *\n * The following example shows how to add a max validator to an input attached to an\n * ngModel binding.\n *\n * ```html\n * <input type=\"number\" ngModel max=\"4\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass MaxValidator extends AbstractValidatorDirective {\n /**\n * @description\n * Tracks changes to the max bound to this directive.\n */\n max;\n /** @internal */\n inputName = 'max';\n /** @internal */\n normalizeInput = input => toFloat(input);\n /** @internal */\n createValidator = max => maxValidator(max);\n static ɵfac = /* @__PURE__ */(() => {\n let ɵMaxValidator_BaseFactory;\n return function MaxValidator_Factory(__ngFactoryType__) {\n return (ɵMaxValidator_BaseFactory || (ɵMaxValidator_BaseFactory = i0.ɵɵgetInheritedFactory(MaxValidator)))(__ngFactoryType__ || MaxValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: MaxValidator,\n selectors: [[\"input\", \"type\", \"number\", \"max\", \"\", \"formControlName\", \"\"], [\"input\", \"type\", \"number\", \"max\", \"\", \"formControl\", \"\"], [\"input\", \"type\", \"number\", \"max\", \"\", \"ngModel\", \"\"]],\n hostVars: 1,\n hostBindings: function MaxValidator_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵattribute(\"max\", ctx._enabled ? ctx.max : null);\n }\n },\n inputs: {\n max: \"max\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([MAX_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(MaxValidator, [{\n type: Directive,\n args: [{\n selector: 'input[type=number][max][formControlName],input[type=number][max][formControl],input[type=number][max][ngModel]',\n providers: [MAX_VALIDATOR],\n host: {\n '[attr.max]': '_enabled ? max : null'\n },\n standalone: false\n }]\n }], null, {\n max: [{\n type: Input\n }]\n });\n})();\n/**\n * @description\n * Provider which adds `MinValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst MIN_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => MinValidator),\n multi: true\n};\n/**\n * A directive which installs the {@link MinValidator} for any `formControlName`,\n * `formControl`, or control with `ngModel` that also has a `min` attribute.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding a min validator\n *\n * The following example shows how to add a min validator to an input attached to an\n * ngModel binding.\n *\n * ```html\n * <input type=\"number\" ngModel min=\"4\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass MinValidator extends AbstractValidatorDirective {\n /**\n * @description\n * Tracks changes to the min bound to this directive.\n */\n min;\n /** @internal */\n inputName = 'min';\n /** @internal */\n normalizeInput = input => toFloat(input);\n /** @internal */\n createValidator = min => minValidator(min);\n static ɵfac = /* @__PURE__ */(() => {\n let ɵMinValidator_BaseFactory;\n return function MinValidator_Factory(__ngFactoryType__) {\n return (ɵMinValidator_BaseFactory || (ɵMinValidator_BaseFactory = i0.ɵɵgetInheritedFactory(MinValidator)))(__ngFactoryType__ || MinValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: MinValidator,\n selectors: [[\"input\", \"type\", \"number\", \"min\", \"\", \"formControlName\", \"\"], [\"input\", \"type\", \"number\", \"min\", \"\", \"formControl\", \"\"], [\"input\", \"type\", \"number\", \"min\", \"\", \"ngModel\", \"\"]],\n hostVars: 1,\n hostBindings: function MinValidator_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵattribute(\"min\", ctx._enabled ? ctx.min : null);\n }\n },\n inputs: {\n min: \"min\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([MIN_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(MinValidator, [{\n type: Directive,\n args: [{\n selector: 'input[type=number][min][formControlName],input[type=number][min][formControl],input[type=number][min][ngModel]',\n providers: [MIN_VALIDATOR],\n host: {\n '[attr.min]': '_enabled ? min : null'\n },\n standalone: false\n }]\n }], null, {\n min: [{\n type: Input\n }]\n });\n})();\n/**\n * @description\n * Provider which adds `RequiredValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst REQUIRED_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => RequiredValidator),\n multi: true\n};\n/**\n * @description\n * Provider which adds `CheckboxRequiredValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst CHECKBOX_REQUIRED_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => CheckboxRequiredValidator),\n multi: true\n};\n/**\n * @description\n * A directive that adds the `required` validator to any controls marked with the\n * `required` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding a required validator using template-driven forms\n *\n * ```html\n * <input name=\"fullName\" ngModel required>\n * ```\n *\n * @ngModule FormsModule\n * @ngModule ReactiveFormsModule\n * @publicApi\n */\nclass RequiredValidator extends AbstractValidatorDirective {\n /**\n * @description\n * Tracks changes to the required attribute bound to this directive.\n */\n required;\n /** @internal */\n inputName = 'required';\n /** @internal */\n normalizeInput = booleanAttribute;\n /** @internal */\n createValidator = input => requiredValidator;\n /** @nodoc */\n enabled(input) {\n return input;\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵRequiredValidator_BaseFactory;\n return function RequiredValidator_Factory(__ngFactoryType__) {\n return (ɵRequiredValidator_BaseFactory || (ɵRequiredValidator_BaseFactory = i0.ɵɵgetInheritedFactory(RequiredValidator)))(__ngFactoryType__ || RequiredValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: RequiredValidator,\n selectors: [[\"\", \"required\", \"\", \"formControlName\", \"\", 3, \"type\", \"checkbox\"], [\"\", \"required\", \"\", \"formControl\", \"\", 3, \"type\", \"checkbox\"], [\"\", \"required\", \"\", \"ngModel\", \"\", 3, \"type\", \"checkbox\"]],\n hostVars: 1,\n hostBindings: function RequiredValidator_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵattribute(\"required\", ctx._enabled ? \"\" : null);\n }\n },\n inputs: {\n required: \"required\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([REQUIRED_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(RequiredValidator, [{\n type: Directive,\n args: [{\n selector: ':not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]',\n providers: [REQUIRED_VALIDATOR],\n host: {\n '[attr.required]': '_enabled ? \"\" : null'\n },\n standalone: false\n }]\n }], null, {\n required: [{\n type: Input\n }]\n });\n})();\n/**\n * A Directive that adds the `required` validator to checkbox controls marked with the\n * `required` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding a required checkbox validator using template-driven forms\n *\n * The following example shows how to add a checkbox required validator to an input attached to an\n * ngModel binding.\n *\n * ```html\n * <input type=\"checkbox\" name=\"active\" ngModel required>\n * ```\n *\n * @publicApi\n * @ngModule FormsModule\n * @ngModule ReactiveFormsModule\n */\nclass CheckboxRequiredValidator extends RequiredValidator {\n /** @internal */\n createValidator = input => requiredTrueValidator;\n static ɵfac = /* @__PURE__ */(() => {\n let ɵCheckboxRequiredValidator_BaseFactory;\n return function CheckboxRequiredValidator_Factory(__ngFactoryType__) {\n return (ɵCheckboxRequiredValidator_BaseFactory || (ɵCheckboxRequiredValidator_BaseFactory = i0.ɵɵgetInheritedFactory(CheckboxRequiredValidator)))(__ngFactoryType__ || CheckboxRequiredValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: CheckboxRequiredValidator,\n selectors: [[\"input\", \"type\", \"checkbox\", \"required\", \"\", \"formControlName\", \"\"], [\"input\", \"type\", \"checkbox\", \"required\", \"\", \"formControl\", \"\"], [\"input\", \"type\", \"checkbox\", \"required\", \"\", \"ngModel\", \"\"]],\n hostVars: 1,\n hostBindings: function CheckboxRequiredValidator_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵattribute(\"required\", ctx._enabled ? \"\" : null);\n }\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([CHECKBOX_REQUIRED_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(CheckboxRequiredValidator, [{\n type: Directive,\n args: [{\n selector: 'input[type=checkbox][required][formControlName],input[type=checkbox][required][formControl],input[type=checkbox][required][ngModel]',\n providers: [CHECKBOX_REQUIRED_VALIDATOR],\n host: {\n '[attr.required]': '_enabled ? \"\" : null'\n },\n standalone: false\n }]\n }], null, null);\n})();\n/**\n * @description\n * Provider which adds `EmailValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst EMAIL_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => EmailValidator),\n multi: true\n};\n/**\n * A directive that adds the `email` validator to controls marked with the\n * `email` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.\n *\n * The email validation is based on the WHATWG HTML specification with some enhancements to\n * incorporate more RFC rules. More information can be found on the [Validators.email\n * page](api/forms/Validators#email).\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding an email validator\n *\n * The following example shows how to add an email validator to an input attached to an ngModel\n * binding.\n *\n * ```html\n * <input type=\"email\" name=\"email\" ngModel email>\n * <input type=\"email\" name=\"email\" ngModel email=\"true\">\n * <input type=\"email\" name=\"email\" ngModel [email]=\"true\">\n * ```\n *\n * @publicApi\n * @ngModule FormsModule\n * @ngModule ReactiveFormsModule\n */\nclass EmailValidator extends AbstractValidatorDirective {\n /**\n * @description\n * Tracks changes to the email attribute bound to this directive.\n */\n email;\n /** @internal */\n inputName = 'email';\n /** @internal */\n normalizeInput = booleanAttribute;\n /** @internal */\n createValidator = input => emailValidator;\n /** @nodoc */\n enabled(input) {\n return input;\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵEmailValidator_BaseFactory;\n return function EmailValidator_Factory(__ngFactoryType__) {\n return (ɵEmailValidator_BaseFactory || (ɵEmailValidator_BaseFactory = i0.ɵɵgetInheritedFactory(EmailValidator)))(__ngFactoryType__ || EmailValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: EmailValidator,\n selectors: [[\"\", \"email\", \"\", \"formControlName\", \"\"], [\"\", \"email\", \"\", \"formControl\", \"\"], [\"\", \"email\", \"\", \"ngModel\", \"\"]],\n inputs: {\n email: \"email\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([EMAIL_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(EmailValidator, [{\n type: Directive,\n args: [{\n selector: '[email][formControlName],[email][formControl],[email][ngModel]',\n providers: [EMAIL_VALIDATOR],\n standalone: false\n }]\n }], null, {\n email: [{\n type: Input\n }]\n });\n})();\n/**\n * @description\n * Provider which adds `MinLengthValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst MIN_LENGTH_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => MinLengthValidator),\n multi: true\n};\n/**\n * A directive that adds minimum length validation to controls marked with the\n * `minlength` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding a minimum length validator\n *\n * The following example shows how to add a minimum length validator to an input attached to an\n * ngModel binding.\n *\n * ```html\n * <input name=\"firstName\" ngModel minlength=\"4\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass MinLengthValidator extends AbstractValidatorDirective {\n /**\n * @description\n * Tracks changes to the minimum length bound to this directive.\n */\n minlength;\n /** @internal */\n inputName = 'minlength';\n /** @internal */\n normalizeInput = input => toInteger(input);\n /** @internal */\n createValidator = minlength => minLengthValidator(minlength);\n static ɵfac = /* @__PURE__ */(() => {\n let ɵMinLengthValidator_BaseFactory;\n return function MinLengthValidator_Factory(__ngFactoryType__) {\n return (ɵMinLengthValidator_BaseFactory || (ɵMinLengthValidator_BaseFactory = i0.ɵɵgetInheritedFactory(MinLengthValidator)))(__ngFactoryType__ || MinLengthValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: MinLengthValidator,\n selectors: [[\"\", \"minlength\", \"\", \"formControlName\", \"\"], [\"\", \"minlength\", \"\", \"formControl\", \"\"], [\"\", \"minlength\", \"\", \"ngModel\", \"\"]],\n hostVars: 1,\n hostBindings: function MinLengthValidator_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵattribute(\"minlength\", ctx._enabled ? ctx.minlength : null);\n }\n },\n inputs: {\n minlength: \"minlength\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([MIN_LENGTH_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(MinLengthValidator, [{\n type: Directive,\n args: [{\n selector: '[minlength][formControlName],[minlength][formControl],[minlength][ngModel]',\n providers: [MIN_LENGTH_VALIDATOR],\n host: {\n '[attr.minlength]': '_enabled ? minlength : null'\n },\n standalone: false\n }]\n }], null, {\n minlength: [{\n type: Input\n }]\n });\n})();\n/**\n * @description\n * Provider which adds `MaxLengthValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst MAX_LENGTH_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => MaxLengthValidator),\n multi: true\n};\n/**\n * A directive that adds maximum length validation to controls marked with the\n * `maxlength` attribute. The directive is provided with the `NG_VALIDATORS` multi-provider list.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding a maximum length validator\n *\n * The following example shows how to add a maximum length validator to an input attached to an\n * ngModel binding.\n *\n * ```html\n * <input name=\"firstName\" ngModel maxlength=\"25\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass MaxLengthValidator extends AbstractValidatorDirective {\n /**\n * @description\n * Tracks changes to the maximum length bound to this directive.\n */\n maxlength;\n /** @internal */\n inputName = 'maxlength';\n /** @internal */\n normalizeInput = input => toInteger(input);\n /** @internal */\n createValidator = maxlength => maxLengthValidator(maxlength);\n static ɵfac = /* @__PURE__ */(() => {\n let ɵMaxLengthValidator_BaseFactory;\n return function MaxLengthValidator_Factory(__ngFactoryType__) {\n return (ɵMaxLengthValidator_BaseFactory || (ɵMaxLengthValidator_BaseFactory = i0.ɵɵgetInheritedFactory(MaxLengthValidator)))(__ngFactoryType__ || MaxLengthValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: MaxLengthValidator,\n selectors: [[\"\", \"maxlength\", \"\", \"formControlName\", \"\"], [\"\", \"maxlength\", \"\", \"formControl\", \"\"], [\"\", \"maxlength\", \"\", \"ngModel\", \"\"]],\n hostVars: 1,\n hostBindings: function MaxLengthValidator_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵattribute(\"maxlength\", ctx._enabled ? ctx.maxlength : null);\n }\n },\n inputs: {\n maxlength: \"maxlength\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([MAX_LENGTH_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(MaxLengthValidator, [{\n type: Directive,\n args: [{\n selector: '[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]',\n providers: [MAX_LENGTH_VALIDATOR],\n host: {\n '[attr.maxlength]': '_enabled ? maxlength : null'\n },\n standalone: false\n }]\n }], null, {\n maxlength: [{\n type: Input\n }]\n });\n})();\n/**\n * @description\n * Provider which adds `PatternValidator` to the `NG_VALIDATORS` multi-provider list.\n */\nconst PATTERN_VALIDATOR = {\n provide: NG_VALIDATORS,\n useExisting: forwardRef(() => PatternValidator),\n multi: true\n};\n/**\n * @description\n * A directive that adds regex pattern validation to controls marked with the\n * `pattern` attribute. The regex must match the entire control value.\n * The directive is provided with the `NG_VALIDATORS` multi-provider list.\n *\n * @see [Form Validation](guide/forms/form-validation)\n *\n * @usageNotes\n *\n * ### Adding a pattern validator\n *\n * The following example shows how to add a pattern validator to an input attached to an\n * ngModel binding.\n *\n * ```html\n * <input name=\"firstName\" ngModel pattern=\"[a-zA-Z ]*\">\n * ```\n *\n * @ngModule ReactiveFormsModule\n * @ngModule FormsModule\n * @publicApi\n */\nclass PatternValidator extends AbstractValidatorDirective {\n /**\n * @description\n * Tracks changes to the pattern bound to this directive.\n */\n pattern; // This input is always defined, since the name matches selector.\n /** @internal */\n inputName = 'pattern';\n /** @internal */\n normalizeInput = input => input;\n /** @internal */\n createValidator = input => patternValidator(input);\n static ɵfac = /* @__PURE__ */(() => {\n let ɵPatternValidator_BaseFactory;\n return function PatternValidator_Factory(__ngFactoryType__) {\n return (ɵPatternValidator_BaseFactory || (ɵPatternValidator_BaseFactory = i0.ɵɵgetInheritedFactory(PatternValidator)))(__ngFactoryType__ || PatternValidator);\n };\n })();\n static ɵdir = /* @__PURE__ */i0.ɵɵdefineDirective({\n type: PatternValidator,\n selectors: [[\"\", \"pattern\", \"\", \"formControlName\", \"\"], [\"\", \"pattern\", \"\", \"formControl\", \"\"], [\"\", \"pattern\", \"\", \"ngModel\", \"\"]],\n hostVars: 1,\n hostBindings: function PatternValidator_HostBindings(rf, ctx) {\n if (rf & 2) {\n i0.ɵɵattribute(\"pattern\", ctx._enabled ? ctx.pattern : null);\n }\n },\n inputs: {\n pattern: \"pattern\"\n },\n standalone: false,\n features: [i0.ɵɵProvidersFeature([PATTERN_VALIDATOR]), i0.ɵɵInheritDefinitionFeature]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(PatternValidator, [{\n type: Directive,\n args: [{\n selector: '[pattern][formControlName],[pattern][formControl],[pattern][ngModel]',\n providers: [PATTERN_VALIDATOR],\n host: {\n '[attr.pattern]': '_enabled ? pattern : null'\n },\n standalone: false\n }]\n }], null, {\n pattern: [{\n type: Input\n }]\n });\n})();\nconst SHARED_FORM_DIRECTIVES = [ɵNgNoValidate, NgSelectOption, ɵNgSelectMultipleOption, DefaultValueAccessor, NumberValueAccessor, RangeValueAccessor, CheckboxControlValueAccessor, SelectControlValueAccessor, SelectMultipleControlValueAccessor, RadioControlValueAccessor, NgControlStatus, NgControlStatusGroup, RequiredValidator, MinLengthValidator, MaxLengthValidator, PatternValidator, CheckboxRequiredValidator, EmailValidator, MinValidator, MaxValidator];\nconst TEMPLATE_DRIVEN_DIRECTIVES = [NgModel, NgModelGroup, NgForm];\nconst REACTIVE_DRIVEN_DIRECTIVES = [FormControlDirective, FormGroupDirective, FormControlName, FormGroupName, FormArrayName];\n/**\n * Internal module used for sharing directives between FormsModule and ReactiveFormsModule\n */\nclass ɵInternalFormsSharedModule {\n static ɵfac = function ɵInternalFormsSharedModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ɵInternalFormsSharedModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: ɵInternalFormsSharedModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({});\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(ɵInternalFormsSharedModule, [{\n type: NgModule,\n args: [{\n declarations: SHARED_FORM_DIRECTIVES,\n exports: SHARED_FORM_DIRECTIVES\n }]\n }], null, null);\n})();\n\n/**\n * Tracks the value and validity state of an array of `FormControl`,\n * `FormGroup` or `FormArray` instances.\n *\n * A `FormArray` aggregates the values of each child `FormControl` into an array.\n * It calculates its status by reducing the status values of its children. For example, if one of\n * the controls in a `FormArray` is invalid, the entire array becomes invalid.\n *\n * `FormArray` accepts one generic argument, which is the type of the controls inside.\n * If you need a heterogenous array, use {@link UntypedFormArray}.\n *\n * `FormArray` is one of the four fundamental building blocks used to define forms in Angular,\n * along with `FormControl`, `FormGroup`, and `FormRecord`.\n *\n * @usageNotes\n *\n * ### Create an array of form controls\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl('Nancy', Validators.minLength(2)),\n * new FormControl('Drew'),\n * ]);\n *\n * console.log(arr.value); // ['Nancy', 'Drew']\n * console.log(arr.status); // 'VALID'\n * ```\n *\n * ### Create a form array with array-level validators\n *\n * You include array-level validators and async validators. These come in handy\n * when you want to perform validation that considers the value of more than one child\n * control.\n *\n * The two types of validators are passed in separately as the second and third arg\n * respectively, or together as part of an options object.\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl('Nancy'),\n * new FormControl('Drew')\n * ], {validators: myValidator, asyncValidators: myAsyncValidator});\n * ```\n *\n * ### Set the updateOn property for all controls in a form array\n *\n * The options object is used to set a default value for each child\n * control's `updateOn` property. If you set `updateOn` to `'blur'` at the\n * array level, all child controls default to 'blur', unless the child\n * has explicitly specified a different `updateOn` value.\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl()\n * ], {updateOn: 'blur'});\n * ```\n *\n * ### Adding or removing controls from a form array\n *\n * To change the controls in the array, use the `push`, `insert`, `removeAt` or `clear` methods\n * in `FormArray` itself. These methods ensure the controls are properly tracked in the\n * form's hierarchy. Do not modify the array of `AbstractControl`s used to instantiate\n * the `FormArray` directly, as that result in strange and unexpected behavior such\n * as broken change detection.\n *\n * @publicApi\n */\nclass FormArray extends AbstractControl {\n /**\n * Creates a new `FormArray` instance.\n *\n * @param controls An array of child controls. Each child control is given an index\n * where it is registered.\n *\n * @param validatorOrOpts A synchronous validator function, or an array of\n * such functions, or an `AbstractControlOptions` object that contains validation functions\n * and a validation trigger.\n *\n * @param asyncValidator A single async validator or array of async validator functions\n *\n */\n constructor(controls, validatorOrOpts, asyncValidator) {\n super(pickValidators(validatorOrOpts), pickAsyncValidators(asyncValidator, validatorOrOpts));\n this.controls = controls;\n this._initObservables();\n this._setUpdateStrategy(validatorOrOpts);\n this._setUpControls();\n this.updateValueAndValidity({\n onlySelf: true,\n // If `asyncValidator` is present, it will trigger control status change from `PENDING` to\n // `VALID` or `INVALID`.\n // The status should be broadcasted via the `statusChanges` observable, so we set `emitEvent`\n // to `true` to allow that during the control creation process.\n emitEvent: !!this.asyncValidator\n });\n }\n controls;\n /**\n * Get the `AbstractControl` at the given `index` in the array.\n *\n * @param index Index in the array to retrieve the control. If `index` is negative, it will wrap\n * around from the back, and if index is greatly negative (less than `-length`), the result is\n * undefined. This behavior is the same as `Array.at(index)`.\n */\n at(index) {\n return this.controls[this._adjustIndex(index)];\n }\n /**\n * Insert a new `AbstractControl` at the end of the array.\n *\n * @param control Form control to be inserted\n * @param options Specifies whether this FormArray instance should emit events after a new\n * control is added.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when the control is\n * inserted. When false, no events are emitted.\n */\n push(control, options = {}) {\n this.controls.push(control);\n this._registerControl(control);\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n this._onCollectionChange();\n }\n /**\n * Insert a new `AbstractControl` at the given `index` in the array.\n *\n * @param index Index in the array to insert the control. If `index` is negative, wraps around\n * from the back. If `index` is greatly negative (less than `-length`), prepends to the array.\n * This behavior is the same as `Array.splice(index, 0, control)`.\n * @param control Form control to be inserted\n * @param options Specifies whether this FormArray instance should emit events after a new\n * control is inserted.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when the control is\n * inserted. When false, no events are emitted.\n */\n insert(index, control, options = {}) {\n this.controls.splice(index, 0, control);\n this._registerControl(control);\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n }\n /**\n * Remove the control at the given `index` in the array.\n *\n * @param index Index in the array to remove the control. If `index` is negative, wraps around\n * from the back. If `index` is greatly negative (less than `-length`), removes the first\n * element. This behavior is the same as `Array.splice(index, 1)`.\n * @param options Specifies whether this FormArray instance should emit events after a\n * control is removed.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when the control is\n * removed. When false, no events are emitted.\n */\n removeAt(index, options = {}) {\n // Adjust the index, then clamp it at no less than 0 to prevent undesired underflows.\n let adjustedIndex = this._adjustIndex(index);\n if (adjustedIndex < 0) adjustedIndex = 0;\n if (this.controls[adjustedIndex]) this.controls[adjustedIndex]._registerOnCollectionChange(() => {});\n this.controls.splice(adjustedIndex, 1);\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n }\n /**\n * Replace an existing control.\n *\n * @param index Index in the array to replace the control. If `index` is negative, wraps around\n * from the back. If `index` is greatly negative (less than `-length`), replaces the first\n * element. This behavior is the same as `Array.splice(index, 1, control)`.\n * @param control The `AbstractControl` control to replace the existing control\n * @param options Specifies whether this FormArray instance should emit events after an\n * existing control is replaced with a new one.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when the control is\n * replaced with a new one. When false, no events are emitted.\n */\n setControl(index, control, options = {}) {\n // Adjust the index, then clamp it at no less than 0 to prevent undesired underflows.\n let adjustedIndex = this._adjustIndex(index);\n if (adjustedIndex < 0) adjustedIndex = 0;\n if (this.controls[adjustedIndex]) this.controls[adjustedIndex]._registerOnCollectionChange(() => {});\n this.controls.splice(adjustedIndex, 1);\n if (control) {\n this.controls.splice(adjustedIndex, 0, control);\n this._registerControl(control);\n }\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n this._onCollectionChange();\n }\n /**\n * Length of the control array.\n */\n get length() {\n return this.controls.length;\n }\n /**\n * Sets the value of the `FormArray`. It accepts an array that matches\n * the structure of the control.\n *\n * This method performs strict checks, and throws an error if you try\n * to set the value of a control that doesn't exist or if you exclude the\n * value of a control.\n *\n * @usageNotes\n * ### Set the values for the controls in the form array\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl(),\n * new FormControl()\n * ]);\n * console.log(arr.value); // [null, null]\n *\n * arr.setValue(['Nancy', 'Drew']);\n * console.log(arr.value); // ['Nancy', 'Drew']\n * ```\n *\n * @param value Array of values for the controls\n * @param options Configure options that determine how the control propagates changes and\n * emits events after the value changes\n *\n * * `onlySelf`: When true, each change only affects this control, and not its parent. Default\n * is false.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges`\n * observables emit events with the latest status and value when the control value is updated.\n * When false, no events are emitted.\n * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity\n * updateValueAndValidity} method.\n */\n setValue(value, options = {}) {\n assertAllValuesPresent(this, false, value);\n value.forEach((newValue, index) => {\n assertControlPresent(this, false, index);\n this.at(index).setValue(newValue, {\n onlySelf: true,\n emitEvent: options.emitEvent\n });\n });\n this.updateValueAndValidity(options);\n }\n /**\n * Patches the value of the `FormArray`. It accepts an array that matches the\n * structure of the control, and does its best to match the values to the correct\n * controls in the group.\n *\n * It accepts both super-sets and sub-sets of the array without throwing an error.\n *\n * @usageNotes\n * ### Patch the values for controls in a form array\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl(),\n * new FormControl()\n * ]);\n * console.log(arr.value); // [null, null]\n *\n * arr.patchValue(['Nancy']);\n * console.log(arr.value); // ['Nancy', null]\n * ```\n *\n * @param value Array of latest values for the controls\n * @param options Configure options that determine how the control propagates changes and\n * emits events after the value changes\n *\n * * `onlySelf`: When true, each change only affects this control, and not its parent. Default\n * is false.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when the control\n * value is updated. When false, no events are emitted. The configuration options are passed to\n * the {@link AbstractControl#updateValueAndValidity updateValueAndValidity} method.\n */\n patchValue(value, options = {}) {\n // Even though the `value` argument type doesn't allow `null` and `undefined` values, the\n // `patchValue` can be called recursively and inner data structures might have these values,\n // so we just ignore such cases when a field containing FormArray instance receives `null` or\n // `undefined` as a value.\n if (value == null /* both `null` and `undefined` */) return;\n value.forEach((newValue, index) => {\n if (this.at(index)) {\n this.at(index).patchValue(newValue, {\n onlySelf: true,\n emitEvent: options.emitEvent\n });\n }\n });\n this.updateValueAndValidity(options);\n }\n /**\n * Resets the `FormArray` and all descendants are marked `pristine` and `untouched`, and the\n * value of all descendants to null or null maps.\n *\n * You reset to a specific form state by passing in an array of states\n * that matches the structure of the control. The state is a standalone value\n * or a form state object with both a value and a disabled status.\n *\n * @usageNotes\n * ### Reset the values in a form array\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl(),\n * new FormControl()\n * ]);\n * arr.reset(['name', 'last name']);\n *\n * console.log(arr.value); // ['name', 'last name']\n * ```\n *\n * ### Reset the values in a form array and the disabled status for the first control\n *\n * ```ts\n * arr.reset([\n * {value: 'name', disabled: true},\n * 'last'\n * ]);\n *\n * console.log(arr.value); // ['last']\n * console.log(arr.at(0).status); // 'DISABLED'\n * ```\n *\n * @param value Array of values for the controls\n * @param options Configure options that determine how the control propagates changes and\n * emits events after the value changes\n *\n * * `onlySelf`: When true, each change only affects this control, and not its parent. Default\n * is false.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges`\n * observables emit events with the latest status and value when the control is reset.\n * When false, no events are emitted.\n * The configuration options are passed to the {@link AbstractControl#updateValueAndValidity\n * updateValueAndValidity} method.\n */\n reset(value = [], options = {}) {\n this._forEachChild((control, index) => {\n control.reset(value[index], {\n onlySelf: true,\n emitEvent: options.emitEvent\n });\n });\n this._updatePristine(options, this);\n this._updateTouched(options, this);\n this.updateValueAndValidity(options);\n }\n /**\n * The aggregate value of the array, including any disabled controls.\n *\n * Reports all values regardless of disabled status.\n */\n getRawValue() {\n return this.controls.map(control => control.getRawValue());\n }\n /**\n * Remove all controls in the `FormArray`.\n *\n * @param options Specifies whether this FormArray instance should emit events after all\n * controls are removed.\n * * `emitEvent`: When true or not supplied (the default), both the `statusChanges` and\n * `valueChanges` observables emit events with the latest status and value when all controls\n * in this FormArray instance are removed. When false, no events are emitted.\n *\n * @usageNotes\n * ### Remove all elements from a FormArray\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl(),\n * new FormControl()\n * ]);\n * console.log(arr.length); // 2\n *\n * arr.clear();\n * console.log(arr.length); // 0\n * ```\n *\n * It's a simpler and more efficient alternative to removing all elements one by one:\n *\n * ```ts\n * const arr = new FormArray([\n * new FormControl(),\n * new FormControl()\n * ]);\n *\n * while (arr.length) {\n * arr.removeAt(0);\n * }\n * ```\n */\n clear(options = {}) {\n if (this.controls.length < 1) return;\n this._forEachChild(control => control._registerOnCollectionChange(() => {}));\n this.controls.splice(0);\n this.updateValueAndValidity({\n emitEvent: options.emitEvent\n });\n }\n /**\n * Adjusts a negative index by summing it with the length of the array. For very negative\n * indices, the result may remain negative.\n * @internal\n */\n _adjustIndex(index) {\n return index < 0 ? index + this.length : index;\n }\n /** @internal */\n _syncPendingControls() {\n let subtreeUpdated = this.controls.reduce((updated, child) => {\n return child._syncPendingControls() ? true : updated;\n }, false);\n if (subtreeUpdated) this.updateValueAndValidity({\n onlySelf: true\n });\n return subtreeUpdated;\n }\n /** @internal */\n _forEachChild(cb) {\n this.controls.forEach((control, index) => {\n cb(control, index);\n });\n }\n /** @internal */\n _updateValue() {\n this.value = this.controls.filter(control => control.enabled || this.disabled).map(control => control.value);\n }\n /** @internal */\n _anyControls(condition) {\n return this.controls.some(control => control.enabled && condition(control));\n }\n /** @internal */\n _setUpControls() {\n this._forEachChild(control => this._registerControl(control));\n }\n /** @internal */\n _allControlsDisabled() {\n for (const control of this.controls) {\n if (control.enabled) return false;\n }\n return this.controls.length > 0 || this.disabled;\n }\n _registerControl(control) {\n control.setParent(this);\n control._registerOnCollectionChange(this._onCollectionChange);\n }\n /** @internal */\n _find(name) {\n return this.at(name) ?? null;\n }\n}\nconst UntypedFormArray = FormArray;\n/**\n * @description\n * Asserts that the given control is an instance of `FormArray`\n *\n * @publicApi\n */\nconst isFormArray = control => control instanceof FormArray;\nfunction isAbstractControlOptions(options) {\n return !!options && (options.asyncValidators !== undefined || options.validators !== undefined || options.updateOn !== undefined);\n}\n/**\n * @description\n * Creates an `AbstractControl` from a user-specified configuration.\n *\n * The `FormBuilder` provides syntactic sugar that shortens creating instances of a\n * `FormControl`, `FormGroup`, or `FormArray`. It reduces the amount of boilerplate needed to\n * build complex forms.\n *\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n *\n * @publicApi\n */\nclass FormBuilder {\n useNonNullable = false;\n /**\n * @description\n * Returns a FormBuilder in which automatically constructed `FormControl` elements\n * have `{nonNullable: true}` and are non-nullable.\n *\n * **Constructing non-nullable controls**\n *\n * When constructing a control, it will be non-nullable, and will reset to its initial value.\n *\n * ```ts\n * let nnfb = new FormBuilder().nonNullable;\n * let name = nnfb.control('Alex'); // FormControl<string>\n * name.reset();\n * console.log(name); // 'Alex'\n * ```\n *\n * **Constructing non-nullable groups or arrays**\n *\n * When constructing a group or array, all automatically created inner controls will be\n * non-nullable, and will reset to their initial values.\n *\n * ```ts\n * let nnfb = new FormBuilder().nonNullable;\n * let name = nnfb.group({who: 'Alex'}); // FormGroup<{who: FormControl<string>}>\n * name.reset();\n * console.log(name); // {who: 'Alex'}\n * ```\n * **Constructing *nullable* fields on groups or arrays**\n *\n * It is still possible to have a nullable field. In particular, any `FormControl` which is\n * *already* constructed will not be altered. For example:\n *\n * ```ts\n * let nnfb = new FormBuilder().nonNullable;\n * // FormGroup<{who: FormControl<string|null>}>\n * let name = nnfb.group({who: new FormControl('Alex')});\n * name.reset(); console.log(name); // {who: null}\n * ```\n *\n * Because the inner control is constructed explicitly by the caller, the builder has\n * no control over how it is created, and cannot exclude the `null`.\n */\n get nonNullable() {\n const nnfb = new FormBuilder();\n nnfb.useNonNullable = true;\n return nnfb;\n }\n group(controls, options = null) {\n const reducedControls = this._reduceControls(controls);\n let newOptions = {};\n if (isAbstractControlOptions(options)) {\n // `options` are `AbstractControlOptions`\n newOptions = options;\n } else if (options !== null) {\n // `options` are legacy form group options\n newOptions.validators = options.validator;\n newOptions.asyncValidators = options.asyncValidator;\n }\n return new FormGroup(reducedControls, newOptions);\n }\n /**\n * @description\n * Constructs a new `FormRecord` instance. Accepts a single generic argument, which is an object\n * containing all the keys and corresponding inner control types.\n *\n * @param controls A collection of child controls. The key for each child is the name\n * under which it is registered.\n *\n * @param options Configuration options object for the `FormRecord`. The object should have the\n * `AbstractControlOptions` type and might contain the following fields:\n * * `validators`: A synchronous validator function, or an array of validator functions.\n * * `asyncValidators`: A single async validator or array of async validator functions.\n * * `updateOn`: The event upon which the control should be updated (options: 'change' | 'blur'\n * | submit').\n */\n record(controls, options = null) {\n const reducedControls = this._reduceControls(controls);\n // Cast to `any` because the inferred types are not as specific as Element.\n return new FormRecord(reducedControls, options);\n }\n /**\n * @description\n * Constructs a new `FormControl` with the given state, validators and options. Sets\n * `{nonNullable: true}` in the options to get a non-nullable control. Otherwise, the\n * control will be nullable. Accepts a single generic argument, which is the type of the\n * control's value.\n *\n * @param formState Initializes the control with an initial state value, or\n * with an object that contains both a value and a disabled status.\n *\n * @param validatorOrOpts A synchronous validator function, or an array of\n * such functions, or a `FormControlOptions` object that contains\n * validation functions and a validation trigger.\n *\n * @param asyncValidator A single async validator or array of async validator\n * functions.\n *\n * @usageNotes\n *\n * ### Initialize a control as disabled\n *\n * The following example returns a control with an initial value in a disabled state.\n *\n * {@example forms/ts/formBuilder/form_builder_example.ts region='disabled-control'}\n */\n control(formState, validatorOrOpts, asyncValidator) {\n let newOptions = {};\n if (!this.useNonNullable) {\n return new FormControl(formState, validatorOrOpts, asyncValidator);\n }\n if (isAbstractControlOptions(validatorOrOpts)) {\n // If the second argument is options, then they are copied.\n newOptions = validatorOrOpts;\n } else {\n // If the other arguments are validators, they are copied into an options object.\n newOptions.validators = validatorOrOpts;\n newOptions.asyncValidators = asyncValidator;\n }\n return new FormControl(formState, {\n ...newOptions,\n nonNullable: true\n });\n }\n /**\n * Constructs a new `FormArray` from the given array of configurations,\n * validators and options. Accepts a single generic argument, which is the type of each control\n * inside the array.\n *\n * @param controls An array of child controls or control configs. Each child control is given an\n * index when it is registered.\n *\n * @param validatorOrOpts A synchronous validator function, or an array of such functions, or an\n * `AbstractControlOptions` object that contains\n * validation functions and a validation trigger.\n *\n * @param asyncValidator A single async validator or array of async validator functions.\n */\n array(controls, validatorOrOpts, asyncValidator) {\n const createdControls = controls.map(c => this._createControl(c));\n // Cast to `any` because the inferred types are not as specific as Element.\n return new FormArray(createdControls, validatorOrOpts, asyncValidator);\n }\n /** @internal */\n _reduceControls(controls) {\n const createdControls = {};\n Object.keys(controls).forEach(controlName => {\n createdControls[controlName] = this._createControl(controls[controlName]);\n });\n return createdControls;\n }\n /** @internal */\n _createControl(controls) {\n if (controls instanceof FormControl) {\n return controls;\n } else if (controls instanceof AbstractControl) {\n // A control; just return it\n return controls;\n } else if (Array.isArray(controls)) {\n // ControlConfig Tuple\n const value = controls[0];\n const validator = controls.length > 1 ? controls[1] : null;\n const asyncValidator = controls.length > 2 ? controls[2] : null;\n return this.control(value, validator, asyncValidator);\n } else {\n // T or FormControlState<T>\n return this.control(controls);\n }\n }\n static ɵfac = function FormBuilder_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FormBuilder)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: FormBuilder,\n factory: FormBuilder.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FormBuilder, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n/**\n * @description\n * `NonNullableFormBuilder` is similar to {@link FormBuilder}, but automatically constructed\n * {@link FormControl} elements have `{nonNullable: true}` and are non-nullable.\n *\n * @publicApi\n */\nclass NonNullableFormBuilder {\n static ɵfac = function NonNullableFormBuilder_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || NonNullableFormBuilder)();\n };\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: NonNullableFormBuilder,\n factory: () => (() => inject(FormBuilder).nonNullable)(),\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(NonNullableFormBuilder, [{\n type: Injectable,\n args: [{\n providedIn: 'root',\n useFactory: () => inject(FormBuilder).nonNullable\n }]\n }], null, null);\n})();\n/**\n * UntypedFormBuilder is the same as `FormBuilder`, but it provides untyped controls.\n */\nclass UntypedFormBuilder extends FormBuilder {\n group(controlsConfig, options = null) {\n return super.group(controlsConfig, options);\n }\n /**\n * Like `FormBuilder#control`, except the resulting control is untyped.\n */\n control(formState, validatorOrOpts, asyncValidator) {\n return super.control(formState, validatorOrOpts, asyncValidator);\n }\n /**\n * Like `FormBuilder#array`, except the resulting array is untyped.\n */\n array(controlsConfig, validatorOrOpts, asyncValidator) {\n return super.array(controlsConfig, validatorOrOpts, asyncValidator);\n }\n static ɵfac = /* @__PURE__ */(() => {\n let ɵUntypedFormBuilder_BaseFactory;\n return function UntypedFormBuilder_Factory(__ngFactoryType__) {\n return (ɵUntypedFormBuilder_BaseFactory || (ɵUntypedFormBuilder_BaseFactory = i0.ɵɵgetInheritedFactory(UntypedFormBuilder)))(__ngFactoryType__ || UntypedFormBuilder);\n };\n })();\n static ɵprov = /* @__PURE__ */i0.ɵɵdefineInjectable({\n token: UntypedFormBuilder,\n factory: UntypedFormBuilder.ɵfac,\n providedIn: 'root'\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(UntypedFormBuilder, [{\n type: Injectable,\n args: [{\n providedIn: 'root'\n }]\n }], null, null);\n})();\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the forms package.\n */\n/**\n * @publicApi\n */\nconst VERSION = new Version('19.2.1');\n\n/**\n * Exports the required providers and directives for template-driven forms,\n * making them available for import by NgModules that import this module.\n *\n * @see [Forms Overview](guide/forms)\n * @see [Template-driven Forms Guide](guide/forms)\n *\n * @publicApi\n */\nclass FormsModule {\n /**\n * @description\n * Provides options for configuring the forms module.\n *\n * @param opts An object of configuration options\n * * `callSetDisabledState` Configures whether to `always` call `setDisabledState`, which is more\n * correct, or to only call it `whenDisabled`, which is the legacy behavior.\n */\n static withConfig(opts) {\n return {\n ngModule: FormsModule,\n providers: [{\n provide: CALL_SET_DISABLED_STATE,\n useValue: opts.callSetDisabledState ?? setDisabledStateDefault\n }]\n };\n }\n static ɵfac = function FormsModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || FormsModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: FormsModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n imports: [ɵInternalFormsSharedModule]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(FormsModule, [{\n type: NgModule,\n args: [{\n declarations: TEMPLATE_DRIVEN_DIRECTIVES,\n exports: [ɵInternalFormsSharedModule, TEMPLATE_DRIVEN_DIRECTIVES]\n }]\n }], null, null);\n})();\n/**\n * Exports the required infrastructure and directives for reactive forms,\n * making them available for import by NgModules that import this module.\n *\n * @see [Forms Overview](guide/forms)\n * @see [Reactive Forms Guide](guide/forms/reactive-forms)\n *\n * @publicApi\n */\nclass ReactiveFormsModule {\n /**\n * @description\n * Provides options for configuring the reactive forms module.\n *\n * @param opts An object of configuration options\n * * `warnOnNgModelWithFormControl` Configures when to emit a warning when an `ngModel`\n * binding is used with reactive form directives.\n * * `callSetDisabledState` Configures whether to `always` call `setDisabledState`, which is more\n * correct, or to only call it `whenDisabled`, which is the legacy behavior.\n */\n static withConfig(opts) {\n return {\n ngModule: ReactiveFormsModule,\n providers: [{\n provide: NG_MODEL_WITH_FORM_CONTROL_WARNING,\n useValue: opts.warnOnNgModelWithFormControl ?? 'always'\n }, {\n provide: CALL_SET_DISABLED_STATE,\n useValue: opts.callSetDisabledState ?? setDisabledStateDefault\n }]\n };\n }\n static ɵfac = function ReactiveFormsModule_Factory(__ngFactoryType__) {\n return new (__ngFactoryType__ || ReactiveFormsModule)();\n };\n static ɵmod = /* @__PURE__ */i0.ɵɵdefineNgModule({\n type: ReactiveFormsModule\n });\n static ɵinj = /* @__PURE__ */i0.ɵɵdefineInjector({\n imports: [ɵInternalFormsSharedModule]\n });\n}\n(() => {\n (typeof ngDevMode === \"undefined\" || ngDevMode) && i0.ɵsetClassMetadata(ReactiveFormsModule, [{\n type: NgModule,\n args: [{\n declarations: [REACTIVE_DRIVEN_DIRECTIVES],\n exports: [ɵInternalFormsSharedModule, REACTIVE_DRIVEN_DIRECTIVES]\n }]\n }], null, null);\n})();\n\n/**\n * @module\n * @description\n * This module is used for handling user input, by defining and building a `FormGroup` that\n * consists of `FormControl` objects, and mapping them onto the DOM. `FormControl`\n * objects can then be used to read information from the form DOM elements.\n *\n * Forms providers are not included in default providers; you must import these providers\n * explicitly.\n */\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of this package.\n */\n// This file only reexports content of the `src` folder. Keep it that way.\n\n// This file is not used to build this module. It is only used during editing\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { AbstractControl, AbstractControlDirective, AbstractFormGroupDirective, COMPOSITION_BUFFER_MODE, CheckboxControlValueAccessor, CheckboxRequiredValidator, ControlContainer, ControlEvent, DefaultValueAccessor, EmailValidator, FormArray, FormArrayName, FormBuilder, FormControl, FormControlDirective, FormControlName, FormGroup, FormGroupDirective, FormGroupName, FormRecord, FormResetEvent, FormSubmittedEvent, FormsModule, MaxLengthValidator, MaxValidator, MinLengthValidator, MinValidator, NG_ASYNC_VALIDATORS, NG_VALIDATORS, NG_VALUE_ACCESSOR, NgControl, NgControlStatus, NgControlStatusGroup, NgForm, NgModel, NgModelGroup, NgSelectOption, NonNullableFormBuilder, NumberValueAccessor, PatternValidator, PristineChangeEvent, RadioControlValueAccessor, RangeValueAccessor, ReactiveFormsModule, RequiredValidator, SelectControlValueAccessor, SelectMultipleControlValueAccessor, StatusChangeEvent, TouchedChangeEvent, UntypedFormArray, UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, VERSION, Validators, ValueChangeEvent, isFormArray, isFormControl, isFormGroup, isFormRecord, ɵInternalFormsSharedModule, ɵNgNoValidate, ɵNgSelectMultipleOption };\n","import { Component, OnInit, TemplateRef, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-tab-body',\r\n templateUrl: './tab-body.component.html',\r\n styleUrls: ['./tab-body.component.scss'],\r\n standalone: false\r\n})\r\nexport class TabBodyComponent implements OnInit {\r\n @ViewChild(TemplateRef)\r\n bodyContent: TemplateRef<any>;\r\n\r\n constructor() { }\r\n\r\n ngOnInit(): void {\r\n }\r\n\r\n}\r\n","<ng-template><ng-content></ng-content></ng-template>","import { Component, ContentChild, Input, OnInit } from '@angular/core';\r\nimport { TabBodyComponent } from '../tab-body/tab-body.component';\r\n\r\n@Component({\r\n selector: 'app-tab-item',\r\n templateUrl: './tab-item.component.html',\r\n styleUrls: ['./tab-item.component.scss'],\r\n standalone: false\r\n})\r\nexport class TabItemComponent implements OnInit {\r\n\r\n @Input()\r\n label: string;\r\n\r\n @Input()\r\n isActive: boolean;\r\n\r\n @ContentChild(TabBodyComponent)\r\n bodyComponent: TabBodyComponent;\r\n\r\n constructor() { }\r\n\r\n ngOnInit(): void { }\r\n\r\n}\r\n","<ng-content></ng-content>","import {\r\n AfterContentChecked,\r\n AfterContentInit,\r\n Component,\r\n ContentChildren,\r\n OnDestroy,\r\n QueryList,\r\n} from '@angular/core';\r\nimport { Observable, Subscription } from 'rxjs';\r\nimport { delay, map, startWith } from 'rxjs/operators';\r\nimport { DefaultTabService } from './default-tab.service';\r\nimport { TabItemComponent } from './tab-item/tab-item.component';\r\n\r\n@Component({\r\n selector: 'app-tabs',\r\n templateUrl: './tabs.component.html',\r\n styleUrls: ['./tabs.component.scss'],\r\n standalone: false\r\n})\r\nexport class TabsComponent implements AfterContentInit, AfterContentChecked, OnDestroy {\r\n @ContentChildren(TabItemComponent)\r\n tabs: QueryList<TabItemComponent>;\r\n\r\n tabItems$: Observable<TabItemComponent[]>;\r\n\r\n activeTab: TabItemComponent;\r\n activeItem: string;\r\n\r\n itemSub: Subscription;\r\n\r\n constructor(private tabService: DefaultTabService) {}\r\n\r\n ngAfterContentInit(): void {\r\n this.tabItems$ = this.tabs.changes\r\n .pipe(startWith(''))\r\n .pipe(delay(0))\r\n .pipe(map(() => this.tabs.toArray()));\r\n }\r\n\r\n ngAfterContentChecked() {\r\n // choose the default tab\r\n // we need to wait for a next VM turn,\r\n // because Tab item content, will not be initialized yet\r\n if (!this.activeTab) {\r\n Promise.resolve().then(() => {\r\n this.activeTab = this.tabs.first;\r\n this.tabService.addItems(this.tabs.map((t) => t.label));\r\n this.itemSub = this.tabService.item$.subscribe((i) => {\r\n if (this.activeItem === i) return;\r\n this.activeItem = i;\r\n this.activeTab.isActive = false;\r\n this.activeTab = this.tabs.filter((t) => t.label === i)[0];\r\n });\r\n });\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.itemSub.unsubscribe();\r\n }\r\n}\r\n","\r\n<div class=\"tabs-body\">\r\n <ng-container *ngIf=\"activeTab && activeTab.bodyComponent\">\r\n <ng-container *ngTemplateOutlet=\"activeTab.bodyComponent.bodyContent\">\r\n </ng-container>\r\n </ng-container>\r\n</div>","import { HostListener, Directive, OnDestroy, Input, ElementRef } from '@angular/core';\r\n\r\n@Directive({\r\n selector: '[tooltip]',\r\n standalone: false\r\n})\r\nexport class TooltipDirective implements OnDestroy {\r\n\r\n @Input() tooltip = ''; // The text for the tooltip to display\r\n @Input() delay?= 100; // Optional delay input, in ms\r\n\r\n private myPopup;\r\n private timer;\r\n\r\n constructor(private el: ElementRef) { }\r\n\r\n ngOnDestroy(): void {\r\n if (this.myPopup) { this.myPopup.remove() }\r\n }\r\n\r\n @HostListener('mouseenter') onMouseEnter() {\r\n this.timer = setTimeout(() => {\r\n let x = this.el.nativeElement.getBoundingClientRect().left + this.el.nativeElement.offsetWidth / 2; // Get the middle of the element\r\n let y = this.el.nativeElement.getBoundingClientRect().top + this.el.nativeElement.offsetHeight + 6; // Get the bottom of the element, plus a little extra\r\n this.createTooltipPopup(x, y);\r\n }, this.delay)\r\n }\r\n\r\n @HostListener('mouseleave') onMouseLeave() {\r\n if (this.timer) clearTimeout(this.timer);\r\n if (this.myPopup) { this.myPopup.remove() }\r\n }\r\n\r\n private createTooltipPopup(x: number, y: number) {\r\n let popup = document.createElement(\"div\");\r\n popup.innerHTML = this.tooltip;\r\n popup.setAttribute(\"class\", \"tooltip-container\");\r\n popup.style.top = y.toString() + \"px\";\r\n popup.style.left = x.toString() + \"px\";\r\n //document.body.appendChild(popup); //doesn't work in our context - maybe because of Stefan's app routing?\r\n this.el.nativeElement.parentNode.appendChild(popup); //append the child to the parent instead\r\n this.myPopup = popup;\r\n // setTimeout(() => {\r\n // if (this.myPopup) this.myPopup.remove();\r\n // }, 5000); // Remove tooltip after 5 seconds \r\n }\r\n\r\n}","import { NgModule } from '@angular/core';\r\nimport { RouterModule, Routes } from '@angular/router';\r\nimport { DefaultLayoutComponent } from './containers/default-layout/default-layout.component';\r\nimport { DefaultComponent } from './views/default/default.component';\r\nimport { Error404Component } from './views/error/error404/error404.component';\r\nimport { Error500Component } from './views/error/error500/error500.component';\r\nimport { EmfLitComponent } from './views/emf-lit/emf-lit.component';\r\n\r\nconst routes: Routes = [\r\n {\r\n path: '',\r\n redirectTo: 'default',\r\n pathMatch: 'full'\r\n },\r\n {\r\n path: '404',\r\n component: Error404Component\r\n },\r\n {\r\n path: '500',\r\n component: Error500Component\r\n },\r\n {\r\n path: '',\r\n component: DefaultLayoutComponent,\r\n data: {\r\n title: 'Limit Info Tool für Elektromagnetische Felder (EMF-LIT)'\r\n },\r\n children: [\r\n {\r\n path: 'default',\r\n component: EmfLitComponent\r\n }\r\n ]\r\n },\r\n {\r\n path: '**',\r\n component: Error404Component\r\n }\r\n];\r\n\r\n@NgModule({\r\n imports: [RouterModule.forRoot(routes)],\r\n exports: [RouterModule]\r\n})\r\nexport class AppRoutingModule { }\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-root',\r\n template: '<router-outlet></router-outlet>',\r\n standalone: false\r\n})\r\nexport class AppComponent {\r\n title = 'template';\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss'],\r\n standalone: false\r\n})\r\nexport class DefaultComponent implements OnInit {\r\n\r\n constructor() { }\r\n\r\n ngOnInit(): void {\r\n }\r\n\r\n}\r\n","<p>Test</p>\r\n\r\n<app-tabs>\r\n <app-tab-item label=\"B-Feld\">\r\n <app-tab-body>\r\n B-Feld\r\n </app-tab-body>\r\n </app-tab-item>\r\n <app-tab-item label=\"E-Feld\">\r\n <app-tab-body>\r\n E-Feld\r\n </app-tab-body>\r\n </app-tab-item>\r\n</app-tabs>","export interface NavigationData {\r\n name: string;\r\n url: string;\r\n}\r\n\r\nexport const navigationItems: NavigationData[] = [\r\n {\r\n name: \"Default component\",\r\n url: \"/default\"\r\n }\r\n]","import { Component, OnInit } from '@angular/core';\r\nimport { NavigationEnd, Router } from '@angular/router';\r\nimport { filter } from 'rxjs/operators';\r\nimport { NavigationData, navigationItems } from 'src/app/_nav';\r\n\r\n@Component({\r\n selector: 'app-default-navbar',\r\n templateUrl: './default-navbar.component.html',\r\n styleUrls: ['./default-navbar.component.scss'],\r\n standalone: false\r\n})\r\nexport class DefaultNavbarComponent implements OnInit {\r\n navItems: NavigationData[] = navigationItems;\r\n currentActiveNavItem: NavigationData;\r\n\r\n constructor(\r\n private router: Router\r\n ) {\r\n this.router.events.pipe(filter(e => e instanceof NavigationEnd))\r\n .subscribe((value: any) => this.colorCurrentLink(value.urlAfterRedirects));\r\n }\r\n\r\n ngOnInit(): void {\r\n }\r\n\r\n private colorCurrentLink(urlAfterRedirects: string): void {\r\n this.navItems.forEach(i => {\r\n if (urlAfterRedirects === i.url) {\r\n this.currentActiveNavItem = i;\r\n }\r\n })\r\n }\r\n\r\n}\r\n","<div *ngIf=\"navItems.length !== 0\" id=\"topnav\">\r\n <dl>\r\n <dd *ngFor=\"let navItem of navItems\">\r\n <a [ngClass]=\"navItem.name === currentActiveNavItem.name ? 'active' : ''\" title={{navItem.name}}\r\n class=\"navigationLink\" href={{navItem.url}}>{{navItem.name}}</a>\r\n </dd>\r\n </dl>\r\n</div>","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TabsComponent } from './tabs.component';\r\nimport { TabBodyComponent } from './tab-body/tab-body.component';\r\nimport { TabItemComponent } from './tab-item/tab-item.component';\r\n\r\n\r\n\r\n@NgModule({\r\n declarations: [\r\n TabsComponent,\r\n TabBodyComponent,\r\n TabItemComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n TabsComponent,\r\n TabBodyComponent,\r\n TabItemComponent\r\n ]\r\n})\r\nexport class TabsModule { }\r\n","class TranslateHttpLoader {\n http;\n prefix;\n suffix;\n constructor(http, prefix = \"/assets/i18n/\", suffix = \".json\") {\n this.http = http;\n this.prefix = prefix;\n this.suffix = suffix;\n }\n /**\n * Gets the translations from the server\n */\n getTranslation(lang) {\n return this.http.get(`${this.prefix}${lang}${this.suffix}`);\n }\n}\n\n/**\n * Generated bundle index. Do not edit.\n */\n\nexport { TranslateHttpLoader };\n","import { NgModule } from '@angular/core';\r\nimport { BrowserModule } from '@angular/platform-browser';\r\n\r\nimport { AppRoutingModule } from './app-routing.module';\r\nimport { AppComponent } from './app.component';\r\nimport { DefaultLayoutComponent } from './containers/default-layout/default-layout.component';\r\nimport { Error404Component } from './views/error/error404/error404.component';\r\nimport { Error500Component } from './views/error/error500/error500.component';\r\nimport { DefaultComponent } from './views/default/default.component';\r\nimport { DefaultNavbarComponent } from './containers/default-navbar/default-navbar.component';\r\nimport { TabsModule } from './containers/tabs/tabs.module';\r\nimport { DefaultTabbarComponent } from './containers/default-tabbar/default-tabbar.component';\r\nimport { TooltipDirective } from './views/emf-lit/tooltip.directive';\r\nimport { EmfLitComponent } from './views/emf-lit/emf-lit.component';\r\nimport { FormsModule } from \"@angular/forms\";\r\nimport { HttpClient, provideHttpClient, withInterceptorsFromDi } from '@angular/common/http';\r\nimport {TranslateModule, TranslateLoader} from '@ngx-translate/core';\r\nimport {TranslateHttpLoader} from '@ngx-translate/http-loader';\r\n\r\n// AoT requires an exported function for factories\r\nexport function HttpLoaderFactory(http: HttpClient) {\r\n return new TranslateHttpLoader(http);\r\n}\r\n\r\n@NgModule({ declarations: [\r\n AppComponent,\r\n DefaultLayoutComponent,\r\n Error404Component,\r\n Error500Component,\r\n DefaultComponent,\r\n DefaultNavbarComponent,\r\n DefaultTabbarComponent,\r\n TooltipDirective,\r\n EmfLitComponent\r\n ],\r\n bootstrap: [AppComponent], imports: [BrowserModule,\r\n FormsModule,\r\n AppRoutingModule,\r\n TabsModule,\r\n TranslateModule.forRoot({\r\n loader: {\r\n provide: TranslateLoader,\r\n useFactory: HttpLoaderFactory,\r\n deps: [HttpClient]\r\n }\r\n })], providers: [provideHttpClient(withInterceptorsFromDi())] })\r\nexport class AppModule { }\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/plugins/zone-error'; // Included with Angular CLI.\r\n","/// <reference types=\"@angular/localize\" />\r\n\r\nimport { enableProdMode } from '@angular/core';\r\nimport { platformBrowserDynamic } from '@angular/platform-browser-dynamic';\r\n\r\nimport { AppModule } from './app/app.module';\r\nimport { environment } from './environments/environment';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAOA,KAAC,SAAU,QAAQ,SAAS;AAC1B,aAAO,YAAY,YAAY,OAAO,WAAW,cAAc,OAAO,UAAU,QAAQ,IAAI,OAAO,WAAW,cAAc,OAAO,MAAM,OAAO,OAAO,IAAI,OAAO,SAAS,QAAQ;AAAA,IACrL,GAAG,SAAM,WAAY;AACnB;AAEA,U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A;AAAA;AAAA;AAAA,EAIA,eAAe,MAAM;AACnB,WAAO,KAAK,KAAK,IAAI,GAAG,KAAK,MAAM,GAAG,IAAI,GAAG,KAAK,MAAM,EAAE;AAAA,EAC5D;AACF;;;ACKM,SAAU,kBAAkB,MAAgB;AAChD,SAAO,IAAI,oBAAoB,IAAI;AACrC;AAwBM,IAAO,YAAP,MAAO,WAAS;;;uCAAT,YAAS;IAAA;EAAA;;wEAAT,YAAS,WAAA,CAXN,YAAY,EAAA,CAAA;EAAA;;6EAUJ,CAAC,kBAAkB,uBAAsB,CAAE,CAAC,GAAC,SAAA;MAV5B;MACjC;MACA;MACA;MACA,gBAAgB,QAAQ;QACpB,QAAQ;UACJ,SAAS;UACT,YAAY;UACZ,MAAM,CAAC,UAAU;;OAExB;IAAC,EAAA,CAAA;EAAA;;;;ACzCH,IAAM,cAAc;EACzB,YAAY;;;;ACGd,IAAI,YAAY,YAAY;AAC1B,iBAAc;AAChB;AAEA,gBAAA,EAAyB,gBAAgB,SAAS,EAC/C,MAAM,SAAO,QAAQ,MAAM,GAAG,CAAC;","names":["isArray","input","isObject","isDate","map","format","locale","to","from","config","isFunction","now","sign","token","ordinal","i","diff","u","localeData","indexOf","createDate","hours","minutes","normalizeLocale","split","match","tokens","meridiem","years","months","weeks","days","seconds","milliseconds","offset","model","toDate","round","thresholds","require","module","convert","model","k","keyword","match","colorString","models","queue","from","routes","options","merge","src","rtl","Element","scales","elements","defaultColor","skip","scale","last","name","config","canvas","valueOrDefault","eventListenerOptions","plugins","title","Chart","animation","round","isArray","first","noop","meta","DEFAULT_MIN","DEFAULT_MAX","input","map","fillText","legend","Title","computed","node","UnsubscriptionErrorImpl","empty","input","observable","ObjectUnsubscribedErrorImpl","observable","refCount","delay","delay","delay","delay","delay","empty","input","input","NotificationKind","empty","delay","ArgumentOutOfRangeErrorImpl","EmptyErrorImpl","iterator","observable","input","observable","input","input","iterator","input","input","input","input","input","empty","first","i","delay","queue","empty","empty","config","refCount","err","name","throwError","throwError","throwError","injectorProfiler","effect","InjectFlags","getCurrentInjector","setCurrentInjector","input","setCurrentInjector","getCurrentInjector","FactoryTarget","R3TemplateDependencyKind","ViewEncapsulation","paramTypes","paramAnnotations","throwError","throwError","store","profiler","CheckNoChangesMode","throwError","isInI18nBlock","throwError","location","NOT_FOUND","noop","self","ChangeDetectionStrategy","document","TracingAction","AfterRenderPhase","scheduled","DeferDependenciesLoadingState","DeferBlockState","DeferBlockInternalState","DeferBlockBehavior","throwError","isRootView","HydrationStatus","ViewEncapsulation","match","SecurityContext","input","schemas","throwError","first","isInlineTemplate","environment","InputFlags","publicName","errorHandler","RendererStyleFlags2","isComponent","effect","getInsertInFrontOfRNodeWithI18n","processI18nInsertBefore","environment","TemplateRef","input","throwError","config","map","environment","ViewContainerRef","throwError","throwError","i","config","iterator","callback","delay","parentEnvInjector","effect","throwError","i","instance","isStandaloneComponent","cb","queue","isPromise","isPromise","config","throwError","queue","tNode","delay","throwError","keyValueArraySet","match","LocaleDataIndex","plural","I18nCreateOpCode","lastNodeWasCreated","throwError","changeMask","value","index","match","substring","remove","inertBodyHelper","hasBinding","placeholder","templateId","isCloseTemplateTag","isComponent","multiFactory","pipe","location","moduleType","modules","importingModule","proto","type","ngModuleDef","pipe","MissingTranslationStrategy","config","errorHandler","isPromise","isPipe","index","item","map","record","effect","errorHandler","noop","ResourceStatus","request","DOCUMENT","window","isAbsoluteUrl","NumberFormatStyle","Plural","FormStyle","TranslationWidth","FormatWidth","WeekDay","getLocaleId","getLocalePluralCase","match","value","getLocaleId","formatValue","from","isDate","carry","digits","plural","getLocalePluralCase","EMPTY_ARRAY","klass","async","isPromise","input","VERSION","DOCUMENT","document","window","config","DOCUMENT","deepForEach","input","OVERSIZED_IMAGE_TOLERANCE","config","input","OVERSIZED_IMAGE_TOLERANCE","value","map","base","headers","params","HttpEventType","HttpStatusCode","first","req","noop","signal","document","DOCUMENT","HttpFeatureKind","request","plugin","DOCUMENT","DOCUMENT","elem","DOCUMENT","HydrationFeatureKind","VERSION","last","isPromise","tree","match","res","commands","noMatch","stringify","EventType","NavigationCancellationCode","NavigationSkippedCode","config","routes","t","c","node","map","location","tree","contexts","NOT_FOUND","isFunction","canActivate","last","config","s","routes","tree","input","from","document","DOCUMENT","t","e","routes","config","VERSION","isObject","store","config","isPromise","acc","noop","FormControl","input","VERSION","element"],"x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,115,131]}