From 05ffdc9b446cb1cba1a7b7f1990c2637f6263ca5 Mon Sep 17 00:00:00 2001 From: Tobias Bosch Date: Mon, 2 Feb 2015 16:25:34 -0800 Subject: [PATCH] refactor(build): explicitly mention `src` folder in imports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Export files are now directly under the module folder, e.g. `core/core.js`. With this, an import like `core/core` won’t need a path mapping (e.g. via `System.paths`) any more. This adds the `src` folder to all other import statements as well. --- gulpfile.js | 48 ++++++++++--------- karma-dart.conf.js | 16 +++---- modules/angular/{src => }/angular.js | 0 .../e2e_test/change_detection_perf.es6 | 2 +- .../e2e_test/change_detection_spec.es6 | 2 +- modules/benchmarks/e2e_test/compiler_perf.es6 | 2 +- modules/benchmarks/e2e_test/compiler_spec.es6 | 2 +- modules/benchmarks/e2e_test/di_perf.es6 | 2 +- modules/benchmarks/e2e_test/di_spec.es6 | 2 +- .../e2e_test/element_injector_perf.es6 | 2 +- .../e2e_test/element_injector_spec.es6 | 2 +- modules/benchmarks/e2e_test/selector_perf.es6 | 2 +- modules/benchmarks/e2e_test/selector_spec.es6 | 2 +- modules/benchmarks/e2e_test/tree_perf.es6 | 2 +- modules/benchmarks/e2e_test/tree_spec.es6 | 2 +- .../change_detection_benchmark.js | 8 ++-- .../src/compiler/compiler_benchmark.js | 22 ++++----- .../src/compiler/selector_benchmark.js | 10 ++-- modules/benchmarks/src/di/di_benchmark.js | 4 +- .../element_injector_benchmark.js | 6 +-- modules/benchmarks/src/tree/tree_benchmark.js | 18 +++---- .../e2e_test/compiler_perf.es6 | 2 +- .../e2e_test/compiler_spec.es6 | 2 +- .../e2e_test/largetable_perf.es6 | 2 +- .../e2e_test/largetable_spec.es6 | 2 +- .../e2e_test/naive_infinite_scroll_perf.es6 | 2 +- .../e2e_test/naive_infinite_scroll_spec.es6 | 2 +- .../e2e_test/tree_perf.es6 | 2 +- .../e2e_test/tree_spec.es6 | 2 +- modules/benchmarks_external/pubspec.yaml | 4 +- .../src/compiler/compiler_benchmark.dart | 2 +- .../src/compiler/compiler_benchmark.es6 | 2 +- .../src/largetable/largetable_benchmark.es6 | 2 +- .../src/naive_infinite_scroll/app.dart | 2 +- .../src/tree/tree_benchmark.dart | 2 +- .../src/tree/tree_benchmark.es6 | 2 +- .../{src => }/change_detection.js | 18 +++---- .../src/abstract_change_detector.js | 2 +- modules/change_detection/src/array_changes.js | 4 +- .../src/change_detection_jit_generator.es6 | 34 ++++++------- .../src/change_detection_util.js | 4 +- modules/change_detection/src/coalesce.js | 4 +- .../src/dynamic_change_detector.js | 4 +- modules/change_detection/src/interfaces.js | 2 +- .../change_detection/src/keyvalue_changes.js | 4 +- modules/change_detection/src/parser/ast.js | 4 +- .../parser/context_with_variable_bindings.js | 4 +- modules/change_detection/src/parser/lexer.js | 4 +- modules/change_detection/src/parser/parser.js | 6 +-- .../src/proto_change_detector.js | 4 +- .../test/array_changes_spec.js | 6 +-- .../test/change_detection_spec.js | 12 ++--- .../change_detection/test/coalesce_spec.js | 4 +- .../test/keyvalue_changes_spec.js | 6 +-- .../context_with_variable_bindings_spec.js | 6 +-- .../test/parser/lexer_spec.js | 6 +-- .../test/parser/parser_spec.js | 14 +++--- modules/change_detection/test/util.js | 2 +- modules/core/core.js | 12 +++++ modules/core/src/annotations/annotations.js | 4 +- modules/core/src/annotations/events.js | 2 +- .../core/src/annotations/template_config.js | 4 +- modules/core/src/annotations/visibility.js | 2 +- modules/core/src/application.js | 14 +++--- modules/core/src/compiler/compiler.js | 8 ++-- .../core/src/compiler/directive_metadata.js | 4 +- .../src/compiler/directive_metadata_reader.js | 6 +-- modules/core/src/compiler/element_binder.js | 6 +-- modules/core/src/compiler/element_injector.js | 22 ++++----- .../src/compiler/pipeline/compile_control.js | 6 +-- .../src/compiler/pipeline/compile_element.js | 6 +-- .../src/compiler/pipeline/compile_pipeline.js | 6 +-- .../src/compiler/pipeline/default_steps.js | 6 +-- .../src/compiler/pipeline/directive_parser.js | 6 +-- .../pipeline/element_binder_builder.js | 8 ++-- .../pipeline/element_binding_marker.js | 6 +-- .../pipeline/property_binding_parser.js | 6 +-- .../proto_element_injector_builder.js | 4 +- .../compiler/pipeline/proto_view_builder.js | 4 +- .../pipeline/text_interpolation_parser.js | 4 +- .../src/compiler/pipeline/view_splitter.js | 6 +-- modules/core/src/compiler/selector.js | 4 +- .../shadow_dom_emulation/content_tag.js | 8 ++-- .../shadow_dom_emulation/light_dom.js | 6 +-- .../core/src/compiler/shadow_dom_strategy.js | 6 +-- modules/core/src/compiler/template_loader.js | 4 +- modules/core/src/compiler/view.js | 10 ++-- modules/core/src/compiler/viewport.js | 10 ++-- modules/core/src/core.js | 12 ----- modules/core/src/dom/element.js | 4 +- modules/core/src/life_cycle/life_cycle.js | 6 +-- modules/core/src/zone/vm_turn_zone.es6 | 4 +- modules/core/test/application_spec.js | 12 ++--- modules/core/test/compiler/compiler_spec.js | 24 +++++----- .../directive_metadata_reader_spec.js | 12 ++--- .../test/compiler/element_injector_spec.js | 22 ++++----- .../core/test/compiler/integration_spec.js | 16 +++---- .../pipeline/directive_parser_spec.js | 26 +++++----- .../pipeline/element_binder_builder_spec.js | 32 ++++++------- .../pipeline/element_binding_marker_spec.js | 22 ++++----- .../test/compiler/pipeline/pipeline_spec.js | 16 +++---- .../pipeline/property_binding_parser_spec.js | 8 ++-- .../proto_element_injector_builder_spec.js | 26 +++++----- .../pipeline/proto_view_builder_spec.js | 18 +++---- .../text_interpolation_parser_spec.js | 8 ++-- .../compiler/pipeline/view_splitter_spec.js | 10 ++-- modules/core/test/compiler/selector_spec.js | 8 ++-- .../compiler/shadow_dom/content_tag_spec.js | 10 ++-- .../compiler/shadow_dom/light_dom_spec.js | 18 +++---- .../shadow_dom_emulation_integration_spec.js | 18 +++---- modules/core/test/compiler/view_spec.js | 26 +++++----- modules/core/test/compiler/viewport_spec.js | 12 ++--- modules/core/test/zone/vm_turn_zone_spec.js | 8 ++-- modules/di/di.js | 7 +++ modules/di/src/annotations.js | 2 +- modules/di/src/binding.js | 6 +-- modules/di/src/di.js | 7 --- modules/di/src/exceptions.js | 4 +- modules/di/src/injector.js | 6 +-- modules/di/src/key.js | 4 +- modules/di/test/di/async_spec.js | 2 +- modules/directives/directives.js | 4 ++ modules/directives/src/directives.js | 4 -- modules/directives/src/ng_if.js | 6 +-- modules/directives/src/ng_non_bindable.js | 2 +- modules/directives/src/ng_repeat.js | 12 ++--- modules/directives/src/ng_switch.js | 14 +++--- modules/directives/test/ng_if_spec.js | 12 ++--- .../directives/test/ng_non_bindable_spec.js | 14 +++--- modules/directives/test/ng_repeat_spec.js | 18 +++---- modules/directives/test/ng_switch_spec.js | 12 ++--- modules/e2e_test_lib/src/benchmark_util.js | 4 +- .../e2e_test/hello_world/hello_world_spec.es6 | 6 +-- modules/examples/src/hello_world/index.js | 4 +- .../examples/src/hello_world/index_static.js | 10 ++-- modules/facade/src/async.es6 | 4 +- modules/facade/src/collection.es6 | 2 +- modules/facade/src/dom.es6 | 2 +- modules/reflection/src/reflection.dart | 2 +- modules/reflection/src/reflection.es6 | 4 +- .../src/reflection_capabilities.es6 | 4 +- modules/reflection/src/reflector.js | 4 +- modules/reflection/test/reflector_spec.js | 8 ++-- modules/rtts_assert/rtts_assert.es6 | 1 + modules/test_lib/src/test_lib.dart | 6 +-- modules/test_lib/src/test_lib.es6 | 2 +- modules/test_lib/src/utils.js | 2 +- modules/test_lib/test/test_lib_spec.js | 6 +-- modules/test_lib/test_lib.js | 2 + test-main.js | 28 +---------- tools/build/dartanalyzer.js | 3 +- tools/build/file2modulename.js | 5 +- tools/build/html.js | 2 +- tools/build/pubbuild.js | 12 ++++- tools/build/snippets/runtime_paths.js | 15 +----- tools/build/transpile.js | 4 +- tools/build/util.js | 42 +++++++++++----- tools/transpiler/spec/annotations_spec.js | 2 +- tools/transpiler/spec/for_of_spec.js | 2 +- tools/transpiler/spec/imports_spec.js | 2 +- 160 files changed, 619 insertions(+), 627 deletions(-) rename modules/angular/{src => }/angular.js (100%) rename modules/change_detection/{src => }/change_detection.js (64%) create mode 100644 modules/core/core.js delete mode 100644 modules/core/src/core.js create mode 100644 modules/di/di.js delete mode 100644 modules/di/src/di.js create mode 100644 modules/directives/directives.js delete mode 100644 modules/directives/src/directives.js create mode 100644 modules/rtts_assert/rtts_assert.es6 create mode 100644 modules/test_lib/test_lib.js diff --git a/gulpfile.js b/gulpfile.js index a02a1ddb40848a..da2fd6d81a3909 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -44,7 +44,7 @@ var CJS_COMPILER_OPTIONS = { var _HTLM_DEFAULT_SCRIPTS_JS = [ {src: '/deps/traceur-runtime.js', mimeType: 'text/javascript'}, - {src: '/rtts_assert/lib/rtts_assert.js', mimeType: 'text/javascript'}, + {src: '/rtts_assert/rtts_assert.js', mimeType: 'text/javascript'}, {src: '/deps/es6-module-loader-sans-promises.src.js', mimeType: 'text/javascript'}, {src: '/deps/zone.js', mimeType: 'text/javascript'}, {src: '/deps/long-stack-trace-zone.js', mimeType: 'text/javascript'}, @@ -78,11 +78,20 @@ var CONFIG = { }, docs: 'dist/docs' }, - srcFolderMapping: { - 'default': 'lib', - '**/benchmarks/**': 'web', - '**/benchmarks_external/**': 'web', - '**/example*/**': 'web' + srcFolderInsertion: { + js: { + '**': '' + }, + dart: { + '**': 'lib', + '*/test/**': '', + 'benchmarks/**': 'web', + 'benchmarks/test/**': '', + 'benchmarks_external/**': 'web', + 'benchmarks_external/test/**': '', + 'example*/**': 'web', + 'example*/test/**': '' + } }, deps: { js: [ @@ -145,7 +154,7 @@ var CONFIG = { }, scriptsPerFolder: { js: { - default: _HTLM_DEFAULT_SCRIPTS_JS, + '**': _HTLM_DEFAULT_SCRIPTS_JS, 'benchmarks/**': [ { src: '/deps/url_params_to_form.js', mimeType: 'text/javascript' } @@ -157,7 +166,7 @@ var CONFIG = { ].concat(_HTLM_DEFAULT_SCRIPTS_JS) }, dart: { - default: _HTML_DEFAULT_SCRIPTS_DART, + '**': _HTML_DEFAULT_SCRIPTS_DART, 'benchmarks*/**': [ { src: '/deps/url_params_to_form.js', mimeType: 'text/javascript' } @@ -221,7 +230,7 @@ gulp.task('build/transpile.js.dev', transpile(gulp, gulpPlugins, { dest: CONFIG.dest.js.dev, outputExt: 'js', options: CONFIG.transpile.options.js.dev, - srcFolderMapping: CONFIG.srcFolderMapping + srcFolderInsertion: CONFIG.srcFolderInsertion.js })); gulp.task('build/transpile.js.prod', transpile(gulp, gulpPlugins, { @@ -230,7 +239,7 @@ gulp.task('build/transpile.js.prod', transpile(gulp, gulpPlugins, { dest: CONFIG.dest.js.prod, outputExt: 'js', options: CONFIG.transpile.options.js.prod, - srcFolderMapping: CONFIG.srcFolderMapping + srcFolderInsertion: CONFIG.srcFolderInsertion.js })); gulp.task('build/transpile.dart', transpile(gulp, gulpPlugins, { @@ -239,7 +248,7 @@ gulp.task('build/transpile.dart', transpile(gulp, gulpPlugins, { dest: CONFIG.dest.dart, outputExt: 'dart', options: CONFIG.transpile.options.dart, - srcFolderMapping: CONFIG.srcFolderMapping + srcFolderInsertion: CONFIG.srcFolderInsertion.dart })); gulp.task('build/transpile/tools.cjs', transpile(gulp, gulpPlugins, { @@ -248,9 +257,7 @@ gulp.task('build/transpile/tools.cjs', transpile(gulp, gulpPlugins, { dest: CONFIG.dest.cjs.tools, outputExt: 'js', options: CONFIG.transpile.options.cjs, - srcFolderMapping: { - 'default': 'src' - } + srcFolderInsertion: CONFIG.srcFolderInsertion.js })); gulp.task('build/transpile/e2eTest.cjs', transpile(gulp, gulpPlugins, { @@ -259,9 +266,7 @@ gulp.task('build/transpile/e2eTest.cjs', transpile(gulp, gulpPlugins, { dest: CONFIG.dest.cjs.e2eTest, outputExt: 'js', options: CONFIG.transpile.options.cjs, - srcFolderMapping: { - 'default': 'src' - } + srcFolderInsertion: CONFIG.srcFolderInsertion.js })); // ------------ @@ -270,21 +275,21 @@ gulp.task('build/transpile/e2eTest.cjs', transpile(gulp, gulpPlugins, { gulp.task('build/html.js.dev', html(gulp, gulpPlugins, { src: CONFIG.html.src.js, dest: CONFIG.dest.js.dev, - srcFolderMapping: CONFIG.srcFolderMapping, + srcFolderInsertion: CONFIG.srcFolderInsertion.js, scriptsPerFolder: CONFIG.html.scriptsPerFolder.js })); gulp.task('build/html.js.prod', html(gulp, gulpPlugins, { src: CONFIG.html.src.js, dest: CONFIG.dest.js.prod, - srcFolderMapping: CONFIG.srcFolderMapping, + srcFolderInsertion: CONFIG.srcFolderInsertion.js, scriptsPerFolder: CONFIG.html.scriptsPerFolder.js })); gulp.task('build/html.dart', html(gulp, gulpPlugins, { src: CONFIG.html.src.dart, dest: CONFIG.dest.dart, - srcFolderMapping: CONFIG.srcFolderMapping, + srcFolderInsertion: CONFIG.srcFolderInsertion.dart, scriptsPerFolder: CONFIG.html.scriptsPerFolder.dart })); @@ -302,8 +307,7 @@ gulp.task('build/pubspec.dart', pubspec(gulp, gulpPlugins, { gulp.task('build/analyze.dart', dartanalyzer(gulp, gulpPlugins, { dest: CONFIG.dest.dart, - command: DART_SDK.ANALYZER, - srcFolderMapping: CONFIG.srcFolderMapping + command: DART_SDK.ANALYZER })); // ------------ diff --git a/karma-dart.conf.js b/karma-dart.conf.js index 10e96e4e1fbba6..ec47c1aa66f880 100644 --- a/karma-dart.conf.js +++ b/karma-dart.conf.js @@ -42,14 +42,14 @@ module.exports = function(config) { '/packages/path': 'http://localhost:9877/base/packages/path', // Local dependencies, transpiled from the source. - '/packages/angular': 'http://localhost:9877/base/modules/angular/src', - '/packages/core': 'http://localhost:9877/base/modules/core/src', - '/packages/change_detection': 'http://localhost:9877/base/modules/change_detection/src', - '/packages/reflection': 'http://localhost:9877/base/modules/reflection/src', - '/packages/di': 'http://localhost:9877/base/modules/di/src', - '/packages/directives': 'http://localhost:9877/base/modules/directives/src', - '/packages/facade': 'http://localhost:9877/base/modules/facade/src', - '/packages/test_lib': 'http://localhost:9877/base/modules/test_lib/src', + '/packages/angular': 'http://localhost:9877/base/modules/angular', + '/packages/core': 'http://localhost:9877/base/modules/core', + '/packages/change_detection': 'http://localhost:9877/base/modules/change_detection', + '/packages/reflection': 'http://localhost:9877/base/modules/reflection', + '/packages/di': 'http://localhost:9877/base/modules/di', + '/packages/directives': 'http://localhost:9877/base/modules/directives', + '/packages/facade': 'http://localhost:9877/base/modules/facade', + '/packages/test_lib': 'http://localhost:9877/base/modules/test_lib', }, preprocessors: { diff --git a/modules/angular/src/angular.js b/modules/angular/angular.js similarity index 100% rename from modules/angular/src/angular.js rename to modules/angular/angular.js diff --git a/modules/benchmarks/e2e_test/change_detection_perf.es6 b/modules/benchmarks/e2e_test/change_detection_perf.es6 index 207432e7f4581c..7a7cd75cbee139 100644 --- a/modules/benchmarks/e2e_test/change_detection_perf.es6 +++ b/modules/benchmarks/e2e_test/change_detection_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng2 change detection benchmark', function () { - var URL = 'benchmarks/web/change_detection/change_detection_benchmark.html'; + var URL = 'benchmarks/src/change_detection/change_detection_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/change_detection_spec.es6 b/modules/benchmarks/e2e_test/change_detection_spec.es6 index 93a72e5806b1d6..ecccf52c24e938 100644 --- a/modules/benchmarks/e2e_test/change_detection_spec.es6 +++ b/modules/benchmarks/e2e_test/change_detection_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng2 change detection benchmark', function () { - var URL = 'benchmarks/web/change_detection/change_detection_benchmark.html'; + var URL = 'benchmarks/src/change_detection/change_detection_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/compiler_perf.es6 b/modules/benchmarks/e2e_test/compiler_perf.es6 index c62b5af0cb39e3..7ad4f29ea34d57 100644 --- a/modules/benchmarks/e2e_test/compiler_perf.es6 +++ b/modules/benchmarks/e2e_test/compiler_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng2 compiler benchmark', function () { - var URL = 'benchmarks/web/compiler/compiler_benchmark.html'; + var URL = 'benchmarks/src/compiler/compiler_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/compiler_spec.es6 b/modules/benchmarks/e2e_test/compiler_spec.es6 index 955a70ae4cf8f1..7a2e8112b1f9b0 100644 --- a/modules/benchmarks/e2e_test/compiler_spec.es6 +++ b/modules/benchmarks/e2e_test/compiler_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng2 compiler benchmark', function () { - var URL = 'benchmarks/web/compiler/compiler_benchmark.html'; + var URL = 'benchmarks/src/compiler/compiler_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/di_perf.es6 b/modules/benchmarks/e2e_test/di_perf.es6 index 2f15caaeefb7dd..c7d82fa9a0cbe1 100644 --- a/modules/benchmarks/e2e_test/di_perf.es6 +++ b/modules/benchmarks/e2e_test/di_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng2 di benchmark', function () { - var URL = 'benchmarks/web/di/di_benchmark.html'; + var URL = 'benchmarks/src/di/di_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/di_spec.es6 b/modules/benchmarks/e2e_test/di_spec.es6 index d7f9a24c93d597..f4512546caa106 100644 --- a/modules/benchmarks/e2e_test/di_spec.es6 +++ b/modules/benchmarks/e2e_test/di_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng2 di benchmark', function () { - var URL = 'benchmarks/web/di/di_benchmark.html'; + var URL = 'benchmarks/src/di/di_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/element_injector_perf.es6 b/modules/benchmarks/e2e_test/element_injector_perf.es6 index df3b0e06ffb775..6cb99606e175cf 100644 --- a/modules/benchmarks/e2e_test/element_injector_perf.es6 +++ b/modules/benchmarks/e2e_test/element_injector_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng2 element injector benchmark', function () { - var URL = 'benchmarks/web/element_injector/element_injector_benchmark.html'; + var URL = 'benchmarks/src/element_injector/element_injector_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/element_injector_spec.es6 b/modules/benchmarks/e2e_test/element_injector_spec.es6 index 90e04ac59069a4..6e21275adda59e 100644 --- a/modules/benchmarks/e2e_test/element_injector_spec.es6 +++ b/modules/benchmarks/e2e_test/element_injector_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng2 element injector benchmark', function () { - var URL = 'benchmarks/web/element_injector/element_injector_benchmark.html'; + var URL = 'benchmarks/src/element_injector/element_injector_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/selector_perf.es6 b/modules/benchmarks/e2e_test/selector_perf.es6 index 345b6887e233c6..030881592e846f 100644 --- a/modules/benchmarks/e2e_test/selector_perf.es6 +++ b/modules/benchmarks/e2e_test/selector_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng2 selector benchmark', function () { - var URL = 'benchmarks/web/compiler/selector_benchmark.html'; + var URL = 'benchmarks/src/compiler/selector_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/selector_spec.es6 b/modules/benchmarks/e2e_test/selector_spec.es6 index b387c54364cd97..ae59759f4cd587 100644 --- a/modules/benchmarks/e2e_test/selector_spec.es6 +++ b/modules/benchmarks/e2e_test/selector_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng2 selector benchmark', function () { - var URL = 'benchmarks/web/compiler/selector_benchmark.html'; + var URL = 'benchmarks/src/compiler/selector_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/tree_perf.es6 b/modules/benchmarks/e2e_test/tree_perf.es6 index dde04ff6c7df3d..90858a15999c43 100644 --- a/modules/benchmarks/e2e_test/tree_perf.es6 +++ b/modules/benchmarks/e2e_test/tree_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng2 tree benchmark', function () { - var URL = 'benchmarks/web/tree/tree_benchmark.html'; + var URL = 'benchmarks/src/tree/tree_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/e2e_test/tree_spec.es6 b/modules/benchmarks/e2e_test/tree_spec.es6 index de1829321ede63..8c8c410c659705 100644 --- a/modules/benchmarks/e2e_test/tree_spec.es6 +++ b/modules/benchmarks/e2e_test/tree_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng2 tree benchmark', function () { - var URL = 'benchmarks/web/tree/tree_benchmark.html'; + var URL = 'benchmarks/src/tree/tree_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks/src/change_detection/change_detection_benchmark.js b/modules/benchmarks/src/change_detection/change_detection_benchmark.js index cb5bbe1f4b0e04..c280d3856e71f0 100644 --- a/modules/benchmarks/src/change_detection/change_detection_benchmark.js +++ b/modules/benchmarks/src/change_detection/change_detection_benchmark.js @@ -1,7 +1,7 @@ -import {ListWrapper, MapWrapper} from 'facade/collection'; -import {reflector} from 'reflection/reflection'; -import {isPresent} from 'facade/lang'; -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {ListWrapper, MapWrapper} from 'facade/src/collection'; +import {reflector} from 'reflection/src/reflection'; +import {isPresent} from 'facade/src/lang'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; import { Lexer, diff --git a/modules/benchmarks/src/compiler/compiler_benchmark.js b/modules/benchmarks/src/compiler/compiler_benchmark.js index b71c37fdf914e6..4964bef6b71f29 100644 --- a/modules/benchmarks/src/compiler/compiler_benchmark.js +++ b/modules/benchmarks/src/compiler/compiler_benchmark.js @@ -1,19 +1,19 @@ -import {DOM, document} from 'facade/dom'; -import {isBlank, Type} from 'facade/lang'; -import {MapWrapper} from 'facade/collection'; -import {DirectiveMetadata} from 'core/compiler/directive_metadata'; +import {DOM, document} from 'facade/src/dom'; +import {isBlank, Type} from 'facade/src/lang'; +import {MapWrapper} from 'facade/src/collection'; +import {DirectiveMetadata} from 'core/src/compiler/directive_metadata'; import {Parser, Lexer, ProtoRecordRange, dynamicChangeDetection} from 'change_detection/change_detection'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; -import {Component} from 'core/annotations/annotations'; -import {Decorator} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; +import {Component} from 'core/src/annotations/annotations'; +import {Decorator} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; -import {reflector} from 'reflection/reflection'; -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {reflector} from 'reflection/src/reflection'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; function setupReflector() { reflector.registerType(BenchmarkComponent, { diff --git a/modules/benchmarks/src/compiler/selector_benchmark.js b/modules/benchmarks/src/compiler/selector_benchmark.js index 8cbe7485db7871..faa34326b8f12a 100644 --- a/modules/benchmarks/src/compiler/selector_benchmark.js +++ b/modules/benchmarks/src/compiler/selector_benchmark.js @@ -1,8 +1,8 @@ -import {SelectorMatcher} from "core/compiler/selector"; -import {CssSelector} from "core/compiler/selector"; -import {StringWrapper, Math} from 'facade/lang'; -import {ListWrapper} from 'facade/collection'; -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {SelectorMatcher} from "core/src/compiler/selector"; +import {CssSelector} from "core/src/compiler/selector"; +import {StringWrapper, Math} from 'facade/src/lang'; +import {ListWrapper} from 'facade/src/collection'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; export function main() { var count = getIntParameter('selectors'); diff --git a/modules/benchmarks/src/di/di_benchmark.js b/modules/benchmarks/src/di/di_benchmark.js index f1e9dd9ff8215a..7de62333909aa0 100644 --- a/modules/benchmarks/src/di/di_benchmark.js +++ b/modules/benchmarks/src/di/di_benchmark.js @@ -1,6 +1,6 @@ import {Injector, Key} from "di/di"; -import {reflector} from 'reflection/reflection'; -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {reflector} from 'reflection/src/reflection'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; var count = 0; diff --git a/modules/benchmarks/src/element_injector/element_injector_benchmark.js b/modules/benchmarks/src/element_injector/element_injector_benchmark.js index e2f8dc63c2fe4d..7b87460443bddd 100644 --- a/modules/benchmarks/src/element_injector/element_injector_benchmark.js +++ b/modules/benchmarks/src/element_injector/element_injector_benchmark.js @@ -1,7 +1,7 @@ -import {reflector} from 'reflection/reflection'; +import {reflector} from 'reflection/src/reflection'; import {Injector} from 'di/di'; -import {ProtoElementInjector} from 'core/compiler/element_injector'; -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {ProtoElementInjector} from 'core/src/compiler/element_injector'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; var count = 0; diff --git a/modules/benchmarks/src/tree/tree_benchmark.js b/modules/benchmarks/src/tree/tree_benchmark.js index f9b4116689e539..ddc59b9f228018 100644 --- a/modules/benchmarks/src/tree/tree_benchmark.js +++ b/modules/benchmarks/src/tree/tree_benchmark.js @@ -3,15 +3,15 @@ import {Parser, Lexer, ChangeDetector, ChangeDetection, jitChangeDetection} import {bootstrap, Component, Template, TemplateConfig, ViewPort, Compiler} from 'angular/angular'; -import {CompilerCache} from 'core/compiler/compiler'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {TemplateLoader} from 'core/compiler/template_loader'; -import {LifeCycle} from 'core/life_cycle/life_cycle'; - -import {reflector} from 'reflection/reflection'; -import {DOM, document, window, Element, gc} from 'facade/dom'; -import {isPresent} from 'facade/lang'; -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {CompilerCache} from 'core/src/compiler/compiler'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {TemplateLoader} from 'core/src/compiler/template_loader'; +import {LifeCycle} from 'core/src/life_cycle/life_cycle'; + +import {reflector} from 'reflection/src/reflection'; +import {DOM, document, window, Element, gc} from 'facade/src/dom'; +import {isPresent} from 'facade/src/lang'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; function setupReflector() { // TODO: Put the general calls to reflector.register... in a shared file diff --git a/modules/benchmarks_external/e2e_test/compiler_perf.es6 b/modules/benchmarks_external/e2e_test/compiler_perf.es6 index e94b25d99f1d64..ad33d2626f938c 100644 --- a/modules/benchmarks_external/e2e_test/compiler_perf.es6 +++ b/modules/benchmarks_external/e2e_test/compiler_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng1.x compiler benchmark', function () { - var URL = 'benchmarks_external/web/compiler/compiler_benchmark.html'; + var URL = 'benchmarks_external/src/compiler/compiler_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/e2e_test/compiler_spec.es6 b/modules/benchmarks_external/e2e_test/compiler_spec.es6 index 183ebec22762ce..55b6c156acb2d7 100644 --- a/modules/benchmarks_external/e2e_test/compiler_spec.es6 +++ b/modules/benchmarks_external/e2e_test/compiler_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng1.x compiler benchmark', function () { - var URL = 'benchmarks_external/web/compiler/compiler_benchmark.html'; + var URL = 'benchmarks_external/src/compiler/compiler_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/e2e_test/largetable_perf.es6 b/modules/benchmarks_external/e2e_test/largetable_perf.es6 index a14826ec49379f..4e2e7c7d995e78 100644 --- a/modules/benchmarks_external/e2e_test/largetable_perf.es6 +++ b/modules/benchmarks_external/e2e_test/largetable_perf.es6 @@ -1,7 +1,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng1.x largetable benchmark', function () { - var URL = 'benchmarks_external/web/largetable/largetable_benchmark.html'; + var URL = 'benchmarks_external/src/largetable/largetable_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/e2e_test/largetable_spec.es6 b/modules/benchmarks_external/e2e_test/largetable_spec.es6 index ace3922f4ca054..0e1966ca17b030 100644 --- a/modules/benchmarks_external/e2e_test/largetable_spec.es6 +++ b/modules/benchmarks_external/e2e_test/largetable_spec.es6 @@ -1,7 +1,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng1.x largetable benchmark', function () { - var URL = 'benchmarks_external/web/largetable/largetable_benchmark.html'; + var URL = 'benchmarks_external/src/largetable/largetable_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/e2e_test/naive_infinite_scroll_perf.es6 b/modules/benchmarks_external/e2e_test/naive_infinite_scroll_perf.es6 index 5e184d3eb918dd..81230987b1d50c 100644 --- a/modules/benchmarks_external/e2e_test/naive_infinite_scroll_perf.es6 +++ b/modules/benchmarks_external/e2e_test/naive_infinite_scroll_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng-dart1.x naive infinite scroll benchmark', function () { - var URL = 'benchmarks_external/web/naive_infinite_scroll/index.html'; + var URL = 'benchmarks_external/src/naive_infinite_scroll/index.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/e2e_test/naive_infinite_scroll_spec.es6 b/modules/benchmarks_external/e2e_test/naive_infinite_scroll_spec.es6 index 691e2f1790e224..e04438cac1d98a 100644 --- a/modules/benchmarks_external/e2e_test/naive_infinite_scroll_spec.es6 +++ b/modules/benchmarks_external/e2e_test/naive_infinite_scroll_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng-dart1.x naive infinite scroll benchmark', function () { - var URL = 'benchmarks_external/web/naive_infinite_scroll/index.html'; + var URL = 'benchmarks_external/src/naive_infinite_scroll/index.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/e2e_test/tree_perf.es6 b/modules/benchmarks_external/e2e_test/tree_perf.es6 index cb19a6f5a14569..b97e2de2b11e7c 100644 --- a/modules/benchmarks_external/e2e_test/tree_perf.es6 +++ b/modules/benchmarks_external/e2e_test/tree_perf.es6 @@ -2,7 +2,7 @@ var perfUtil = require('../../e2e_test_lib/e2e_test/perf_util'); describe('ng1.x tree benchmark', function () { - var URL = 'benchmarks_external/web/tree/tree_benchmark.html'; + var URL = 'benchmarks_external/src/tree/tree_benchmark.html'; afterEach(perfUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/e2e_test/tree_spec.es6 b/modules/benchmarks_external/e2e_test/tree_spec.es6 index 83202bc27dff10..6bb6cb3789f811 100644 --- a/modules/benchmarks_external/e2e_test/tree_spec.es6 +++ b/modules/benchmarks_external/e2e_test/tree_spec.es6 @@ -2,7 +2,7 @@ var testUtil = require('../../e2e_test_lib/e2e_test/test_util'); describe('ng1.x tree benchmark', function () { - var URL = 'benchmarks_external/web/tree/tree_benchmark.html'; + var URL = 'benchmarks_external/src/tree/tree_benchmark.html'; afterEach(testUtil.verifyNoBrowserErrors); diff --git a/modules/benchmarks_external/pubspec.yaml b/modules/benchmarks_external/pubspec.yaml index aad86d9b6a3150..ce97889134ea71 100644 --- a/modules/benchmarks_external/pubspec.yaml +++ b/modules/benchmarks_external/pubspec.yaml @@ -10,5 +10,5 @@ dependencies: transformers: - angular: html_files: - - web/naive_infinite_scroll/scroll_area.html - - web/naive_infinite_scroll/scroll_item.html + - web/src/naive_infinite_scroll/scroll_area.html + - web/src/naive_infinite_scroll/scroll_item.html diff --git a/modules/benchmarks_external/src/compiler/compiler_benchmark.dart b/modules/benchmarks_external/src/compiler/compiler_benchmark.dart index 855c7cfc1fd669..b9c5d59335aa9b 100644 --- a/modules/benchmarks_external/src/compiler/compiler_benchmark.dart +++ b/modules/benchmarks_external/src/compiler/compiler_benchmark.dart @@ -4,7 +4,7 @@ library compiler_benchmark_ng10; import 'package:angular/angular.dart'; import 'package:angular/application_factory.dart'; import 'dart:html'; -import 'package:e2e_test_lib/benchmark_util.dart'; +import 'package:e2e_test_lib/src/benchmark_util.dart'; main() { diff --git a/modules/benchmarks_external/src/compiler/compiler_benchmark.es6 b/modules/benchmarks_external/src/compiler/compiler_benchmark.es6 index 76e3e83bc881db..d6d35a11622db2 100644 --- a/modules/benchmarks_external/src/compiler/compiler_benchmark.es6 +++ b/modules/benchmarks_external/src/compiler/compiler_benchmark.es6 @@ -1,5 +1,5 @@ // compiler benchmark in AngularJS 1.x -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; export function main() { var ngEl = document.createElement('div'); diff --git a/modules/benchmarks_external/src/largetable/largetable_benchmark.es6 b/modules/benchmarks_external/src/largetable/largetable_benchmark.es6 index 3dabc90736e6d0..97cd94e713b9c5 100644 --- a/modules/benchmarks_external/src/largetable/largetable_benchmark.es6 +++ b/modules/benchmarks_external/src/largetable/largetable_benchmark.es6 @@ -1,4 +1,4 @@ -import {getIntParameter, getStringParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {getIntParameter, getStringParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; var totalRows = getIntParameter('rows'); var totalColumns = getIntParameter('columns'); diff --git a/modules/benchmarks_external/src/naive_infinite_scroll/app.dart b/modules/benchmarks_external/src/naive_infinite_scroll/app.dart index c78d7f178d4fda..a7294415616207 100644 --- a/modules/benchmarks_external/src/naive_infinite_scroll/app.dart +++ b/modules/benchmarks_external/src/naive_infinite_scroll/app.dart @@ -3,7 +3,7 @@ library scroll_app; import 'dart:async'; import 'dart:html'; import 'package:angular/angular.dart'; -import 'package:e2e_test_lib/benchmark_util.dart'; +import 'package:e2e_test_lib/src/benchmark_util.dart'; @Component( selector: 'scroll-app', diff --git a/modules/benchmarks_external/src/tree/tree_benchmark.dart b/modules/benchmarks_external/src/tree/tree_benchmark.dart index 7158159d1d3773..fa65ee893f5c9b 100644 --- a/modules/benchmarks_external/src/tree/tree_benchmark.dart +++ b/modules/benchmarks_external/src/tree/tree_benchmark.dart @@ -4,7 +4,7 @@ library tree_benchmark_ng10; import 'package:angular/angular.dart'; import 'package:angular/application_factory.dart'; import 'dart:html'; -import 'package:e2e_test_lib/benchmark_util.dart'; +import 'package:e2e_test_lib/src/benchmark_util.dart'; setup() { diff --git a/modules/benchmarks_external/src/tree/tree_benchmark.es6 b/modules/benchmarks_external/src/tree/tree_benchmark.es6 index 641dcd35ac80a6..3592b74f6befc8 100644 --- a/modules/benchmarks_external/src/tree/tree_benchmark.es6 +++ b/modules/benchmarks_external/src/tree/tree_benchmark.es6 @@ -1,5 +1,5 @@ // tree benchmark in AngularJS 1.x -import {getIntParameter, bindAction} from 'e2e_test_lib/benchmark_util'; +import {getIntParameter, bindAction} from 'e2e_test_lib/src/benchmark_util'; export function main() { angular.bootstrap(document.querySelector('tree'), ['app']); diff --git a/modules/change_detection/src/change_detection.js b/modules/change_detection/change_detection.js similarity index 64% rename from modules/change_detection/src/change_detection.js rename to modules/change_detection/change_detection.js index 1e53b263518756..2f5a8e80847914 100644 --- a/modules/change_detection/src/change_detection.js +++ b/modules/change_detection/change_detection.js @@ -1,14 +1,14 @@ -export {AST} from './parser/ast'; -export {Lexer} from './parser/lexer'; -export {Parser} from './parser/parser'; -export {ContextWithVariableBindings} from './parser/context_with_variable_bindings'; +export {AST} from './src/parser/ast'; +export {Lexer} from './src/parser/lexer'; +export {Parser} from './src/parser/parser'; +export {ContextWithVariableBindings} from './src/parser/context_with_variable_bindings'; -export {ExpressionChangedAfterItHasBeenChecked, ChangeDetectionError} from './exceptions'; -export {ChangeRecord, ChangeDispatcher, ChangeDetector} from './interfaces'; -export {ProtoChangeDetector, DynamicProtoChangeDetector, JitProtoChangeDetector} from './proto_change_detector'; -export {DynamicChangeDetector} from './dynamic_change_detector'; +export {ExpressionChangedAfterItHasBeenChecked, ChangeDetectionError} from './src/exceptions'; +export {ChangeRecord, ChangeDispatcher, ChangeDetector} from './src/interfaces'; +export {ProtoChangeDetector, DynamicProtoChangeDetector, JitProtoChangeDetector} from './src/proto_change_detector'; +export {DynamicChangeDetector} from './src/dynamic_change_detector'; -import {ProtoChangeDetector, DynamicProtoChangeDetector, JitProtoChangeDetector} from './proto_change_detector'; +import {ProtoChangeDetector, DynamicProtoChangeDetector, JitProtoChangeDetector} from './src/proto_change_detector'; export class ChangeDetection { createProtoChangeDetector(name:string){} diff --git a/modules/change_detection/src/abstract_change_detector.js b/modules/change_detection/src/abstract_change_detector.js index 2a2b4829c459b7..10f00b5ca07b61 100644 --- a/modules/change_detection/src/abstract_change_detector.js +++ b/modules/change_detection/src/abstract_change_detector.js @@ -1,4 +1,4 @@ -import {List, ListWrapper} from 'facade/collection'; +import {List, ListWrapper} from 'facade/src/collection'; import {ChangeDetector} from './interfaces'; export class AbstractChangeDetector extends ChangeDetector { diff --git a/modules/change_detection/src/array_changes.js b/modules/change_detection/src/array_changes.js index 8fd108807cf0d5..78d616f224658d 100644 --- a/modules/change_detection/src/array_changes.js +++ b/modules/change_detection/src/array_changes.js @@ -3,7 +3,7 @@ import { iterateListLike, ListWrapper, MapWrapper -} from 'facade/collection'; +} from 'facade/src/collection'; import { int, @@ -12,7 +12,7 @@ import { stringify, getMapKey, looseIdentical, -} from 'facade/lang'; +} from 'facade/src/lang'; export class ArrayChanges { _collection; diff --git a/modules/change_detection/src/change_detection_jit_generator.es6 b/modules/change_detection/src/change_detection_jit_generator.es6 index 31df528142ef00..b580ffbc7da877 100644 --- a/modules/change_detection/src/change_detection_jit_generator.es6 +++ b/modules/change_detection/src/change_detection_jit_generator.es6 @@ -1,5 +1,5 @@ -import {isPresent, isBlank, BaseException, Type} from 'facade/lang'; -import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {isPresent, isBlank, BaseException, Type} from 'facade/src/lang'; +import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/src/collection'; import {ContextWithVariableBindings} from './parser/context_with_variable_bindings'; import {AbstractChangeDetector} from './abstract_change_detector'; @@ -24,21 +24,21 @@ import { * The code generator takes a list of proto records and creates a function/class * that "emulates" what the developer would write by hand to implement the same * kind of behaviour. - * + * * For example: An expression `address.city` will result in the following class: - * + * * var ChangeDetector0 = function ChangeDetector0(dispatcher, formatters, protos) { * AbstractChangeDetector.call(this); * this.dispatcher = dispatcher; * this.formatters = formatters; * this.protos = protos; - * + * * this.context = null; * this.address0 = null; * this.city1 = null; * } * ChangeDetector0.prototype = Object.create(AbstractChangeDetector.prototype); - * + * * ChangeDetector0.prototype.detectChangesInRecords = function(throwOnChange) { * var address0; * var city1; @@ -46,47 +46,47 @@ import { * var changes = null; * var temp; * var context = this.context; - * + * * temp = ChangeDetectionUtil.findContext("address", context); * if (temp instanceof ContextWithVariableBindings) { * address0 = temp.get('address'); * } else { * address0 = temp.address; * } - * + * * if (address0 !== this.address0) { * this.address0 = address0; * } - * + * * city1 = address0.city; * if (city1 !== this.city1) { * changes = ChangeDetectionUtil.addRecord(changes, * ChangeDetectionUtil.simpleChangeRecord(this.protos[1].bindingMemento, this.city1, city1)); * this.city1 = city1; * } - * + * * if (changes.length > 0) { * if(throwOnChange) ChangeDetectionUtil.throwOnChange(this.protos[1], changes[0]); * this.dispatcher.onRecordChange('address.city', changes); * changes = null; * } * } - * - * + * + * * ChangeDetector0.prototype.setContext = function(context) { * this.context = context; * } - * + * * return ChangeDetector0; - * - * + * + * * The only thing the generated class depends on is the super class AbstractChangeDetector. * * The implementation comprises two parts: * * ChangeDetectorJITGenerator has the logic of how everything fits together. * * template functions (e.g., constructorTemplate) define what code is generated. */ - + var ABSTRACT_CHANGE_DETECTOR = "AbstractChangeDetector"; var UTIL = "ChangeDetectionUtil"; var DISPATCHER_ACCESSOR = "this.dispatcher"; @@ -382,7 +382,7 @@ export class ChangeDetectorJITGenerator { res += this.genLiteral(r.fixedArgs[r.args.length]); return res; } - + genLiteral(value):string { return JSON.stringify(value); } diff --git a/modules/change_detection/src/change_detection_util.js b/modules/change_detection/src/change_detection_util.js index 9cc844347631e6..eca1bb474e2c66 100644 --- a/modules/change_detection/src/change_detection_util.js +++ b/modules/change_detection/src/change_detection_util.js @@ -1,5 +1,5 @@ -import {isPresent, isBlank, BaseException, Type} from 'facade/lang'; -import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {isPresent, isBlank, BaseException, Type} from 'facade/src/lang'; +import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/src/collection'; import {ContextWithVariableBindings} from './parser/context_with_variable_bindings'; import {ArrayChanges} from './array_changes'; import {KeyValueChanges} from './keyvalue_changes'; diff --git a/modules/change_detection/src/coalesce.js b/modules/change_detection/src/coalesce.js index 2b2f087e37fce9..6fffda1f64d1c1 100644 --- a/modules/change_detection/src/coalesce.js +++ b/modules/change_detection/src/coalesce.js @@ -1,5 +1,5 @@ -import {isPresent} from 'facade/lang'; -import {List, ListWrapper, Map, MapWrapper} from 'facade/collection'; +import {isPresent} from 'facade/src/lang'; +import {List, ListWrapper, Map, MapWrapper} from 'facade/src/collection'; import {RECORD_TYPE_SELF, ProtoRecord} from './proto_change_detector'; /** diff --git a/modules/change_detection/src/dynamic_change_detector.js b/modules/change_detection/src/dynamic_change_detector.js index 0039f5e99f831e..544184ebab096d 100644 --- a/modules/change_detection/src/dynamic_change_detector.js +++ b/modules/change_detection/src/dynamic_change_detector.js @@ -1,5 +1,5 @@ -import {isPresent, isBlank, BaseException, FunctionWrapper} from 'facade/lang'; -import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {isPresent, isBlank, BaseException, FunctionWrapper} from 'facade/src/lang'; +import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/src/collection'; import {ContextWithVariableBindings} from './parser/context_with_variable_bindings'; import {AbstractChangeDetector} from './abstract_change_detector'; diff --git a/modules/change_detection/src/interfaces.js b/modules/change_detection/src/interfaces.js index 8e2cf5a3c8ace3..a824f2e363d6f8 100644 --- a/modules/change_detection/src/interfaces.js +++ b/modules/change_detection/src/interfaces.js @@ -1,4 +1,4 @@ -import {List} from 'facade/collection'; +import {List} from 'facade/src/collection'; export class ChangeRecord { bindingMemento:any; diff --git a/modules/change_detection/src/keyvalue_changes.js b/modules/change_detection/src/keyvalue_changes.js index f50f82488a0044..6420e0a0a01e88 100644 --- a/modules/change_detection/src/keyvalue_changes.js +++ b/modules/change_detection/src/keyvalue_changes.js @@ -1,6 +1,6 @@ -import {ListWrapper, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {ListWrapper, MapWrapper, StringMapWrapper} from 'facade/src/collection'; -import {stringify, looseIdentical, isJsObject} from 'facade/lang'; +import {stringify, looseIdentical, isJsObject} from 'facade/src/lang'; export class KeyValueChanges { _records:Map; diff --git a/modules/change_detection/src/parser/ast.js b/modules/change_detection/src/parser/ast.js index 5c5e3520fc8594..92ff157d616777 100644 --- a/modules/change_detection/src/parser/ast.js +++ b/modules/change_detection/src/parser/ast.js @@ -1,5 +1,5 @@ -import {FIELD, autoConvertAdd, isBlank, isPresent, FunctionWrapper, BaseException} from "facade/lang"; -import {List, Map, ListWrapper, StringMapWrapper} from "facade/collection"; +import {FIELD, autoConvertAdd, isBlank, isPresent, FunctionWrapper, BaseException} from "facade/src/lang"; +import {List, Map, ListWrapper, StringMapWrapper} from "facade/src/collection"; import {ContextWithVariableBindings} from "./context_with_variable_bindings"; export class AST { diff --git a/modules/change_detection/src/parser/context_with_variable_bindings.js b/modules/change_detection/src/parser/context_with_variable_bindings.js index 0ae0f325e54290..71ece1246757ba 100644 --- a/modules/change_detection/src/parser/context_with_variable_bindings.js +++ b/modules/change_detection/src/parser/context_with_variable_bindings.js @@ -1,5 +1,5 @@ -import {MapWrapper} from 'facade/collection'; -import {BaseException} from 'facade/lang'; +import {MapWrapper} from 'facade/src/collection'; +import {BaseException} from 'facade/src/lang'; export class ContextWithVariableBindings { parent:any; diff --git a/modules/change_detection/src/parser/lexer.js b/modules/change_detection/src/parser/lexer.js index 6c7148690423ef..3a8aef458eac5b 100644 --- a/modules/change_detection/src/parser/lexer.js +++ b/modules/change_detection/src/parser/lexer.js @@ -1,5 +1,5 @@ -import {List, ListWrapper, SetWrapper} from "facade/collection"; -import {int, FIELD, NumberWrapper, StringJoiner, StringWrapper} from "facade/lang"; +import {List, ListWrapper, SetWrapper} from "facade/src/collection"; +import {int, FIELD, NumberWrapper, StringJoiner, StringWrapper} from "facade/src/lang"; export const TOKEN_TYPE_CHARACTER = 1; export const TOKEN_TYPE_IDENTIFIER = 2; diff --git a/modules/change_detection/src/parser/parser.js b/modules/change_detection/src/parser/parser.js index df00dc2e18784c..a6e1d5588ef8a9 100644 --- a/modules/change_detection/src/parser/parser.js +++ b/modules/change_detection/src/parser/parser.js @@ -1,8 +1,8 @@ -import {FIELD, int, isBlank, isPresent, BaseException, StringWrapper, RegExpWrapper} from 'facade/lang'; -import {ListWrapper, List} from 'facade/collection'; +import {FIELD, int, isBlank, isPresent, BaseException, StringWrapper, RegExpWrapper} from 'facade/src/lang'; +import {ListWrapper, List} from 'facade/src/collection'; import {Lexer, EOF, Token, $PERIOD, $COLON, $SEMICOLON, $LBRACKET, $RBRACKET, $COMMA, $LBRACE, $RBRACE, $LPAREN, $RPAREN} from './lexer'; -import {reflector, Reflector} from 'reflection/reflection'; +import {reflector, Reflector} from 'reflection/src/reflection'; import { AST, EmptyExpr, diff --git a/modules/change_detection/src/proto_change_detector.js b/modules/change_detection/src/proto_change_detector.js index 7a969537903485..3dca29d2345b56 100644 --- a/modules/change_detection/src/proto_change_detector.js +++ b/modules/change_detection/src/proto_change_detector.js @@ -1,5 +1,5 @@ -import {isPresent, isBlank, BaseException, Type, isString} from 'facade/lang'; -import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {isPresent, isBlank, BaseException, Type, isString} from 'facade/src/lang'; +import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/src/collection'; import { AccessMember, diff --git a/modules/change_detection/test/array_changes_spec.js b/modules/change_detection/test/array_changes_spec.js index 6419799558fe36..c83695ff65080d 100644 --- a/modules/change_detection/test/array_changes_spec.js +++ b/modules/change_detection/test/array_changes_spec.js @@ -1,8 +1,8 @@ import {describe, it, iit, xit, expect, beforeEach, afterEach} from 'test_lib/test_lib'; -import {ArrayChanges} from 'change_detection/array_changes'; +import {ArrayChanges} from 'change_detection/src/array_changes'; -import {NumberWrapper} from 'facade/lang'; -import {ListWrapper, MapWrapper} from 'facade/collection'; +import {NumberWrapper} from 'facade/src/lang'; +import {ListWrapper, MapWrapper} from 'facade/src/collection'; import {TestIterable} from './iterable'; import {arrayChangesAsString} from './util'; diff --git a/modules/change_detection/test/change_detection_spec.js b/modules/change_detection/test/change_detection_spec.js index 30460d659068e9..7e92333686f4a1 100644 --- a/modules/change_detection/test/change_detection_spec.js +++ b/modules/change_detection/test/change_detection_spec.js @@ -1,18 +1,18 @@ import {ddescribe, describe, it, iit, xit, expect, beforeEach, afterEach, IS_DARTIUM} from 'test_lib/test_lib'; -import {isPresent, isBlank, isJsObject, BaseException, FunctionWrapper} from 'facade/lang'; -import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {isPresent, isBlank, isJsObject, BaseException, FunctionWrapper} from 'facade/src/lang'; +import {List, ListWrapper, MapWrapper, StringMapWrapper} from 'facade/src/collection'; -import {Parser} from 'change_detection/parser/parser'; -import {Lexer} from 'change_detection/parser/lexer'; -import {reflector} from 'reflection/reflection'; +import {Parser} from 'change_detection/src/parser/parser'; +import {Lexer} from 'change_detection/src/parser/lexer'; +import {reflector} from 'reflection/src/reflection'; import {arrayChangesAsString, kvChangesAsString} from './util'; import {ChangeDispatcher, DynamicChangeDetector, ChangeDetectionError, ContextWithVariableBindings} from 'change_detection/change_detection'; -import {JitProtoChangeDetector, DynamicProtoChangeDetector} from 'change_detection/proto_change_detector'; +import {JitProtoChangeDetector, DynamicProtoChangeDetector} from 'change_detection/src/proto_change_detector'; export function main() { diff --git a/modules/change_detection/test/coalesce_spec.js b/modules/change_detection/test/coalesce_spec.js index fcddcadcff1e66..0608af18ccd638 100644 --- a/modules/change_detection/test/coalesce_spec.js +++ b/modules/change_detection/test/coalesce_spec.js @@ -1,7 +1,7 @@ import {ddescribe, describe, it, iit, xit, expect, beforeEach, afterEach} from 'test_lib/test_lib'; -import {coalesce} from 'change_detection/coalesce'; -import {RECORD_TYPE_SELF, ProtoRecord} from 'change_detection/proto_change_detector'; +import {coalesce} from 'change_detection/src/coalesce'; +import {RECORD_TYPE_SELF, ProtoRecord} from 'change_detection/src/proto_change_detector'; export function main() { function r(funcOrValue, args, contextIndex, selfIndex, lastInBinding = false) { diff --git a/modules/change_detection/test/keyvalue_changes_spec.js b/modules/change_detection/test/keyvalue_changes_spec.js index 985a2d7fe416e4..bd559691e6a3e6 100644 --- a/modules/change_detection/test/keyvalue_changes_spec.js +++ b/modules/change_detection/test/keyvalue_changes_spec.js @@ -1,7 +1,7 @@ import {describe, it, iit, xit, expect, beforeEach, afterEach} from 'test_lib/test_lib'; -import {KeyValueChanges} from 'change_detection/keyvalue_changes'; -import {NumberWrapper, isJsObject} from 'facade/lang'; -import {MapWrapper} from 'facade/collection'; +import {KeyValueChanges} from 'change_detection/src/keyvalue_changes'; +import {NumberWrapper, isJsObject} from 'facade/src/lang'; +import {MapWrapper} from 'facade/src/collection'; import {kvChangesAsString} from './util'; // todo(vicb): Update the code & tests for object equality diff --git a/modules/change_detection/test/parser/context_with_variable_bindings_spec.js b/modules/change_detection/test/parser/context_with_variable_bindings_spec.js index 300badfa4391d6..6a6455487c4538 100644 --- a/modules/change_detection/test/parser/context_with_variable_bindings_spec.js +++ b/modules/change_detection/test/parser/context_with_variable_bindings_spec.js @@ -1,9 +1,9 @@ import {ddescribe, describe, it, xit, iit, expect, beforeEach} from 'test_lib/test_lib'; -import {ContextWithVariableBindings} from 'change_detection/parser/context_with_variable_bindings'; +import {ContextWithVariableBindings} from 'change_detection/src/parser/context_with_variable_bindings'; -import {BaseException, isBlank, isPresent} from 'facade/lang'; -import {MapWrapper, ListWrapper} from 'facade/collection'; +import {BaseException, isBlank, isPresent} from 'facade/src/lang'; +import {MapWrapper, ListWrapper} from 'facade/src/collection'; export function main() { describe('ContextWithVariableBindings', () => { diff --git a/modules/change_detection/test/parser/lexer_spec.js b/modules/change_detection/test/parser/lexer_spec.js index 5b17de715006be..fdaabf197d4436 100644 --- a/modules/change_detection/test/parser/lexer_spec.js +++ b/modules/change_detection/test/parser/lexer_spec.js @@ -1,9 +1,9 @@ import {describe, it, expect} from 'test_lib/test_lib'; -import {Lexer, Token} from 'change_detection/parser/lexer'; +import {Lexer, Token} from 'change_detection/src/parser/lexer'; -import {List, ListWrapper} from "facade/collection"; -import {StringWrapper, int} from "facade/lang"; +import {List, ListWrapper} from "facade/src/collection"; +import {StringWrapper, int} from "facade/src/lang"; function lex(text:string):List { return new Lexer().tokenize(text); diff --git a/modules/change_detection/test/parser/parser_spec.js b/modules/change_detection/test/parser/parser_spec.js index 87a515abd0b779..5fe8ebdf72665e 100644 --- a/modules/change_detection/test/parser/parser_spec.js +++ b/modules/change_detection/test/parser/parser_spec.js @@ -1,11 +1,11 @@ import {ddescribe, describe, it, xit, iit, expect, beforeEach} from 'test_lib/test_lib'; -import {BaseException, isBlank, isPresent} from 'facade/lang'; -import {reflector} from 'reflection/reflection'; -import {MapWrapper, ListWrapper} from 'facade/collection'; -import {Parser} from 'change_detection/parser/parser'; -import {Lexer} from 'change_detection/parser/lexer'; -import {ContextWithVariableBindings} from 'change_detection/parser/context_with_variable_bindings'; -import {Formatter, LiteralPrimitive} from 'change_detection/parser/ast'; +import {BaseException, isBlank, isPresent} from 'facade/src/lang'; +import {reflector} from 'reflection/src/reflection'; +import {MapWrapper, ListWrapper} from 'facade/src/collection'; +import {Parser} from 'change_detection/src/parser/parser'; +import {Lexer} from 'change_detection/src/parser/lexer'; +import {ContextWithVariableBindings} from 'change_detection/src/parser/context_with_variable_bindings'; +import {Formatter, LiteralPrimitive} from 'change_detection/src/parser/ast'; class TestData { a; diff --git a/modules/change_detection/test/util.js b/modules/change_detection/test/util.js index dc27ee747b1f10..bbc6b00604f329 100644 --- a/modules/change_detection/test/util.js +++ b/modules/change_detection/test/util.js @@ -1,4 +1,4 @@ -import {isBlank} from 'facade/lang'; +import {isBlank} from 'facade/src/lang'; export function arrayChangesAsString({collection, previous, additions, moves, removals}) { if (isBlank(collection)) collection = []; diff --git a/modules/core/core.js b/modules/core/core.js new file mode 100644 index 00000000000000..827a4c4c5af333 --- /dev/null +++ b/modules/core/core.js @@ -0,0 +1,12 @@ +export * from './src/annotations/annotations'; +export * from './src/compiler/interfaces'; +export * from './src/annotations/template_config'; + +export * from './src/application'; + +export * from './src/compiler/compiler'; +export * from './src/compiler/template_loader'; +export * from './src/compiler/view'; +export * from './src/compiler/viewport'; + +export * from './src/dom/element'; diff --git a/modules/core/src/annotations/annotations.js b/modules/core/src/annotations/annotations.js index 7155d0e77c6ccd..911fe20a729e72 100644 --- a/modules/core/src/annotations/annotations.js +++ b/modules/core/src/annotations/annotations.js @@ -1,5 +1,5 @@ -import {ABSTRACT, CONST, normalizeBlank} from 'facade/lang'; -import {List} from 'facade/collection'; +import {ABSTRACT, CONST, normalizeBlank} from 'facade/src/lang'; +import {List} from 'facade/src/collection'; import {TemplateConfig} from './template_config'; import {ShadowDomStrategy} from '../compiler/shadow_dom'; diff --git a/modules/core/src/annotations/events.js b/modules/core/src/annotations/events.js index bfe4d08baa95fc..1983c7ef2838f8 100644 --- a/modules/core/src/annotations/events.js +++ b/modules/core/src/annotations/events.js @@ -1,4 +1,4 @@ -import {CONST} from 'facade/lang'; +import {CONST} from 'facade/src/lang'; import {DependencyAnnotation} from 'di/di'; /** diff --git a/modules/core/src/annotations/template_config.js b/modules/core/src/annotations/template_config.js index dee67a90124ef9..a0990ee5bb350b 100644 --- a/modules/core/src/annotations/template_config.js +++ b/modules/core/src/annotations/template_config.js @@ -1,5 +1,5 @@ -import {ABSTRACT, CONST, Type} from 'facade/lang'; -import {List} from 'facade/collection'; +import {ABSTRACT, CONST, Type} from 'facade/src/lang'; +import {List} from 'facade/src/collection'; export class TemplateConfig { url:any; //string; diff --git a/modules/core/src/annotations/visibility.js b/modules/core/src/annotations/visibility.js index 3e2f4e67926a67..84e2da298a394b 100644 --- a/modules/core/src/annotations/visibility.js +++ b/modules/core/src/annotations/visibility.js @@ -1,4 +1,4 @@ -import {CONST} from 'facade/lang'; +import {CONST} from 'facade/src/lang'; import {DependencyAnnotation} from 'di/di'; /** diff --git a/modules/core/src/application.js b/modules/core/src/application.js index b744fba0a8263e..d9bdc8b42114f7 100644 --- a/modules/core/src/application.js +++ b/modules/core/src/application.js @@ -1,17 +1,17 @@ import {Injector, bind, OpaqueToken} from 'di/di'; -import {Type, FIELD, isBlank, isPresent, BaseException, assertionsEnabled, print} from 'facade/lang'; -import {DOM, Element} from 'facade/dom'; +import {Type, FIELD, isBlank, isPresent, BaseException, assertionsEnabled, print} from 'facade/src/lang'; +import {DOM, Element} from 'facade/src/dom'; import {Compiler, CompilerCache} from './compiler/compiler'; import {ProtoView} from './compiler/view'; -import {Reflector, reflector} from 'reflection/reflection'; +import {Reflector, reflector} from 'reflection/src/reflection'; import {Parser, Lexer, ChangeDetection, dynamicChangeDetection, jitChangeDetection} from 'change_detection/change_detection'; import {TemplateLoader} from './compiler/template_loader'; import {DirectiveMetadataReader} from './compiler/directive_metadata_reader'; import {DirectiveMetadata} from './compiler/directive_metadata'; -import {List, ListWrapper} from 'facade/collection'; -import {PromiseWrapper} from 'facade/async'; -import {VmTurnZone} from 'core/zone/vm_turn_zone'; -import {LifeCycle} from 'core/life_cycle/life_cycle'; +import {List, ListWrapper} from 'facade/src/collection'; +import {PromiseWrapper} from 'facade/src/async'; +import {VmTurnZone} from 'core/src/zone/vm_turn_zone'; +import {LifeCycle} from 'core/src/life_cycle/life_cycle'; var _rootInjector: Injector; diff --git a/modules/core/src/compiler/compiler.js b/modules/core/src/compiler/compiler.js index 56cb745d011ea7..301bd4b1bc7eff 100644 --- a/modules/core/src/compiler/compiler.js +++ b/modules/core/src/compiler/compiler.js @@ -1,7 +1,7 @@ -import {Type, FIELD, isBlank, isPresent, BaseException, stringify} from 'facade/lang'; -import {Promise, PromiseWrapper} from 'facade/async'; -import {List, ListWrapper, MapWrapper} from 'facade/collection'; -import {DOM, Element} from 'facade/dom'; +import {Type, FIELD, isBlank, isPresent, BaseException, stringify} from 'facade/src/lang'; +import {Promise, PromiseWrapper} from 'facade/src/async'; +import {List, ListWrapper, MapWrapper} from 'facade/src/collection'; +import {DOM, Element} from 'facade/src/dom'; import {ChangeDetection, Parser} from 'change_detection/change_detection'; diff --git a/modules/core/src/compiler/directive_metadata.js b/modules/core/src/compiler/directive_metadata.js index 0f868d8f97240f..3b735fcad26698 100644 --- a/modules/core/src/compiler/directive_metadata.js +++ b/modules/core/src/compiler/directive_metadata.js @@ -1,6 +1,6 @@ -import {Type} from 'facade/lang'; +import {Type} from 'facade/src/lang'; import {Directive} from '../annotations/annotations' -import {List} from 'facade/collection' +import {List} from 'facade/src/collection' import {ShadowDomStrategy} from './shadow_dom'; /** diff --git a/modules/core/src/compiler/directive_metadata_reader.js b/modules/core/src/compiler/directive_metadata_reader.js index 0fb0bcc3673103..9e85a099fcf268 100644 --- a/modules/core/src/compiler/directive_metadata_reader.js +++ b/modules/core/src/compiler/directive_metadata_reader.js @@ -1,8 +1,8 @@ -import {Type, isPresent, BaseException, stringify} from 'facade/lang'; -import {List, ListWrapper} from 'facade/collection'; +import {Type, isPresent, BaseException, stringify} from 'facade/src/lang'; +import {List, ListWrapper} from 'facade/src/collection'; import {Directive, Component} from '../annotations/annotations'; import {DirectiveMetadata} from './directive_metadata'; -import {reflector} from 'reflection/reflection'; +import {reflector} from 'reflection/src/reflection'; import {ShadowDom, ShadowDomStrategy, ShadowDomNative} from './shadow_dom'; export class DirectiveMetadataReader { diff --git a/modules/core/src/compiler/element_binder.js b/modules/core/src/compiler/element_binder.js index 126698cf5f59d7..3ddb64db67d3dd 100644 --- a/modules/core/src/compiler/element_binder.js +++ b/modules/core/src/compiler/element_binder.js @@ -1,8 +1,8 @@ import {ProtoElementInjector} from './element_injector'; -import {FIELD} from 'facade/lang'; -import {MapWrapper} from 'facade/collection'; +import {FIELD} from 'facade/src/lang'; +import {MapWrapper} from 'facade/src/collection'; import {DirectiveMetadata} from './directive_metadata'; -import {List, Map} from 'facade/collection'; +import {List, Map} from 'facade/src/collection'; import {ProtoView} from './view'; export class ElementBinder { diff --git a/modules/core/src/compiler/element_injector.js b/modules/core/src/compiler/element_injector.js index 2b9d44df2c5858..0c2b458d6302c2 100644 --- a/modules/core/src/compiler/element_injector.js +++ b/modules/core/src/compiler/element_injector.js @@ -1,15 +1,15 @@ -import {FIELD, isPresent, isBlank, Type, int, BaseException} from 'facade/lang'; -import {Math} from 'facade/math'; -import {List, ListWrapper, MapWrapper} from 'facade/collection'; +import {FIELD, isPresent, isBlank, Type, int, BaseException} from 'facade/src/lang'; +import {Math} from 'facade/src/math'; +import {List, ListWrapper, MapWrapper} from 'facade/src/collection'; import {Injector, Key, Dependency, bind, Binding, NoProviderError, ProviderError, CyclicDependencyError} from 'di/di'; -import {Parent, Ancestor} from 'core/annotations/visibility'; -import {EventEmitter} from 'core/annotations/events'; -import {onDestroy} from 'core/annotations/annotations'; -import {View, ProtoView} from 'core/compiler/view'; -import {LightDom, SourceLightDom, DestinationLightDom} from 'core/compiler/shadow_dom_emulation/light_dom'; -import {ViewPort} from 'core/compiler/viewport'; -import {NgElement} from 'core/dom/element'; -import {Directive} from 'core/annotations/annotations' +import {Parent, Ancestor} from 'core/src/annotations/visibility'; +import {EventEmitter} from 'core/src/annotations/events'; +import {onDestroy} from 'core/src/annotations/annotations'; +import {View, ProtoView} from 'core/src/compiler/view'; +import {LightDom, SourceLightDom, DestinationLightDom} from 'core/src/compiler/shadow_dom_emulation/light_dom'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {NgElement} from 'core/src/dom/element'; +import {Directive} from 'core/src/annotations/annotations' var _MAX_DIRECTIVE_CONSTRUCTION_COUNTER = 10; diff --git a/modules/core/src/compiler/pipeline/compile_control.js b/modules/core/src/compiler/pipeline/compile_control.js index 7a0013e1f29791..24cc0b32807cd0 100644 --- a/modules/core/src/compiler/pipeline/compile_control.js +++ b/modules/core/src/compiler/pipeline/compile_control.js @@ -1,6 +1,6 @@ -import {isBlank} from 'facade/lang'; -import {List, ListWrapper} from 'facade/collection'; -import {DOM, Element} from 'facade/dom'; +import {isBlank} from 'facade/src/lang'; +import {List, ListWrapper} from 'facade/src/collection'; +import {DOM, Element} from 'facade/src/dom'; import {CompileElement} from './compile_element'; import {CompileStep} from './compile_step'; diff --git a/modules/core/src/compiler/pipeline/compile_element.js b/modules/core/src/compiler/pipeline/compile_element.js index b0ab1171ef05ec..8a73b90cf9409e 100644 --- a/modules/core/src/compiler/pipeline/compile_element.js +++ b/modules/core/src/compiler/pipeline/compile_element.js @@ -1,6 +1,6 @@ -import {List, Map, ListWrapper, MapWrapper} from 'facade/collection'; -import {Element, DOM} from 'facade/dom'; -import {int, isBlank, isPresent, Type} from 'facade/lang'; +import {List, Map, ListWrapper, MapWrapper} from 'facade/src/collection'; +import {Element, DOM} from 'facade/src/dom'; +import {int, isBlank, isPresent, Type} from 'facade/src/lang'; import {DirectiveMetadata} from '../directive_metadata'; import {Decorator} from '../../annotations/annotations'; import {Component} from '../../annotations/annotations'; diff --git a/modules/core/src/compiler/pipeline/compile_pipeline.js b/modules/core/src/compiler/pipeline/compile_pipeline.js index 3d74a2b28ab777..012d022f07a072 100644 --- a/modules/core/src/compiler/pipeline/compile_pipeline.js +++ b/modules/core/src/compiler/pipeline/compile_pipeline.js @@ -1,6 +1,6 @@ -import {isPresent} from 'facade/lang'; -import {List, ListWrapper} from 'facade/collection'; -import {Element, Node, DOM} from 'facade/dom'; +import {isPresent} from 'facade/src/lang'; +import {List, ListWrapper} from 'facade/src/collection'; +import {Element, Node, DOM} from 'facade/src/dom'; import {CompileElement} from './compile_element'; import {CompileControl} from './compile_control'; import {CompileStep} from './compile_step'; diff --git a/modules/core/src/compiler/pipeline/default_steps.js b/modules/core/src/compiler/pipeline/default_steps.js index 02b53f95b0b45f..27f406475ef333 100644 --- a/modules/core/src/compiler/pipeline/default_steps.js +++ b/modules/core/src/compiler/pipeline/default_steps.js @@ -1,5 +1,5 @@ import {ChangeDetection, Parser} from 'change_detection/change_detection'; -import {List} from 'facade/collection'; +import {List} from 'facade/src/collection'; import {PropertyBindingParser} from './property_binding_parser'; import {TextInterpolationParser} from './text_interpolation_parser'; @@ -9,8 +9,8 @@ import {ElementBindingMarker} from './element_binding_marker'; import {ProtoViewBuilder} from './proto_view_builder'; import {ProtoElementInjectorBuilder} from './proto_element_injector_builder'; import {ElementBinderBuilder} from './element_binder_builder'; -import {DirectiveMetadata} from 'core/compiler/directive_metadata'; -import {stringify} from 'facade/lang'; +import {DirectiveMetadata} from 'core/src/compiler/directive_metadata'; +import {stringify} from 'facade/src/lang'; /** * Default steps used for compiling a template. diff --git a/modules/core/src/compiler/pipeline/directive_parser.js b/modules/core/src/compiler/pipeline/directive_parser.js index b272a7694e4706..2576cf32a8d03d 100644 --- a/modules/core/src/compiler/pipeline/directive_parser.js +++ b/modules/core/src/compiler/pipeline/directive_parser.js @@ -1,6 +1,6 @@ -import {isPresent, BaseException} from 'facade/lang'; -import {List, MapWrapper} from 'facade/collection'; -import {TemplateElement} from 'facade/dom'; +import {isPresent, BaseException} from 'facade/src/lang'; +import {List, MapWrapper} from 'facade/src/collection'; +import {TemplateElement} from 'facade/src/dom'; import {SelectorMatcher} from '../selector'; import {CssSelector} from '../selector'; diff --git a/modules/core/src/compiler/pipeline/element_binder_builder.js b/modules/core/src/compiler/pipeline/element_binder_builder.js index 282f33d36171a3..094d0d14538d22 100644 --- a/modules/core/src/compiler/pipeline/element_binder_builder.js +++ b/modules/core/src/compiler/pipeline/element_binder_builder.js @@ -1,8 +1,8 @@ -import {int, isPresent, isBlank, Type, BaseException, stringify} from 'facade/lang'; -import {Element, DOM} from 'facade/dom'; -import {ListWrapper, List, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {int, isPresent, isBlank, Type, BaseException, stringify} from 'facade/src/lang'; +import {Element, DOM} from 'facade/src/dom'; +import {ListWrapper, List, MapWrapper, StringMapWrapper} from 'facade/src/collection'; -import {reflector} from 'reflection/reflection'; +import {reflector} from 'reflection/src/reflection'; import {Parser, ProtoChangeDetector} from 'change_detection/change_detection'; diff --git a/modules/core/src/compiler/pipeline/element_binding_marker.js b/modules/core/src/compiler/pipeline/element_binding_marker.js index 441fd67f6aaf1d..4876e037bade56 100644 --- a/modules/core/src/compiler/pipeline/element_binding_marker.js +++ b/modules/core/src/compiler/pipeline/element_binding_marker.js @@ -1,6 +1,6 @@ -import {isPresent} from 'facade/lang'; -import {MapWrapper} from 'facade/collection'; -import {DOM} from 'facade/dom'; +import {isPresent} from 'facade/src/lang'; +import {MapWrapper} from 'facade/src/collection'; +import {DOM} from 'facade/src/dom'; import {CompileStep} from './compile_step'; import {CompileElement} from './compile_element'; diff --git a/modules/core/src/compiler/pipeline/property_binding_parser.js b/modules/core/src/compiler/pipeline/property_binding_parser.js index aed44b9dc8b06a..a5c75a127f656d 100644 --- a/modules/core/src/compiler/pipeline/property_binding_parser.js +++ b/modules/core/src/compiler/pipeline/property_binding_parser.js @@ -1,6 +1,6 @@ -import {isPresent, isBlank, RegExpWrapper, BaseException} from 'facade/lang'; -import {MapWrapper} from 'facade/collection'; -import {TemplateElement} from 'facade/dom'; +import {isPresent, isBlank, RegExpWrapper, BaseException} from 'facade/src/lang'; +import {MapWrapper} from 'facade/src/collection'; +import {TemplateElement} from 'facade/src/dom'; import {Parser, AST, ExpressionWithSource} from 'change_detection/change_detection'; diff --git a/modules/core/src/compiler/pipeline/proto_element_injector_builder.js b/modules/core/src/compiler/pipeline/proto_element_injector_builder.js index 3226a451f4a475..b77d321f88c53d 100644 --- a/modules/core/src/compiler/pipeline/proto_element_injector_builder.js +++ b/modules/core/src/compiler/pipeline/proto_element_injector_builder.js @@ -1,5 +1,5 @@ -import {isPresent, isBlank} from 'facade/lang'; -import {ListWrapper} from 'facade/collection'; +import {isPresent, isBlank} from 'facade/src/lang'; +import {ListWrapper} from 'facade/src/collection'; import {Key} from 'di/di'; import {ProtoElementInjector, ComponentKeyMetaData, DirectiveBinding} from '../element_injector'; diff --git a/modules/core/src/compiler/pipeline/proto_view_builder.js b/modules/core/src/compiler/pipeline/proto_view_builder.js index b1309a0cda7e05..b86d8161997f92 100644 --- a/modules/core/src/compiler/pipeline/proto_view_builder.js +++ b/modules/core/src/compiler/pipeline/proto_view_builder.js @@ -1,5 +1,5 @@ -import {isPresent, BaseException} from 'facade/lang'; -import {ListWrapper, MapWrapper} from 'facade/collection'; +import {isPresent, BaseException} from 'facade/src/lang'; +import {ListWrapper, MapWrapper} from 'facade/src/collection'; import {ProtoView} from '../view'; import {ChangeDetection} from 'change_detection/change_detection'; diff --git a/modules/core/src/compiler/pipeline/text_interpolation_parser.js b/modules/core/src/compiler/pipeline/text_interpolation_parser.js index 3d91cc398e35f2..54f56f48abc4e5 100644 --- a/modules/core/src/compiler/pipeline/text_interpolation_parser.js +++ b/modules/core/src/compiler/pipeline/text_interpolation_parser.js @@ -1,5 +1,5 @@ -import {RegExpWrapper, StringWrapper, isPresent} from 'facade/lang'; -import {Node, DOM} from 'facade/dom'; +import {RegExpWrapper, StringWrapper, isPresent} from 'facade/src/lang'; +import {Node, DOM} from 'facade/src/dom'; import {Parser} from 'change_detection/change_detection'; diff --git a/modules/core/src/compiler/pipeline/view_splitter.js b/modules/core/src/compiler/pipeline/view_splitter.js index 187274f496cc7b..2e5888b8106470 100644 --- a/modules/core/src/compiler/pipeline/view_splitter.js +++ b/modules/core/src/compiler/pipeline/view_splitter.js @@ -1,6 +1,6 @@ -import {isBlank, isPresent} from 'facade/lang'; -import {DOM, TemplateElement} from 'facade/dom'; -import {MapWrapper, ListWrapper} from 'facade/collection'; +import {isBlank, isPresent} from 'facade/src/lang'; +import {DOM, TemplateElement} from 'facade/src/dom'; +import {MapWrapper, ListWrapper} from 'facade/src/collection'; import {Parser} from 'change_detection/change_detection'; diff --git a/modules/core/src/compiler/selector.js b/modules/core/src/compiler/selector.js index a594c5bfa29391..2fc12c680257b7 100644 --- a/modules/core/src/compiler/selector.js +++ b/modules/core/src/compiler/selector.js @@ -1,5 +1,5 @@ -import {List, Map, ListWrapper, MapWrapper} from 'facade/collection'; -import {isPresent, isBlank, RegExpWrapper, RegExpMatcherWrapper, StringWrapper} from 'facade/lang'; +import {List, Map, ListWrapper, MapWrapper} from 'facade/src/collection'; +import {isPresent, isBlank, RegExpWrapper, RegExpMatcherWrapper, StringWrapper} from 'facade/src/lang'; const _EMPTY_ATTR_VALUE = ''; diff --git a/modules/core/src/compiler/shadow_dom_emulation/content_tag.js b/modules/core/src/compiler/shadow_dom_emulation/content_tag.js index c812f22e62e5df..2d9ff788228948 100644 --- a/modules/core/src/compiler/shadow_dom_emulation/content_tag.js +++ b/modules/core/src/compiler/shadow_dom_emulation/content_tag.js @@ -1,10 +1,10 @@ import {Decorator} from '../../annotations/annotations'; import {SourceLightDom, DestinationLightDom, LightDom} from './light_dom'; import {Inject} from 'di/di'; -import {Element, Node, DOM} from 'facade/dom'; -import {isPresent} from 'facade/lang'; -import {List, ListWrapper} from 'facade/collection'; -import {NgElement} from 'core/dom/element'; +import {Element, Node, DOM} from 'facade/src/dom'; +import {isPresent} from 'facade/src/lang'; +import {List, ListWrapper} from 'facade/src/collection'; +import {NgElement} from 'core/src/dom/element'; var _scriptTemplate = DOM.createScriptTag('type', 'ng/content') diff --git a/modules/core/src/compiler/shadow_dom_emulation/light_dom.js b/modules/core/src/compiler/shadow_dom_emulation/light_dom.js index 19cfc9ffda493c..fead98b6987720 100644 --- a/modules/core/src/compiler/shadow_dom_emulation/light_dom.js +++ b/modules/core/src/compiler/shadow_dom_emulation/light_dom.js @@ -1,6 +1,6 @@ -import {Element, Node, DOM} from 'facade/dom'; -import {List, ListWrapper} from 'facade/collection'; -import {isBlank, isPresent} from 'facade/lang'; +import {Element, Node, DOM} from 'facade/src/dom'; +import {List, ListWrapper} from 'facade/src/collection'; +import {isBlank, isPresent} from 'facade/src/lang'; import {View} from '../view'; import {ElementInjector} from '../element_injector'; diff --git a/modules/core/src/compiler/shadow_dom_strategy.js b/modules/core/src/compiler/shadow_dom_strategy.js index 38ca5a50c4e136..79815bda540b2a 100644 --- a/modules/core/src/compiler/shadow_dom_strategy.js +++ b/modules/core/src/compiler/shadow_dom_strategy.js @@ -1,6 +1,6 @@ -import {CONST} from 'facade/lang'; -import {DOM, Element} from 'facade/dom'; -import {List} from 'facade/collection'; +import {CONST} from 'facade/src/lang'; +import {DOM, Element} from 'facade/src/dom'; +import {List} from 'facade/src/collection'; import {View} from './view'; import {Content} from './shadow_dom_emulation/content_tag'; import {LightDom} from './shadow_dom_emulation/light_dom'; diff --git a/modules/core/src/compiler/template_loader.js b/modules/core/src/compiler/template_loader.js index 043a8d837cd5c1..850d1618336a17 100644 --- a/modules/core/src/compiler/template_loader.js +++ b/modules/core/src/compiler/template_loader.js @@ -1,5 +1,5 @@ -import {Promise} from 'facade/async'; -//import {Document} from 'facade/dom'; +import {Promise} from 'facade/src/async'; +//import {Document} from 'facade/src/dom'; /** * Strategy to load component templates. diff --git a/modules/core/src/compiler/view.js b/modules/core/src/compiler/view.js index 2fb81634470017..e2d41a609e01c6 100644 --- a/modules/core/src/compiler/view.js +++ b/modules/core/src/compiler/view.js @@ -1,15 +1,15 @@ -import {DOM, Element, Node, Text, DocumentFragment, TemplateElement} from 'facade/dom'; -import {ListWrapper, MapWrapper, StringMapWrapper, List} from 'facade/collection'; +import {DOM, Element, Node, Text, DocumentFragment, TemplateElement} from 'facade/src/dom'; +import {ListWrapper, MapWrapper, StringMapWrapper, List} from 'facade/src/collection'; import {AST, ContextWithVariableBindings, ChangeDispatcher, ProtoChangeDetector, ChangeDetector, ChangeRecord} from 'change_detection/change_detection'; import {ProtoElementInjector, ElementInjector, PreBuiltObjects} from './element_injector'; import {ElementBinder} from './element_binder'; import {DirectiveMetadata} from './directive_metadata'; -import {SetterFn} from 'reflection/types'; -import {FIELD, IMPLEMENTS, int, isPresent, isBlank, BaseException} from 'facade/lang'; +import {SetterFn} from 'reflection/src/types'; +import {FIELD, IMPLEMENTS, int, isPresent, isBlank, BaseException} from 'facade/src/lang'; import {Injector} from 'di/di'; -import {NgElement} from 'core/dom/element'; +import {NgElement} from 'core/src/dom/element'; import {ViewPort} from './viewport'; import {OnChange} from './interfaces'; import {Content} from './shadow_dom_emulation/content_tag'; diff --git a/modules/core/src/compiler/viewport.js b/modules/core/src/compiler/viewport.js index 51ca5bb23944c4..2c688f8b54c9e3 100644 --- a/modules/core/src/compiler/viewport.js +++ b/modules/core/src/compiler/viewport.js @@ -1,10 +1,10 @@ import {View, ProtoView} from './view'; -import {DOM, Node, Element} from 'facade/dom'; -import {ListWrapper, MapWrapper, List} from 'facade/collection'; -import {BaseException} from 'facade/lang'; +import {DOM, Node, Element} from 'facade/src/dom'; +import {ListWrapper, MapWrapper, List} from 'facade/src/collection'; +import {BaseException} from 'facade/src/lang'; import {Injector} from 'di/di'; -import {ElementInjector} from 'core/compiler/element_injector'; -import {isPresent, isBlank} from 'facade/lang'; +import {ElementInjector} from 'core/src/compiler/element_injector'; +import {isPresent, isBlank} from 'facade/src/lang'; export class ViewPort { parentView: View; diff --git a/modules/core/src/core.js b/modules/core/src/core.js deleted file mode 100644 index a6ca957c08ebdd..00000000000000 --- a/modules/core/src/core.js +++ /dev/null @@ -1,12 +0,0 @@ -export * from './annotations/annotations'; -export * from './compiler/interfaces'; -export * from './annotations/template_config'; - -export * from './application'; - -export * from './compiler/compiler'; -export * from './compiler/template_loader'; -export * from './compiler/view'; -export * from './compiler/viewport'; - -export * from './dom/element'; diff --git a/modules/core/src/dom/element.js b/modules/core/src/dom/element.js index 056b184c633d60..ec7930113ebf5c 100644 --- a/modules/core/src/dom/element.js +++ b/modules/core/src/dom/element.js @@ -1,5 +1,5 @@ -import {DOM, Element} from 'facade/dom'; -import {normalizeBlank} from 'facade/lang'; +import {DOM, Element} from 'facade/src/dom'; +import {normalizeBlank} from 'facade/src/lang'; export class NgElement { domElement:Element; diff --git a/modules/core/src/life_cycle/life_cycle.js b/modules/core/src/life_cycle/life_cycle.js index 38f0e71fc62eb8..18ab438d6bf95f 100644 --- a/modules/core/src/life_cycle/life_cycle.js +++ b/modules/core/src/life_cycle/life_cycle.js @@ -1,7 +1,7 @@ -import {FIELD, print} from 'facade/lang'; +import {FIELD, print} from 'facade/src/lang'; import {ChangeDetector} from 'change_detection/change_detection'; -import {VmTurnZone} from 'core/zone/vm_turn_zone'; -import {ListWrapper} from 'facade/collection'; +import {VmTurnZone} from 'core/src/zone/vm_turn_zone'; +import {ListWrapper} from 'facade/src/collection'; export class LifeCycle { _changeDetector:ChangeDetector; diff --git a/modules/core/src/zone/vm_turn_zone.es6 b/modules/core/src/zone/vm_turn_zone.es6 index 2377c0d6a76042..83ab359cc54115 100644 --- a/modules/core/src/zone/vm_turn_zone.es6 +++ b/modules/core/src/zone/vm_turn_zone.es6 @@ -1,5 +1,5 @@ -import {List, ListWrapper, StringMapWrapper} from 'facade/collection'; -import {normalizeBlank, isPresent} from 'facade/lang'; +import {List, ListWrapper, StringMapWrapper} from 'facade/src/collection'; +import {normalizeBlank, isPresent} from 'facade/src/lang'; export class VmTurnZone { _outerZone; diff --git a/modules/core/test/application_spec.js b/modules/core/test/application_spec.js index 3e80c52125ce0b..254ab8879170fb 100644 --- a/modules/core/test/application_spec.js +++ b/modules/core/test/application_spec.js @@ -1,12 +1,12 @@ import {describe, ddescribe, it, iit, xit, xdescribe, expect, beforeEach} from 'test_lib/test_lib'; import {bootstrap, appDocumentToken, appElementToken} - from 'core/application'; -import {Component} from 'core/annotations/annotations'; -import {DOM} from 'facade/dom'; -import {ListWrapper} from 'facade/collection'; -import {PromiseWrapper} from 'facade/async'; + from 'core/src/application'; +import {Component} from 'core/src/annotations/annotations'; +import {DOM} from 'facade/src/dom'; +import {ListWrapper} from 'facade/src/collection'; +import {PromiseWrapper} from 'facade/src/async'; import {bind, Inject} from 'di/di'; -import {TemplateConfig} from 'core/annotations/template_config'; +import {TemplateConfig} from 'core/src/annotations/template_config'; @Component({ selector: 'hello-app', diff --git a/modules/core/test/compiler/compiler_spec.js b/modules/core/test/compiler/compiler_spec.js index a5371cda83c676..82a2387733cd39 100644 --- a/modules/core/test/compiler/compiler_spec.js +++ b/modules/core/test/compiler/compiler_spec.js @@ -1,16 +1,16 @@ import {describe, beforeEach, it, expect, ddescribe, iit, el} from 'test_lib/test_lib'; -import {DOM} from 'facade/dom'; -import {List} from 'facade/collection'; - -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {ProtoView} from 'core/compiler/view'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {TemplateLoader} from 'core/compiler/template_loader'; -import {Component} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; -import {CompileElement} from 'core/compiler/pipeline/compile_element'; -import {CompileStep} from 'core/compiler/pipeline/compile_step' -import {CompileControl} from 'core/compiler/pipeline/compile_control'; +import {DOM} from 'facade/src/dom'; +import {List} from 'facade/src/collection'; + +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {ProtoView} from 'core/src/compiler/view'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {TemplateLoader} from 'core/src/compiler/template_loader'; +import {Component} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; +import {CompileElement} from 'core/src/compiler/pipeline/compile_element'; +import {CompileStep} from 'core/src/compiler/pipeline/compile_step' +import {CompileControl} from 'core/src/compiler/pipeline/compile_control'; import {Lexer, Parser, dynamicChangeDetection} from 'change_detection/change_detection'; diff --git a/modules/core/test/compiler/directive_metadata_reader_spec.js b/modules/core/test/compiler/directive_metadata_reader_spec.js index 56e71c4734f631..a32a5d38fd153e 100644 --- a/modules/core/test/compiler/directive_metadata_reader_spec.js +++ b/modules/core/test/compiler/directive_metadata_reader_spec.js @@ -1,10 +1,10 @@ import {ddescribe, describe, it, iit, expect, beforeEach} from 'test_lib/test_lib'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {Decorator, Component} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; -import {DirectiveMetadata} from 'core/compiler/directive_metadata'; -import {ShadowDomStrategy, ShadowDomNative} from 'core/compiler/shadow_dom'; -import {CONST} from 'facade/lang'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {Decorator, Component} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; +import {DirectiveMetadata} from 'core/src/compiler/directive_metadata'; +import {ShadowDomStrategy, ShadowDomNative} from 'core/src/compiler/shadow_dom'; +import {CONST} from 'facade/src/lang'; class FakeShadowDomStrategy extends ShadowDomStrategy { diff --git a/modules/core/test/compiler/element_injector_spec.js b/modules/core/test/compiler/element_injector_spec.js index 61ec3ca1703d48..1ddf6a3f222aca 100644 --- a/modules/core/test/compiler/element_injector_spec.js +++ b/modules/core/test/compiler/element_injector_spec.js @@ -1,17 +1,17 @@ import {describe, ddescribe, it, iit, xit, xdescribe, expect, beforeEach, SpyObject} from 'test_lib/test_lib'; -import {isBlank, isPresent, FIELD, IMPLEMENTS, proxy} from 'facade/lang'; -import {ListWrapper, MapWrapper, List} from 'facade/collection'; -import {ProtoElementInjector, PreBuiltObjects, DirectiveBinding} from 'core/compiler/element_injector'; -import {Parent, Ancestor} from 'core/annotations/visibility'; -import {EventEmitter} from 'core/annotations/events'; -import {onDestroy} from 'core/annotations/annotations'; +import {isBlank, isPresent, FIELD, IMPLEMENTS, proxy} from 'facade/src/lang'; +import {ListWrapper, MapWrapper, List} from 'facade/src/collection'; +import {ProtoElementInjector, PreBuiltObjects, DirectiveBinding} from 'core/src/compiler/element_injector'; +import {Parent, Ancestor} from 'core/src/annotations/visibility'; +import {EventEmitter} from 'core/src/annotations/events'; +import {onDestroy} from 'core/src/annotations/annotations'; import {Injector, Inject, bind} from 'di/di'; -import {View} from 'core/compiler/view'; +import {View} from 'core/src/compiler/view'; import {ProtoRecordRange} from 'change_detection/change_detection'; -import {ViewPort} from 'core/compiler/viewport'; -import {NgElement} from 'core/dom/element'; -import {LightDom, SourceLightDom, DestinationLightDom} from 'core/compiler/shadow_dom_emulation/light_dom'; -import {Directive} from 'core/annotations/annotations'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {NgElement} from 'core/src/dom/element'; +import {LightDom, SourceLightDom, DestinationLightDom} from 'core/src/compiler/shadow_dom_emulation/light_dom'; +import {Directive} from 'core/src/annotations/annotations'; @proxy @IMPLEMENTS(View) diff --git a/modules/core/test/compiler/integration_spec.js b/modules/core/test/compiler/integration_spec.js index 7aad9aa34ec85d..c191b7a57c8449 100644 --- a/modules/core/test/compiler/integration_spec.js +++ b/modules/core/test/compiler/integration_spec.js @@ -1,19 +1,19 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, el} from 'test_lib/test_lib'; -import {DOM} from 'facade/dom'; +import {DOM} from 'facade/src/dom'; import {Injector} from 'di/di'; import {Lexer, Parser, ChangeDetector, dynamicChangeDetection} from 'change_detection/change_detection'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {ShadowDomEmulated} from 'core/compiler/shadow_dom'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {ShadowDomEmulated} from 'core/src/compiler/shadow_dom'; -import {Decorator, Component, Template} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; +import {Decorator, Component, Template} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; -import {ViewPort} from 'core/compiler/viewport'; -import {MapWrapper} from 'facade/collection'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {MapWrapper} from 'facade/src/collection'; export function main() { describe('integration tests', function() { diff --git a/modules/core/test/compiler/pipeline/directive_parser_spec.js b/modules/core/test/compiler/pipeline/directive_parser_spec.js index 87eb23a39ca1e0..6bdc76d780fff4 100644 --- a/modules/core/test/compiler/pipeline/directive_parser_spec.js +++ b/modules/core/test/compiler/pipeline/directive_parser_spec.js @@ -1,17 +1,17 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {isPresent} from 'facade/lang'; -import {ListWrapper, MapWrapper, StringMapWrapper} from 'facade/collection'; -import {DirectiveParser} from 'core/compiler/pipeline/directive_parser'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {CompileStep} from 'core/compiler/pipeline/compile_step'; -import {CompileElement} from 'core/compiler/pipeline/compile_element'; -import {CompileControl} from 'core/compiler/pipeline/compile_control'; -import {DOM} from 'facade/dom'; -import {Component} from 'core/annotations/annotations'; -import {Decorator} from 'core/annotations/annotations'; -import {Template} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; +import {isPresent} from 'facade/src/lang'; +import {ListWrapper, MapWrapper, StringMapWrapper} from 'facade/src/collection'; +import {DirectiveParser} from 'core/src/compiler/pipeline/directive_parser'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {CompileStep} from 'core/src/compiler/pipeline/compile_step'; +import {CompileElement} from 'core/src/compiler/pipeline/compile_element'; +import {CompileControl} from 'core/src/compiler/pipeline/compile_control'; +import {DOM} from 'facade/src/dom'; +import {Component} from 'core/src/annotations/annotations'; +import {Decorator} from 'core/src/annotations/annotations'; +import {Template} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; import {Lexer, Parser} from 'change_detection/change_detection'; export function main() { diff --git a/modules/core/test/compiler/pipeline/element_binder_builder_spec.js b/modules/core/test/compiler/pipeline/element_binder_builder_spec.js index b0532cb9e77610..1cc6b5605a1340 100644 --- a/modules/core/test/compiler/pipeline/element_binder_builder_spec.js +++ b/modules/core/test/compiler/pipeline/element_binder_builder_spec.js @@ -1,20 +1,20 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {isPresent} from 'facade/lang'; -import {DOM} from 'facade/dom'; -import {ListWrapper, MapWrapper} from 'facade/collection'; - -import {ElementBinderBuilder} from 'core/compiler/pipeline/element_binder_builder'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {CompileElement} from 'core/compiler/pipeline/compile_element'; -import {CompileStep} from 'core/compiler/pipeline/compile_step' -import {CompileControl} from 'core/compiler/pipeline/compile_control'; - -import {Decorator} from 'core/annotations/annotations'; -import {Template} from 'core/annotations/annotations'; -import {Component} from 'core/annotations/annotations'; -import {ProtoView, ElementPropertyMemento, DirectivePropertyMemento} from 'core/compiler/view'; -import {ProtoElementInjector} from 'core/compiler/element_injector'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; +import {isPresent} from 'facade/src/lang'; +import {DOM} from 'facade/src/dom'; +import {ListWrapper, MapWrapper} from 'facade/src/collection'; + +import {ElementBinderBuilder} from 'core/src/compiler/pipeline/element_binder_builder'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {CompileElement} from 'core/src/compiler/pipeline/compile_element'; +import {CompileStep} from 'core/src/compiler/pipeline/compile_step' +import {CompileControl} from 'core/src/compiler/pipeline/compile_control'; + +import {Decorator} from 'core/src/annotations/annotations'; +import {Template} from 'core/src/annotations/annotations'; +import {Component} from 'core/src/annotations/annotations'; +import {ProtoView, ElementPropertyMemento, DirectivePropertyMemento} from 'core/src/compiler/view'; +import {ProtoElementInjector} from 'core/src/compiler/element_injector'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; import {ChangeDetector, Lexer, Parser, DynamicProtoChangeDetector, } from 'change_detection/change_detection'; diff --git a/modules/core/test/compiler/pipeline/element_binding_marker_spec.js b/modules/core/test/compiler/pipeline/element_binding_marker_spec.js index f5a543d3b609e6..4c53f407c86346 100644 --- a/modules/core/test/compiler/pipeline/element_binding_marker_spec.js +++ b/modules/core/test/compiler/pipeline/element_binding_marker_spec.js @@ -1,15 +1,15 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {isPresent} from 'facade/lang'; -import {DOM} from 'facade/dom'; -import {MapWrapper} from 'facade/collection'; - -import {ElementBindingMarker} from 'core/compiler/pipeline/element_binding_marker'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {CompileElement} from 'core/compiler/pipeline/compile_element'; -import {CompileStep} from 'core/compiler/pipeline/compile_step' -import {CompileControl} from 'core/compiler/pipeline/compile_control'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {Template, Decorator, Component} from 'core/annotations/annotations'; +import {isPresent} from 'facade/src/lang'; +import {DOM} from 'facade/src/dom'; +import {MapWrapper} from 'facade/src/collection'; + +import {ElementBindingMarker} from 'core/src/compiler/pipeline/element_binding_marker'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {CompileElement} from 'core/src/compiler/pipeline/compile_element'; +import {CompileStep} from 'core/src/compiler/pipeline/compile_step' +import {CompileControl} from 'core/src/compiler/pipeline/compile_control'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {Template, Decorator, Component} from 'core/src/annotations/annotations'; export function main() { describe('ElementBindingMarker', () => { diff --git a/modules/core/test/compiler/pipeline/pipeline_spec.js b/modules/core/test/compiler/pipeline/pipeline_spec.js index 1058396092a580..195ee17966c9f5 100644 --- a/modules/core/test/compiler/pipeline/pipeline_spec.js +++ b/modules/core/test/compiler/pipeline/pipeline_spec.js @@ -1,12 +1,12 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {ListWrapper, List, MapWrapper} from 'facade/collection'; -import {DOM} from 'facade/dom'; -import {isPresent, NumberWrapper, StringWrapper} from 'facade/lang'; - -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {CompileElement} from 'core/compiler/pipeline/compile_element'; -import {CompileStep} from 'core/compiler/pipeline/compile_step' -import {CompileControl} from 'core/compiler/pipeline/compile_control'; +import {ListWrapper, List, MapWrapper} from 'facade/src/collection'; +import {DOM} from 'facade/src/dom'; +import {isPresent, NumberWrapper, StringWrapper} from 'facade/src/lang'; + +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {CompileElement} from 'core/src/compiler/pipeline/compile_element'; +import {CompileStep} from 'core/src/compiler/pipeline/compile_step' +import {CompileControl} from 'core/src/compiler/pipeline/compile_control'; export function main() { describe('compile_pipeline', () => { diff --git a/modules/core/test/compiler/pipeline/property_binding_parser_spec.js b/modules/core/test/compiler/pipeline/property_binding_parser_spec.js index 157765a808e114..354634d8b00f3f 100644 --- a/modules/core/test/compiler/pipeline/property_binding_parser_spec.js +++ b/modules/core/test/compiler/pipeline/property_binding_parser_spec.js @@ -1,8 +1,8 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {PropertyBindingParser} from 'core/compiler/pipeline/property_binding_parser'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {DOM} from 'facade/dom'; -import {MapWrapper} from 'facade/collection'; +import {PropertyBindingParser} from 'core/src/compiler/pipeline/property_binding_parser'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {DOM} from 'facade/src/dom'; +import {MapWrapper} from 'facade/src/collection'; import {Lexer, Parser} from 'change_detection/change_detection'; diff --git a/modules/core/test/compiler/pipeline/proto_element_injector_builder_spec.js b/modules/core/test/compiler/pipeline/proto_element_injector_builder_spec.js index b8b5714a301267..85fdf309c462b9 100644 --- a/modules/core/test/compiler/pipeline/proto_element_injector_builder_spec.js +++ b/modules/core/test/compiler/pipeline/proto_element_injector_builder_spec.js @@ -1,17 +1,17 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {isPresent, isBlank} from 'facade/lang'; -import {DOM} from 'facade/dom'; -import {List, ListWrapper} from 'facade/collection'; - -import {ProtoElementInjectorBuilder} from 'core/compiler/pipeline/proto_element_injector_builder'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {CompileElement} from 'core/compiler/pipeline/compile_element'; -import {CompileStep} from 'core/compiler/pipeline/compile_step' -import {CompileControl} from 'core/compiler/pipeline/compile_control'; -import {ProtoView} from 'core/compiler/view'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {Template, Decorator, Component} from 'core/annotations/annotations'; -import {ProtoElementInjector} from 'core/compiler/element_injector'; +import {isPresent, isBlank} from 'facade/src/lang'; +import {DOM} from 'facade/src/dom'; +import {List, ListWrapper} from 'facade/src/collection'; + +import {ProtoElementInjectorBuilder} from 'core/src/compiler/pipeline/proto_element_injector_builder'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {CompileElement} from 'core/src/compiler/pipeline/compile_element'; +import {CompileStep} from 'core/src/compiler/pipeline/compile_step' +import {CompileControl} from 'core/src/compiler/pipeline/compile_control'; +import {ProtoView} from 'core/src/compiler/view'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {Template, Decorator, Component} from 'core/src/annotations/annotations'; +import {ProtoElementInjector} from 'core/src/compiler/element_injector'; export function main() { describe('ProtoElementInjectorBuilder', () => { diff --git a/modules/core/test/compiler/pipeline/proto_view_builder_spec.js b/modules/core/test/compiler/pipeline/proto_view_builder_spec.js index d8d4e82c79739c..631cb9dd92f51e 100644 --- a/modules/core/test/compiler/pipeline/proto_view_builder_spec.js +++ b/modules/core/test/compiler/pipeline/proto_view_builder_spec.js @@ -1,14 +1,14 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {isPresent} from 'facade/lang'; +import {isPresent} from 'facade/src/lang'; import {dynamicChangeDetection} from 'change_detection/change_detection'; -import {ElementBinder} from 'core/compiler/element_binder'; -import {ProtoViewBuilder} from 'core/compiler/pipeline/proto_view_builder'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {CompileElement} from 'core/compiler/pipeline/compile_element'; -import {CompileStep} from 'core/compiler/pipeline/compile_step' -import {CompileControl} from 'core/compiler/pipeline/compile_control'; -import {DOM} from 'facade/dom'; -import {MapWrapper} from 'facade/collection'; +import {ElementBinder} from 'core/src/compiler/element_binder'; +import {ProtoViewBuilder} from 'core/src/compiler/pipeline/proto_view_builder'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {CompileElement} from 'core/src/compiler/pipeline/compile_element'; +import {CompileStep} from 'core/src/compiler/pipeline/compile_step' +import {CompileControl} from 'core/src/compiler/pipeline/compile_control'; +import {DOM} from 'facade/src/dom'; +import {MapWrapper} from 'facade/src/collection'; export function main() { describe('ProtoViewBuilder', () => { diff --git a/modules/core/test/compiler/pipeline/text_interpolation_parser_spec.js b/modules/core/test/compiler/pipeline/text_interpolation_parser_spec.js index 94ce36768ce63e..da306a21be0b51 100644 --- a/modules/core/test/compiler/pipeline/text_interpolation_parser_spec.js +++ b/modules/core/test/compiler/pipeline/text_interpolation_parser_spec.js @@ -1,8 +1,8 @@ import {describe, beforeEach, expect, it, iit, ddescribe, el} from 'test_lib/test_lib'; -import {TextInterpolationParser} from 'core/compiler/pipeline/text_interpolation_parser'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {DOM} from 'facade/dom'; -import {MapWrapper} from 'facade/collection'; +import {TextInterpolationParser} from 'core/src/compiler/pipeline/text_interpolation_parser'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {DOM} from 'facade/src/dom'; +import {MapWrapper} from 'facade/src/collection'; import {Lexer, Parser} from 'change_detection/change_detection'; import {IgnoreChildrenStep} from './pipeline_spec'; diff --git a/modules/core/test/compiler/pipeline/view_splitter_spec.js b/modules/core/test/compiler/pipeline/view_splitter_spec.js index 839a5e4047573d..66b69d876b48e6 100644 --- a/modules/core/test/compiler/pipeline/view_splitter_spec.js +++ b/modules/core/test/compiler/pipeline/view_splitter_spec.js @@ -1,10 +1,10 @@ import {describe, beforeEach, it, expect, iit, ddescribe, el} from 'test_lib/test_lib'; -import {isPresent} from 'facade/lang'; -import {MapWrapper} from 'facade/collection'; +import {isPresent} from 'facade/src/lang'; +import {MapWrapper} from 'facade/src/collection'; -import {ViewSplitter} from 'core/compiler/pipeline/view_splitter'; -import {CompilePipeline} from 'core/compiler/pipeline/compile_pipeline'; -import {DOM, TemplateElement} from 'facade/dom'; +import {ViewSplitter} from 'core/src/compiler/pipeline/view_splitter'; +import {CompilePipeline} from 'core/src/compiler/pipeline/compile_pipeline'; +import {DOM, TemplateElement} from 'facade/src/dom'; import {Lexer, Parser} from 'change_detection/change_detection'; diff --git a/modules/core/test/compiler/selector_spec.js b/modules/core/test/compiler/selector_spec.js index 6e124ed0e8f17d..3f1758525b53e3 100644 --- a/modules/core/test/compiler/selector_spec.js +++ b/modules/core/test/compiler/selector_spec.js @@ -1,8 +1,8 @@ import {describe, it, expect, beforeEach, ddescribe, iit, xit, el} from 'test_lib/test_lib'; -import {SelectorMatcher} from 'core/compiler/selector'; -import {CssSelector} from 'core/compiler/selector'; -import {List, ListWrapper, MapWrapper} from 'facade/collection'; -import {DOM} from 'facade/dom'; +import {SelectorMatcher} from 'core/src/compiler/selector'; +import {CssSelector} from 'core/src/compiler/selector'; +import {List, ListWrapper, MapWrapper} from 'facade/src/collection'; +import {DOM} from 'facade/src/dom'; export function main() { describe('SelectorMatcher', () => { diff --git a/modules/core/test/compiler/shadow_dom/content_tag_spec.js b/modules/core/test/compiler/shadow_dom/content_tag_spec.js index cf5359d65cc658..b0277528366bff 100644 --- a/modules/core/test/compiler/shadow_dom/content_tag_spec.js +++ b/modules/core/test/compiler/shadow_dom/content_tag_spec.js @@ -1,9 +1,9 @@ import {describe, beforeEach, it, expect, ddescribe, iit, SpyObject, el} from 'test_lib/test_lib'; -import {proxy, IMPLEMENTS} from 'facade/lang'; -import {DOM} from 'facade/dom'; -import {Content} from 'core/compiler/shadow_dom_emulation/content_tag'; -import {NgElement} from 'core/dom/element'; -import {LightDom} from 'core/compiler/shadow_dom_emulation/light_dom'; +import {proxy, IMPLEMENTS} from 'facade/src/lang'; +import {DOM} from 'facade/src/dom'; +import {Content} from 'core/src/compiler/shadow_dom_emulation/content_tag'; +import {NgElement} from 'core/src/dom/element'; +import {LightDom} from 'core/src/compiler/shadow_dom_emulation/light_dom'; @proxy @IMPLEMENTS(LightDom) diff --git a/modules/core/test/compiler/shadow_dom/light_dom_spec.js b/modules/core/test/compiler/shadow_dom/light_dom_spec.js index da73706605b927..39842452a5bf8e 100644 --- a/modules/core/test/compiler/shadow_dom/light_dom_spec.js +++ b/modules/core/test/compiler/shadow_dom/light_dom_spec.js @@ -1,13 +1,13 @@ import {describe, beforeEach, it, expect, ddescribe, iit, SpyObject, el} from 'test_lib/test_lib'; -import {proxy, IMPLEMENTS, isBlank} from 'facade/lang'; -import {ListWrapper, MapWrapper} from 'facade/collection'; -import {DOM} from 'facade/dom'; -import {Content} from 'core/compiler/shadow_dom_emulation/content_tag'; -import {NgElement} from 'core/dom/element'; -import {LightDom} from 'core/compiler/shadow_dom_emulation/light_dom'; -import {View} from 'core/compiler/view'; -import {ViewPort} from 'core/compiler/viewport'; -import {ElementInjector} from 'core/compiler/element_injector'; +import {proxy, IMPLEMENTS, isBlank} from 'facade/src/lang'; +import {ListWrapper, MapWrapper} from 'facade/src/collection'; +import {DOM} from 'facade/src/dom'; +import {Content} from 'core/src/compiler/shadow_dom_emulation/content_tag'; +import {NgElement} from 'core/src/dom/element'; +import {LightDom} from 'core/src/compiler/shadow_dom_emulation/light_dom'; +import {View} from 'core/src/compiler/view'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {ElementInjector} from 'core/src/compiler/element_injector'; import {ProtoRecordRange} from 'change_detection/change_detection'; @proxy diff --git a/modules/core/test/compiler/shadow_dom/shadow_dom_emulation_integration_spec.js b/modules/core/test/compiler/shadow_dom/shadow_dom_emulation_integration_spec.js index ae8029e5e0f5bc..5078e5e03c32cd 100644 --- a/modules/core/test/compiler/shadow_dom/shadow_dom_emulation_integration_spec.js +++ b/modules/core/test/compiler/shadow_dom/shadow_dom_emulation_integration_spec.js @@ -1,20 +1,20 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, el} from 'test_lib/test_lib'; -import {DOM} from 'facade/dom'; +import {DOM} from 'facade/src/dom'; import {Injector} from 'di/di'; import {Lexer, Parser, ChangeDetector, dynamicChangeDetection} from 'change_detection/change_detection'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {LifeCycle} from 'core/life_cycle/life_cycle'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {ShadowDomStrategy, ShadowDomNative, ShadowDomEmulated} from 'core/compiler/shadow_dom'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {LifeCycle} from 'core/src/life_cycle/life_cycle'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {ShadowDomStrategy, ShadowDomNative, ShadowDomEmulated} from 'core/src/compiler/shadow_dom'; -import {Decorator, Component, Template} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; +import {Decorator, Component, Template} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; -import {ViewPort} from 'core/compiler/viewport'; -import {StringMapWrapper, MapWrapper} from 'facade/collection'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {StringMapWrapper, MapWrapper} from 'facade/src/collection'; export function main() { describe('integration tests', function() { diff --git a/modules/core/test/compiler/view_spec.js b/modules/core/test/compiler/view_spec.js index fcceaebaaaa44e..8cd68424c54a9a 100644 --- a/modules/core/test/compiler/view_spec.js +++ b/modules/core/test/compiler/view_spec.js @@ -1,21 +1,21 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, el} from 'test_lib/test_lib'; -import {ProtoView, ElementPropertyMemento, DirectivePropertyMemento} from 'core/compiler/view'; -import {ProtoElementInjector, ElementInjector} from 'core/compiler/element_injector'; -import {ShadowDomEmulated} from 'core/compiler/shadow_dom'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {Component, Decorator, Template} from 'core/annotations/annotations'; +import {ProtoView, ElementPropertyMemento, DirectivePropertyMemento} from 'core/src/compiler/view'; +import {ProtoElementInjector, ElementInjector} from 'core/src/compiler/element_injector'; +import {ShadowDomEmulated} from 'core/src/compiler/shadow_dom'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {Component, Decorator, Template} from 'core/src/annotations/annotations'; import {OnChange} from 'core/core'; import {Lexer, Parser, DynamicProtoChangeDetector, ChangeDetector} from 'change_detection/change_detection'; -import {TemplateConfig} from 'core/annotations/template_config'; -import {EventEmitter} from 'core/annotations/events'; -import {List, MapWrapper} from 'facade/collection'; -import {DOM, Element} from 'facade/dom'; -import {int, proxy, IMPLEMENTS} from 'facade/lang'; +import {TemplateConfig} from 'core/src/annotations/template_config'; +import {EventEmitter} from 'core/src/annotations/events'; +import {List, MapWrapper} from 'facade/src/collection'; +import {DOM, Element} from 'facade/src/dom'; +import {int, proxy, IMPLEMENTS} from 'facade/src/lang'; import {Injector} from 'di/di'; -import {View} from 'core/compiler/view'; -import {ViewPort} from 'core/compiler/viewport'; -import {reflector} from 'reflection/reflection'; +import {View} from 'core/src/compiler/view'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {reflector} from 'reflection/src/reflection'; @proxy diff --git a/modules/core/test/compiler/viewport_spec.js b/modules/core/test/compiler/viewport_spec.js index 0c37dea903ca8e..5e09b9c0291a50 100644 --- a/modules/core/test/compiler/viewport_spec.js +++ b/modules/core/test/compiler/viewport_spec.js @@ -1,11 +1,11 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, el} from 'test_lib/test_lib'; -import {View, ProtoView} from 'core/compiler/view'; -import {ViewPort} from 'core/compiler/viewport'; -import {proxy, IMPLEMENTS} from 'facade/lang'; -import {DOM} from 'facade/dom'; -import {ListWrapper, MapWrapper} from 'facade/collection'; +import {View, ProtoView} from 'core/src/compiler/view'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {proxy, IMPLEMENTS} from 'facade/src/lang'; +import {DOM} from 'facade/src/dom'; +import {ListWrapper, MapWrapper} from 'facade/src/collection'; import {Injector} from 'di/di'; -import {ProtoElementInjector, ElementInjector} from 'core/compiler/element_injector'; +import {ProtoElementInjector, ElementInjector} from 'core/src/compiler/element_injector'; import {DynamicProtoChangeDetector, ChangeDetector, Lexer, Parser} from 'change_detection/change_detection'; function createView(nodes) { diff --git a/modules/core/test/zone/vm_turn_zone_spec.js b/modules/core/test/zone/vm_turn_zone_spec.js index 4238cafc7c7ed1..515547854e7406 100644 --- a/modules/core/test/zone/vm_turn_zone_spec.js +++ b/modules/core/test/zone/vm_turn_zone_spec.js @@ -1,8 +1,8 @@ import {describe, ddescribe, it, iit, xit, xdescribe, expect, beforeEach, async, tick} from 'test_lib/test_lib'; -import {Log, once} from 'test_lib/utils'; -import {PromiseWrapper} from 'facade/async'; -import {BaseException} from 'facade/lang'; -import {VmTurnZone} from 'core/zone/vm_turn_zone'; +import {Log, once} from 'test_lib/test_lib'; +import {PromiseWrapper} from 'facade/src/async'; +import {BaseException} from 'facade/src/lang'; +import {VmTurnZone} from 'core/src/zone/vm_turn_zone'; export function main() { describe("VmTurnZone", () => { diff --git a/modules/di/di.js b/modules/di/di.js new file mode 100644 index 00000000000000..3e3d0f0271622c --- /dev/null +++ b/modules/di/di.js @@ -0,0 +1,7 @@ +export {Inject, InjectPromise, InjectLazy, DependencyAnnotation} from './src/annotations'; +export {Injector} from './src/injector'; +export {Binding, Dependency, bind} from './src/binding'; +export {Key, KeyRegistry} from './src/key'; +export {KeyMetadataError, NoProviderError, ProviderError, AsyncBindingError, CyclicDependencyError, + InstantiationError, InvalidBindingError, NoAnnotationError} from './src/exceptions'; +export {OpaqueToken} from './src/opaque_token'; diff --git a/modules/di/src/annotations.js b/modules/di/src/annotations.js index 29d556ccd02c7b..b4884ab271db0d 100644 --- a/modules/di/src/annotations.js +++ b/modules/di/src/annotations.js @@ -1,4 +1,4 @@ -import {CONST} from "facade/lang"; +import {CONST} from "facade/src/lang"; /** * A parameter annotation that creates a synchronous eager dependency. diff --git a/modules/di/src/binding.js b/modules/di/src/binding.js index e90cf5ea39038f..5acb358a58bb53 100644 --- a/modules/di/src/binding.js +++ b/modules/di/src/binding.js @@ -1,6 +1,6 @@ -import {FIELD, Type, isBlank, isPresent} from 'facade/lang'; -import {List, MapWrapper, ListWrapper} from 'facade/collection'; -import {reflector} from 'reflection/reflection'; +import {FIELD, Type, isBlank, isPresent} from 'facade/src/lang'; +import {List, MapWrapper, ListWrapper} from 'facade/src/collection'; +import {reflector} from 'reflection/src/reflection'; import {Key} from './key'; import {Inject, InjectLazy, InjectPromise, DependencyAnnotation} from './annotations'; import {NoAnnotationError} from './exceptions'; diff --git a/modules/di/src/di.js b/modules/di/src/di.js deleted file mode 100644 index a4481bdeae9c54..00000000000000 --- a/modules/di/src/di.js +++ /dev/null @@ -1,7 +0,0 @@ -export {Inject, InjectPromise, InjectLazy, DependencyAnnotation} from './annotations'; -export {Injector} from './injector'; -export {Binding, Dependency, bind} from './binding'; -export {Key, KeyRegistry} from './key'; -export {KeyMetadataError, NoProviderError, ProviderError, AsyncBindingError, CyclicDependencyError, - InstantiationError, InvalidBindingError, NoAnnotationError} from './exceptions'; -export {OpaqueToken} from './opaque_token'; diff --git a/modules/di/src/exceptions.js b/modules/di/src/exceptions.js index 8573b3aa21122f..f81839a830cb08 100644 --- a/modules/di/src/exceptions.js +++ b/modules/di/src/exceptions.js @@ -1,5 +1,5 @@ -import {ListWrapper, List} from 'facade/collection'; -import {stringify} from 'facade/lang'; +import {ListWrapper, List} from 'facade/src/collection'; +import {stringify} from 'facade/src/lang'; import {Key} from './key'; function findFirstClosedCycle(keys:List) { diff --git a/modules/di/src/injector.js b/modules/di/src/injector.js index e7644658e8648a..1c183e0da3881a 100644 --- a/modules/di/src/injector.js +++ b/modules/di/src/injector.js @@ -1,9 +1,9 @@ -import {Map, List, MapWrapper, ListWrapper} from 'facade/collection'; +import {Map, List, MapWrapper, ListWrapper} from 'facade/src/collection'; import {Binding, BindingBuilder, bind} from './binding'; import {ProviderError, NoProviderError, InvalidBindingError, AsyncBindingError, CyclicDependencyError, InstantiationError} from './exceptions'; -import {FunctionWrapper, Type, isPresent, isBlank} from 'facade/lang'; -import {Promise, PromiseWrapper} from 'facade/async'; +import {FunctionWrapper, Type, isPresent, isBlank} from 'facade/src/lang'; +import {Promise, PromiseWrapper} from 'facade/src/async'; import {Key} from './key'; var _constructing = new Object(); diff --git a/modules/di/src/key.js b/modules/di/src/key.js index 7ce42d17ae772e..4b9c231d06f62e 100644 --- a/modules/di/src/key.js +++ b/modules/di/src/key.js @@ -1,6 +1,6 @@ import {KeyMetadataError} from './exceptions'; -import {MapWrapper, Map} from 'facade/collection'; -import {FIELD, int, isPresent} from 'facade/lang'; +import {MapWrapper, Map} from 'facade/src/collection'; +import {FIELD, int, isPresent} from 'facade/src/lang'; export class Key { token; diff --git a/modules/di/test/di/async_spec.js b/modules/di/test/di/async_spec.js index 8bdd4f1a931e0c..2c1f136248c512 100644 --- a/modules/di/test/di/async_spec.js +++ b/modules/di/test/di/async_spec.js @@ -1,6 +1,6 @@ import {ddescribe, describe, it, iit, xit, expect, beforeEach} from 'test_lib/test_lib'; import {Injector, Inject, InjectPromise, bind, Key} from 'di/di'; -import {Promise, PromiseWrapper} from 'facade/async'; +import {Promise, PromiseWrapper} from 'facade/src/async'; class UserList { } diff --git a/modules/directives/directives.js b/modules/directives/directives.js new file mode 100644 index 00000000000000..f77ab0325e2013 --- /dev/null +++ b/modules/directives/directives.js @@ -0,0 +1,4 @@ +export * from './src/ng_if'; +export * from './src/ng_non_bindable'; +export * from './src/ng_repeat'; +export * from './src/ng_switch'; diff --git a/modules/directives/src/directives.js b/modules/directives/src/directives.js deleted file mode 100644 index 8e2880822936e6..00000000000000 --- a/modules/directives/src/directives.js +++ /dev/null @@ -1,4 +0,0 @@ -export * from './ng_if'; -export * from './ng_non_bindable'; -export * from './ng_repeat'; -export * from './ng_switch'; diff --git a/modules/directives/src/ng_if.js b/modules/directives/src/ng_if.js index 590ba532bfc4fa..9b88c59141b60c 100644 --- a/modules/directives/src/ng_if.js +++ b/modules/directives/src/ng_if.js @@ -1,6 +1,6 @@ -import {Template} from 'core/annotations/annotations'; -import {ViewPort} from 'core/compiler/viewport'; -import {isBlank} from 'facade/lang'; +import {Template} from 'core/src/annotations/annotations'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {isBlank} from 'facade/src/lang'; @Template({ selector: '[ng-if]', diff --git a/modules/directives/src/ng_non_bindable.js b/modules/directives/src/ng_non_bindable.js index be0793575c67be..d5ae03343c168f 100644 --- a/modules/directives/src/ng_non_bindable.js +++ b/modules/directives/src/ng_non_bindable.js @@ -1,4 +1,4 @@ -import {Decorator} from 'core/annotations/annotations'; +import {Decorator} from 'core/src/annotations/annotations'; @Decorator({ selector: '[ng-non-bindable]', diff --git a/modules/directives/src/ng_repeat.js b/modules/directives/src/ng_repeat.js index 3bc599b0b3a703..7468d047b83a8b 100644 --- a/modules/directives/src/ng_repeat.js +++ b/modules/directives/src/ng_repeat.js @@ -1,9 +1,9 @@ -import {Template} from 'core/annotations/annotations'; -import {OnChange} from 'core/compiler/interfaces'; -import {ViewPort} from 'core/compiler/viewport'; -import {View} from 'core/compiler/view'; -import {isPresent, isBlank} from 'facade/lang'; -import {ListWrapper} from 'facade/collection'; +import {Template} from 'core/src/annotations/annotations'; +import {OnChange} from 'core/src/compiler/interfaces'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {View} from 'core/src/compiler/view'; +import {isPresent, isBlank} from 'facade/src/lang'; +import {ListWrapper} from 'facade/src/collection'; @Template({ selector: '[ng-repeat]', diff --git a/modules/directives/src/ng_switch.js b/modules/directives/src/ng_switch.js index 50a122f6f087bb..8fe28f6860f0fb 100644 --- a/modules/directives/src/ng_switch.js +++ b/modules/directives/src/ng_switch.js @@ -1,10 +1,10 @@ -import {Decorator, Template} from 'core/annotations/annotations'; -import {ViewPort} from 'core/compiler/viewport'; -import {NgElement} from 'core/dom/element'; -import {DOM} from 'facade/dom'; -import {isPresent, isBlank} from 'facade/lang'; -import {ListWrapper, List, MapWrapper, Map} from 'facade/collection'; -import {Parent} from 'core/annotations/visibility'; +import {Decorator, Template} from 'core/src/annotations/annotations'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {NgElement} from 'core/src/dom/element'; +import {DOM} from 'facade/src/dom'; +import {isPresent, isBlank} from 'facade/src/lang'; +import {ListWrapper, List, MapWrapper, Map} from 'facade/src/collection'; +import {Parent} from 'core/src/annotations/visibility'; /** * The `ngSwitch` directive is used to conditionally swap DOM structure on your template based on a diff --git a/modules/directives/test/ng_if_spec.js b/modules/directives/test/ng_if_spec.js index b24ba2a8c12695..5439b5eb3de10b 100644 --- a/modules/directives/test/ng_if_spec.js +++ b/modules/directives/test/ng_if_spec.js @@ -1,17 +1,17 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, IS_DARTIUM, el} from 'test_lib/test_lib'; -import {DOM} from 'facade/dom'; +import {DOM} from 'facade/src/dom'; import {Injector} from 'di/di'; import {Lexer, Parser, ChangeDetector, dynamicChangeDetection} from 'change_detection/change_detection'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; -import {Component} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; +import {Component} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; -import {NgIf} from 'directives/ng_if'; +import {NgIf} from 'directives/src/ng_if'; export function main() { describe('ng-if', () => { diff --git a/modules/directives/test/ng_non_bindable_spec.js b/modules/directives/test/ng_non_bindable_spec.js index bd796459cdef7a..102edb9caa4ac6 100644 --- a/modules/directives/test/ng_non_bindable_spec.js +++ b/modules/directives/test/ng_non_bindable_spec.js @@ -1,13 +1,13 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, el} from 'test_lib/test_lib'; -import {DOM} from 'facade/dom'; +import {DOM} from 'facade/src/dom'; import {Injector} from 'di/di'; import {Lexer, Parser, ChangeDetector, dynamicChangeDetection} from 'change_detection/change_detection'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {Decorator, Component} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; -import {NgElement} from 'core/dom/element'; -import {NgNonBindable} from 'directives/ng_non_bindable'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {Decorator, Component} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; +import {NgElement} from 'core/src/dom/element'; +import {NgNonBindable} from 'directives/src/ng_non_bindable'; export function main() { describe('ng-non-bindable', () => { diff --git a/modules/directives/test/ng_repeat_spec.js b/modules/directives/test/ng_repeat_spec.js index f8d1965e94dcba..3487b842bf1ceb 100644 --- a/modules/directives/test/ng_repeat_spec.js +++ b/modules/directives/test/ng_repeat_spec.js @@ -1,20 +1,20 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, el} from 'test_lib/test_lib'; -import {DOM} from 'facade/dom'; +import {DOM} from 'facade/src/dom'; import {Injector} from 'di/di'; import {Lexer, Parser, ChangeDetector, dynamicChangeDetection} from 'change_detection/change_detection'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {OnChange} from 'core/compiler/interfaces'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {OnChange} from 'core/src/compiler/interfaces'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; -import {Decorator, Component, Template} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; +import {Decorator, Component, Template} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; -import {ViewPort} from 'core/compiler/viewport'; -import {MapWrapper, ListWrapper} from 'facade/collection'; -import {NgRepeat} from 'directives/ng_repeat'; +import {ViewPort} from 'core/src/compiler/viewport'; +import {MapWrapper, ListWrapper} from 'facade/src/collection'; +import {NgRepeat} from 'directives/src/ng_repeat'; export function main() { describe('ng-repeat', () => { diff --git a/modules/directives/test/ng_switch_spec.js b/modules/directives/test/ng_switch_spec.js index 40875cf8d1b990..02cf2660b68ea3 100644 --- a/modules/directives/test/ng_switch_spec.js +++ b/modules/directives/test/ng_switch_spec.js @@ -1,12 +1,12 @@ import {describe, xit, it, expect, beforeEach, ddescribe, iit, el} from 'test_lib/test_lib'; -import {DOM} from 'facade/dom'; +import {DOM} from 'facade/src/dom'; import {Injector} from 'di/di'; import {Lexer, Parser, dynamicChangeDetection} from 'change_detection/change_detection'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {Component} from 'core/annotations/annotations'; -import {TemplateConfig} from 'core/annotations/template_config'; -import {NgSwitch, NgSwitchWhen, NgSwitchDefault} from 'directives/ng_switch'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {Component} from 'core/src/annotations/annotations'; +import {TemplateConfig} from 'core/src/annotations/template_config'; +import {NgSwitch, NgSwitchWhen, NgSwitchDefault} from 'directives/src/ng_switch'; export function main() { describe('ng-switch', () => { diff --git a/modules/e2e_test_lib/src/benchmark_util.js b/modules/e2e_test_lib/src/benchmark_util.js index 277e289a6304b9..030ab1d42ed9fb 100644 --- a/modules/e2e_test_lib/src/benchmark_util.js +++ b/modules/e2e_test_lib/src/benchmark_util.js @@ -1,5 +1,5 @@ -import {DOM, document, location} from 'facade/dom'; -import {NumberWrapper, BaseException, isBlank} from 'facade/lang'; +import {DOM, document, location} from 'facade/src/dom'; +import {NumberWrapper, BaseException, isBlank} from 'facade/src/lang'; export function getIntParameter(name:string) { return NumberWrapper.parseInt(getStringParameter(name), 10); diff --git a/modules/examples/e2e_test/hello_world/hello_world_spec.es6 b/modules/examples/e2e_test/hello_world/hello_world_spec.es6 index 3d06ef3971b0e4..e7355401e2e565 100644 --- a/modules/examples/e2e_test/hello_world/hello_world_spec.es6 +++ b/modules/examples/e2e_test/hello_world/hello_world_spec.es6 @@ -1,10 +1,10 @@ var benchpress = require('../../../../tools/benchpress/index.js'); -describe('hello world', function () { +fdescribe('hello world', function () { afterEach(benchpress.verifyNoBrowserErrors); describe('static reflection', function() { - var URL = 'examples/web/hello_world/index_static.html'; + var URL = 'examples/src/hello_world/index_static.html'; it('should greet', function() { browser.get(URL); @@ -21,7 +21,7 @@ describe('hello world', function () { }); describe('dynamic reflection', function() { - var URL = 'examples/web/hello_world/index.html'; + var URL = 'examples/src/hello_world/index.html'; it('should greet', function() { browser.get(URL); diff --git a/modules/examples/src/hello_world/index.js b/modules/examples/src/hello_world/index.js index 28c3e55ffc1493..b8049ca527b2b0 100644 --- a/modules/examples/src/hello_world/index.js +++ b/modules/examples/src/hello_world/index.js @@ -1,6 +1,6 @@ import * as app from './index_common'; -import {reflector} from 'reflection/reflection'; -import {ReflectionCapabilities} from 'reflection/reflection_capabilities'; +import {reflector} from 'reflection/src/reflection'; +import {ReflectionCapabilities} from 'reflection/src/reflection_capabilities'; export function main() { // Initializing the reflector is only required for the Dart version of the application. diff --git a/modules/examples/src/hello_world/index_static.js b/modules/examples/src/hello_world/index_static.js index 361ad09f5868c6..58ea578db91fd7 100644 --- a/modules/examples/src/hello_world/index_static.js +++ b/modules/examples/src/hello_world/index_static.js @@ -2,13 +2,13 @@ import * as app from './index_common'; import {Component, Decorator, TemplateConfig, NgElement} from 'angular/angular'; import {Lexer, Parser, ChangeDetection, ChangeDetector} from 'change_detection/change_detection'; -import {LifeCycle} from 'core/life_cycle/life_cycle'; +import {LifeCycle} from 'core/src/life_cycle/life_cycle'; -import {Compiler, CompilerCache} from 'core/compiler/compiler'; -import {DirectiveMetadataReader} from 'core/compiler/directive_metadata_reader'; -import {TemplateLoader} from 'core/compiler/template_loader'; +import {Compiler, CompilerCache} from 'core/src/compiler/compiler'; +import {DirectiveMetadataReader} from 'core/src/compiler/directive_metadata_reader'; +import {TemplateLoader} from 'core/src/compiler/template_loader'; -import {reflector} from 'reflection/reflection'; +import {reflector} from 'reflection/src/reflection'; function setup() { reflector.registerType(app.HelloCmp, { diff --git a/modules/facade/src/async.es6 b/modules/facade/src/async.es6 index b08c66864628b3..7b71b4fe26e56e 100644 --- a/modules/facade/src/async.es6 +++ b/modules/facade/src/async.es6 @@ -1,5 +1,5 @@ -import {int} from 'facade/lang'; -import {List} from 'facade/collection'; +import {int} from 'facade/src/lang'; +import {List} from 'facade/src/collection'; export var Promise = window.Promise; export class PromiseWrapper { diff --git a/modules/facade/src/collection.es6 b/modules/facade/src/collection.es6 index 0a8d5cd9e5ce8c..ef37fd5b6f5a87 100644 --- a/modules/facade/src/collection.es6 +++ b/modules/facade/src/collection.es6 @@ -1,4 +1,4 @@ -import {int, isJsObject} from 'facade/lang'; +import {int, isJsObject} from 'facade/src/lang'; export var List = window.Array; export var Map = window.Map; diff --git a/modules/facade/src/dom.es6 b/modules/facade/src/dom.es6 index 8f1148acdf6938..b5452612a049df 100644 --- a/modules/facade/src/dom.es6 +++ b/modules/facade/src/dom.es6 @@ -9,7 +9,7 @@ export var document = window.document; export var location = window.location; export var gc = window.gc ? () => window.gc() : () => null; -import {List, MapWrapper, ListWrapper} from 'facade/collection'; +import {List, MapWrapper, ListWrapper} from 'facade/src/collection'; export class DOM { static query(selector) { diff --git a/modules/reflection/src/reflection.dart b/modules/reflection/src/reflection.dart index c58ef03c5e3119..92d18f1e720b18 100644 --- a/modules/reflection/src/reflection.dart +++ b/modules/reflection/src/reflection.dart @@ -3,7 +3,7 @@ library reflection.reflection; import 'reflector.dart'; import 'types.dart'; export 'reflector.dart'; -import 'package:facade/lang.dart'; +import 'package:facade/src/lang.dart'; class NoReflectionCapabilities { Function factory(Type type){ diff --git a/modules/reflection/src/reflection.es6 b/modules/reflection/src/reflection.es6 index 3ed625946f6259..6b34296739ae6f 100644 --- a/modules/reflection/src/reflection.es6 +++ b/modules/reflection/src/reflection.es6 @@ -1,5 +1,5 @@ -import {Type, isPresent} from 'facade/lang'; -import {List, ListWrapper} from 'facade/collection'; +import {Type, isPresent} from 'facade/src/lang'; +import {List, ListWrapper} from 'facade/src/collection'; import {Reflector} from './reflector'; export {Reflector} from './reflector'; import {ReflectionCapabilities} from './reflection_capabilities'; diff --git a/modules/reflection/src/reflection_capabilities.es6 b/modules/reflection/src/reflection_capabilities.es6 index 9aa0bd0bfb6bfe..7d398d92e08d5b 100644 --- a/modules/reflection/src/reflection_capabilities.es6 +++ b/modules/reflection/src/reflection_capabilities.es6 @@ -1,5 +1,5 @@ -import {Type, isPresent} from 'facade/lang'; -import {List, ListWrapper} from 'facade/collection'; +import {Type, isPresent} from 'facade/src/lang'; +import {List, ListWrapper} from 'facade/src/collection'; import {GetterFn, SetterFn, MethodFn} from './types'; export class ReflectionCapabilities { diff --git a/modules/reflection/src/reflector.js b/modules/reflection/src/reflector.js index 47a4f36c54db78..74ee1aede3daf1 100644 --- a/modules/reflection/src/reflector.js +++ b/modules/reflection/src/reflector.js @@ -1,5 +1,5 @@ -import {Type, isPresent, stringify, BaseException} from 'facade/lang'; -import {List, ListWrapper, Map, MapWrapper, StringMapWrapper} from 'facade/collection'; +import {Type, isPresent, stringify, BaseException} from 'facade/src/lang'; +import {List, ListWrapper, Map, MapWrapper, StringMapWrapper} from 'facade/src/collection'; import {SetterFn, GetterFn, MethodFn} from './types'; export {SetterFn, GetterFn, MethodFn} from './types'; diff --git a/modules/reflection/test/reflector_spec.js b/modules/reflection/test/reflector_spec.js index 15cd96be3a65fc..f4060ef6e01390 100644 --- a/modules/reflection/test/reflector_spec.js +++ b/modules/reflection/test/reflector_spec.js @@ -1,7 +1,7 @@ import {describe, it, iit, ddescribe, expect, beforeEach} from 'test_lib/test_lib'; -import {Reflector} from 'reflection/reflection'; -import {ReflectionCapabilities} from 'reflection/reflection_capabilities'; -import {CONST} from 'facade/lang'; +import {Reflector} from 'reflection/src/reflection'; +import {ReflectionCapabilities} from 'reflection/src/reflection_capabilities'; +import {CONST} from 'facade/src/lang'; class Annotation { value; @@ -122,7 +122,7 @@ export function main() { expect(reflector.annotations(TestObj)).toEqual([1,2]); }); }); - + describe("getter", () => { it("returns a function reading a property", () => { var getA = reflector.getter('a'); diff --git a/modules/rtts_assert/rtts_assert.es6 b/modules/rtts_assert/rtts_assert.es6 new file mode 100644 index 00000000000000..117e09a60f27d0 --- /dev/null +++ b/modules/rtts_assert/rtts_assert.es6 @@ -0,0 +1 @@ +export * from './src/rtts_assert'; \ No newline at end of file diff --git a/modules/test_lib/src/test_lib.dart b/modules/test_lib/src/test_lib.dart index 5624ffc37ebeff..c9f353fecef086 100644 --- a/modules/test_lib/src/test_lib.dart +++ b/modules/test_lib/src/test_lib.dart @@ -5,9 +5,9 @@ export 'package:guinness/guinness_html.dart'; import 'package:unittest/unittest.dart' hide expect; import 'dart:mirrors'; import 'dart:async'; -import 'package:reflection/reflection.dart'; -import 'package:facade/dom.dart'; -import 'package:reflection/reflection_capabilities.dart'; +import 'package:reflection/src/reflection.dart'; +import 'package:facade/src/dom.dart'; +import 'package:reflection/src/reflection_capabilities.dart'; bool IS_DARTIUM = true; diff --git a/modules/test_lib/src/test_lib.es6 b/modules/test_lib/src/test_lib.es6 index eee4f7ab50e678..74081eeb05b740 100644 --- a/modules/test_lib/src/test_lib.es6 +++ b/modules/test_lib/src/test_lib.es6 @@ -1,4 +1,4 @@ -import {DOM} from 'facade/dom'; +import {DOM} from 'facade/src/dom'; export var describe = window.describe; export var xdescribe = window.xdescribe; diff --git a/modules/test_lib/src/utils.js b/modules/test_lib/src/utils.js index 547d072f3e7c91..9348e8a1e7fb9a 100644 --- a/modules/test_lib/src/utils.js +++ b/modules/test_lib/src/utils.js @@ -1,4 +1,4 @@ -import {List, ListWrapper} from 'facade/collection'; +import {List, ListWrapper} from 'facade/src/collection'; export class Log { _result:List; diff --git a/modules/test_lib/test/test_lib_spec.js b/modules/test_lib/test/test_lib_spec.js index ed0d46ef4ae83d..0aee62b0174cd5 100644 --- a/modules/test_lib/test/test_lib_spec.js +++ b/modules/test_lib/test/test_lib_spec.js @@ -1,7 +1,7 @@ import {describe, it, iit, ddescribe, expect, tick, async, SpyObject, beforeEach} from 'test_lib/test_lib'; -import {MapWrapper, ListWrapper} from 'facade/collection'; -import {PromiseWrapper} from 'facade/async'; -import {IMPLEMENTS, proxy} from 'facade/lang'; +import {MapWrapper, ListWrapper} from 'facade/src/collection'; +import {PromiseWrapper} from 'facade/src/async'; +import {IMPLEMENTS, proxy} from 'facade/src/lang'; class TestObj { prop; diff --git a/modules/test_lib/test_lib.js b/modules/test_lib/test_lib.js new file mode 100644 index 00000000000000..999fb8afa3a8e8 --- /dev/null +++ b/modules/test_lib/test_lib.js @@ -0,0 +1,2 @@ +export * from './src/test_lib'; +export * from './src/utils'; \ No newline at end of file diff --git a/test-main.js b/test-main.js index fad4c8574e0fb3..b3fd43dae3b697 100644 --- a/test-main.js +++ b/test-main.js @@ -13,33 +13,7 @@ System.baseURL = '/base/modules/'; // So that we can import packages like `core/foo`, instead of `core/src/foo`. System.paths = { - 'angular/*': './angular/src/*.js', - 'angular/test/*': './angular/test/*.js', - - 'core/*': './core/src/*.js', - 'core/test/*': './core/test/*.js', - - 'change_detection/*': './change_detection/src/*.js', - 'change_detection/test/*': './change_detection/test/*.js', - - 'facade/*': './facade/src/*.js', - 'facade/test/*': './facade/test/*.js', - - 'di/*': './di/src/*.js', - 'di/test/*': './di/test/*.js', - - 'directives/*': './directives/src/*.js', - 'directives/test/*': './directives/test/*.js', - - 'reflection/*': './reflection/src/*.js', - 'reflection/test/*': './reflection/test/*.js', - - 'rtts_assert/*': './rtts_assert/src/*.js', - 'rtts_assert/test/*': './rtts_assert/test/*.js', - - 'test_lib/*': './test_lib/src/*.js', - 'test_lib/test/*': './test_lib/test/*.js', - + '*': './*.js', 'transpiler/*': '../tools/transpiler/*.js' } diff --git a/tools/build/dartanalyzer.js b/tools/build/dartanalyzer.js index 89771e1d3becc4..84112afce94b60 100644 --- a/tools/build/dartanalyzer.js +++ b/tools/build/dartanalyzer.js @@ -4,7 +4,6 @@ var spawn = require('child_process').spawn; var path = require('path'); var glob = require('glob'); var fs = require('fs'); -var util = require('./util'); module.exports = function(gulp, plugins, config) { return function() { @@ -12,7 +11,7 @@ module.exports = function(gulp, plugins, config) { var tempFile = '_analyzer.dart'; // analyze in parallel! return Q.all(dartModuleFolders.map(function(dir) { - var srcFiles = [].slice.call(glob.sync(util.filterByFile(config.srcFolderMapping, dir + '/pubspec.yaml') + '/**/*.dart', { + var srcFiles = [].slice.call(glob.sync(dir + '{/lib,/web}/**/*.dart', { cwd: dir })); var testFiles = [].slice.call(glob.sync('test/**/*_spec.dart', { diff --git a/tools/build/file2modulename.js b/tools/build/file2modulename.js index d670db62604a39..103dbcb652574f 100644 --- a/tools/build/file2modulename.js +++ b/tools/build/file2modulename.js @@ -3,10 +3,9 @@ function file2moduleName(filePath) { // module name should be relative to `modules` and `tools` folder .replace(/.*\/modules\//, '') .replace(/.*\/tools\//, '') - // module name should not include `src`, `test`, `lib` - .replace(/\/src\//, '/') + // module name should not include `lib`, `web` folders + // as they are wrapper packages for dart .replace(/\/web\//, '/') - .replace(/\/perf_tmp\//, '/') .replace(/\/lib\//, '/') // module name should not have a suffix .replace(/\.\w*$/, ''); diff --git a/tools/build/html.js b/tools/build/html.js index 140bc86cffd1ae..61c9f12419f1b6 100644 --- a/tools/build/html.js +++ b/tools/build/html.js @@ -6,7 +6,7 @@ var path = require('path'); module.exports = function(gulp, plugins, config) { return function() { return gulp.src(config.src) - .pipe(util.renameSrcFolder(plugins, config.srcFolderMapping)) + .pipe(util.insertSrcFolder(plugins, config.srcFolderInsertion, config.modulesFolder)) .pipe(through2.obj(function(file, enc, done) { var fileName = file.relative; var moduleName = file2moduleName(fileName); diff --git a/tools/build/pubbuild.js b/tools/build/pubbuild.js index 5f72dbaec67a66..1d4d8b487d8b52 100644 --- a/tools/build/pubbuild.js +++ b/tools/build/pubbuild.js @@ -4,6 +4,7 @@ var spawn = require('child_process').spawn; var through2 = require('through2'); var path = require('path'); var glob = require('glob'); +var fs = require('fs'); module.exports = function(gulp, plugins, config) { return function() { @@ -21,6 +22,8 @@ module.exports = function(gulp, plugins, config) { cwd: folder })).then(function() { return replaceDartWithJsScripts(gulp, destFolder); + }).then(function() { + return removeWebFolder(gulp, destFolder); }).then(nextFolder); } }; @@ -37,4 +40,11 @@ function replaceDartWithJsScripts(gulp, folder) { done(); })) .pipe(gulp.dest(folder))); -} \ No newline at end of file +} + +function removeWebFolder(gulp, folder) { + fs.renameSync(path.join(folder, 'web', 'src'), path.join(folder, 'src')); + fs.renameSync(path.join(folder, 'web', 'packages'), path.join(folder, 'packages')); + fs.rmdirSync(path.join(folder, 'web')); + return Q.resolve(); +} diff --git a/tools/build/snippets/runtime_paths.js b/tools/build/snippets/runtime_paths.js index 5a58ef936e0a16..52f2464225ab8e 100644 --- a/tools/build/snippets/runtime_paths.js +++ b/tools/build/snippets/runtime_paths.js @@ -1,17 +1,4 @@ System.paths = { - 'angular/*': '/angular/lib/*.js', - 'core/*': '/core/lib/*.js', - 'change_detection/*': '/change_detection/lib/*.js', - 'facade/*': '/facade/lib/*.js', - 'di/*': '/di/lib/*.js', - 'directives/*': '/directives/lib/*.js', - 'rtts_assert/*': '/rtts_assert/lib/*.js', - 'test_lib/*': '/test_lib/lib/*.js', - 'reflection/*': '/reflection/lib/*.js', - 'benchpress/*': '/benchpress/lib/*.js', - 'examples/*': '/examples/web/*.js', - 'e2e_test_lib/*': '/e2e_test_lib/lib/*.js', - 'benchmarks/*': '/benchmarks/web/*.js', - 'benchmarks_external/*': '/benchmarks_external/web/*.js', + '*': '/*.js' }; register(System); diff --git a/tools/build/transpile.js b/tools/build/transpile.js index df2c4bd3c11eb6..78f2f9681763d3 100644 --- a/tools/build/transpile.js +++ b/tools/build/transpile.js @@ -7,7 +7,7 @@ module.exports = function(gulp, plugins, config) { return function() { var transpile = gulp.src(config.src) .pipe(plugins.rename({extname: '.'+config.outputExt})) - .pipe(util.renameSrcFolder(plugins, config.srcFolderMapping)) + .pipe(util.insertSrcFolder(plugins, config.srcFolderInsertion, config.modulesFolder)) .pipe(gulpTraceur( config.options, file2moduleName) @@ -16,7 +16,7 @@ module.exports = function(gulp, plugins, config) { var copy = gulp.src(config.copy) .pipe(plugins.rename({extname: '.'+config.outputExt})) - .pipe(util.renameSrcFolder(plugins, config.srcFolderMapping)) + .pipe(util.insertSrcFolder(plugins, config.srcFolderInsertion, config.modulesFolder)) .pipe(gulp.dest(config.dest)); return mergeStreams(transpile, copy); diff --git a/tools/build/util.js b/tools/build/util.js index f715e26412a46d..c5d840c1725c55 100644 --- a/tools/build/util.js +++ b/tools/build/util.js @@ -1,22 +1,14 @@ var Q = require('q'); +var path = require('path'); var minimatch = require('minimatch'); module.exports = { processToPromise: processToPromise, streamToPromise: streamToPromise, - renameSrcFolder: renameSrcFolder, + insertSrcFolder: insertSrcFolder, filterByFile: filterByFile }; -function filterByFile(valuesWithPatterns, fileName) { - var match = null; - for (var pattern in valuesWithPatterns) { - if (pattern !== 'default' && minimatch(fileName, pattern)) { - match = valuesWithPatterns[pattern]; - } - } - return match || valuesWithPatterns['default']; -} function processToPromise(process) { var defer = Q.defer(); @@ -37,9 +29,33 @@ function streamToPromise(stream) { return defer.promise; } -function renameSrcFolder(plugins, srcFolderMapping) { +function filterByFile(pathMapping, folder) { + var folderParts = folder.split(path.sep); + var match; + var lastPattern; + for (var pattern in pathMapping) { + if (minimatch(folder, pattern)) { + if (!lastPattern || lastPattern.length < pattern.length) { + match = pathMapping[pattern]; + lastPattern = pattern; + } + } + } + if (match !== undefined) { + return match; + } else { + throw new Error('No entry for folder '+folder+' found in '+JSON.stringify(pathMapping)); + } +} + +function insertSrcFolder(plugins, srcFolderInsertion) { return plugins.rename(function(file) { - var srcOutputFolder = filterByFile(srcFolderMapping, file.dirname); - file.dirname = file.dirname.replace(/\bsrc\b/, srcOutputFolder); + var folder = file.dirname; + var srcDir = filterByFile(srcFolderInsertion, folder); + if (srcDir) { + var folderParts = file.dirname.split(path.sep); + folder = [folderParts[0], srcDir].concat(folderParts.slice(1)).join(path.sep); + } + file.dirname = folder; }); } diff --git a/tools/transpiler/spec/annotations_spec.js b/tools/transpiler/spec/annotations_spec.js index a69fa9c3ca2634..255ab8c86c0964 100644 --- a/tools/transpiler/spec/annotations_spec.js +++ b/tools/transpiler/spec/annotations_spec.js @@ -1,6 +1,6 @@ import {describe, it, expect, iit} from 'test_lib/test_lib'; import {readFirstAnnotation} from './fixtures/annotations'; -import {CONST} from 'facade/lang'; +import {CONST} from 'facade/src/lang'; class Inject {} class Bar {} diff --git a/tools/transpiler/spec/for_of_spec.js b/tools/transpiler/spec/for_of_spec.js index cd2eb5eb61ec4b..06c0a343334961 100644 --- a/tools/transpiler/spec/for_of_spec.js +++ b/tools/transpiler/spec/for_of_spec.js @@ -1,5 +1,5 @@ import {describe, it, expect} from 'test_lib/test_lib'; -import {ListWrapper, MapWrapper} from 'facade/collection'; +import {ListWrapper, MapWrapper} from 'facade/src/collection'; import {IterableList} from './fixtures/facade'; export function main() { diff --git a/tools/transpiler/spec/imports_spec.js b/tools/transpiler/spec/imports_spec.js index dff69bbda3bb6b..a3bffcbacc8931 100644 --- a/tools/transpiler/spec/imports_spec.js +++ b/tools/transpiler/spec/imports_spec.js @@ -7,7 +7,7 @@ import * as fooModule from './foo'; import * as exportModule from './export'; -import {Type} from 'facade/lang'; +import {Type} from 'facade/src/lang'; import {Baz} from './reexport';