Compare commits

...

35 Commits

Author SHA1 Message Date
Alex Rickabaugh 0115e2b664 release: cut the v13.1.1 release (#44495)
PR Close #44495
2021-12-15 14:32:40 -05:00
Kristiyan Kostadinov c2ed1ae945 fix(docs-infra): update examples to Angular 13.1 (#44487)
Updates AIO and the live examples to 13.1.0 in order to resolve a build error when opened on Stackblitz. They were using TS 4.5 with Angular ~13.0.0 which doesn't support 4.5.

Fixes #44480.

PR Close #44487
2021-12-15 13:22:14 -05:00
Dylan Hunn bce108ab49 fix(forms): _reduceValue arrow function now has correct types. (#44483)
I previously strengthened some weak types in #44370. One of these fixes exposed an incorrect call into `_reduceChildren` from `_reduceValue`. This was caught in google3 by a caller who was extending `FormGroup` and overriding these methods.

Special thanks to Bart G for catching this issue and suggesting a fix.

PR Close #44483
2021-12-15 12:27:06 -05:00
Dylan Hunn 240edcbc4e test(docs-infra): Correct an invalid assumption in aio tests. (#44479)
The aio application expects `FormControl` to have no properties for the purposes of its own internal tests, but this is no longer true after #44434.

PR Close #44479
2021-12-14 16:14:48 -05:00
Kristiyan Kostadinov 11187ef433 refactor(compiler): clean up workarounds for TypeScript 4.5 (#44477)
Cleans up some of the temporary workarounds that were necessary in order to land support for TypeScript 4.5 since they're no longer necessary.

PR Close #44477
2021-12-14 16:14:02 -05:00
George Kalpakas 9165191a13 build(docs-infra): upgrade cli command docs sources to febee7484 (#44476)
Updating [angular#13.1.x](https://github.com/angular/angular/tree/13.1.x) from
[cli-builds#13.1.x](https://github.com/angular/cli-builds/tree/13.1.x).

##
Relevant changes in
[commit range](https://github.com/angular/cli-builds/compare/e7881e40b...febee7484):

**Modified**
- help/new.json

PR Close #44476
2021-12-14 16:13:30 -05:00
Spej 17ac7c6624 docs: Fixed typo 'test' => 'text' (#44464)
PR Close #44464
2021-12-14 16:12:58 -05:00
dario-piotrowicz c195bd0b24 refactor(animations): remove the unused enter and leave selectors (#44460)
remove the no longer used ENTER_SELECTOR and LEAVE_SELECTOR constants

note: their uses have been removed in PR #19455

PR Close #44460
2021-12-14 16:12:36 -05:00
dario-piotrowicz 4a1cdbafc6 refactor(animations): improve _finalKeyframe non-null assertion (#44458)
instead of declaring the WebAnimationsPlayer's _finalKeyframe
field with a non-null assertion, declare it as optional field
and use a non-null assertion only when it is being used in the
beforeDestroy function

relates to #24571

PR Close #44458
2021-12-14 16:12:12 -05:00
Dylan Hunn f6f7a375a8 test(forms): Add more tests for FormBuilder method argument shapes. (#44452)
It is possible to pass arguments to `FormBuilder` using four different formats: value-only, boxed value, control config, and value-array. Currently, these different methods are not well-tested, especially as they interact. This PR will add tests for the variety of different argument shapes.

This was originally inspired by typed forms: when `FormBuilder` becomes typed, all these argument shapes should just work, with correct inferred types.

PR Close #44452
2021-12-14 16:11:29 -05:00
Dylan Hunn 199f7a2ba9 refactor(forms): Make the minimum changes to the forms unit tests in order to support the typed forms PR (#43834). (#44451)
Currently, many of our unit tests are written to use heterogenous groups and arrays, and controls that accept heterogenous values. This PR will make the minimum possible alterations to prepare those usages, mainly by annotating them as untyped controls, etc.

This PR is *not* intended to test typed forms, merely to minimize the size of the upcoming PR. This will allow that PR to be focused on the actual features and tests, rather than boilerplate fixes.

PR Close #44451
2021-12-14 16:10:08 -05:00
Dylan Hunn 998c1e63fe fix(forms): I indroduced a minor error in a previous PR: pendingValue is a value not a boolean flag. (#44450)
The bug should have no effect since it's a typings-only, internal-only bug, but it's good to fix nonetheless.

PR Close #44450
2021-12-14 16:09:43 -05:00
JoostK 1a25e381e6 test(ngcc): don't use the workspace typescript version to generate integration test fixtures (#44448)
Now that ViewEngine libraries can no longer be created, the latest
TypeScript version that ngcc should be able to process is TypeScript 4.3,
i.e. the version of TypeScript that was supported in Angular 12.
However, ngcc's integration tests used the TypeScript version of the
workspace to create the JavaScript files from TypeScript sources on
demand. This introduces friction when upgrading the TypeScript version
within the workspace, as changes to TypeScript's emit format may affect
ngcc's ability to process it correctly.

The on demand creation of JavaScript files was convenient for authoring
tests, but it also helped to detect incompatibilities with newer
versions of TypeScript. Now that ngcc no longer has to process newer
versions of TypeScript, we want to pin the integration suite to use
JavaScript code as if it were compiled using TypeScript 4.3, i.e. a
version of TypeScript that is actually supported by ngcc.

This commit updates the integration test to inline all the generated
files directly in the tests, instead of compiling them on demand. This
was done by temporarily installing TypeScript 4.3 and using it to create
the `loadTestFiles` statement from the original TypeScript inputs.

An alternative could have been to install TypeScript 4.3 as an actual
dependency in the workspace and using that to continue compiling the
integration suite on demand, but this brings some overhead in package
installations (TypeScript is ~60MB) and the authoring aspect of ngcc
integration test is expected to diminish, now that ngcc's support is no
longer a moving target.

PR Close #44448
2021-12-14 16:08:28 -05:00
Yousaf Nawaz 48e692dabe docs(docs-infra): change variable names in route guards examples (#44444)
change variable name 'next' to 'route' in route guards examples on developer guides "Routing and Navigation Tutorial: Adding routing to Tour of Heroes" to make it consistent with api docs and subsequent examples.

Fixes #44291

PR Close #44444
2021-12-14 16:08:05 -05:00
faso-dev 5ef03852c8 docs: fix typo (#44427)
`name` instead of `id`
PR Close #44427
2021-12-14 16:07:23 -05:00
jaybell 716f473d29 docs: add jaybell to gde list (#44423)
PR Close #44423
2021-12-14 16:06:32 -05:00
Aristeidis Bampakos 524e5152d7 docs: update Aristeidis Bampakos bio (#44410)
PR Close #44410
2021-12-14 16:06:06 -05:00
dario-piotrowicz bb1d4ff315 fix(animations): don't consume instructions for animateChild (#44357)
TODO: Fill body commit if PR gets accepted

resolves #41483
resolves #30693

PR Close #44357
2021-12-14 16:05:35 -05:00
zuckjet d8b6adb7bc fix(animations): should not invoke disabled child animations (#37724)
Currently child animation will be triggered by `animateChild()` despite it has been disabled.
These changes add some logic to prevent that unexpected behavior.

PR Close #37724

PR Close #37724
2021-12-14 16:05:00 -05:00
Renovate Bot f4fcdffbac build: update all non-major dependencies (#44152)
PR Close #44152
2021-12-14 16:04:34 -05:00
Dylan Hunn a0316ab0c0 refactor(forms): Fix weak helper types in the Forms package, mostly Function types that can be strengthened to specific callbacks. This was originally proposed as part of Typed Forms, but it may be possible to submit at least some of these changes separately and unconditionally (i.e. without relying on TypedOrUntyped.) (#44370)
It is desirable to land this separately to reduce the scope of the Typed Forms PR, by focusing it only on the new type parameters (rather than incidental strictness fixes).

PR Close #44370
2021-12-10 17:13:25 -05:00
Renovate Bot 6c0ac5145b build: update dependency google-closure-compiler to v20211201 (#44392)
PR Close #44392
2021-12-10 16:39:42 -05:00
Renovate Bot a8e5a93e12 build: update angular (#44273)
PR Close #44273
2021-12-10 16:39:05 -05:00
George Kalpakas 266b62c20f build(docs-infra): upgrade cli command docs sources to e7881e40b (#44413)
Updating [angular#13.1.x](https://github.com/angular/angular/tree/13.1.x) from
[cli-builds#13.0.x](https://github.com/angular/cli-builds/tree/13.0.x).

##
Relevant changes in
[commit range](https://github.com/angular/cli-builds/compare/481eb4544...e7881e40b):

**Modified**
- help/new.json

PR Close #44413
2021-12-10 16:36:41 -05:00
dario-piotrowicz a0e68250ad docs(animations): improve animation transition api docs (#44396)
improve the transition api docs by removing unnecessary examplanations
and examples

also provide helpful information regarding entering and leaving
elements (as part of #44253)

PR Close #44396
2021-12-10 16:34:01 -05:00
Paul Gschwendtner d7a9b36d91 build: remove unused starlark file that is no longer used (#44430)
Cleans up an unused Starlark file used by the old integration test
setup.

PR Close #44430
2021-12-10 16:31:04 -05:00
Paul Gschwendtner 5bdf321a97 build: fix integration test size trackings not running after recent refactoring (#44430)
Fixes that the integration test size trackings stopped working due to
the recent refactorings (switch to the rule from `@angular/dev-infra-private`).

The size-tracking does not integrate very-well into Bazel and needs
a better solution in the future, allowing for RBE and Windows support,
but currently with the new rule/setup/structure the tracking does not
validate sizes because:

* The `dist/*.js` argument to the tracking script got expanded and
  messed up the indices. It should be passed as a literal. This now
  surfaced because the new rule runs commands in a shell.

* The name for the size goldens were not computed properly because they
  were based on `ctx.attr.name`, but given the new structure, the test
  targets are always named `test`.

PR Close #44430
2021-12-10 16:31:04 -05:00
Alex Rickabaugh b11d3c3759 release: cut the v13.1.0 release (#44418)
PR Close #44418
2021-12-09 12:02:43 -05:00
Alex Rickabaugh 0c35e67ee7 Revert "release: cut the v13.1.0 release (#44417)"
This reverts commit 0e2c357358.

One more try, this time with a manual workaround.
2021-12-09 11:56:46 -05:00
Alex Rickabaugh 0e2c357358 release: cut the v13.1.0 release (#44417)
PR Close #44417
2021-12-09 11:52:25 -05:00
Alex Rickabaugh 22d8e5668e Revert "release: cut the v13.1.0 release (#44416)"
This reverts commit 6fb733fb40.

Still seeing transient errors - trying one more time before moving to a
workaround.
2021-12-09 11:50:04 -05:00
Alex Rickabaugh 6fb733fb40 release: cut the v13.1.0 release (#44416)
PR Close #44416
2021-12-09 11:37:17 -05:00
Alex Rickabaugh 6992a68935 Revert "release: cut the v13.1.0 release (#44415)"
This reverts commit 7e39556013.

The release process failed with a transient error, so reverting this commit
and trying again.
2021-12-09 11:35:00 -05:00
Alex Rickabaugh 7e39556013 release: cut the v13.1.0 release (#44415)
PR Close #44415
2021-12-09 11:31:04 -05:00
Alex Rickabaugh 08694e34dd release: cut the v13.1.0-rc.0 release 2021-12-08 14:24:20 -05:00
66 changed files with 4666 additions and 3951 deletions
+1 -1
View File
@@ -9,6 +9,6 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: angular/dev-infra/github-actions/commit-message-based-labels@c2fb49a44ad9fa77f508010f950524ee97f5e8d5
- uses: angular/dev-infra/github-actions/commit-message-based-labels@486b6e2b6388e2bebf19e6daf0b4b997df62693c
with:
angular-robot-key: ${{ secrets.ANGULAR_ROBOT_PRIVATE_KEY }}
+1 -1
View File
@@ -10,6 +10,6 @@ jobs:
if: github.repository == 'angular/angular'
runs-on: ubuntu-latest
steps:
- uses: angular/dev-infra/github-actions/feature-request@c2fb49a44ad9fa77f508010f950524ee97f5e8d5
- uses: angular/dev-infra/github-actions/feature-request@486b6e2b6388e2bebf19e6daf0b4b997df62693c
with:
angular-robot-key: ${{ secrets.ANGULAR_ROBOT_PRIVATE_KEY }}
+1 -1
View File
@@ -10,6 +10,6 @@ jobs:
if: github.repository == 'angular/angular'
runs-on: ubuntu-latest
steps:
- uses: angular/dev-infra/github-actions/lock-closed@c2fb49a44ad9fa77f508010f950524ee97f5e8d5
- uses: angular/dev-infra/github-actions/lock-closed@486b6e2b6388e2bebf19e6daf0b4b997df62693c
with:
lock-bot-key: ${{ secrets.LOCK_BOT_PRIVATE_KEY }}
+25 -290
View File
@@ -1,5 +1,17 @@
<a name="13.1.0-next.3"></a>
# 13.1.0-next.3 (2021-12-01)
<a name="13.1.1"></a>
# 13.1.1 (2021-12-15)
### animations
| Commit | Type | Description |
| -- | -- | -- |
| [bb1d4ff315](https://github.com/angular/angular/commit/bb1d4ff31592836b5268f1b42fc05823aff212aa) | fix | don't consume instructions for animateChild ([#44357](https://github.com/angular/angular/pull/44357)) |
| [d8b6adb7bc](https://github.com/angular/angular/commit/d8b6adb7bcf1ed6edc01c61406d30c86b2385284) | fix | should not invoke disabled child animations ([#37724](https://github.com/angular/angular/pull/37724)) |
## Special Thanks
Aristeidis Bampakos, Dylan Hunn, George Kalpakas, JoostK, Kristiyan Kostadinov, Paul Gschwendtner, Spej, Yousaf Nawaz, dario-piotrowicz, faso-dev, jaybell and zuckjet
<!-- CHANGELOG SPLIT MARKER -->
<a name="13.1.0"></a>
# 13.1.0 (2021-12-09)
## Deprecations
###
- The `downgradeModule` function calls with NgModule factories are deprecated. Please use NgModule class based `downgradeModule` calls instead.
@@ -15,40 +27,35 @@ accepts `ErrorEvent` when simulating XHR errors. Instead instances of
| Commit | Type | Description |
| -- | -- | -- |
| [489cf42cd0](https://github.com/angular/angular/commit/489cf42cd07ac2b549ea958127590b30f1b3d28f) | fix | incorrect error type for XHR errors in `TestRequest` ([#36082](https://github.com/angular/angular/pull/36082)) |
### compiler-cli
| [13362972bb](https://github.com/angular/angular/commit/13362972bb5dae606889c06ff7718502057b6b9c) | perf | code size reduction of `ngFor` directive ([#44315](https://github.com/angular/angular/pull/44315)) |
### compiler
| Commit | Type | Description |
| -- | -- | -- |
| [6c1573bc08](https://github.com/angular/angular/commit/6c1573bc08099bee40a6214c68e82fe91848a08a) | fix | downlevel transform incorrectly extracting constructor parameters for nested classes ([#44281](https://github.com/angular/angular/pull/44281)) |
| [48ca7dce4f](https://github.com/angular/angular/commit/48ca7dce4fe1474820abc296824cda9e7824c159) | fix | interpret string concat calls ([#44167](https://github.com/angular/angular/pull/44167)) |
| [c85bcb0c63](https://github.com/angular/angular/commit/c85bcb0c636d65706541d44be62694720f12ad9e) | feat | reference ICU message IDs from their placeholders ([#43534](https://github.com/angular/angular/pull/43534)) |
### core
| Commit | Type | Description |
| -- | -- | -- |
| [5dff077d50](https://github.com/angular/angular/commit/5dff077d505da60ddead9f2ff2ddaaaea6feeb4a) | feat | add migration to remove entryComponents ([#44308](https://github.com/angular/angular/pull/44308)) |
| [e65a245a0b](https://github.com/angular/angular/commit/e65a245a0b67c67f08a29f8c3ac2e3e7e824a029) | feat | add migration to remove entryComponents ([#44322](https://github.com/angular/angular/pull/44322)) |
| [d56e3f43a1](https://github.com/angular/angular/commit/d56e3f43a1f3ca5004d2c5413167737cff7d936f) | feat | support TypeScript 4.5 ([#44164](https://github.com/angular/angular/pull/44164)) |
| [b06e3981bc](https://github.com/angular/angular/commit/b06e3981bc1fa2b80465275cb657f0537b2c7385) | fix | add missing info about a component in the "pipe could not be found" error message ([#44081](https://github.com/angular/angular/pull/44081)) |
| [43dfab447d](https://github.com/angular/angular/commit/43dfab447d48a4978e52d7c7d67d4527a79f4240) | fix | destroy hooks not set up for `useClass` provider using `forwardRef` ([#44281](https://github.com/angular/angular/pull/44281)) |
| [b930547ffd](https://github.com/angular/angular/commit/b930547ffd951228c26e3c6bad456f90cc449e07) | fix | support cyclic metadata in TestBed overrides ([#44215](https://github.com/angular/angular/pull/44215)) |
### forms
### http
| Commit | Type | Description |
| -- | -- | -- |
| [38c02e13a5](https://github.com/angular/angular/commit/38c02e13a51e6ae00df5a594936572d1b1cfd38c) | fix | make the `FormControlStatus` available as a public API ([#44183](https://github.com/angular/angular/pull/44183)) |
### language-service
| [d452b388bd](https://github.com/angular/angular/commit/d452b388bdc0d661f41ab382f5e7ac998b0f9915) | feat | add `has()` method to `HttpContext` class ([#43887](https://github.com/angular/angular/pull/43887)) |
### localize
| Commit | Type | Description |
| -- | -- | -- |
| [3aafa765ee](https://github.com/angular/angular/commit/3aafa765eef2dbbafd422050d21e7436b113a832) | fix | Correctly parse inputs and selectors with dollar signs ([#44268](https://github.com/angular/angular/pull/44268)) |
| [d3cf222a81](https://github.com/angular/angular/commit/d3cf222a8193bc7ccd9e7ce886846d1f79131627) | feat | support "associated message ids" for placeholders ([#43534](https://github.com/angular/angular/pull/43534)) |
### ngcc
| Commit | Type | Description |
| -- | -- | -- |
| [de0975c6d9](https://github.com/angular/angular/commit/de0975c6d99bbe9332382a8f6f2b920f9e4b9d49) | fix | correctly report error when collecting dependencies of UMD module ([#44245](https://github.com/angular/angular/pull/44245)) |
| [24b635395f](https://github.com/angular/angular/commit/24b635395f163e727effbf66da168dfbb29fc4a0) | fix | ensure that ngcc does not write a lock-file into node_modules package directories ([#44228](https://github.com/angular/angular/pull/44228)) |
| [3c8a5d1c70](https://github.com/angular/angular/commit/3c8a5d1c706fe0ebff621f76eb9e98e0f5ec0f77) | fix | support the UMD wrapper function format emitted by Webpack ([#44245](https://github.com/angular/angular/pull/44245)) |
### router
| [41265919aa](https://github.com/angular/angular/commit/41265919aa90415911169057ef016e2f9b78aafd) | fix | correctly resolve UMD dependencies ([#44381](https://github.com/angular/angular/pull/44381)) |
### upgrade
| Commit | Type | Description |
| -- | -- | -- |
| [f44cb57c12](https://github.com/angular/angular/commit/f44cb57c12c29e76167272c675c0ce23838ce723) | fix | prevent componentless routes from being detached ([#44240](https://github.com/angular/angular/pull/44240)) |
| [34f990986c](https://github.com/angular/angular/commit/34f990986cade3ce6b355354d1e2f6e5ec2f18ec) | feat | support NgModule class as an argument of the `downgradeModule` function ([#43973](https://github.com/angular/angular/pull/43973)) |
## Special Thanks
Alan Agius, Alex Rickabaugh, Andrew Kushnir, Andrew Scott, Artur, Christian-E, David Shevitz, Doug Parker, Douglas Parker, Dylan Hunn, George Kalpakas, Jessica Janiuk, Joey Perrott, JoostK, Kristiyan Kostadinov, Marc Redemske, Paul Gschwendtner, Pei Wang, Pete Bacon Darwin, Ramesh Thiruchelvam, Ravi Chandra, Rohan Pednekar, Ruslan Usmanov, dario-piotrowicz, profanis and unknown
Alex Rickabaugh, Andrew Kushnir, Andrew Scott, Doug Parker, Dustin M. Eastway, Dylan Hunn, George Kalpakas, HyperLife1119, Jelle Bruisten, Jessica Janiuk, Joey Perrott, JoostK, Kristiyan Kostadinov, Markus Doggweiler, Paul Gschwendtner, Pei Wang, Pete Bacon Darwin and dario-piotrowicz
<!-- CHANGELOG SPLIT MARKER -->
@@ -88,16 +95,6 @@ Alan Agius, Alex Rickabaugh, Andrew Kushnir, Andrew Scott, Artur, Christian-E, D
<!-- CHANGELOG SPLIT MARKER -->
<a name="13.1.0-next.2"></a>
# 13.1.0-next.2 (2021-11-17)
This release contains various API docs improvements.
## Special Thanks
Andrew Kushnir, Armen Vardanyan, Dylan Hunn, Joey Perrott, Martin von Gagern, Paul Gschwendtner, Pete Bacon Darwin, Ramesh Thiruchelvam, dario-piotrowicz and fusho-takahashi
<!-- CHANGELOG SPLIT MARKER -->
<a name="13.0.2"></a>
# 13.0.2 (2021-11-17)
@@ -108,39 +105,6 @@ Andrew Kushnir, Armen Vardanyan, Dylan Hunn, Joey Perrott, Martin von Gagern, Pa
<!-- CHANGELOG SPLIT MARKER -->
<a name="13.1.0-next.1"></a>
# 13.1.0-next.1 (2021-11-10)
### compiler
| Commit | Type | Description |
| -- | -- | -- |
| [393efa54e6](https://github.com/angular/angular/commit/393efa54e669c4ae1e479fd59fc4f9ea69ab77e9) | fix | ensure that partially compiled queries can handle forward references ([#44113](https://github.com/angular/angular/pull/44113)) |
| [b249e24979](https://github.com/angular/angular/commit/b249e24979d1494957b429ef73f37b68b9087ef9) | fix | generate correct code for safe method calls ([#44088](https://github.com/angular/angular/pull/44088)) |
### compiler-cli
| Commit | Type | Description |
| -- | -- | -- |
| [2a2744721b](https://github.com/angular/angular/commit/2a2744721b429cbce7fd9dabc2963c1c679b67bd) | fix | ensure literal types are retained when `strictNullInputTypes` is disabled ([#38305](https://github.com/angular/angular/pull/38305)) |
| [247c18dee0](https://github.com/angular/angular/commit/247c18dee011f8a743b0b438b8ba2f017b113921) | fix | handle pre-release versions when checking version ([#44109](https://github.com/angular/angular/pull/44109)) |
### core
| Commit | Type | Description |
| -- | -- | -- |
| [4f8eaac7ff](https://github.com/angular/angular/commit/4f8eaac7ff2b73dd18d6317c955d447011a69301) | fix | do not use Function constructors in development mode to avoid CSP violations ([#43587](https://github.com/angular/angular/pull/43587)) |
### http
| Commit | Type | Description |
| -- | -- | -- |
| [d452b388bd](https://github.com/angular/angular/commit/d452b388bdc0d661f41ab382f5e7ac998b0f9915) | feat | add `has()` method to `HttpContext` class ([#43887](https://github.com/angular/angular/pull/43887)) |
### platform-browser
| Commit | Type | Description |
| -- | -- | -- |
| [236bdff831](https://github.com/angular/angular/commit/236bdff831f7dc794d5a03e2d82921887bd5eda8) | fix | use correct parent in animation removeChild callback ([#44033](https://github.com/angular/angular/pull/44033)) |
### upgrade
| Commit | Type | Description |
| -- | -- | -- |
| [34f990986c](https://github.com/angular/angular/commit/34f990986cade3ce6b355354d1e2f6e5ec2f18ec) | feat | support NgModule class as an argument of the `downgradeModule` function ([#43973](https://github.com/angular/angular/pull/43973)) |
## Special Thanks
A. Singh, Alan Agius, Andrew Kushnir, Andrew Scott, Aristeidis Bampakos, Dustin M. Eastway, George Kalpakas, HyperLife1119, Jelle Bruisten, Joe Martin (Crowdstaffing), Joel Lefkowitz, Joey Perrott, JoostK, Kristiyan Kostadinov, Michael Urban, Paul Gschwendtner, Pavan Kumar Jadda, Pei Wang, Pete Bacon Darwin, Roman Frołow, dario-piotrowicz, iRealNirmal, ileil, kreuzerk, mgechev, profanis and raman
<!-- CHANGELOG SPLIT MARKER -->
<a name="13.0.1"></a>
# 13.0.1 (2021-11-10)
### compiler
@@ -166,235 +130,6 @@ A. Singh, Alan Agius, Alex Rickabaugh, Andrew Kushnir, Andrew Scott, Aristeidis
<!-- CHANGELOG SPLIT MARKER -->
<a name="13.1.0-next.0"></a>
# 13.1.0-next.0 (2021-11-03)
### compiler
| Commit | Type | Description |
| -- | -- | -- |
| [c85bcb0c63](https://github.com/angular/angular/commit/c85bcb0c636d65706541d44be62694720f12ad9e) | feat | reference ICU message IDs from their placeholders ([#43534](https://github.com/angular/angular/pull/43534)) |
### localize
| Commit | Type | Description |
| -- | -- | -- |
| [d3cf222a81](https://github.com/angular/angular/commit/d3cf222a8193bc7ccd9e7ce886846d1f79131627) | feat | support "associated message ids" for placeholders ([#43534](https://github.com/angular/angular/pull/43534)) |
## Special Thanks
Alex Rickabaugh, Andrew Kushnir, Andrew Scott, Doug Parker, Dylan Hunn, George Kalpakas, Jessica Janiuk, Joey Perrott, Paul Gschwendtner and Pete Bacon Darwin
<a name="13.0.0"></a>
# 13.0.0 (2021-11-03)
[Blog post "Angular v13 is now available"](http://goo.gle/angular-v13).
## Breaking Changes
### common
- The behavior of the `SpyLocation` used by the `RouterTestingModule` has changed
to match the behavior of browsers. It no longer emits a 'popstate' event
when `Location.go` is called. In addition, `simulateHashChange` now
triggers _both_ a `hashchange` and a `popstate` event.
Tests which use `location.go` and expect the changes to be picked up by
the `Router` should likely change to `simulateHashChange` instead.
Each test is different in what it attempts to assert so there is no
single change that works for all tests. Each test using the `SpyLocation` to
simulate browser URL changes should be evaluated on a case-by-case basis.
### core
- TypeScript versions older than 4.4.2 are no longer supported.
- NodeJS versions older than `v12.20.0` are no longer
supported due to the Angular packages using the NodeJS package exports
feature with subpath patterns.
- The `WrappedValue` class can no longer be imported from `@angular/core`,
which may result in compile errors or failures at runtime if outdated
libraries are used that are still using `WrappedValue`. The usage of
`WrappedValue` should be removed as no replacement is available.
### forms
- A new type called `FormControlStatus` has been introduced, which is a union of all possible status strings for form controls. `AbstractControl.status` has been narrowed from `string` to `FormControlStatus`, and `statusChanges` has been narrowed from `Observable<any>` to `Observable<FormControlStatus>`. Most applications should consume the new types seamlessly. Any breakage caused by this change is likely due to one of the following two problems: (1) the app is comparing `AbstractControl.status` against a string which is not a valid status; or, (2) the app is using `statusChanges` events as if they were something other than strings.
### router
- The default url serializer would previously drop
everything after and including a question mark in query parameters. That
is, for a navigation to `/path?q=hello?&other=123`, the query
params would be parsed to just `{q: 'hello'}`. This is
incorrect because the URI spec allows for question mark characers in
query data. This change will now correctly parse the params for the
above example to be `{v: 'hello?', other: '123'}`.
- Previously `null` and `undefined` inputs for `routerLink` were
equivalent to empty string and there was no way to disable the link's
navigation.
In addition, the `href` is changed from a property `HostBinding()` to an
attribute binding (`HostBinding('attr.href')`). The effect of this
change is that `DebugElement.properties['href']` will now return the
`href` value returned by the native element which will be the full URL
rather than the internal value of the `RouterLink` `href` property.
- The router will no longer replace the browser URL when a new navigation
cancels an ongoing navigation. This often causes URL flicker and was
only in place to support some AngularJS hybrid applications. Hybrid
applications which rely on the `navigationId` being present on initial
navigations that were handled by the Angular router should instead
subscribe to `NavigationCancel` events and perform the
`location.replaceState` themselves to add `navigationId` to the Router
state.
In addition, tests which assert `urlChanges` on the `SpyLocation` may
need to be adjusted to account for the `replaceState` which is no longer
triggered.
- It is no longer possible to use `Route.loadChildren` using a string
value. The following supporting classes were removed from
`@angular/core`:
- `NgModuleFactoryLoader`
- `SystemJsNgModuleFactoryLoader`
The `@angular/router` package no longer exports these symbols:
- `SpyNgModuleFactoryLoader`
- `DeprecatedLoadChildren`
The signature of the `setupTestingRouter` function from
`@angular/core/testing` has been changed to drop its `NgModuleFactoryLoader`
parameter, as an argument for that parameter can no longer be created.
### service-worker
- The return type of `SwUpdate#activateUpdate` and `SwUpdate#checkForUpdate` changed to `Promise<boolean>`.
Although unlikely, it is possible that this change will cause TypeScript type-checking to fail in
some cases. If necessary, update your types to account for the new
return type.
## Deprecations
### core
- Angular no longer requires component factories to dynamically create components. The factory-based signature of the `ViewContainerRef.createComponent` function is deprecated in favor of a different signature that allows passing component classes instead.
- The `getModuleFactory` function is deprecated in favor of the `getNgModuleById` one. With Ivy it's possible to work with NgModule classes directly, without retrieving corresponding factories, so the `getNgModuleById` should be used instead.
- Ivy made it possible to avoid the need to resolve Component and NgModule factories. Framework APIs allow to use Component and NgModule Types directly. As a result, the `PlatformRef.bootstrapModuleFactory` and a factory-based signature of the `ApplicationRef.bootstrap` method are now obsolete and are now deprecated. The `PlatformRef.bootstrapModuleFactory` calls can be replaced with `PlatformRef.bootstrapModule` ones. The `ApplicationRef.bootstrap` method allows to provide Component Type, so this can be used a replacement for the factory-based calls.
- In ViewEngine, [JIT compilation](https://angular.io/guide/glossary#jit) required special providers (like `Compiler`, `CompilerFactory`, etc) to be injected in the app and corresponding methods to be invoked. With Ivy, JIT compilation takes place implicitly if the Component, NgModule, etc have not already been [AOT compiled](https://angular.io/guide/glossary#aot). Those special providers were made available in Ivy for backwards-compatibility with ViewEngine to make the transition to Ivy smoother. Since ViewEngine is deprecated and will soon be removed, those symbols are now deprecated as well:
- `ModuleWithComponentFactories`
- `Compiler`
- `CompilerFactory`
- `JitCompilerFactory`
- `NgModuleFactory`
Important note: this deprecation doesn't affect JIT mode in Ivy (JIT remains available with Ivy).
- In Ivy, AOT summary files are unused in TestBed. Passing AOT summary files in TestBed has no effect, so the `aotSummaries` usage in TestBed is deprecated and will be removed in a future version of Angular.
### platform-server
- The `renderModuleFactory` symbol in `@angular/platform-server` is no longer necessary as of Angular v13.
The `renderModuleFactory` calls can be replaced with `renderModule`.
### service-worker
- The `SwUpdate#activated` observable is deprecated.
The `SwUpdate#activated` observable only emits values as a direct response to calling
`SwUpdate#activateUpdate()` and was only useful for determining whether the call resulted in an
update or not. Now, the return value of `SwUpdate#activateUpdate()` can be used to determine the
outcome of the operation and therefore using `SwUpdate#activated` does not offer any benefit.
- The `SwUpdate#availalbe` observable is deprecated.
The new `SwUpdate#versionUpdates` observable provides the same information and more. Therefore, it
is possible to rebuild the same behavior as `SwUpdate#availalbe` using the events emitted by
`SwUpdate#versionUpdates` and filtering for `VersionReadyEvent` events.
As a result, the `SwUpdate#availalbe` observable is now redundant.
###
| Commit | Type | Description |
| -- | -- | -- |
| [747553dd68](https://github.com/angular/angular/commit/747553dd68209fe25a9704fe7094b4b3fb38bf06) | docs | deprecate ViewEngine-based `renderModuleFactory` ([#43757](https://github.com/angular/angular/pull/43757)) |
### bazel
| Commit | Type | Description |
| -- | -- | -- |
| [62d7005a52](https://github.com/angular/angular/commit/62d7005a52304f41a48f878f176f40e90437a555) | feat | add `strict_templates` and `experimental_extended_template_diagnostics` to `ng_module()` rule ([#43582](https://github.com/angular/angular/pull/43582)) |
| [d977701a43](https://github.com/angular/angular/commit/d977701a43866e9f9fae9f83f224e4b6980a8bd4) | feat | allow for custom conditions to be set in `ng_package` targets ([#43764](https://github.com/angular/angular/pull/43764)) |
| [4886585875](https://github.com/angular/angular/commit/48865858750bc1607f20db9b6bf9f913870742bc) | feat | create transition for enabling partial compilation ([#43431](https://github.com/angular/angular/pull/43431)) |
| [cd1b52483e](https://github.com/angular/angular/commit/cd1b52483e886f6e2ad6cde23ff8a2225cafa219) | feat | expose `esm2020` and `es2020` conditions in APF package exports ([#43740](https://github.com/angular/angular/pull/43740)) |
| [49b82ae561](https://github.com/angular/angular/commit/49b82ae56112c1e0d58ac28bcab1705e1f678ab1) | feat | implement partial compilation APF v13 for `ng_package` rule ([#43431](https://github.com/angular/angular/pull/43431)) |
| [274cb38e0b](https://github.com/angular/angular/commit/274cb38e0bb9a8bff4a48d1d15f4e16e59ec6f88) | feat | switch prodmode output to ES2020 ([#43431](https://github.com/angular/angular/pull/43431)) |
| [73ac50c447](https://github.com/angular/angular/commit/73ac50c44759c5d3048f11d6f98b98a5e625df58) | feat | wire up partial compilation build setting in `ng_module` ([#43431](https://github.com/angular/angular/pull/43431)) |
| [e0a72857cc](https://github.com/angular/angular/commit/e0a72857ccda2b21a91875ee714fef608b54c083) | fix | construct a manifest file even when warnings are emitted ([#43582](https://github.com/angular/angular/pull/43582)) |
| [dbe656d1e0](https://github.com/angular/angular/commit/dbe656d1e0569304c7001296ec90cf2e9cc8c91f) | fix | ngc-wrapped should not rely on linker for external workspaces ([#43690](https://github.com/angular/angular/pull/43690)) |
### common
| Commit | Type | Description |
| -- | -- | -- |
| [adf4481211](https://github.com/angular/angular/commit/adf4481211ac0a2eabf560f42ef5193ca550ec98) | feat | add injection token for default date pipe timezone ([#43611](https://github.com/angular/angular/pull/43611)) |
| [c6a93001eb](https://github.com/angular/angular/commit/c6a93001eb74374b0fbc6aea1286fe1183d21382) | fix | synchronise location mock behavior with the navigators ([#41730](https://github.com/angular/angular/pull/41730)) |
### compiler
| Commit | Type | Description |
| -- | -- | -- |
| [14b492df26](https://github.com/angular/angular/commit/14b492df26fcb3f2218f67878a382e8f7dff2c05) | fix | do not error if $any is used inside a listener ([#43866](https://github.com/angular/angular/pull/43866)) |
### compiler-cli
| Commit | Type | Description |
| -- | -- | -- |
| [bed121c34f](https://github.com/angular/angular/commit/bed121c34f9c4ec4741a4690693423bb7ed66982) | feat | inline resources when generating class metadata calls ([#43178](https://github.com/angular/angular/pull/43178)) |
| [263feba5c2](https://github.com/angular/angular/commit/263feba5c2d56e8433068718d1fdcbc3b2ae144c) | fix | handle nullable expressions correctly in the nullish coalescing extended template diagnostic ([#43572](https://github.com/angular/angular/pull/43572)) |
| [8f7fdc59af](https://github.com/angular/angular/commit/8f7fdc59af7f1b0a51b07e69044368c223b9f186) | fix | not evaluating new signature for __spreadArray ([#43618](https://github.com/angular/angular/pull/43618)) |
| [426a3ecae7](https://github.com/angular/angular/commit/426a3ecae7288c2cb3e8928d7fe56b0b4552d821) | fix | updates `ngc` to pass the build when only warnings are emitted ([#43673](https://github.com/angular/angular/pull/43673)) |
### core
| Commit | Type | Description |
| -- | -- | -- |
| [a3960846da](https://github.com/angular/angular/commit/a3960846da1f73282306560302daa3a4ddeca0f7) | feat | add `createNgModuleRef` function to create `NgModuleRef` based on NgModule class ([#43580](https://github.com/angular/angular/pull/43580)) |
| [fe1f6421d2](https://github.com/angular/angular/commit/fe1f6421d2b647adb706e65f69ec2e40e604fac3) | feat | add `getNgModuleById` function to retrieve loaded NgModules by id ([#43580](https://github.com/angular/angular/pull/43580)) |
| [81c7eb813c](https://github.com/angular/angular/commit/81c7eb813c27f08d2d640f34e165a1b5e487bac2) | feat | add migration to opt out existing apps from new test module teardown behavior ([#43353](https://github.com/angular/angular/pull/43353)) |
| [e57691c9c5](https://github.com/angular/angular/commit/e57691c9c5f8456f7dc75180aa1e80330da560fe) | feat | Add migration to update empty routerLinks in templates ([#43176](https://github.com/angular/angular/pull/43176)) |
| [7dccbdd27b](https://github.com/angular/angular/commit/7dccbdd27be13eb7287f535f482b1de2c13fca74) | feat | add support for Types in ViewContainerRef.createComponent ([#43022](https://github.com/angular/angular/pull/43022)) |
| [c14085e434](https://github.com/angular/angular/commit/c14085e43493f0a1eaea1df949cbf6f3b13b72a0) | feat | drop support for TypeScript 4.2 and 4.3 ([#43642](https://github.com/angular/angular/pull/43642)) |
| [94ba59bc9d](https://github.com/angular/angular/commit/94ba59bc9db81ae04f20e8147b5133a0d3d45510) | feat | enable test module teardown by default ([#43353](https://github.com/angular/angular/pull/43353)) |
| [ea61ec2562](https://github.com/angular/angular/commit/ea61ec25628206d18a424906f685c0d0fd6aa714) | feat | support TypeScript 4.4 ([#43281](https://github.com/angular/angular/pull/43281)) |
| [e0a0d05d45](https://github.com/angular/angular/commit/e0a0d05d45bcb93448a8c2fd03f9e1783146cf00) | feat | update node version support range to support v16 ([#43740](https://github.com/angular/angular/pull/43740)) |
| [7396021e4b](https://github.com/angular/angular/commit/7396021e4b22faca47b7fc0bab188c838090f3e7) | fix | avoid duplicating comments in TestBed teardown migration ([#43776](https://github.com/angular/angular/pull/43776)) |
| [7fd0428aae](https://github.com/angular/angular/commit/7fd0428aae3a7d94bfc8fee764ac24f5fe3fbb41) | fix | don't rethrow errors if test teardown has been disabled ([#43635](https://github.com/angular/angular/pull/43635)) |
| [66fb311d20](https://github.com/angular/angular/commit/66fb311d205e51647e2c1f84a6e3adf5ef3cfd64) | fix | incorrect signature for initTestEnvironment ([#43615](https://github.com/angular/angular/pull/43615)) |
| [8ae99821d6](https://github.com/angular/angular/commit/8ae99821d657ba940df998f6abec425f8a1f4cb1) | fix | support `InjectFlags` argument in `NodeInjector.get()` ([#41592](https://github.com/angular/angular/pull/41592)) |
| [8878183521](https://github.com/angular/angular/commit/88781835212354d7058a3674a04c2a1dd4b8f9c3) | perf | remove support for the deprecated `WrappedValue` ([#43507](https://github.com/angular/angular/pull/43507)) |
### elements
| Commit | Type | Description |
| -- | -- | -- |
| [a468213f34](https://github.com/angular/angular/commit/a468213f34943b7ddf234e6f9fd406431173d6a0) | fix | remove `ng-add` schematic ([#43975](https://github.com/angular/angular/pull/43975)) |
| [f544a53f5f](https://github.com/angular/angular/commit/f544a53f5f3667b4c557537543a9b74a122d5f24) | fix | remove incorrect `@angular/platform-browser` peer dependency ([#43975](https://github.com/angular/angular/pull/43975)) |
### forms
| Commit | Type | Description |
| -- | -- | -- |
| [d9d8f950e9](https://github.com/angular/angular/commit/d9d8f950e90567c79b43eb156b81810a9f3d5c93) | feat | allow disabling min/max validators dynamically (by setting the value to `null`) ([#42978](https://github.com/angular/angular/pull/42978)) |
| [e49fc96ed3](https://github.com/angular/angular/commit/e49fc96ed33c26434a14b80487dd912d8c76cace) | feat | Make Form Statuses use stricter types. ([#42952](https://github.com/angular/angular/pull/42952)) |
### language-service
| Commit | Type | Description |
| -- | -- | -- |
| [b10d90bef6](https://github.com/angular/angular/commit/b10d90bef6a3d1b721d087268aa7377985dd4c4f) | feat | Add method for retrieving the component template at the cursor location ([#43208](https://github.com/angular/angular/pull/43208)) |
| [d5f9890c92](https://github.com/angular/angular/commit/d5f9890c9205b4a121275ace84b26776aedd0478) | feat | auto-apply optional chaining on nullable symbol ([#42995](https://github.com/angular/angular/pull/42995)) |
| [69957f72e2](https://github.com/angular/angular/commit/69957f72e240e516fe65146c314014fadc43dd1f) | feat | provide snippets for attribute ([#43590](https://github.com/angular/angular/pull/43590)) |
| [fc3b50e427](https://github.com/angular/angular/commit/fc3b50e4275c84a1cd3f75e4b52ee2dc4b65c35c) | fix | exclude the `SafePropertyRead` when applying the optional chaining ([#43321](https://github.com/angular/angular/pull/43321)) |
### migrations
| Commit | Type | Description |
| -- | -- | -- |
| [95a68c5dc3](https://github.com/angular/angular/commit/95a68c5dc3b72c0fe275e5025445befec3d9dc1e) | fix | account for CRLF characters in template migrations ([#44013](https://github.com/angular/angular/pull/44013)) |
| [77bd2538cb](https://github.com/angular/angular/commit/77bd2538cb8fe114a326209791d7ec043d65ea9e) | fix | apply individual expression edits to preserve newline characters ([#43519](https://github.com/angular/angular/pull/43519)) |
| [d849350c7b](https://github.com/angular/angular/commit/d849350c7bf19117bbf85e2d854b5be4d5eb4b25) | fix | Ensure routerLink migration doesn't update unrelated files ([#43519](https://github.com/angular/angular/pull/43519)) |
| [2efc18e675](https://github.com/angular/angular/commit/2efc18e6757157589004e23d8d22b7967de4387d) | fix | migration failed finding tsconfig file ([#43343](https://github.com/angular/angular/pull/43343)) |
| [b6f2a55147](https://github.com/angular/angular/commit/b6f2a551475126893c4ceff1241314067e14d0b6) | fix | prevent migrations from updating external templates multiple times ([#44013](https://github.com/angular/angular/pull/44013)) |
### router
| Commit | Type | Description |
| -- | -- | -- |
| [4f3beffdbf](https://github.com/angular/angular/commit/4f3beffdbfa974b380b2225f163d363dd17e10bd) | feat | emit activate/deactivate events when an outlet gets attached/detached ([#43333](https://github.com/angular/angular/pull/43333)) |
| [faf9f5a3bc](https://github.com/angular/angular/commit/faf9f5a3bc444bb6cbf75916c8022f60e0742bca) | feat | new output that would notify when link is activated ([#43280](https://github.com/angular/angular/pull/43280)) |
| [3c6b653089](https://github.com/angular/angular/commit/3c6b653089837459809a370ebcaf8911c3bab9ed) | feat | Option to correctly restore history on failed navigation ([#43289](https://github.com/angular/angular/pull/43289)) |
| [784671597e](https://github.com/angular/angular/commit/784671597e0b28d9696bdc325b426a6c7be0cd8e) | fix | Allow question marks in query param values ([#31187](https://github.com/angular/angular/pull/31187)) |
| [796da641f0](https://github.com/angular/angular/commit/796da641f0a29e9f5f5de115c456da37426e971c) | fix | Do not modify parts of URL excluded from with 'eager' updates ([#43421](https://github.com/angular/angular/pull/43421)) |
| [772e08d14e](https://github.com/angular/angular/commit/772e08d14e534f20e4376109e81604965e189abf) | fix | fix Router's public API for canceledNavigationResolution ([#43842](https://github.com/angular/angular/pull/43842)) |
| [ccb09b4558](https://github.com/angular/angular/commit/ccb09b4558a3864fb5b2fe2214d08f1c1fe2758f) | fix | null/undefined routerLink should disable navigation ([#43087](https://github.com/angular/angular/pull/43087)) |
| [9e039ca68b](https://github.com/angular/angular/commit/9e039ca68bfae5328f3fc1f16fabd7673c466a25) | fix | Only trigger router navigation on `popstate` events from `Location` subscription ([#43328](https://github.com/angular/angular/pull/43328)) |
| [c5d0bd4966](https://github.com/angular/angular/commit/c5d0bd4966a4fc595d57f75569754b4d224ef2ba) | fix | Prevent URL flicker when new navigations cancel ongoing ones ([#43496](https://github.com/angular/angular/pull/43496)) |
| [adc68b100b](https://github.com/angular/angular/commit/adc68b100b98aef171ee298cc23bd5291b106526) | fix | reuse route strategy fix ([#43791](https://github.com/angular/angular/pull/43791)) |
| [361273fad5](https://github.com/angular/angular/commit/361273fad5030c900c83d333a779f6edbe20c688) | refactor | remove support for `loadChildren` string syntax ([#43591](https://github.com/angular/angular/pull/43591)) |
### service-worker
| Commit | Type | Description |
| -- | -- | -- |
| [59225f5586](https://github.com/angular/angular/commit/59225f5586f1319a47768cef2e3325d7ab6940af) | feat | `SwUpdate#activeUpdate` and `SwUpdate#checkForUpdate` should have a meaningful outcome ([#43668](https://github.com/angular/angular/pull/43668)) |
| [0dc45446fe](https://github.com/angular/angular/commit/0dc45446fe487febaefaf68a928c5a249880f2f3) | feat | expose more version update events ([#43668](https://github.com/angular/angular/pull/43668)) |
## Special Thanks
Ahmed Ayed, Alan Agius, Alex Rickabaugh, Andrew Kushnir, Andrew Scott, Bjarki, Charles Lyding, Dmitrij Kuba, Doug Parker, Dylan Hunn, George Kalpakas, Jessica Janiuk, Jochen Kraushaar, Joe Martin (Crowdstaffing), Joey Perrott, Jon Rimmer, JoostK, Kristiyan Kostadinov, Maximilian Köller, Paul Gschwendtner, Pei Wang, Pete Bacon Darwin, Tomasz Domański, Willy Schott, anandtiwary, dario-piotrowicz, iRealNirmal, ivanwonder, krzysztof-grzybek, mgechev and vthinkxie
<!-- CHANGELOG SPLIT MARKER -->
<a name="12.2.13"></a>
# 12.2.13 (2021-11-03)
### compiler-cli
+2 -2
View File
@@ -8,8 +8,8 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
# Fetch rules_nodejs so we can install our npm dependencies
http_archive(
name = "build_bazel_rules_nodejs",
sha256 = "4913ea835810c195df24d3a929315c29a64566cc48e409d8b0f35008b4e02e59",
urls = ["https://github.com/bazelbuild/rules_nodejs/releases/download/4.4.4/rules_nodejs-4.4.4.tar.gz"],
sha256 = "cfc289523cf1594598215901154a6c2515e8bf3671fd708264a6f6aefe02bf39",
urls = ["https://github.com/bazelbuild/rules_nodejs/releases/download/4.4.6/rules_nodejs-4.4.6.tar.gz"],
)
# The PKG rules are needed to build tar packages for integration tests. The builtin
@@ -7,7 +7,7 @@ import { CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot } from '@angul
})
export class AuthGuard implements CanActivate {
canActivate(
next: ActivatedRouteSnapshot,
route: ActivatedRouteSnapshot,
state: RouterStateSnapshot): boolean {
console.log('AuthGuard#canActivate called');
return true;
@@ -11,7 +11,7 @@ export class AuthGuard implements CanActivate {
constructor(private authService: AuthService, private router: Router) {}
canActivate(
next: ActivatedRouteSnapshot,
route: ActivatedRouteSnapshot,
state: RouterStateSnapshot): true|UrlTree {
const url: string = state.url;
+2 -2
View File
@@ -4,7 +4,7 @@ To prepare your project for translation, complete the following actions.
* Use the `i18n` attribute to mark text in component templates
* Use the `i18n-` attribute to mark attribute text strings in component templates
* Use the `$localize` tagged message string to mark test strings in component code
* Use the `$localize` tagged message string to mark text strings in component code
## Mark text in component template
@@ -489,4 +489,4 @@ The following code example shows nested clauses based on the `gender` and `minut
<!-- end links -->
@reviewed 2021-10-13
@reviewed 2021-12-13
+1 -1
View File
@@ -141,7 +141,7 @@ To get information from a route:
<code-example path="router/src/app/heroes/hero-detail/hero-detail.component.ts" region="activated-route" header="In the component class (excerpt)">
</code-example>
1. Update the `ngOnInit()` method to access the `ActivatedRoute` and track the `id` parameter:
1. Update the `ngOnInit()` method to access the `ActivatedRoute` and track the `name` parameter:
<code-example header="In the component (excerpt)">
ngOnInit() {
Binary file not shown.

After

Width:  |  Height:  |  Size: 29 KiB

+9 -1
View File
@@ -134,7 +134,7 @@
"picture": "aristeidis.jpg",
"twitter": "abampakos",
"website": "https://medium.com/@abampakos",
"bio": "Aristeidis is a web development team lead at Plex-Earth working with Angular. He is a co-organizer of the Angular Athens meetup and the author of Learning Angular - 3rd Edition and Angular Projects - 2nd Edition books. He is also a senior Angular instructor at Code.Hub where he teaches the Angular framework to other developers.",
"bio": "Aristeidis is a web development team lead at Plex-Earth working with Angular. He is the author of two books about Angular: Learning Angular - 3rd Edition and Angular Projects - 2nd Edition. He also works as an Angular senior tech instructor at Code.Hub where he teaches the Angular framework to other developers and professionals.",
"groups": ["GDE"]
},
"bbrennan": {
@@ -992,6 +992,14 @@
"bio": "GDE (Google Developer Expert) Angular and Web Technologies, GDG Salvador organizer, passionate about technology and active in communities with a focus on web development, including Angular, JavaScript, HTML5, CSS3, Workflow, web performance, security and Internet of things. Participates in events organization, speaker at conferences in Brazil and other countries and contributes to several open source projects.",
"groups": ["GDE"]
},
"yharaskrik": {
"name": "Jay Bell",
"picture": "jaybell.jpg",
"twitter": "jaycooperbell",
"website": "tech.trellis.org",
"bio": "Jay is the CTO and Co-Founder of a Social Enterprise in Canada that is using Angular and technology to empower global collective impact in the non-profit and charity industries. He is an avid contributor to Nx and loves Angular, NgRx and Nest. Jay loves to share knowledge he has learned from figuring out problems (complex or otherwise) so that others can solve them easier the next time.",
"groups": ["GDE"]
},
"yjaaidi": {
"name": "Younes Jaaidi",
"picture": "younes.jpg",
+19 -19
View File
@@ -18,7 +18,7 @@
"build-local": "yarn ~~build",
"prebuild-local-ci": "yarn setup-local-ci",
"build-local-ci": "yarn ~~build --progress=false",
"extract-cli-command-docs": "node tools/transforms/cli-docs-package/extract-cli-commands.js 481eb4544",
"extract-cli-command-docs": "node tools/transforms/cli-docs-package/extract-cli-commands.js febee7484",
"lint": "yarn check-env && yarn docs-lint && ng lint && yarn example-lint && yarn tools-lint && yarn security-lint",
"test": "yarn check-env && ng test",
"pree2e": "yarn check-env && yarn update-webdriver",
@@ -85,39 +85,39 @@
},
"private": true,
"dependencies": {
"@angular/animations": "13.0.2",
"@angular/cdk": "13.0.2",
"@angular/common": "13.0.2",
"@angular/compiler": "13.0.2",
"@angular/core": "13.0.2",
"@angular/elements": "13.0.2",
"@angular/forms": "13.0.2",
"@angular/material": "13.0.2",
"@angular/platform-browser": "13.0.2",
"@angular/platform-browser-dynamic": "13.0.2",
"@angular/router": "13.0.2",
"@angular/service-worker": "13.0.2",
"@angular/animations": "13.0.3",
"@angular/cdk": "13.0.3",
"@angular/common": "13.0.3",
"@angular/compiler": "13.0.3",
"@angular/core": "13.0.3",
"@angular/elements": "13.0.3",
"@angular/forms": "13.0.3",
"@angular/material": "13.0.3",
"@angular/platform-browser": "13.0.3",
"@angular/platform-browser-dynamic": "13.0.3",
"@angular/router": "13.0.3",
"@angular/service-worker": "13.0.3",
"rxjs": "~7.4.0",
"safevalues": "^0.1.8",
"tslib": "^2.3.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "13.0.3",
"@angular-devkit/build-angular": "^13.1.0",
"@angular-eslint/builder": "^13.0.0",
"@angular-eslint/eslint-plugin": "^13.0.0",
"@angular-eslint/eslint-plugin-template": "^13.0.0",
"@angular-eslint/template-parser": "^13.0.0",
"@angular/cli": "13.0.3",
"@angular/compiler-cli": "13.0.2",
"@angular/cli": "^13.1.0",
"@angular/compiler-cli": "13.0.3",
"@types/jasmine": "~3.10.0",
"@types/lunr": "^2.3.3",
"@types/node": "^12.7.9",
"@types/stemmer": "^1.0.2",
"@types/trusted-types": "^2.0.2",
"@types/xregexp": "^4.3.0",
"@typescript-eslint/eslint-plugin": "5.3.1",
"@typescript-eslint/parser": "5.3.1",
"@typescript-eslint/eslint-plugin": "5.7.0",
"@typescript-eslint/parser": "5.7.0",
"@yarnpkg/lockfile": "^1.1.0",
"archiver": "^5.3.0",
"assert": "^2.0.0",
@@ -152,7 +152,7 @@
"json5": "^2.2.0",
"karma": "~6.3.2",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage": "~2.0.3",
"karma-coverage": "~2.1.0",
"karma-jasmine": "~4.0.0",
"karma-jasmine-html-reporter": "~1.7.0",
"light-server": "^2.9.1",
+1 -1
View File
@@ -58,7 +58,7 @@ describe('Api pages', () => {
});
it('should not show a "Properties" section if there are only internal properties', async () => {
await page.navigateTo('api/forms/FormControl');
await page.navigateTo('api/forms/AsyncValidator');
expect(await page.getSection('instance-properties').isPresent()).toBe(false);
});
@@ -13,14 +13,14 @@
},
"private": true,
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/router": "~13.1.0",
"angular": "1.8.0",
"angular-in-memory-web-api": "~0.11.0",
"angular-route": "1.8.0",
@@ -29,9 +29,9 @@
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.0.0-rc.3",
"@angular/cli": "~13.0.0-rc.3",
"@angular/compiler-cli": "~13.0.0-next.0",
"@angular-devkit/build-angular": "~13.1.0",
"@angular/cli": "~13.1.0",
"@angular/compiler-cli": "~13.1.0",
"@types/angular": "1.7.3",
"@types/angular-route": "1.7.1",
"@types/jasmine": "~3.10.0",
@@ -13,23 +13,23 @@
},
"private": true,
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/router": "~13.1.0",
"angular-in-memory-web-api": "~0.11.0",
"rxjs": "~7.4.0",
"tslib": "^2.3.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.0.0-rc.3",
"@angular/cli": "~13.0.0-rc.3",
"@angular/compiler-cli": "~13.0.0-next.0",
"@angular-devkit/build-angular": "~13.1.0",
"@angular/cli": "~13.1.0",
"@angular/compiler-cli": "~13.1.0",
"@types/jasmine": "~3.10.0",
"@types/node": "^12.11.1",
"copyfiles": "^2.4.1",
@@ -13,24 +13,24 @@
},
"private": true,
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/elements": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/elements": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/router": "~13.1.0",
"angular-in-memory-web-api": "~0.11.0",
"rxjs": "~7.4.0",
"tslib": "^2.3.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.0.0-rc.3",
"@angular/cli": "~13.0.0-rc.3",
"@angular/compiler-cli": "~13.0.0-next.0",
"@angular-devkit/build-angular": "~13.1.0",
"@angular/cli": "~13.1.0",
"@angular/compiler-cli": "~13.1.0",
"@types/jasmine": "~3.10.0",
"@types/node": "^12.11.1",
"jasmine-core": "~3.10.0",
@@ -16,24 +16,24 @@
},
"private": true,
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/localize": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/localize": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/router": "~13.1.0",
"angular-in-memory-web-api": "~0.11.0",
"rxjs": "~7.4.0",
"tslib": "^2.3.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.0.0-rc.3",
"@angular/cli": "~13.0.0-rc.3",
"@angular/compiler-cli": "~13.0.0-next.0",
"@angular-devkit/build-angular": "~13.1.0",
"@angular/cli": "~13.1.0",
"@angular/compiler-cli": "~13.1.0",
"@types/jasmine": "~3.10.0",
"@types/node": "^12.11.1",
"jasmine-core": "~3.10.0",
@@ -13,24 +13,24 @@
},
"private": true,
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@angular/service-worker": "~13.0.0-next.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/router": "~13.1.0",
"@angular/service-worker": "~13.1.0",
"angular-in-memory-web-api": "~0.11.0",
"rxjs": "~7.4.0",
"tslib": "^2.3.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.0.0-rc.3",
"@angular/cli": "~13.0.0-rc.3",
"@angular/compiler-cli": "~13.0.0-next.0",
"@angular-devkit/build-angular": "~13.1.0",
"@angular/cli": "~13.1.0",
"@angular/compiler-cli": "~13.1.0",
"@types/jasmine": "~3.10.0",
"@types/node": "^12.11.1",
"jasmine-core": "~3.10.0",
@@ -25,15 +25,15 @@
},
"private": true,
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@angular/upgrade": "~13.0.0-next.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/router": "~13.1.0",
"@angular/upgrade": "~13.1.0",
"core-js": "^2.5.4",
"rxjs": "~7.4.0",
"systemjs": "~0.19.39",
@@ -42,7 +42,7 @@
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular/compiler-cli": "~13.0.0-next.0",
"@angular/compiler-cli": "~13.1.0",
"@types/angular": "1.7.3",
"@types/angular-animate": "1.5.10",
"@types/angular-mocks": "1.7.0",
@@ -17,16 +17,16 @@
},
"private": true,
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/platform-server": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@nguniversal/express-engine": "~13.0.0-rc.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/platform-server": "~13.1.0",
"@angular/router": "~13.1.0",
"@nguniversal/express-engine": "~13.0.0",
"angular-in-memory-web-api": "~0.11.0",
"express": "^4.15.2",
"rxjs": "~7.4.0",
@@ -34,10 +34,10 @@
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.0.0-rc.3",
"@angular/cli": "~13.0.0-rc.3",
"@angular/compiler-cli": "~13.0.0-next.0",
"@nguniversal/builders": "~13.0.0-rc.0",
"@angular-devkit/build-angular": "~13.1.0",
"@angular/cli": "~13.1.0",
"@angular/compiler-cli": "~13.1.0",
"@nguniversal/builders": "~13.0.0",
"@types/express": "^4.17.8",
"@types/jasmine": "~3.10.0",
"@types/node": "^12.11.1",
+18 -18
View File
@@ -21,20 +21,20 @@
"license": "MIT",
"repository": {},
"dependencies": {
"@angular/animations": "~13.0.0-next.0",
"@angular/common": "~13.0.0-next.0",
"@angular/compiler": "~13.0.0-next.0",
"@angular/core": "~13.0.0-next.0",
"@angular/elements": "~13.0.0-next.0",
"@angular/forms": "~13.0.0-next.0",
"@angular/localize": "~13.0.0-next.0",
"@angular/platform-browser": "~13.0.0-next.0",
"@angular/platform-browser-dynamic": "~13.0.0-next.0",
"@angular/platform-server": "~13.0.0-next.0",
"@angular/router": "~13.0.0-next.0",
"@angular/service-worker": "~13.0.0-next.0",
"@angular/upgrade": "~13.0.0-next.0",
"@nguniversal/express-engine": "~13.0.0-rc.0",
"@angular/animations": "~13.1.0",
"@angular/common": "~13.1.0",
"@angular/compiler": "~13.1.0",
"@angular/core": "~13.1.0",
"@angular/elements": "~13.1.0",
"@angular/forms": "~13.1.0",
"@angular/localize": "~13.1.0",
"@angular/platform-browser": "~13.1.0",
"@angular/platform-browser-dynamic": "~13.1.0",
"@angular/platform-server": "~13.1.0",
"@angular/router": "~13.1.0",
"@angular/service-worker": "~13.1.0",
"@angular/upgrade": "~13.1.0",
"@nguniversal/express-engine": "~13.0.0",
"angular": "1.8.0",
"angular-in-memory-web-api": "~0.11.0",
"angular-route": "1.8.0",
@@ -47,10 +47,10 @@
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.0.0-rc.3",
"@angular/cli": "~13.0.0-rc.3",
"@angular/compiler-cli": "~13.0.0-next.0",
"@nguniversal/builders": "~13.0.0-rc.0",
"@angular-devkit/build-angular": "~13.1.0",
"@angular/cli": "~13.1.0",
"@angular/compiler-cli": "~13.1.0",
"@nguniversal/builders": "~13.0.0",
"@types/angular": "1.7.3",
"@types/angular-animate": "1.5.10",
"@types/angular-mocks": "1.7.0",
File diff suppressed because it is too large Load Diff
+949 -841
View File
File diff suppressed because it is too large Load Diff
+4 -4
View File
@@ -2,8 +2,8 @@
"aio": {
"master": {
"uncompressed": {
"runtime": 4436,
"main": 460179,
"runtime": 4330,
"main": 457054,
"polyfills": 37123,
"styles": 70149,
"light-theme": 77369,
@@ -14,8 +14,8 @@
"aio-local": {
"master": {
"uncompressed": {
"runtime": 4436,
"main": 458469,
"runtime": 4330,
"main": 456498,
"polyfills": 37271,
"styles": 70149,
"light-theme": 77369,
-198
View File
@@ -1,198 +0,0 @@
# Copyright Google LLC All Rights Reserved.
#
# Use of this source code is governed by an MIT-style license that can be
# found in the LICENSE file at https://angular.io/license
"""Angular integration testing
"""
load("//tools/npm_integration_test:npm_integration_test.bzl", "npm_integration_test")
load("@build_bazel_rules_nodejs//:index.bzl", "copy_to_bin")
# The @npm packages at the root node_modules are used by integration tests
# with `file:../../node_modules/foobar` references
NPM_PACKAGE_ARCHIVES = [
"@angular/animations-12",
"@angular/common-12",
"@angular/core-12",
"@angular/forms-12",
"@angular/platform-browser-12",
"@angular/platform-browser-dynamic-12",
"@angular/platform-server-12",
"@angular/router-12",
"@babel/core",
"@rollup/plugin-babel",
"@rollup/plugin-node-resolve",
"@rollup/plugin-commonjs",
"check-side-effects",
"core-js",
"google-closure-compiler",
"jasmine",
"typescript",
"rxjs",
"systemjs",
"tsickle",
"tslib",
"protractor",
"terser",
"puppeteer",
"rollup",
"rollup-plugin-sourcemaps",
"webdriver-manager",
"@angular/cli",
"@angular-devkit/build-angular",
"@bazel/bazelisk",
"@types/jasmine",
"@types/jasminewd2",
"@types/node",
]
# The generated npm packages should ALWAYS be replaced in integration tests
# so we pass them to the `check_npm_packages` attribute of npm_integration_test
FRAMEWORK_PACKAGES = [
"@angular/animations",
"@angular/bazel",
"@angular/benchpress",
"@angular/common",
"@angular/compiler",
"@angular/compiler-cli",
"@angular/core",
"@angular/elements",
"@angular/forms",
"@angular/language-service",
"@angular/localize",
"@angular/platform-browser",
"@angular/platform-browser-dynamic",
"@angular/platform-server",
"@angular/router",
"@angular/service-worker",
"@angular/upgrade",
"zone.js",
]
def npm_package_archives():
"""Function to generate pkg_tar definitions for WORKSPACE yarn_install manual_build_file_contents"""
npm_packages_to_archive = NPM_PACKAGE_ARCHIVES
result = """load("@rules_pkg//:pkg.bzl", "pkg_tar")
"""
for name in npm_packages_to_archive:
label_name = _npm_package_archive_label(name)
last_segment_name = name.split("/")[-1]
result += """pkg_tar(
name = "{label_name}",
srcs = ["//{name}:{last_segment_name}__all_files"],
extension = "tar.gz",
strip_prefix = "/external/npm/node_modules/{name}",
# should not be built unless it is a dependency of another rule
tags = ["manual"],
)
""".format(name = name, label_name = label_name, last_segment_name = last_segment_name)
return result
def _npm_package_archive_label(package_name):
return package_name.replace("/", "_").replace("@", "") + "_archive"
def _angular_integration_test(name, **kwargs):
"Set defaults for the npm_integration_test common to the angular repo"
payload_size_tracking = kwargs.pop("payload_size_tracking", [])
pinned_npm_packages = kwargs.pop("pinned_npm_packages", [])
use_view_engine_packages = kwargs.pop("use_view_engine_packages", [])
data = [
# We need the yarn_bin & yarn_files available at runtime
"@nodejs//:yarn_bin",
"@nodejs//:yarn_files",
]
# By default run `yarn install` followed by `yarn test` using
# the bazel managed hermetic version of yarn inside
DEFAULT_COMMANDS = [
"patch-package-json",
# Workaround https://github.com/yarnpkg/yarn/issues/2165
# Yarn will cache file://dist URIs and not update Angular code
"rm -rf ./.yarn_local_cache",
"mkdir .yarn_local_cache",
"$(rootpath @nodejs//:yarn_bin) install --cache-folder ./.yarn_local_cache",
"$(rootpath @nodejs//:yarn_bin) test",
]
commands = kwargs.pop("commands", [])
if commands == "default":
commands = DEFAULT_COMMANDS
elif commands == "payload_size_tracking":
commands = DEFAULT_COMMANDS + [
"$(rootpath @nodejs//:yarn_bin) build",
"$(rootpath //:scripts/ci/track-payload-size.sh) %s dist/*.js true ${RUNFILES}/angular/$(rootpath //goldens:size-tracking/integration-payloads.json)" % name,
]
data = data + [
"//goldens:size-tracking/integration-payloads.json",
"//:scripts/ci/track-payload-size.sh",
"//:scripts/ci/payload-size.sh",
"//:scripts/ci/payload-size.js",
]
# Complete list of npm packages to override in the test's package.json file mapped to
# tgz archive to use for the replacement. This is the full list for all integration
# tests. Any given integration does not need to use all of these packages.
npm_packages = {}
for pkg in NPM_PACKAGE_ARCHIVES:
if pkg not in pinned_npm_packages:
npm_packages["@npm//:" + _npm_package_archive_label(pkg)] = pkg
for pkg in FRAMEWORK_PACKAGES:
# If the generated Angular framework package is listed in the `use_view_engine_packages`
# list, we will not use the local-built NPM package, but instead map to the
# corresponding View Engine v12.x package from the `@npm//` workspace.
if pkg in use_view_engine_packages:
npm_packages["@npm//:" + _npm_package_archive_label("%s-12" % pkg)] = pkg
else:
last_segment_name = pkg.split("/")[-1]
npm_packages["//packages/%s:npm_package_archive" % last_segment_name] = pkg
npm_integration_test(
name = name + "_test",
check_npm_packages = FRAMEWORK_PACKAGES,
commands = commands,
npm_packages = npm_packages,
tags = kwargs.pop("tags", []) + [
# `integration` tag is used for filtering out these tests from the normal
# developer workflow
"integration",
# Integration do not work inside of a sandbox as they may run host applications such
# as chrome (which is run by ng) that require access to files outside of the sandbox.
"no-sandbox",
# Remote doesn't work as it needs network access right now
"no-remote-exec",
],
data = kwargs.pop("data", []) + data,
# 15-minute timeout
timeout = "long",
# Tells bazel that this test should be allocated a large amount of memory.
# See https://docs.bazel.build/versions/2.0.0/be/common-definitions.html#common-attributes-tests.
size = "enormous",
**kwargs
)
def angular_integration_test(name, **kwargs):
"Sets up the integration test target based on the test folder name"
# Note: We copy the `package.json` file to the `bazel-bin` as otherwise
# the actual source file `package.json` file would be modified on Windows.
copy_to_bin(
name = "%s_package_json" % name,
srcs = ["%s/package.json" % name],
)
native.filegroup(
name = "_%s_sources" % name,
srcs = ["%s_package_json" % name] + native.glob(
include = ["%s/**" % name],
exclude = [
"%s/package.json",
"%s/node_modules/**" % name,
"%s/.yarn_local_cache/**" % name,
],
),
)
_angular_integration_test(
name = name,
test_files = kwargs.pop("test_files", "_%s_sources" % name),
**kwargs
)
@@ -2,6 +2,6 @@ load("//integration:index.bzl", "ng_integration_test")
ng_integration_test(
name = "test",
commands = "payload_size_tracking",
setup_chromium = True,
track_payload_size = "cli-hello-world-ivy-compat",
)
@@ -2,6 +2,6 @@ load("//integration:index.bzl", "ng_integration_test")
ng_integration_test(
name = "test",
commands = "payload_size_tracking",
setup_chromium = True,
track_payload_size = "cli-hello-world-ivy-i18n",
)
@@ -2,6 +2,6 @@ load("//integration:index.bzl", "ng_integration_test")
ng_integration_test(
name = "test",
commands = "payload_size_tracking",
setup_chromium = True,
track_payload_size = "cli-hello-world-ivy-minimal",
)
+1 -1
View File
@@ -2,6 +2,6 @@ load("//integration:index.bzl", "ng_integration_test")
ng_integration_test(
name = "test",
commands = "payload_size_tracking",
setup_chromium = True,
track_payload_size = "cli-hello-world-lazy",
)
+1 -1
View File
@@ -2,6 +2,6 @@ load("//integration:index.bzl", "ng_integration_test")
ng_integration_test(
name = "test",
commands = "payload_size_tracking",
setup_chromium = True,
track_payload_size = "cli-hello-world",
)
+1 -1
View File
@@ -2,6 +2,6 @@ load("//integration:index.bzl", "ng_integration_test")
ng_integration_test(
name = "test",
commands = "payload_size_tracking",
setup_chromium = True,
track_payload_size = "forms",
)
+2 -2
View File
@@ -2,10 +2,10 @@ load("//integration:index.bzl", "ng_integration_test")
ng_integration_test(
name = "test",
# TODO: Re-enable the payload_size_tracking command:
# TODO: Re-enable size-tracking:
# We should define ngDevMode to false in Closure, but --define only works in the global scope.
# With ngDevMode not being set to false, this size tracking test provides little value but a lot of
# headache to continue updating the size.
# commands = "payload_size_tracking",
# track_payload_size = "hello_world_closure",
setup_chromium = True,
)
+5 -6
View File
@@ -38,6 +38,7 @@ def _ng_integration_test(name, setup_chromium = False, **kwargs):
use_view_engine_packages = kwargs.pop("use_view_engine_packages", [])
toolchains = kwargs.pop("toolchains", [])
environment = kwargs.pop("environment", {})
track_payload_size = kwargs.pop("track_payload_size", None)
data = kwargs.pop("data", [])
data += [
@@ -56,18 +57,16 @@ def _ng_integration_test(name, setup_chromium = False, **kwargs):
# By default run `yarn install` followed by `yarn test` using the tools linked
# into the integration tests (using the `tool_mappings` attribute).
commands = [
commands = kwargs.pop("commands", [
"yarn install --cache-folder ./.yarn_local_cache",
"yarn test",
]
])
command_type = kwargs.pop("commands", "default")
if command_type == "payload_size_tracking":
if track_payload_size:
commands += [
"yarn build",
# TODO: Replace the track payload-size script with a RBE and Windows-compatible script.
"$(rootpath //:scripts/ci/track-payload-size.sh) %s dist/*.js true $${RUNFILES}/angular/$(rootpath //goldens:size-tracking/integration-payloads.json)" % name,
"$(rootpath //:scripts/ci/track-payload-size.sh) %s 'dist/*.js' true $${RUNFILES}/angular/$(rootpath //goldens:size-tracking/integration-payloads.json)" % track_payload_size,
]
data += [
"//goldens:size-tracking/integration-payloads.json",
+19 -19
View File
@@ -1,6 +1,6 @@
{
"name": "angular-srcs",
"version": "13.1.0-next.3",
"version": "13.1.1",
"private": true,
"description": "Angular - a web framework for modern web apps",
"homepage": "https://github.com/angular/angular",
@@ -38,12 +38,12 @@
},
"// 1": "dependencies are used locally and by bazel",
"dependencies": {
"@angular-devkit/build-angular": "13.0.3",
"@angular-devkit/build-optimizer": "0.1300.3",
"@angular-devkit/core": "13.0.3",
"@angular-devkit/schematics": "13.0.3",
"@angular-devkit/build-angular": "13.0.4",
"@angular-devkit/build-optimizer": "0.1300.4",
"@angular-devkit/core": "13.0.4",
"@angular-devkit/schematics": "13.0.4",
"@angular/animations-12": "npm:@angular/animations@12.2.13",
"@angular/cli": "13.0.3",
"@angular/cli": "13.0.4",
"@angular/common-12": "npm:@angular/common@12.2.13",
"@angular/core-12": "npm:@angular/core@12.2.13",
"@angular/forms-12": "npm:@angular/forms@12.2.13",
@@ -58,19 +58,19 @@
"@babel/preset-env": "7.10.2",
"@babel/template": "7.8.6",
"@babel/traverse": "7.8.6",
"@bazel/concatjs": "4.4.2",
"@bazel/esbuild": "4.4.2",
"@bazel/jasmine": "4.4.2",
"@bazel/protractor": "4.4.2",
"@bazel/rollup": "4.4.2",
"@bazel/runfiles": "4.4.2",
"@bazel/terser": "4.4.2",
"@bazel/typescript": "4.4.2",
"@microsoft/api-extractor": "7.18.19",
"@bazel/concatjs": "4.4.6",
"@bazel/esbuild": "4.4.6",
"@bazel/jasmine": "4.4.6",
"@bazel/protractor": "4.4.6",
"@bazel/rollup": "4.4.6",
"@bazel/runfiles": "4.4.6",
"@bazel/terser": "4.4.6",
"@bazel/typescript": "4.4.6",
"@microsoft/api-extractor": "7.19.2",
"@rollup/plugin-babel": "^5.3.0",
"@rollup/plugin-commonjs": "^21.0.0",
"@rollup/plugin-node-resolve": "^13.0.4",
"@schematics/angular": "13.0.3",
"@schematics/angular": "13.0.4",
"@types/angular": "^1.6.47",
"@types/babel__core": "7.1.6",
"@types/babel__generator": "7.6.1",
@@ -114,7 +114,7 @@
"dependency-graph": "^0.11.0",
"diff": "^5.0.0",
"domino": "~2.1.6",
"google-closure-compiler": "20211006.0.0",
"google-closure-compiler": "20211201.0.0",
"graceful-fs": "4.2.8",
"hammerjs": "~2.0.8",
"http-server": "^14.0.0",
@@ -137,7 +137,7 @@
"puppeteer": "10.2.0",
"reflect-metadata": "^0.1.3",
"requirejs": "^2.3.6",
"rollup": "~2.59.0",
"rollup": "~2.61.0",
"rollup-plugin-preserve-shebang": "^1.0.1",
"rollup-plugin-sourcemaps": "^0.6.3",
"rxjs": "^6.6.7",
@@ -158,7 +158,7 @@
},
"// 2": "devDependencies are not used under Bazel. Many can be removed after test.sh is deleted.",
"devDependencies": {
"@angular/dev-infra-private": "https://github.com/angular/dev-infra-private-builds.git#74fb4de008fde297fb83393ff076de10532f82a9",
"@angular/dev-infra-private": "https://github.com/angular/dev-infra-private-builds.git#e4a13cfd135ec766dc9148ba4fe4d3ac76d94137",
"@bazel/bazelisk": "^1.7.5",
"@bazel/buildifier": "^4.0.1",
"@bazel/ibazel": "^0.15.8",
@@ -9,7 +9,7 @@ import {AnimateTimings, AnimationAnimateChildMetadata, AnimationAnimateMetadata,
import {AnimationDriver} from '../render/animation_driver';
import {getOrSetAsInMap} from '../render/shared';
import {copyObj, ENTER_SELECTOR, extractStyleParams, iteratorToArray, LEAVE_SELECTOR, NG_ANIMATING_SELECTOR, NG_TRIGGER_SELECTOR, normalizeAnimationEntry, resolveTiming, SUBSTITUTION_EXPR_START, validateStyleParams, visitDslNode} from '../util';
import {copyObj, extractStyleParams, iteratorToArray, NG_ANIMATING_SELECTOR, NG_TRIGGER_SELECTOR, normalizeAnimationEntry, resolveTiming, SUBSTITUTION_EXPR_START, validateStyleParams, visitDslNode} from '../util';
import {AnimateAst, AnimateChildAst, AnimateRefAst, Ast, DynamicTimingAst, GroupAst, KeyframesAst, QueryAst, ReferenceAst, SequenceAst, StaggerAst, StateAst, StyleAst, TimingAst, TransitionAst, TriggerAst} from './animation_ast';
import {AnimationDslVisitor} from './animation_dsl_visitor';
@@ -154,7 +154,7 @@ export class AnimationTimelineBuilderVisitor implements AstVisitor {
}
visitAnimateChild(ast: AnimateChildAst, context: AnimationTimelineContext): any {
const elementInstructions = context.subInstructions.consume(context.element);
const elementInstructions = context.subInstructions.get(context.element);
if (elementInstructions) {
const innerContext = context.createSubContext(ast.options);
const startTime = context.currentTimeline.currentTime;
@@ -10,14 +10,8 @@ import {AnimationTimelineInstruction} from './animation_timeline_instruction';
export class ElementInstructionMap {
private _map = new Map<any, AnimationTimelineInstruction[]>();
consume(element: any): AnimationTimelineInstruction[] {
let instructions = this._map.get(element);
if (instructions) {
this._map.delete(element);
} else {
instructions = [];
}
return instructions;
get(element: any): AnimationTimelineInstruction[] {
return this._map.get(element) || [];
}
append(element: any, instructions: AnimationTimelineInstruction[]) {
@@ -1034,7 +1034,14 @@ export class TransitionAnimationEngine {
// instead stretch the first keyframe gap until the animation starts. This is
// important in order to prevent extra initialization styles from being
// required by the user for the animation.
instruction.timelines.forEach(tl => tl.stretchStartingKeyframe = true);
const timelines: AnimationTimelineInstruction[] = [];
instruction.timelines.forEach(tl => {
tl.stretchStartingKeyframe = true;
if (!this.disabledNodes.has(tl.element)) {
timelines.push(tl);
}
});
instruction.timelines = timelines;
subTimelines.append(element, instruction.timelines);
@@ -22,8 +22,7 @@ export class WebAnimationsPlayer implements AnimationPlayer {
private _finished = false;
private _started = false;
private _destroyed = false;
// TODO(issue/24571): remove '!'.
private _finalKeyframe!: {[key: string]: string|number};
private _finalKeyframe?: {[key: string]: string|number};
// TODO(issue/24571): remove '!'.
public readonly domPlayer!: DOMAnimation;
@@ -173,10 +172,13 @@ export class WebAnimationsPlayer implements AnimationPlayer {
beforeDestroy() {
const styles: {[key: string]: string|number} = {};
if (this.hasStarted()) {
Object.keys(this._finalKeyframe).forEach(prop => {
// note: this code is invoked only when the `play` function was called prior to this
// (thus `hasStarted` returns true), this implies that the code that initializes
// `_finalKeyframe` has also been executed and the non-null assertion can be safely used here
const finalKeyframe = this._finalKeyframe!;
Object.keys(finalKeyframe).forEach(prop => {
if (prop != 'offset') {
styles[prop] =
this._finished ? this._finalKeyframe[prop] : computeStyle(this.element, prop);
styles[prop] = this._finished ? finalKeyframe[prop] : computeStyle(this.element, prop);
}
});
}
+1 -2
View File
@@ -6,6 +6,7 @@
* found in the LICENSE file at https://angular.io/license
*/
import {AnimateTimings, AnimationMetadata, AnimationMetadataType, AnimationOptions, sequence, ɵStyleData} from '@angular/animations';
import {Ast as AnimationAst, AstVisitor as AnimationAstVisitor} from './dsl/animation_ast';
import {AnimationDslVisitor} from './dsl/animation_dsl_visitor';
import {isNode} from './render/shared';
@@ -16,8 +17,6 @@ export const SUBSTITUTION_EXPR_START = '{{';
export const SUBSTITUTION_EXPR_END = '}}';
export const ENTER_CLASSNAME = 'ng-enter';
export const LEAVE_CLASSNAME = 'ng-leave';
export const ENTER_SELECTOR = '.ng-enter';
export const LEAVE_SELECTOR = '.ng-leave';
export const NG_TRIGGER_CLASSNAME = 'ng-trigger';
export const NG_TRIGGER_SELECTOR = '.ng-trigger';
export const NG_ANIMATING_CLASSNAME = 'ng-animating';
+111 -133
View File
@@ -871,170 +871,148 @@ export function keyframes(steps: AnimationStyleMetadata[]): AnimationKeyframesSe
}
/**
* Declares an animation transition as a sequence of animation steps to run when a given
* condition is satisfied. The condition is a Boolean expression or function that compares
* the previous and current animation states, and returns true if this transition should occur.
* When the state criteria of a defined transition are met, the associated animation is
* triggered.
* Declares an animation transition which is played when a certain specified condition is met.
*
* @param stateChangeExpr A Boolean expression or function that compares the previous and current
* animation states, and returns true if this transition should occur. Note that "true" and "false"
* match 1 and 0, respectively. An expression is evaluated each time a state change occurs in the
* animation trigger element.
* The animation steps run when the expression evaluates to true.
* @param stateChangeExpr A string with a specific format or a function that specifies when the
* animation transition should occur (see [State Change Expression](#state-change-expression)).
*
* - A state-change string takes the form "state1 => state2", where each side is a defined animation
* state, or an asterisk (*) to refer to a dynamic start or end state.
* - The expression string can contain multiple comma-separated statements;
* for example "state1 => state2, state3 => state4".
* - Special values `:enter` and `:leave` initiate a transition on the entry and exit states,
* equivalent to "void => *" and "* => void".
* - Special values `:increment` and `:decrement` initiate a transition when a numeric value has
* increased or decreased in value.
* - A function is executed each time a state change occurs in the animation trigger element.
* The animation steps run when the function returns true.
* @param steps One or more animation objects that represent the animation's instructions.
*
* @param options An options object that can be used to specify a delay for the animation or provide
* custom parameters for it.
*
* @param steps One or more animation objects, as returned by the `animate()` or
* `sequence()` function, that form a transformation from one state to another.
* A sequence is used by default when you pass an array.
* @param options An options object that can contain a delay value for the start of the animation,
* and additional developer-defined parameters. Provided values for additional parameters are used
* as defaults, and override values can be passed to the caller on invocation.
* @returns An object that encapsulates the transition data.
*
* @usageNotes
* The template associated with a component binds an animation trigger to an element.
*
* ```HTML
* <!-- somewhere inside of my-component-tpl.html -->
* <div [@myAnimationTrigger]="myStatusExp">...</div>
* ```
* ### State Change Expression
*
* All transitions are defined within an animation trigger,
* along with named states that the transitions change to and from.
* The State Change Expression instructs Angular when to run the transition's animations, it can
*either be
* - a string with a specific syntax
* - or a function that compares the previous and current state (value of the expression bound to
* the element's trigger) and returns `true` if the transition should occur or `false` otherwise
*
* ```typescript
* trigger("myAnimationTrigger", [
* // define states
* state("on", style({ background: "green" })),
* state("off", style({ background: "grey" })),
* ...]
* ```
* The string format can be:
* - `fromState => toState`, which indicates that the transition's animations should occur then the
* expression bound to the trigger's element goes from `fromState` to `toState`
*
* Note that when you call the `sequence()` function within a `{@link animations/group group()}`
* or a `transition()` call, execution does not continue to the next instruction
* until each of the inner animation steps have completed.
* _Example:_
* ```typescript
* transition('open => closed', animate('.5s ease-out', style({ height: 0 }) ))
* ```
*
* ### Syntax examples
* - `fromState <=> toState`, which indicates that the transition's animations should occur then
* the expression bound to the trigger's element goes from `fromState` to `toState` or vice versa
*
* The following examples define transitions between the two defined states (and default states),
* using various options:
* _Example:_
* ```typescript
* transition('enabled <=> disabled', animate('1s cubic-bezier(0.8,0.3,0,1)'))
* ```
*
* ```typescript
* // Transition occurs when the state value
* // bound to "myAnimationTrigger" changes from "on" to "off"
* transition("on => off", animate(500))
* // Run the same animation for both directions
* transition("on <=> off", animate(500))
* // Define multiple state-change pairs separated by commas
* transition("on => off, off => void", animate(500))
* ```
* - `:enter`/`:leave`, which indicates that the transition's animations should occur when the
* element enters or exists the DOM
*
* ### Special values for state-change expressions
* _Example:_
* ```typescript
* transition(':enter', [
* style({ opacity: 0 }),
* animate('500ms', style({ opacity: 1 }))
* ])
* ```
*
* - Catch-all state change for when an element is inserted into the page and the
* destination state is unknown:
* - `:increment`/`:decrement`, which indicates that the transition's animations should occur when
* the numerical expression bound to the trigger's element has increased in value or decreased
*
* ```typescript
* transition("void => *", [
* style({ opacity: 0 }),
* animate(500)
* ])
* ```
* _Example:_
* ```typescript
* transition(':increment', query('@counter', animateChild()))
* ```
*
* - Capture a state change between any states:
* - a sequence of any of the above divided by commas, which indicates that transition's animations
* should occur whenever one of the state change expressions matches
*
* `transition("* => *", animate("1s 0s"))`
* _Example:_
* ```typescript
* transition(':increment, * => enabled, :enter', animate('1s ease', keyframes([
* style({ transform: 'scale(1)', offset: 0}),
* style({ transform: 'scale(1.1)', offset: 0.7}),
* style({ transform: 'scale(1)', offset: 1})
* ]))),
* ```
*
* - Entry and exit transitions:
* Also note that in such context:
* - `void` can be used to indicate the absence of the element
* - asterisks can be used as wildcards that match any state
* - (as a consequence of the above, `void => *` is equivalent to `:enter` and `* => void` is
* equivalent to `:leave`)
* - `true` and `false` also match expression values of `1` and `0` respectively (but do not match
* _truthy_ and _falsy_ values)
*
* ```typescript
* transition(":enter", [
* style({ opacity: 0 }),
* animate(500, style({ opacity: 1 }))
* ]),
* transition(":leave", [
* animate(500, style({ opacity: 0 }))
* ])
* ```
* <div class="alert is-helpful">
*
* - Use `:increment` and `:decrement` to initiate transitions:
* Be careful about entering end leaving elements as their transitions present a common
* pitfall for developers.
*
* ```typescript
* transition(":increment", group([
* query(':enter', [
* style({ left: '100%' }),
* animate('0.5s ease-out', style('*'))
* ]),
* query(':leave', [
* animate('0.5s ease-out', style({ left: '-100%' }))
* ])
* ]))
* Note that when an element with a trigger enters the DOM its `:enter` transition always
* gets executed, but its `:leave` transition will not be executed if the element is removed
* alongside its parent (as it will be removed "without warning" before its transition has
* a chance to be executed, the only way that such transition can occur is if the element
* is exiting the DOM on its own).
*
* transition(":decrement", group([
* query(':enter', [
* style({ left: '100%' }),
* animate('0.5s ease-out', style('*'))
* ]),
* query(':leave', [
* animate('0.5s ease-out', style({ left: '-100%' }))
* ])
* ]))
* ```
*
* ### State-change functions
* </div>
*
* Here is an example of a `fromState` specified as a state-change function that invokes an
* animation when true:
*
* ```typescript
* transition((fromState, toState) =>
* {
* return fromState == "off" && toState == "on";
* },
* animate("1s 0s"))
* ```
*
* ### Animating to the final state
* ### Animating to a Final State
*
* If the final step in a transition is a call to `animate()` that uses a timing value
* with no style data, that step is automatically considered the final animation arc,
* for the element to reach the final state. Angular automatically adds or removes
* with no `style` data, that step is automatically considered the final animation arc,
* for the element to reach the final state, in such case Angular automatically adds or removes
* CSS styles to ensure that the element is in the correct final state.
*
* The following example defines a transition that starts by hiding the element,
* then makes sure that it animates properly to whatever state is currently active for trigger:
*
* ```typescript
* transition("void => *", [
* style({ opacity: 0 }),
* animate(500)
* ])
* ```
* ### Boolean value matching
* If a trigger binding value is a Boolean, it can be matched using a transition expression
* that compares true and false or 1 and 0. For example:
* ### Usage Examples
*
* ```
* // in the template
* <div [@openClose]="open ? true : false">...</div>
* // in the component metadata
* trigger('openClose', [
* state('true', style({ height: '*' })),
* state('false', style({ height: '0px' })),
* transition('false <=> true', animate(500))
* ])
* ```
* - Transition animations applied based on
* the trigger's expression value
*
* ```HTML
* <div [@myAnimationTrigger]="myStatusExp">
* ...
* </div>
* ```
*
* ```typescript
* trigger("myAnimationTrigger", [
* ..., // states
* transition("on => off, open => closed", animate(500)),
* transition("* <=> error", query('.indicator', animateChild()))
* ])
* ```
*
* - Transition animations applied based on custom logic dependent
* on the trigger's expression value and provided parameters
*
* ```HTML
* <div [@myAnimationTrigger]="{
* value: stepName,
* params: { target: currentTarget }
* }">
* ...
* </div>
* ```
*
* ```typescript
* trigger("myAnimationTrigger", [
* ..., // states
* transition(
* (fromState, toState, _element, params) =>
* ['firststep', 'laststep'].includes(fromState.toLowerCase())
* && toState === params?.['target'],
* animate('1s')
* )
* ])
* ```
*
* @publicApi
**/
+1 -1
View File
@@ -22,7 +22,7 @@
}
},
"dependencies": {
"@microsoft/api-extractor": "7.18.19",
"@microsoft/api-extractor": "7.19.2",
"shelljs": "0.8.4",
"tsickle": "^0.38.0",
"tslib": "^2.3.0"
File diff suppressed because it is too large Load Diff
@@ -6,224 +6,10 @@
* found in the LICENSE file at https://angular.io/license
*/
import ts from 'typescript';
import {AbsoluteFsPath, FileSystem, getFileSystem} from '../../../src/ngtsc/file_system';
import {AbsoluteFsPath} from '../../../src/ngtsc/file_system';
import {Folder, MockFileSystemPosix} from '../../../src/ngtsc/file_system/testing';
import {loadTestDirectory, loadTsLib, resolveNpmTreeArtifact} from '../../../src/ngtsc/testing';
export type PackageSources = {
[path: string]: string;
};
/**
* Instead of writing packaged code by hand, and manually describing the layout of the package, this
* function transpiles the TypeScript sources into a flat file structure using the ES5 format. In
* this package layout, all compiled sources are at the root of the package, with `.d.ts` files next
* to the `.js` files. Each `.js` also has a corresponding `.metadata.json` file alongside with it.
*
* All generated code is written into the `node_modules` in the top-level filesystem, ready for use
* in testing ngcc.
*
* @param pkgName The name of the package to compile.
* @param sources The TypeScript sources to compile.
*/
export function compileIntoFlatEs5Package(pkgName: string, sources: PackageSources): void {
compileIntoFlatPackage(pkgName, sources, {
target: ts.ScriptTarget.ES5,
module: ts.ModuleKind.ESNext,
formatProperty: 'esm5',
});
}
/**
* Instead of writing packaged code by hand, and manually describing the layout of the package,
* this function transpiles the TypeScript sources into a flat file structure using the ES2015
* format. In this package layout, all compiled sources are at the root of the package, with
* `.d.ts` files next to the `.js` files. Each `.js` also has a corresponding `.metadata.json`
* file alongside with it.
*
* All generated code is written into the `node_modules` in the top-level filesystem, ready for use
* in testing ngcc.
*
* @param pkgName The name of the package to compile.
* @param sources The TypeScript sources to compile.
*/
export function compileIntoFlatEs2015Package(pkgName: string, sources: PackageSources): void {
compileIntoFlatPackage(pkgName, sources, {
target: ts.ScriptTarget.ES2015,
module: ts.ModuleKind.ESNext,
formatProperty: 'esm2015',
});
}
export interface FlatLayoutOptions {
/**
* The script target version to compile into.
*/
target: ts.ScriptTarget;
/**
* The module kind to use in the compiled result.
*/
module: ts.ModuleKind;
/**
* The name of the property in package.json that refers to the root source file.
*/
formatProperty: string;
}
/**
* Instead of writing packaged code by hand, and manually describing the layout of the package, this
* function transpiles the TypeScript sources into a flat file structure using a single format. In
* this package layout, all compiled sources are at the root of the package, with `.d.ts` files next
* to the `.js` files. Each `.js` also has a corresponding `.metadata.json` file alongside with it.
*
* All generated code is written into the `node_modules` in the top-level filesystem, ready for use
* in testing ngcc.
*
* @param pkgName The name of the package to compile.
* @param sources The TypeScript sources to compile.
* @param options Allows for configuration of how the sources are compiled.
*/
function compileIntoFlatPackage(
pkgName: string, sources: PackageSources, options: FlatLayoutOptions): void {
const fs = getFileSystem();
const {rootNames, compileFs} = setupCompileFs(sources);
const emit = (options: ts.CompilerOptions) => {
const host = new MockCompilerHost(compileFs);
const program = ts.createProgram({host, rootNames, options});
program.emit();
};
emit({
declaration: true,
emitDecoratorMetadata: true,
moduleResolution: ts.ModuleResolutionKind.NodeJs,
module: options.module,
target: options.target,
lib: [],
});
// Copy over the JS and .d.ts files, and add a .metadata.json for each .d.ts file.
for (const file of rootNames) {
const inFileBase = file.replace(/\.ts$/, '');
const dtsContents = compileFs.readFile(compileFs.resolve(`/${inFileBase}.d.ts`));
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/${inFileBase}.d.ts`), dtsContents);
const jsContents = compileFs.readFile(compileFs.resolve(`/${inFileBase}.js`));
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/${inFileBase}.js`), jsContents);
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/${inFileBase}.metadata.json`), '{}');
}
// Write the package.json
const pkgJson: unknown = {
name: pkgName,
version: '0.0.1',
[options.formatProperty]: './index.js',
typings: './index.d.ts',
};
fs.writeFile(
fs.resolve(`/node_modules/${pkgName}/package.json`), JSON.stringify(pkgJson, null, 2));
}
/**
* Instead of writing packaged code by hand, and manually describing the layout of the package, this
* function transpiles the TypeScript sources into a package layout that of Angular Package Format.
* Both esm2015 and esm5 bundles are present in this layout. The .d.ts files reside in the /src
* directory and a public .d.ts file is present in the root, re-exporting /src/index.ts.
*
* Flat modules (fesm2015 and fesm5) and UMD bundles are not generated like they ought to be in APF.
*
* All generated code is written into the `node_modules` in the top-level filesystem, ready for use
* in testing ngcc.
*/
export function compileIntoApf(
pkgName: string, sources: PackageSources, extraCompilerOptions: ts.CompilerOptions = {}): void {
const fs = getFileSystem();
const {rootNames, compileFs} = setupCompileFs(sources);
const emit = (options: ts.CompilerOptions) => {
const host = new MockCompilerHost(compileFs);
const program =
ts.createProgram({host, rootNames, options: {...extraCompilerOptions, ...options}});
program.emit();
};
// Compile esm2015 into /esm2015
compileFs.ensureDir(compileFs.resolve('esm2015'));
emit({
declaration: true,
emitDecoratorMetadata: true,
outDir: './esm2015',
moduleResolution: ts.ModuleResolutionKind.NodeJs,
module: ts.ModuleKind.ESNext,
target: ts.ScriptTarget.ES2015,
lib: [],
});
fs.ensureDir(fs.resolve(`/node_modules/${pkgName}/src`));
fs.ensureDir(fs.resolve(`/node_modules/${pkgName}/esm2015/src`));
for (const file of rootNames) {
const inFileBase = file.replace(/\.ts$/, '');
// Copy declaration file into /src tree
const dtsContents = compileFs.readFile(compileFs.resolve(`/esm2015/${inFileBase}.d.ts`));
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/src/${inFileBase}.d.ts`), dtsContents);
// Copy compiled source file into /esm2015/src tree
const jsContents = compileFs.readFile(compileFs.resolve(`/esm2015/${inFileBase}.js`));
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/esm2015/src/${inFileBase}.js`), jsContents);
}
fs.writeFile(
fs.resolve(`/node_modules/${pkgName}/esm2015/index.js`), `export * from './src/index';`);
// Compile esm5 into /esm5
compileFs.ensureDir(compileFs.resolve('esm5'));
emit({
declaration: false,
emitDecoratorMetadata: true,
outDir: './esm5',
moduleResolution: ts.ModuleResolutionKind.NodeJs,
module: ts.ModuleKind.ESNext,
target: ts.ScriptTarget.ES5,
lib: [],
});
fs.ensureDir(fs.resolve(`/node_modules/${pkgName}/esm5/src`));
for (const file of rootNames) {
const inFileBase = file.replace(/\.ts$/, '');
// Copy compiled source file into esm5/src tree
const jsContents = compileFs.readFile(compileFs.resolve(`/esm5/${inFileBase}.js`));
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/esm5/src/${inFileBase}.js`), jsContents);
}
fs.writeFile(
fs.resolve(`/node_modules/${pkgName}/esm5/index.js`), `export * from './src/index';`);
// Write a main declaration and metadata file to the root
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/index.d.ts`), `export * from './src/index';`);
fs.writeFile(fs.resolve(`/node_modules/${pkgName}/index.metadata.json`), '{}');
// Write the package.json
const pkgJson: unknown = {
name: pkgName,
version: '0.0.1',
esm5: './esm5/index.js',
esm2015: './esm2015/index.js',
module: './esm2015/index.js',
typings: './index.d.ts',
};
fs.writeFile(
fs.resolve(`/node_modules/${pkgName}/package.json`), JSON.stringify(pkgJson, null, 2));
}
export function loadNgccIntegrationTestFiles(): Folder {
const tmpFs = new MockFileSystemPosix(true);
const basePath = '/' as AbsoluteFsPath;
@@ -240,68 +26,3 @@ export function loadNgccIntegrationTestFiles(): Folder {
loadTestDirectory(tmpFs, resolveNpmTreeArtifact('rxjs'), tmpFs.resolve('/node_modules/rxjs'));
return tmpFs.dump();
}
const stdFiles = loadNgccIntegrationTestFiles();
/**
* Prepares a mock filesystem that contains all provided source files, which can be used to emit
* compiled code into.
*/
function setupCompileFs(sources: PackageSources): {rootNames: string[], compileFs: FileSystem} {
const compileFs = new MockFileSystemPosix(true);
compileFs.init(stdFiles);
const rootNames = Object.keys(sources);
for (const fileName of rootNames) {
compileFs.writeFile(compileFs.resolve(fileName), sources[fileName]);
}
return {rootNames, compileFs};
}
/**
* A simple `ts.CompilerHost` that uses a `FileSystem` instead of the real FS.
*
* TODO(alxhub): convert this into a first class `FileSystemCompilerHost` and use it as the base for
* the entire compiler.
*/
class MockCompilerHost implements ts.CompilerHost {
constructor(private fs: FileSystem) {}
getSourceFile(
fileName: string, languageVersion: ts.ScriptTarget,
onError?: ((message: string) => void)|undefined,
shouldCreateNewSourceFile?: boolean|undefined): ts.SourceFile|undefined {
return ts.createSourceFile(
fileName, this.fs.readFile(this.fs.resolve(fileName)), languageVersion, true,
ts.ScriptKind.TS);
}
getDefaultLibFileName(options: ts.CompilerOptions): string {
return ts.getDefaultLibFileName(options);
}
writeFile(fileName: string, data: string): void {
this.fs.writeFile(this.fs.resolve(fileName), data);
}
getCurrentDirectory(): string {
return this.fs.pwd();
}
getCanonicalFileName(fileName: string): string {
return fileName;
}
useCaseSensitiveFileNames(): boolean {
return true;
}
getNewLine(): string {
return '\n';
}
fileExists(fileName: string): boolean {
return this.fs.exists(this.fs.resolve(fileName));
}
readFile(fileName: string): string|undefined {
const abs = this.fs.resolve(fileName);
return this.fs.exists(abs) ? this.fs.readFile(abs) : undefined;
}
}
@@ -67,10 +67,7 @@ export class DelegatingCompilerHost implements
trace = this.delegateMethod('trace');
useCaseSensitiveFileNames = this.delegateMethod('useCaseSensitiveFileNames');
writeFile = this.delegateMethod('writeFile');
// TODO(crisbeto): the cast to `any` is here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
getModuleResolutionCache = this.delegateMethod('getModuleResolutionCache' as any);
getModuleResolutionCache = this.delegateMethod('getModuleResolutionCache');
}
/**
@@ -126,9 +126,7 @@ function isTypeOnlyImportClause(node: ts.ImportClause): boolean {
// All the specifiers in the cause are type-only (e.g. `import {type a, type b} from '...'`).
if (node.namedBindings !== undefined && ts.isNamedImports(node.namedBindings) &&
// TODO(crisbeto): the cast to `any` is here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
node.namedBindings.elements.every(specifier => (specifier as any).isTypeOnly)) {
node.namedBindings.elements.every(specifier => specifier.isTypeOnly)) {
return true;
}
@@ -51,10 +51,7 @@ export class DelegatingCompilerHost implements
resolveTypeReferenceDirectives = this.delegateMethod('resolveTypeReferenceDirectives');
trace = this.delegateMethod('trace');
useCaseSensitiveFileNames = this.delegateMethod('useCaseSensitiveFileNames');
// TODO(crisbeto): the cast to `any` is here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
getModuleResolutionCache = this.delegateMethod('getModuleResolutionCache' as any);
getModuleResolutionCache = this.delegateMethod('getModuleResolutionCache');
}
/**
@@ -72,9 +72,7 @@ export function typeToValue(
// or
// import {Foo as Bar} from 'foo';
// TODO(crisbeto): the cast to `any` is here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
if ((firstDecl as any).isTypeOnly) {
if (firstDecl.isTypeOnly) {
// The import specifier can't be type-only (e.g. `import {type Foo} from '...')`.
return typeOnlyImport(typeNode, firstDecl);
}
@@ -237,8 +237,6 @@ export class AdapterResourceLoader implements ResourceLoader {
*/
function createLookupResolutionHost(adapter: NgCompilerAdapter):
RequiredDelegations<ts.ModuleResolutionHost> {
// TODO(crisbeto): the cast to `any` is here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
return {
directoryExists(directoryName: string): boolean {
if (directoryName.includes(RESOURCE_MARKER)) {
@@ -263,8 +261,8 @@ function createLookupResolutionHost(adapter: NgCompilerAdapter):
getDirectories: adapter.getDirectories?.bind(adapter),
realpath: adapter.realpath?.bind(adapter),
trace: adapter.trace?.bind(adapter),
useCaseSensitiveFileNames: typeof (adapter as any).useCaseSensitiveFileNames === 'function' ?
(adapter as any).useCaseSensitiveFileNames.bind(adapter) :
(adapter as any).useCaseSensitiveFileNames
} as any;
useCaseSensitiveFileNames: typeof adapter.useCaseSensitiveFileNames === 'function' ?
adapter.useCaseSensitiveFileNames.bind(adapter) :
adapter.useCaseSensitiveFileNames
};
}
@@ -159,9 +159,7 @@ function transformFactorySourceFile(
const rewrittenModuleSpecifier =
importRewriter.rewriteSpecifier('@angular/core', sourceFilePath);
if (rewrittenModuleSpecifier !== stmt.moduleSpecifier.text) {
// TODO(crisbeto): the cast to `any` is here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
transformedStatements.push((ts.updateImportDeclaration as any)(
transformedStatements.push(ts.updateImportDeclaration(
stmt, stmt.decorators, stmt.modifiers, stmt.importClause,
ts.createStringLiteral(rewrittenModuleSpecifier), undefined));
@@ -213,28 +213,8 @@ export function toUnredirectedSourceFile(sf: ts.SourceFile): ts.SourceFile {
export function createExportSpecifier(
propertyName: string|ts.Identifier|undefined, name: string|ts.Identifier,
isTypeOnly = false): ts.ExportSpecifier {
return PARSED_TS_VERSION > 4.4 ?
// TODO(crisbeto): the function is cast to `any` here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
(ts.createExportSpecifier as any)(isTypeOnly, propertyName, name) :
// TODO(crisbeto): backwards-compatibility layer for TS 4.4.
// Should be cleaned up when we drop support for it.
(ts.createExportSpecifier as any)(propertyName, name);
}
/**
* Backwards-compatible version of `ts.createImportSpecifier`
* to handle a breaking change between 4.4 and 4.5.
*/
export function createImportSpecifier(
propertyName: string|ts.Identifier|undefined, name: string|ts.Identifier,
isTypeOnly = false): ts.ImportSpecifier {
return PARSED_TS_VERSION > 4.4 ?
// TODO(crisbeto): the function is cast to `any` here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
(ts.createImportSpecifier as any)(isTypeOnly, propertyName, name) :
// TODO(crisbeto): backwards-compatibility layer for TS 4.4.
// Should be cleaned up when we drop support for it.
(ts.createImportSpecifier as any)(propertyName, name);
return PARSED_TS_VERSION > 4.4 ? ts.createExportSpecifier(isTypeOnly, propertyName, name) :
// TODO(crisbeto): backwards-compatibility layer for TS 4.4.
// Should be cleaned up when we drop support for it.
(ts.createExportSpecifier as any)(propertyName, name);
}
@@ -265,14 +265,11 @@ export class ImportManager {
* Backwards-compatible version of `ts.createImportSpecifier`
* to handle a breaking change between 4.4 and 4.5.
*/
export function createImportSpecifier(
propertyName: string|ts.Identifier|undefined, name: string|ts.Identifier,
function createImportSpecifier(
propertyName: ts.Identifier|undefined, name: ts.Identifier,
isTypeOnly = false): ts.ImportSpecifier {
return PARSED_TS_VERSION > 4.4 ?
// TODO(crisbeto): the function is cast to `any` here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
(ts.createImportSpecifier as any)(isTypeOnly, propertyName, name) :
// TODO(crisbeto): backwards-compatibility layer for TS 4.4.
// Should be cleaned up when we drop support for it.
(ts.createImportSpecifier as any)(propertyName, name);
return PARSED_TS_VERSION > 4.4 ? ts.createImportSpecifier(isTypeOnly, propertyName, name) :
// TODO(crisbeto): backwards-compatibility layer for TS 4.4.
// Should be cleaned up when we drop support for it.
(ts.createImportSpecifier as any)(propertyName, name);
}
@@ -108,13 +108,10 @@ export function replaceImport(
return ts.updateNamedImports(node, [
...node.elements.filter(current => current !== existingImportNode),
// Create a new import while trying to preserve the alias of the old one.
PARSED_TS_VERSION > 4.4 ?
// TODO(crisbeto): the function is cast to `any` here since g3 is still on TS 4.4.
// Should be cleaned up when g3 has been updated.
(ts.createImportSpecifier as any)(false, importPropertyName, importName) :
// TODO(crisbeto): backwards-compatibility layer for TS 4.4.
// Should be cleaned up when we drop support for it.
(ts.createImportSpecifier as any)(importPropertyName, importName)
PARSED_TS_VERSION > 4.4 ? ts.createImportSpecifier(false, importPropertyName, importName) :
// TODO(crisbeto): backwards-compatibility layer for TS 4.4.
// Should be cleaned up when we drop support for it.
(ts.createImportSpecifier as any)(importPropertyName, importName)
]);
}
@@ -979,9 +979,9 @@ describe('animation tests', function() {
expect(fixture.nativeElement.children.length).toBe(1);
engine.flush();
expect(getLog().length).toBe(1);
expect(getLog().length).toBe(2);
const player = getLog()[0];
const player = getLog()[1];
expect(player.keyframes).toEqual([
{opacity: '1', offset: 0},
{opacity: '0', offset: 1},
@@ -3007,18 +3007,25 @@ describe('animation tests', function() {
cmp.log = [];
const players = getLog();
expect(players.length).toEqual(3);
const [p1, p2, p3] = players;
expect(players.length).toEqual(4);
p1.finish();
// players:
// - _scp (skipped child player): player for the child animation
// - pp1 (parent player 1): player for parent animation (from 0px to 100px)
// - pcp (parent child player):
// player for child animation executed by parent via query and animateChild
// - pp2 (parent player 2): player for parent animation (from 100px to 0px)
const [_scp, pp1, pcp, pp2] = players;
pp1.finish();
flushMicrotasks();
expect(cmp.log).toEqual([]);
p2.finish();
pcp.finish();
flushMicrotasks();
expect(cmp.log).toEqual([]);
p3.finish();
pp2.finish();
flushMicrotasks();
expect(cmp.log).toEqual(['parent-done', 'child-done']);
}));
@@ -3080,33 +3087,45 @@ describe('animation tests', function() {
cmp.log = [];
const players = getLog();
// 1 + 4 + 4 = 9 players
expect(players.length).toEqual(9);
expect(players.length).toEqual(13);
const [pA, pq1a, pq1b, pq1c, pq1d, pq2a, pq2b, pq2c, pq2d] = getLog();
pA.finish();
pq1a.finish();
pq1b.finish();
pq1c.finish();
pq1d.finish();
// players:
// - _sc1p, _sc2p, _sc3p, _sc4p (skipped child n (1 to 4) players):
// players for the children animations
// - pp1 (parent player 1): player for parent animation (from opacity 0 to opacity 1)
// - pc1p1, pc2p1, pc3p1, pc4p1 (parent child n (1 to 4) player 1):
// players for children animations executed by parent via query and animate
// (from opacity 0 to opacity 1)
// - pc1p2, pc2p2, pc3p2, pc4p2 (parent child n (1 to 4) player 2):
// players for children animations executed by parent via query and animateChild
const [_sc1p, _sc2p, _sc3p, _sc4p, pp1, pc1p1, pc2p1, pc3p1, pc4p1, pc1p2, pc2p2, pc3p2, pc4p2] =
getLog();
pp1.finish();
pc1p1.finish();
pc2p1.finish();
pc3p1.finish();
pc4p1.finish();
flushMicrotasks();
expect(cmp.log).toEqual([]);
pq2a.finish();
pq2b.finish();
pq2c.finish();
pq2d.finish();
pc1p2.finish();
pc2p2.finish();
pc3p2.finish();
pc4p2.finish();
flushMicrotasks();
expect(cmp.log).toEqual(['all-done', 'c-0-done', 'c-1-done', 'c-2-done', 'c-3-done']);
expect(cmp.events['c-0'].totalTime).toEqual(4100); // 1000 + 1000 + 1800 + 300
expect(cmp.events['all'].totalTime).toEqual(4100); // 1000 + 1000 + 1800 + 300
expect(cmp.events['all'].element.innerText.trim().replaceAll('\n', ' '))
.toEqual('0 1 2 3');
expect(cmp.events['c-0'].totalTime).toEqual(1500);
expect(cmp.events['c-0'].element.innerText.trim()).toEqual('0');
expect(cmp.events['c-1'].totalTime).toEqual(4100);
expect(cmp.events['c-1'].totalTime).toEqual(1500);
expect(cmp.events['c-1'].element.innerText.trim()).toEqual('1');
expect(cmp.events['c-2'].totalTime).toEqual(4100);
expect(cmp.events['c-2'].totalTime).toEqual(1500);
expect(cmp.events['c-2'].element.innerText.trim()).toEqual('2');
expect(cmp.events['c-3'].totalTime).toEqual(4100);
expect(cmp.events['c-3'].totalTime).toEqual(1500);
expect(cmp.events['c-3'].element.innerText.trim()).toEqual('3');
}));
});
@@ -782,8 +782,8 @@ describe('animation query tests', function() {
engine.flush();
const players = getLog();
expect(players.length).toEqual(1);
const player = players[0];
expect(players.length).toEqual(2);
const player = players[1];
expect(player.keyframes).toEqual([{height: '0px', offset: 0}, {height: '444px', offset: 1}]);
player.finish();
@@ -1868,16 +1868,23 @@ describe('animation query tests', function() {
const elm1 = cmp.elm1;
const elm2 = cmp.elm2;
const [p1, p2] = getLog();
expect(p1.delay).toEqual(0);
expect(p1.element).toEqual(elm1.nativeElement);
expect(p1.duration).toEqual(1000);
expect(p1.keyframes).toEqual([{width: '0px', offset: 0}, {width: '100px', offset: 1}]);
const players = getLog();
expect(p2.delay).toEqual(0);
expect(p2.element).toEqual(elm2.nativeElement);
expect(p2.duration).toEqual(2000);
expect(p2.keyframes).toEqual([
// players:
// - _scp (skipped child player): player for the child animation
// - pp (parent player): player for parent animation (from 0px to 100px)
// - pcp (parent child player):
// player for child animation executed by parent via query and animateChild
const [_scp, pp, pcp] = players;
expect(pp.delay).toEqual(0);
expect(pp.element).toEqual(elm1.nativeElement);
expect(pp.duration).toEqual(1000);
expect(pp.keyframes).toEqual([{width: '0px', offset: 0}, {width: '100px', offset: 1}]);
expect(pcp.delay).toEqual(0);
expect(pcp.element).toEqual(elm2.nativeElement);
expect(pcp.duration).toEqual(2000);
expect(pcp.keyframes).toEqual([
{height: '0px', offset: 0}, {height: '0px', offset: .5}, {height: '100px', offset: 1}
]);
});
@@ -1928,36 +1935,45 @@ describe('animation query tests', function() {
const elements = parent.querySelectorAll('.item');
const players = getLog();
expect(players.length).toEqual(7);
const [pA, pc1, pc2, pc3, pc4, pc5, pZ] = players;
expect(players.length).toEqual(12);
expect(pA.element).toEqual(parent);
expect(pA.delay).toEqual(0);
expect(pA.duration).toEqual(1000);
// players:
// - _sc1p, _sc2p, _sc3p, _sc4p (skipped child n (1 to 4) players):
// players for the children animations
// - pp1 (parent player 1): player for parent animation (from opacity 0 to opacity 1)
// - pc1p, pc2p, pc3p, pc4p, pc5p (parent child n (1 to 4) player):
// players for children animations executed by parent via query and animateChild
// - pp2 (parent player 2): player for parent animation (from opacity 1 to opacity 0)
const [_sc1p, _sc2p, _sc3p, _sc4p, _sc5p, pp1, pc1p, pc2p, pc3p, pc4p, pc5p, pp2] =
players;
expect(pc1.element).toEqual(elements[0]);
expect(pc1.delay).toEqual(0);
expect(pc1.duration).toEqual(4000);
expect(pp1.element).toEqual(parent);
expect(pp1.delay).toEqual(0);
expect(pp1.duration).toEqual(1000);
expect(pc2.element).toEqual(elements[1]);
expect(pc2.delay).toEqual(0);
expect(pc2.duration).toEqual(4000);
expect(pc1p.element).toEqual(elements[0]);
expect(pc1p.delay).toEqual(0);
expect(pc1p.duration).toEqual(4000);
expect(pc3.element).toEqual(elements[2]);
expect(pc3.delay).toEqual(0);
expect(pc3.duration).toEqual(4000);
expect(pc2p.element).toEqual(elements[1]);
expect(pc2p.delay).toEqual(0);
expect(pc2p.duration).toEqual(4000);
expect(pc4.element).toEqual(elements[3]);
expect(pc4.delay).toEqual(0);
expect(pc4.duration).toEqual(4000);
expect(pc3p.element).toEqual(elements[2]);
expect(pc3p.delay).toEqual(0);
expect(pc3p.duration).toEqual(4000);
expect(pc5.element).toEqual(elements[4]);
expect(pc5.delay).toEqual(0);
expect(pc5.duration).toEqual(4000);
expect(pc4p.element).toEqual(elements[3]);
expect(pc4p.delay).toEqual(0);
expect(pc4p.duration).toEqual(4000);
expect(pZ.element).toEqual(parent);
expect(pZ.delay).toEqual(4000);
expect(pZ.duration).toEqual(1000);
expect(pc5p.element).toEqual(elements[4]);
expect(pc5p.delay).toEqual(0);
expect(pc5p.duration).toEqual(4000);
expect(pp2.element).toEqual(parent);
expect(pp2.delay).toEqual(4000);
expect(pp2.duration).toEqual(1000);
});
it('should silently continue if a sub trigger is animated that doesn\'t exist', () => {
@@ -2110,17 +2126,27 @@ describe('animation query tests', function() {
engine.flush();
const players = getLog();
expect(players.length).toEqual(4);
const [pA, pc1, pc2, pZ] = players;
expect(players.length).toEqual(6);
expect(pc1.delay).toEqual(0);
expect(pc1.duration).toEqual(2800);
// players:
// - _scwp (skipped child w player): player for the child animation (trigger w)
// - _schp (skipped child h player): player for the child animation (trigger h)
// - _pp1 (parent player 1): player for parent animation (from opacity 0 to opacity 1)
// - pcwp (parent child w player):
// player for child w animation executed by parent via query and animateChild
// - pchp (parent child h player):
// player for child w animation executed by parent via query and animateChild
// - pp2 (parent player 2): player for parent animation (from opacity 1 to opacity 0)
const [_scwp, _schp, _pp1, pcwp, pchp, pp2] = players;
expect(pc2.delay).toEqual(0);
expect(pc2.duration).toEqual(2500);
expect(pcwp.delay).toEqual(0);
expect(pcwp.duration).toEqual(2800);
expect(pZ.delay).toEqual(2800);
expect(pZ.duration).toEqual(1000);
expect(pchp.delay).toEqual(0);
expect(pchp.duration).toEqual(2500);
expect(pp2.delay).toEqual(2800);
expect(pp2.duration).toEqual(1000);
});
it('should skip a sub animation when a zero duration value is passed in', () => {
@@ -2163,14 +2189,21 @@ describe('animation query tests', function() {
engine.flush();
const players = getLog();
expect(players.length).toEqual(2);
const [pA, pZ] = players;
expect(players.length).toEqual(3);
expect(pA.delay).toEqual(0);
expect(pA.duration).toEqual(1000);
// players:
// - _scp (skipped child player): player for the child animation
// - pp1 (parent player 1): player for parent animation (from opacity 0 to opacity 1)
// - ( the player for the child animation executed by parent via query
// and animateChild is skipped entirely )
// - pp2 (parent player 2): player for parent animation (from opacity 1 to opacity 0)
const [_scp, pp1, pp2] = players;
expect(pZ.delay).toEqual(1000);
expect(pZ.duration).toEqual(1000);
expect(pp1.delay).toEqual(0);
expect(pp1.duration).toEqual(1000);
expect(pp2.delay).toEqual(1000);
expect(pp2.duration).toEqual(1000);
});
it('should only allow a sub animation to be used up by a parent trigger once', () => {
@@ -2215,14 +2248,23 @@ describe('animation query tests', function() {
engine.flush();
const players = getLog();
expect(players.length).toEqual(3);
expect(players.length).toEqual(5);
const [p1, p2, p3] = players;
// players:
// - _scp (skipped child player): player for the child animation
// (note: parent2 is evaluated first because it is inside of parent1)
// - p2p (parent 2 player): player for parent animation (from opacity 0 to opacity 1)
// - p2cp (parent 2 child player):
// player for child animation executed by parent 2 via query and animateChild
// - p1p (parent 1 player): player for parent animation (from opacity 0 to opacity 1)
// - p1cp (parent 1 child player):
// player for child animation executed by parent 1 via query and animateChild
const [_scp, p2p, p2cp, p1p, p1cp] = players;
// parent2 is evaluated first because it is inside of parent1
expect(p1.element.classList.contains('parent2')).toBeTruthy();
expect(p2.element.classList.contains('child')).toBeTruthy();
expect(p3.element.classList.contains('parent1')).toBeTruthy();
expect(p2p.element.classList.contains('parent2')).toBeTruthy();
expect(p2cp.element.classList.contains('child')).toBeTruthy();
expect(p1p.element.classList.contains('parent1')).toBeTruthy();
expect(p1cp.element.classList.contains('child')).toBeTruthy();
});
it('should emulate a leave animation on the nearest sub host elements when a parent is removed',
@@ -2363,11 +2405,16 @@ describe('animation query tests', function() {
fixture.detectChanges();
let players = getLog();
expect(players.length).toEqual(1);
const [player] = players;
expect(players.length).toEqual(2);
expect(player.element.classList.contains('inner-div')).toBeTruthy();
expect(player.keyframes).toEqual([
// players:
// - _scp (skipped child player): player for the child animation
// - pcp (parent child player):
// player for child animation executed by parent via query and animateChild
const [_scp, pcp] = players;
expect(pcp.element.classList.contains('inner-div')).toBeTruthy();
expect(pcp.keyframes).toEqual([
{opacity: '0', offset: 0},
{opacity: '1', offset: 1},
]);
@@ -3140,10 +3187,23 @@ describe('animation query tests', function() {
fixture.detectChanges();
engine.flush();
const players = getLog();
expect(players.length).toEqual(5);
const [p1, p2, p3, p4, p5] = players;
expect(players.length).toEqual(6);
expect(p5.keyframes).toEqual([
// players:
// - _sgcp (skipped grand child player): player for the grand child animation
// - _psp (parent self player): player for parent self animation (opacity 0)
// - _pgcp1 (parent grand child player 1):
// player for child animation executed by parent via query (opacity 0)
// - _pp1 (parent player 1): player for parent animation (from opacity 0 to opacity 1)
// - _pgcp2 (parent grand child player 2):
// player for child animation executed by parent via query and animate
// (from opacity 0 to opacity 1)
// - pgcp3 (parent grand child player 3):
// player for child animation executed by parent via query and animateChild
// (from 0px to 200px)
const [_sgcp, _psp, _pgcp1, _pp1, _pgcp2, pgcp3] = players;
expect(pgcp3.keyframes).toEqual([
{offset: 0, width: '0px'}, {offset: .67, width: '0px'}, {offset: 1, width: '200px'}
]);
});
@@ -3206,11 +3266,16 @@ describe('animation query tests', function() {
fixture.detectChanges();
const players = getLog();
expect(players.length).toEqual(2);
expect(players.length).toEqual(3);
const [p1, p2] = players;
expect(p1.element.classList.contains('container')).toBeTruthy();
expect(p2.element.classList.contains('item')).toBeTruthy();
// players:
// - _scp (skipped child player): player for the child animation
// - pp (parent player): player for parent animation (from opacity 0 to opacity 1)
// - pcp (parent child player):
// player for child animation executed by parent via query and animateChild
const [_scp, pp, pcp] = players;
expect(pp.element.classList.contains('container')).toBeTruthy();
expect(pcp.element.classList.contains('item')).toBeTruthy();
});
it('should scope :leave queries between sub animations', () => {
@@ -3272,11 +3337,16 @@ describe('animation query tests', function() {
fixture.detectChanges();
const players = getLog();
expect(players.length).toEqual(2);
expect(players.length).toEqual(3);
const [p1, p2] = players;
expect(p1.element.classList.contains('container')).toBeTruthy();
expect(p2.element.classList.contains('item')).toBeTruthy();
// players:
// - _scp (skipped child player): player for the child animation
// - pp (parent player): player for parent animation (from opacity 0 to opacity 1)
// - pcp (parent child player):
// player for child animation executed by parent via query and animateChild
const [_scp, pp, pcp] = players;
expect(pp.element.classList.contains('container')).toBeTruthy();
expect(pcp.element.classList.contains('item')).toBeTruthy();
});
});
@@ -3309,14 +3379,14 @@ describe('animation query tests', function() {
})
class Cmp {
exp: any = '';
disableExp = false;
disabledExp = false;
}
TestBed.configureTestingModule({declarations: [Cmp]});
const fixture = TestBed.createComponent(Cmp);
const cmp = fixture.componentInstance;
cmp.disableExp = true;
cmp.disabledExp = true;
fixture.detectChanges();
resetLog();
@@ -3363,14 +3433,14 @@ describe('animation query tests', function() {
})
class Cmp {
exp: any = '';
disableExp = false;
disabledExp = false;
}
TestBed.configureTestingModule({declarations: [Cmp]});
const fixture = TestBed.createComponent(Cmp);
const cmp = fixture.componentInstance;
cmp.disableExp = true;
cmp.disabledExp = true;
fixture.detectChanges();
resetLog();
@@ -3386,6 +3456,63 @@ describe('animation query tests', function() {
expect(p2.duration).toEqual(1000);
expect(p2.element.classList.contains('parent')).toBeTrue();
});
it('should disable the animation for the given element regardless of existing parent element animation queries or child element animation queries',
() => {
@Component({
selector: 'some-cmp',
template: `
<div class="parent" [@parentAnimation]="exp">
<div class="child" [@.disabled]="disabledExp" [@childAnimation]="exp">
<div class="grand-child" [@grandChildAnimation]="exp"></div>
</div>
</div>
`,
animations: [
trigger(
'parentAnimation',
[
transition(
'* => go',
[query('@*', animateChild()), animate(1500, style({opacity: 0}))]),
]),
trigger(
'childAnimation',
[
transition('* => go', [animate(1000, style({opacity: 0}))]),
]),
trigger(
'grandChildAnimation',
[
transition('* => go', [animate(500, style({opacity: 0}))]),
]),
]
})
class Cmp {
exp: any = '';
disabledExp = false;
}
TestBed.configureTestingModule({declarations: [Cmp]});
const fixture = TestBed.createComponent(Cmp);
const cmp = fixture.componentInstance;
cmp.disabledExp = true;
fixture.detectChanges();
resetLog();
cmp.exp = 'go';
fixture.detectChanges();
const players = getLog();
expect(players.length).toEqual(2);
const [p1, p2] = players;
expect(p1.duration).toEqual(500);
expect(p1.element.classList.contains('grand-child')).toBeTrue();
expect(p2.duration).toEqual(1500);
expect(p2.element.classList.contains('parent')).toBeTrue();
});
});
});
});
+1 -1
View File
@@ -226,7 +226,7 @@ function updateControl(control: FormControl, dir: NgControl): void {
}
function setUpModelChangePipeline(control: FormControl, dir: NgControl): void {
const onChange = (newValue: any, emitModelEvent: boolean) => {
const onChange = (newValue?: any, emitModelEvent?: boolean) => {
// control -> view
dir.valueAccessor!.writeValue(newValue);
+19 -14
View File
@@ -1054,10 +1054,10 @@ export abstract class AbstractControl {
abstract _updateValue(): void;
/** @internal */
abstract _forEachChild(cb: Function): void;
abstract _forEachChild(cb: (c: AbstractControl) => void): void;
/** @internal */
abstract _anyControls(condition: Function): boolean;
abstract _anyControls(condition: (c: AbstractControl) => boolean): boolean;
/** @internal */
abstract _allControlsDisabled(): boolean;
@@ -1099,7 +1099,7 @@ export abstract class AbstractControl {
}
/** @internal */
_onDisabledChange: Function[] = [];
_onDisabledChange: Array<(isDisabled: boolean) => void> = [];
/** @internal */
_isBoxedValue(formState: any): boolean {
@@ -1229,13 +1229,18 @@ export abstract class AbstractControl {
*/
export class FormControl extends AbstractControl {
/** @internal */
_onChange: Function[] = [];
_onChange: Array<Function> = [];
/** @internal */
/**
* This field holds a pending value that has not yet been applied to the form's value.
* It is `any` because the value is untyped.
* @internal
*/
_pendingValue: any;
/** @internal */
_pendingChange: any;
_pendingChange: boolean = false;
/**
* Creates a new `FormControl` instance.
@@ -1358,7 +1363,7 @@ export class FormControl extends AbstractControl {
/**
* @internal
*/
override _anyControls(condition: Function): boolean {
override _anyControls(condition: (c: AbstractControl) => boolean): boolean {
return false;
}
@@ -1382,7 +1387,7 @@ export class FormControl extends AbstractControl {
* Internal function to unregister a change events listener.
* @internal
*/
_unregisterOnChange(fn: Function): void {
_unregisterOnChange(fn: (value?: any, emitModelEvent?: boolean) => void): void {
removeListItem(this._onChange, fn);
}
@@ -1406,7 +1411,7 @@ export class FormControl extends AbstractControl {
/**
* @internal
*/
override _forEachChild(cb: Function): void {}
override _forEachChild(cb: (c: AbstractControl) => void): void {}
/** @internal */
override _syncPendingControls(): boolean {
@@ -1847,7 +1852,7 @@ export class FormGroup extends AbstractControl {
}
/** @internal */
override _anyControls(condition: Function): boolean {
override _anyControls(condition: (c: AbstractControl) => boolean): boolean {
for (const controlName of Object.keys(this.controls)) {
const control = this.controls[controlName];
if (this.contains(controlName) && condition(control)) {
@@ -1860,7 +1865,7 @@ export class FormGroup extends AbstractControl {
/** @internal */
_reduceValue() {
return this._reduceChildren(
{}, (acc: {[k: string]: AbstractControl}, control: AbstractControl, name: string) => {
{}, (acc: {[k: string]: any}, control: AbstractControl, name: string): any => {
if (control.enabled || this.disabled) {
acc[name] = control.value;
}
@@ -1869,7 +1874,7 @@ export class FormGroup extends AbstractControl {
}
/** @internal */
_reduceChildren(initValue: any, fn: Function) {
_reduceChildren<T>(initValue: T, fn: (acc: T, control: AbstractControl, name: string) => T): T {
let res = initValue;
this._forEachChild((control: AbstractControl, name: string) => {
res = fn(res, control, name);
@@ -2308,7 +2313,7 @@ export class FormArray extends AbstractControl {
}
/** @internal */
override _forEachChild(cb: Function): void {
override _forEachChild(cb: (c: AbstractControl, index: number) => void): void {
this.controls.forEach((control: AbstractControl, index: number) => {
cb(control, index);
});
@@ -2322,7 +2327,7 @@ export class FormArray extends AbstractControl {
}
/** @internal */
override _anyControls(condition: Function): boolean {
override _anyControls(condition: (c: AbstractControl) => boolean): boolean {
return this.controls.some((control: AbstractControl) => control.enabled && condition(control));
}
+9 -6
View File
@@ -10,6 +10,7 @@ import {fakeAsync, tick} from '@angular/core/testing';
import {AbstractControl, FormArray, FormControl, FormGroup, ValidationErrors, ValidatorFn} from '@angular/forms';
import {Validators} from '@angular/forms/src/validators';
import {of} from 'rxjs';
import {asyncValidator} from './util';
(function() {
@@ -137,7 +138,7 @@ describe('FormArray', () => {
// becomes invalid.
const validatorFn = (value: any) => value.controls.length > 0 ? {controls: true} : null;
const asyncValidatorFn = (value: any) => of(validatorFn(value));
const arr = new FormArray([], validatorFn, asyncValidatorFn);
const arr: FormArray = new FormArray([], validatorFn, asyncValidatorFn);
expect(arr.valid).toBe(true);
arr.statusChanges.subscribe(() => logger.push('status change'));
@@ -178,7 +179,8 @@ describe('FormArray', () => {
it('should work with nested form groups/arrays', () => {
a = new FormArray([
new FormGroup({'c2': new FormControl('v2'), 'c3': new FormControl('v3')}),
new FormGroup(
{'c2': new FormControl('v2') as AbstractControl, 'c3': new FormControl('v3')}),
new FormArray([new FormControl('v4'), new FormControl('v5')])
]);
a.at(0).get('c3')!.disable();
@@ -191,7 +193,8 @@ describe('FormArray', () => {
describe('markAllAsTouched', () => {
it('should mark all descendants as touched', () => {
const formArray: FormArray = new FormArray([
new FormControl('v1'), new FormControl('v2'), new FormGroup({'c1': new FormControl('v1')}),
new FormControl('v1') as AbstractControl, new FormControl('v2'),
new FormGroup({'c1': new FormControl('v1')}),
new FormArray([new FormGroup({'c2': new FormControl('v2')})])
]);
@@ -306,7 +309,7 @@ describe('FormArray', () => {
});
it('should throw if no controls are set yet', () => {
const empty = new FormArray([]);
const empty: FormArray = new FormArray([]);
expect(() => empty.setValue(['one']))
.toThrowError(new RegExp(`no form controls registered with this array`));
});
@@ -730,7 +733,7 @@ describe('FormArray', () => {
const simpleValidator = (c: FormArray) =>
c.controls[0].value != 'correct' ? {'broken': true} : null;
const c = new FormControl(null);
const c = new FormControl('');
const g = new FormArray([c], simpleValidator as ValidatorFn);
c.setValue('correct');
@@ -1174,7 +1177,7 @@ describe('FormArray', () => {
});
it('should keep empty, disabled arrays disabled when updating validity', () => {
const arr = new FormArray([]);
const arr: FormArray = new FormArray([]);
expect(arr.status).toEqual('VALID');
arr.disable();
+55 -1
View File
@@ -55,6 +55,59 @@ describe('Form Builder', () => {
expect(g.controls['login'].asyncValidator).toBe(asyncValidator);
});
it('should create controls from FormStates', () => {
const c = b.control({value: 'one', disabled: false});
expect(c.value).toEqual('one');
c.reset();
expect(c.value).toEqual(null);
});
it('should work on a directly constructed FormBuilder object', () => {
const g = b.group({'login': 'some value'});
expect(g.controls['login'].value).toEqual('some value');
});
it('should create homogenous control arrays', () => {
const a = b.array(['one', 'two', 'three']);
expect(a.value).toEqual(['one', 'two', 'three']);
});
it('should create control arrays with FormStates and ControlConfigs', () => {
const a = b.array(['one', 'two', {value: 'three', disabled: false}]);
expect(a.value).toEqual(['one', 'two', 'three']);
});
it('should create control arrays with ControlConfigs', () => {
const a = b.array([['one', syncValidator, asyncValidator]]);
expect(a.value).toEqual(['one']);
expect(a.controls[0].validator).toBe(syncValidator);
expect(a.controls[0].asyncValidator).toBe(asyncValidator);
});
it('should create nested control arrays with ControlConfigs', () => {
const a = b.array(['one', ['two', syncValidator, asyncValidator]]);
expect(a.value).toEqual(['one', 'two']);
expect(a.controls[1].validator).toBe(syncValidator);
expect(a.controls[1].asyncValidator).toBe(asyncValidator);
});
it('should create control arrays with AbstractControls', () => {
const ctrl = b.control('one');
const a = b.array([ctrl], syncValidator, asyncValidator);
expect(a.value).toEqual(['one']);
expect(a.validator).toBe(syncValidator);
expect(a.asyncValidator).toBe(asyncValidator);
});
it('should create control arrays with mixed value representations', () => {
const a = b.array([
'one', ['two', syncValidator, asyncValidator], {value: 'three', disabled: false},
[{value: 'four', disabled: false}, syncValidator, asyncValidator], ['five'], b.control('six'),
b.control({value: 'seven', disabled: false})
]);
expect(a.value).toEqual(['one', 'two', 'three', 'four', 'five', 'six', 'seven']);
});
it('should support controls with no validators and whose form state is null', () => {
const g = b.group({'login': b.control(null)});
expect(g.controls['login'].value).toBeNull();
@@ -107,7 +160,8 @@ describe('Form Builder', () => {
const e = b.control(null);
const f = b.control(undefined);
const a = b.array(
['one', ['two', syncValidator], c, b.array(['four']), e, f], syncValidator, asyncValidator);
['one' as any, ['two', syncValidator], c, b.array(['four']), e, f], syncValidator,
asyncValidator);
expect(a.value).toEqual(['one', 'two', 'three', ['four'], null, null]);
expect(a.validator).toBe(syncValidator);
+7 -5
View File
@@ -8,8 +8,8 @@
import {fakeAsync, tick} from '@angular/core/testing';
import {FormControl, FormGroup, Validators} from '@angular/forms';
import {FormArray} from '@angular/forms/src/model';
import {asyncValidator, asyncValidatorReturningObservable} from './util';
(function() {
@@ -59,7 +59,8 @@ describe('FormControl', () => {
});
it('should not treat objects as boxed values if they have more than two props', () => {
const c = new FormControl({value: '', disabled: true, test: 'test'}, null!, null!);
const c: FormControl =
new FormControl({value: '', disabled: true, test: 'test'} as any, null!, null!);
expect(c.value).toEqual({value: '', disabled: true, test: 'test'});
expect(c.disabled).toBe(false);
});
@@ -175,7 +176,7 @@ describe('FormControl', () => {
});
it('should support single validator from options obj', () => {
const c = new FormControl(null, {validators: Validators.required});
const c: FormControl = new FormControl(null, {validators: Validators.required});
expect(c.valid).toEqual(false);
expect(c.errors).toEqual({required: true});
@@ -184,7 +185,8 @@ describe('FormControl', () => {
});
it('should support multiple validators from options obj', () => {
const c = new FormControl(null, {validators: [Validators.required, Validators.minLength(3)]});
const c: FormControl =
new FormControl(null, {validators: [Validators.required, Validators.minLength(3)]});
expect(c.valid).toEqual(false);
expect(c.errors).toEqual({required: true});
@@ -212,7 +214,7 @@ describe('FormControl', () => {
});
it('should set single validator', () => {
const c = new FormControl(null);
const c: FormControl = new FormControl(null);
expect(c.valid).toEqual(true);
c.setValidators(Validators.required);
+19 -17
View File
@@ -70,7 +70,8 @@ describe('FormGroup', () => {
'c1': new FormControl('v1'),
'group': new FormGroup({'c2': new FormControl('v2'), 'c3': new FormControl('v3')}),
'array': new FormArray([
new FormControl('v4'), new FormControl('v5'), new FormGroup({'c4': new FormControl('v4')})
new FormControl('v4') as any, new FormControl('v5'),
new FormGroup({'c4': new FormControl('v4')})
])
});
@@ -132,7 +133,7 @@ describe('FormGroup', () => {
});
it('should update value and validity when control is added', () => {
const g = new FormGroup({'one': new FormControl('1')});
const g: FormGroup = new FormGroup({'one': new FormControl('1')});
expect(g.value).toEqual({'one': '1'});
expect(g.valid).toBe(true);
@@ -143,7 +144,7 @@ describe('FormGroup', () => {
});
it('should update value and validity when control is removed', () => {
const g = new FormGroup(
const g: FormGroup = new FormGroup(
{'one': new FormControl('1'), 'two': new FormControl('2', Validators.minLength(10))});
expect(g.value).toEqual({'one': '1', 'two': '2'});
expect(g.valid).toBe(false);
@@ -156,7 +157,7 @@ describe('FormGroup', () => {
it('should not emit events when `FormGroup.addControl` is called with `emitEvent: false`',
() => {
const g = new FormGroup({'one': new FormControl('1')});
const g: FormGroup = new FormGroup({'one': new FormControl('1')});
expect(g.value).toEqual({'one': '1'});
g.valueChanges.subscribe(() => logger.push('value change'));
@@ -170,7 +171,7 @@ describe('FormGroup', () => {
it('should not emit events when `FormGroup.removeControl` is called with `emitEvent: false`',
() => {
const g = new FormGroup(
const g: FormGroup = new FormGroup(
{'one': new FormControl('1'), 'two': new FormControl('2', Validators.minLength(10))});
expect(g.value).toEqual({'one': '1', 'two': '2'});
expect(g.valid).toBe(false);
@@ -190,7 +191,7 @@ describe('FormGroup', () => {
const validatorFn = (value: any) =>
value.controls.invalidCtrl ? {invalidCtrl: true} : null;
const asyncValidatorFn = (value: any) => of(validatorFn(value));
const g = new FormGroup({}, validatorFn, asyncValidatorFn);
const g: FormGroup = new FormGroup({}, validatorFn, asyncValidatorFn);
expect(g.valid).toBe(true);
g.statusChanges.subscribe(() => logger.push('status change'));
@@ -939,7 +940,7 @@ describe('FormGroup', () => {
}
it('should run a single validator when the value changes', () => {
const c = new FormControl(null);
const c: FormControl = new FormControl(null);
const g = new FormGroup({'one': c}, simpleValidator);
c.setValue('correct');
@@ -1152,14 +1153,14 @@ describe('FormGroup', () => {
fakeAsync(() => {
const c = new FormControl(
'fcValue', null!, simpleAsyncValidator({timeout: 0, shouldFail: false}));
const g = new FormGroup(
const g: FormGroup = new FormGroup(
{'one': c}, null!, simpleAsyncValidator({timeout: 0, shouldFail: false}));
const c2 =
new FormControl('fcVal', null!, simpleAsyncValidator({timeout: 0, shouldFail: false}));
const a =
new FormArray([g, c2], null!, simpleAsyncValidator({timeout: 0, shouldFail: true}));
const a = new FormArray(
[g as any, c2], null!, simpleAsyncValidator({timeout: 0, shouldFail: true}));
expect(currentStateOf([a, a.at(0)!, a.at(1)!])).toEqual([
{errors: {async: true}, pending: false, status: 'INVALID'}, // Array
@@ -1266,8 +1267,8 @@ describe('FormGroup', () => {
const c2 =
new FormControl('fcVal', null!, simpleAsyncValidator({timeout: 3, shouldFail: false}));
const a =
new FormArray([g, c2], null!, simpleAsyncValidator({timeout: 4, shouldFail: false}));
const a = new FormArray(
[g as any, c2], null!, simpleAsyncValidator({timeout: 4, shouldFail: false}));
// Initially, the form array and the tested form group and form control c2 are in pending
// state
@@ -1314,8 +1315,8 @@ describe('FormGroup', () => {
const c2 =
new FormControl('fcVal', null!, simpleAsyncValidator({timeout: 3, shouldFail: false}));
const a =
new FormArray([g, c2], null!, simpleAsyncValidator({timeout: 4, shouldFail: true}));
const a = new FormArray(
[g as any, c2], null!, simpleAsyncValidator({timeout: 4, shouldFail: true}));
// Initially, the form array and the tested form group and form control c2 are in pending
// state
@@ -1711,7 +1712,7 @@ describe('FormGroup', () => {
});
it('should keep empty, disabled groups disabled when updating validity', () => {
const group = new FormGroup({});
const group: FormGroup = new FormGroup({});
expect(group.status).toEqual('VALID');
group.disable();
@@ -1764,7 +1765,7 @@ describe('FormGroup', () => {
});
it('should re-populate group errors when enabled from a child', () => {
const g = new FormGroup({'one': new FormControl()}, () => ({'expected': true}));
const g: FormGroup = new FormGroup({'one': new FormControl()}, () => ({'expected': true}));
g.disable();
expect(g.errors).toEqual(null);
@@ -1786,7 +1787,8 @@ describe('FormGroup', () => {
}));
it('should re-populate async group errors when enabled from a child', fakeAsync(() => {
const g = new FormGroup({'one': new FormControl()}, null!, asyncValidator('expected'));
const g: FormGroup =
new FormGroup({'one': new FormControl()}, null!, asyncValidator('expected'));
tick();
expect(g.errors).toEqual({'async': true});
@@ -261,7 +261,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
it('should strip named controls that are not found', () => {
const fixture = initTest(NestedFormGroupNameComp, LoginIsEmptyValidator);
const form = new FormGroup({
const form: FormGroup = new FormGroup({
'signin': new FormGroup({'login': new FormControl(''), 'password': new FormControl('')})
});
fixture.componentInstance.form = form;
@@ -311,7 +311,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
describe('nested control rebinding', () => {
it('should attach dir to control when leaf control changes', () => {
const form = new FormGroup({'login': new FormControl('oldValue')});
const form: FormGroup = new FormGroup({'login': new FormControl('oldValue')});
const fixture = initTest(FormGroupComp);
fixture.componentInstance.form = form;
fixture.detectChanges();
@@ -336,7 +336,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
it('should attach dirs to all child controls when group control changes', () => {
const fixture = initTest(NestedFormGroupNameComp, LoginIsEmptyValidator);
const form = new FormGroup({
const form: FormGroup = new FormGroup({
signin: new FormGroup(
{login: new FormControl('oldLogin'), password: new FormControl('oldPassword')})
});
@@ -369,7 +369,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
it('should attach dirs to all present child controls when array control changes', () => {
const fixture = initTest(FormArrayComp);
const cityArray = new FormArray([new FormControl('SF'), new FormControl('NY')]);
const form = new FormGroup({cities: cityArray});
const form: FormGroup = new FormGroup({cities: cityArray});
fixture.componentInstance.form = form;
fixture.componentInstance.cityArray = cityArray;
fixture.detectChanges();
@@ -1458,7 +1458,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
class App implements OnDestroy {
private _subscription: Subscription;
form = new FormGroup({
form: FormGroup = new FormGroup({
name: new FormControl('Frodo'),
surname: new FormControl('Baggins'),
});
@@ -1490,7 +1490,8 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
it('should not emit valueChanges or statusChanges until blur', () => {
const fixture = initTest(FormControlComp);
const control = new FormControl('', {validators: Validators.required, updateOn: 'blur'});
const control: FormControl =
new FormControl('', {validators: Validators.required, updateOn: 'blur'});
fixture.componentInstance.control = control;
fixture.detectChanges();
const values: string[] = [];
@@ -1516,7 +1517,8 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
it('should not emit valueChanges or statusChanges on blur if value unchanged', () => {
const fixture = initTest(FormControlComp);
const control = new FormControl('', {validators: Validators.required, updateOn: 'blur'});
const control: FormControl =
new FormControl('', {validators: Validators.required, updateOn: 'blur'});
fixture.componentInstance.control = control;
fixture.detectChanges();
const values: string[] = [];
@@ -1890,7 +1892,7 @@ const ValueAccessorB = createControlValueAccessor('[cva-b]');
fixture.componentInstance.form = formGroup;
fixture.detectChanges();
const values: (string|{[key: string]: string})[] = [];
const values: any[] = [];
const streams = merge(
control.valueChanges, control.statusChanges, formGroup.valueChanges,
formGroup.statusChanges);
@@ -5322,7 +5324,7 @@ class FormControlWithAsyncValidatorFn {
`
})
class FormControlWithValidators {
form = new FormGroup({login: new FormControl('INITIAL')});
form: FormGroup = new FormGroup({login: new FormControl('INITIAL')});
}
@Component({
@@ -5353,7 +5355,7 @@ class MultipleFormControls {
`
})
class NgForFormControlWithValidators {
form = new FormGroup({login: new FormControl('a')});
form: FormGroup = new FormGroup({login: new FormControl('a')});
logins = ['a', 'b', 'c'];
}
@@ -621,7 +621,7 @@ import {dispatchEvent} from '@angular/platform-browser/testing/src/browser_util'
it('should properly set value to null and undefined', () => {
const fixture = initTest(FormControlRadioButtons);
const form = new FormGroup(
const form: FormGroup = new FormGroup(
{'food': new FormControl('chicken'), 'drink': new FormControl('sprite')});
fixture.componentInstance.form = form;
fixture.detectChanges();
@@ -675,7 +675,7 @@ import {dispatchEvent} from '@angular/platform-browser/testing/src/browser_util'
it('should support removing controls from <type=radio>', () => {
const fixture = initTest(FormControlRadioButtons);
const showRadio = new FormControl('yes');
const form =
const form: FormGroup =
new FormGroup({'food': new FormControl('fish'), 'drink': new FormControl('sprite')});
fixture.componentInstance.form = form;
fixture.componentInstance.showRadio = showRadio;
+1 -1
View File
@@ -15,7 +15,7 @@
"@types/node": "^10.9.4",
"domino": "2.1.6",
"jest": "^26.4",
"google-closure-compiler": "^20211006.0.0",
"google-closure-compiler": "^20211201.0.0",
"mocha": "^9.0.0",
"mock-require": "3.0.3",
"promises-aplus-tests": "^2.1.2",
+24 -24
View File
@@ -1706,40 +1706,40 @@ globals@^11.1.0:
resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e"
integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA==
google-closure-compiler-java@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-java/-/google-closure-compiler-java-20211006.0.0.tgz#d3ccbbfa349f2ffff5e623d45e7798cfe8e450c4"
integrity sha512-ggvk48GuP5Y8TD1I9dcJTu50+BQ2AfroAAsTV7nnbKdEPCZ/XJmGqy5qrJk0ImdAvONUHZETc5DMHHgFI5WjMg==
google-closure-compiler-java@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-java/-/google-closure-compiler-java-20211201.0.0.tgz#41eb570189ad35d9b09a2331e37157951dd99e75"
integrity sha512-TQop4dF0k/mb9sPu0aZsvW8OVfuZG4+t4ITZeA/u43deiAA4AFScZQQUMUmoVmXzR8Jz0eeucKoZPTwKAwcSmQ==
google-closure-compiler-linux@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-linux/-/google-closure-compiler-linux-20211006.0.0.tgz#471eef6600a682d6cf95fc3218f9d925bcedb6b7"
integrity sha512-7FclqwRDHcx9zvoy1JCQB3DC84T0anyOsb5kNIZgIf/oaUCvq27ElJK1X7W6IenOcwYyvDDWeDb38YkWl15ANw==
google-closure-compiler-linux@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-linux/-/google-closure-compiler-linux-20211201.0.0.tgz#6f84f745d9c0f79677b270cc3007d70ce4a741e1"
integrity sha512-7nMgBFZYYQTvDLcO+LqqwtibgZJu8qaFJbK84T12xneY1Yy1fUSn56NXaZ9cgdS7p30Hqy6tYcw9ZSuxK7fuEA==
google-closure-compiler-osx@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-osx/-/google-closure-compiler-osx-20211006.0.0.tgz#6e74c82b9c167e34319bf67e93201bcde0a91169"
integrity sha512-b0FGLvYZuMbDoLcu5z1lw0nWigpT8G29acuh4Yz6zO4NFq1aCpyR1X+BPhC2KCxb2eaMWPx2xoxbsekhkU0VzQ==
google-closure-compiler-osx@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-osx/-/google-closure-compiler-osx-20211201.0.0.tgz#9ba8231a68cfaacc02d47367af43171a383dbe96"
integrity sha512-eJKmvYm5C82BAcfK64/7nR3RbR4bwIXO2Dmhmb5AR6FXxD/J1svaG3BMINlS+U/GT7NeV4Z7bKb2TcPIAfGO9A==
google-closure-compiler-windows@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-windows/-/google-closure-compiler-windows-20211006.0.0.tgz#ae88366bfce882e6d524a0dd35bb1a5681c31172"
integrity sha512-7P13hA42LWIm4o+speQC5Yhs3D+3q9nvuItOxLCzess1sPDeBKi5dQi3w+C2MBTDyVN0CTKL86iClyyOnrbuRQ==
google-closure-compiler-windows@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-windows/-/google-closure-compiler-windows-20211201.0.0.tgz#e81c1b2d68df5730065c08cd80daed84bf0013fc"
integrity sha512-OPZYA0+tJSjutt1EYrECmXChNsY5USoMbQkBEmwI29riVvNnK5Ot+/SE66/NPHwm3qI/p3O7TnOTKhVpXKed5Q==
google-closure-compiler@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler/-/google-closure-compiler-20211006.0.0.tgz#0c26abc40b30f989a913ead39d3b6d2099cf4e7a"
integrity sha512-WrzPLGtNMtgPubcvSur8JzzpuNn4feS7OMF74Hsm00G0qpdNvBVCIkMpnLr9SPZnl2vZ8UVqt83XVXMpQRTkUw==
google-closure-compiler@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler/-/google-closure-compiler-20211201.0.0.tgz#e767dc74b72b1d9b2203450185120abcb9278d5f"
integrity sha512-QPNp6uHR94EKbi17XCsdISHAqIgk1Ep7LpB+rmPDY7VoNAX4784WT/0bz6HyVK4QYRVLlNAy2X+1+VlFhS0FzQ==
dependencies:
chalk "2.x"
google-closure-compiler-java "^20211006.0.0"
google-closure-compiler-java "^20211201.0.0"
minimist "1.x"
vinyl "2.x"
vinyl-sourcemaps-apply "^0.2.0"
optionalDependencies:
google-closure-compiler-linux "^20211006.0.0"
google-closure-compiler-osx "^20211006.0.0"
google-closure-compiler-windows "^20211006.0.0"
google-closure-compiler-linux "^20211201.0.0"
google-closure-compiler-osx "^20211201.0.0"
google-closure-compiler-windows "^20211201.0.0"
graceful-fs@^4.2.4:
version "4.2.8"
+211 -175
View File
@@ -34,23 +34,23 @@
"@jridgewell/resolve-uri" "1.0.0"
sourcemap-codec "1.4.8"
"@angular-devkit/architect@0.1300.3":
version "0.1300.3"
resolved "https://registry.yarnpkg.com/@angular-devkit/architect/-/architect-0.1300.3.tgz#8d74a0f3cc3a0e4ecb0c6723e13fc0fee4790363"
integrity sha512-XY3sjRLk06Q+uAU0BePuIWcK1n3Jr0ksNV0ACNAct+MnI3QFfPPaYA/Tdhp9uWobuZ4lUrL0drc2uppNu0wKmA==
"@angular-devkit/architect@0.1300.4":
version "0.1300.4"
resolved "https://registry.yarnpkg.com/@angular-devkit/architect/-/architect-0.1300.4.tgz#2b3a0606138a4f1259bb146e378a835f667fd82c"
integrity sha512-COW2W6rI9D69QEXGc/MyTbJY9gT+u8yMTpONpIjopd+KoSK/q2wGr0RleUf7XSCunZCs0SRI7z3Pw1EAdQCP7Q==
dependencies:
"@angular-devkit/core" "13.0.3"
"@angular-devkit/core" "13.0.4"
rxjs "6.6.7"
"@angular-devkit/build-angular@13.0.3":
version "13.0.3"
resolved "https://registry.yarnpkg.com/@angular-devkit/build-angular/-/build-angular-13.0.3.tgz#763db8882ff86612462a2b6bcdf441ba8e4b29a5"
integrity sha512-5KFsknpnq3mc0KwcIDjvmqB3trz5cMt48dB0nrc23zkFI9v4hkpalc/OEg/H3G93K0c9g6dcyxmHkNfsU1+CHw==
"@angular-devkit/build-angular@13.0.4":
version "13.0.4"
resolved "https://registry.yarnpkg.com/@angular-devkit/build-angular/-/build-angular-13.0.4.tgz#2a976cdc8265a13a10e7aaf615e13da55e39a41a"
integrity sha512-GYAxQTI0YkjVKciepwliMugUDjgXlmePG80LL2FCVQYnSM6r2uAI3dF8vX8fREZIRpBpDuTtUIohCRr1X5Oysg==
dependencies:
"@ampproject/remapping" "1.0.1"
"@angular-devkit/architect" "0.1300.3"
"@angular-devkit/build-webpack" "0.1300.3"
"@angular-devkit/core" "13.0.3"
"@angular-devkit/architect" "0.1300.4"
"@angular-devkit/build-webpack" "0.1300.4"
"@angular-devkit/core" "13.0.4"
"@babel/core" "7.15.8"
"@babel/generator" "7.15.8"
"@babel/helper-annotate-as-pure" "7.15.4"
@@ -61,7 +61,7 @@
"@babel/runtime" "7.15.4"
"@babel/template" "7.15.4"
"@discoveryjs/json-ext" "0.5.5"
"@ngtools/webpack" "13.0.3"
"@ngtools/webpack" "13.0.4"
ansi-colors "4.1.1"
babel-loader "8.2.3"
babel-plugin-istanbul "6.1.1"
@@ -114,10 +114,10 @@
optionalDependencies:
esbuild "0.13.12"
"@angular-devkit/build-optimizer@0.1300.3":
version "0.1300.3"
resolved "https://registry.yarnpkg.com/@angular-devkit/build-optimizer/-/build-optimizer-0.1300.3.tgz#d5af19553193d719f613814bc28b7e88a68beef3"
integrity sha512-dlTMQ9RBPrhUyAx41aqp1f1b7TjkIh4Ydnx0iMPi8zYJYuyUzNvqQBvBE7POQjeIqnYlL6AktrUrCY7Wul9T2g==
"@angular-devkit/build-optimizer@0.1300.4":
version "0.1300.4"
resolved "https://registry.yarnpkg.com/@angular-devkit/build-optimizer/-/build-optimizer-0.1300.4.tgz#69a351ad62a00267f5a2e81c1b2fbcd75d6da6c9"
integrity sha512-vGWZcUKp6ET91fQa600uNOXrkN/vhP73s/rfse6YwdTWgqFLOTTt/TH3yIG2SBJ2IZOPIsgfJy2KmioOec72QQ==
dependencies:
source-map "0.7.3"
tslib "2.3.1"
@@ -142,18 +142,18 @@
tslib "2.3.1"
typescript "4.4.4"
"@angular-devkit/build-webpack@0.1300.3":
version "0.1300.3"
resolved "https://registry.yarnpkg.com/@angular-devkit/build-webpack/-/build-webpack-0.1300.3.tgz#c0464b6c0d5d09cdd613ed17173a7f3822da1aa3"
integrity sha512-3DNo8575FFPMqJaVMXxrIduWkrcKm5zYSCvkMOmzHLp+gx+RXQiwnoXfVJpukcE/jwK/4SWyRE8Tw75sfPJ71A==
"@angular-devkit/build-webpack@0.1300.4":
version "0.1300.4"
resolved "https://registry.yarnpkg.com/@angular-devkit/build-webpack/-/build-webpack-0.1300.4.tgz#5835dcb4a591560a89791616be5173a70075cfd2"
integrity sha512-6h4ecyGefj0Fdn8+wYV0QhQgtNQOw83Jw/cM+LeIR28VX7A6ZEEnYf2P5YrCmZFGxznXFYQZNiu8E0mPgBOh3A==
dependencies:
"@angular-devkit/architect" "0.1300.3"
"@angular-devkit/architect" "0.1300.4"
rxjs "6.6.7"
"@angular-devkit/core@13.0.3":
version "13.0.3"
resolved "https://registry.yarnpkg.com/@angular-devkit/core/-/core-13.0.3.tgz#05911ab964f8cbd5cade9bd48215424836ab9c87"
integrity sha512-5yTYW6m4pkDPSYNxThm+47h+UZ6XVEfdfsXR3o+WlRG0hc18EuQ+sXZkzhvZrk5KMLlXFex4eO40RPq2vvWS/w==
"@angular-devkit/core@13.0.4":
version "13.0.4"
resolved "https://registry.yarnpkg.com/@angular-devkit/core/-/core-13.0.4.tgz#98b7e2d34afc117cafcbba1cd71f00e3c7089289"
integrity sha512-AzgLvERLC6qzY5aZWUpkz5nx+pZChrq3DSt6azMPALwzzoABrwiO6XqzRnj17mXtANXLH2oe9FuHr9jzgFbF1g==
dependencies:
ajv "8.6.3"
ajv-formats "2.1.1"
@@ -162,12 +162,12 @@
rxjs "6.6.7"
source-map "0.7.3"
"@angular-devkit/schematics@13.0.3":
version "13.0.3"
resolved "https://registry.yarnpkg.com/@angular-devkit/schematics/-/schematics-13.0.3.tgz#255895e10c2b025df8ee4ff93428cb2249ae5fc0"
integrity sha512-+Va1E0zJBCg5jqSfITusghoMJgPAwlU+WUs49fuGVCzfJPwfSjTKSrsbhanahMd27+Ys3rovGZq0F2JUdL801A==
"@angular-devkit/schematics@13.0.4":
version "13.0.4"
resolved "https://registry.yarnpkg.com/@angular-devkit/schematics/-/schematics-13.0.4.tgz#9455e695ae25b642d9a93179938149cd52ccdbb1"
integrity sha512-3LsmpfAEOxwPyachrktCHtGUYBzQCCzD0++CUjhK8W99v8/IAplkm4dgovFb1RiRkUm44l+HIS7387AbvEIf5A==
dependencies:
"@angular-devkit/core" "13.0.3"
"@angular-devkit/core" "13.0.4"
jsonc-parser "3.0.0"
magic-string "0.25.7"
ora "5.4.1"
@@ -188,15 +188,15 @@
"@angular/core" "^10.0.0-0 || ^11.0.0"
reflect-metadata "^0.1.13"
"@angular/cli@13.0.3":
version "13.0.3"
resolved "https://registry.yarnpkg.com/@angular/cli/-/cli-13.0.3.tgz#7d357a80dc612421115b1288291ce6278720d0a4"
integrity sha512-LDXDXDbQ1MBHVUstu4aNjFbyg5f9hLP52gEKB8Z6fQlf5CB1X5zD6UPcR4IvoYt03EFxg3DHco+ueJQ20oZUWQ==
"@angular/cli@13.0.4":
version "13.0.4"
resolved "https://registry.yarnpkg.com/@angular/cli/-/cli-13.0.4.tgz#28932cb8e2c9e1eb4a65db459be851932f51eecd"
integrity sha512-0QMJXFNn57LVg7ZwZFPO90g6aZHDnoe5yCB7fo3nskOhDw1AW/rnbbaNVMVX/SvP30hOOTLsfVJ1Y3I6eKDgRA==
dependencies:
"@angular-devkit/architect" "0.1300.3"
"@angular-devkit/core" "13.0.3"
"@angular-devkit/schematics" "13.0.3"
"@schematics/angular" "13.0.3"
"@angular-devkit/architect" "0.1300.4"
"@angular-devkit/core" "13.0.4"
"@angular-devkit/schematics" "13.0.4"
"@schematics/angular" "13.0.4"
"@yarnpkg/lockfile" "1.1.0"
ansi-colors "4.1.1"
debug "4.3.2"
@@ -234,9 +234,10 @@
dependencies:
tslib "^2.0.0"
"@angular/dev-infra-private@https://github.com/angular/dev-infra-private-builds.git#74fb4de008fde297fb83393ff076de10532f82a9":
version "0.0.0-c2fb49a44ad9fa77f508010f950524ee97f5e8d5"
resolved "https://github.com/angular/dev-infra-private-builds.git#74fb4de008fde297fb83393ff076de10532f82a9"
"@angular/dev-infra-private@https://github.com/angular/dev-infra-private-builds.git#e4a13cfd135ec766dc9148ba4fe4d3ac76d94137":
version "0.0.0-486b6e2b6388e2bebf19e6daf0b4b997df62693c"
uid e4a13cfd135ec766dc9148ba4fe4d3ac76d94137
resolved "https://github.com/angular/dev-infra-private-builds.git#e4a13cfd135ec766dc9148ba4fe4d3ac76d94137"
dependencies:
"@actions/core" "^1.4.0"
"@actions/github" "^5.0.0"
@@ -245,11 +246,11 @@
"@babel/core" "^7.16.0"
"@bazel/bazelisk" "^1.10.1"
"@bazel/buildifier" "^4.0.1"
"@bazel/esbuild" "4.4.5"
"@bazel/jasmine" "4.4.5"
"@bazel/protractor" "4.4.5"
"@bazel/runfiles" "4.4.5"
"@bazel/typescript" "4.4.5"
"@bazel/esbuild" "4.4.6"
"@bazel/jasmine" "4.4.6"
"@bazel/protractor" "4.4.6"
"@bazel/runfiles" "4.4.6"
"@bazel/typescript" "4.4.6"
"@microsoft/api-extractor" "7.18.19"
"@octokit/auth-app" "^3.6.0"
"@octokit/core" "^3.5.1"
@@ -279,7 +280,7 @@
node-fetch "^2.6.1"
prettier "^2.3.2"
protractor "^7.0.0"
rollup "2.60.0"
rollup "2.60.1"
rollup-plugin-sourcemaps "^0.6.3"
selenium-webdriver "3.5.0"
semver "^7.3.5"
@@ -289,7 +290,7 @@
tslib "^2.3.0"
tslint "^6.1.3"
typed-graphqlify "^3.1.1"
typescript "~4.4.0"
typescript "~4.5.0"
uuid "^8.3.2"
yaml "^1.10.0"
yargs "^17.0.0"
@@ -1203,111 +1204,70 @@
resolved "https://registry.yarnpkg.com/@bazel/buildifier/-/buildifier-4.2.3.tgz#2c6e54faa12e31b75051834cf1cfa68c71678262"
integrity sha512-19GqPhxlyh376mJT6kvvNAJbRCjDj4WFjqy+sT2LAMt5THMGSES8+lwde5J1jwpud/mqrNUIRjEzVZR5A/6+BA==
"@bazel/concatjs@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/concatjs/-/concatjs-4.4.2.tgz#773272bc62f54d58044842998e21a152e840d943"
integrity sha512-8AyR4fsITSQFPpCwneftRYPg6Rlr/JfVnNbBDUSKzj9Fm3DWdR21t3nSQcUkUMJNSQ54ZYaVkpZD8y0zPN0u/w==
"@bazel/concatjs@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/concatjs/-/concatjs-4.4.6.tgz#842e4472f5d766a610a93ecc1315dd89a17f0cd3"
integrity sha512-2qt6M9G5S3gPTTB/VG8KwhTtv5w9ZqedFvOQS7yBbHHyV4UEWSxijhqHinpbJs0iKOWRbsDGE+jtRdgq8Vu+ZQ==
dependencies:
protobufjs "6.8.8"
source-map-support "0.5.9"
tsutils "3.21.0"
"@bazel/esbuild@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/esbuild/-/esbuild-4.4.2.tgz#e1f35922cc9b63e96cc8c263a77b8e1b2938a445"
integrity sha512-P3cXIje01zsg3TMhTwwbA0sKldYa1J2EGVwahmOPfXlxewd+6cwjhQBQV8SSoxZeFLmCuoMu8eA++mnXgHzm2g==
"@bazel/esbuild@4.4.5":
version "4.4.5"
resolved "https://registry.yarnpkg.com/@bazel/esbuild/-/esbuild-4.4.5.tgz#17331868ac42f2d2c03afc776847dea2d0e650d4"
integrity sha512-CImfEr+1ecouGFVGgfCV6Zvx0I3Lw0abxkI8R3BmMleyQcLj8FejCGSFhxIJLKLuxGh/OJXjxoE+PAMTON4O9Q==
"@bazel/esbuild@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/esbuild/-/esbuild-4.4.6.tgz#20ae2b2b77ecf40e4a18f7e9627f3ca51e95784d"
integrity sha512-iI4GlfhZEzSWg1mqoYl6WfeDJ/xSkEb7V8XbVOtXrZ1NG35yU5eYDRlIODEhdVRu/QyAMdcCePDJfgHwAsYXLg==
"@bazel/ibazel@^0.15.8":
version "0.15.10"
resolved "https://registry.yarnpkg.com/@bazel/ibazel/-/ibazel-0.15.10.tgz#cf0cff1aec6d8e7bb23e1fc618d09fbd39b7a13f"
integrity sha512-0v+OwCQ6fsGFa50r6MXWbUkSGuWOoZ22K4pMSdtWiL5LKFIE4kfmMmtQS+M7/ICNwk2EIYob+NRreyi/DGUz5A==
"@bazel/jasmine@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/jasmine/-/jasmine-4.4.2.tgz#04fc413856984456525d3e2e3ebf7f308e915c54"
integrity sha512-r0ZUB//pRZnpXiy5keSt2vDQfV/3a9x/kar865CgMJRV+mVQsHMF4l72rQD8LPhGzx4QgX+yOWI2gpAq5E5/zQ==
"@bazel/jasmine@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/jasmine/-/jasmine-4.4.6.tgz#12d72d55c65b34bffeb1108f8081deaa9ef42ec2"
integrity sha512-9/oBxEIFImRa+j2YxTfgjsLB+4iz/3M2a7MUE1iKN07QwOVBmMoaP74WtJlNbw69SIxzyG8IdidXNL1sgtPPSA==
dependencies:
c8 "~7.5.0"
jasmine-reporters "~2.4.0"
"@bazel/jasmine@4.4.5":
version "4.4.5"
resolved "https://registry.yarnpkg.com/@bazel/jasmine/-/jasmine-4.4.5.tgz#e9540f0bffe286f23ce47ab59e6e015cc14c21af"
integrity sha512-BDWKtDmfux89TtWOhSMSuA01cdaNmdU9/8zrMNQopkTGDBmaDyPYvaxyhBAvQQLMiloOUBcS2eMO/fcSKRyg/A==
"@bazel/protractor@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/protractor/-/protractor-4.4.6.tgz#2ed9c3780caf741bbe6e6947bcb84635fe0aa2a1"
integrity sha512-jLg2FDf7pCx87P56+HFEdXmcACpHJiGvePnVhKohLs0QOj+SEi1hDz4YgUsTBmcxZOEftI/v0zmXwgi9FFZ8QA==
"@bazel/rollup@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/rollup/-/rollup-4.4.6.tgz#936d34c9c8159d42f84f1ac3c9ebb1bed27f691a"
integrity sha512-VujfM6QGuNpQZVzOf2nfAi3Xoi4EdA9nXXy6Gq4WiSaDPbgZrlXl/4Db+Hb6Nej5uvWqqppgvigCPHcWX9yM/w==
dependencies:
c8 "~7.5.0"
jasmine-reporters "~2.4.0"
"@bazel/worker" "4.4.6"
"@bazel/protractor@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/protractor/-/protractor-4.4.2.tgz#0d2b7ba2a003b30d54c1383b3de2e9f7d80642a5"
integrity sha512-mryiNMyQEEeMubjAM9yZpMIex388kvLxmfhhZpbePxLRG7Nm9Lr4C/+fn7iho3GDAPS04HggQLCYsYj+nQ9Rug==
"@bazel/runfiles@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/runfiles/-/runfiles-4.4.6.tgz#a96d8f655d9aa8e3f3b7ad94f2f28562d480b977"
integrity sha512-bVZ+nZQqpprt8BOcfz0P8Nljr0gEsSiw8HrA6E8bSc/nRK7s+PWk1uRxOvoHfTiyJeOW2uvh+pJ9uDYd0d71Ow==
"@bazel/protractor@4.4.5":
version "4.4.5"
resolved "https://registry.yarnpkg.com/@bazel/protractor/-/protractor-4.4.5.tgz#b406e85c3d59015e0895c00700396ddd0d58d755"
integrity sha512-pW4hwkpLpBYHGFp7CO+vHfUXkOoFJBh11+2zFUjEXPaCYAol78Zt2SUzWRYD14CVEDWhxJlI6kCRg7IxW7/S2w==
"@bazel/terser@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/terser/-/terser-4.4.6.tgz#7e1579078ab604a0b53135f43086c0a060c83804"
integrity sha512-mJKxI3Vinj5kPEXR+XZXch11T18D7nHBle4+pcVmh675xlXRVTTvptYf7Qm0x9FMdjq4D6d1gJOeyxjz8YKaIg==
"@bazel/rollup@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/rollup/-/rollup-4.4.2.tgz#a6e627acb8fa7fe031c0b671b704744cbd8a117f"
integrity sha512-zsmpBxlrCjt/LdZK3gp6fnMmVF2yFU7cjs8g9ZKnvZ6IUYBtjiq5TsQ0H/himg4gkqL14c6k8pTeBWILD/8iDg==
"@bazel/typescript@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/typescript/-/typescript-4.4.6.tgz#fbaac22460b3aa4a0961c6c657d239af8f895778"
integrity sha512-J205En8MjmnWSPnz4CqJm1x4mzcdWM+HvAsOzzVb0DHx86O+mjPFwqleeAtPGLTE9aWskel81XICJfEuTlNtiw==
dependencies:
"@bazel/worker" "4.4.2"
"@bazel/runfiles@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/runfiles/-/runfiles-4.4.2.tgz#9d424f0f9ad7505d2ff2f854a450b986e132ac8e"
integrity sha512-Om8T+Chx//6DoxghILc6tUXtXkotvO3I5loNpU76OTf9tgiIZ9wlDtgHkaXxthoe0cYLZFai6GCaKFPyAL+ztw==
"@bazel/runfiles@4.4.5":
version "4.4.5"
resolved "https://registry.yarnpkg.com/@bazel/runfiles/-/runfiles-4.4.5.tgz#bbf112e882ea37d88f02009bb7cb661ac8908742"
integrity sha512-tFua24Ra/AI/K2di3sD03gzqG1uf9ziL+gSyc9dwjx9De1z4Fgafnqul9zXf1gqjEdWdJhZYXbntYmyj76BZNw==
"@bazel/terser@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/terser/-/terser-4.4.2.tgz#8513730f81388a2434deaf466eeb10cdb9027b6f"
integrity sha512-+eQV6S5qMSy4D5Sm4k/7WrZ9mUP2MiKgWomD4aJfYgv0ME2kkGuOk1QBK055NjBF+Fop5GUKZe0OJM3VFRg01g==
"@bazel/typescript@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/typescript/-/typescript-4.4.2.tgz#987000806043d9df1388debcd576420ce5b8c860"
integrity sha512-dTt/AvlnwWiUXF7T25FpAozmLKN9Z+me07iSOcjDv7+6aVcxV5vJTbhpktZO1Ij0oSaYew4I8e/NlRf/mS2k7g==
dependencies:
"@bazel/worker" "4.4.2"
"@bazel/worker" "4.4.6"
protobufjs "6.8.8"
semver "5.6.0"
source-map-support "0.5.9"
tsutils "3.21.0"
"@bazel/typescript@4.4.5":
version "4.4.5"
resolved "https://registry.yarnpkg.com/@bazel/typescript/-/typescript-4.4.5.tgz#0b323a292910dbfdc5f90312377e9282c73035f0"
integrity sha512-Cgq7ZXGkFPAAOn2t9C9JWIDkSjDKB7AkwNgXEwrPwpchKgdoCcD1uMieiErfwBB0FWgJF1xvwwLGOnWA6E/G0A==
dependencies:
"@bazel/worker" "4.4.5"
protobufjs "6.8.8"
semver "5.6.0"
source-map-support "0.5.9"
tsutils "3.21.0"
"@bazel/worker@4.4.2":
version "4.4.2"
resolved "https://registry.yarnpkg.com/@bazel/worker/-/worker-4.4.2.tgz#01dcfa873786d4ad0b7150b8f9d03a23aa0c19e4"
integrity sha512-EkxgsV2o6nPd/+ujnyCuKU3C57sjYDdtQVPLdBBIiOmx37RPBw+tRMrp6XYgU3PkhqgMqNQPpS/9Exbj0XSihQ==
dependencies:
google-protobuf "^3.6.1"
"@bazel/worker@4.4.5":
version "4.4.5"
resolved "https://registry.yarnpkg.com/@bazel/worker/-/worker-4.4.5.tgz#1f9292c31615dff8a7297960f7f520bf9febf428"
integrity sha512-PoBMiN0SGSb1Qn/SabiM9HWC5nqwyWn0yTJgz6Vq2GMHo1UG7olVHuIfDb2ScFx9jY+mJ3wSyxQ4htlTGldedA==
"@bazel/worker@4.4.6":
version "4.4.6"
resolved "https://registry.yarnpkg.com/@bazel/worker/-/worker-4.4.6.tgz#c9122c8ec765f62dc723203270a3c913caf8826a"
integrity sha512-1Sk0FGIc1m9rFwXhCnm46XDRng88vAnY1FBb7OQPonha/kuxjZTpPDP7q2ndSkqDNyCFKp94cPUFUT58Fgqvfw==
dependencies:
google-protobuf "^3.6.1"
@@ -1455,6 +1415,15 @@
"@microsoft/tsdoc-config" "~0.15.2"
"@rushstack/node-core-library" "3.43.2"
"@microsoft/api-extractor-model@7.15.1":
version "7.15.1"
resolved "https://registry.yarnpkg.com/@microsoft/api-extractor-model/-/api-extractor-model-7.15.1.tgz#e52d68676e846d8b86e3b18e2654af39fba6e4a1"
integrity sha512-DWfS1o3oMY0mzdO3OuQbD/9vzn80jwM6tFd7XbiYnkpxwhD83LMGXz7NZWwSh+IaA+9w3LF4w62fT31Qq+dAMw==
dependencies:
"@microsoft/tsdoc" "0.13.2"
"@microsoft/tsdoc-config" "~0.15.2"
"@rushstack/node-core-library" "3.44.2"
"@microsoft/api-extractor@7.18.19":
version "7.18.19"
resolved "https://registry.yarnpkg.com/@microsoft/api-extractor/-/api-extractor-7.18.19.tgz#f09afc1c210aa67e2f3f34b0a68281a12f144541"
@@ -1473,6 +1442,24 @@
source-map "~0.6.1"
typescript "~4.4.2"
"@microsoft/api-extractor@7.19.2":
version "7.19.2"
resolved "https://registry.yarnpkg.com/@microsoft/api-extractor/-/api-extractor-7.19.2.tgz#8c546003523163c1432f6e19506065f790d6182c"
integrity sha512-LxSa9lwp7eYtM4i5y/1n79QpotPKlmpCrVQbkb0LAHE1sCRHpZDTb6p3cMJthDhYPMjAYKOLfq639GwtZrg23Q==
dependencies:
"@microsoft/api-extractor-model" "7.15.1"
"@microsoft/tsdoc" "0.13.2"
"@microsoft/tsdoc-config" "~0.15.2"
"@rushstack/node-core-library" "3.44.2"
"@rushstack/rig-package" "0.3.6"
"@rushstack/ts-command-line" "4.10.5"
colors "~1.2.1"
lodash "~4.17.15"
resolve "~1.17.0"
semver "~7.3.0"
source-map "~0.6.1"
typescript "~4.5.2"
"@microsoft/tsdoc-config@~0.15.2":
version "0.15.2"
resolved "https://registry.yarnpkg.com/@microsoft/tsdoc-config/-/tsdoc-config-0.15.2.tgz#eb353c93f3b62ab74bdc9ab6f4a82bcf80140f14"
@@ -1488,10 +1475,10 @@
resolved "https://registry.yarnpkg.com/@microsoft/tsdoc/-/tsdoc-0.13.2.tgz#3b0efb6d3903bd49edb073696f60e90df08efb26"
integrity sha512-WrHvO8PDL8wd8T2+zBGKrMwVL5IyzR3ryWUsl0PXgEV0QHup4mTLi0QcATefGI6Gx9Anu7vthPyyyLpY0EpiQg==
"@ngtools/webpack@13.0.3":
version "13.0.3"
resolved "https://registry.yarnpkg.com/@ngtools/webpack/-/webpack-13.0.3.tgz#ec31dfa49dae79aeee68cc970fea6f5fd9ebc76d"
integrity sha512-sVi1Xk8pyy6Y6JODySucYfvuxb5k3IIX/oIWy8QxlFVzpeB2UMqEOevrgvtmiEbQNB1W+aYSTph6oeV+PRX5YA==
"@ngtools/webpack@13.0.4":
version "13.0.4"
resolved "https://registry.yarnpkg.com/@ngtools/webpack/-/webpack-13.0.4.tgz#9389c95fdbefb48fe061a30d81aab2f83bbf2081"
integrity sha512-kH0kYOQvbv6SnVdcdi21AbJo17H1HSGlCy/8C1ujLdgtT6enKMnx9onYIoZSmb5U98GqYc+DV/W0HwpHwRcOoQ==
"@nicolo-ribaudo/chokidar-2@2.1.8-no-fsevents.3":
version "2.1.8-no-fsevents.3"
@@ -1867,6 +1854,21 @@
timsort "~0.3.0"
z-schema "~3.18.3"
"@rushstack/node-core-library@3.44.2":
version "3.44.2"
resolved "https://registry.yarnpkg.com/@rushstack/node-core-library/-/node-core-library-3.44.2.tgz#4fcd8f76887ae5968f2796f633a7e48f5ebd2271"
integrity sha512-lQ8Ct267UKkNSJSDxpBWn7SyyITWQ9l3Xqww0V+YY0rMt02r9eiGvwwPaU1ugJW7IMVo6r/HXvgbmpOSPyzGyg==
dependencies:
"@types/node" "12.20.24"
colors "~1.2.1"
fs-extra "~7.0.1"
import-lazy "~4.0.0"
jju "~1.4.0"
resolve "~1.17.0"
semver "~7.3.0"
timsort "~0.3.0"
z-schema "~5.0.2"
"@rushstack/rig-package@0.3.5":
version "0.3.5"
resolved "https://registry.yarnpkg.com/@rushstack/rig-package/-/rig-package-0.3.5.tgz#7ddab0994647837bab8fdef26f990f1774d82e78"
@@ -1875,6 +1877,14 @@
resolve "~1.17.0"
strip-json-comments "~3.1.1"
"@rushstack/rig-package@0.3.6":
version "0.3.6"
resolved "https://registry.yarnpkg.com/@rushstack/rig-package/-/rig-package-0.3.6.tgz#a57b53db59106fb93bcda36cad4f8602f508ebc6"
integrity sha512-H/uFsAT6cD4JCYrlQXYMZg+wPVECByFoJLGqfGRiTwSS5ngQw9QxnFV2mPG2LrxFUsMjLQ2lsrYr523700XzfA==
dependencies:
resolve "~1.17.0"
strip-json-comments "~3.1.1"
"@rushstack/ts-command-line@4.10.4":
version "4.10.4"
resolved "https://registry.yarnpkg.com/@rushstack/ts-command-line/-/ts-command-line-4.10.4.tgz#05142b74e5cb207d3dd9b935c82f80d7fcb68042"
@@ -1885,13 +1895,23 @@
colors "~1.2.1"
string-argv "~0.3.1"
"@schematics/angular@13.0.3":
version "13.0.3"
resolved "https://registry.yarnpkg.com/@schematics/angular/-/angular-13.0.3.tgz#08c5511b0e72a9934ac84545d3e49e05bd0dbf6c"
integrity sha512-qH6mnmGaDCuG1FM3vLdvSFDG394TeZO0ZvRDrw3iCYlX5Nkbz0Kvt0MPtWNZmlohwFhGlbXKVQiR++1dxa6eEA==
"@rushstack/ts-command-line@4.10.5":
version "4.10.5"
resolved "https://registry.yarnpkg.com/@rushstack/ts-command-line/-/ts-command-line-4.10.5.tgz#a31a44ddd24fe3a594e4ad91c22f3ea7668b43a9"
integrity sha512-5fVlTDbKsJ5WyT6L7NrnOlLG3uoITKxoqTPP2j0QZEi95kPbVT4+VPZaXXDJtkrao9qrIyig8pLK9WABY1bb3w==
dependencies:
"@angular-devkit/core" "13.0.3"
"@angular-devkit/schematics" "13.0.3"
"@types/argparse" "1.0.38"
argparse "~1.0.9"
colors "~1.2.1"
string-argv "~0.3.1"
"@schematics/angular@13.0.4":
version "13.0.4"
resolved "https://registry.yarnpkg.com/@schematics/angular/-/angular-13.0.4.tgz#e7efd26bf24abc359c902c4576451f988cc8582a"
integrity sha512-P9F5c8ApLbEyfNO4TZNsTyAdrtOjwIhrM/P+eEC4/x6nklWlEFE6TGMYTNjiK/RRhkbX1tBs8gcdJLYxtEqPSg==
dependencies:
"@angular-devkit/core" "13.0.4"
"@angular-devkit/schematics" "13.0.4"
jsonc-parser "3.0.0"
"@sindresorhus/is@^0.14.0":
@@ -7214,40 +7234,40 @@ google-auth-library@^7.0.0, google-auth-library@^7.6.1:
jws "^4.0.0"
lru-cache "^6.0.0"
google-closure-compiler-java@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-java/-/google-closure-compiler-java-20211006.0.0.tgz#d3ccbbfa349f2ffff5e623d45e7798cfe8e450c4"
integrity sha512-ggvk48GuP5Y8TD1I9dcJTu50+BQ2AfroAAsTV7nnbKdEPCZ/XJmGqy5qrJk0ImdAvONUHZETc5DMHHgFI5WjMg==
google-closure-compiler-java@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-java/-/google-closure-compiler-java-20211201.0.0.tgz#41eb570189ad35d9b09a2331e37157951dd99e75"
integrity sha512-TQop4dF0k/mb9sPu0aZsvW8OVfuZG4+t4ITZeA/u43deiAA4AFScZQQUMUmoVmXzR8Jz0eeucKoZPTwKAwcSmQ==
google-closure-compiler-linux@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-linux/-/google-closure-compiler-linux-20211006.0.0.tgz#471eef6600a682d6cf95fc3218f9d925bcedb6b7"
integrity sha512-7FclqwRDHcx9zvoy1JCQB3DC84T0anyOsb5kNIZgIf/oaUCvq27ElJK1X7W6IenOcwYyvDDWeDb38YkWl15ANw==
google-closure-compiler-linux@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-linux/-/google-closure-compiler-linux-20211201.0.0.tgz#6f84f745d9c0f79677b270cc3007d70ce4a741e1"
integrity sha512-7nMgBFZYYQTvDLcO+LqqwtibgZJu8qaFJbK84T12xneY1Yy1fUSn56NXaZ9cgdS7p30Hqy6tYcw9ZSuxK7fuEA==
google-closure-compiler-osx@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-osx/-/google-closure-compiler-osx-20211006.0.0.tgz#6e74c82b9c167e34319bf67e93201bcde0a91169"
integrity sha512-b0FGLvYZuMbDoLcu5z1lw0nWigpT8G29acuh4Yz6zO4NFq1aCpyR1X+BPhC2KCxb2eaMWPx2xoxbsekhkU0VzQ==
google-closure-compiler-osx@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-osx/-/google-closure-compiler-osx-20211201.0.0.tgz#9ba8231a68cfaacc02d47367af43171a383dbe96"
integrity sha512-eJKmvYm5C82BAcfK64/7nR3RbR4bwIXO2Dmhmb5AR6FXxD/J1svaG3BMINlS+U/GT7NeV4Z7bKb2TcPIAfGO9A==
google-closure-compiler-windows@^20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-windows/-/google-closure-compiler-windows-20211006.0.0.tgz#ae88366bfce882e6d524a0dd35bb1a5681c31172"
integrity sha512-7P13hA42LWIm4o+speQC5Yhs3D+3q9nvuItOxLCzess1sPDeBKi5dQi3w+C2MBTDyVN0CTKL86iClyyOnrbuRQ==
google-closure-compiler-windows@^20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler-windows/-/google-closure-compiler-windows-20211201.0.0.tgz#e81c1b2d68df5730065c08cd80daed84bf0013fc"
integrity sha512-OPZYA0+tJSjutt1EYrECmXChNsY5USoMbQkBEmwI29riVvNnK5Ot+/SE66/NPHwm3qI/p3O7TnOTKhVpXKed5Q==
google-closure-compiler@20211006.0.0:
version "20211006.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler/-/google-closure-compiler-20211006.0.0.tgz#0c26abc40b30f989a913ead39d3b6d2099cf4e7a"
integrity sha512-WrzPLGtNMtgPubcvSur8JzzpuNn4feS7OMF74Hsm00G0qpdNvBVCIkMpnLr9SPZnl2vZ8UVqt83XVXMpQRTkUw==
google-closure-compiler@20211201.0.0:
version "20211201.0.0"
resolved "https://registry.yarnpkg.com/google-closure-compiler/-/google-closure-compiler-20211201.0.0.tgz#e767dc74b72b1d9b2203450185120abcb9278d5f"
integrity sha512-QPNp6uHR94EKbi17XCsdISHAqIgk1Ep7LpB+rmPDY7VoNAX4784WT/0bz6HyVK4QYRVLlNAy2X+1+VlFhS0FzQ==
dependencies:
chalk "2.x"
google-closure-compiler-java "^20211006.0.0"
google-closure-compiler-java "^20211201.0.0"
minimist "1.x"
vinyl "2.x"
vinyl-sourcemaps-apply "^0.2.0"
optionalDependencies:
google-closure-compiler-linux "^20211006.0.0"
google-closure-compiler-osx "^20211006.0.0"
google-closure-compiler-windows "^20211006.0.0"
google-closure-compiler-linux "^20211201.0.0"
google-closure-compiler-osx "^20211201.0.0"
google-closure-compiler-windows "^20211201.0.0"
google-gax@^2.24.1:
version "2.28.0"
@@ -9252,7 +9272,7 @@ lodash.flatten@^4.4.0:
resolved "https://registry.yarnpkg.com/lodash.flatten/-/lodash.flatten-4.4.0.tgz#f31c22225a9632d2bbf8e4addbef240aa765a61f"
integrity sha1-8xwiIlqWMtK7+OSt2+8kCqdlph8=
lodash.get@^4.0.0:
lodash.get@^4.0.0, lodash.get@^4.4.2:
version "4.4.2"
resolved "https://registry.yarnpkg.com/lodash.get/-/lodash.get-4.4.2.tgz#2d177f652fa31e939b4438d5341499dfa3825e99"
integrity sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk=
@@ -9277,7 +9297,7 @@ lodash.isboolean@^3.0.3:
resolved "https://registry.yarnpkg.com/lodash.isboolean/-/lodash.isboolean-3.0.3.tgz#6c2e171db2a257cd96802fd43b01b20d5f5870f6"
integrity sha1-bC4XHbKiV82WgC/UOwGyDV9YcPY=
lodash.isequal@^4.0.0:
lodash.isequal@^4.0.0, lodash.isequal@^4.5.0:
version "4.5.0"
resolved "https://registry.yarnpkg.com/lodash.isequal/-/lodash.isequal-4.5.0.tgz#415c4478f2bcc30120c22ce10ed3226f7d3e18e0"
integrity sha1-QVxEePK8wwEgwizhDtMib30+GOA=
@@ -12455,10 +12475,10 @@ rollup-plugin-terser@^7.0.1:
serialize-javascript "^4.0.0"
terser "^5.0.0"
rollup@2.60.0:
version "2.60.0"
resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.60.0.tgz#4ee60ab7bdd0356763f87d7099f413e5460fc193"
integrity sha512-cHdv9GWd58v58rdseC8e8XIaPUo8a9cgZpnCMMDGZFDZKEODOiPPEQFXLriWr/TjXzhPPmG5bkAztPsOARIcGQ==
rollup@2.60.1:
version "2.60.1"
resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.60.1.tgz#4b34cd247f09b421f10a3c9286eda2ecf9972079"
integrity sha512-akwfnpjY0rXEDSn1UTVfKXJhPsEBu+imi1gqBA1ZkHGydUnkV/fWCC90P7rDaLEW8KTwBcS1G3N4893Ndz+jwg==
optionalDependencies:
fsevents "~2.3.2"
@@ -12471,10 +12491,10 @@ rollup@~1.11.3:
"@types/node" "^11.13.9"
acorn "^6.1.1"
rollup@~2.59.0:
version "2.59.0"
resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.59.0.tgz#108c61b0fa0a37ebc8d1f164f281622056f0db59"
integrity sha512-l7s90JQhCQ6JyZjKgo7Lq1dKh2RxatOM+Jr6a9F7WbS9WgKbocyUSeLmZl8evAse7y96Ae98L2k1cBOwWD8nHw==
rollup@~2.61.0:
version "2.61.1"
resolved "https://registry.yarnpkg.com/rollup/-/rollup-2.61.1.tgz#1a5491f84543cf9e4caf6c61222d9a3f8f2ba454"
integrity sha512-BbTXlEvB8d+XFbK/7E5doIcRtxWPRiqr0eb5vQ0+2paMM04Ye4PZY5nHOQef2ix24l/L0SpLd5hwcH15QHPdvA==
optionalDependencies:
fsevents "~2.3.2"
@@ -14111,7 +14131,7 @@ typescript@3.2.4:
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.2.4.tgz#c585cb952912263d915b462726ce244ba510ef3d"
integrity sha512-0RNDbSdEokBeEAkgNbxJ+BLwSManFy9TeXz8uW+48j/xhEXv1ePME60olyzw2XzUqUBNAYFeJadIqAgNqIACwg==
typescript@4.4.4, typescript@~4.4.0, typescript@~4.4.2:
typescript@4.4.4, typescript@~4.4.2:
version "4.4.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.4.tgz#2cd01a1a1f160704d3101fd5a58ff0f9fcb8030c"
integrity sha512-DqGhF5IKoBl8WNf8C1gu8q0xZSInh9j1kJJMqT3a94w1JzVaBU4EXOSMrz9yDqMT0xt3selp83fuFMQ0uzv6qA==
@@ -14121,7 +14141,7 @@ typescript@^3.9.5, typescript@^3.9.7:
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.9.10.tgz#70f3910ac7a51ed6bef79da7800690b19bf778b8"
integrity sha512-w6fIxVE/H1PkLKcCPsFqKE7Kv7QUwhU8qQY2MueZXWx5cPZdwFupLgKK3vntcK98BtNHZtAF4LA/yl2a7k8R6Q==
typescript@~4.5.2:
typescript@~4.5.0, typescript@~4.5.2:
version "4.5.2"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.5.2.tgz#8ac1fba9f52256fdb06fb89e4122fa6a346c2998"
integrity sha512-5BlMof9H1yGt0P8/WF+wPNw6GfctgGjXp5hkblpyT+8rkASSmkUKMXrxR0Xg8ThVCi/JnHQiKXeBaEwCeQwMFw==
@@ -14479,6 +14499,11 @@ validate-npm-package-name@^3.0.0:
dependencies:
builtins "^1.0.3"
validator@^13.7.0:
version "13.7.0"
resolved "https://registry.yarnpkg.com/validator/-/validator-13.7.0.tgz#4f9658ba13ba8f3d82ee881d3516489ea85c0857"
integrity sha512-nYXQLCBkpJ8X6ltALua9dRrZDHVYxjJ1wgskNt1lH9fzGjs3tgojGSCBjmEPwkWS1y29+DrizMTW19Pr9uB2nw==
validator@^8.0.0:
version "8.2.0"
resolved "https://registry.yarnpkg.com/validator/-/validator-8.2.0.tgz#3c1237290e37092355344fef78c231249dab77b9"
@@ -15132,6 +15157,17 @@ z-schema@~3.18.3:
optionalDependencies:
commander "^2.7.1"
z-schema@~5.0.2:
version "5.0.2"
resolved "https://registry.yarnpkg.com/z-schema/-/z-schema-5.0.2.tgz#f410394b2c9fcb9edaf6a7511491c0bb4e89a504"
integrity sha512-40TH47ukMHq5HrzkeVE40Ad7eIDKaRV2b+Qpi2prLc9X9eFJFzV7tMe5aH12e6avaSS/u5l653EQOv+J9PirPw==
dependencies:
lodash.get "^4.4.2"
lodash.isequal "^4.5.0"
validator "^13.7.0"
optionalDependencies:
commander "^2.7.1"
zip-stream@^4.1.0:
version "4.1.0"
resolved "https://registry.yarnpkg.com/zip-stream/-/zip-stream-4.1.0.tgz#51dd326571544e36aa3f756430b313576dc8fc79"