@angular/router 2.0.0-rc.1 → 2.0.0-rc.2

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.
Files changed (160) hide show
  1. package/{router.umd.js → bundles/router.umd.js} +727 -637
  2. package/bundles/router.umd.min.js +2 -0
  3. package/esm/index.d.ts +7 -25
  4. package/esm/index.js +10 -30
  5. package/esm/index.js.map +1 -1
  6. package/esm/src/constants.js +4 -4
  7. package/esm/src/constants.js.map +1 -1
  8. package/esm/src/constants.metadata.json +1 -1
  9. package/esm/src/core_private.d.ts +3 -2
  10. package/esm/src/core_private.js +3 -2
  11. package/esm/src/core_private.js.map +1 -1
  12. package/esm/src/core_private.metadata.json +1 -1
  13. package/esm/src/directives/router_directives.d.ts +21 -0
  14. package/esm/src/directives/router_directives.js +24 -0
  15. package/esm/src/directives/router_directives.js.map +1 -0
  16. package/esm/src/directives/router_directives.metadata.json +1 -0
  17. package/esm/src/directives/router_link.d.ts +4 -2
  18. package/esm/src/directives/router_link.js +21 -13
  19. package/esm/src/directives/router_link.js.map +1 -1
  20. package/esm/src/directives/router_link.metadata.json +1 -1
  21. package/esm/src/directives/router_outlet.d.ts +6 -6
  22. package/esm/src/directives/router_outlet.js +13 -11
  23. package/esm/src/directives/router_outlet.js.map +1 -1
  24. package/esm/src/directives/router_outlet.metadata.json +1 -1
  25. package/esm/src/facade/async.d.ts +11 -4
  26. package/esm/src/facade/async.js +25 -15
  27. package/esm/src/facade/async.js.map +1 -1
  28. package/esm/src/facade/base_wrapped_exception.js +4 -4
  29. package/esm/src/facade/base_wrapped_exception.js.map +1 -1
  30. package/esm/src/facade/collection.js +1 -1
  31. package/esm/src/facade/collection.js.map +1 -1
  32. package/esm/src/facade/collection.metadata.json +1 -1
  33. package/esm/src/facade/exception_handler.d.ts +2 -11
  34. package/esm/src/facade/exception_handler.js +8 -7
  35. package/esm/src/facade/exception_handler.js.map +1 -1
  36. package/esm/src/facade/exceptions.d.ts +4 -0
  37. package/esm/src/facade/exceptions.js +6 -2
  38. package/esm/src/facade/exceptions.js.map +1 -1
  39. package/esm/src/facade/exceptions.metadata.json +1 -0
  40. package/esm/src/facade/lang.d.ts +6 -4
  41. package/esm/src/facade/lang.js +12 -11
  42. package/esm/src/facade/lang.js.map +1 -1
  43. package/esm/src/facade/lang.metadata.json +1 -1
  44. package/esm/src/facade/promise.js.map +1 -1
  45. package/esm/src/interfaces.js.map +1 -1
  46. package/esm/src/lifecycle_reflector.js.map +1 -1
  47. package/esm/src/link.d.ts +1 -1
  48. package/esm/src/link.js +31 -18
  49. package/esm/src/link.js.map +1 -1
  50. package/esm/src/metadata/decorators.d.ts +1 -1
  51. package/esm/src/metadata/decorators.js +1 -1
  52. package/esm/src/metadata/decorators.js.map +1 -1
  53. package/esm/src/metadata/decorators.metadata.json +1 -1
  54. package/esm/src/metadata/metadata.d.ts +3 -3
  55. package/esm/src/metadata/metadata.js +1 -1
  56. package/esm/src/metadata/metadata.js.map +1 -1
  57. package/esm/src/recognize.d.ts +3 -3
  58. package/esm/src/recognize.js +57 -41
  59. package/esm/src/recognize.js.map +1 -1
  60. package/esm/src/router.d.ts +3 -23
  61. package/esm/src/router.js +54 -58
  62. package/esm/src/router.js.map +1 -1
  63. package/esm/src/router_providers.d.ts +1 -1
  64. package/esm/src/router_providers.js +3 -7
  65. package/esm/src/router_providers.js.map +1 -1
  66. package/esm/src/router_providers.metadata.json +1 -1
  67. package/esm/src/router_providers_common.d.ts +7 -0
  68. package/esm/src/router_providers_common.js +10 -7
  69. package/esm/src/router_providers_common.js.map +1 -1
  70. package/esm/src/router_providers_common.metadata.json +1 -1
  71. package/esm/src/router_url_serializer.js +9 -9
  72. package/esm/src/router_url_serializer.js.map +1 -1
  73. package/esm/src/segments.d.ts +7 -12
  74. package/esm/src/segments.js +27 -45
  75. package/esm/src/segments.js.map +1 -1
  76. package/esm/src/segments.metadata.json +1 -0
  77. package/esm/testing/router_testing_providers.js +10 -3
  78. package/esm/testing/router_testing_providers.js.map +1 -1
  79. package/esm/testing/router_testing_providers.metadata.json +1 -1
  80. package/esm/testing.js.map +1 -1
  81. package/index.d.ts +7 -25
  82. package/index.js +22 -39
  83. package/index.js.map +1 -1
  84. package/package.json +8 -4
  85. package/src/constants.js +4 -4
  86. package/src/constants.js.map +1 -1
  87. package/src/constants.metadata.json +1 -1
  88. package/src/core_private.d.ts +3 -2
  89. package/src/core_private.js +1 -0
  90. package/src/core_private.js.map +1 -1
  91. package/src/core_private.metadata.json +1 -1
  92. package/src/directives/router_directives.d.ts +21 -0
  93. package/src/directives/router_directives.js +25 -0
  94. package/src/directives/router_directives.js.map +1 -0
  95. package/src/directives/router_directives.metadata.json +1 -0
  96. package/src/directives/router_link.d.ts +4 -2
  97. package/src/directives/router_link.js +20 -12
  98. package/src/directives/router_link.js.map +1 -1
  99. package/src/directives/router_link.metadata.json +1 -1
  100. package/src/directives/router_outlet.d.ts +6 -6
  101. package/src/directives/router_outlet.js +13 -11
  102. package/src/directives/router_outlet.js.map +1 -1
  103. package/src/directives/router_outlet.metadata.json +1 -1
  104. package/src/facade/async.d.ts +11 -4
  105. package/src/facade/async.js +27 -17
  106. package/src/facade/async.js.map +1 -1
  107. package/src/facade/base_wrapped_exception.js +4 -4
  108. package/src/facade/base_wrapped_exception.js.map +1 -1
  109. package/src/facade/collection.js.map +1 -1
  110. package/src/facade/collection.metadata.json +1 -1
  111. package/src/facade/exception_handler.d.ts +2 -11
  112. package/src/facade/exception_handler.js +8 -7
  113. package/src/facade/exception_handler.js.map +1 -1
  114. package/src/facade/exceptions.d.ts +4 -0
  115. package/src/facade/exceptions.js +6 -2
  116. package/src/facade/exceptions.js.map +1 -1
  117. package/src/facade/exceptions.metadata.json +1 -0
  118. package/src/facade/lang.d.ts +6 -4
  119. package/src/facade/lang.js +12 -11
  120. package/src/facade/lang.js.map +1 -1
  121. package/src/facade/lang.metadata.json +1 -1
  122. package/src/facade/promise.js.map +1 -1
  123. package/src/interfaces.js.map +1 -1
  124. package/src/lifecycle_reflector.js.map +1 -1
  125. package/src/link.d.ts +1 -1
  126. package/src/link.js +33 -18
  127. package/src/link.js.map +1 -1
  128. package/src/metadata/decorators.d.ts +1 -1
  129. package/src/metadata/decorators.js +1 -1
  130. package/src/metadata/decorators.js.map +1 -1
  131. package/src/metadata/decorators.metadata.json +1 -1
  132. package/src/metadata/metadata.d.ts +3 -3
  133. package/src/metadata/metadata.js +1 -1
  134. package/src/metadata/metadata.js.map +1 -1
  135. package/src/recognize.d.ts +3 -3
  136. package/src/recognize.js +62 -42
  137. package/src/recognize.js.map +1 -1
  138. package/src/router.d.ts +3 -23
  139. package/src/router.js +64 -64
  140. package/src/router.js.map +1 -1
  141. package/src/router_providers.d.ts +1 -1
  142. package/src/router_providers.js +3 -7
  143. package/src/router_providers.js.map +1 -1
  144. package/src/router_providers.metadata.json +1 -1
  145. package/src/router_providers_common.d.ts +7 -0
  146. package/src/router_providers_common.js +10 -5
  147. package/src/router_providers_common.js.map +1 -1
  148. package/src/router_providers_common.metadata.json +1 -1
  149. package/src/router_url_serializer.js +8 -8
  150. package/src/router_url_serializer.js.map +1 -1
  151. package/src/segments.d.ts +7 -12
  152. package/src/segments.js +26 -44
  153. package/src/segments.js.map +1 -1
  154. package/src/segments.metadata.json +1 -0
  155. package/testing/router_testing_providers.js +9 -2
  156. package/testing/router_testing_providers.js.map +1 -1
  157. package/testing/router_testing_providers.metadata.json +1 -1
  158. package/testing.js.map +1 -1
  159. package/esm/index.metadata.json +0 -1
  160. package/index.metadata.json +0 -1
package/index.js CHANGED
@@ -1,48 +1,31 @@
1
- "use strict";
2
1
  /**
3
- * @module
4
- * @description
5
- * Maps application URLs into application states, to support deep-linking and navigation.
6
- */
2
+ * @module
3
+ * @description
4
+ * Maps application URLs into application states, to support deep-linking and navigation.
5
+ */
6
+ "use strict";
7
+ var router_directives_1 = require('./src/directives/router_directives');
8
+ exports.ROUTER_DIRECTIVES = router_directives_1.ROUTER_DIRECTIVES;
9
+ var router_link_1 = require('./src/directives/router_link');
10
+ exports.RouterLink = router_link_1.RouterLink;
11
+ var router_outlet_1 = require('./src/directives/router_outlet');
12
+ exports.RouterOutlet = router_outlet_1.RouterOutlet;
13
+ var decorators_1 = require('./src/metadata/decorators');
14
+ exports.Routes = decorators_1.Routes;
15
+ var metadata_1 = require('./src/metadata/metadata');
16
+ exports.Route = metadata_1.Route;
7
17
  var router_1 = require('./src/router');
8
18
  exports.Router = router_1.Router;
9
19
  exports.RouterOutletMap = router_1.RouterOutletMap;
20
+ var router_providers_1 = require('./src/router_providers');
21
+ exports.ROUTER_PROVIDERS = router_providers_1.ROUTER_PROVIDERS;
22
+ var router_url_serializer_1 = require('./src/router_url_serializer');
23
+ exports.DefaultRouterUrlSerializer = router_url_serializer_1.DefaultRouterUrlSerializer;
24
+ exports.RouterUrlSerializer = router_url_serializer_1.RouterUrlSerializer;
10
25
  var segments_1 = require('./src/segments');
11
26
  exports.RouteSegment = segments_1.RouteSegment;
12
- exports.UrlSegment = segments_1.UrlSegment;
27
+ exports.RouteTree = segments_1.RouteTree;
13
28
  exports.Tree = segments_1.Tree;
29
+ exports.UrlSegment = segments_1.UrlSegment;
14
30
  exports.UrlTree = segments_1.UrlTree;
15
- exports.RouteTree = segments_1.RouteTree;
16
- var decorators_1 = require('./src/metadata/decorators');
17
- exports.Routes = decorators_1.Routes;
18
- var metadata_1 = require('./src/metadata/metadata');
19
- exports.Route = metadata_1.Route;
20
- var router_url_serializer_1 = require('./src/router_url_serializer');
21
- exports.RouterUrlSerializer = router_url_serializer_1.RouterUrlSerializer;
22
- exports.DefaultRouterUrlSerializer = router_url_serializer_1.DefaultRouterUrlSerializer;
23
- var router_providers_1 = require('./src/router_providers');
24
- exports.ROUTER_PROVIDERS = router_providers_1.ROUTER_PROVIDERS;
25
- var router_outlet_1 = require('./src/directives/router_outlet');
26
- var router_link_1 = require('./src/directives/router_link');
27
- /**
28
- * A list of directives. To use the router directives like {@link RouterOutlet} and
29
- * {@link RouterLink}, add this to your `directives` array in the {@link View} decorator of your
30
- * component.
31
- *
32
- * ```
33
- * import {Component} from '@angular/core';
34
- * import {ROUTER_DIRECTIVES, Routes} from '@angular/router-deprecated';
35
- *
36
- * @Component({directives: [ROUTER_DIRECTIVES]})
37
- * @RouteConfig([
38
- * {...},
39
- * ])
40
- * class AppCmp {
41
- * // ...
42
- * }
43
- *
44
- * bootstrap(AppCmp);
45
- * ```
46
- */
47
- exports.ROUTER_DIRECTIVES = [router_outlet_1.RouterOutlet, router_link_1.RouterLink];
48
31
  //# sourceMappingURL=index.js.map
package/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../modules/@angular/router/index.ts"],"names":[],"mappings":";AAIE;;;;EAIC;AAEH,uBAAsC,cAAc,CAAC;AAA7C,iCAAM;AAAE,mDAAqC;AACrD,yBAAiE,gBAAgB,CAAC;AAA1E,+CAAY;AAAE,2CAAU;AAAE,+BAAI;AAAE,qCAAO;AAAE,yCAAiC;AAClF,2BAAqB,2BAA2B,CAAC;AAAzC,qCAAyC;AACjD,yBAAoB,yBAAyB,CAAC;AAAtC,iCAAsC;AAC9C,sCAA8D,6BAA6B,CAAC;AAApF,0EAAmB;AAAE,wFAA+D;AAE5F,iCAA+B,wBAAwB,CAAC;AAAhD,+DAAgD;AAExD,8BAA2B,gCAAgC,CAAC,CAAA;AAC5D,4BAAyB,8BAA8B,CAAC,CAAA;AAExD;;;;;;;;;;;;;;;;;;;GAmBG;AACU,yBAAiB,GAA4B,CAAC,4BAAY,EAAE,wBAAU,CAAC,CAAC","sourcesContent":["interface DecoratorInvocation {\n type: Function;\n args?: any[];\n }\n /**\n * @module\n * @description\n * Maps application URLs into application states, to support deep-linking and navigation.\n */\n\nexport {Router, RouterOutletMap} from './src/router';\nexport {RouteSegment, UrlSegment, Tree, UrlTree, RouteTree} from './src/segments';\nexport {Routes} from './src/metadata/decorators';\nexport {Route} from './src/metadata/metadata';\nexport {RouterUrlSerializer, DefaultRouterUrlSerializer} from './src/router_url_serializer';\nexport {OnActivate, CanDeactivate} from './src/interfaces';\nexport {ROUTER_PROVIDERS} from './src/router_providers';\n\nimport {RouterOutlet} from './src/directives/router_outlet';\nimport {RouterLink} from './src/directives/router_link';\n\n/**\n * A list of directives. To use the router directives like {@link RouterOutlet} and\n * {@link RouterLink}, add this to your `directives` array in the {@link View} decorator of your\n * component.\n *\n * ```\n * import {Component} from '@angular/core';\n * import {ROUTER_DIRECTIVES, Routes} from '@angular/router-deprecated';\n *\n * @Component({directives: [ROUTER_DIRECTIVES]})\n * @RouteConfig([\n * {...},\n * ])\n * class AppCmp {\n * // ...\n * }\n *\n * bootstrap(AppCmp);\n * ```\n */\nexport const ROUTER_DIRECTIVES: any[] = /*@ts2dart_const*/[RouterOutlet, RouterLink];\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../modules/@angular/router/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;;AAEH,kCAAgC,oCAAoC,CAAC;AAA7D,kEAA6D;AACrE,4BAAyB,8BAA8B,CAAC;AAAhD,8CAAgD;AACxD,8BAA2B,gCAAgC,CAAC;AAApD,oDAAoD;AAE5D,2BAAqB,2BAA2B,CAAC;AAAzC,qCAAyC;AACjD,yBAAoB,yBAAyB,CAAC;AAAtC,iCAAsC;AAC9C,uBAAsC,cAAc,CAAC;AAA7C,iCAAM;AAAE,mDAAqC;AACrD,iCAA+B,wBAAwB,CAAC;AAAhD,+DAAgD;AACxD,sCAA8D,6BAA6B,CAAC;AAApF,wFAA0B;AAAE,0EAAwD;AAC5F,yBAAiE,gBAAgB,CAAC;AAA1E,+CAAY;AAAE,yCAAS;AAAE,+BAAI;AAAE,2CAAU;AAAE,qCAA+B","sourcesContent":["/**\n * @module\n * @description\n * Maps application URLs into application states, to support deep-linking and navigation.\n */\n\nexport {ROUTER_DIRECTIVES} from './src/directives/router_directives';\nexport {RouterLink} from './src/directives/router_link';\nexport {RouterOutlet} from './src/directives/router_outlet';\nexport {CanDeactivate, OnActivate} from './src/interfaces';\nexport {Routes} from './src/metadata/decorators';\nexport {Route} from './src/metadata/metadata';\nexport {Router, RouterOutletMap} from './src/router';\nexport {ROUTER_PROVIDERS} from './src/router_providers';\nexport {DefaultRouterUrlSerializer, RouterUrlSerializer} from './src/router_url_serializer';\nexport {RouteSegment, RouteTree, Tree, UrlSegment, UrlTree} from './src/segments';\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular/router",
3
- "version": "2.0.0-rc.1",
3
+ "version": "2.0.0-rc.2",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "jsnext:main": "esm/index.js",
@@ -8,8 +8,12 @@
8
8
  "author": "angular",
9
9
  "license": "MIT",
10
10
  "peerDependencies": {
11
- "@angular/core": "2.0.0-rc.1",
12
- "@angular/common": "2.0.0-rc.1",
13
- "@angular/platform-browser": "2.0.0-rc.1"
11
+ "@angular/core": "^2.0.0-rc",
12
+ "@angular/common": "^2.0.0-rc",
13
+ "@angular/platform-browser": "^2.0.0-rc"
14
+ },
15
+ "repository": {
16
+ "type": "git",
17
+ "url": "https://github.com/angular/angular.git"
14
18
  }
15
19
  }
package/src/constants.js CHANGED
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  /**
3
- * Name of the default outlet outlet.
4
- * @type {string}
5
- */
6
- exports.DEFAULT_OUTLET_NAME = "__DEFAULT";
3
+ * Name of the default outlet outlet.
4
+ * @type {string}
5
+ */
6
+ exports.DEFAULT_OUTLET_NAME = '__DEFAULT';
7
7
  //# sourceMappingURL=constants.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../modules/@angular/router/src/constants.ts"],"names":[],"mappings":";AAIE;;;EAGC;AACU,2BAAmB,GAAG,WAAW,CAAC","sourcesContent":["interface DecoratorInvocation {\n type: Function;\n args?: any[];\n }\n /**\n * Name of the default outlet outlet.\n * @type {string}\n */\nexport const DEFAULT_OUTLET_NAME = \"__DEFAULT\";"]}
1
+ {"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../../modules/@angular/router/src/constants.ts"],"names":[],"mappings":";AAAA;;;GAGG;AACU,2BAAmB,GAAG,WAAW,CAAC","sourcesContent":["/**\n * Name of the default outlet outlet.\n * @type {string}\n */\nexport const DEFAULT_OUTLET_NAME = '__DEFAULT';\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
@@ -1 +1 @@
1
- {"__symbolic":"module","metadata":{"DEFAULT_OUTLET_NAME":"__DEFAULT"}}
1
+ {"__symbolic":"module","version":1,"metadata":{"DEFAULT_OUTLET_NAME":"__DEFAULT"}}
@@ -1,2 +1,3 @@
1
- import { __core_private__ } from '@angular/core';
2
- export declare var makeDecorator: typeof __core_private__.makeDecorator;
1
+ import { __core_private__ as _ } from '@angular/core';
2
+ export declare var makeDecorator: typeof _.makeDecorator;
3
+ export declare var reflector: typeof _.reflector;
@@ -1,4 +1,5 @@
1
1
  "use strict";
2
2
  var core_1 = require('@angular/core');
3
3
  exports.makeDecorator = core_1.__core_private__.makeDecorator;
4
+ exports.reflector = core_1.__core_private__.reflector;
4
5
  //# sourceMappingURL=core_private.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"core_private.js","sourceRoot":"","sources":["../../../../modules/@angular/router/src/core_private.ts"],"names":[],"mappings":";AAIE,qBAA+B,eAAe,CAAC,CAAA;AAEtC,qBAAa,GAA0C,uBAAgB,CAAC,aAAa,CAAC","sourcesContent":["interface DecoratorInvocation {\n type: Function;\n args?: any[];\n }\n import {__core_private__} from '@angular/core';\n\nexport var makeDecorator: typeof __core_private__.makeDecorator = __core_private__.makeDecorator;\n"]}
1
+ {"version":3,"file":"core_private.js","sourceRoot":"","sources":["../../../../modules/@angular/router/src/core_private.ts"],"names":[],"mappings":";AAAA,qBAAoC,eAAe,CAAC,CAAA;AAEzC,qBAAa,GAA2B,uBAAC,CAAC,aAAa,CAAC;AACxD,iBAAS,GAAuB,uBAAC,CAAC,SAAS,CAAC","sourcesContent":["import {__core_private__ as _} from '@angular/core';\n\nexport var makeDecorator: typeof _.makeDecorator = _.makeDecorator;\nexport var reflector: typeof _.reflector = _.reflector;\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
@@ -1 +1 @@
1
- {"__symbolic":"module","metadata":{"makeDecorator":{"__symbolic":"select","expression":{"__symbolic":"reference","name":"___core_private__","module":"@angular/core"},"member":"makeDecorator"}}}
1
+ {"__symbolic":"module","version":1,"metadata":{"makeDecorator":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"___core_private__"},"member":"makeDecorator"},"reflector":{"__symbolic":"select","expression":{"__symbolic":"reference","module":"@angular/core","name":"___core_private__"},"member":"reflector"}}}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * A list of directives. To use the router directives like {@link RouterOutlet} and
3
+ * {@link RouterLink}, add this to your `directives` array in the {@link View} decorator of your
4
+ * component.
5
+ *
6
+ * ```
7
+ * import {Component} from '@angular/core';
8
+ * import {ROUTER_DIRECTIVES, Routes} from '@angular/router';
9
+ *
10
+ * @Component({directives: [ROUTER_DIRECTIVES]})
11
+ * @Routes([
12
+ * {...},
13
+ * ])
14
+ * class AppCmp {
15
+ * // ...
16
+ * }
17
+ *
18
+ * bootstrap(AppCmp);
19
+ * ```
20
+ */
21
+ export declare const ROUTER_DIRECTIVES: any[];
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ var router_link_1 = require('./router_link');
3
+ var router_outlet_1 = require('./router_outlet');
4
+ /**
5
+ * A list of directives. To use the router directives like {@link RouterOutlet} and
6
+ * {@link RouterLink}, add this to your `directives` array in the {@link View} decorator of your
7
+ * component.
8
+ *
9
+ * ```
10
+ * import {Component} from '@angular/core';
11
+ * import {ROUTER_DIRECTIVES, Routes} from '@angular/router';
12
+ *
13
+ * @Component({directives: [ROUTER_DIRECTIVES]})
14
+ * @Routes([
15
+ * {...},
16
+ * ])
17
+ * class AppCmp {
18
+ * // ...
19
+ * }
20
+ *
21
+ * bootstrap(AppCmp);
22
+ * ```
23
+ */
24
+ exports.ROUTER_DIRECTIVES = [router_outlet_1.RouterOutlet, router_link_1.RouterLink];
25
+ //# sourceMappingURL=router_directives.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"router_directives.js","sourceRoot":"","sources":["../../../../../modules/@angular/router/src/directives/router_directives.ts"],"names":[],"mappings":";AAAA,4BAAyB,eAAe,CAAC,CAAA;AACzC,8BAA2B,iBAAiB,CAAC,CAAA;AAE7C;;;;;;;;;;;;;;;;;;;GAmBG;AAEU,yBAAiB,GAA4B,CAAC,4BAAY,EAAE,wBAAU,CAAC,CAAC","sourcesContent":["import {RouterLink} from './router_link';\nimport {RouterOutlet} from './router_outlet';\n\n/**\n * A list of directives. To use the router directives like {@link RouterOutlet} and\n * {@link RouterLink}, add this to your `directives` array in the {@link View} decorator of your\n * component.\n *\n * ```\n * import {Component} from '@angular/core';\n * import {ROUTER_DIRECTIVES, Routes} from '@angular/router';\n *\n * @Component({directives: [ROUTER_DIRECTIVES]})\n * @Routes([\n * {...},\n * ])\n * class AppCmp {\n * // ...\n * }\n *\n * bootstrap(AppCmp);\n * ```\n */\n\nexport const ROUTER_DIRECTIVES: any[] = /*@ts2dart_const*/[RouterOutlet, RouterLink];\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
@@ -0,0 +1 @@
1
+ {"__symbolic":"module","version":1,"metadata":{"ROUTER_DIRECTIVES":[{"__symbolic":"reference","module":"./router_outlet","name":"RouterOutlet"},{"__symbolic":"reference","module":"./router_link","name":"RouterLink"}]}}
@@ -1,3 +1,4 @@
1
+ import { LocationStrategy } from '@angular/common';
1
2
  import { OnDestroy } from '@angular/core';
2
3
  import { Router } from '../router';
3
4
  import { RouteSegment } from '../segments';
@@ -34,14 +35,15 @@ import { RouteSegment } from '../segments';
34
35
  export declare class RouterLink implements OnDestroy {
35
36
  private _routeSegment;
36
37
  private _router;
38
+ private _locationStrategy;
37
39
  target: string;
38
40
  private _commands;
39
41
  private _subscription;
40
42
  href: string;
41
43
  isActive: boolean;
42
- constructor(_routeSegment: RouteSegment, _router: Router);
44
+ constructor(_routeSegment: RouteSegment, _router: Router, _locationStrategy: LocationStrategy);
43
45
  ngOnDestroy(): void;
44
46
  routerLink: any[] | any;
45
- onClick(): boolean;
47
+ onClick(button: number, ctrlKey: boolean, metaKey: boolean): boolean;
46
48
  private _updateTargetUrlAndHref();
47
49
  }
@@ -1,14 +1,16 @@
1
1
  "use strict";
2
+ var common_1 = require('@angular/common');
2
3
  var core_1 = require('@angular/core');
4
+ var async_1 = require('../facade/async');
5
+ var lang_1 = require('../facade/lang');
3
6
  var router_1 = require('../router');
4
7
  var segments_1 = require('../segments');
5
- var lang_1 = require('../facade/lang');
6
- var async_1 = require('../facade/async');
7
8
  var RouterLink = (function () {
8
- function RouterLink(_routeSegment, _router) {
9
+ function RouterLink(_routeSegment, _router, _locationStrategy) {
9
10
  var _this = this;
10
11
  this._routeSegment = _routeSegment;
11
12
  this._router = _router;
13
+ this._locationStrategy = _locationStrategy;
12
14
  this._commands = [];
13
15
  this.isActive = false;
14
16
  // because auxiliary links take existing primary and auxiliary routes into account,
@@ -30,37 +32,43 @@ var RouterLink = (function () {
30
32
  enumerable: true,
31
33
  configurable: true
32
34
  });
33
- RouterLink.prototype.onClick = function () {
34
- // If no target, or if target is _self, prevent default browser behavior
35
- if (!lang_1.isString(this.target) || this.target == '_self') {
36
- this._router.navigate(this._commands, this._routeSegment);
37
- return false;
35
+ RouterLink.prototype.onClick = function (button, ctrlKey, metaKey) {
36
+ if (button != 0 || ctrlKey || metaKey) {
37
+ return true;
38
+ }
39
+ if (lang_1.isString(this.target) && this.target != '_self') {
40
+ return true;
38
41
  }
39
- return true;
42
+ this._router.navigate(this._commands, this._routeSegment);
43
+ return false;
40
44
  };
41
45
  RouterLink.prototype._updateTargetUrlAndHref = function () {
42
46
  var tree = this._router.createUrlTree(this._commands, this._routeSegment);
43
47
  if (lang_1.isPresent(tree)) {
44
- this.href = this._router.serializeUrl(tree);
48
+ this.href = this._locationStrategy.prepareExternalUrl(this._router.serializeUrl(tree));
45
49
  this.isActive = this._router.urlTree.contains(tree);
46
50
  }
47
51
  else {
48
52
  this.isActive = false;
49
53
  }
50
54
  };
55
+ /** @nocollapse */
51
56
  RouterLink.decorators = [
52
57
  { type: core_1.Directive, args: [{ selector: '[routerLink]' },] },
53
58
  ];
59
+ /** @nocollapse */
54
60
  RouterLink.ctorParameters = [
55
- { type: segments_1.RouteSegment, decorators: [{ type: core_1.Optional },] },
61
+ { type: segments_1.RouteSegment, },
56
62
  { type: router_1.Router, },
63
+ { type: common_1.LocationStrategy, },
57
64
  ];
65
+ /** @nocollapse */
58
66
  RouterLink.propDecorators = {
59
67
  'target': [{ type: core_1.Input },],
60
68
  'href': [{ type: core_1.HostBinding },],
61
69
  'isActive': [{ type: core_1.HostBinding, args: ['class.router-link-active',] },],
62
70
  'routerLink': [{ type: core_1.Input },],
63
- 'onClick': [{ type: core_1.HostListener, args: ["click",] },],
71
+ 'onClick': [{ type: core_1.HostListener, args: ['click', ['$event.button', '$event.ctrlKey', '$event.metaKey'],] },],
64
72
  };
65
73
  return RouterLink;
66
74
  }());
@@ -1 +1 @@
1
- {"version":3,"file":"router_link.js","sourceRoot":"","sources":["../../../../../modules/@angular/router/src/directives/router_link.ts"],"names":[],"mappings":";AAIE,qBAeK,eAAe,CAAC,CAAA;AACvB,uBAAsC,WAAW,CAAC,CAAA;AAClD,yBAA6C,aAAa,CAAC,CAAA;AAC3D,qBAA2C,gBAAgB,CAAC,CAAA;AAC5D,sBAAgC,iBAAiB,CAAC,CAAA;AAClD;IAIE,oBAAqB,aAA2B,EAAU,OAAe;QAJ3E,iBAoDC;QAhDsB,kBAAa,GAAb,aAAa,CAAc;QAAU,YAAO,GAAP,OAAO,CAAQ;QAHjE,cAAS,GAAU,EAAE,CAAC;QACY,aAAQ,GAAY,KAA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AC5C,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACtD,CAAC;QAAC,IAAI,CAAC,CAAC;YACN,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC;QACxB,CAAC;IACH,CAAC;IACI,qBAAU,GAA0B;QAC3C,EAAE,IAAI,EAAE,gBAAS,EAAE,IAAI,EAAE,CAAC,EAAC,QAAQ,EAAE,cAAc,EAAC,EAAG,EAAE;KACxD,CAAC;IACK,yBAAc,GAA2D;QAChF,EAAC,IAAI,EAAE,uBAAY,EAAE,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,eAAQ,EAAE,EAAG,EAAC;QACxD,EAAC,IAAI,EAAE,eAAM,GAAG;KACf,CAAC;IACK,yBAAc,GAA2C;QAChE,QAAQ,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAC5B,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,kBAAW,EAAE,EAAE;QAChC,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,kBAAW,EAAE,IAAI,EAAE,CAAC,0BAA0B,EAAG,EAAE,EAAE;QAC1E,YAAY,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAChC,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,mBAAY,EAAE,IAAI,EAAE,CAAC,OAAO,EAAG,EAAE,EAAE;KACtD,CAAC;IACF,iBAAC;AAAD,CAAC,AApDD,IAoDC;AApDY,kBAAU,aAoDtB,CAAA","sourcesContent":["interface DecoratorInvocation {\n type: Function;\n args?: any[];\n }\n import {\n ResolvedReflectiveProvider,\n Directive,\n DynamicComponentLoader,\n ViewContainerRef,\n Attribute,\n ComponentRef,\n ComponentFactory,\n ReflectiveInjector,\n OnInit,\n HostListener,\n HostBinding,\n Input,\n OnDestroy,\n Optional\n} from '@angular/core';\nimport {RouterOutletMap, Router} from '../router';\nimport {RouteSegment, UrlSegment, Tree} from '../segments';\nimport {isString, isArray, isPresent} from '../facade/lang';\nimport {ObservableWrapper} from '../facade/async';\nexport class RouterLink implements OnDestroy { target: string;\n private _commands: any[] = [];\n private _subscription: any; href: string; isActive: boolean = false;\n\n constructor( private _routeSegment: RouteSegment, private _router: Router) {\n // because auxiliary links take existing primary and auxiliary routes into account,\n // we need to update the link whenever params or other routes change.\n this._subscription =\n ObservableWrapper.subscribe(_router.changes, (_) => { this._updateTargetUrlAndHref(); });\n }\n\n ngOnDestroy() { ObservableWrapper.dispose(this._subscription); }\n set routerLink(data: any[]|any) {\n if (isArray(data)) {\n this._commands = <any[]>data;\n } else {\n this._commands = [data];\n }\n this._updateTargetUrlAndHref();\n }\n onClick(): boolean {\n // If no target, or if target is _self, prevent default browser behavior\n if (!isString(this.target) || this.target == '_self') {\n this._router.navigate(this._commands, this._routeSegment);\n return false;\n }\n return true;\n }\n\n private _updateTargetUrlAndHref(): void {\n let tree = this._router.createUrlTree(this._commands, this._routeSegment);\n if (isPresent(tree)) {\n this.href = this._router.serializeUrl(tree);\n this.isActive = this._router.urlTree.contains(tree);\n } else {\n this.isActive = false;\n }\n }\nstatic decorators: DecoratorInvocation[] = [\n{ type: Directive, args: [{selector: '[routerLink]'}, ] },\n];\nstatic ctorParameters: {type: Function, decorators?: DecoratorInvocation[]}[] = [\n{type: RouteSegment, decorators: [{ type: Optional }, ]},\n{type: Router, },\n];\nstatic propDecorators: {[key: string]: DecoratorInvocation[]} = {\n'target': [{ type: Input },],\n'href': [{ type: HostBinding },],\n'isActive': [{ type: HostBinding, args: ['class.router-link-active', ] },],\n'routerLink': [{ type: Input },],\n'onClick': [{ type: HostListener, args: [\"click\", ] },],\n};\n}\n"]}
1
+ {"version":3,"file":"router_link.js","sourceRoot":"","sources":["../../../../../modules/@angular/router/src/directives/router_link.ts"],"names":[],"mappings":";AAAA,uBAA+B,iBAAiB,CAAC,CAAA;AACjD,qBAAqE,eAAe,CAAC,CAAA;AAErF,sBAAgC,i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AW,EAAE,IAAI,EAAE,CAAC,0BAA0B,EAAG,EAAE,EAAE;QAC1E,YAAY,EAAE,CAAC,EAAE,IAAI,EAAE,YAAK,EAAE,EAAE;QAChC,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,mBAAY,EAAE,IAAI,EAAE,CAAC,OAAO,EAAE,CAAC,eAAe,EAAE,gBAAgB,EAAE,gBAAgB,CAAC,EAAG,EAAE,EAAE;KAC7G,CAAC;IACF,iBAAC;AAAD,CAAC,AA9DD,IA8DC;AA9DY,kBAAU,aA8DtB,CAAA","sourcesContent":["import {LocationStrategy} from '@angular/common';\nimport {Directive, HostBinding, HostListener, Input, OnDestroy} from '@angular/core';\n\nimport {ObservableWrapper} from '../facade/async';\nimport {isArray, isPresent, isString} from '../facade/lang';\nimport {Router} from '../router';\nimport {RouteSegment} from '../segments';\nexport class RouterLink implements OnDestroy { target: string;\n private _commands: any[] = [];\n private _subscription: any; href: string; isActive: boolean = false;\n\n constructor(\n private _routeSegment: RouteSegment, private _router: Router,\n private _locationStrategy: LocationStrategy) {\n // because auxiliary links take existing primary and auxiliary routes into account,\n // we need to update the link whenever params or other routes change.\n this._subscription =\n ObservableWrapper.subscribe(_router.changes, (_) => { this._updateTargetUrlAndHref(); });\n }\n\n ngOnDestroy() { ObservableWrapper.dispose(this._subscription); }\n set routerLink(data: any[]|any) {\n if (isArray(data)) {\n this._commands = <any[]>data;\n } else {\n this._commands = [data];\n }\n this._updateTargetUrlAndHref();\n }\n onClick(button: number, ctrlKey: boolean, metaKey: boolean): boolean {\n if (button != 0 || ctrlKey || metaKey) {\n return true;\n }\n\n if (isString(this.target) && this.target != '_self') {\n return true;\n }\n\n this._router.navigate(this._commands, this._routeSegment);\n return false;\n }\n\n private _updateTargetUrlAndHref(): void {\n let tree = this._router.createUrlTree(this._commands, this._routeSegment);\n if (isPresent(tree)) {\n this.href = this._locationStrategy.prepareExternalUrl(this._router.serializeUrl(tree));\n this.isActive = this._router.urlTree.contains(tree);\n } else {\n this.isActive = false;\n }\n }\n/** @nocollapse */\nstatic decorators: DecoratorInvocation[] = [\n{ type: Directive, args: [{selector: '[routerLink]'}, ] },\n];\n/** @nocollapse */\nstatic ctorParameters: {type: Function, decorators?: DecoratorInvocation[]}[] = [\n{type: RouteSegment, },\n{type: Router, },\n{type: LocationStrategy, },\n];\n/** @nocollapse */\nstatic propDecorators: {[key: string]: DecoratorInvocation[]} = {\n'target': [{ type: Input },],\n'href': [{ type: HostBinding },],\n'isActive': [{ type: HostBinding, args: ['class.router-link-active', ] },],\n'routerLink': [{ type: Input },],\n'onClick': [{ type: HostListener, args: ['click', ['$event.button', '$event.ctrlKey', '$event.metaKey'], ] },],\n};\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
@@ -1 +1 @@
1
- {"__symbolic":"module","metadata":{"RouterLink":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"Directive","module":"@angular/core"},"arguments":[{"selector":"[routerLink]"}]}],"members":{"target":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"Input","module":"@angular/core"}}]}],"href":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"HostBinding","module":"@angular/core"}}]}],"isActive":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"HostBinding","module":"@angular/core"},"arguments":["class.router-link-active"]}]}],"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"Optional","module":"@angular/core"}}],null],"parameters":[{"__symbolic":"reference","name":"RouteSegment","module":"../segments"},{"__symbolic":"reference","name":"Router","module":"../router"}]}],"routerLink":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"Input","module":"@angular/core"}}]}],"onClick":[{"__symbolic":"method","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"HostListener","module":"@angular/core"},"arguments":["click"]}]}]}}}}
1
+ {"__symbolic":"module","version":1,"metadata":{"RouterLink":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Directive"},"arguments":[{"selector":"[routerLink]"}]}],"members":{"target":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"href":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"HostBinding"}}]}],"isActive":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"HostBinding"},"arguments":["class.router-link-active"]}]}],"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"../segments","name":"RouteSegment"},{"__symbolic":"reference","module":"../router","name":"Router"},{"__symbolic":"reference","module":"@angular/common","name":"LocationStrategy"}]}],"ngOnDestroy":[{"__symbolic":"method"}],"routerLink":[{"__symbolic":"property","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Input"}}]}],"onClick":[{"__symbolic":"method","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"HostListener"},"arguments":["click",["$event.button","$event.ctrlKey","$event.metaKey"]]}]}],"_updateTargetUrlAndHref":[{"__symbolic":"method"}]}}}}
@@ -1,4 +1,4 @@
1
- import { ResolvedReflectiveProvider, ViewContainerRef, ComponentRef, ComponentFactory } from '@angular/core';
1
+ import { ComponentFactory, ComponentRef, ResolvedReflectiveProvider, ViewContainerRef } from '@angular/core';
2
2
  import { RouterOutletMap } from '../router';
3
3
  /**
4
4
  * A router outlet is a placeholder that Angular dynamically fills based on the application's route.
@@ -17,20 +17,20 @@ import { RouterOutletMap } from '../router';
17
17
  */
18
18
  export declare class RouterOutlet {
19
19
  private _location;
20
- private _loaded;
20
+ private _activated;
21
21
  outletMap: RouterOutletMap;
22
22
  constructor(parentOutletMap: RouterOutletMap, _location: ViewContainerRef, name: string);
23
- unload(): void;
23
+ deactivate(): void;
24
24
  /**
25
25
  * Returns the loaded component.
26
26
  */
27
- loadedComponent: Object;
27
+ component: Object;
28
28
  /**
29
29
  * Returns true is the outlet is not empty.
30
30
  */
31
- isLoaded: boolean;
31
+ isActivated: boolean;
32
32
  /**
33
33
  * Called by the Router to instantiate a new component.
34
34
  */
35
- load(factory: ComponentFactory<any>, providers: ResolvedReflectiveProvider[], outletMap: RouterOutletMap): ComponentRef<any>;
35
+ activate(factory: ComponentFactory<any>, providers: ResolvedReflectiveProvider[], outletMap: RouterOutletMap): ComponentRef<any>;
36
36
  }
@@ -1,45 +1,47 @@
1
1
  "use strict";
2
2
  var core_1 = require('@angular/core');
3
- var router_1 = require('../router');
4
3
  var constants_1 = require('../constants');
5
4
  var lang_1 = require('../facade/lang');
5
+ var router_1 = require('../router');
6
6
  var RouterOutlet = (function () {
7
7
  function RouterOutlet(parentOutletMap, _location, name) {
8
8
  this._location = _location;
9
9
  parentOutletMap.registerOutlet(lang_1.isBlank(name) ? constants_1.DEFAULT_OUTLET_NAME : name, this);
10
10
  }
11
- RouterOutlet.prototype.unload = function () {
12
- this._loaded.destroy();
13
- this._loaded = null;
11
+ RouterOutlet.prototype.deactivate = function () {
12
+ this._activated.destroy();
13
+ this._activated = null;
14
14
  };
15
- Object.defineProperty(RouterOutlet.prototype, "loadedComponent", {
15
+ Object.defineProperty(RouterOutlet.prototype, "component", {
16
16
  /**
17
17
  * Returns the loaded component.
18
18
  */
19
- get: function () { return lang_1.isPresent(this._loaded) ? this._loaded.instance : null; },
19
+ get: function () { return lang_1.isPresent(this._activated) ? this._activated.instance : null; },
20
20
  enumerable: true,
21
21
  configurable: true
22
22
  });
23
- Object.defineProperty(RouterOutlet.prototype, "isLoaded", {
23
+ Object.defineProperty(RouterOutlet.prototype, "isActivated", {
24
24
  /**
25
25
  * Returns true is the outlet is not empty.
26
26
  */
27
- get: function () { return lang_1.isPresent(this._loaded); },
27
+ get: function () { return lang_1.isPresent(this._activated); },
28
28
  enumerable: true,
29
29
  configurable: true
30
30
  });
31
31
  /**
32
32
  * Called by the Router to instantiate a new component.
33
33
  */
34
- RouterOutlet.prototype.load = function (factory, providers, outletMap) {
34
+ RouterOutlet.prototype.activate = function (factory, providers, outletMap) {
35
35
  this.outletMap = outletMap;
36
36
  var inj = core_1.ReflectiveInjector.fromResolvedProviders(providers, this._location.parentInjector);
37
- this._loaded = this._location.createComponent(factory, this._location.length, inj, []);
38
- return this._loaded;
37
+ this._activated = this._location.createComponent(factory, this._location.length, inj, []);
38
+ return this._activated;
39
39
  };
40
+ /** @nocollapse */
40
41
  RouterOutlet.decorators = [
41
42
  { type: core_1.Directive, args: [{ selector: 'router-outlet' },] },
42
43
  ];
44
+ /** @nocollapse */
43
45
  RouterOutlet.ctorParameters = [
44
46
  { type: router_1.RouterOutletMap, },
45
47
  { type: core_1.ViewContainerRef, },
@@ -1 +1 @@
1
- {"version":3,"file":"router_outlet.js","sourceRoot":"","sources":["../../../../../modules/@angular/router/src/directives/router_outlet.ts"],"names":[],"mappings":";AAIE,qBAUK,eAAe,CAAC,CAAA;AACvB,uBAA8B,WAAW,CAAC,CAAA;AAC1C,0BAAkC,cAAc,CAAC,CAAA;AACjD,qBAAiC,gBAAgB,CAAC,CAAA;AAClD;IAIE,sBAAY,eAAgC,EAAU,SAA2B,EAAE,IAAY;QAAzC,cAAS,GAAT,SAAS,CAAkB;QAC/E,eAAe,CAAC,cAAc,CAAC,cAAO,CAAC,IAAI,CAAC,GAAG,+BAAmB,GAAG,IAAI,EAAE,IAAI,CAAC,CAAC;IACnF,CAAC;IAED,6BAAM,GAAN;QACE,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC;QACvB,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;IACtB,CAAC;IAKD,sBAAI,yCAAe;QAHnB;;WAEG;aACH,cAAgC,MAAM,CAAC,gBAAS,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,GAAG,IAAI,CAAC,CAAC,CAAC;;;OAAA;IAKhG,sBAAI,kCAAQ;QAHZ;;WAEG;aACH,cAA0B,MAAM,CAAC,gBAAS,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;;;OAAA;IAE3D;;OAEG;IACH,2BAAI,GAAJ,UAAK,OAA8B,EAAE,SAAuC,EACvE,SAA0B;QAC7B,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;QAC3B,IAAI,GAAG,GAAG,yBAAkB,CAAC,qBAAqB,CAAC,SAAS,EAAE,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,CAAC;QAC7F,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC,SAAS,CAAC,eAAe,CAAC,OAAO,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,GAAG,EAAE,EAAE,CAAC,CAAC;QACvF,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IACI,uBAAU,GAA0B;QAC3C,EAAE,IAAI,EAAE,gBAAS,EAAE,IAAI,EAAE,CAAC,EAAC,QAAQ,EAAE,eAAe,EAAC,EAAG,EAAE;KACzD,CAAC;IACK,2BAAc,GAA2D;QAChF,EAAC,IAAI,EAAE,wBAAe,GAAG;QACzB,EAAC,IAAI,EAAE,uBAAgB,GAAG;QAC1B,EAAC,IAAI,EAAE,SAAS,EAAE,UAAU,EAAE,CAAC,EAAE,IAAI,EAAE,gBAAS,EAAE,IAAI,EAAE,CAAC,MAAM,EAAG,EAAE,EAAG,EAAC;KACvE,CAAC;IACF,mBAAC;AAAD,CAAC,AAzCD,IAyCC;AAzCY,oBAAY,eAyCxB,CAAA","sourcesContent":["interface DecoratorInvocation {\n type: Function;\n args?: any[];\n }\n import {\n ResolvedReflectiveProvider,\n Directive,\n DynamicComponentLoader,\n ViewContainerRef,\n Attribute,\n ComponentRef,\n ComponentFactory,\n ReflectiveInjector,\n OnInit\n} from '@angular/core';\nimport {RouterOutletMap} from '../router';\nimport {DEFAULT_OUTLET_NAME} from '../constants';\nimport {isPresent, isBlank} from '../facade/lang';\nexport class RouterOutlet {\n private _loaded: ComponentRef<any>;\n public outletMap: RouterOutletMap;\n\n constructor(parentOutletMap: RouterOutletMap, private _location: ViewContainerRef, name: string) {\n parentOutletMap.registerOutlet(isBlank(name) ? DEFAULT_OUTLET_NAME : name, this);\n }\n\n unload(): void {\n this._loaded.destroy();\n this._loaded = null;\n }\n\n /**\n * Returns the loaded component.\n */\n get loadedComponent(): Object { return isPresent(this._loaded) ? this._loaded.instance : null; }\n\n /**\n * Returns true is the outlet is not empty.\n */\n get isLoaded(): boolean { return isPresent(this._loaded); }\n\n /**\n * Called by the Router to instantiate a new component.\n */\n load(factory: ComponentFactory<any>, providers: ResolvedReflectiveProvider[],\n outletMap: RouterOutletMap): ComponentRef<any> {\n this.outletMap = outletMap;\n let inj = ReflectiveInjector.fromResolvedProviders(providers, this._location.parentInjector);\n this._loaded = this._location.createComponent(factory, this._location.length, inj, []);\n return this._loaded;\n }\nstatic decorators: DecoratorInvocation[] = [\n{ type: Directive, args: [{selector: 'router-outlet'}, ] },\n];\nstatic ctorParameters: {type: Function, decorators?: DecoratorInvocation[]}[] = [\n{type: RouterOutletMap, },\n{type: ViewContainerRef, },\n{type: undefined, decorators: [{ type: Attribute, args: ['name', ] }, ]},\n];\n}\n"]}
1
+ {"version":3,"file":"router_outlet.js","sourceRoot":"","sources":["../../../../../modules/@angular/router/src/directives/router_outlet.ts"],"names":[],"mappings":";AAAA,qBAAqI,eAAe,CAAC,CAAA;AAErJ,0BAAkC,cAAc,CAAC,CAAA;AACjD,qBAAiC,gBAAgB,CAAC,CAAA;AAClD,uBAA8B,WAAW,CAAC,CAAA;AAC1C;IAIE,sBACI,eAAgC,EAAU,SAA2B,EAAE,IAAY;QAAzC,cAAS,GAAT,SAAS,CAAkB;QACvE,eAAe,CAAC,cAAc,CAAC,cAAO,CAAC,IAAI,CAAC,GAAG,+BAAmB,G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AAE,CAAC,MAAM,EAAG,EAAE,EAAG,EAAC;KACvE,CAAC;IACF,mBAAC;AAAD,CAAC,AA7CD,IA6CC;AA7CY,oBAAY,eA6CxB,CAAA","sourcesContent":["import {Attribute, ComponentFactory, ComponentRef, Directive, ReflectiveInjector, ResolvedReflectiveProvider, ViewContainerRef} from '@angular/core';\n\nimport {DEFAULT_OUTLET_NAME} from '../constants';\nimport {isBlank, isPresent} from '../facade/lang';\nimport {RouterOutletMap} from '../router';\nexport class RouterOutlet {\n private _activated: ComponentRef<any>;\n public outletMap: RouterOutletMap;\n\n constructor(\n parentOutletMap: RouterOutletMap, private _location: ViewContainerRef, name: string) {\n parentOutletMap.registerOutlet(isBlank(name) ? DEFAULT_OUTLET_NAME : name, this);\n }\n\n deactivate(): void {\n this._activated.destroy();\n this._activated = null;\n }\n\n /**\n * Returns the loaded component.\n */\n get component(): Object { return isPresent(this._activated) ? this._activated.instance : null; }\n\n /**\n * Returns true is the outlet is not empty.\n */\n get isActivated(): boolean { return isPresent(this._activated); }\n\n /**\n * Called by the Router to instantiate a new component.\n */\n activate(\n factory: ComponentFactory<any>, providers: ResolvedReflectiveProvider[],\n outletMap: RouterOutletMap): ComponentRef<any> {\n this.outletMap = outletMap;\n let inj = ReflectiveInjector.fromResolvedProviders(providers, this._location.parentInjector);\n this._activated = this._location.createComponent(factory, this._location.length, inj, []);\n return this._activated;\n }\n/** @nocollapse */\nstatic decorators: DecoratorInvocation[] = [\n{ type: Directive, args: [{selector: 'router-outlet'}, ] },\n];\n/** @nocollapse */\nstatic ctorParameters: {type: Function, decorators?: DecoratorInvocation[]}[] = [\n{type: RouterOutletMap, },\n{type: ViewContainerRef, },\n{type: undefined, decorators: [{ type: Attribute, args: ['name', ] }, ]},\n];\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
@@ -1 +1 @@
1
- {"__symbolic":"module","metadata":{"RouterOutlet":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"Directive","module":"@angular/core"},"arguments":[{"selector":"router-outlet"}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[null,null,[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"Attribute","module":"@angular/core"},"arguments":["name"]}]],"parameters":[{"__symbolic":"reference","name":"RouterOutletMap","module":"../router"},{"__symbolic":"reference","name":"ViewContainerRef","module":"@angular/core"},null]}]}}}}
1
+ {"__symbolic":"module","version":1,"metadata":{"RouterOutlet":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Directive"},"arguments":[{"selector":"router-outlet"}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[null,null,[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Attribute"},"arguments":["name"]}]],"parameters":[{"__symbolic":"reference","module":"../router","name":"RouterOutletMap"},{"__symbolic":"reference","module":"@angular/core","name":"ViewContainerRef"},{"__symbolic":"reference","name":"string"}]}],"deactivate":[{"__symbolic":"method"}],"activate":[{"__symbolic":"method"}]}}}}
@@ -1,8 +1,8 @@
1
- export { PromiseWrapper, PromiseCompleter } from './promise';
2
1
  import { Observable } from 'rxjs/Observable';
3
2
  import { Subject } from 'rxjs/Subject';
4
3
  export { Observable } from 'rxjs/Observable';
5
4
  export { Subject } from 'rxjs/Subject';
5
+ export { PromiseCompleter, PromiseWrapper } from './promise';
6
6
  export declare class TimerWrapper {
7
7
  static setTimeout(fn: (...args: any[]) => void, millis: number): number;
8
8
  static clearTimeout(id: number): void;
@@ -61,14 +61,21 @@ export declare class ObservableWrapper {
61
61
  * }
62
62
  * ```
63
63
  *
64
- * Use Rx.Observable but provides an adapter to make it work as specified here:
64
+ * The events payload can be accessed by the parameter `$event` on the components output event
65
+ * handler:
66
+ *
67
+ * ```
68
+ * <zippy (open)="onOpen($event)" (close)="onClose($event)"></zippy>
69
+ * ```
70
+ *
71
+ * Uses Rx.Observable but provides an adapter to make it work as specified here:
65
72
  * https://github.com/jhusain/observable-spec
66
73
  *
67
74
  * Once a reference implementation of the spec is available, switch to it.
75
+ * @stable
68
76
  */
69
77
  export declare class EventEmitter<T> extends Subject<T> {
70
- /** @internal */
71
- _isAsync: boolean;
78
+ __isAsync: boolean;
72
79
  /**
73
80
  * Creates an instance of [EventEmitter], which depending on [isAsync],
74
81
  * delivers events synchronously or asynchronously.
@@ -4,17 +4,17 @@ var __extends = (this && this.__extends) || function (d, b) {
4
4
  function __() { this.constructor = d; }
5
5
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
6
6
  };
7
- var lang_1 = require('./lang');
8
- var promise_1 = require('./promise');
9
- exports.PromiseWrapper = promise_1.PromiseWrapper;
10
- exports.PromiseCompleter = promise_1.PromiseCompleter;
11
7
  var Subject_1 = require('rxjs/Subject');
12
8
  var PromiseObservable_1 = require('rxjs/observable/PromiseObservable');
13
9
  var toPromise_1 = require('rxjs/operator/toPromise');
10
+ var lang_1 = require('./lang');
14
11
  var Observable_1 = require('rxjs/Observable');
15
12
  exports.Observable = Observable_1.Observable;
16
13
  var Subject_2 = require('rxjs/Subject');
17
14
  exports.Subject = Subject_2.Subject;
15
+ var promise_1 = require('./promise');
16
+ exports.PromiseCompleter = promise_1.PromiseCompleter;
17
+ exports.PromiseWrapper = promise_1.PromiseWrapper;
18
18
  var TimerWrapper = (function () {
19
19
  function TimerWrapper() {
20
20
  }
@@ -35,8 +35,8 @@ var ObservableWrapper = (function () {
35
35
  // TODO(vsavkin): when we use rxnext, try inferring the generic type from the first arg
36
36
  ObservableWrapper.subscribe = function (emitter, onNext, onError, onComplete) {
37
37
  if (onComplete === void 0) { onComplete = function () { }; }
38
- onError = (typeof onError === "function") && onError || lang_1.noop;
39
- onComplete = (typeof onComplete === "function") && onComplete || lang_1.noop;
38
+ onError = (typeof onError === 'function') && onError || lang_1.noop;
39
+ onComplete = (typeof onComplete === 'function') && onComplete || lang_1.noop;
40
40
  return emitter.subscribe({ next: onNext, error: onError, complete: onComplete });
41
41
  };
42
42
  ObservableWrapper.isObservable = function (obs) { return !!obs.subscribe; };
@@ -93,10 +93,18 @@ exports.ObservableWrapper = ObservableWrapper;
93
93
  * }
94
94
  * ```
95
95
  *
96
- * Use Rx.Observable but provides an adapter to make it work as specified here:
96
+ * The events payload can be accessed by the parameter `$event` on the components output event
97
+ * handler:
98
+ *
99
+ * ```
100
+ * <zippy (open)="onOpen($event)" (close)="onClose($event)"></zippy>
101
+ * ```
102
+ *
103
+ * Uses Rx.Observable but provides an adapter to make it work as specified here:
97
104
  * https://github.com/jhusain/observable-spec
98
105
  *
99
106
  * Once a reference implementation of the spec is available, switch to it.
107
+ * @stable
100
108
  */
101
109
  var EventEmitter = (function (_super) {
102
110
  __extends(EventEmitter, _super);
@@ -105,9 +113,9 @@ var EventEmitter = (function (_super) {
105
113
  * delivers events synchronously or asynchronously.
106
114
  */
107
115
  function EventEmitter(isAsync) {
108
- if (isAsync === void 0) { isAsync = true; }
116
+ if (isAsync === void 0) { isAsync = false; }
109
117
  _super.call(this);
110
- this._isAsync = isAsync;
118
+ this.__isAsync = isAsync;
111
119
  }
112
120
  EventEmitter.prototype.emit = function (value) { _super.prototype.next.call(this, value); };
113
121
  /**
@@ -119,27 +127,29 @@ var EventEmitter = (function (_super) {
119
127
  var errorFn = function (err) { return null; };
120
128
  var completeFn = function () { return null; };
121
129
  if (generatorOrNext && typeof generatorOrNext === 'object') {
122
- schedulerFn = this._isAsync ? function (value) { setTimeout(function () { return generatorOrNext.next(value); }); } :
123
- function (value) { generatorOrNext.next(value); };
130
+ schedulerFn = this.__isAsync ? function (value /** TODO #9100 */) {
131
+ setTimeout(function () { return generatorOrNext.next(value); });
132
+ } : function (value /** TODO #9100 */) { generatorOrNext.next(value); };
124
133
  if (generatorOrNext.error) {
125
- errorFn = this._isAsync ? function (err) { setTimeout(function () { return generatorOrNext.error(err); }); } :
134
+ errorFn = this.__isAsync ? function (err) { setTimeout(function () { return generatorOrNext.error(err); }); } :
126
135
  function (err) { generatorOrNext.error(err); };
127
136
  }
128
137
  if (generatorOrNext.complete) {
129
- completeFn = this._isAsync ? function () { setTimeout(function () { return generatorOrNext.complete(); }); } :
138
+ completeFn = this.__isAsync ? function () { setTimeout(function () { return generatorOrNext.complete(); }); } :
130
139
  function () { generatorOrNext.complete(); };
131
140
  }
132
141
  }
133
142
  else {
134
- schedulerFn = this._isAsync ? function (value) { setTimeout(function () { return generatorOrNext(value); }); } :
135
- function (value) { generatorOrNext(value); };
143
+ schedulerFn = this.__isAsync ? function (value /** TODO #9100 */) {
144
+ setTimeout(function () { return generatorOrNext(value); });
145
+ } : function (value /** TODO #9100 */) { generatorOrNext(value); };
136
146
  if (error) {
137
147
  errorFn =
138
- this._isAsync ? function (err) { setTimeout(function () { return error(err); }); } : function (err) { error(err); };
148
+ this.__isAsync ? function (err) { setTimeout(function () { return error(err); }); } : function (err) { error(err); };
139
149
  }
140
150
  if (complete) {
141
151
  completeFn =
142
- this._isAsync ? function () { setTimeout(function () { return complete(); }); } : function () { complete(); };
152
+ this.__isAsync ? function () { setTimeout(function () { return complete(); }); } : function () { complete(); };
143
153
  }
144
154
  }
145
155
  return _super.prototype.subscribe.call(this, schedulerFn, errorFn, completeFn);