feat(core): renam AMBIENT_DIRECTIVES and AMBIENT_PIPES into PLATFORM_DIRECTIVES and PLATFORM_PIPES

After discussing it we decided that PLATFORM_ is a better prefix for directives available everywhere in the app.

BREAKING CHANGE

AMBIENT_DIRECTIVES -> PLATFORM_DIRECTIVES
AMBIENT_PIPES -> PLATFORM_PIPES

Closes #5201
This commit is contained in:
vsavkin
2015-11-09 14:33:22 -08:00
committed by Victor Savkin
parent 2618becaa5
commit e27665c368
16 changed files with 72 additions and 72 deletions

View File

@ -14,7 +14,7 @@ import {DirectiveResolver} from './directive_resolver';
import {ViewResolver} from './view_resolver';
import {PipeResolver} from './pipe_resolver';
import {ViewMetadata, ViewEncapsulation} from '../metadata/view';
import {AMBIENT_PIPES} from 'angular2/src/core/ambient';
import {PLATFORM_PIPES} from 'angular2/src/core/platform_directives_and_pipes';
import {
visitAllCommands,
@ -40,7 +40,7 @@ export class ProtoViewFactory {
private _nextTemplateId: number = 0;
constructor(private _renderer: Renderer,
@Optional() @Inject(AMBIENT_PIPES) private _ambientPipes: Array<Type | any[]>,
@Optional() @Inject(PLATFORM_PIPES) private _platformPipes: Array<Type | any[]>,
private _directiveResolver: DirectiveResolver, private _viewResolver: ViewResolver,
private _pipeResolver: PipeResolver, @Inject(APP_ID) private _appId: string) {}
@ -119,8 +119,8 @@ export class ProtoViewFactory {
private _flattenPipes(view: ViewMetadata): any[] {
let pipes = [];
if (isPresent(this._ambientPipes)) {
_flattenArray(this._ambientPipes, pipes);
if (isPresent(this._platformPipes)) {
_flattenArray(this._platformPipes, pipes);
}
if (isPresent(view.pipes)) {
_flattenArray(view.pipes, pipes);