30796 Commits

Author SHA1 Message Date
Kristiyan Kostadinov 5dc6deca85 build: update docs infra package (#56758)
Updates to the latest docs infra code to fix an issue with generating the `hiddenFiles` field.

PR Close #56758
2024-07-01 13:43:10 +00:00
Jessica Janiuk ecd5e6b754 ci: update pullapprove primitives list (#56761)
This removes one user from the shared primitives group to fix pullapprove requests.

PR Close #56761
2024-06-28 21:07:59 +00:00
cexbrayat f25653e231 fix(common): typo in NgOptimizedImage warning (#56756)
A space is missing in the warning message for `TOO_MANY_PRIORITY_ATTRIBUTES`.

PR Close #56756
2024-06-28 18:38:25 +00:00
Kristiyan Kostadinov ceaaa9815b build: update to latest docs tooling to resolve missing answers (#56746)
Updates to the latest version of `@angular/docs` which should include a fix for the missing answers in the tutorials.

PR Close #56746
2024-06-27 21:17:38 +00:00
Andrew Scott ed2665a74d docs: fix indentation on control flow documentation page (#56748)
This fixes the indentation on the examples in the control flow docs

fixes #56745

PR Close #56748
2024-06-27 19:55:48 +00:00
Tom Wilkinson 040d86137e refactor(core): Remove dom.ts and use native Element.prototype.contains. (#56591)
Delete the entire dom.ts file, it is no longer needed.

PR Close #56591
2024-06-27 18:28:19 +00:00
Tom Wilkinson 3773f406ac refactor(core): Remove ActionResolver code from EventContract (#56723)
Now that all `Dispatcher` implementations use `ActionResolver`, `EventContract` no longer needs to. Additionally, all a11y click support has been removed. `EventContract` will not specifically listen for `keydown` automatically, as all `EventContract` instances already have `keydown` listeners. This removes the need for the `A11Y_CLICK_SUPPORT` define, which will be removed in a future PR.

PR Close #56723
2024-06-27 18:27:44 +00:00
Tom Wilkinson 60a72af163 refactor(core): Remove attribute, char, and property values for ActionFlow. (#56590)
These values are inlined in ActionFlow internally in google3, and are no longer used.

Do some additional cleanup to only define the properties once.

PR Close #56590
2024-06-27 18:27:15 +00:00
Sasidharan SD 0cfd13c671 docs: fix cold observable and frames link (#56742)
PR Close #56742
2024-06-27 18:26:25 +00:00
Andrew Kushnir 917cd14bb4 ci: add more team members into the public-api group (#56743)
This commit adds more team members into the `public-api` group, so that they can approve public API changes, but they would not be requested for reviews by PullApprove (to avoid requests for unrelated changes).

PR Close #56743
2024-06-27 18:24:43 +00:00
Andrew Kushnir 344775344b Revert "fix(common): Don't run preconnect assertion on the server. (#56213)" (#56740)
This reverts commit 39e48ce675.

PR Close #56740
2024-06-27 17:44:42 +00:00
Paul Gschwendtner 2d8a96b684 refactor(compiler-cli): support running JIT transforms as part of tsickle emit (#56520)
When running the JIT transforms in 1P w/ tsickle, tsickle will
transform source files before our custom transforms can run. This is
also impacting the Ivy transform and hence we use `ts.getOriginalNode`
in various places to inspect the source AST for detecting Angular.

For the JIT transform we need to do a similar change so that the
transform could run in 1P.

PR Close #56520
2024-06-27 15:55:18 +00:00
Matthieu Riegler e618521a57 docs: replace @link with absolute link. (#56557)
Currently `@link` doesn't work for cross-package references.

Fixes #56556

PR Close #56557
2024-06-27 15:54:47 +00:00
Matthieu Riegler 39e48ce675 fix(common): Don't run preconnect assertion on the server. (#56213)
The `window` global is patched by domino on the server but the value of `window.location.href` isn't a valid base.

Before this change `getUrl()` would throw when running in devmode on the server.

Fixes #56207

PR Close #56213
2024-06-27 15:54:12 +00:00
Matthieu Riegler d23aa878a0 test(core): Add testing for defer error block (#56561)
In #56558 it was raised that we used an devMode function in a prod scope.
This commit adds a test when an defer error block is missing in devMode and prodMode

PR Close #56561
2024-06-27 15:53:19 +00:00
Angular Robot 34b5efcf0d build: update dependency selenium-webdriver4 to v4.22.0 (#56580)
See associated pull request for more information.

PR Close #56580
2024-06-27 15:52:47 +00:00
Pawel Kozlowski 08f56d980b refactor(common): remove ng_switch ability to use == equality check (#56426)
In Angular v17 we've alligned NgSwitch equality check with the build in control
flow to be ===. At the same time we've left the ability to use ==. This ability was
controlled by the NG_SWITCH_USE_STRICT_EQUALS const targetted by the G3 patch.

This commits removes the infrastructure to swap equality operator in preparation
for the G3 patch removal.

PR Close #56426
2024-06-27 15:07:57 +00:00
Thomas Nguyen 40fb81fd0e refactor(core): Add global event delegation provider (#56247)
This replaces all addEventListener calls with a stashing function,
and installs an event listener on the document body to retrieve
the stashed function;

PR Close #56247
2024-06-27 14:24:47 +00:00
Dylan Hunn 3bfba7ec15 docs: release notes for the v18.0.5 release 2024-06-26 17:15:22 -07:00
Dylan Hunn 5dc0de1494 release: cut the v18.1.0-next.4 release 18.1.0-next.4 2024-06-26 17:06:09 -07:00
Matthieu Riegler 033dfc39bc docs: Add mention of picture support in FAQ (#56692)
PR Close #56692
2024-06-26 16:58:27 -07:00
Matthieu Riegler cc4cb9608a refactor(common): Log a warning when the priority attribute of NgOptimizedImage is used too often. (#56669)
When the DOM content is loaded, Angular will log a warning message if the `priority` attribute is applied to often on `NgOptimizedImage` directive instances.

PR Close #56669
2024-06-26 12:43:00 -07:00
Matthieu Riegler ec654f72ae docs(docs-infra): fix asset path for learn angular #11 (#56587)
fixes #56568

PR Close #56587
2024-06-26 12:39:00 -07:00
Ofer Segev d3a488ad00 docs: Update signals overview.md (#56671)
change "computed" to a term using a backtick
PR Close #56671
2024-06-26 12:38:25 -07:00
Kristiyan Kostadinov 0a48d584f2 feat(core): add support for let syntax (#56715)
Enables the new `@let` syntax by default.

`@let` declarations are defined as:
1. The `@let` keyword.
2. Followed by one or more whitespaces.
3. Followed by a valid JavaScript name and zero or more whitespaces.
4. Followed by the `=` symbol and zero or more whitespaces.
5. Followed by an Angular expression which can be multi-line.
6. Terminated by the `;` symbol.

Example usage:
```
@let user = user$ | async;
@let greeting = user ? 'Hello, ' + user.name : 'Loading';
<h1>{{greeting}}</h1>
```

Fixes #15280.

PR Close #56715
2024-06-26 12:37:02 -07:00
Matthieu Riegler c19a4e7a96 docs: Move the background image migration to its own section. (#56588)
PR Close #56588
2024-06-26 08:52:17 -07:00
Tom Wilkinson 1d28fbb84c refactor(core): Use ActionResolver in Dispatcher. (#56369) (#56369)
`EventContract` usages in Angular now use `false` for
`useActionResolver`. Tests have been updated, with functionality that
depends on `ActionResolver` moving to dispatcher_test.ts.

PR Close #56369

PR Close #56369
2024-06-26 08:49:30 -07:00
Kristiyan Kostadinov 7dfe302f47 refactor(core): support let declarations during hydration (#56527)
Updates the hydration logic to account for the fact that let declarations don't create a DOM node.

PR Close #56527
2024-06-26 08:48:31 -07:00
Kristiyan Kostadinov bbe39c1738 refactor(core): integrate let instructions into the runtime (#56527)
Adds the implementation of the following new instructions:
* `declareLet` - creation-time instruction that initializes the slot for a let declaration.
* `storeLet` - update-time instruction that stores the current value of a let declaration.
* `readContextLet` - instruction that reads the stored value of a let declaration from a different view.

On top of the instructions, it also introduces a new `LetDeclaration` TNode type.
The new TNode is nececessary for DI to work correctly in pipes inside the let expression,
as well as for proper hydration support.

PR Close #56527
2024-06-26 08:48:31 -07:00
Andrew Scott 2431f206d7 refactor(forms): Update status, touched, and pristine to use private setter (#56573)
This refactor updates the touched, status, and pristine properties to
have a private setter.

PR Close #56573
2024-06-26 08:47:39 -07:00
Kristiyan Kostadinov ccc8c80cd0 build: update to TypeScript 5.5 stable (#56358)
Updates the repo to the stable release of TypeScript 5.5.

PR Close #56358
2024-06-25 09:29:16 -07:00
Shannon V.C 362e3c74a0 docs: add neovim setup section to adev (#56057)
PR Close #56057
2024-06-25 09:28:47 -07:00
Matthieu Riegler cc21989132 fix(http): Make Content-Type header case insensitive (#56541)
Prior to this change, is the `Content-Type` passed to the `FetchBackend` was lowercase it was overwritten with the default one.

fixes #56539

PR Close #56541
2024-06-25 09:28:18 -07:00
MikaelSvanasbakken f7d56790f5 docs: fix broken redirection to contributing.md (#56581)
PR Close #56581
2024-06-25 09:27:56 -07:00
Matthieu Riegler 5be16d06bd fix(core): prevent calling devMode only function on @defer error. (#56559)
`getTemplateLocationDetails()` is a devMode only function and should guarded by `ngDevMode` or calling it will throw an error.

fixes #56558

PR Close #56559
2024-06-25 09:17:33 -07:00
Sasidharan SD 85dc9123a1 docs: fix broken component fixture link (#56563)
PR Close #56563
2024-06-25 09:15:02 -07:00
Matthieu Riegler e81abdbd49 docs(docs-infra): add canonical link to each adev page (#56540)
PR Close #56540
2024-06-24 09:44:29 -07:00
Sasidharan SD 49b2e65bfb docs: fix file structure link (#56542)
PR Close #56542
2024-06-21 10:04:45 -07:00
Matthieu Riegler a9bbfdd103 build: add ignores for aio (#56538)
The files are needed/generated to run aio on the 17.3.

PR Close #56538
2024-06-21 10:03:34 -07:00
Gerald Monaco 29ca6d10cc fix(core): improve support for i18n hydration of projected content (#56192)
When collecting nodes from the DOM for hydration, we need to treat nodes with paths (e.g. content projection) as the new root for all subsequent elements, not just the next one.

Additionally, when using content projection it's possible for translated content to become disconnected, e.g. when it doesn't match a selector and there isn't a default. We need to handle such cases by manipulating the disconnected node data associated with hydration as usual.

PR Close #56192
2024-06-20 14:59:57 -07:00
Luis Fernando Scapin 3ea7794474 docs: ordered words (#56534)
Ordered correctly some words

PR Close #56534
2024-06-20 14:58:12 -07:00
Andrew Kushnir 29ecb39895 release: cut the v18.1.0-next.3 release 18.1.0-next.3 2024-06-20 12:07:20 -07:00
Andrew Kushnir 34c3bd3c83 docs: release notes for the v18.0.4 release 2024-06-20 12:02:32 -07:00
Andrew Scott 0d52c6b182 fix(router): Delay the view transition to ensure renders in microtasks complete (#56494)
This commit delays makes two changes:

* Use the `read` phase for `afterNextRender` hook. We really want to
   wait for any write hooks to complete before starting the animation
* In addition, wait a macrotask before resolve (really, this makes the
   above change unnecessary but it's still conceptually the right
   thing). This ensures any follow-up rendering in the microtask queue
   is flushed before the animation starts.

Important note: This only affects the timing of the animation start,
delaying it longer to allow additional rendering/change detections to
flush. This promise already resolves in an `afterNextRender` hook and is
only used directly by the browser's view transition machinery.

PR Close #56494
2024-06-20 08:56:49 -07:00
Sasidharan SD 955ade66e1 docs: fix page not found (#56512)
PR Close #56512
2024-06-20 08:56:09 -07:00
Matthieu Riegler 55835e9bc9 docs: fix code example for http headers (#56508)
PR Close #56508
2024-06-20 08:55:31 -07:00
Matthieu Riegler dd506c1802 docs: add mention of preconnect links (#56503)
Text is copied from AIO.

fixes #56502

PR Close #56503
2024-06-20 08:54:50 -07:00
Charles Lyding c12f318f72 build: remove unused root dependencies (#56499)
With the removal of AIO, several dependencies are now unused and can be removed.

PR Close #56499
2024-06-20 08:54:11 -07:00
Andrew Kushnir e20c6df65e refactor(core): use performance API for Event Replay (#56509)
This commit adds a standard performance marker that can be viewed in Chrome dev tools and other tooling.
See more info at https://developer.mozilla.org/en-US/docs/Web/API/Performance/mark

PR Close #56509
2024-06-20 08:53:18 -07:00
Andrew Kushnir bf6df6f186 fix(core): do not activate event replay when no events are registered (#56509)
This commit adds extra checks to handle a situation when an application has no events configured, but the Event Replay feature was enabled. This situation can happen when some routes in an application are mostly static, when other routes are more interactive.

Resolves #56423.

PR Close #56509
2024-06-20 08:53:18 -07:00