chore(router): update build dir
This commit is contained in:
parent
f34af4f249
commit
5d386dc426
|
@ -2,7 +2,7 @@ import { RouterOutletMap } from './router_outlet_map';
|
|||
import { UrlSerializer, DefaultUrlSerializer } from './url_serializer';
|
||||
import { ActivatedRoute } from './router_state';
|
||||
import { Router } from './router';
|
||||
import { ComponentResolver, ApplicationRef } from '@angular/core';
|
||||
import { ComponentResolver, ApplicationRef, Injector } from '@angular/core';
|
||||
import { LocationStrategy, PathLocationStrategy, Location } from '@angular/common';
|
||||
export function provideRouter(config) {
|
||||
return [
|
||||
|
@ -11,20 +11,20 @@ export function provideRouter(config) {
|
|||
{ provide: UrlSerializer, useClass: DefaultUrlSerializer },
|
||||
{
|
||||
provide: Router,
|
||||
useFactory: (ref, resolver, urlSerializer, outletMap, location) => {
|
||||
useFactory: (ref, resolver, urlSerializer, outletMap, location, injector) => {
|
||||
if (ref.componentTypes.length == 0) {
|
||||
throw new Error("Bootstrap at least one component before injecting Router.");
|
||||
}
|
||||
const componentType = ref.componentTypes[0];
|
||||
const r = new Router(componentType, resolver, urlSerializer, outletMap, location);
|
||||
const r = new Router(componentType, resolver, urlSerializer, outletMap, location, injector);
|
||||
r.resetConfig(config);
|
||||
ref.registerDisposeListener(() => r.dispose());
|
||||
return r;
|
||||
},
|
||||
deps: [ApplicationRef, ComponentResolver, UrlSerializer, RouterOutletMap, Location]
|
||||
deps: [ApplicationRef, ComponentResolver, UrlSerializer, RouterOutletMap, Location, Injector]
|
||||
},
|
||||
RouterOutletMap,
|
||||
{ provide: ActivatedRoute, useFactory: (r) => r.routerState.root, deps: [Router] },
|
||||
];
|
||||
}
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tbW9uX3JvdXRlcl9wcm92aWRlcnMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvY29tbW9uX3JvdXRlcl9wcm92aWRlcnMudHMiXSwibmFtZXMiOltdLCJtYX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lbnRUeXBlLCByZXNvbHZlciwgdXJsU2VyaWFsaXplciwgb3V0bGV0TWFwLCBsb2NhdGlvbiwgaW5qZWN0b3IpO1xuICAgICAgICByLnJlc2V0Q29uZmlnKGNvbmZpZyk7XG4gICAgICAgIHJlZi5yZWdpc3RlckRpc3Bvc2VMaXN0ZW5lcigoKSA9PiByLmRpc3Bvc2UoKSk7XG4gICAgICAgIHJldHVybiByO1xuICAgICAgfSxcbiAgICAgIGRlcHM6IFtBcHBsaWNhdGlvblJlZiwgQ29tcG9uZW50UmVzb2x2ZXIsIFVybFNlcmlhbGl6ZXIsIFJvdXRlck91dGxldE1hcCwgTG9jYXRpb24sIEluamVjdG9yXVxuICAgIH0sXG5cbiAgICBSb3V0ZXJPdXRsZXRNYXAsXG4gICAge3Byb3ZpZGU6IEFjdGl2YXRlZFJvdXRlLCB1c2VGYWN0b3J5OiAocikgPT4gci5yb3V0ZXJTdGF0ZS5yb290LCBkZXBzOiBbUm91dGVyXX0sXG4gIF07XG59XG4iXX0=
|
|
@ -5,5 +5,7 @@ export interface Route {
|
|||
path?: string;
|
||||
component: Type | string;
|
||||
outlet?: string;
|
||||
canActivate?: any[];
|
||||
canDeactivate?: any[];
|
||||
children?: Route[];
|
||||
}
|
||||
|
|
|
@ -1 +1 @@
|
|||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29uZmlnLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vc3JjL2NvbmZpZy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgVHlwZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuXG5leHBvcnQgdHlwZSBSb3V0ZXJDb25maWcgPSBSb3V0ZVtdO1xuXG5leHBvcnQgaW50ZXJmYWNlIFJvdXRlIHtcbiAgaW5kZXg/OiBib29sZWFuO1xuICBwYXRoPzogc3RyaW5nO1xuICBjb21wb25lbnQ6IFR5cGUgfCBzdHJpbmc7XG4gIG91dGxldD86IHN0cmluZztcbiAgY2hpbGRyZW4/OiBSb3V0ZVtdO1xufSJdfQ==
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29uZmlnLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vc3JjL2NvbmZpZy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgVHlwZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuXG5leHBvcnQgdHlwZSBSb3V0ZXJDb25maWcgPSBSb3V0ZVtdO1xuXG5leHBvcnQgaW50ZXJmYWNlIFJvdXRlIHtcbiAgaW5kZXg/OiBib29sZWFuO1xuICBwYXRoPzogc3RyaW5nO1xuICBjb21wb25lbnQ6IFR5cGUgfCBzdHJpbmc7XG4gIG91dGxldD86IHN0cmluZztcbiAgY2FuQWN0aXZhdGU/OiBhbnlbXSxcbiAgY2FuRGVhY3RpdmF0ZT86IGFueVtdLFxuICBjaGlsZHJlbj86IFJvdXRlW107XG59Il19
|
|
@ -0,0 +1,2 @@
|
|||
import { RouterStateSnapshot, RouterState } from './router_state';
|
||||
export declare function createRouterState(curr: RouterStateSnapshot, prevState: RouterState): RouterState;
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -62,4 +62,4 @@ RouterLink = __decorate([
|
|||
Directive({ selector: '[routerLink]' }),
|
||||
__metadata('design:paramtypes', [Router, ActivatedRoute])
|
||||
], RouterLink);
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicm91dGVyX2xpbmsuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi9zcmMvZGlyZWN0aXZlcy9yb3V0ZXJfbGluay50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91dGVyLnNlcmlhbGl6ZVVybCh0cmVlKTtcbiAgICB9XG4gIH1cbn1cbiJdfQ==
|
|
@ -6,6 +6,7 @@ export declare class RouterOutlet {
|
|||
outletMap: RouterOutletMap;
|
||||
constructor(parentOutletMap: RouterOutletMap, location: ViewContainerRef, name: string);
|
||||
readonly isActivated: boolean;
|
||||
readonly component: Object;
|
||||
deactivate(): void;
|
||||
activate(factory: ComponentFactory<any>, providers: ResolvedReflectiveProvider[], outletMap: RouterOutletMap): void;
|
||||
}
|
||||
|
|
|
@ -19,6 +19,11 @@ export let RouterOutlet = class RouterOutlet {
|
|||
parentOutletMap.registerOutlet(name ? name : PRIMARY_OUTLET, this);
|
||||
}
|
||||
get isActivated() { return !!this.activated; }
|
||||
get component() {
|
||||
if (!this.activated)
|
||||
throw new Error("Outlet is not activated");
|
||||
return this.activated.instance;
|
||||
}
|
||||
deactivate() {
|
||||
if (this.activated) {
|
||||
this.activated.destroy();
|
||||
|
@ -27,7 +32,7 @@ export let RouterOutlet = class RouterOutlet {
|
|||
}
|
||||
activate(factory, providers, outletMap) {
|
||||
this.outletMap = outletMap;
|
||||
let inj = ReflectiveInjector.fromResolvedProviders(providers, this.location.parentInjector);
|
||||
const inj = ReflectiveInjector.fromResolvedProviders(providers, this.location.parentInjector);
|
||||
this.activated = this.location.createComponent(factory, this.location.length, inj, []);
|
||||
}
|
||||
};
|
||||
|
@ -36,4 +41,4 @@ RouterOutlet = __decorate([
|
|||
__param(2, Attribute('name')),
|
||||
__metadata('design:paramtypes', [RouterOutletMap, ViewContainerRef, String])
|
||||
], RouterOutlet);
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicm91dGVyX291dGxldC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy9kaXJlY3RpdmVzL3JvdXRlcl9vdXRsZXQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7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
||||
export { UrlSerializer, DefaultUrlSerializer } from './url_serializer';
|
||||
export { RouterState, ActivatedRoute } from './router_state';
|
||||
export { RouterState, ActivatedRoute, RouterStateSnapshot, ActivatedRouteSnapshot } from './router_state';
|
||||
export { UrlTree, UrlSegment } from './url_tree';
|
||||
export { RouterOutletMap } from './router_outlet_map';
|
||||
export { RouterConfig, Route } from './config';
|
||||
export { Params, PRIMARY_OUTLET } from './shared';
|
||||
export { provideRouter } from './router_providers';
|
||||
export { CanActivate, CanDeactivate } from './interfaces';
|
||||
import { RouterOutlet } from './directives/router_outlet';
|
||||
import { RouterLink } from './directives/router_link';
|
||||
export declare const ROUTER_DIRECTIVES: (typeof RouterOutlet | typeof RouterLink)[];
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
export { Router } from './router';
|
||||
export { UrlSerializer, DefaultUrlSerializer } from './url_serializer';
|
||||
export { RouterState, ActivatedRoute } from './router_state';
|
||||
export { RouterState, ActivatedRoute, RouterStateSnapshot, ActivatedRouteSnapshot } from './router_state';
|
||||
export { UrlTree, UrlSegment } from './url_tree';
|
||||
export { RouterOutletMap } from './router_outlet_map';
|
||||
export { PRIMARY_OUTLET } from './shared';
|
||||
|
@ -8,4 +8,4 @@ export { provideRouter } from './router_providers';
|
|||
import { RouterOutlet } from './directives/router_outlet';
|
||||
import { RouterLink } from './directives/router_link';
|
||||
export const ROUTER_DIRECTIVES = [RouterOutlet, RouterLink];
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsU0FBUyxNQUFNLFFBQVEsVUFBVSxDQUFDO0FBQ2xDLFNBQVMsYUFBYSxFQUFFLG9CQUFvQixRQUFRLGtCQUFrQixDQUFDO0FBQ3ZFLFNBQVMsV0FBVyxFQUFFLGNB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b3J0IHsgUm91dGVyU3RhdGUsIEFjdGl2YXRlZFJvdXRlLCBSb3V0ZXJTdGF0ZVNuYXBzaG90LCBBY3RpdmF0ZWRSb3V0ZVNuYXBzaG90IH0gZnJvbSAnLi9yb3V0ZXJfc3RhdGUnO1xuZXhwb3J0IHsgVXJsVHJlZSwgVXJsU2VnbWVudH0gZnJvbSAnLi91cmxfdHJlZSc7XG5leHBvcnQgeyBSb3V0ZXJPdXRsZXRNYXAgfSBmcm9tICcuL3JvdXRlcl9vdXRsZXRfbWFwJztcbmV4cG9ydCB7IFJvdXRlckNvbmZpZywgUm91dGUgfSBmcm9tICcuL2NvbmZpZyc7XG5leHBvcnQgeyBQYXJhbXMsIFBSSU1BUllfT1VUTEVUIH0gZnJvbSAnLi9zaGFyZWQnO1xuZXhwb3J0IHsgcHJvdmlkZVJvdXRlciB9IGZyb20gJy4vcm91dGVyX3Byb3ZpZGVycyc7XG5leHBvcnQgeyBDYW5BY3RpdmF0ZSwgQ2FuRGVhY3RpdmF0ZSB9IGZyb20gJy4vaW50ZXJmYWNlcyc7XG5cbmltcG9ydCB7IFJvdXRlck91dGxldCB9IGZyb20gJy4vZGlyZWN0aXZlcy9yb3V0ZXJfb3V0bGV0JztcbmltcG9ydCB7IFJvdXRlckxpbmsgfSBmcm9tICcuL2RpcmVjdGl2ZXMvcm91dGVyX2xpbmsnO1xuXG5leHBvcnQgY29uc3QgUk9VVEVSX0RJUkVDVElWRVMgPSBbUm91dGVyT3V0bGV0LCBSb3V0ZXJMaW5rXTsiXX0=
|
|
@ -0,0 +1,8 @@
|
|||
import { Observable } from 'rxjs/Observable';
|
||||
import { ActivatedRouteSnapshot, RouterStateSnapshot } from './router_state';
|
||||
export interface CanActivate {
|
||||
canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean> | boolean;
|
||||
}
|
||||
export interface CanDeactivate<T> {
|
||||
canDeactivate(component: T, route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean> | bo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jtcbn0iXX0=
|
|
@ -1,5 +1,6 @@
|
|||
import { UrlTree } from './url_tree';
|
||||
import { RouterState } from './router_state';
|
||||
import { RouterStateSnapshot } from './router_state';
|
||||
import { RouterConfig } from './config';
|
||||
import { Type } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
export declare function recognize(config: RouterConfig, url: UrlTree, existingState: RouterState): Observable<RouterState>;
|
||||
export declare function recognize(rootComponentType: Type, config: RouterConfig, url: UrlTree): Observable<RouterStateSnapshot>;
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,6 @@
|
|||
import { RouterStateSnapshot } from './router_state';
|
||||
import { ComponentResolver } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import 'rxjs/add/operator/map';
|
||||
import 'rxjs/add/operator/toPromise';
|
||||
export declare function resolve(resolver: ComponentResolver, state: RouterStateSnapshot): Observable<RouterStateSnapshot>;
|
|
@ -0,0 +1,23 @@
|
|||
import 'rxjs/add/operator/map';
|
||||
import { forkJoin } from 'rxjs/observable/forkJoin';
|
||||
import { fromPromise } from 'rxjs/observable/fromPromise';
|
||||
import 'rxjs/add/operator/toPromise';
|
||||
export function resolve(resolver, state) {
|
||||
return resolveNode(resolver, state._root).map(_ => state);
|
||||
}
|
||||
function resolveNode(resolver, node) {
|
||||
if (node.children.length === 0) {
|
||||
return fromPromise(resolver.resolveComponent(node.value.component).then(factory => {
|
||||
node.value._resolvedComponentFactory = factory;
|
||||
return node.value;
|
||||
}));
|
||||
}
|
||||
else {
|
||||
const c = node.children.map(c => resolveNode(resolver, c).toPromise());
|
||||
return forkJoin(c).map(_ => resolver.resolveComponent(node.value.component).then(factory => {
|
||||
node.value._resolvedComponentFactory = factory;
|
||||
return node.value;
|
||||
}));
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzb2x2ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3Vy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m1hcChfID0+IHN0YXRlKTtcbn1cblxuZnVuY3Rpb24gcmVzb2x2ZU5vZGUocmVzb2x2ZXI6IENvbXBvbmVudFJlc29sdmVyLCBub2RlOiBUcmVlTm9kZTxBY3RpdmF0ZWRSb3V0ZVNuYXBzaG90Pik6IE9ic2VydmFibGU8YW55PiB7XG4gIGlmIChub2RlLmNoaWxkcmVuLmxlbmd0aCA9PT0gMCkge1xuICAgIHJldHVybiBmcm9tUHJvbWlzZShyZXNvbHZlci5yZXNvbHZlQ29tcG9uZW50KDxhbnk+bm9kZS52YWx1ZS5jb21wb25lbnQpLnRoZW4oZmFjdG9yeSA9PiB7XG4gICAgICBub2RlLnZhbHVlLl9yZXNvbHZlZENvbXBvbmVudEZhY3RvcnkgPSBmYWN0b3J5O1xuICAgICAgcmV0dXJuIG5vZGUudmFsdWU7XG4gICAgfSkpO1xuICAgIFxuICB9IGVsc2Uge1xuICAgIGNvbnN0IGMgPSBub2RlLmNoaWxkcmVuLm1hcChjID0+IHJlc29sdmVOb2RlKHJlc29sdmVyLCBjKS50b1Byb21pc2UoKSk7XG4gICAgcmV0dXJuIGZvcmtKb2luKGMpLm1hcChfID0+IHJlc29sdmVyLnJlc29sdmVDb21wb25lbnQoPGFueT5ub2RlLnZhbHVlLmNvbXBvbmVudCkudGhlbihmYWN0b3J5ID0+IHtcbiAgICAgIG5vZGUudmFsdWUuX3Jlc29sdmVkQ29tcG9uZW50RmFjdG9yeSA9IGZhY3Rvcnk7XG4gICAgICByZXR1cm4gbm9kZS52YWx1ZTtcbiAgICB9KSk7XG4gIH1cbn0iXX0=
|
|
@ -1,4 +1,4 @@
|
|||
import { ComponentResolver } from '@angular/core';
|
||||
import { ComponentResolver, Type, Injector } from '@angular/core';
|
||||
import { Location } from '@angular/common';
|
||||
import { UrlSerializer } from './url_serializer';
|
||||
import { RouterOutletMap } from './router_outlet_map';
|
||||
|
@ -8,24 +8,25 @@ import { RouterState, ActivatedRoute } from './router_state';
|
|||
import { RouterConfig } from './config';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import 'rxjs/add/operator/map';
|
||||
import 'rxjs/add/operator/scan';
|
||||
import 'rxjs/add/operator/mergeMap';
|
||||
import 'rxjs/add/operator/toPromise';
|
||||
export interface NavigationExtras {
|
||||
relativeTo?: ActivatedRoute;
|
||||
queryParameters?: Params;
|
||||
fragment?: string;
|
||||
}
|
||||
export declare class Router {
|
||||
private rootComponent;
|
||||
private rootComponentType;
|
||||
private resolver;
|
||||
private urlSerializer;
|
||||
private outletMap;
|
||||
private location;
|
||||
private injector;
|
||||
private currentUrlTree;
|
||||
private currentRouterState;
|
||||
private config;
|
||||
private locationSubscription;
|
||||
constructor(rootComponent: Object, resolver: ComponentResolver, urlSerializer: UrlSerializer, outletMap: RouterOutletMap, location: Location);
|
||||
constructor(rootComponentType: Type, resolver: ComponentResolver, urlSerializer: UrlSerializer, outletMap: RouterOutletMap, location: Location, injector: Injector);
|
||||
readonly routerState: RouterState;
|
||||
readonly urlTree: UrlTree;
|
||||
navigateByUrl(url: string): Observable<void>;
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -1,12 +1,14 @@
|
|||
import { Tree, TreeNode } from './utils/tree';
|
||||
import { UrlSegment } from './url_tree';
|
||||
import { Route } from './config';
|
||||
import { Params } from './shared';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { Type } from '@angular/core';
|
||||
import { Type, ComponentFactory } from '@angular/core';
|
||||
export declare class RouterState extends Tree<ActivatedRoute> {
|
||||
queryParams: Observable<Params>;
|
||||
fragment: Observable<string>;
|
||||
constructor(root: TreeNode<ActivatedRoute>, queryParams: Observable<Params>, fragment: Observable<string>);
|
||||
snapshot: RouterStateSnapshot;
|
||||
constructor(root: TreeNode<ActivatedRoute>, queryParams: Observable<Params>, fragment: Observable<string>, snapshot: RouterStateSnapshot);
|
||||
}
|
||||
export declare function createEmptyState(rootComponent: Type): RouterState;
|
||||
export declare class ActivatedRoute {
|
||||
|
@ -14,5 +16,23 @@ export declare class ActivatedRoute {
|
|||
params: Observable<Params>;
|
||||
outlet: string;
|
||||
component: Type | string;
|
||||
constructor(urlSegments: Observable<UrlSegment[]>, params: Observable<Params>, outlet: string, component: Type | string);
|
||||
_futureSnapshot: ActivatedRouteSnapshot;
|
||||
snapshot: ActivatedRouteSnapshot;
|
||||
constructor(urlSegments: Observable<UrlSegment[]>, params: Observable<Params>, outlet: string, component: Type | string, futureSnapshot: ActivatedRouteSnapshot);
|
||||
}
|
||||
export declare class ActivatedRouteSnapshot {
|
||||
urlSegments: UrlSegment[];
|
||||
params: Params;
|
||||
outlet: string;
|
||||
component: Type | string;
|
||||
_resolvedComponentFactory: ComponentFactory<any>;
|
||||
_routeConfig: Route | null;
|
||||
_lastUrlSegment: UrlSegment;
|
||||
constructor(urlSegments: UrlSegment[], params: Params, outlet: string, component: Type | string, routeConfig: Route | null, lastUrlSegment: UrlSegment);
|
||||
}
|
||||
export declare class RouterStateSnapshot extends Tree<ActivatedRouteSnapshot> {
|
||||
queryParams: Params;
|
||||
fragment: string | null;
|
||||
constructor(root: TreeNode<ActivatedRouteSnapshot>, queryParams: Params, fragment: string | null);
|
||||
}
|
||||
export declare function advanceActivatedRoute(route: ActivatedRoute): void;
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -40,4 +40,4 @@ export function equalUrlSegments(a, b) {
|
|||
}
|
||||
return true;
|
||||
}
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXJsX3RyZWUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvdXJsX3RyZWUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ik9BQU8sRUFBRSxJQUFJLEVBQUUsUUFBUSxFQUFFLE1BQU0sY0FBYztPQUN0QyxFQUFFLFlBQVksRUFBRSxNQUFNLG9CQUFvQjtPQUMxQyxFQUFFLGNBQWMsRUFBRSxNQUFNL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WV0ZXJzLmhhc093blByb3BlcnR5KHByb3ApKSB7XG4gICAgICAgIHBhcmFtcy5wdXNoKGAke3Byb3B9PSR7dGhpcy5wYXJhbWV0ZXJzW3Byb3BdfWApO1xuICAgICAgfVxuICAgIH1cbiAgICBjb25zdCBwYXJhbXNTdHJpbmcgPSBwYXJhbXMubGVuZ3RoID4gMCA/IGAoJHtwYXJhbXMuam9pbignLCcpfSlgIDogJyc7XG4gICAgY29uc3Qgb3V0bGV0ID0gdGhpcy5vdXRsZXQgPT09IFBSSU1BUllfT1VUTEVUID8gJycgOiBgJHt0aGlzLm91dGxldH06YDtcbiAgICByZXR1cm4gYCR7b3V0bGV0fSR7dGhpcy5wYXRofSR7cGFyYW1zU3RyaW5nfWA7XG4gIH1cbn1cblxuZXhwb3J0IGZ1bmN0aW9uIGVxdWFsVXJsU2VnbWVudHMoYTogVXJsU2VnbWVudFtdLCBiOiBVcmxTZWdtZW50W10pOiBib29sZWFuIHtcbiAgaWYgKGEubGVuZ3RoICE9PSBiLmxlbmd0aCkgcmV0dXJuIGZhbHNlO1xuICBmb3IgKGxldCBpID0gMDsgaSA8IGEubGVuZ3RoOyArK2kpIHtcbiAgICBpZiAoYVtpXS5wYXRoICE9PSBiW2ldLnBhdGgpIHJldHVybiBmYWxzZTtcbiAgICBpZiAoIXNoYWxsb3dFcXVhbChhW2ldLnBhcmFtZXRlcnMsIGJbaV0ucGFyYW1ldGVycykpIHJldHVybiBmYWxzZTtcbiAgfVxuICByZXR1cm4gdHJ1ZTtcbn1cbiJdfQ==
|
|
@ -5,6 +5,7 @@ export declare function shallowEqual(a: {
|
|||
}): boolean;
|
||||
export declare function flatten<T>(a: T[][]): T[];
|
||||
export declare function first<T>(a: T[]): T | null;
|
||||
export declare function and(bools: boolean[]): boolean;
|
||||
export declare function merge<V>(m1: {
|
||||
[key: string]: V;
|
||||
}, m2: {
|
||||
|
|
|
@ -25,6 +25,9 @@ export function flatten(a) {
|
|||
export function first(a) {
|
||||
return a.length > 0 ? a[0] : null;
|
||||
}
|
||||
export function and(bools) {
|
||||
return bools.reduce((a, b) => a && b, true);
|
||||
}
|
||||
export function merge(m1, m2) {
|
||||
var m = {};
|
||||
for (var attr in m1) {
|
||||
|
@ -46,4 +49,4 @@ export function forEach(map, callback) {
|
|||
}
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29sbGVjdGlvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3NyYy91dGlscy9jb2xsZWN0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLDZCQUE2QixDQUFtQixFQUFFLENBQW1CO0lBQ25FLElBQUksRUFBRSxHQUFHLE1BQU0sQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDLENBQUM7SUFDeEIsSUFBSSxFQUFFLEdBQUcsTUFBTSxDQUFDLElBQUksQ0FBQyxDQUFDLENBQUMsQ0FBQztJQUN4QixFQUFFLENBQUMsQ0FBQyxFQUFFLENBQUMsTUFBTSxJQUFJLEVBQUUsQ0FBQyxNQUFNLENBQUMsQ0FBQyxDQUFDO1FBQzNCLE1BQU0sQ0FBQyxLQUFLLENBQUM7SUFDZixDQUFDO0lBQ0QsSUFBSSxHQUFHLENBQUM7SUFDUixHQUFHLENBQUMsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLEVBQUUsQ0FBQyxHQUFHLEVBQUUsQ0FBQyxNQUFNLEVBQUUsQ0FBQyxFQUFFLEVBQUUsQ0FBQztRQUNuQyxHQUFHLEdBQUcsRUFBRSxDQUFDLENBQUMsQ0FBQyxDQUFDO1FBQ1osRUFBRSxDQUFDLENBQUMsQ0FBQyxDQUFDLEdBQUcsQ0FBQyxLQUFLLENBQUMsQ0FBQyxHQUFHLENBQUMsQ0FBQyxDQUFDLENBQUM7WUFDdEIsTUFBTSxDQUFDLEtBQUssQ0FBQzt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AgZm9yICh2YXIgYXR0ciBpbiBtMikge1xuICAgIGlmIChtMi5oYXNPd25Qcm9wZXJ0eShhdHRyKSkge1xuICAgICAgbVthdHRyXSA9IG0yW2F0dHJdO1xuICAgIH1cbiAgfVxuXG4gIHJldHVybiBtO1xufVxuXG5leHBvcnQgZnVuY3Rpb24gZm9yRWFjaDxLLCBWPihtYXA6IHtba2V5OiBzdHJpbmddOiBWfSwgY2FsbGJhY2s6IC8qKFYsIEspID0+IHZvaWQqLyBGdW5jdGlvbik6IHZvaWQge1xuICBmb3IgKHZhciBwcm9wIGluIG1hcCkge1xuICAgIGlmIChtYXAuaGFzT3duUHJvcGVydHkocHJvcCkpIHtcbiAgICAgIGNhbGxiYWNrKG1hcFtwcm9wXSwgcHJvcCk7XG4gICAgfVxuICB9XG59Il19
|
|
@ -9,7 +9,6 @@ export declare class Tree<T> {
|
|||
pathFromRoot(t: T): T[];
|
||||
contains(tree: Tree<T>): boolean;
|
||||
}
|
||||
export declare function rootNode<T>(tree: Tree<T>): TreeNode<T>;
|
||||
export declare class TreeNode<T> {
|
||||
value: T;
|
||||
children: TreeNode<T>[];
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -12,21 +12,21 @@ function provideRouter(config) {
|
|||
{ provide: url_serializer_1.UrlSerializer, useClass: url_serializer_1.DefaultUrlSerializer },
|
||||
{
|
||||
provide: router_1.Router,
|
||||
useFactory: function (ref, resolver, urlSerializer, outletMap, location) {
|
||||
useFactory: function (ref, resolver, urlSerializer, outletMap, location, injector) {
|
||||
if (ref.componentTypes.length == 0) {
|
||||
throw new Error("Bootstrap at least one component before injecting Router.");
|
||||
}
|
||||
var componentType = ref.componentTypes[0];
|
||||
var r = new router_1.Router(componentType, resolver, urlSerializer, outletMap, location);
|
||||
var r = new router_1.Router(componentType, resolver, urlSerializer, outletMap, location, injector);
|
||||
r.resetConfig(config);
|
||||
ref.registerDisposeListener(function () { return r.dispose(); });
|
||||
return r;
|
||||
},
|
||||
deps: [core_1.ApplicationRef, core_1.ComponentResolver, url_serializer_1.UrlSerializer, router_outlet_map_1.RouterOutletMap, common_1.Location]
|
||||
deps: [core_1.ApplicationRef, core_1.ComponentResolver, url_serializer_1.UrlSerializer, router_outlet_map_1.RouterOutletMap, common_1.Location, core_1.Injector]
|
||||
},
|
||||
router_outlet_map_1.RouterOutletMap,
|
||||
{ provide: router_state_1.ActivatedRoute, useFactory: function (r) { return r.routerState.root; }, deps: [router_1.Router] },
|
||||
];
|
||||
}
|
||||
exports.provideRouter = provideRouter;
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29tbW9uX3JvdXRlcl9wcm92aWRlcnMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvY29tbW9uX3JvdXRlcl9wcm92aWRlcnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLGtDQUFnQyxxQkFBcUIsQ0FBQyxDQUFBO0FBQ3RELCtCQUFvRCxrQkFBa0IsQ0FBQyxDQUFBO0FBQ3ZFLDZCQUErQixnQkFBZ0IsQ0FBQyxDQUFBO0FBQ2hELHVCQUF1QixVQUFVLENBQUMsQ0FBQTtBQUVsQyxxQkFBaUQsZUFBZSxDQUFDLENBQUE7QUFDakUsdUJBQWlFLGlCQUFpQixDQUFDLENBQUE7QUFvQm5GLHVCQUE4QixNQUFvQjtJQUNoRCxNQUFNLENBQUM7UUFDTCxpQkFBUTtRQUNSLEVBQUMsT0FBTyxFQUFFLHlCQUFnQixFQUFFLFFBQVEsRUFBRSw2QkFBb0IsRUFBQztRQUMzRCxFQUFDLE9BQU8sRUFBRSw4QkFBYSxFQUFFLFFBQVEsRUFBRSxxQ0FBb0IsRUFBQztRQUV4RDtZQUNFLE9BQU8sRUFBRSxlQUFNO1lBQ2YsVUFBVSxFQUFFLFVBQUMsR0FBRyxFQUFFLFFBQVEsRUFBRSxhQUFhLEVBQUUsU0FBUyxFQUFFLFFBQ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yfSxcblxuICAgIHtcbiAgICAgIHByb3ZpZGU6IFJvdXRlcixcbiAgICAgIHVzZUZhY3Rvcnk6IChyZWYsIHJlc29sdmVyLCB1cmxTZXJpYWxpemVyLCBvdXRsZXRNYXAsIGxvY2F0aW9uLCBpbmplY3RvcikgPT4ge1xuICAgICAgICBpZiAocmVmLmNvbXBvbmVudFR5cGVzLmxlbmd0aCA9PSAwKSB7XG4gICAgICAgICAgdGhyb3cgbmV3IEVycm9yKFwiQm9vdHN0cmFwIGF0IGxlYXN0IG9uZSBjb21wb25lbnQgYmVmb3JlIGluamVjdGluZyBSb3V0ZXIuXCIpO1xuICAgICAgICB9XG4gICAgICAgIGNvbnN0IGNvbXBvbmVudFR5cGUgPSByZWYuY29tcG9uZW50VHlwZXNbMF07XG4gICAgICAgIGNvbnN0IHIgPSBuZXcgUm91dGVyKGNvbXBvbmVudFR5cGUsIHJlc29sdmVyLCB1cmxTZXJpYWxpemVyLCBvdXRsZXRNYXAsIGxvY2F0aW9uLCBpbmplY3Rvcik7XG4gICAgICAgIHIucmVzZXRDb25maWcoY29uZmlnKTtcbiAgICAgICAgcmVmLnJlZ2lzdGVyRGlzcG9zZUxpc3RlbmVyKCgpID0+IHIuZGlzcG9zZSgpKTtcbiAgICAgICAgcmV0dXJuIHI7XG4gICAgICB9LFxuICAgICAgZGVwczogW0FwcGxpY2F0aW9uUmVmLCBDb21wb25lbnRSZXNvbHZlciwgVXJsU2VyaWFsaXplciwgUm91dGVyT3V0bGV0TWFwLCBMb2NhdGlvbiwgSW5qZWN0b3JdXG4gICAgfSxcblxuICAgIFJvdXRlck91dGxldE1hcCxcbiAgICB7cHJvdmlkZTogQWN0aXZhdGVkUm91dGUsIHVzZUZhY3Rvcnk6IChyKSA9PiByLnJvdXRlclN0YXRlLnJvb3QsIGRlcHM6IFtSb3V0ZXJdfSxcbiAgXTtcbn1cbiJdfQ==
|
|
@ -5,5 +5,7 @@ export interface Route {
|
|||
path?: string;
|
||||
component: Type | string;
|
||||
outlet?: string;
|
||||
canActivate?: any[];
|
||||
canDeactivate?: any[];
|
||||
children?: Route[];
|
||||
}
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
"use strict";
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29uZmlnLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL2NvbmZpZy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgVHlwZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuXG5leHBvcnQgdHlwZSBSb3V0ZXJDb25maWcgPSBSb3V0ZVtdO1xuXG5leHBvcnQgaW50ZXJmYWNlIFJvdXRlIHtcbiAgaW5kZXg/OiBib29sZWFuO1xuICBwYXRoPzogc3RyaW5nO1xuICBjb21wb25lbnQ6IFR5cGUgfCBzdHJpbmc7XG4gIG91dGxldD86IHN0cmluZztcbiAgY2hpbGRyZW4/OiBSb3V0ZVtdO1xufSJdfQ==
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29uZmlnLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL2NvbmZpZy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgVHlwZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuXG5leHBvcnQgdHlwZSBSb3V0ZXJDb25maWcgPSBSb3V0ZVtdO1xuXG5leHBvcnQgaW50ZXJmYWNlIFJvdXRlIHtcbiAgaW5kZXg/OiBib29sZWFuO1xuICBwYXRoPzogc3RyaW5nO1xuICBjb21wb25lbnQ6IFR5cGUgfCBzdHJpbmc7XG4gIG91dGxldD86IHN0cmluZztcbiAgY2FuQWN0aXZhdGU/OiBhbnlbXSxcbiAgY2FuRGVhY3RpdmF0ZT86IGFueVtdLFxuICBjaGlsZHJlbj86IFJvdXRlW107XG59Il19
|
|
@ -0,0 +1,2 @@
|
|||
import { RouterStateSnapshot, RouterState } from './router_state';
|
||||
export declare function createRouterState(curr: RouterStateSnapshot, prevState: RouterState): RouterState;
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -69,4 +69,4 @@ var RouterLink = (function () {
|
|||
return RouterLink;
|
||||
}());
|
||||
exports.RouterLink = RouterLink;
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicm91dGVyX2xpbmsuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvZGlyZWN0aXZlcy9yb3V0ZXJfbGluay50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7O0FBQUEscUJBS08sZUFBZSxDQUFDLENBQUE7QUFDdkIsdUJBQXFCLFdBQVcsQ0FBQyxDQUFBO0FBQ2pDLDZCQUE2QixpQkFBaUIsQ0FBQyxDQUFBO0FBNEIvQztJQU9FLG9CQUFvQixNQUFjLEVBQVUsS0FBcUI7UUFBN0MsV0FBTSxHQUFOLE1BQU0sQ0FBUTtRQUFVLFVBQUssR0FBTCxLQUFLLENBQWdCO1FBTHpELGFBQVEsR0FBVSxFQUFFLENBQUM7SUFLdUMsQ0FBQztJQUdyRSxzQkFBSSxrQ0FBVTthQUFkLFVBQWUsSUFBb0I7WUFDakMsRUFBRSxDQUFDLENBQUMsS0FBSyxDQUFDLE9BQU8sQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDLENBQUM7Z0JBQ3hCLElBQUksQ0FBQyxRQUFRLEdBQUcsSUFBSSxDQUFDO1lBQ3ZCLENBQUM7WUFBQyxJQUFJLENBQUMsQ0FBQztnQkFDTixJQUFJLENBQUMsUUFBUSxHQUFHLENBQUMsSUFBSSxDQUFDLENBQUM7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JldmVudCBkZWZhdWx0IGJyb3dzZXIgYmVoYXZpb3JcbiAgICBpZiAoISh0eXBlb2YgdGhpcy50YXJnZXQgPT09IFwic3RyaW5nXCIpIHx8IHRoaXMudGFyZ2V0ID09ICdfc2VsZicpIHtcbiAgICAgIHRoaXMucm91dGVyLm5hdmlnYXRlKHRoaXMuY29tbWFuZHMsIHtyZWxhdGl2ZVRvOiB0aGlzLnJvdXRlfSk7XG4gICAgICByZXR1cm4gZmFsc2U7XG4gICAgfVxuICAgIHJldHVybiB0cnVlO1xuICB9XG5cbiAgcHJpdmF0ZSB1cGRhdGVUYXJnZXRVcmxBbmRIcmVmKCk6IHZvaWQge1xuICAgIGNvbnN0IHRyZWUgPSB0aGlzLnJvdXRlci5jcmVhdGVVcmxUcmVlKHRoaXMuY29tbWFuZHMsIHtyZWxhdGl2ZVRvOiB0aGlzLnJvdXRlfSk7XG4gICAgaWYgKHRyZWUpIHtcbiAgICAgIHRoaXMuaHJlZiA9IHRoaXMucm91dGVyLnNlcmlhbGl6ZVVybCh0cmVlKTtcbiAgICB9XG4gIH1cbn1cbiJdfQ==
|
|
@ -6,6 +6,7 @@ export declare class RouterOutlet {
|
|||
outletMap: RouterOutletMap;
|
||||
constructor(parentOutletMap: RouterOutletMap, location: ViewContainerRef, name: string);
|
||||
readonly isActivated: boolean;
|
||||
readonly component: Object;
|
||||
deactivate(): void;
|
||||
activate(factory: ComponentFactory<any>, providers: ResolvedReflectiveProvider[], outletMap: RouterOutletMap): void;
|
||||
}
|
||||
|
|
|
@ -24,6 +24,15 @@ var RouterOutlet = (function () {
|
|||
enumerable: true,
|
||||
configurable: true
|
||||
});
|
||||
Object.defineProperty(RouterOutlet.prototype, "component", {
|
||||
get: function () {
|
||||
if (!this.activated)
|
||||
throw new Error("Outlet is not activated");
|
||||
return this.activated.instance;
|
||||
},
|
||||
enumerable: true,
|
||||
configurable: true
|
||||
});
|
||||
RouterOutlet.prototype.deactivate = function () {
|
||||
if (this.activated) {
|
||||
this.activated.destroy();
|
||||
|
@ -43,4 +52,4 @@ var RouterOutlet = (function () {
|
|||
return RouterOutlet;
|
||||
}());
|
||||
exports.RouterOutlet = RouterOutlet;
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicm91dGVyX291dGxldC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9kaXJlY3RpdmVzL3JvdXRlcl9vdXRsZXQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7OztBQUFBLHFCQUFxSSxlQUFlLENBQUMsQ0FBQTtBQUNySixrQ0FBOEIsc0JBQXNCLENBQUMsQ0FBQTtBQUNyRCx1QkFBNkIsV0FBVyxDQUFDLENBQUE7QUFHekM7SUFJRSxzQkFBWSxlQUErQixFQUFVLFFBQXlCLEVBQy9DLElBQVc7UUFEVyxhQUFRLEdBQVIsUUFBUSxDQUFpQjtRQUU1RSxlQUFlLENBQUMsY0FBYyxDQUFDLElBQUksR0FBRyxJQUFJLEdBQUcsdUJBQWMsRUFBRSxJQUFJLENBQUMsQ0FBQztJQUNyRSxDQUFDO0lBRUQsc0JBQUkscUNBQVc7YUFBZixjQUE2QixNQUFNLENBQUMsQ0FBQyxDQUFDLElBQUksQ0FBQyxTQUFTLENBQUMsQ0FBQyxDQUFDOzs7T0FBQTtJQUV2RCxpQ0FBVSxHQUFWO1FBQ0UsRUFBRSxDQUFDLENBQUMsSUFBSSxDQUFDLFNBQVMsQ0FBQyxDQUFDLENBQUM7WUFDbkIsSUFBSSxDQUFDLFNBQVMsQ0FBQyxPQUFPLEVBQUUsQ0FBQztZQUN6QixJQUFJLENBQUMsU0FBUyxHQUFHLElBQUksQ0FBQztRQUN4QixDQUFDO0lBQ0gsQ0FBQztJQUVELCtCQUFRLEdBQVIsVUFBUyxPQUE4QixFQUFFLFNBQXVDLEVBQ3ZFLFNBQTBCO1FBQ2pDLElBQUksQ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pZCB7XG4gICAgdGhpcy5vdXRsZXRNYXAgPSBvdXRsZXRNYXA7XG4gICAgY29uc3QgaW5qID0gUmVmbGVjdGl2ZUluamVjdG9yLmZyb21SZXNvbHZlZFByb3ZpZGVycyhwcm92aWRlcnMsIHRoaXMubG9jYXRpb24ucGFyZW50SW5qZWN0b3IpO1xuICAgIHRoaXMuYWN0aXZhdGVkID0gdGhpcy5sb2NhdGlvbi5jcmVhdGVDb21wb25lbnQoZmFjdG9yeSwgdGhpcy5sb2NhdGlvbi5sZW5ndGgsIGluaiwgW10pO1xuICB9XG59XG4iXX0=
|
|
@ -1,11 +1,12 @@
|
|||
export { Router } from './router';
|
||||
export { UrlSerializer, DefaultUrlSerializer } from './url_serializer';
|
||||
export { RouterState, ActivatedRoute } from './router_state';
|
||||
export { RouterState, ActivatedRoute, RouterStateSnapshot, ActivatedRouteSnapshot } from './router_state';
|
||||
export { UrlTree, UrlSegment } from './url_tree';
|
||||
export { RouterOutletMap } from './router_outlet_map';
|
||||
export { RouterConfig, Route } from './config';
|
||||
export { Params, PRIMARY_OUTLET } from './shared';
|
||||
export { provideRouter } from './router_providers';
|
||||
export { CanActivate, CanDeactivate } from './interfaces';
|
||||
import { RouterOutlet } from './directives/router_outlet';
|
||||
import { RouterLink } from './directives/router_link';
|
||||
export declare const ROUTER_DIRECTIVES: (typeof RouterOutlet | typeof RouterLink)[];
|
||||
|
|
|
@ -7,6 +7,8 @@ exports.DefaultUrlSerializer = url_serializer_1.DefaultUrlSerializer;
|
|||
var router_state_1 = require('./router_state');
|
||||
exports.RouterState = router_state_1.RouterState;
|
||||
exports.ActivatedRoute = router_state_1.ActivatedRoute;
|
||||
exports.RouterStateSnapshot = router_state_1.RouterStateSnapshot;
|
||||
exports.ActivatedRouteSnapshot = router_state_1.ActivatedRouteSnapshot;
|
||||
var url_tree_1 = require('./url_tree');
|
||||
exports.UrlTree = url_tree_1.UrlTree;
|
||||
exports.UrlSegment = url_tree_1.UrlSegment;
|
||||
|
@ -19,4 +21,4 @@ exports.provideRouter = router_providers_1.provideRouter;
|
|||
var router_outlet_1 = require('./directives/router_outlet');
|
||||
var router_link_1 = require('./directives/router_link');
|
||||
exports.ROUTER_DIRECTIVES = [router_outlet_1.RouterOutlet, router_link_1.RouterLink];
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLHVCQUF1QixVQUFVLENBQUM7QUFBekIsaUNBQXlCO0FBQ2xDLCtCQUFvRCxrQkFBa0IsQ0FBQztBQUE5RCx1REFBYTtBQUFFLHFFQUErQztBQUN2RSw2QkFBNEMsZ0JBQWdCLENBQUM7QUFBcEQsaURBQVc7QUFBRSx1REFBdUM7QUFDN0QseUJBQW1DLFlBQVksQ0FBQztBQUF2QyxxQ0FBTztBQUFFLDJDQUE4QjtBQUNoRCxrQ0FBZ0MscUJBQXFCLENBQUM7QUFBN0MsOERBQTZDO0FBRXRELHVCQUF1QyxVQUFVLENBQUM7QUFBakMsaURBQWlDO0FBQ2xELGlDQUE4QixvQkFBb0IsQ0FBQztBQUExQyx5REFBMEM7QUFFbkQsOEJBQTZCLDRCQUE0QixDQUFDLENBQUE7QUFDMUQsNEJBQTJCLDBCQUEwQixDQUFDLENBQUE7QUFFekMseUJBQWlCLEdBQUcsQ0FBQyw0QkFBWSxFQUFFLHdCQUFVLENBQUMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbImV4cG9ydCB7IFJvdXRlciB9IGZyb20gJy4vcm91dGVyJztcbmV4cG9ydCB7IFVybFNlcmlhbGl6ZXIsIERlZmF1bHRVcmxTZXJpYWxpemVyIH0gZnJvbSAnLi91cmxfc2VyaWFsaXplcic7XG5leHBvcnQgeyBSb3V0ZXJTdGF0ZSwgQWN0aXZhdGVkUm91dGUgfSBmcm9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tICcuL2RpcmVjdGl2ZXMvcm91dGVyX291dGxldCc7XG5pbXBvcnQgeyBSb3V0ZXJMaW5rIH0gZnJvbSAnLi9kaXJlY3RpdmVzL3JvdXRlcl9saW5rJztcblxuZXhwb3J0IGNvbnN0IFJPVVRFUl9ESVJFQ1RJVkVTID0gW1JvdXRlck91dGxldCwgUm91dGVyTGlua107Il19
|
|
@ -0,0 +1,8 @@
|
|||
import { Observable } from 'rxjs/Observable';
|
||||
import { ActivatedRouteSnapshot, RouterStateSnapshot } from './router_state';
|
||||
export interface CanActivate {
|
||||
canActivate(route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean> | boolean;
|
||||
}
|
||||
export interface CanDeactivate<T> {
|
||||
canDeactivate(component: T, route: ActivatedRouteSnapshot, state: RouterStateSnapshot): Observable<boolean> | boolean;
|
||||
}
|
|
@ -0,0 +1,2 @@
|
|||
"use strict";
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW50ZXJmYWNlcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9pbnRlcmZhY2VzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIiLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQge09ic2VydmFibGV9IGZyb20gJ3J4anMvT2JzZXJ2YWJsZSc7XG5pbXBvcnQge0FjdGl2YXRlZFJvdXRlU25hcHNob3QsIFJvdXRlclN0YXRlU25hcHNob3R9IGZyb20gJy4vcm91dGVyX3N0YXRlJztcblxuLyoqXG4gKiBBbiBpbnRlcmZhY2UgYSBjbGFzcyBjYW4gaW1wbGVtZW50IHRvIGJlIGEgZ3VhcmQgZGVjaWRpbmcgaWYgYSByb3V0ZSBjYW4gYmUgYWN0aXZhdGVkLlxuICovXG5leHBvcnQgaW50ZXJmYWNlIENhbkFjdGl2YXRlIHtcbiAgY2FuQWN0aXZhdGUocm91dGU6QWN0aXZhdGVkUm91dGVTbmFwc2hvdCwgc3RhdGU6Um91dGVyU3RhdGVTbmFwc2hvdCk6T2JzZXJ2YWJsZTxib29sZWFuPiB8IGJvb2xlYW47XG59XG5cbi8qKlxuICogQW4gaW50ZXJmYWNlIGEgY2xhc3MgY2FuIGltcGxlbWVudCB0byBiZSBhIGd1YXJkIGRlY2lkaW5nIGlmIGEgcm91dGUgY2FuIGJlIGRlYWN0aXZhdGVkLlxuICovXG5leHBvcnQgaW50ZXJmYWNlIENhbkRlYWN0aXZhdGU8VD4ge1xuICBjYW5EZWFjdGl2YXRlKGNvbXBvbmVudDpULCByb3V0ZTpBY3RpdmF0ZWRSb3V0ZVNuYXBzaG90LCBzdGF0ZTpSb3V0ZXJTdGF0ZVNuYXBzaG90KTpPYnNlcnZhYmxlPGJvb2xlYW4+IHwgYm9vbGVhbjtcbn0iXX0=
|
|
@ -1,5 +1,6 @@
|
|||
import { UrlTree } from './url_tree';
|
||||
import { RouterState } from './router_state';
|
||||
import { RouterStateSnapshot } from './router_state';
|
||||
import { RouterConfig } from './config';
|
||||
import { Type } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
export declare function recognize(config: RouterConfig, url: UrlTree, existingState: RouterState): Observable<RouterState>;
|
||||
export declare function recognize(rootComponentType: Type, config: RouterConfig, url: UrlTree): Observable<RouterStateSnapshot>;
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,6 @@
|
|||
import { RouterStateSnapshot } from './router_state';
|
||||
import { ComponentResolver } from '@angular/core';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import 'rxjs/add/operator/map';
|
||||
import 'rxjs/add/operator/toPromise';
|
||||
export declare function resolve(resolver: ComponentResolver, state: RouterStateSnapshot): Observable<RouterStateSnapshot>;
|
|
@ -0,0 +1,25 @@
|
|||
"use strict";
|
||||
require('rxjs/add/operator/map');
|
||||
var forkJoin_1 = require('rxjs/observable/forkJoin');
|
||||
var fromPromise_1 = require('rxjs/observable/fromPromise');
|
||||
require('rxjs/add/operator/toPromise');
|
||||
function resolve(resolver, state) {
|
||||
return resolveNode(resolver, state._root).map(function (_) { return state; });
|
||||
}
|
||||
exports.resolve = resolve;
|
||||
function resolveNode(resolver, node) {
|
||||
if (node.children.length === 0) {
|
||||
return fromPromise_1.fromPromise(resolver.resolveComponent(node.value.component).then(function (factory) {
|
||||
node.value._resolvedComponentFactory = factory;
|
||||
return node.value;
|
||||
}));
|
||||
}
|
||||
else {
|
||||
var c = node.children.map(function (c) { return resolveNode(resolver, c).toPromise(); });
|
||||
return forkJoin_1.forkJoin(c).map(function (_) { return resolver.resolveComponent(node.value.component).then(function (factory) {
|
||||
node.value._resolvedComponentFactory = factory;
|
||||
return node.value;
|
||||
}); });
|
||||
}
|
||||
}
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzb2x2ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9yZXNvbHZlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFJQSxRQUFPLHVCQUF1QixDQUFDLENBQUE7QUFDL0IseUJBQXVCLDBCQUEwQixDQUFDLENBQUE7QUFDbEQsNEJBQTBCLDZCQUE2QixDQUFDLENBQUE7QUFDeEQsUUFBTyw2QkFBNkIsQ0FBQyxDQUFBO0FBRXJDLGlCQUF3QixRQUEyQixFQUFFLEtBQTBCO0lBQzdFLE1BQU0sQ0FBQyxXQUFXLENBQUMsUUFBUSxFQUFFLEtBQUssQ0FBQyxLQUFLLENBQUMsQ0FBQyxHQUFHLENBQUMsVUFBQSxDQUFDLElBQUksT0FBQSxLQUFLLEVBQUwsQ0FBSyxDQUFDLENBQUM7QUFDNUQsQ0FBQztBQUZlLGVBQU8sVUFFdEIsQ0FBQTtBQUVELHFCQUFxQixRQUEyQixFQUFFLElBQXNDO0lBQ3RGLEVBQUUsQ0FBQyxDQUFDLElBQUksQ0FBQyxR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W50RmFjdG9yeSA9IGZhY3Rvcnk7XG4gICAgICByZXR1cm4gbm9kZS52YWx1ZTtcbiAgICB9KSk7XG4gICAgXG4gIH0gZWxzZSB7XG4gICAgY29uc3QgYyA9IG5vZGUuY2hpbGRyZW4ubWFwKGMgPT4gcmVzb2x2ZU5vZGUocmVzb2x2ZXIsIGMpLnRvUHJvbWlzZSgpKTtcbiAgICByZXR1cm4gZm9ya0pvaW4oYykubWFwKF8gPT4gcmVzb2x2ZXIucmVzb2x2ZUNvbXBvbmVudCg8YW55Pm5vZGUudmFsdWUuY29tcG9uZW50KS50aGVuKGZhY3RvcnkgPT4ge1xuICAgICAgbm9kZS52YWx1ZS5fcmVzb2x2ZWRDb21wb25lbnRGYWN0b3J5ID0gZmFjdG9yeTtcbiAgICAgIHJldHVybiBub2RlLnZhbHVlO1xuICAgIH0pKTtcbiAgfVxufSJdfQ==
|
|
@ -1,4 +1,4 @@
|
|||
import { ComponentResolver } from '@angular/core';
|
||||
import { ComponentResolver, Type, Injector } from '@angular/core';
|
||||
import { Location } from '@angular/common';
|
||||
import { UrlSerializer } from './url_serializer';
|
||||
import { RouterOutletMap } from './router_outlet_map';
|
||||
|
@ -8,24 +8,25 @@ import { RouterState, ActivatedRoute } from './router_state';
|
|||
import { RouterConfig } from './config';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import 'rxjs/add/operator/map';
|
||||
import 'rxjs/add/operator/scan';
|
||||
import 'rxjs/add/operator/mergeMap';
|
||||
import 'rxjs/add/operator/toPromise';
|
||||
export interface NavigationExtras {
|
||||
relativeTo?: ActivatedRoute;
|
||||
queryParameters?: Params;
|
||||
fragment?: string;
|
||||
}
|
||||
export declare class Router {
|
||||
private rootComponent;
|
||||
private rootComponentType;
|
||||
private resolver;
|
||||
private urlSerializer;
|
||||
private outletMap;
|
||||
private location;
|
||||
private injector;
|
||||
private currentUrlTree;
|
||||
private currentRouterState;
|
||||
private config;
|
||||
private locationSubscription;
|
||||
constructor(rootComponent: Object, resolver: ComponentResolver, urlSerializer: UrlSerializer, outletMap: RouterOutletMap, location: Location);
|
||||
constructor(rootComponentType: Type, resolver: ComponentResolver, urlSerializer: UrlSerializer, outletMap: RouterOutletMap, location: Location, injector: Injector);
|
||||
readonly routerState: RouterState;
|
||||
readonly urlTree: UrlTree;
|
||||
navigateByUrl(url: string): Observable<void>;
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -1,12 +1,14 @@
|
|||
import { Tree, TreeNode } from './utils/tree';
|
||||
import { UrlSegment } from './url_tree';
|
||||
import { Route } from './config';
|
||||
import { Params } from './shared';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { Type } from '@angular/core';
|
||||
import { Type, ComponentFactory } from '@angular/core';
|
||||
export declare class RouterState extends Tree<ActivatedRoute> {
|
||||
queryParams: Observable<Params>;
|
||||
fragment: Observable<string>;
|
||||
constructor(root: TreeNode<ActivatedRoute>, queryParams: Observable<Params>, fragment: Observable<string>);
|
||||
snapshot: RouterStateSnapshot;
|
||||
constructor(root: TreeNode<ActivatedRoute>, queryParams: Observable<Params>, fragment: Observable<string>, snapshot: RouterStateSnapshot);
|
||||
}
|
||||
export declare function createEmptyState(rootComponent: Type): RouterState;
|
||||
export declare class ActivatedRoute {
|
||||
|
@ -14,5 +16,23 @@ export declare class ActivatedRoute {
|
|||
params: Observable<Params>;
|
||||
outlet: string;
|
||||
component: Type | string;
|
||||
constructor(urlSegments: Observable<UrlSegment[]>, params: Observable<Params>, outlet: string, component: Type | string);
|
||||
_futureSnapshot: ActivatedRouteSnapshot;
|
||||
snapshot: ActivatedRouteSnapshot;
|
||||
constructor(urlSegments: Observable<UrlSegment[]>, params: Observable<Params>, outlet: string, component: Type | string, futureSnapshot: ActivatedRouteSnapshot);
|
||||
}
|
||||
export declare class ActivatedRouteSnapshot {
|
||||
urlSegments: UrlSegment[];
|
||||
params: Params;
|
||||
outlet: string;
|
||||
component: Type | string;
|
||||
_resolvedComponentFactory: ComponentFactory<any>;
|
||||
_routeConfig: Route | null;
|
||||
_lastUrlSegment: UrlSegment;
|
||||
constructor(urlSegments: UrlSegment[], params: Params, outlet: string, component: Type | string, routeConfig: Route | null, lastUrlSegment: UrlSegment);
|
||||
}
|
||||
export declare class RouterStateSnapshot extends Tree<ActivatedRouteSnapshot> {
|
||||
queryParams: Params;
|
||||
fragment: string | null;
|
||||
constructor(root: TreeNode<ActivatedRouteSnapshot>, queryParams: Params, fragment: string | null);
|
||||
}
|
||||
export declare function advanceActivatedRoute(route: ActivatedRoute): void;
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -53,4 +53,4 @@ function equalUrlSegments(a, b) {
|
|||
return true;
|
||||
}
|
||||
exports.equalUrlSegments = equalUrlSegments;
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidXJsX3RyZWUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvdXJsX3RyZWUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUEscUJBQStCLGNBQWMsQ0FBQyxDQUFBO0FBQzlDLDJCQUE2QixvQkFBb0IsQ0FBQyxDQUFBO0FBQ2xELHVCQUErQixVQUFVLENBQUMsQ0FBQTtBQUUxQztJQUNFLE1BQU0sQ0FBQyxJQUFJLE9BQU8sQ0FBQyxJQUFJLGVBQVEsQ0FBYSxJQUFJLFVBQVUsQ0FBQyxFQUFFLEVBQUUsRUFBRSxFQUFFLHVCQUFjLENBQUMsRUFBRSxFQUFFLENBQUMsRUFBRSxFQUFFLEVBQUUsSUFBSSxDQUFDLENBQUM7QUFDckcsQ0FBQztBQUZlLDBCQUFrQixxQkFFakMsQ0FBQTtBQUtEO0lBQTZCLDJCQUFnQjtJQUMzQyxpQkFBWSxJQUEwQixFQUFTLGVBQXdDLEVBQVMsUUFBdUI7UUFDckgsa0JBQU0sSUFBSSxDQUFDLENBQUM7UUFEaUMsb0JBQW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CkpIHtcbiAgICAgICAgcGFyYW1zLnB1c2goYCR7cHJvcH09JHt0aGlzLnBhcmFtZXRlcnNbcHJvcF19YCk7XG4gICAgICB9XG4gICAgfVxuICAgIGNvbnN0IHBhcmFtc1N0cmluZyA9IHBhcmFtcy5sZW5ndGggPiAwID8gYCgke3BhcmFtcy5qb2luKCcsJyl9KWAgOiAnJztcbiAgICBjb25zdCBvdXRsZXQgPSB0aGlzLm91dGxldCA9PT0gUFJJTUFSWV9PVVRMRVQgPyAnJyA6IGAke3RoaXMub3V0bGV0fTpgO1xuICAgIHJldHVybiBgJHtvdXRsZXR9JHt0aGlzLnBhdGh9JHtwYXJhbXNTdHJpbmd9YDtcbiAgfVxufVxuXG5leHBvcnQgZnVuY3Rpb24gZXF1YWxVcmxTZWdtZW50cyhhOiBVcmxTZWdtZW50W10sIGI6IFVybFNlZ21lbnRbXSk6IGJvb2xlYW4ge1xuICBpZiAoYS5sZW5ndGggIT09IGIubGVuZ3RoKSByZXR1cm4gZmFsc2U7XG4gIGZvciAobGV0IGkgPSAwOyBpIDwgYS5sZW5ndGg7ICsraSkge1xuICAgIGlmIChhW2ldLnBhdGggIT09IGJbaV0ucGF0aCkgcmV0dXJuIGZhbHNlO1xuICAgIGlmICghc2hhbGxvd0VxdWFsKGFbaV0ucGFyYW1ldGVycywgYltpXS5wYXJhbWV0ZXJzKSkgcmV0dXJuIGZhbHNlO1xuICB9XG4gIHJldHVybiB0cnVlO1xufVxuIl19
|
|
@ -5,6 +5,7 @@ export declare function shallowEqual(a: {
|
|||
}): boolean;
|
||||
export declare function flatten<T>(a: T[][]): T[];
|
||||
export declare function first<T>(a: T[]): T | null;
|
||||
export declare function and(bools: boolean[]): boolean;
|
||||
export declare function merge<V>(m1: {
|
||||
[key: string]: V;
|
||||
}, m2: {
|
||||
|
|
|
@ -29,6 +29,10 @@ function first(a) {
|
|||
return a.length > 0 ? a[0] : null;
|
||||
}
|
||||
exports.first = first;
|
||||
function and(bools) {
|
||||
return bools.reduce(function (a, b) { return a && b; }, true);
|
||||
}
|
||||
exports.and = and;
|
||||
function merge(m1, m2) {
|
||||
var m = {};
|
||||
for (var attr in m1) {
|
||||
|
@ -52,4 +56,4 @@ function forEach(map, callback) {
|
|||
}
|
||||
}
|
||||
exports.forEach = forEach;
|
||||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29sbGVjdGlvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy91dGlscy9jb2xsZWN0aW9uLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFBQSxzQkFBNkIsQ0FBbUIsRUFBRSxDQUFtQjtJQUNuRSxJQUFJLEVBQUUsR0FBRyxNQUFNLENBQUMsSUFBSSxDQUFDLENBQUMsQ0FBQyxDQUFDO0lBQ3hCLElBQUksRUFBRSxHQUFHLE1BQU0sQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDLENBQUM7SUFDeEIsRUFBRSxDQUFDLENBQUMsRUFBRSxDQUFDLE1BQU0sSUFBSSxFQUFFLENBQUMsTUFBTSxDQUFDLENBQUMsQ0FBQztRQUMzQixNQUFNLENBQUMsS0FBSyxDQUFDO0lBQ2YsQ0FBQztJQUNELElBQUksR0FBRyxDQUFDO0lBQ1IsR0FBRyxDQUFDLENBQUMsSUFBSSxDQUFDLEdBQUcsQ0FBQyxFQUFFLENBQUMsR0FBRyxFQUFFLENBQUMsTUFBTSxFQUFFLENBQUMsRUFBRSxFQUFFLENBQUM7UUFDbkMsR0FBRyxHQUFHLEVBQUUsQ0FBQyxDQUFDLENBQUMsQ0FBQztRQUNaLEVBQUUsQ0FBQyxDQUFDLENBQUMsQ0FBQyxHQUFHLENBQUMsS0FBSyxDQUFDLENBQUMsR0FBRyxDQUFDLENBQUMsQ0FBQyxDQUFDO1lBQ3RCLE1BQU0sQ0FBQyxLQUFLLENBQUM7UUFDZixDQUFDO0lBQ0gsQ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gPT4gYSAmJiBiLCB0cnVlKTtcbn1cblxuZXhwb3J0IGZ1bmN0aW9uIG1lcmdlPFY+KG0xOiB7W2tleTogc3RyaW5nXTogVn0sIG0yOiB7W2tleTogc3RyaW5nXTogVn0pOiB7W2tleTogc3RyaW5nXTogVn0ge1xuICB2YXIgbToge1trZXk6IHN0cmluZ106IFZ9ID0ge307XG5cbiAgZm9yICh2YXIgYXR0ciBpbiBtMSkge1xuICAgIGlmIChtMS5oYXNPd25Qcm9wZXJ0eShhdHRyKSkge1xuICAgICAgbVthdHRyXSA9IG0xW2F0dHJdO1xuICAgIH1cbiAgfVxuXG4gIGZvciAodmFyIGF0dHIgaW4gbTIpIHtcbiAgICBpZiAobTIuaGFzT3duUHJvcGVydHkoYXR0cikpIHtcbiAgICAgIG1bYXR0cl0gPSBtMlthdHRyXTtcbiAgICB9XG4gIH1cblxuICByZXR1cm4gbTtcbn1cblxuZXhwb3J0IGZ1bmN0aW9uIGZvckVhY2g8SywgVj4obWFwOiB7W2tleTogc3RyaW5nXTogVn0sIGNhbGxiYWNrOiAvKihWLCBLKSA9PiB2b2lkKi8gRnVuY3Rpb24pOiB2b2lkIHtcbiAgZm9yICh2YXIgcHJvcCBpbiBtYXApIHtcbiAgICBpZiAobWFwLmhhc093blByb3BlcnR5KHByb3ApKSB7XG4gICAgICBjYWxsYmFjayhtYXBbcHJvcF0sIHByb3ApO1xuICAgIH1cbiAgfVxufSJdfQ==
|
|
@ -9,7 +9,6 @@ export declare class Tree<T> {
|
|||
pathFromRoot(t: T): T[];
|
||||
contains(tree: Tree<T>): boolean;
|
||||
}
|
||||
export declare function rootNode<T>(tree: Tree<T>): TreeNode<T>;
|
||||
export declare class TreeNode<T> {
|
||||
value: T;
|
||||
children: TreeNode<T>[];
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue