286 Commits

Author SHA1 Message Date
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
Kara Erickson
6cc8f2298e docs(core): add docs to instructions, minor renames ()
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
1a9064ba2b docs(core): add more comments to di and fix formatting ()
PR Close 
2017-12-21 21:40:58 -08:00
Kara Erickson
5bc869cb24 docs(core): document di and minor renames ()
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
Kara Erickson
f3d38ce053 docs(core): add comments to node_manipulation functions ()
PR Close 
2017-12-21 21:40:58 -08:00
Kara Erickson
05953b3b83 docs(core): add comments to assert functions ()
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
George Kalpakas
3846f19f22 docs(core): move core examples into examples/core/ directory
This allows examples to be found during aio's `yarn serve-and-sync`, which only
looks for examples in `packages/examples/<packageName>/**/*`, where
`packageName` is the name of the package that the modified file belonged to;
e.g. `core`, `common`, etc.).
2017-12-18 12:10:29 -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
Chuck Jazdzewski
e7d9cb3e4c feat(compiler): narrow types of expressions used in *ngIf ()
Structural directives can now specify a type guard that describes
what types can be inferred for an input expression inside the
directive's template.

NgIf was modified to declare an input guard on ngIf.

After this change, `fullTemplateTypeCheck` will infer that
usage of `ngIf` expression inside it's template is truthy.

For example, if a component has a property `person?: Person`
and a template of `<div *ngIf="person"> {{person.name}} </div>`
the compiler will no longer report that `person` might be null or
undefined.

The template compiler will generate code similar to,

```
  if (NgIf.ngIfTypeGuard(instance.person)) {
    instance.person.name
  }
```

to validate the template's use of the interpolation expression.
Calling the type guard in this fashion allows TypeScript to infer
that `person` is non-null.

Fixes: ?

PR Close 
2017-12-08 10:24:26 -08:00
Yuan Gao
e544742156 refactor(core): Removed readonly getters and changed to readonly ()
variables

PR Close 
2017-12-08 10:24:19 -08:00
Matias Niemelä
46aa0a1cf6 fix(animations): properly recover and cleanup DOM when CD failures occur ()
Closes 

PR Close 
2017-12-07 17:16:27 -08:00
Matias Niemelä
590d93b30d feat(animations): re-introduce support for transition matching functions ()
Closes 

PR Close 
2017-12-07 17:16:09 -08:00
Alex Eagle
ef534c0cc1 build: upgrade bazel rules to latest ()
Add enough BUILD files to make it possible to
`bazel build packages/core/test`

Also re-format BUILD.bazel files with Buildifier.
Add a CI lint check that they stay formatted.

PR Close 
2017-12-07 11:27:50 -08:00
Matias Niemelä
b78ada198a fix(animations): ensure DOM is cleaned up after multiple @trigger leave animations finish ()
Closes 

PR Close 
2017-12-06 07:02:42 -08:00
Olivier Combe
be994496cd docs(core): add docs for i18n tokens ()
PR Close 
2017-12-05 21:56:43 -08:00
Matias Niemelä
c2b3792a3b fix(animations): ensure multi-level leave animations work ()
PR Close 
2017-11-28 18:24:41 -06:00
Matias Niemelä
b2a586cee1 fix(animations): ensure multi-level enter animations work ()
PR Close 
2017-11-28 18:24:40 -06:00
Miško Hevery
add5953aa1 Revert "fix(animations): ensure multi-level enter animations work ()"
This reverts commit dd6237ecd97123e8122dd30d6ae1d546fed599b8.
2017-11-28 15:08:44 -06:00
Miško Hevery
6b4c24020d Revert "fix(animations): ensure multi-level leave animations work ()"
This reverts commit 1366762d12e0faa857deb793255099bfe0e0f717.
2017-11-28 15:08:31 -06:00
Matias Niemelä
1366762d12 fix(animations): ensure multi-level leave animations work ()
PR Close 
2017-11-27 16:59:47 -06:00
Matias Niemelä
dd6237ecd9 fix(animations): ensure multi-level enter animations work ()
PR Close 
2017-11-27 16:59:46 -06:00
Juri Strumpflohner
6293ca23c3 docs(core): fix broken NgZone code example ()
The current code example was broken as there were a couple of syntax errors. This commit fixes the demo.

PR Close 
2017-11-27 12:14:47 -06:00
Matias Niemelä
ffb6dbeefe fix(animations): always fire start and done callbacks in order for noop animations ()
PR Close 
2017-11-22 12:36:28 -06:00
Matias Niemelä
0e012c9669 fix(animations): always fire inner trigger callbacks even if blocked by parent animations ()
Closes 

PR Close 
2017-11-22 10:38:02 -06:00
Chuck Jazdzewski
dcfffbf828 build: fix build failures () 2017-11-15 22:33:30 -08:00
Alex Eagle
5ec1717c58 fix: Update test code to type-check under TS 2.5 ()
PR Close 
2017-11-15 18:12:16 -06:00
Miško Hevery
f8658cdc38 Revert "fix(animations): always fire inner trigger callbacks even if blocked by parent animations ()"
This reverts commit d47b2a6f706c42c049bf0faf1112c97ecf681c0a.
2017-11-15 17:04:22 -06:00
Jason Aden
043e408805 style(core): fix comment format for linter 2017-11-15 11:53:11 -08:00
George Kalpakas
c004d483ab style(core): fix max line length to pass linting ()
Accidentally introduced in , where other linting errors (unrelated to the
PR) prevented proper linting.

PR Close 
2017-11-15 11:44:52 -08:00
Matias Niemelä
d47b2a6f70 fix(animations): always fire inner trigger callbacks even if blocked by parent animations ()
Closes 

PR Close 
2017-11-14 15:59:47 -08:00