@angular/core 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.
- package/{core.umd.js → bundles/core.umd.js} +6402 -4606
- package/bundles/core.umd.min.js +6 -0
- package/esm/index.d.ts +5 -4
- package/esm/index.js +9 -8
- package/esm/index.js.map +1 -1
- package/esm/private_export.d.ts +96 -11
- package/esm/private_export.js +39 -10
- package/esm/private_export.js.map +1 -1
- package/esm/private_export.metadata.json +1 -1
- package/esm/src/animation/active_animation_players_map.d.ts +11 -0
- package/esm/src/animation/active_animation_players_map.js +47 -0
- package/esm/src/animation/active_animation_players_map.js.map +1 -0
- package/esm/src/animation/animation_constants.d.ts +4 -0
- package/esm/src/animation/animation_constants.js +5 -0
- package/esm/src/animation/animation_constants.js.map +1 -0
- package/esm/src/animation/animation_constants.metadata.json +1 -0
- package/esm/src/animation/animation_driver.d.ts +9 -0
- package/esm/src/animation/animation_driver.js +9 -0
- package/esm/src/animation/animation_driver.js.map +1 -0
- package/esm/src/animation/animation_group_player.d.ts +18 -0
- package/esm/src/animation/animation_group_player.js +60 -0
- package/esm/src/animation/animation_group_player.js.map +1 -0
- package/esm/src/animation/animation_keyframe.d.ts +6 -0
- package/esm/src/animation/animation_keyframe.js +7 -0
- package/esm/src/animation/animation_keyframe.js.map +1 -0
- package/esm/src/animation/animation_player.d.ts +26 -0
- package/esm/src/animation/animation_player.js +30 -0
- package/esm/src/animation/animation_player.js.map +1 -0
- package/esm/src/animation/animation_sequence_player.d.ts +21 -0
- package/esm/src/animation/animation_sequence_player.js +64 -0
- package/esm/src/animation/animation_sequence_player.js.map +1 -0
- package/esm/src/animation/animation_style_util.d.ts +32 -0
- package/esm/src/animation/animation_style_util.js +91 -0
- package/esm/src/animation/animation_style_util.js.map +1 -0
- package/esm/src/animation/animation_style_util.metadata.json +1 -0
- package/esm/src/animation/animation_styles.d.ts +8 -0
- package/esm/src/animation/animation_styles.js +6 -0
- package/esm/src/animation/animation_styles.js.map +1 -0
- package/esm/src/animation/metadata.d.ts +511 -0
- package/esm/src/animation/metadata.js +565 -0
- package/esm/src/animation/metadata.js.map +1 -0
- package/esm/src/animation/metadata.metadata.json +1 -0
- package/esm/src/application_common_providers.d.ts +1 -0
- package/esm/src/application_common_providers.js +5 -4
- package/esm/src/application_common_providers.js.map +1 -1
- package/esm/src/application_common_providers.metadata.json +1 -1
- package/esm/src/application_ref.d.ts +17 -41
- package/esm/src/application_ref.js +32 -23
- package/esm/src/application_ref.js.map +1 -1
- package/esm/src/application_ref.metadata.json +1 -1
- package/esm/src/application_tokens.d.ts +6 -1
- package/esm/src/application_tokens.js +9 -4
- package/esm/src/application_tokens.js.map +1 -1
- package/esm/src/application_tokens.metadata.json +1 -1
- package/esm/src/change_detection/change_detection.d.ts +9 -8
- package/esm/src/change_detection/change_detection.js +7 -7
- package/esm/src/change_detection/change_detection.js.map +1 -1
- package/esm/src/change_detection/change_detection.metadata.json +1 -1
- package/esm/src/change_detection/change_detection_util.d.ts +3 -1
- package/esm/src/change_detection/change_detection_util.js +6 -5
- package/esm/src/change_detection/change_detection_util.js.map +1 -1
- package/esm/src/change_detection/change_detection_util.metadata.json +1 -1
- package/esm/src/change_detection/change_detector_ref.d.ts +3 -0
- package/esm/src/change_detection/change_detector_ref.js +3 -0
- package/esm/src/change_detection/change_detector_ref.js.map +1 -1
- package/esm/src/change_detection/constants.d.ts +1 -0
- package/esm/src/change_detection/constants.js +4 -3
- package/esm/src/change_detection/constants.js.map +1 -1
- package/esm/src/change_detection/constants.metadata.json +1 -1
- package/esm/src/change_detection/differs/default_iterable_differ.d.ts +6 -94
- package/esm/src/change_detection/differs/default_iterable_differ.js +25 -18
- package/esm/src/change_detection/differs/default_iterable_differ.js.map +1 -1
- package/esm/src/change_detection/differs/default_keyvalue_differ.d.ts +3 -30
- package/esm/src/change_detection/differs/default_keyvalue_differ.js +13 -8
- package/esm/src/change_detection/differs/default_keyvalue_differ.js.map +1 -1
- package/esm/src/change_detection/differs/iterable_differs.d.ts +4 -1
- package/esm/src/change_detection/differs/iterable_differs.js +5 -4
- package/esm/src/change_detection/differs/iterable_differs.js.map +1 -1
- package/esm/src/change_detection/differs/keyvalue_differs.d.ts +2 -1
- package/esm/src/change_detection/differs/keyvalue_differs.js +5 -4
- package/esm/src/change_detection/differs/keyvalue_differs.js.map +1 -1
- package/esm/src/change_detection/pipe_transform.js.map +1 -1
- package/esm/src/change_detection.d.ts +1 -1
- package/esm/src/change_detection.js +5 -5
- package/esm/src/change_detection.js.map +1 -1
- package/esm/src/console.js +2 -1
- package/esm/src/console.js.map +1 -1
- package/esm/src/console.metadata.json +1 -1
- package/esm/src/debug/debug_node.d.ts +20 -2
- package/esm/src/debug/debug_node.js +16 -2
- package/esm/src/debug/debug_node.js.map +1 -1
- package/esm/src/debug/debug_node.metadata.json +1 -0
- package/esm/src/debug/debug_renderer.d.ts +10 -6
- package/esm/src/debug/debug_renderer.js +13 -2
- package/esm/src/debug/debug_renderer.js.map +1 -1
- package/esm/src/di/decorators.d.ts +13 -1
- package/esm/src/di/decorators.js +7 -1
- package/esm/src/di/decorators.js.map +1 -1
- package/esm/src/di/decorators.metadata.json +1 -1
- package/esm/src/di/forward_ref.d.ts +3 -1
- package/esm/src/di/forward_ref.js +3 -1
- package/esm/src/di/forward_ref.js.map +1 -1
- package/esm/src/di/injector.d.ts +4 -1
- package/esm/src/di/injector.js +5 -2
- package/esm/src/di/injector.js.map +1 -1
- package/esm/src/di/injector.metadata.json +1 -1
- package/esm/src/di/metadata.d.ts +8 -1
- package/esm/src/di/metadata.js +10 -3
- package/esm/src/di/metadata.js.map +1 -1
- package/esm/src/di/opaque_token.d.ts +2 -1
- package/esm/src/di/opaque_token.js +22 -21
- package/esm/src/di/opaque_token.js.map +1 -1
- package/esm/src/di/provider.d.ts +11 -10
- package/esm/src/di/provider.js +17 -14
- package/esm/src/di/provider.js.map +1 -1
- package/esm/src/di/provider.metadata.json +1 -0
- package/esm/src/di/provider_util.js.map +1 -1
- package/esm/src/di/provider_util.metadata.json +1 -0
- package/esm/src/di/reflective_exceptions.d.ts +11 -16
- package/esm/src/di/reflective_exceptions.js +28 -22
- package/esm/src/di/reflective_exceptions.js.map +1 -1
- package/esm/src/di/reflective_injector.d.ts +3 -33
- package/esm/src/di/reflective_injector.js +10 -7
- package/esm/src/di/reflective_injector.js.map +1 -1
- package/esm/src/di/reflective_key.d.ts +1 -8
- package/esm/src/di/reflective_key.js +3 -2
- package/esm/src/di/reflective_key.js.map +1 -1
- package/esm/src/di/reflective_provider.d.ts +2 -1
- package/esm/src/di/reflective_provider.js +6 -5
- package/esm/src/di/reflective_provider.js.map +1 -1
- package/esm/src/di/reflective_provider.metadata.json +1 -0
- package/esm/src/di.d.ts +2 -2
- package/esm/src/di.js +6 -6
- package/esm/src/di.js.map +1 -1
- package/esm/src/facade/async.d.ts +11 -4
- package/esm/src/facade/async.js +25 -15
- package/esm/src/facade/async.js.map +1 -1
- package/esm/src/facade/base_wrapped_exception.js +4 -4
- package/esm/src/facade/base_wrapped_exception.js.map +1 -1
- package/esm/src/facade/collection.js +1 -1
- package/esm/src/facade/collection.js.map +1 -1
- package/esm/src/facade/collection.metadata.json +1 -1
- package/esm/src/facade/exception_handler.d.ts +2 -11
- package/esm/src/facade/exception_handler.js +8 -7
- package/esm/src/facade/exception_handler.js.map +1 -1
- package/esm/src/facade/exceptions.d.ts +4 -0
- package/esm/src/facade/exceptions.js +6 -2
- package/esm/src/facade/exceptions.js.map +1 -1
- package/esm/src/facade/exceptions.metadata.json +1 -0
- package/esm/src/facade/lang.d.ts +6 -4
- package/esm/src/facade/lang.js +12 -11
- package/esm/src/facade/lang.js.map +1 -1
- package/esm/src/facade/lang.metadata.json +1 -1
- package/esm/src/facade/math.d.ts +2 -0
- package/esm/src/facade/math.js +4 -0
- package/esm/src/facade/math.js.map +1 -0
- package/esm/src/facade/math.metadata.json +1 -0
- package/esm/src/facade/promise.js.map +1 -1
- package/esm/src/linker/component_factory.d.ts +5 -4
- package/esm/src/linker/component_factory.js +7 -3
- package/esm/src/linker/component_factory.js.map +1 -1
- package/esm/src/linker/component_resolver.d.ts +5 -4
- package/esm/src/linker/component_resolver.js +12 -7
- package/esm/src/linker/component_resolver.js.map +1 -1
- package/esm/src/linker/component_resolver.metadata.json +1 -1
- package/esm/src/linker/debug_context.js +5 -4
- package/esm/src/linker/debug_context.js.map +1 -1
- package/esm/src/linker/dynamic_component_loader.d.ts +5 -6
- package/esm/src/linker/dynamic_component_loader.js +5 -3
- package/esm/src/linker/dynamic_component_loader.js.map +1 -1
- package/esm/src/linker/dynamic_component_loader.metadata.json +1 -1
- package/esm/src/linker/element.d.ts +3 -3
- package/esm/src/linker/element.js +5 -5
- package/esm/src/linker/element.js.map +1 -1
- package/esm/src/linker/element_injector.js.map +1 -1
- package/esm/src/linker/element_ref.d.ts +1 -0
- package/esm/src/linker/element_ref.js +5 -5
- package/esm/src/linker/element_ref.js.map +1 -1
- package/esm/src/linker/exceptions.d.ts +4 -1
- package/esm/src/linker/exceptions.js +4 -1
- package/esm/src/linker/exceptions.js.map +1 -1
- package/esm/src/linker/query_list.d.ts +3 -10
- package/esm/src/linker/query_list.js +8 -7
- package/esm/src/linker/query_list.js.map +1 -1
- package/esm/src/linker/systemjs_component_resolver.d.ts +21 -0
- package/esm/src/linker/systemjs_component_resolver.js +44 -0
- package/esm/src/linker/systemjs_component_resolver.js.map +1 -0
- package/esm/src/linker/template_ref.d.ts +2 -1
- package/esm/src/linker/template_ref.js +1 -0
- package/esm/src/linker/template_ref.js.map +1 -1
- package/esm/src/linker/view.d.ts +12 -1
- package/esm/src/linker/view.js +62 -16
- package/esm/src/linker/view.js.map +1 -1
- package/esm/src/linker/view_container_ref.d.ts +2 -10
- package/esm/src/linker/view_container_ref.js +4 -3
- package/esm/src/linker/view_container_ref.js.map +1 -1
- package/esm/src/linker/view_ref.d.ts +5 -1
- package/esm/src/linker/view_ref.js +6 -2
- package/esm/src/linker/view_ref.js.map +1 -1
- package/esm/src/linker/view_type.js.map +1 -1
- package/esm/src/linker/view_utils.d.ts +2 -4
- package/esm/src/linker/view_utils.js +21 -21
- package/esm/src/linker/view_utils.js.map +1 -1
- package/esm/src/linker/view_utils.metadata.json +1 -1
- package/esm/src/linker.d.ts +5 -4
- package/esm/src/linker.js +5 -4
- package/esm/src/linker.js.map +1 -1
- package/esm/src/metadata/di.d.ts +8 -1
- package/esm/src/metadata/di.js +10 -3
- package/esm/src/metadata/di.js.map +1 -1
- package/esm/src/metadata/directives.d.ts +104 -20
- package/esm/src/metadata/directives.js +25 -19
- package/esm/src/metadata/directives.js.map +1 -1
- package/esm/src/metadata/lifecycle_hooks.d.ts +46 -31
- package/esm/src/metadata/lifecycle_hooks.js +464 -10
- package/esm/src/metadata/lifecycle_hooks.js.map +1 -1
- package/esm/src/metadata/lifecycle_hooks.metadata.json +1 -1
- package/esm/src/metadata/view.d.ts +6 -2
- package/esm/src/metadata/view.js +3 -1
- package/esm/src/metadata/view.js.map +1 -1
- package/esm/src/metadata/view.metadata.json +1 -1
- package/esm/src/metadata.d.ts +49 -15
- package/esm/src/metadata.js +35 -10
- package/esm/src/metadata.js.map +1 -1
- package/esm/src/metadata.metadata.json +1 -1
- package/esm/src/platform_common_providers.d.ts +1 -0
- package/esm/src/platform_common_providers.js +3 -3
- package/esm/src/platform_common_providers.js.map +1 -1
- package/esm/src/platform_common_providers.metadata.json +1 -1
- package/esm/src/platform_directives_and_pipes.d.ts +48 -45
- package/esm/src/platform_directives_and_pipes.js +50 -47
- package/esm/src/platform_directives_and_pipes.js.map +1 -1
- package/esm/src/platform_directives_and_pipes.metadata.json +1 -1
- package/esm/src/profile/profile.d.ts +5 -1
- package/esm/src/profile/profile.js +4 -0
- package/esm/src/profile/profile.js.map +1 -1
- package/esm/src/profile/profile.metadata.json +1 -1
- package/esm/src/profile/wtf_impl.js +1 -1
- package/esm/src/profile/wtf_impl.js.map +1 -1
- package/esm/src/profile/wtf_impl.metadata.json +1 -0
- package/esm/src/profile/wtf_init.js +2 -2
- package/esm/src/profile/wtf_init.js.map +1 -1
- package/esm/src/reflection/platform_reflection_capabilities.d.ts +4 -3
- package/esm/src/reflection/platform_reflection_capabilities.js.map +1 -1
- package/esm/src/reflection/reflection.d.ts +1 -1
- package/esm/src/reflection/reflection.js +2 -2
- package/esm/src/reflection/reflection.js.map +1 -1
- package/esm/src/reflection/reflection.metadata.json +1 -1
- package/esm/src/reflection/reflection_capabilities.d.ts +4 -5
- package/esm/src/reflection/reflection_capabilities.js +22 -10
- package/esm/src/reflection/reflection_capabilities.js.map +1 -1
- package/esm/src/reflection/reflector.d.ts +8 -20
- package/esm/src/reflection/reflector.js +13 -3
- package/esm/src/reflection/reflector.js.map +1 -1
- package/esm/src/reflection/reflector_reader.js +3 -3
- package/esm/src/reflection/reflector_reader.js.map +1 -1
- package/esm/src/reflection/types.js.map +1 -1
- package/esm/src/render/api.d.ts +17 -6
- package/esm/src/render/api.js +8 -1
- package/esm/src/render/api.js.map +1 -1
- package/esm/src/render.d.ts +1 -1
- package/esm/src/render.js +1 -1
- package/esm/src/render.js.map +1 -1
- package/esm/src/security.js +6 -6
- package/esm/src/security.js.map +1 -1
- package/esm/src/testability/testability.d.ts +3 -19
- package/esm/src/testability/testability.js +10 -5
- package/esm/src/testability/testability.js.map +1 -1
- package/esm/src/testability/testability.metadata.json +1 -1
- package/esm/src/util/decorators.d.ts +2 -1
- package/esm/src/util/decorators.js +10 -9
- package/esm/src/util/decorators.js.map +1 -1
- package/esm/src/util.js.map +1 -1
- package/esm/src/zone/ng_zone.d.ts +6 -17
- package/esm/src/zone/ng_zone.js +7 -6
- package/esm/src/zone/ng_zone.js.map +1 -1
- package/esm/src/zone/ng_zone_impl.d.ts +1 -4
- package/esm/src/zone/ng_zone_impl.js +3 -2
- package/esm/src/zone/ng_zone_impl.js.map +1 -1
- package/esm/src/zone.js.map +1 -1
- package/esm/testing/async.js +20 -22
- package/esm/testing/async.js.map +1 -1
- package/esm/testing/async.metadata.json +1 -0
- package/esm/testing/async_test_completer.js.map +1 -1
- package/esm/testing/fake_async.d.ts +4 -1
- package/esm/testing/fake_async.js +9 -2
- package/esm/testing/fake_async.js.map +1 -1
- package/esm/testing/lang_utils.js +1 -1
- package/esm/testing/lang_utils.js.map +1 -1
- package/esm/testing/lang_utils.metadata.json +1 -0
- package/esm/testing/logger.js +5 -3
- package/esm/testing/logger.js.map +1 -1
- package/esm/testing/logger.metadata.json +1 -1
- package/esm/testing/mock_application_ref.d.ts +1 -1
- package/esm/testing/mock_application_ref.js +1 -0
- package/esm/testing/mock_application_ref.js.map +1 -1
- package/esm/testing/mock_application_ref.metadata.json +1 -1
- package/esm/testing/ng_zone_mock.d.ts +0 -1
- package/esm/testing/ng_zone_mock.js +2 -1
- package/esm/testing/ng_zone_mock.js.map +1 -1
- package/esm/testing/ng_zone_mock.metadata.json +1 -1
- package/esm/testing/regexp.js +1 -1
- package/esm/testing/regexp.js.map +1 -1
- package/esm/testing/regexp.metadata.json +1 -0
- package/esm/testing/test_injector.d.ts +6 -12
- package/esm/testing/test_injector.js +4 -10
- package/esm/testing/test_injector.js.map +1 -1
- package/esm/testing/test_injector.metadata.json +1 -0
- package/esm/testing/testing.d.ts +2 -2
- package/esm/testing/testing.js +2 -2
- package/esm/testing/testing.js.map +1 -1
- package/esm/testing/testing.metadata.json +1 -1
- package/esm/testing.js.map +1 -1
- package/index.d.ts +5 -4
- package/index.js +10 -8
- package/index.js.map +1 -1
- package/package.json +5 -1
- package/private_export.d.ts +96 -11
- package/private_export.js +39 -10
- package/private_export.js.map +1 -1
- package/private_export.metadata.json +1 -1
- package/src/animation/active_animation_players_map.d.ts +11 -0
- package/src/animation/active_animation_players_map.js +54 -0
- package/src/animation/active_animation_players_map.js.map +1 -0
- package/src/animation/animation_constants.d.ts +4 -0
- package/src/animation/animation_constants.js +6 -0
- package/src/animation/animation_constants.js.map +1 -0
- package/src/animation/animation_constants.metadata.json +1 -0
- package/src/animation/animation_driver.d.ts +9 -0
- package/src/animation/animation_driver.js +25 -0
- package/src/animation/animation_driver.js.map +1 -0
- package/src/animation/animation_group_player.d.ts +18 -0
- package/src/animation/animation_group_player.js +64 -0
- package/src/animation/animation_group_player.js.map +1 -0
- package/src/animation/animation_keyframe.d.ts +6 -0
- package/src/animation/animation_keyframe.js +10 -0
- package/src/animation/animation_keyframe.js.map +1 -0
- package/src/animation/animation_player.d.ts +26 -0
- package/src/animation/animation_player.js +42 -0
- package/src/animation/animation_player.js.map +1 -0
- package/src/animation/animation_sequence_player.d.ts +21 -0
- package/src/animation/animation_sequence_player.js +69 -0
- package/src/animation/animation_sequence_player.js.map +1 -0
- package/src/animation/animation_style_util.d.ts +32 -0
- package/src/animation/animation_style_util.js +99 -0
- package/src/animation/animation_style_util.js.map +1 -0
- package/src/animation/animation_style_util.metadata.json +1 -0
- package/src/animation/animation_styles.d.ts +8 -0
- package/src/animation/animation_styles.js +9 -0
- package/src/animation/animation_styles.js.map +1 -0
- package/src/animation/metadata.d.ts +511 -0
- package/src/animation/metadata.js +627 -0
- package/src/animation/metadata.js.map +1 -0
- package/src/animation/metadata.metadata.json +1 -0
- package/src/application_common_providers.d.ts +1 -0
- package/src/application_common_providers.js +4 -3
- package/src/application_common_providers.js.map +1 -1
- package/src/application_common_providers.metadata.json +1 -1
- package/src/application_ref.d.ts +17 -41
- package/src/application_ref.js +30 -21
- package/src/application_ref.js.map +1 -1
- package/src/application_ref.metadata.json +1 -1
- package/src/application_tokens.d.ts +6 -1
- package/src/application_tokens.js +9 -4
- package/src/application_tokens.js.map +1 -1
- package/src/application_tokens.metadata.json +1 -1
- package/src/change_detection/change_detection.d.ts +9 -8
- package/src/change_detection/change_detection.js +21 -21
- package/src/change_detection/change_detection.js.map +1 -1
- package/src/change_detection/change_detection.metadata.json +1 -1
- package/src/change_detection/change_detection_util.d.ts +3 -1
- package/src/change_detection/change_detection_util.js +6 -5
- package/src/change_detection/change_detection_util.js.map +1 -1
- package/src/change_detection/change_detection_util.metadata.json +1 -1
- package/src/change_detection/change_detector_ref.d.ts +3 -0
- package/src/change_detection/change_detector_ref.js +3 -0
- package/src/change_detection/change_detector_ref.js.map +1 -1
- package/src/change_detection/constants.d.ts +1 -0
- package/src/change_detection/constants.js +4 -3
- package/src/change_detection/constants.js.map +1 -1
- package/src/change_detection/constants.metadata.json +1 -1
- package/src/change_detection/differs/default_iterable_differ.d.ts +6 -94
- package/src/change_detection/differs/default_iterable_differ.js +25 -18
- package/src/change_detection/differs/default_iterable_differ.js.map +1 -1
- package/src/change_detection/differs/default_keyvalue_differ.d.ts +3 -30
- package/src/change_detection/differs/default_keyvalue_differ.js +13 -8
- package/src/change_detection/differs/default_keyvalue_differ.js.map +1 -1
- package/src/change_detection/differs/iterable_differs.d.ts +4 -1
- package/src/change_detection/differs/iterable_differs.js +4 -3
- package/src/change_detection/differs/iterable_differs.js.map +1 -1
- package/src/change_detection/differs/keyvalue_differs.d.ts +2 -1
- package/src/change_detection/differs/keyvalue_differs.js +4 -3
- package/src/change_detection/differs/keyvalue_differs.js.map +1 -1
- package/src/change_detection/pipe_transform.js.map +1 -1
- package/src/change_detection.d.ts +1 -1
- package/src/change_detection.js +9 -9
- package/src/change_detection.js.map +1 -1
- package/src/console.js +2 -1
- package/src/console.js.map +1 -1
- package/src/console.metadata.json +1 -1
- package/src/debug/debug_node.d.ts +20 -2
- package/src/debug/debug_node.js +16 -2
- package/src/debug/debug_node.js.map +1 -1
- package/src/debug/debug_node.metadata.json +1 -0
- package/src/debug/debug_renderer.d.ts +10 -6
- package/src/debug/debug_renderer.js +12 -1
- package/src/debug/debug_renderer.js.map +1 -1
- package/src/di/decorators.d.ts +13 -1
- package/src/di/decorators.js +7 -1
- package/src/di/decorators.js.map +1 -1
- package/src/di/decorators.metadata.json +1 -1
- package/src/di/forward_ref.d.ts +3 -1
- package/src/di/forward_ref.js +3 -1
- package/src/di/forward_ref.js.map +1 -1
- package/src/di/injector.d.ts +4 -1
- package/src/di/injector.js +5 -2
- package/src/di/injector.js.map +1 -1
- package/src/di/injector.metadata.json +1 -1
- package/src/di/metadata.d.ts +8 -1
- package/src/di/metadata.js +10 -3
- package/src/di/metadata.js.map +1 -1
- package/src/di/opaque_token.d.ts +2 -1
- package/src/di/opaque_token.js +22 -21
- package/src/di/opaque_token.js.map +1 -1
- package/src/di/provider.d.ts +11 -10
- package/src/di/provider.js +17 -14
- package/src/di/provider.js.map +1 -1
- package/src/di/provider.metadata.json +1 -0
- package/src/di/provider_util.js.map +1 -1
- package/src/di/provider_util.metadata.json +1 -0
- package/src/di/reflective_exceptions.d.ts +11 -16
- package/src/di/reflective_exceptions.js +28 -22
- package/src/di/reflective_exceptions.js.map +1 -1
- package/src/di/reflective_injector.d.ts +3 -33
- package/src/di/reflective_injector.js +9 -6
- package/src/di/reflective_injector.js.map +1 -1
- package/src/di/reflective_key.d.ts +1 -8
- package/src/di/reflective_key.js +3 -2
- package/src/di/reflective_key.js.map +1 -1
- package/src/di/reflective_provider.d.ts +2 -1
- package/src/di/reflective_provider.js +6 -5
- package/src/di/reflective_provider.js.map +1 -1
- package/src/di/reflective_provider.metadata.json +1 -0
- package/src/di.d.ts +2 -2
- package/src/di.js +7 -9
- package/src/di.js.map +1 -1
- package/src/facade/async.d.ts +11 -4
- package/src/facade/async.js +27 -17
- package/src/facade/async.js.map +1 -1
- package/src/facade/base_wrapped_exception.js +4 -4
- package/src/facade/base_wrapped_exception.js.map +1 -1
- package/src/facade/collection.js.map +1 -1
- package/src/facade/collection.metadata.json +1 -1
- package/src/facade/exception_handler.d.ts +2 -11
- package/src/facade/exception_handler.js +8 -7
- package/src/facade/exception_handler.js.map +1 -1
- package/src/facade/exceptions.d.ts +4 -0
- package/src/facade/exceptions.js +6 -2
- package/src/facade/exceptions.js.map +1 -1
- package/src/facade/exceptions.metadata.json +1 -0
- package/src/facade/lang.d.ts +6 -4
- package/src/facade/lang.js +12 -11
- package/src/facade/lang.js.map +1 -1
- package/src/facade/lang.metadata.json +1 -1
- package/src/facade/math.d.ts +2 -0
- package/src/facade/math.js +5 -0
- package/src/facade/math.js.map +1 -0
- package/src/facade/math.metadata.json +1 -0
- package/src/facade/promise.js.map +1 -1
- package/src/linker/component_factory.d.ts +5 -4
- package/src/linker/component_factory.js +7 -3
- package/src/linker/component_factory.js.map +1 -1
- package/src/linker/component_resolver.d.ts +5 -4
- package/src/linker/component_resolver.js +12 -7
- package/src/linker/component_resolver.js.map +1 -1
- package/src/linker/component_resolver.metadata.json +1 -1
- package/src/linker/debug_context.js +5 -4
- package/src/linker/debug_context.js.map +1 -1
- package/src/linker/dynamic_component_loader.d.ts +5 -6
- package/src/linker/dynamic_component_loader.js +5 -3
- package/src/linker/dynamic_component_loader.js.map +1 -1
- package/src/linker/dynamic_component_loader.metadata.json +1 -1
- package/src/linker/element.d.ts +3 -3
- package/src/linker/element.js +5 -5
- package/src/linker/element.js.map +1 -1
- package/src/linker/element_injector.js.map +1 -1
- package/src/linker/element_ref.d.ts +1 -0
- package/src/linker/element_ref.js +5 -5
- package/src/linker/element_ref.js.map +1 -1
- package/src/linker/exceptions.d.ts +4 -1
- package/src/linker/exceptions.js +4 -1
- package/src/linker/exceptions.js.map +1 -1
- package/src/linker/query_list.d.ts +3 -10
- package/src/linker/query_list.js +8 -7
- package/src/linker/query_list.js.map +1 -1
- package/src/linker/systemjs_component_resolver.d.ts +21 -0
- package/src/linker/systemjs_component_resolver.js +52 -0
- package/src/linker/systemjs_component_resolver.js.map +1 -0
- package/src/linker/template_ref.d.ts +2 -1
- package/src/linker/template_ref.js +1 -0
- package/src/linker/template_ref.js.map +1 -1
- package/src/linker/view.d.ts +12 -1
- package/src/linker/view.js +65 -15
- package/src/linker/view.js.map +1 -1
- package/src/linker/view_container_ref.d.ts +2 -10
- package/src/linker/view_container_ref.js +4 -3
- package/src/linker/view_container_ref.js.map +1 -1
- package/src/linker/view_ref.d.ts +5 -1
- package/src/linker/view_ref.js +6 -2
- package/src/linker/view_ref.js.map +1 -1
- package/src/linker/view_type.js.map +1 -1
- package/src/linker/view_utils.d.ts +2 -4
- package/src/linker/view_utils.js +21 -21
- package/src/linker/view_utils.js.map +1 -1
- package/src/linker/view_utils.metadata.json +1 -1
- package/src/linker.d.ts +5 -4
- package/src/linker.js +12 -9
- package/src/linker.js.map +1 -1
- package/src/metadata/di.d.ts +8 -1
- package/src/metadata/di.js +10 -3
- package/src/metadata/di.js.map +1 -1
- package/src/metadata/directives.d.ts +104 -20
- package/src/metadata/directives.js +25 -27
- package/src/metadata/directives.js.map +1 -1
- package/src/metadata/lifecycle_hooks.d.ts +46 -31
- package/src/metadata/lifecycle_hooks.js +496 -10
- package/src/metadata/lifecycle_hooks.js.map +1 -1
- package/src/metadata/lifecycle_hooks.metadata.json +1 -1
- package/src/metadata/view.d.ts +6 -2
- package/src/metadata/view.js +3 -1
- package/src/metadata/view.js.map +1 -1
- package/src/metadata/view.metadata.json +1 -1
- package/src/metadata.d.ts +49 -15
- package/src/metadata.js +70 -37
- package/src/metadata.js.map +1 -1
- package/src/metadata.metadata.json +1 -1
- package/src/platform_common_providers.d.ts +1 -0
- package/src/platform_common_providers.js +3 -3
- package/src/platform_common_providers.js.map +1 -1
- package/src/platform_common_providers.metadata.json +1 -1
- package/src/platform_directives_and_pipes.d.ts +48 -45
- package/src/platform_directives_and_pipes.js +50 -47
- package/src/platform_directives_and_pipes.js.map +1 -1
- package/src/platform_directives_and_pipes.metadata.json +1 -1
- package/src/profile/profile.d.ts +5 -1
- package/src/profile/profile.js +5 -3
- package/src/profile/profile.js.map +1 -1
- package/src/profile/profile.metadata.json +1 -1
- package/src/profile/wtf_impl.js +1 -1
- package/src/profile/wtf_impl.js.map +1 -1
- package/src/profile/wtf_impl.metadata.json +1 -0
- package/src/profile/wtf_init.js +2 -2
- package/src/profile/wtf_init.js.map +1 -1
- package/src/reflection/platform_reflection_capabilities.d.ts +4 -3
- package/src/reflection/platform_reflection_capabilities.js.map +1 -1
- package/src/reflection/reflection.d.ts +1 -1
- package/src/reflection/reflection.js +2 -2
- package/src/reflection/reflection.js.map +1 -1
- package/src/reflection/reflection.metadata.json +1 -1
- package/src/reflection/reflection_capabilities.d.ts +4 -5
- package/src/reflection/reflection_capabilities.js +24 -10
- package/src/reflection/reflection_capabilities.js.map +1 -1
- package/src/reflection/reflector.d.ts +8 -20
- package/src/reflection/reflector.js +13 -3
- package/src/reflection/reflector.js.map +1 -1
- package/src/reflection/reflector_reader.js +3 -3
- package/src/reflection/reflector_reader.js.map +1 -1
- package/src/reflection/types.js.map +1 -1
- package/src/render/api.d.ts +17 -6
- package/src/render/api.js +8 -1
- package/src/render/api.js.map +1 -1
- package/src/render.d.ts +1 -1
- package/src/render.js +2 -2
- package/src/render.js.map +1 -1
- package/src/security.js +6 -6
- package/src/security.js.map +1 -1
- package/src/testability/testability.d.ts +3 -19
- package/src/testability/testability.js +10 -5
- package/src/testability/testability.js.map +1 -1
- package/src/testability/testability.metadata.json +1 -1
- package/src/util/decorators.d.ts +2 -1
- package/src/util/decorators.js +10 -9
- package/src/util/decorators.js.map +1 -1
- package/src/util.js.map +1 -1
- package/src/zone/ng_zone.d.ts +6 -17
- package/src/zone/ng_zone.js +11 -6
- package/src/zone/ng_zone.js.map +1 -1
- package/src/zone/ng_zone_impl.d.ts +1 -4
- package/src/zone/ng_zone_impl.js +3 -2
- package/src/zone/ng_zone_impl.js.map +1 -1
- package/src/zone.js.map +1 -1
- package/testing/async.js +20 -22
- package/testing/async.js.map +1 -1
- package/testing/async.metadata.json +1 -0
- package/testing/async_test_completer.js.map +1 -1
- package/testing/fake_async.d.ts +4 -1
- package/testing/fake_async.js +10 -2
- package/testing/fake_async.js.map +1 -1
- package/testing/lang_utils.js +1 -1
- package/testing/lang_utils.js.map +1 -1
- package/testing/lang_utils.metadata.json +1 -0
- package/testing/logger.js +5 -3
- package/testing/logger.js.map +1 -1
- package/testing/logger.metadata.json +1 -1
- package/testing/mock_application_ref.d.ts +1 -1
- package/testing/mock_application_ref.js +1 -0
- package/testing/mock_application_ref.js.map +1 -1
- package/testing/mock_application_ref.metadata.json +1 -1
- package/testing/ng_zone_mock.d.ts +0 -1
- package/testing/ng_zone_mock.js +2 -1
- package/testing/ng_zone_mock.js.map +1 -1
- package/testing/ng_zone_mock.metadata.json +1 -1
- package/testing/regexp.js +1 -1
- package/testing/regexp.js.map +1 -1
- package/testing/regexp.metadata.json +1 -0
- package/testing/test_injector.d.ts +6 -12
- package/testing/test_injector.js +3 -9
- package/testing/test_injector.js.map +1 -1
- package/testing/test_injector.metadata.json +1 -0
- package/testing/testing.d.ts +2 -2
- package/testing/testing.js +5 -5
- package/testing/testing.js.map +1 -1
- package/testing/testing.metadata.json +1 -1
- package/testing.js.map +1 -1
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { Injectable } from '../di/decorators';
|
|
2
|
+
import { PromiseWrapper } from '../facade/async';
|
|
3
|
+
import { BaseException } from '../facade/exceptions';
|
|
4
|
+
import { isBlank, isString, stringify } from '../facade/lang';
|
|
4
5
|
import { reflector } from '../reflection/reflection';
|
|
5
6
|
import { ComponentFactory } from './component_factory';
|
|
6
|
-
import { Injectable } from '../di/decorators';
|
|
7
7
|
/**
|
|
8
8
|
* Low-level service for loading {@link ComponentFactory}s, which
|
|
9
9
|
* can later be used to create and render a Component instance.
|
|
10
|
+
* @experimental
|
|
10
11
|
*/
|
|
11
12
|
export class ComponentResolver {
|
|
12
13
|
}
|
|
@@ -14,16 +15,20 @@ function _isComponentFactory(type) {
|
|
|
14
15
|
return type instanceof ComponentFactory;
|
|
15
16
|
}
|
|
16
17
|
export class ReflectorComponentResolver extends ComponentResolver {
|
|
17
|
-
resolveComponent(
|
|
18
|
-
|
|
18
|
+
resolveComponent(component) {
|
|
19
|
+
if (isString(component)) {
|
|
20
|
+
return PromiseWrapper.reject(new BaseException(`Cannot resolve component using '${component}'.`), null);
|
|
21
|
+
}
|
|
22
|
+
var metadatas = reflector.annotations(component);
|
|
19
23
|
var componentFactory = metadatas.find(_isComponentFactory);
|
|
20
24
|
if (isBlank(componentFactory)) {
|
|
21
|
-
throw new BaseException(`No precompiled component ${stringify(
|
|
25
|
+
throw new BaseException(`No precompiled component ${stringify(component)} found`);
|
|
22
26
|
}
|
|
23
27
|
return PromiseWrapper.resolve(componentFactory);
|
|
24
28
|
}
|
|
25
29
|
clearCache() { }
|
|
26
30
|
}
|
|
31
|
+
/** @nocollapse */
|
|
27
32
|
ReflectorComponentResolver.decorators = [
|
|
28
33
|
{ type: Injectable },
|
|
29
34
|
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"component_resolver.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/component_resolver.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"component_resolver.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/component_resolver.ts"],"names":[],"mappings":"OAAO,EAAC,UAAU,EAAC,MAAM,kBAAkB;OACpC,EAAC,cAAc,EAAC,MAAM,iBAAiB;OACvC,EAAC,aAAa,EAAC,MAAM,sBAAsB;OAC3C,EAAO,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAC,MAAM,gBAAgB;OAC1D,EAAC,SAAS,EAAC,MAAM,0BAA0B;OAE3C,EAAC,gBAAgB,EAAC,MAAM,qBAAqB;AAGpD;;;;GAIG;AACH;AAGA,CAAC;AAED,6BAA6B,IAAS;IACpC,MAAM,CAAC,IAAI,YAAY,gBAAgB,CAAC;AAC1C,CAAC;AACD,gDAAgD,iBAAiB;IAC/D,gBAAgB,CAAC,SAAsB;QACrC,EAAE,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;YACxB,MAAM,CAAC,cAAc,CAAC,MAAM,CACxB,IAAI,aAAa,CAAC,mCAAmC,SAAS,IAAI,CAAC,EAAE,IAAI,CAAC,CAAC;QACjF,CAAC;QAED,IAAI,SAAS,GAAG,SAAS,CAAC,WAAW,CAAO,SAAS,CAAC,CAAC;QACvD,IAAI,gBAAgB,GAAG,SAAS,CAAC,IAAI,CAAC,mBAAmB,CAAC,CAAC;QAE3D,EAAE,CAAC,CAAC,OAAO,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC;YAC9B,MAAM,IAAI,aAAa,CAAC,4BAA4B,SAAS,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;QACpF,CAAC;QACD,MAAM,CAAC,cAAc,CAAC,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAClD,CAAC;IAED,UAAU,KAAI,CAAC;AAKjB,CAAC;AAJD,kBAAkB;AACX,qCAAU,GAA0B;IAC3C,EAAE,IAAI,EAAE,UAAU,EAAE;CACnB,CACA","sourcesContent":["import {Injectable} from '../di/decorators';\nimport {PromiseWrapper} from '../facade/async';\nimport {BaseException} from '../facade/exceptions';\nimport {Type, isBlank, isString, stringify} from '../facade/lang';\nimport {reflector} from '../reflection/reflection';\n\nimport {ComponentFactory} from './component_factory';\n\n\n/**\n * Low-level service for loading {@link ComponentFactory}s, which\n * can later be used to create and render a Component instance.\n * @experimental\n */\nexport abstract class ComponentResolver {\n abstract resolveComponent(component: Type|string): Promise<ComponentFactory<any>>;\n abstract clearCache(): void;\n}\n\nfunction _isComponentFactory(type: any): boolean {\n return type instanceof ComponentFactory;\n}\nexport class ReflectorComponentResolver extends ComponentResolver {\n resolveComponent(component: Type|string): Promise<ComponentFactory<any>> {\n if (isString(component)) {\n return PromiseWrapper.reject(\n new BaseException(`Cannot resolve component using '${component}'.`), null);\n }\n\n var metadatas = reflector.annotations(<Type>component);\n var componentFactory = metadatas.find(_isComponentFactory);\n\n if (isBlank(componentFactory)) {\n throw new BaseException(`No precompiled component ${stringify(component)} found`);\n }\n return PromiseWrapper.resolve(componentFactory);\n }\n\n clearCache() {}\n/** @nocollapse */\nstatic decorators: DecoratorInvocation[] = [\n{ type: Injectable },\n];\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"__symbolic":"module","metadata":{"ReflectorComponentResolver":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","name":"Injectable","
|
|
1
|
+
{"__symbolic":"module","version":1,"metadata":{"ReflectorComponentResolver":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"../di/decorators","name":"Injectable"}}],"members":{"resolveComponent":[{"__symbolic":"method"}],"clearCache":[{"__symbolic":"method"}]}}}}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { StringMapWrapper } from '../facade/collection';
|
|
2
|
+
import { isBlank, isPresent } from '../facade/lang';
|
|
3
3
|
import { ViewType } from './view_type';
|
|
4
4
|
/* @ts2dart_const */
|
|
5
5
|
export class StaticNodeDebugInfo {
|
|
@@ -58,10 +58,11 @@ export class DebugContext {
|
|
|
58
58
|
var staticNodeInfo = this._staticNodeInfo;
|
|
59
59
|
if (isPresent(staticNodeInfo)) {
|
|
60
60
|
var refs = staticNodeInfo.refTokens;
|
|
61
|
-
StringMapWrapper.forEach(refs, (refToken
|
|
61
|
+
StringMapWrapper.forEach(refs, (refToken /** TODO #9100 */, refName /** TODO #9100 */) => {
|
|
62
62
|
var varValue;
|
|
63
63
|
if (isBlank(refToken)) {
|
|
64
|
-
varValue =
|
|
64
|
+
varValue =
|
|
65
|
+
isPresent(this._view.allNodes) ? this._view.allNodes[this._nodeIndex] : null;
|
|
65
66
|
}
|
|
66
67
|
else {
|
|
67
68
|
varValue = this._view.injectorGet(refToken, this._nodeIndex, null);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"debug_context.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/debug_context.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"debug_context.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/debug_context.ts"],"names":[],"mappings":"OACO,EAAc,gBAAgB,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C,QAAa,CAAC,iBAAiB,EAAE,OAAY,CAAC,iBAAiB;gBACpE,IAAI,QAAa,CAAmB;gBACpC,EAAE,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC;oBACtB,QAAQ;wBACJ,SAAS,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,UAAU,CAAC,GAAG,IAAI,CAAC;gBACnF,CAAC;gBAAC,IAAI,CAAC,CAAC;oBACN,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,QAAQ,EAAE,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,CAAC;gBACrE,CAAC;gBACD,SAAS,CAAC,OAAO,CAAC,GAAG,QAAQ,CAAC;YAChC,CAAC,CAAC,CAAC;QACT,CAAC;QACD,MAAM,CAAC,SAAS,CAAC;IACnB,CAAC;AACH,CAAC;AAAA","sourcesContent":["import {Injector} from '../di';\nimport {ListWrapper, StringMapWrapper} from '../facade/collection';\nimport {isBlank, isPresent} from '../facade/lang';\nimport {RenderDebugInfo} from '../render/api';\n\nimport {DebugAppView} from './view';\nimport {ViewType} from './view_type';\n\n\n/* @ts2dart_const */\nexport class StaticNodeDebugInfo {\n constructor(\n public providerTokens: any[], public componentToken: any,\n public refTokens: {[key: string]: any}) {}\n}\n\nexport class DebugContext implements RenderDebugInfo {\n constructor(\n private _view: DebugAppView<any>, private _nodeIndex: number, private _tplRow: number,\n private _tplCol: number) {}\n\n private get _staticNodeInfo(): StaticNodeDebugInfo {\n return isPresent(this._nodeIndex) ? this._view.staticNodeDebugInfos[this._nodeIndex] : null;\n }\n\n get context() { return this._view.context; }\n get component() {\n var staticNodeInfo = this._staticNodeInfo;\n if (isPresent(staticNodeInfo) && isPresent(staticNodeInfo.componentToken)) {\n return this.injector.get(staticNodeInfo.componentToken);\n }\n return null;\n }\n get componentRenderElement() {\n var componentView = this._view;\n while (isPresent(componentView.declarationAppElement) &&\n componentView.type !== ViewType.COMPONENT) {\n componentView = <DebugAppView<any>>componentView.declarationAppElement.parentView;\n }\n return isPresent(componentView.declarationAppElement) ?\n componentView.declarationAppElement.nativeElement :\n null;\n }\n get injector(): Injector { return this._view.injector(this._nodeIndex); }\n get renderNode(): any {\n if (isPresent(this._nodeIndex) && isPresent(this._view.allNodes)) {\n return this._view.allNodes[this._nodeIndex];\n } else {\n return null;\n }\n }\n get providerTokens(): any[] {\n var staticNodeInfo = this._staticNodeInfo;\n return isPresent(staticNodeInfo) ? staticNodeInfo.providerTokens : null;\n }\n get source(): string {\n return `${this._view.componentType.templateUrl}:${this._tplRow}:${this._tplCol}`;\n }\n get references(): {[key: string]: any} {\n var varValues: {[key: string]: string} = {};\n var staticNodeInfo = this._staticNodeInfo;\n if (isPresent(staticNodeInfo)) {\n var refs = staticNodeInfo.refTokens;\n StringMapWrapper.forEach(\n refs, (refToken: any /** TODO #9100 */, refName: any /** TODO #9100 */) => {\n var varValue: any /** TODO #9100 */;\n if (isBlank(refToken)) {\n varValue =\n isPresent(this._view.allNodes) ? this._view.allNodes[this._nodeIndex] : null;\n } else {\n varValue = this._view.injectorGet(refToken, this._nodeIndex, null);\n }\n varValues[refName] = varValue;\n });\n }\n return varValues;\n }\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { Injector } from '../di/injector';
|
|
2
|
+
import { ResolvedReflectiveProvider } from '../di/reflective_provider';
|
|
3
|
+
import { Type } from '../facade/lang';
|
|
3
4
|
import { ComponentRef } from './component_factory';
|
|
5
|
+
import { ComponentResolver } from './component_resolver';
|
|
4
6
|
import { ViewContainerRef } from './view_container_ref';
|
|
5
|
-
import { ResolvedReflectiveProvider } from '../di/reflective_provider';
|
|
6
|
-
import { Injector } from '../di/injector';
|
|
7
7
|
/**
|
|
8
8
|
* Use ComponentResolver and ViewContainerRef directly.
|
|
9
9
|
*
|
|
@@ -18,8 +18,7 @@ export declare abstract class DynamicComponentLoader {
|
|
|
18
18
|
*
|
|
19
19
|
* If needed, the component's selector can be overridden via `overrideSelector`.
|
|
20
20
|
*
|
|
21
|
-
*
|
|
22
|
-
* Component.
|
|
21
|
+
* A provided {@link Injector} will be used to instantiate the Component.
|
|
23
22
|
*
|
|
24
23
|
* To be notified when this Component instance is destroyed, you can also optionally provide
|
|
25
24
|
* `onDispose` callback.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ComponentResolver } from './component_resolver';
|
|
2
|
-
import { isPresent } from '../../src/facade/lang';
|
|
3
|
-
import { ReflectiveInjector } from '../di/reflective_injector';
|
|
4
1
|
import { Injectable } from '../di/decorators';
|
|
2
|
+
import { ReflectiveInjector } from '../di/reflective_injector';
|
|
3
|
+
import { isPresent } from '../facade/lang';
|
|
4
|
+
import { ComponentResolver } from './component_resolver';
|
|
5
5
|
/**
|
|
6
6
|
* Use ComponentResolver and ViewContainerRef directly.
|
|
7
7
|
*
|
|
@@ -33,9 +33,11 @@ export class DynamicComponentLoader_ extends DynamicComponentLoader {
|
|
|
33
33
|
});
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
|
+
/** @nocollapse */
|
|
36
37
|
DynamicComponentLoader_.decorators = [
|
|
37
38
|
{ type: Injectable },
|
|
38
39
|
];
|
|
40
|
+
/** @nocollapse */
|
|
39
41
|
DynamicComponentLoader_.ctorParameters = [
|
|
40
42
|
{ type: ComponentResolver, },
|
|
41
43
|
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dynamic_component_loader.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/dynamic_component_loader.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"dynamic_component_loader.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/dynamic_component_loader.ts"],"names":[],"mappings":"OAAO,EAAC,UAAU,EAAC,M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C,eAAe,CAC3B,gBAAgB,EAAE,QAAQ,CAAC,MAAM,EAAE,aAAa,EAAE,gBAAgB,CAAC,CAAC;QAC1E,CAAC,CAAC,CAAC;IACL,CAAC;AASH,CAAC;AARD,kBAAkB;AACX,kCAAU,GAA0B;IAC3C,EAAE,IAAI,EAAE,UAAU,EAAE;CACnB,CAAC;AACF,kBAAkB;AACX,sCAAc,GAA2D;IAChF,EAAC,IAAI,EAAE,iBAAiB,GAAG;CAC1B,CACA","sourcesContent":["import {Injectable} from '../di/decorators';\nimport {Injector} from '../di/injector';\nimport {ReflectiveInjector} from '../di/reflective_injector';\nimport {ResolvedReflectiveProvider} from '../di/reflective_provider';\nimport {Type, isPresent} from '../facade/lang';\n\nimport {ComponentRef} from './component_factory';\nimport {ComponentResolver} from './component_resolver';\nimport {ViewContainerRef} from './view_container_ref';\n\n\n/**\n * Use ComponentResolver and ViewContainerRef directly.\n *\n * @deprecated\n */\nexport abstract class DynamicComponentLoader {\n /**\n * Creates an instance of a Component `type` and attaches it to the first element in the\n * platform-specific global view that matches the component's selector.\n *\n * In a browser the platform-specific global view is the main DOM Document.\n *\n * If needed, the component's selector can be overridden via `overrideSelector`.\n *\n * A provided {@link Injector} will be used to instantiate the Component.\n *\n * To be notified when this Component instance is destroyed, you can also optionally provide\n * `onDispose` callback.\n *\n * Returns a promise for the {@link ComponentRef} representing the newly created Component.\n *\n * ### Example\n *\n * ```\n * @Component({\n * selector: 'child-component',\n * template: 'Child'\n * })\n * class ChildComponent {\n * }\n *\n * @Component({\n * selector: 'my-app',\n * template: 'Parent (<child id=\"child\"></child>)'\n * })\n * class MyApp {\n * constructor(dcl: DynamicComponentLoader, injector: Injector) {\n * dcl.loadAsRoot(ChildComponent, '#child', injector);\n * }\n * }\n *\n * bootstrap(MyApp);\n * ```\n *\n * Resulting DOM:\n *\n * ```\n * <my-app>\n * Parent (\n * <child id=\"child\">Child</child>\n * )\n * </my-app>\n * ```\n */\n abstract loadAsRoot(\n type: Type, overrideSelectorOrNode: string|any, injector: Injector, onDispose?: () => void,\n projectableNodes?: any[][]): Promise<ComponentRef<any>>;\n\n\n /**\n * Creates an instance of a Component and attaches it to the View Container found at the\n * `location` specified as {@link ViewContainerRef}.\n *\n * You can optionally provide `providers` to configure the {@link Injector} provisioned for this\n * Component Instance.\n *\n * Returns a promise for the {@link ComponentRef} representing the newly created Component.\n *\n *\n * ### Example\n *\n * ```\n * @Component({\n * selector: 'child-component',\n * template: 'Child'\n * })\n * class ChildComponent {\n * }\n *\n * @Component({\n * selector: 'my-app',\n * template: 'Parent'\n * })\n * class MyApp {\n * constructor(dcl: DynamicComponentLoader, viewContainerRef: ViewContainerRef) {\n * dcl.loadNextToLocation(ChildComponent, viewContainerRef);\n * }\n * }\n *\n * bootstrap(MyApp);\n * ```\n *\n * Resulting DOM:\n *\n * ```\n * <my-app>Parent</my-app>\n * <child-component>Child</child-component>\n * ```\n */\n abstract loadNextToLocation(\n type: Type, location: ViewContainerRef, providers?: ResolvedReflectiveProvider[],\n projectableNodes?: any[][]): Promise<ComponentRef<any>>;\n}\nexport class DynamicComponentLoader_ extends DynamicComponentLoader {\n constructor(private _compiler: ComponentResolver) { super(); }\n\n loadAsRoot(\n type: Type, overrideSelectorOrNode: string|any, injector: Injector, onDispose?: () => void,\n projectableNodes?: any[][]): Promise<ComponentRef<any>> {\n return this._compiler.resolveComponent(type).then(componentFactory => {\n var componentRef = componentFactory.create(\n injector, projectableNodes,\n isPresent(overrideSelectorOrNode) ? overrideSelectorOrNode : componentFactory.selector);\n if (isPresent(onDispose)) {\n componentRef.onDestroy(onDispose);\n }\n return componentRef;\n });\n }\n\n loadNextToLocation(\n type: Type, location: ViewContainerRef, providers: ResolvedReflectiveProvider[] = null,\n projectableNodes: any[][] = null): Promise<ComponentRef<any>> {\n return this._compiler.resolveComponent(type).then(componentFactory => {\n var contextInjector = location.parentInjector;\n var childInjector = isPresent(providers) && providers.length > 0 ?\n ReflectiveInjector.fromResolvedProviders(providers, contextInjector) :\n contextInjector;\n return location.createComponent(\n componentFactory, location.length, childInjector, projectableNodes);\n });\n }\n/** @nocollapse */\nstatic decorators: DecoratorInvocation[] = [\n{ type: Injectable },\n];\n/** @nocollapse */\nstatic ctorParameters: {type: Function, decorators?: DecoratorInvocation[]}[] = [\n{type: ComponentResolver, },\n];\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"__symbolic":"module","metadata":{"DynamicComponentLoader_":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","
|
|
1
|
+
{"__symbolic":"module","version":1,"metadata":{"DynamicComponentLoader_":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"../di/decorators","name":"Injectable"}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","module":"./component_resolver","name":"ComponentResolver"}]}],"loadAsRoot":[{"__symbolic":"method"}],"loadNextToLocation":[{"__symbolic":"method"}]}}}}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Injector } from '../di/injector';
|
|
2
2
|
import { ElementRef } from './element_ref';
|
|
3
|
-
import { ViewContainerRef_ } from './view_container_ref';
|
|
4
3
|
import { QueryList } from './query_list';
|
|
5
|
-
import {
|
|
4
|
+
import { AppView } from './view';
|
|
5
|
+
import { ViewContainerRef_ } from './view_container_ref';
|
|
6
6
|
/**
|
|
7
7
|
* An AppElement is created for elements that have a ViewContainerRef,
|
|
8
8
|
* a nested component or a <template> element to keep data around
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { ViewType } from './view_type';
|
|
1
|
+
import { ListWrapper } from '../facade/collection';
|
|
2
|
+
import { BaseException } from '../facade/exceptions';
|
|
3
|
+
import { isPresent } from '../facade/lang';
|
|
5
4
|
import { ElementRef } from './element_ref';
|
|
6
5
|
import { ViewContainerRef_ } from './view_container_ref';
|
|
6
|
+
import { ViewType } from './view_type';
|
|
7
7
|
/**
|
|
8
8
|
* An AppElement is created for elements that have a ViewContainerRef,
|
|
9
9
|
* a nested component or a <template> element to keep data around
|
|
@@ -66,7 +66,7 @@ export class AppElement {
|
|
|
66
66
|
if (view.type === ViewType.COMPONENT) {
|
|
67
67
|
throw new BaseException(`Component views can't be moved!`);
|
|
68
68
|
}
|
|
69
|
-
view.
|
|
69
|
+
view.detach();
|
|
70
70
|
view.removeFromContentChildren(this);
|
|
71
71
|
return view;
|
|
72
72
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"element.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/element.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"element.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/element.ts"],"names":[],"mappings":"OACO,EAAC,WAAW,EAAC,MAAM,sBAAsB;OACzC,EAAC,aAAa,EAAC,MAAM,sBAAsB;OAC3C,EAAC,SAAS,EAAC,MAAM,gBAAgB;OAEjC,EAAC,UAAU,EAAC,MAAM,eAAe;OAGjC,EAAC,iBAAiB,EAAC,MAAM,sBAAsB;OAC/C,EAAC,QAAQ,EAAC,MAAM,aAAa;AAGpC;;;;GAIG;AACH;IAOE,YACW,KAAa,EAAS,WAAmB,EAAS,UAAwB,EAC1E,aAAkB;QADlB,UAAK,GAAL,KAAK,CAAQ;QAAS,gBAAW,GAAX,WAAW,CAAQ;QAAS,eAAU,GAAV,UAAU,CAAc;QAC1E,kBAAa,GAAb,aAAa,CAAK;QARtB,gBAAW,GAAmB,IAAI,CAAC;QACnC,kBAAa,GAAiB,IAAI,CAAC;IAOV,CAAC;IAEjC,IAAI,UAAU,KAAiB,MAAM,CAAC,IAAI,UAAU,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;IAE3E,IAAI,KAAK,KAAwB,MAAM,CAAC,IAAI,iBAAiB,CA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,IAAI,CAAC,WAAW,GAAG,WAAW,CAAC;QACjC,CAAC;QACD,WAAW,CAAC,MAAM,CAAC,WAAW,EAAE,SAAS,EAAE,IAAI,CAAC,CAAC;QACjD,IAAI,aAAkB,CAAmB;QACzC,EAAE,CAAC,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC,CAAC;YAClB,IAAI,QAAQ,GAAG,WAAW,CAAC,SAAS,GAAG,CAAC,CAAC,CAAC;YAC1C,aAAa,GAAG,QAAQ,CAAC,YAAY,CAAC;QACxC,CAAC;QAAC,IAAI,CAAC,CAAC;YACN,aAAa,GAAG,IAAI,CAAC,aAAa,CAAC;QACrC,CAAC;QACD,EAAE,CAAC,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC;YAC7B,IAAI,CAAC,QAAQ,CAAC,eAAe,CAAC,aAAa,EAAE,IAAI,CAAC,aAAa,CAAC,CAAC;QACnE,CAAC;QACD,IAAI,CAAC,oBAAoB,CAAC,IAAI,CAAC,CAAC;IAClC,CAAC;IAED,UAAU,CAAC,SAAiB;QAC1B,IAAI,IAAI,GAAG,WAAW,CAAC,QAAQ,CAAC,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,CAAC;QAC7D,EAAE,CAAC,CAAC,IAAI,CAAC,IAAI,KAAK,QAAQ,CAAC,SAAS,CAAC,CAAC,CAAC;YACrC,MAAM,IAAI,aAAa,CAAC,iCAAiC,CAAC,CAAC;QAC7D,CAAC;QACD,IAAI,CAAC,MAAM,EAAE,CAAC;QAEd,IAAI,CAAC,yBAAyB,CAAC,IAAI,CAAC,CAAC;QACrC,MAAM,CAAC,IAAI,CAAC;IACd,CAAC;AACH,CAAC;AAAA","sourcesContent":["import {Injector} from '../di/injector';\nimport {ListWrapper} from '../facade/collection';\nimport {BaseException} from '../facade/exceptions';\nimport {isPresent} from '../facade/lang';\n\nimport {ElementRef} from './element_ref';\nimport {QueryList} from './query_list';\nimport {AppView} from './view';\nimport {ViewContainerRef_} from './view_container_ref';\nimport {ViewType} from './view_type';\n\n\n/**\n * An AppElement is created for elements that have a ViewContainerRef,\n * a nested component or a <template> element to keep data around\n * that is needed for later instantiations.\n */\nexport class AppElement {\n public nestedViews: AppView<any>[] = null;\n public componentView: AppView<any> = null;\n\n public component: any;\n public componentConstructorViewQueries: QueryList<any>[];\n\n constructor(\n public index: number, public parentIndex: number, public parentView: AppView<any>,\n public nativeElement: any) {}\n\n get elementRef(): ElementRef { return new ElementRef(this.nativeElement); }\n\n get vcRef(): ViewContainerRef_ { return new ViewContainerRef_(this); }\n\n initComponent(\n component: any, componentConstructorViewQueries: QueryList<any>[], view: AppView<any>) {\n this.component = component;\n this.componentConstructorViewQueries = componentConstructorViewQueries;\n this.componentView = view;\n }\n\n get parentInjector(): Injector { return this.parentView.injector(this.parentIndex); }\n get injector(): Injector { return this.parentView.injector(this.index); }\n\n mapNestedViews(nestedViewClass: any, callback: Function): any[] {\n var result: any[] /** TODO #9100 */ = [];\n if (isPresent(this.nestedViews)) {\n this.nestedViews.forEach((nestedView) => {\n if (nestedView.clazz === nestedViewClass) {\n result.push(callback(nestedView));\n }\n });\n }\n return result;\n }\n\n\n attachView(view: AppView<any>, viewIndex: number) {\n if (view.type === ViewType.COMPONENT) {\n throw new BaseException(`Component views can't be moved!`);\n }\n var nestedViews = this.nestedViews;\n if (nestedViews == null) {\n nestedViews = [];\n this.nestedViews = nestedViews;\n }\n ListWrapper.insert(nestedViews, viewIndex, view);\n var refRenderNode: any /** TODO #9100 */;\n if (viewIndex > 0) {\n var prevView = nestedViews[viewIndex - 1];\n refRenderNode = prevView.lastRootNode;\n } else {\n refRenderNode = this.nativeElement;\n }\n if (isPresent(refRenderNode)) {\n view.renderer.attachViewAfter(refRenderNode, view.flatRootNodes);\n }\n view.addToContentChildren(this);\n }\n\n detachView(viewIndex: number): AppView<any> {\n var view = ListWrapper.removeAt(this.nestedViews, viewIndex);\n if (view.type === ViewType.COMPONENT) {\n throw new BaseException(`Component views can't be moved!`);\n }\n view.detach();\n\n view.removeFromContentChildren(this);\n return view;\n }\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"element_injector.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/element_injector.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"element_injector.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/element_injector.ts"],"names":[],"mappings":"OAAO,EAAC,QAAQ,EAAE,kBAAkB,EAAC,MAAM,gBAAgB;AAG3D,MAAM,UAAU,GAAsB,IAAI,MAAM,EAAE,CAAC;AAEnD,qCAAqC,QAAQ;IAC3C,YAAoB,KAAmB,EAAU,UAAkB;QAAI,OAAO,CAAC;QAA3D,UAAK,GAAL,KAAK,CAAc;QAAU,eAAU,GAAV,UAAU,CAAQ;IAAa,CAAC;IAEjF,GAAG,CAAC,KAAU,EAAE,aAAa,GAAQ,kBAAkB;QACrD,IAAI,MAAM,GAAG,UAAU,CAAC;QACxB,EAAE,CAAC,CAAC,MAAM,KAAK,UAAU,CAAC,CAAC,CAAC;YAC1B,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,EAAE,UAAU,CAAC,CAAC;QACtE,CAAC;QACD,EAAE,CAAC,CAAC,MAAM,KAAK,UAAU,CAAC,CAAC,CAAC;YAC1B,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,GAAG,CAAC,KAAK,EAAE,aAAa,CAAC,CAAC;QAC/D,CAAC;QACD,MAAM,CAAC,MAAM,CAAC;IAChB,CAAC;AACH,CAAC;AAAA","sourcesContent":["import {Injector, THROW_IF_NOT_FOUND} from '../di/injector';\nimport {AppView} from './view';\n\nconst _UNDEFINED = /*@ts2dart_const*/ new Object();\n\nexport class ElementInjector extends Injector {\n constructor(private _view: AppView<any>, private _nodeIndex: number) { super(); }\n\n get(token: any, notFoundValue: any = THROW_IF_NOT_FOUND): any {\n var result = _UNDEFINED;\n if (result === _UNDEFINED) {\n result = this._view.injectorGet(token, this._nodeIndex, _UNDEFINED);\n }\n if (result === _UNDEFINED) {\n result = this._view.parentInjector.get(token, notFoundValue);\n }\n return result;\n }\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* A wrapper around a native element inside of a View.
|
|
3
|
-
*
|
|
4
|
-
* An `ElementRef` is backed by a render-specific element. In the browser, this is usually a DOM
|
|
5
|
-
* element.
|
|
6
|
-
*/
|
|
2
|
+
* A wrapper around a native element inside of a View.
|
|
3
|
+
*
|
|
4
|
+
* An `ElementRef` is backed by a render-specific element. In the browser, this is usually a DOM
|
|
5
|
+
* element.
|
|
6
|
+
*/
|
|
7
7
|
// Note: We don't expose things like `Injector`, `ViewContainer`, ... here,
|
|
8
8
|
// i.e. users have to ask for what they need. With that, we can build better analysis tools
|
|
9
9
|
// and could do better codegen in the future.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"element_ref.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/element_ref.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"element_ref.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/element_ref.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,2EAA2E;AAC3E,2FAA2F;AAC3F,6CAA6C;AAC7C;IAuBE,YAAY,aAAkB;QAAI,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;IAAC,CAAC;AACzE,CAAC;AAAA","sourcesContent":["/**\n * A wrapper around a native element inside of a View.\n *\n * An `ElementRef` is backed by a render-specific element. In the browser, this is usually a DOM\n * element.\n */\n// Note: We don't expose things like `Injector`, `ViewContainer`, ... here,\n// i.e. users have to ask for what they need. With that, we can build better analysis tools\n// and could do better codegen in the future.\nexport class ElementRef {\n /**\n * The underlying native element or `null` if direct access to native elements is not supported\n * (e.g. when the application runs in a web worker).\n *\n * <div class=\"callout is-critical\">\n * <header>Use with caution</header>\n * <p>\n * Use this API as the last resort when direct access to DOM is needed. Use templating and\n * data-binding provided by Angular instead. Alternatively you take a look at {@link Renderer}\n * which provides API that can safely be used even when direct access to native elements is not\n * supported.\n * </p>\n * <p>\n * Relying on direct DOM access creates tight coupling between your application and rendering\n * layers which will make it impossible to separate the two and deploy your application into a\n * web worker.\n * </p>\n * </div>\n * @stable\n */\n public nativeElement: any;\n\n constructor(nativeElement: any) { this.nativeElement = nativeElement; }\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BaseException, WrappedException } from '
|
|
1
|
+
import { BaseException, WrappedException } from '../facade/exceptions';
|
|
2
2
|
/**
|
|
3
3
|
* An error thrown if application changes model breaking the top-down data flow.
|
|
4
4
|
*
|
|
@@ -31,6 +31,7 @@ import { BaseException, WrappedException } from '../../src/facade/exceptions';
|
|
|
31
31
|
* }
|
|
32
32
|
* }
|
|
33
33
|
* ```
|
|
34
|
+
* @stable
|
|
34
35
|
*/
|
|
35
36
|
export declare class ExpressionChangedAfterItHasBeenCheckedException extends BaseException {
|
|
36
37
|
constructor(oldValue: any, currValue: any, context: any);
|
|
@@ -40,6 +41,7 @@ export declare class ExpressionChangedAfterItHasBeenCheckedException extends Bas
|
|
|
40
41
|
*
|
|
41
42
|
* This error wraps the original exception to attach additional contextual information that can
|
|
42
43
|
* be useful for debugging.
|
|
44
|
+
* @stable
|
|
43
45
|
*/
|
|
44
46
|
export declare class ViewWrappedException extends WrappedException {
|
|
45
47
|
constructor(originalException: any, originalStack: any, context: any);
|
|
@@ -50,6 +52,7 @@ export declare class ViewWrappedException extends WrappedException {
|
|
|
50
52
|
* This error indicates a bug in the framework.
|
|
51
53
|
*
|
|
52
54
|
* This is an internal Angular error.
|
|
55
|
+
* @stable
|
|
53
56
|
*/
|
|
54
57
|
export declare class ViewDestroyedException extends BaseException {
|
|
55
58
|
constructor(details: string);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BaseException, WrappedException } from '
|
|
1
|
+
import { BaseException, WrappedException } from '../facade/exceptions';
|
|
2
2
|
/**
|
|
3
3
|
* An error thrown if application changes model breaking the top-down data flow.
|
|
4
4
|
*
|
|
@@ -31,6 +31,7 @@ import { BaseException, WrappedException } from '../../src/facade/exceptions';
|
|
|
31
31
|
* }
|
|
32
32
|
* }
|
|
33
33
|
* ```
|
|
34
|
+
* @stable
|
|
34
35
|
*/
|
|
35
36
|
export class ExpressionChangedAfterItHasBeenCheckedException extends BaseException {
|
|
36
37
|
constructor(oldValue, currValue, context) {
|
|
@@ -43,6 +44,7 @@ export class ExpressionChangedAfterItHasBeenCheckedException extends BaseExcepti
|
|
|
43
44
|
*
|
|
44
45
|
* This error wraps the original exception to attach additional contextual information that can
|
|
45
46
|
* be useful for debugging.
|
|
47
|
+
* @stable
|
|
46
48
|
*/
|
|
47
49
|
export class ViewWrappedException extends WrappedException {
|
|
48
50
|
constructor(originalException, originalStack, context) {
|
|
@@ -55,6 +57,7 @@ export class ViewWrappedException extends WrappedException {
|
|
|
55
57
|
* This error indicates a bug in the framework.
|
|
56
58
|
*
|
|
57
59
|
* This is an internal Angular error.
|
|
60
|
+
* @stable
|
|
58
61
|
*/
|
|
59
62
|
export class ViewDestroyedException extends BaseException {
|
|
60
63
|
constructor(details) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"exceptions.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/exceptions.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"exceptions.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/exceptions.ts"],"names":[],"mappings":"OAAO,EAAC,aAAa,EAAE,gBAAgB,EAAC,MAAM,sBAAsB;AAEpE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,qEAAqE,aAAa;IAChF,YAAY,QAAa,EAAE,SAAc,EAAE,OAAY;QACrD,MACI,+CAA+C;YAC/C,oBAAoB,QAAQ,sBAAsB,SAAS,GAAG,CAAC,CAAC;IACtE,CAAC;AACH,CAAC;AAED;;;;;;GAMG;AACH,0CAA0C,gBAAgB;IACxD,YAAY,iBAAsB,EAAE,aAAkB,EAAE,OAAY;QAClE,MAAM,YAAY,OAAO,CAAC,MAAM,EAAE,EAAE,iBAAiB,EAAE,aAAa,EAAE,OAAO,CAAC,CAAC;IACjF,CAAC;AACH,CAAC;AAED;;;;;;;GAOG;AACH,4CAA4C,aAAa;IACvD,YAAY,OAAe;QAAI,MAAM,oCAAoC,OAAO,EAAE,CAAC,CAAC;IAAC,CAAC;AACxF,CAAC;AAAA","sourcesContent":["import {BaseException, WrappedException} from '../facade/exceptions';\n\n/**\n * An error thrown if application changes model breaking the top-down data flow.\n *\n * This exception is only thrown in dev mode.\n *\n * <!-- TODO: Add a link once the dev mode option is configurable -->\n *\n * ### Example\n *\n * ```typescript\n * @Component({\n * selector: 'parent',\n * template: `\n * <child [prop]=\"parentProp\"></child>\n * `,\n * directives: [forwardRef(() => Child)]\n * })\n * class Parent {\n * parentProp = \"init\";\n * }\n *\n * @Directive({selector: 'child', inputs: ['prop']})\n * class Child {\n * constructor(public parent: Parent) {}\n *\n * set prop(v) {\n * // this updates the parent property, which is disallowed during change detection\n * // this will result in ExpressionChangedAfterItHasBeenCheckedException\n * this.parent.parentProp = \"updated\";\n * }\n * }\n * ```\n * @stable\n */\nexport class ExpressionChangedAfterItHasBeenCheckedException extends BaseException {\n constructor(oldValue: any, currValue: any, context: any) {\n super(\n `Expression has changed after it was checked. ` +\n `Previous value: '${oldValue}'. Current value: '${currValue}'`);\n }\n}\n\n/**\n * Thrown when an exception was raised during view creation, change detection or destruction.\n *\n * This error wraps the original exception to attach additional contextual information that can\n * be useful for debugging.\n * @stable\n */\nexport class ViewWrappedException extends WrappedException {\n constructor(originalException: any, originalStack: any, context: any) {\n super(`Error in ${context.source}`, originalException, originalStack, context);\n }\n}\n\n/**\n * Thrown when a destroyed view is used.\n *\n * This error indicates a bug in the framework.\n *\n * This is an internal Angular error.\n * @stable\n */\nexport class ViewDestroyedException extends BaseException {\n constructor(details: string) { super(`Attempt to use a destroyed view: ${details}`); }\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Observable } from '
|
|
1
|
+
import { Observable } from '../facade/async';
|
|
2
2
|
/**
|
|
3
3
|
* An unmodifiable list of items that Angular keeps up to date when the state
|
|
4
4
|
* of the application changes.
|
|
@@ -17,11 +17,10 @@ import { Observable } from '../../src/facade/async';
|
|
|
17
17
|
* ```typescript
|
|
18
18
|
* @Component({...})
|
|
19
19
|
* class Container {
|
|
20
|
-
*
|
|
21
|
-
* items.changes.subscribe(_ => console.log(items.length));
|
|
22
|
-
* }
|
|
20
|
+
* @ViewChildren(Item) items:QueryList<Item>;
|
|
23
21
|
* }
|
|
24
22
|
* ```
|
|
23
|
+
* @stable
|
|
25
24
|
*/
|
|
26
25
|
export declare class QueryList<T> {
|
|
27
26
|
private _dirty;
|
|
@@ -52,12 +51,6 @@ export declare class QueryList<T> {
|
|
|
52
51
|
*/
|
|
53
52
|
toArray(): T[];
|
|
54
53
|
toString(): string;
|
|
55
|
-
/**
|
|
56
|
-
* @internal
|
|
57
|
-
*/
|
|
58
|
-
reset(res: Array<T | any[]>): void;
|
|
59
|
-
/** @internal */
|
|
60
|
-
notifyOnChanges(): void;
|
|
61
54
|
/** internal */
|
|
62
55
|
setDirty(): void;
|
|
63
56
|
/** internal */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { EventEmitter } from '../facade/async';
|
|
2
|
+
import { ListWrapper } from '../facade/collection';
|
|
3
|
+
import { getSymbolIterator } from '../facade/lang';
|
|
4
4
|
/**
|
|
5
5
|
* An unmodifiable list of items that Angular keeps up to date when the state
|
|
6
6
|
* of the application changes.
|
|
@@ -19,11 +19,10 @@ import { EventEmitter } from '../../src/facade/async';
|
|
|
19
19
|
* ```typescript
|
|
20
20
|
* @Component({...})
|
|
21
21
|
* class Container {
|
|
22
|
-
*
|
|
23
|
-
* items.changes.subscribe(_ => console.log(items.length));
|
|
24
|
-
* }
|
|
22
|
+
* @ViewChildren(Item) items:QueryList<Item>;
|
|
25
23
|
* }
|
|
26
24
|
* ```
|
|
25
|
+
* @stable
|
|
27
26
|
*/
|
|
28
27
|
export class QueryList {
|
|
29
28
|
constructor() {
|
|
@@ -55,7 +54,9 @@ export class QueryList {
|
|
|
55
54
|
* converts QueryList into an array
|
|
56
55
|
*/
|
|
57
56
|
toArray() { return ListWrapper.clone(this._results); }
|
|
58
|
-
[getSymbolIterator()]() {
|
|
57
|
+
[getSymbolIterator()]() {
|
|
58
|
+
return this._results[getSymbolIterator()]();
|
|
59
|
+
}
|
|
59
60
|
toString() { return this._results.toString(); }
|
|
60
61
|
/**
|
|
61
62
|
* @internal
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"query_list.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/query_list.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"query_list.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/query_list.ts"],"names":[],"mappings":"OAAO,EAAC,YAAY,EAAa,MAAM,iBAAiB;OACjD,EAAC,WAAW,EAAC,MAAM,sBAAsB;OACzC,EAAC,iBAAiB,EAAC,MAAM,gBAAgB;AAIhD;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH;IAAA;QACU,WAAM,GAAG,IAAI,CAAC;QACd,aAAQ,GAAa,EAAE,CAAC;QACxB,aAAQ,GAAG,IAAI,YAAY,EAAE,CAAC;IAsDxC,CAAC;IApDC,IAAI,OAAO,KAAsB,MAAM,CAAC,IAAI,CAAC,Q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O,CAAC,GAAG,CAAC,CAAC;QACzC,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC;IACtB,CAAC;IAED,gBAAgB;IAChB,eAAe,KAAW,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IAErD,eAAe;IACf,QAAQ,KAAK,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC;IAElC,eAAe;IACf,IAAI,KAAK,KAAK,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;AACrC,CAAC;AAAA","sourcesContent":["import {EventEmitter, Observable} from '../facade/async';\nimport {ListWrapper} from '../facade/collection';\nimport {getSymbolIterator} from '../facade/lang';\n\n\n\n/**\n * An unmodifiable list of items that Angular keeps up to date when the state\n * of the application changes.\n *\n * The type of object that {@link QueryMetadata} and {@link ViewQueryMetadata} provide.\n *\n * Implements an iterable interface, therefore it can be used in both ES6\n * javascript `for (var i of items)` loops as well as in Angular templates with\n * `*ngFor=\"let i of myList\"`.\n *\n * Changes can be observed by subscribing to the changes `Observable`.\n *\n * NOTE: In the future this class will implement an `Observable` interface.\n *\n * ### Example ([live demo](http://plnkr.co/edit/RX8sJnQYl9FWuSCWme5z?p=preview))\n * ```typescript\n * @Component({...})\n * class Container {\n * @ViewChildren(Item) items:QueryList<Item>;\n * }\n * ```\n * @stable\n */\nexport class QueryList<T> {\n private _dirty = true;\n private _results: Array<T> = [];\n private _emitter = new EventEmitter();\n\n get changes(): Observable<any> { return this._emitter; }\n get length(): number { return this._results.length; }\n get first(): T { return ListWrapper.first(this._results); }\n get last(): T { return ListWrapper.last(this._results); }\n\n /**\n * returns a new array with the passed in function applied to each element.\n */\n map<U>(fn: (item: T) => U): U[] { return this._results.map(fn); }\n\n /**\n * returns a filtered array.\n */\n filter(fn: (item: T) => boolean): T[] { return this._results.filter(fn); }\n\n /**\n * returns a reduced value.\n */\n reduce<U>(fn: (acc: U, item: T) => U, init: U): U { return this._results.reduce(fn, init); }\n\n /**\n * executes function for each element in a query.\n */\n forEach(fn: (item: T) => void): void { this._results.forEach(fn); }\n\n /**\n * converts QueryList into an array\n */\n toArray(): T[] { return ListWrapper.clone(this._results); }\n\n [getSymbolIterator()](): any {\n return (this._results as any /** TODO #???? */)[getSymbolIterator()]();\n }\n\n toString(): string { return this._results.toString(); }\n\n /**\n * @internal\n */\n reset(res: Array<T|any[]>): void {\n this._results = ListWrapper.flatten(res);\n this._dirty = false;\n }\n\n /** @internal */\n notifyOnChanges(): void { this._emitter.emit(this); }\n\n /** internal */\n setDirty() { this._dirty = true; }\n\n /** internal */\n get dirty() { return this._dirty; }\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { Type } from '../facade/lang';
|
|
2
|
+
import { ComponentFactory } from './component_factory';
|
|
3
|
+
import { ComponentResolver } from './component_resolver';
|
|
4
|
+
/**
|
|
5
|
+
* Component resolver that can load components lazily
|
|
6
|
+
* @experimental
|
|
7
|
+
*/
|
|
8
|
+
export declare class SystemJsComponentResolver implements ComponentResolver {
|
|
9
|
+
private _resolver;
|
|
10
|
+
constructor(_resolver: ComponentResolver);
|
|
11
|
+
resolveComponent(componentType: string | Type): Promise<ComponentFactory<any>>;
|
|
12
|
+
clearCache(): void;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Component resolver that can load component factories lazily
|
|
16
|
+
* @experimental
|
|
17
|
+
*/
|
|
18
|
+
export declare class SystemJsCmpFactoryResolver implements ComponentResolver {
|
|
19
|
+
resolveComponent(componentType: string | Type): Promise<ComponentFactory<any>>;
|
|
20
|
+
clearCache(): void;
|
|
21
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { global, isString } from '../facade/lang';
|
|
2
|
+
const _SEPARATOR = '#';
|
|
3
|
+
/**
|
|
4
|
+
* Component resolver that can load components lazily
|
|
5
|
+
* @experimental
|
|
6
|
+
*/
|
|
7
|
+
export class SystemJsComponentResolver {
|
|
8
|
+
constructor(_resolver) {
|
|
9
|
+
this._resolver = _resolver;
|
|
10
|
+
}
|
|
11
|
+
resolveComponent(componentType) {
|
|
12
|
+
if (isString(componentType)) {
|
|
13
|
+
let [module, component] = componentType.split(_SEPARATOR);
|
|
14
|
+
if (component === void (0)) {
|
|
15
|
+
// Use the default export when no component is specified
|
|
16
|
+
component = 'default';
|
|
17
|
+
}
|
|
18
|
+
return global
|
|
19
|
+
.System.import(module)
|
|
20
|
+
.then((module) => this._resolver.resolveComponent(module[component]));
|
|
21
|
+
}
|
|
22
|
+
return this._resolver.resolveComponent(componentType);
|
|
23
|
+
}
|
|
24
|
+
clearCache() { }
|
|
25
|
+
}
|
|
26
|
+
const FACTORY_MODULE_SUFFIX = '.ngfactory';
|
|
27
|
+
const FACTORY_CLASS_SUFFIX = 'NgFactory';
|
|
28
|
+
/**
|
|
29
|
+
* Component resolver that can load component factories lazily
|
|
30
|
+
* @experimental
|
|
31
|
+
*/
|
|
32
|
+
export class SystemJsCmpFactoryResolver {
|
|
33
|
+
resolveComponent(componentType) {
|
|
34
|
+
if (isString(componentType)) {
|
|
35
|
+
let [module, factory] = componentType.split(_SEPARATOR);
|
|
36
|
+
return global
|
|
37
|
+
.System.import(module + FACTORY_MODULE_SUFFIX)
|
|
38
|
+
.then((module) => module[factory + FACTORY_CLASS_SUFFIX]);
|
|
39
|
+
}
|
|
40
|
+
return Promise.resolve(null);
|
|
41
|
+
}
|
|
42
|
+
clearCache() { }
|
|
43
|
+
}
|
|
44
|
+
//# sourceMappingURL=systemjs_component_resolver.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"systemjs_component_resolver.js","sourceRoot":"","sources":["../../../../../../modules/@angular/core/src/linker/systemjs_component_resolver.ts"],"names":[],"mappings":"OAAO,EAAO,MAAM,EAAE,QAAQ,EAAC,MAAM,gBAAgB;AAKrD,MAAM,UAAU,GAAG,GAAG,CAAC;AAEvB;;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AC,CAAC;IAC/B,CAAC;IAED,UAAU,KAAU,CAAC;AACvB,CAAC;AAAA","sourcesContent":["import {Type, global, isString} from '../facade/lang';\n\nimport {ComponentFactory} from './component_factory';\nimport {ComponentResolver} from './component_resolver';\n\nconst _SEPARATOR = '#';\n\n/**\n * Component resolver that can load components lazily\n * @experimental\n */\nexport class SystemJsComponentResolver implements ComponentResolver {\n constructor(private _resolver: ComponentResolver) {}\n\n resolveComponent(componentType: string|Type): Promise<ComponentFactory<any>> {\n if (isString(componentType)) {\n let [module, component] = componentType.split(_SEPARATOR);\n\n if (component === void(0)) {\n // Use the default export when no component is specified\n component = 'default';\n }\n\n return (<any>global)\n .System.import(module)\n .then((module: any) => this._resolver.resolveComponent(module[component]));\n }\n\n return this._resolver.resolveComponent(componentType);\n }\n\n clearCache(): void {}\n}\n\nconst FACTORY_MODULE_SUFFIX = '.ngfactory';\nconst FACTORY_CLASS_SUFFIX = 'NgFactory';\n\n/**\n * Component resolver that can load component factories lazily\n * @experimental\n */\nexport class SystemJsCmpFactoryResolver implements ComponentResolver {\n resolveComponent(componentType: string|Type): Promise<ComponentFactory<any>> {\n if (isString(componentType)) {\n let [module, factory] = componentType.split(_SEPARATOR);\n return (<any>global)\n .System.import(module + FACTORY_MODULE_SUFFIX)\n .then((module: any) => module[factory + FACTORY_CLASS_SUFFIX]);\n }\n\n return Promise.resolve(null);\n }\n\n clearCache(): void {}\n}\n\ninterface DecoratorInvocation {\n type: Function;\n args?: any[];\n}\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ElementRef } from './element_ref';
|
|
2
1
|
import { AppElement } from './element';
|
|
2
|
+
import { ElementRef } from './element_ref';
|
|
3
3
|
import { EmbeddedViewRef } from './view_ref';
|
|
4
4
|
/**
|
|
5
5
|
* Represents an Embedded Template that can be used to instantiate Embedded Views.
|
|
@@ -12,6 +12,7 @@ import { EmbeddedViewRef } from './view_ref';
|
|
|
12
12
|
* To instantiate Embedded Views based on a Template, use
|
|
13
13
|
* {@link ViewContainerRef#createEmbeddedView}, which will create the View and attach it to the
|
|
14
14
|
* View Container.
|
|
15
|
+
* @stable
|
|
15
16
|
*/
|
|
16
17
|
export declare abstract class TemplateRef<C> {
|
|
17
18
|
/**
|
|
@@ -11,6 +11,7 @@ const EMPTY_CONTEXT = new Object();
|
|
|
11
11
|
* To instantiate Embedded Views based on a Template, use
|
|
12
12
|
* {@link ViewContainerRef#createEmbeddedView}, which will create the View and attach it to the
|
|
13
13
|
* View Container.
|
|
14
|
+
* @stable
|
|
14
15
|
*/
|
|
15
16
|
export class TemplateRef {
|
|
16
17
|
/**
|