fix(router): reexport router directives

This commit is contained in:
vsavkin 2016-06-29 15:11:36 -07:00
parent 8aa388de6c
commit f208ee0d57
2 changed files with 48 additions and 2 deletions

View File

@ -19,9 +19,12 @@ export {provideRouter} from './src/router_providers';
export {ActivatedRoute, ActivatedRouteSnapshot, RouterState, RouterStateSnapshot} from './src/router_state';
export {PRIMARY_OUTLET, Params} from './src/shared';
export {DefaultUrlSerializer, UrlPathWithParams, UrlSerializer, UrlTree} from './src/url_tree';
export {RouterLink, RouterLinkWithHref} from './src/directives/router_link';
export {RouterLinkActive} from './src/directives/router_link_active';
export {RouterOutlet} from './src/directives/router_outlet';
/**
* @experimental
* @stable
*/
export const ROUTER_DIRECTIVES = [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive];

View File

@ -123,12 +123,55 @@ export declare class Router {
serializeUrl(url: UrlTree): string;
}
/** @experimental */
/** @stable */
export declare const ROUTER_DIRECTIVES: (typeof RouterOutlet | typeof RouterLink | typeof RouterLinkWithHref | typeof RouterLinkActive)[];
/** @stable */
export declare type RouterConfig = Route[];
/** @stable */
export declare class RouterLink {
fragment: string;
queryParams: {
[k: string]: any;
};
routerLink: any[] | string;
urlTree: UrlTree;
onClick(button: number, ctrlKey: boolean, metaKey: boolean): boolean;
}
/** @stable */
export declare class RouterLinkActive implements OnChanges, OnDestroy, AfterContentInit {
routerLinkActive: string[] | string;
ngAfterContentInit(): void;
ngOnChanges(changes: {}): any;
ngOnDestroy(): any;
}
/** @stable */
export declare class RouterLinkWithHref implements OnChanges {
fragment: string;
href: string;
queryParams: {
[k: string]: any;
};
routerLink: any[] | string;
target: string;
urlTree: UrlTree;
ngOnChanges(changes: {}): any;
onClick(button: number, ctrlKey: boolean, metaKey: boolean): boolean;
}
/** @stable */
export declare class RouterOutlet {
activatedRoute: ActivatedRoute;
component: Object;
isActivated: boolean;
outletMap: RouterOutletMap;
activate(activatedRoute: ActivatedRoute, providers: ResolvedReflectiveProvider[], outletMap: RouterOutletMap): void;
deactivate(): void;
}
/** @stable */
export declare class RouterOutletMap {
registerOutlet(name: string, outlet: RouterOutlet): void;