@angular/core 5.2.1 → 5.2.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/esm2015/core.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v5.2.1
2
+ * @license Angular v5.2.5
3
3
  * (c) 2010-2018 Google, Inc. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -7,6 +7,7 @@ import { Observable } from 'rxjs/Observable';
7
7
  import { merge } from 'rxjs/observable/merge';
8
8
  import { share } from 'rxjs/operator/share';
9
9
  import { Subject } from 'rxjs/Subject';
10
+ import { Subscription } from 'rxjs/Subscription';
10
11
 
11
12
  /**
12
13
  * @fileoverview added by tsickle
@@ -682,7 +683,7 @@ class Version {
682
683
  /**
683
684
  * \@stable
684
685
  */
685
- const VERSION = new Version('5.2.1');
686
+ const VERSION = new Version('5.2.5');
686
687
 
687
688
  /**
688
689
  * @fileoverview added by tsickle
@@ -796,6 +797,7 @@ const __self = typeof self !== 'undefined' && typeof WorkerGlobalScope !== 'unde
796
797
  self instanceof WorkerGlobalScope && self;
797
798
  const __global = typeof global !== 'undefined' && global;
798
799
  const _global = __window || __global || __self;
800
+ const promise = Promise.resolve(0);
799
801
  let _symbolIterator = null;
800
802
  /**
801
803
  * @return {?}
@@ -825,7 +827,13 @@ function getSymbolIterator() {
825
827
  * @return {?}
826
828
  */
827
829
  function scheduleMicroTask(fn) {
828
- Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
830
+ if (typeof Zone === 'undefined') {
831
+ // use promise to schedule microTask instead of use Zone
832
+ promise.then(() => { fn && fn.apply(null, null); });
833
+ }
834
+ else {
835
+ Zone.current.scheduleMicroTask('scheduleMicrotask', fn);
836
+ }
829
837
  }
830
838
  /**
831
839
  * @param {?} a
@@ -3703,7 +3711,11 @@ class EventEmitter extends Subject {
3703
3711
  this.__isAsync ? () => { setTimeout(() => complete()); } : () => { complete(); };
3704
3712
  }
3705
3713
  }
3706
- return super.subscribe(schedulerFn, errorFn, completeFn);
3714
+ const /** @type {?} */ sink = super.subscribe(schedulerFn, errorFn, completeFn);
3715
+ if (generatorOrNext instanceof Subscription) {
3716
+ generatorOrNext.add(sink);
3717
+ }
3718
+ return sink;
3707
3719
  }
3708
3720
  }
3709
3721
 
@@ -4169,23 +4181,13 @@ class Testability {
4169
4181
  */
4170
4182
  _runCallbacksIfReady() {
4171
4183
  if (this.isStable()) {
4172
- if (this._callbacks.length !== 0) {
4173
- // Schedules the call backs after a macro task run outside of the angular zone to make sure
4174
- // no new task are added
4175
- this._ngZone.runOutsideAngular(() => {
4176
- setTimeout(() => {
4177
- if (this.isStable()) {
4178
- while (this._callbacks.length !== 0) {
4179
- (/** @type {?} */ ((this._callbacks.pop())))(this._didWork);
4180
- }
4181
- this._didWork = false;
4182
- }
4183
- });
4184
- });
4185
- }
4186
- else {
4184
+ // Schedules the call backs in a new frame so that it is always async.
4185
+ scheduleMicroTask(() => {
4186
+ while (this._callbacks.length !== 0) {
4187
+ (/** @type {?} */ ((this._callbacks.pop())))(this._didWork);
4188
+ }
4187
4189
  this._didWork = false;
4188
- }
4190
+ });
4189
4191
  }
4190
4192
  else {
4191
4193
  // Not Ready
@@ -5169,6 +5171,7 @@ class QueryList {
5169
5171
  this.dirty = true;
5170
5172
  this._results = [];
5171
5173
  this.changes = new EventEmitter();
5174
+ this.length = 0;
5172
5175
  }
5173
5176
  /**
5174
5177
  * See
@@ -8100,7 +8103,7 @@ function checkAndUpdateBinding(view, def, bindingIdx, value) {
8100
8103
  function checkBindingNoChanges(view, def, bindingIdx, value) {
8101
8104
  const /** @type {?} */ oldValue = view.oldValues[def.bindingIndex + bindingIdx];
8102
8105
  if ((view.state & 1 /* BeforeFirstCheck */) || !devModeEqual(oldValue, value)) {
8103
- const /** @type {?} */ bindingName = def.bindings[def.bindingIndex].name;
8106
+ const /** @type {?} */ bindingName = def.bindings[bindingIdx].name;
8104
8107
  throw expressionChangedAfterItHasBeenCheckedError(Services.createDebugContext(view, def.nodeIndex), `${bindingName}: ${oldValue}`, `${bindingName}: ${value}`, (view.state & 1 /* BeforeFirstCheck */) !== 0);
8105
8108
  }
8106
8109
  }
@@ -15827,7 +15830,7 @@ function invertObject(obj) {
15827
15830
  * The `\@childAnimation` trigger will not animate because `\@.disabled` prevents it from happening
15828
15831
  * (when true).
15829
15832
  *
15830
- * Note that `\@.disbled` will only disable all animations (this means any animations running on
15833
+ * Note that `\@.disabled` will only disable all animations (this means any animations running on
15831
15834
  * the same element will also be disabled).
15832
15835
  *
15833
15836
  * ### Disabling Animations Application-wide
@@ -16848,5 +16851,5 @@ function transition$$1(stateChangeExpr, steps) {
16848
16851
  * Generated bundle index. Do not edit.
16849
16852
  */
16850
16853
 
16851
- export { createPlatform, assertPlatform, destroyPlatform, getPlatform, PlatformRef, ApplicationRef, enableProdMode, isDevMode, createPlatformFactory, NgProbeToken, APP_ID, PACKAGE_ROOT_URL, PLATFORM_INITIALIZER, PLATFORM_ID, APP_BOOTSTRAP_LISTENER, APP_INITIALIZER, ApplicationInitStatus, DebugElement, DebugNode, asNativeElements, getDebugNode, Testability, TestabilityRegistry, setTestabilityGetter, TRANSLATIONS, TRANSLATIONS_FORMAT, LOCALE_ID, MissingTranslationStrategy, ApplicationModule, wtfCreateScope, wtfLeave, wtfStartTimeRange, wtfEndTimeRange, Type, EventEmitter, ErrorHandler, Sanitizer, SecurityContext, ANALYZE_FOR_ENTRY_COMPONENTS, Attribute, ContentChild, ContentChildren, Query, ViewChild, ViewChildren, Component, Directive, HostBinding, HostListener, Input, Output, Pipe, CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA, NgModule, ViewEncapsulation, Version, VERSION, forwardRef, resolveForwardRef, Injector, ReflectiveInjector, ResolvedReflectiveFactory, ReflectiveKey, InjectionToken, Inject, Optional, Injectable, Self, SkipSelf, Host, NgZone, RenderComponentType, Renderer, Renderer2, RendererFactory2, RendererStyleFlags2, RootRenderer, COMPILER_OPTIONS, Compiler, CompilerFactory, ModuleWithComponentFactories, ComponentFactory, ComponentRef, ComponentFactoryResolver, ElementRef, NgModuleFactory, NgModuleRef, NgModuleFactoryLoader, getModuleFactory, QueryList, SystemJsNgModuleLoader, SystemJsNgModuleLoaderConfig, TemplateRef, ViewContainerRef, EmbeddedViewRef, ViewRef, ChangeDetectionStrategy, ChangeDetectorRef, DefaultIterableDiffer, IterableDiffers, KeyValueDiffers, SimpleChange, WrappedValue, platformCore, ALLOW_MULTIPLE_PLATFORMS as ɵALLOW_MULTIPLE_PLATFORMS, APP_ID_RANDOM_PROVIDER as ɵAPP_ID_RANDOM_PROVIDER, devModeEqual as ɵdevModeEqual, isListLikeIterable as ɵisListLikeIterable, ChangeDetectorStatus as ɵChangeDetectorStatus, isDefaultChangeDetectionStrategy as ɵisDefaultChangeDetectionStrategy, Console as ɵConsole, ComponentFactory as ɵComponentFactory, CodegenComponentFactoryResolver as ɵCodegenComponentFactoryResolver, ReflectionCapabilities as ɵReflectionCapabilities, RenderDebugInfo as ɵRenderDebugInfo, _global as ɵglobal, looseIdentical as ɵlooseIdentical, stringify as ɵstringify, makeDecorator as ɵmakeDecorator, isObservable as ɵisObservable, isPromise as ɵisPromise, clearOverrides as ɵclearOverrides, overrideComponentView as ɵoverrideComponentView, overrideProvider as ɵoverrideProvider, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR as ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, defineComponent as ɵdefineComponent, detectChanges as ɵdetectChanges, renderComponent as ɵrenderComponent, containerStart as ɵC, directive as ɵD, elementStart as ɵE, text as ɵT, viewStart as ɵV, bind as ɵb, bind1 as ɵb1, containerEnd as ɵc, containerRefreshStart as ɵcR, containerRefreshEnd as ɵcr, elementEnd as ɵe, elementProperty as ɵp, elementStyle as ɵs, textBinding as ɵt, viewEnd as ɵv, registerModuleFactory as ɵregisterModuleFactory, EMPTY_ARRAY as ɵEMPTY_ARRAY, EMPTY_MAP as ɵEMPTY_MAP, anchorDef as ɵand, createComponentFactory as ɵccf, createNgModuleFactory as ɵcmf, createRendererType2 as ɵcrt, directiveDef as ɵdid, elementDef as ɵeld, elementEventFullName as ɵelementEventFullName, getComponentViewDefinitionFactory as ɵgetComponentViewDefinitionFactory, inlineInterpolate as ɵinlineInterpolate, interpolate as ɵinterpolate, moduleDef as ɵmod, moduleProvideDef as ɵmpd, ngContentDef as ɵncd, nodeValue as ɵnov, pipeDef as ɵpid, providerDef as ɵprd, pureArrayDef as ɵpad, pureObjectDef as ɵpod, purePipeDef as ɵppd, queryDef as ɵqud, textDef as ɵted, unwrapValue as ɵunv, viewDef as ɵvid, AUTO_STYLE, trigger$$1 as trigger, animate$$1 as animate, group$$1 as group, sequence$$1 as sequence, style$$1 as style, state$$1 as state, keyframes$$1 as keyframes, transition$$1 as transition, animate$1 as ɵbe, group$1 as ɵbf, keyframes$1 as ɵbj, sequence$1 as ɵbg, state$1 as ɵbi, style$1 as ɵbh, transition$1 as ɵbk, trigger$1 as ɵbd, _iterableDiffersFactory as ɵm, _keyValueDiffersFactory as ɵn, _localeFactory as ɵo, _appIdRandomProviderFactory as ɵh, defaultIterableDiffers as ɵi, defaultKeyValueDiffers as ɵj, DefaultIterableDifferFactory as ɵk, DefaultKeyValueDifferFactory as ɵl, ReflectiveInjector_ as ɵd, ReflectiveDependency as ɵf, resolveReflectiveProviders as ɵg, wtfEnabled as ɵq, createScope$1 as ɵu, detectWTF as ɵr, endTimeRange as ɵy, leave as ɵw, startTimeRange as ɵx, stringify$1 as ɵbb, makeParamDecorator as ɵa, _def as ɵz, DebugContext as ɵba };
16854
+ export { createPlatform, assertPlatform, destroyPlatform, getPlatform, PlatformRef, ApplicationRef, enableProdMode, isDevMode, createPlatformFactory, NgProbeToken, APP_ID, PACKAGE_ROOT_URL, PLATFORM_INITIALIZER, PLATFORM_ID, APP_BOOTSTRAP_LISTENER, APP_INITIALIZER, ApplicationInitStatus, DebugElement, DebugNode, asNativeElements, getDebugNode, Testability, TestabilityRegistry, setTestabilityGetter, TRANSLATIONS, TRANSLATIONS_FORMAT, LOCALE_ID, MissingTranslationStrategy, ApplicationModule, wtfCreateScope, wtfLeave, wtfStartTimeRange, wtfEndTimeRange, Type, EventEmitter, ErrorHandler, Sanitizer, SecurityContext, ANALYZE_FOR_ENTRY_COMPONENTS, Attribute, ContentChild, ContentChildren, Query, ViewChild, ViewChildren, Component, Directive, HostBinding, HostListener, Input, Output, Pipe, CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA, NgModule, ViewEncapsulation, Version, VERSION, forwardRef, resolveForwardRef, Injector, ReflectiveInjector, ResolvedReflectiveFactory, ReflectiveKey, InjectionToken, Inject, Optional, Injectable, Self, SkipSelf, Host, NgZone, RenderComponentType, Renderer, Renderer2, RendererFactory2, RendererStyleFlags2, RootRenderer, COMPILER_OPTIONS, Compiler, CompilerFactory, ModuleWithComponentFactories, ComponentFactory, ComponentRef, ComponentFactoryResolver, ElementRef, NgModuleFactory, NgModuleRef, NgModuleFactoryLoader, getModuleFactory, QueryList, SystemJsNgModuleLoader, SystemJsNgModuleLoaderConfig, TemplateRef, ViewContainerRef, EmbeddedViewRef, ViewRef, ChangeDetectionStrategy, ChangeDetectorRef, DefaultIterableDiffer, IterableDiffers, KeyValueDiffers, SimpleChange, WrappedValue, platformCore, ALLOW_MULTIPLE_PLATFORMS as ɵALLOW_MULTIPLE_PLATFORMS, APP_ID_RANDOM_PROVIDER as ɵAPP_ID_RANDOM_PROVIDER, devModeEqual as ɵdevModeEqual, isListLikeIterable as ɵisListLikeIterable, ChangeDetectorStatus as ɵChangeDetectorStatus, isDefaultChangeDetectionStrategy as ɵisDefaultChangeDetectionStrategy, Console as ɵConsole, ComponentFactory as ɵComponentFactory, CodegenComponentFactoryResolver as ɵCodegenComponentFactoryResolver, ReflectionCapabilities as ɵReflectionCapabilities, RenderDebugInfo as ɵRenderDebugInfo, _global as ɵglobal, looseIdentical as ɵlooseIdentical, stringify as ɵstringify, makeDecorator as ɵmakeDecorator, isObservable as ɵisObservable, isPromise as ɵisPromise, clearOverrides as ɵclearOverrides, overrideComponentView as ɵoverrideComponentView, overrideProvider as ɵoverrideProvider, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR as ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, defineComponent as ɵdefineComponent, detectChanges as ɵdetectChanges, renderComponent as ɵrenderComponent, containerStart as ɵC, directive as ɵD, elementStart as ɵE, text as ɵT, viewStart as ɵV, bind as ɵb, bind1 as ɵb1, containerEnd as ɵc, containerRefreshStart as ɵcR, containerRefreshEnd as ɵcr, elementEnd as ɵe, elementProperty as ɵp, elementStyle as ɵs, textBinding as ɵt, viewEnd as ɵv, registerModuleFactory as ɵregisterModuleFactory, EMPTY_ARRAY as ɵEMPTY_ARRAY, EMPTY_MAP as ɵEMPTY_MAP, anchorDef as ɵand, createComponentFactory as ɵccf, createNgModuleFactory as ɵcmf, createRendererType2 as ɵcrt, directiveDef as ɵdid, elementDef as ɵeld, elementEventFullName as ɵelementEventFullName, getComponentViewDefinitionFactory as ɵgetComponentViewDefinitionFactory, inlineInterpolate as ɵinlineInterpolate, interpolate as ɵinterpolate, moduleDef as ɵmod, moduleProvideDef as ɵmpd, ngContentDef as ɵncd, nodeValue as ɵnov, pipeDef as ɵpid, providerDef as ɵprd, pureArrayDef as ɵpad, pureObjectDef as ɵpod, purePipeDef as ɵppd, queryDef as ɵqud, textDef as ɵted, unwrapValue as ɵunv, viewDef as ɵvid, AUTO_STYLE, trigger$$1 as trigger, animate$$1 as animate, group$$1 as group, sequence$$1 as sequence, style$$1 as style, state$$1 as state, keyframes$$1 as keyframes, transition$$1 as transition, animate$1 as ɵbf, group$1 as ɵbg, keyframes$1 as ɵbk, sequence$1 as ɵbh, state$1 as ɵbj, style$1 as ɵbi, transition$1 as ɵbl, trigger$1 as ɵbe, _iterableDiffersFactory as ɵn, _keyValueDiffersFactory as ɵo, _localeFactory as ɵq, _appIdRandomProviderFactory as ɵi, defaultIterableDiffers as ɵj, defaultKeyValueDiffers as ɵk, DefaultIterableDifferFactory as ɵl, DefaultKeyValueDifferFactory as ɵm, ReflectiveInjector_ as ɵf, ReflectiveDependency as ɵg, resolveReflectiveProviders as ɵh, wtfEnabled as ɵr, createScope$1 as ɵw, detectWTF as ɵu, endTimeRange as ɵz, leave as ɵx, startTimeRange as ɵy, stringify$1 as ɵbc, makeParamDecorator as ɵa, makePropDecorator as ɵd, _def as ɵba, DebugContext as ɵbb };
16852
16855
  //# sourceMappingURL=core.js.map