468 Commits

Author SHA1 Message Date
Kara Erickson
1fe55e252c feat(ivy): add afterContentInit and afterContentChecked to render3 ()
PR Close 
2018-01-24 22:14:32 -08:00
Kara Erickson
53ed4b4648 test(ivy): add missing lifecycle tests for projected components ()
PR Close 
2018-01-24 22:14:32 -08:00
Miško Hevery
1e9cd95f5c test(ivy): content projection canonical example ()
PR Close 
2018-01-23 16:42:07 -08:00
Chuck Jazdzewski
c65634215b feat(ivy): update specification to include template variables ()
PR Close 
2018-01-23 13:32:57 -08:00
Alex Rickabaugh
0ad02de47e feat(ivy): support for the ngForOf directive, with tests ()
Implement NgOnChangesFeature, ViewContainerRef, TemplateRef,
and the renderEmbeddedTemplate instruction, and wire together the
pieces required for the ngForOf directive to work.

PR Close 
2018-01-23 12:54:39 -08:00
Alex Rickabaugh
6472661ae8 refactor(ivy): avoid circular dep with query/di/instructions ()
To prepare for pending ngForOf work, the dep from instructions -> query
should be broken. This will enable a dep from di -> instructions while
avoiding a di -> instructions -> query -> di cycle.

Analyzing this cycle also uncovered another problem: the implementation
of query() breaks tree-shaking through a hard dependency on DI concepts
of TemplateRef, ElementRef, ViewContainerRef. This is fundamentally due
to how query() can query for those values without any configuration.

Instead, this fix introduces the concept by employing the strategy
pattern, and redefining QueryReadType to pass a function which will
return one of the above values. This strategy is then used for 'read'
instead of an enum in cases where special values should be read from
the DI system.

PR Close 
2018-01-23 12:54:39 -08:00
Kara Erickson
e18f1de003 refactor(ivy): remove unnecessary D instruction ()
PR Close 
2018-01-19 15:23:17 -08:00
Chuck Jazdzewski
21e37e47c6 fix(ivy): update the compiler specification ()
Also make a minor fix for directive definitions

PR Close 
2018-01-19 13:23:54 -08:00
Alex Eagle
a1492a73ce build: Remove angular_src nested workspace ()
PR Close 
2018-01-19 10:17:37 -08:00
Chuck Jazdzewski
47b7898697 Revert "fix(core): fix chained http call ()"
This reverts commit 7e3f9a482a475a1366d770e93818575183a7568d.
2018-01-17 15:28:21 -08:00
Xander Garbett
d3bf54bdeb feat(core): add binding name to content changed error ()
Adding the binding name to the error message recieved by the user gives
extra context on what exactly changed. The tests are also updated to
reflect the new error message.

PR Close 
2018-01-17 07:16:40 -08:00
Benjamin Ingberg
7e3f9a482a fix(core): fix chained http call ()
Fixes an issue where chained http calls would prematurely call
testability whenStable callbacks after the first http call.

Fixes 

PR Close 
2018-01-17 07:13:57 -08:00
Kara Erickson
efe545a878 refactor(ivy): add TView and TContainer ()
PR Close 
2018-01-16 10:51:55 -08:00
Miško Hevery
5eaaac35a8 refactor(ivy): remove type from DirectiveDef ()
This change makes the code cleaner for the user. It does mean
a little bit more work for us since we have to patch the `type` back
into the `DirectiveDef`. However since the patching happens only once
on startup it should not be significant.

PR Close 
2018-01-11 07:02:18 -08:00
Miško Hevery
16232f000f refactor(ivy): merged containerStart/containerEnd ()
This separation is no longer needed since directives are now passed into the `container` as an array rather than as child functions of the `containerStart`

PR Close 
2018-01-11 07:02:18 -08:00
Misko Hevery
9f43f5f09e test(ivy): add canonical template translation examples ()
This change creates a spec file which contains canonical examples
of how the template compiler will translate templates into expected
output.

PR Close 
2018-01-11 07:02:18 -08:00
Misko Hevery
a6d41c47a9 refactor(ivy): move directive into elementStart ()
We used to have a separate `directive` instruction for instantiating
directives. However, such an instruction requires that directives
are created in the correct order, which would require that template
compiler would have knowledge of all dependent directives. This
would break template compilation locality principle.

This change only changes the APIs to expected form but does
not change the semantics. The semantics will need to be corrected
in subsequent commits. The semantic change needed is to
resolve the directive instantiation error at runtime based on
injection dependencies.

PR Close 
2018-01-11 07:02:17 -08:00
Kara Erickson
6be9c0466c refactor(core): split up interface files in render3 ()
PR Close 
2018-01-10 16:13:44 -08:00
Alex Eagle
c4f02e21dd build: move repeated tsconfig attributes to a macro ()
This helps ensure we use the same tsconfig.json file for all compilations.
Next steps are to make it the same tsconfig.json file used by the editor

PR Close 
2018-01-10 12:30:19 -08:00
Kara Erickson
fc3e7e0381 refactor(core): create consistent naming scheme across classes ()
PR Close 
2018-01-10 11:15:48 -08:00
Kara Erickson
3db91ffd96 feat(core): add ngAfterViewInit and ngAfterViewChecked support to render3 ()
PR Close 
2018-01-09 14:18:17 -08:00
Marc Laval
a2f3f4550d test(core): properly stringify HTML elements in render3 tests ()
PR Close 
2018-01-05 14:25:40 -08:00
Marc Laval
d2cfc6a719 build: activate render3 tests in CI ()
PR Close 
2018-01-05 14:25:40 -08:00
Miško Hevery
9f538a6cac build: add karma tests for render3 ()
PR Close 
2017-12-27 16:46:56 -06:00
Pawel Kozlowski
3750ea9dff feat(core): final adjustements to ngIvy read option for queries ()
PR Close 
2017-12-27 16:46:56 -06:00
Pawel Kozlowski
afd89ed8d9 fix(core): support read option when querying for types ()
PR Close 
2017-12-27 16:46:56 -06:00
Pawel Kozlowski
a62371c0eb feat(core): more read options for ngIvy queries ()
PR Close 
2017-12-27 16:46:56 -06:00
Kara Erickson
c516bc3b35 feat(core): add ngOnInit and ngDoCheck support in render3 ()
PR Close 
2017-12-27 16:46:56 -06:00
Miško Hevery
ae97920fe2 build: move _testing_init into tools; limit web_test concurrency ()
PR Close 
2017-12-22 13:10:51 -08:00
Misko Hevery
47bcb5bc35 build(core): add bazel test targets for core ()
- Add tests target for `test`, `test_node_only` and `test_web` in `core` package.
- Created a `_testing_init` pseudo package where bootstrap code for tests is kept.
- Moved `source_map_util` from `test` to `testing` so to prevent circular dependency.
- Removed `visibility:public` for testing `BUILD` packages.

PR Close 
2017-12-22 13:10:51 -08:00
Miško Hevery
f3fc74ab67 build(core): remove main() from specs ()
`main()` function used to be needed to support dart, since dart
Does not allow top level statements. Since we no longer use dart
The need for `main()` has been removed.

In preparation for `Basel` and standardized way of running tests
we are removing `main()`

PR Close 
2017-12-22 13:10:51 -08:00
Matias Niemelä
86a36eaadd fix(animations): avoid infinite loop with multiple blocked sub triggers ()
This patch fixes animations so that if multiple sub @triggers are used
and are blocked by a parent animation then the engine will not lead
itself into an infinite loop.

PR Close 
2017-12-22 09:23:28 -08:00
Miško Hevery
5a7bf36723 build: fix circular dep between interface and l_node by merging ()
PR Close 
2017-12-21 21:40:58 -08:00
Miško Hevery
66528a21f6 build: fix benchmarks for render3 ()
PR Close 
2017-12-21 21:40:58 -08:00
Miško Hevery
a77757277b build: yarn buildifier ()
PR Close 
2017-12-21 21:40:58 -08:00
Pawel Kozlowski
4f05d022c1 feat(core): support 'read' option for ngIvy queries ()
PR Close 
2017-12-21 21:40:58 -08:00
Kara Erickson
5df343169e docs(core): add missing docs to component and fix formatting ()
PR Close 
2017-12-21 21:40:58 -08:00
Marc Laval
764fea1344 test(core): animation renderer factory in render3 ()
PR Close 
2017-12-21 21:40:58 -08:00
Pawel Kozlowski
bbdea96a66 refactor: remove import circular dependencies ()
This PR fixes a circular dependency among those files in Renderer3:
`query` -> `di` -> `instructions` -> `query` -> ...

Looking at the above dependencies the `di` -> `instructions` import is
a problematic one. Previously `di` had an import from `instructions`
since we can known about "current node" only in `instructions`
(and we need "current node" to create node injector instances).

This commit refactors the code in the way that functions in the
`di` file don't depend on any info stored module-global variables
in `instructions`.

PR Close 
2017-12-21 21:40:58 -08:00
Marc Laval
d1de587ce0 feat(core): add renderer factory in render3 ()
PR Close 
2017-12-21 21:40:58 -08:00
Pawel Kozlowski
147aec43bd feat: support queries for elements with local names ()
PR Close 
2017-12-21 21:40:58 -08:00
Miško Hevery
1f5049f30c style: fix formatting errors ()
PR Close 
2017-12-21 21:40:58 -08:00
Kara Erickson
19eeba2281 refactor(core): rename instructions for consistency ()
PR Close 
2017-12-21 21:40:58 -08:00
Miško Hevery
83b27bac17 style: fix formatting errors ()
PR Close 
2017-12-21 21:40:58 -08:00
Kara Erickson
b462f49ce7 refactor(core): renamed and split out interfaces ()
PR Close 
2017-12-21 21:40:58 -08:00
Kara Erickson
8fdb1e09c1 refactor(core): store directive defs in static data ()
PR Close 
2017-12-21 21:40:58 -08:00
Miško Hevery
93b00cceb6 refactor(core): store locals in main array in rederer3 ()
PR Close 
2017-12-21 21:40:58 -08:00
Miško Hevery
0fa818b318 feat(core): Moving Renderer3 into @angular/core ()
PR Close 
2017-12-21 21:40:58 -08:00
Olivier Combe
b7738e1fe5 feat(core): add source to StaticInjectorError message ()
Closes 
PR Close 
2017-12-12 11:56:06 -08:00
Matias Niemelä
13e663c232 fix(animations): ensure multi-level route leave animations are queryable ()
Closes 

PR Close 
2017-12-08 13:44:01 -08:00