Commit graph

20926 commits

Author SHA1 Message Date
wagnermaciel
28ee9864a4 fix(benchpress): update the check for start and end events (#42085)
* recently, performance events started showing up with a -bpstart and -bpend
  suffix to indicate their being the start and end events for our performance
  testing. to fix this, we added an additional check for those suffixes in
  addition to the old checks.

PR Close #42085
2021-05-13 17:01:25 -07:00
Renovate Bot
c2bcf6c9e6 build: update angular (#42035)
Merge conflicts in yarn.lock and aio/yarn.lock were resolved manually by
@alxhub (by running `yarn` to update the lockfiles instead of guessing at
conflict resolution).

PR Close #42035
2021-05-13 16:32:13 -04:00
Dylan Hunn
9b90c03a9f fix(forms): registerOnValidatorChange should be called for ngModelGroup. (#41971)
The Validator and AsyncValidator interfaces provide a callback, `registerOnValidatorChange(fn)`. `registerOnValidatorChange` is supposed to be fired at least once to register `fn` with the validator. `fn` is then called by the validator whenever its inputs change. This was previously not happening for FormGroup validators, and is now fixed.

PR Close #41971
2021-05-13 13:57:47 -04:00
George Kalpakas
03dcdbd788 build(docs-infra): upgrade cli command docs sources to 88d955627 (#42039)
Updating [angular#12.0.x](https://github.com/angular/angular/tree/12.0.x) from
[cli-builds#12.0.x](https://github.com/angular/cli-builds/tree/12.0.x).

##
Relevant changes in
[commit range](0f1fe9a4d...88d955627):

**Modified**
- help/update.json

PR Close #42039
2021-05-13 13:53:53 -04:00
George Kalpakas
1f4b9293a5 docs: change updating-to-version-* redirects to point to the respective versions (#42019)
Previously, the `updating-to-version-*` URLs would redirect to the next
version update guide. More specifically:
- `/guide/updating-to-version-10` --> `https://v11.angular.io/guide/updating-to-version-11`
- `/guide/updating-to-version-11` --> `/guide/updating-to-version-12`

This seems confusing and inconsistent. Either all URLs should redirect
to the latest update guide (currently `/guide/updating-to-version-12`)
or each URL should redirect to the corresponding version.

This commit implements the second approach:
- `/guide/updating-to-version-10` --> `https://v10.angular.io/guide/updating-to-version-10`
- `/guide/updating-to-version-11` --> `https://v11.angular.io/guide/updating-to-version-11`

PR Close #42019
2021-05-13 13:48:57 -04:00
Renovate Bot
30c5d2714d build: update dependency google-closure-compiler to v20210505 (#41980)
PR Close #41980
2021-05-13 13:32:55 -04:00
mgechev
8022e2d007 docs: add link to the blog post in the changelog (#42072)
PR Close #42072
2021-05-12 20:47:28 -04:00
mgechev
875598e292 docs: update the angular roadmap (#42050)
Update the Angular roadmap to reflect efforts in Q2 2021.

PR Close #42050
2021-05-12 20:46:34 -04:00
mgechev
1c5172eeac docs: update the angular roadmap (#42050)
Update the Angular roadmap to reflect efforts in Q2 2021.

PR Close #42050
2021-05-12 20:46:34 -04:00
Alex Rickabaugh
751491701e build(docs-infra): update docs examples to Angular v12.0.0 (#42071)
This commit updates the example boilerplate to Angular v12.0.0. The
[diff](https://github.com/cexbrayat/angular-cli-diff/compare/11.2.11...12.0.0)
is fairly trivial and the migrations did not produce any code changes.

PR Close #42071
2021-05-12 19:37:16 -04:00
Alex Rickabaugh
564ebacbfc docs: update CHANGELOG for v12.0.0 to include changes from -next releases
These were omitted during the synthesis of the initial CHANGELOG for this
release.
2021-05-12 17:09:40 -04:00
Alex Rickabaugh
0a2191f8e7 Revert "refactor(core): optimize calls to split and slice while computing version parts (#41208)"
This reverts commit 744bd2b64f.

This commit seems to cause issues in Safari.
2021-05-12 14:24:15 -04:00
Alex Rickabaugh
52cd8c928a release: cut the v12.0.0 release (#42065)
PR Close #42065
2021-05-12 13:32:32 -04:00
Alex Rickabaugh
1f84ac1d5f release: cut the v12.0.0-rc.3 release (#42031)
PR Close #42031
2021-05-10 17:47:57 -04:00
JoostK
d5555558d0 fix(platform-browser): prevent memory leak of style nodes if shadow DOM encapsulation is used (#42005)
Prior to this change, any inserted `<style>` nodes into shadow dom trees would be retained
in memory, even after the shadow dom tree has been removed. This commit fixes the memory
leak by tracking the inserted `<style>` nodes per host element, such that removal of the
host element also releases the style nodes.

Fixes #36655

PR Close #42005
2021-05-10 16:12:22 -04:00
iRealNirmal
150b2ece1d build(docs-infra): fixed i18n broken stackblitz example (#42001)
This commit fixes the broken stackblitz example of i18n.

Closes #41838.

PR Close #42001
2021-05-10 16:11:38 -04:00
Pete Bacon Darwin
a4e03d3f7a build(docs-infra): show a dist-tag when installing the CLI on non-stable versions (#41991)
It is important to use the correct major version of the Angular CLI when
following the examples in the tutorials. This commit provides a custom
element that renders an appropriate dist-tag in the setup step of
the tutorial when the docs are not in "stable" mode.

Fixes #39821

PR Close #41991
2021-05-10 16:10:34 -04:00
Igor Minar
d43e3515e1 docs: clarify the IE11 deprecation timeline, and link to the RFC (#42023)
PR Close #42023
2021-05-10 12:41:59 -04:00
Alan Agius
b6de210feb test: refactor test to work with latest @types/jasmine (#41956) (#42024)
In some cases we are using private APIs. This change adds casting were needed to make the build successful.

PR Close #41956

PR Close #42024
2021-05-10 12:34:46 -04:00
Renovate Bot
c909bb8f57 build: update all non-major dependencies (#41956) (#42024)
Manually merged from PR #41956 to 12.0.x, resolving a simple conflict in
`packages/localize/package.json`.

PR Close #42024
2021-05-10 12:34:46 -04:00
Richard Sithole
388f4056e6 docs: fix a grammatical error in lazy-loading-ngmodules guide (#42008)
PR Close #42008
2021-05-10 11:53:20 -04:00
Ajit Singh
cffba6fa0b build: update node version to stop aio from breaking while generating docs (#42009)
When aio yarn docs-only command runs on v12.14.1 it fails details given on issue #41979. Upgrading node version to v12.17.0 solves this but creates a new warning (node:467072) ExperimentalWarning: The ESM module loader is experimental.
This warning gets removed in v12.20.0. Upgrading node version to 12.20.0

PR Close #42009
2021-05-10 10:39:39 -04:00
JoostK
1449c5c8ff fix(core): do not retain dynamically compiled components and modules (#42003)
The JIT compiler has a mapping from component to the owning NgModule
and tracks whether a certain NgModule class has been verified; these
maps causes any JIT compiled component and NgModule to be retained even
if they are no longer referenced from anywhere else. This commit
switches the maps to `WeakMap` to allow garbage collecting any
components and NgModules that are no longer referenced elsewhere.

Fixes #19997

PR Close #42003
2021-05-10 10:36:24 -04:00
Pete Bacon Darwin
b99520101f refactor(compiler-cli): remove redundant potentialSourceMapUrl property (#42000)
Now that there is no need to work around the source-map bug in TypeScript
(https://github.com/Microsoft/TypeScript/issues/29300) we can just use
`resolvedTemplateUrl` for the source-map URL, rather than having a separate
property.

PR Close #42000
2021-05-10 10:33:28 -04:00
Pete Bacon Darwin
876069ee94 docs(compiler-cli): fix typo (#42000)
PR Close #42000
2021-05-10 10:33:28 -04:00
Pete Bacon Darwin
007ffd3374 refactor(compiler-cli): remove unused import (#42000)
The `makeDiagnostic()` function is not used in this file.

PR Close #42000
2021-05-10 10:33:27 -04:00
Pete Bacon Darwin
b575707ef2 refactor(compiler-cli): remove TS bug workaround (#42000)
The TS bug at https://github.com/Microsoft/TypeScript/issues/29300 was
fixed in TS 3.3, so the workaround is no longer required.

PR Close #42000
2021-05-10 10:33:27 -04:00
Teri Glover
4f4880b17f docs: Edited to remove jargon (#41976)
PR Close #41976
2021-05-10 10:29:39 -04:00
Pete Bacon Darwin
effde9d1bf refactor(core): remove unnecessary cast (#41960)
The `as any` is no longer needed since `providedIn` can accept `'any'`.

PR Close #41960
2021-05-10 10:28:35 -04:00
Pete Bacon Darwin
04450b48c5 refactor(docs-infra): remove unused CSS rule (#41960)
The `.ngmodule-iist` is no longer used so can be removed.

PR Close #41960
2021-05-10 10:28:34 -04:00
Pete Bacon Darwin
26a1197bc7 build(docs-infra): add NgModules references to provided injectables (#41960)
Parse the `providers` property of each NgModule doc and add this doc to
the `ngModules` property of each provided injectable.

PR Close #41960
2021-05-10 10:28:34 -04:00
Pete Bacon Darwin
bb55ec4f56 build(docs-infra): associate providedIn injectables with their NgModule (#41960)
Such injectables were not appearing in the providers lists of their NgModule.
This commit updates the doc-gen to support associating these automatically.
Further, it also allows developers to mark other injectables that are provided
in an NgModule with a reference to the NgModule where they are provided.

The commit also does a refactoring of the `processNgModuleDocs` dgeni
processor code, to make it easier to maintain.

Fixes #41203

PR Close #41960
2021-05-10 10:28:34 -04:00
Andrew J Asche
a8dd75879a fix(docs-infra): update glossary to include the term template-input-variable (#41632)
Template input variables are now described in the glossary.

PR Close #41632
2021-05-10 10:27:57 -04:00
Julien Marcou
6bec2d47f3 refactor(core): optimize calls to split and slice while computing version parts (#41208)
Reduce the number of calls made to `split` and `slice` while computing version parts by deconstructing the result.

PR Close #41208
2021-05-10 10:26:37 -04:00
Julien Marcou
e3bb6fcd82 docs: fix package name in version.ts files in different packages (#41208)
PR Close #41208
2021-05-10 10:26:37 -04:00
Alex Rickabaugh
7a4d9805ea fix(compiler-cli): use '' for the source map URL of indirect templates (#41973)
Indirect templates are templates produced by a non-literal expression value
of the `template` field in `@Component`. The compiler can statically
determine the template string, but there is not guaranteed to be a physical
file which contains the bytes of the template string. For example, the
template string may be computed by a concatenation expression: 'a' + 'b'.

Previously, the compiler would use the TS file path as the source map path
for indirect templates. This is incorrect, however, and breaks source
mapping for such templates, since the offsets within the template string do
not correspond to bytes of the TS file.

This commit returns the compiler to its old behavior for indirect templates,
which is to use `''` as the source map URL for such templates.

Fixes #40854

PR Close #41973
2021-05-07 15:46:21 -04:00
Paul Gschwendtner
c580fbb60c fix(dev-infra): merge tool should ensure that token has workflow oauth scope (#41989)
Currently if a PR modifies any file that configures a Github action
(e.g. a workflow file), the caretaker might face an error when merging
such PR:

```
! [remote rejected]       merge_pr_target_11.2.x -> 11.2.x (refusing to allow a Personal Access Token to create or update workflow
```

This happens because Github requires the token being used for the
push operation to have the `workflow` scope set. This is a special
scope added by Github to ensure that no changes can be made on
upstream branches that might expose the `GITHUB_TOKEN` environment
variable, which is available for push builds and could cause the
token being leaked.

With this commit we enforce that the caretaker adds the workflow
scope to their github token. Since PRs can only be merged if reviewed
thoroughly, it's acceptable to allow workflow file changes being
merged through the merge tool by the caretaker (especially since we
also allow CircleCI config files being merged with the default
`repo`/`public_repo` scope).

PR Close #41989
2021-05-07 14:10:40 -04:00
Pete Bacon Darwin
89c02980ae build(docs-infra): ensure that terminal code snippets render correctly (#41986)
After the changes to the `lang-none` styling in #41335, code snippets marked with

```
language="none" class="code-shell"
```

were being styled with the same foreground and background colours.

It turns out that most of these ought to be marked `language="sh"`
in which case the `code-shell` style became redundant and has been
removed.

Fixes #41984

PR Close #41986
2021-05-07 13:11:05 -04:00
Joey Perrott
d6c217b777 fix(dev-infra): set the default LogLevel of GitClient logging to DEBUG (#41899)
Previously by default GitClient would log the commands it was executing at the
INFO level. This change moves the default level of this logging to DEBUG, while
still allowing callers of the methods to set the log level back to INFO.

PR Close #41899
2021-05-07 10:15:21 -04:00
profanis
c38dce7d7a docs: change the documentation of creating-libraries by providing material links (#41982)
while reading the documentation, I noticed that there were
references in the material's documentation. Since the
links were absent, I had to google the terms and
continue my study. I find it easier for the reader not
to be distracted by googling, but just clicking
and following the suggested links

PR Close #41982
2021-05-07 10:11:11 -04:00
mgechev
afb036309a ci: introduce action implementing feature request prioritization process (#41975)
Enable a GitHub action that implements our new feature request
[process](ce8e011a9f/docs/GITHUB_PROCESS.md (feature-request-process)).

As a prerequisite, we need to create the following labels:
- `in backlog`
- `votes required`
- `under consideration`
- `insufficient votes`

The bot will also use the existing `feature` label to identify feature
requests.

With its current configuration, we need to kick the process off
manually. We currently also have a limit, meaning the bot will process
only 50 feature requests before it exits. Additionally, now the bot will
not close issues, it'll just comment on them and if they have an
insufficient number of votes, the bot will label them with `insufficient
votes`.

On the next iteration, we can:
- Expand the limit from 50 to infinity (removing the option from the
yml file)
- Set a cron configuration to kick off the bot automatically
- Enable autoclose by setting the `close-when-no-sufficient-votes` to
`true`

PR Close #41975
2021-05-07 10:09:47 -04:00
mgechev
e9ddc57f94 fix(core): invoke profiler around ngOnDestroy lifecycle hooks (#41969)
Invoke the profiler for `ngOnDestroy` lifecycle hooks for services,
components, directives, and pipes.

PR Close #41969
2021-05-07 10:04:24 -04:00
Renovate Bot
921703f388 build: update angular (#41955)
PR Close #41955
2021-05-07 10:03:37 -04:00
Joey Perrott
51cc14292d docs: reword a few phrases in the GITHUB_PROCESS.md doc (#41977)
Reword a few things in the explanation around our `Feature request process` to make
the process a little clearer.

PR Close #41977
2021-05-06 18:11:08 -07:00
mgechev
8dd5216c9e docs: use relative path for the feature request process diagram (#41970)
Center the diagram and use a relative path to make sure we don't break a branch if we restructure `master`/`main`.

PR Close #41970
2021-05-06 17:35:35 -04:00
Georgii Dolzhykov
21f523699b refactor(compiler): stricter types for HTML AST (#41360)
A Node can only be an instance of one of the six classes.
This relation can be accurately expressed using a union type.

PR Close #41360
2021-05-06 17:34:55 -04:00
Joey Perrott
568a69cfda feat(dev-infra): include release notes in Github release entries when publishing (#41964)
Include the release notes entry for the release in the release created on Github.

PR Close #41964
2021-05-06 15:45:52 -04:00
va-stefanek
e218a8b839 refactor(common): change missing NgSwitch provider error message (#41704)
change error message of invalid NgSwitch use and add corner cases tests

PR Close #41704
2021-05-06 15:44:42 -04:00
iRealNirmal
bc23ed0012 docs: update testing components doc with generated compileComponent (#41947)
Updated testing-components-scenarios.md to match CLI generated test case.

Closes #39740

PR Close #41947
2021-05-06 15:40:36 -04:00
Kapunahele Wong
e56cb5fc9f docs: add redirect and update updating-to-v11 to v12 (#41625)
PR Close #41625
2021-05-06 15:15:09 -04:00