docs(*): Document a lot more symbols that are missing comments in our generated docs.
This commit is contained in:
@ -53,6 +53,9 @@ var _chromeNumKeyPadMap = {
|
||||
'\x90': 'NumLock'
|
||||
};
|
||||
|
||||
/**
|
||||
* A `DomAdapter` powered by full browser DOM APIs.
|
||||
*/
|
||||
/* tslint:disable:requireParameterType */
|
||||
export class BrowserDomAdapter extends GenericBrowserDomAdapter {
|
||||
parse(templateHtml: string) { throw new Error("parse not implemented"); }
|
||||
|
@ -42,6 +42,11 @@ export {
|
||||
export {BrowserDomAdapter} from './browser/browser_adapter';
|
||||
export {enableDebugTools, disableDebugTools} from 'angular2/src/platform/browser/tools/tools';
|
||||
|
||||
/**
|
||||
* A set of providers to initialize the Angular platform in a web browser.
|
||||
*
|
||||
* Used automatically by `bootstrap`, or can be passed to {@link platform}.
|
||||
*/
|
||||
export const BROWSER_PROVIDERS: Array<any /*Type | Provider | any[]*/> = CONST_EXPR([
|
||||
PLATFORM_COMMON_PROVIDERS,
|
||||
new Provider(PLATFORM_INITIALIZER, {useValue: initDomAdapter, multi: true}),
|
||||
@ -57,6 +62,11 @@ function _document(): any {
|
||||
return DOM.defaultDoc();
|
||||
}
|
||||
|
||||
/**
|
||||
* A set of providers to initialize an Angular application in a web browser.
|
||||
*
|
||||
* Used automatically by `bootstrap`, or can be passed to {@link PlatformRef.application}.
|
||||
*/
|
||||
export const BROWSER_APP_COMMON_PROVIDERS: Array<any /*Type | Provider | any[]*/> = CONST_EXPR([
|
||||
APPLICATION_COMMON_PROVIDERS,
|
||||
FORM_PROVIDERS,
|
||||
|
@ -3,9 +3,26 @@ import {Predicate} from 'angular2/src/facade/collection';
|
||||
import {DOM} from 'angular2/src/platform/dom/dom_adapter';
|
||||
import {DebugElement} from 'angular2/core';
|
||||
|
||||
/**
|
||||
* Predicates for use with {@link DebugElement}'s query functions.
|
||||
*/
|
||||
export class By {
|
||||
static all(): Function { return (debugElement) => true; }
|
||||
/**
|
||||
* Match all elements.
|
||||
*
|
||||
* ## Example
|
||||
*
|
||||
* {@example platform/dom/debug/ts/by/by.ts region='by_all'}
|
||||
*/
|
||||
static all(): Predicate<DebugElement> { return (debugElement) => true; }
|
||||
|
||||
/**
|
||||
* Match elements by the given CSS selector.
|
||||
*
|
||||
* ## Example
|
||||
*
|
||||
* {@example platform/dom/debug/ts/by/by.ts region='by_css'}
|
||||
*/
|
||||
static css(selector: string): Predicate<DebugElement> {
|
||||
return (debugElement) => {
|
||||
return isPresent(debugElement.nativeElement) ?
|
||||
@ -13,6 +30,14 @@ export class By {
|
||||
false;
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* Match elements that have the given directive present.
|
||||
*
|
||||
* ## Example
|
||||
*
|
||||
* {@example platform/dom/debug/ts/by/by.ts region='by_directive'}
|
||||
*/
|
||||
static directive(type: Type): Predicate<DebugElement> {
|
||||
return (debugElement) => { return debugElement.hasDirective(type); };
|
||||
}
|
||||
|
@ -72,9 +72,21 @@ export class DebugElementViewListener implements AppViewListener {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Providers which support debugging Angular applications (e.g. via `ng.probe`).
|
||||
*
|
||||
* ## Example
|
||||
*
|
||||
* {@example platform/dom/debug/ts/debug_element_view_listener/providers.ts region='providers'}
|
||||
*/
|
||||
export const ELEMENT_PROBE_PROVIDERS: any[] = CONST_EXPR([
|
||||
DebugElementViewListener,
|
||||
CONST_EXPR(new Provider(AppViewListener, {useExisting: DebugElementViewListener})),
|
||||
]);
|
||||
|
||||
/**
|
||||
* Use {@link ELEMENT_PROBE_PROVIDERS}.
|
||||
*
|
||||
* @deprecated
|
||||
*/
|
||||
export const ELEMENT_PROBE_BINDINGS = ELEMENT_PROBE_PROVIDERS;
|
||||
|
Reference in New Issue
Block a user