36240 Commits

Author SHA1 Message Date
Leon Senft 70668befde release: cut the v21.1.3 release v21.1.3 2026-02-04 16:06:24 -08:00
Matthieu Riegler 767c6b4754 fix(vscode-extension): support highlighting for class bindings with brackets
Tailwind classes can often be quite complex strings. This change adds supports for classes with backets.

fixes #66818

(cherry picked from commit 01ed57f297)
2026-02-04 15:45:08 -08:00
SkyZeroZx 1bf6bfc07f test(forms): remove zone-based testing utilities
Removes usages of zone-based helpers such as `fakeAsync` , `tick`
`waitForAsync` as part of the migration to zoneless tests.

Completes the transition to zoneless.

(cherry picked from commit 7dfbacbcf8)
2026-02-04 15:38:13 -08:00
Walter Breakell 70313f13fe docs: fix syntax errors and improve grammar in navigation guide
(cherry picked from commit d6585fe837)
2026-02-04 15:37:21 -08:00
Jef f9b69cc67b docs: fix typo
Add missing n to componet(s)

(cherry picked from commit 81876c2583)
2026-02-04 15:36:52 -08:00
Ben Hong 52dfcd9865 docs: add guidance on submit and novalidate for signal forms
(cherry picked from commit 38428945ac)
2026-02-04 15:36:22 -08:00
Angular Robot d793dde00f build: update cross-repo angular dependencies
See associated pull request for more information.
2026-02-04 15:30:54 -08:00
Kristiyan Kostadinov 04d518bc26 refactor(forms): work around internal issue
Works around an internal property renaming issue by changing how we declare the interface for `InteropNgControl`.

(cherry picked from commit 680d99b1c3)
2026-02-04 14:25:48 -08:00
David Neil 2cf4da0ea1 fix(core): hold constructors weakly in DepsTracker cache
Otherwise a component can be held in memory longer than
the component constructor is reachable from application code.

(cherry picked from commit cab5ddd526)
2026-02-03 12:44:27 -08:00
Matthieu Riegler f15d33d68b docs(docs-infra): extract call signature return type.
fixes #66799

(cherry picked from commit 43d61ecbb2)
2026-02-03 12:31:40 -08:00
Shuaib Hasan Akib 33e8cde034 docs: generalize wording for CSP nonce configuration options
Replaces “one of two ways” with “one of the following ways” to avoid
hardcoding the number of supported approaches and keep the
documentation accurate if options change.

fixes: #66861
(cherry picked from commit cfa7664361)
2026-02-03 12:27:15 -08:00
Angular Robot 8343b05ad7 build: lock file maintenance
See associated pull request for more information.
2026-02-03 12:26:06 -08:00
Matthieu Riegler 443654ac77 docs(docs-infra): fix foot width
This was due to a regression introduced by #66825

fixes #66880

(cherry picked from commit 9c032972a8)
2026-02-03 12:25:46 -08:00
David Neil 49a36f4cc7 perf(router): Use .bind to avoid holding other closures in memory
In many JS runtimes all closures created in the same scope share a context
this means that data held in one of the closures is not collected until all of the closures are collected.
This change prevents the returned promise from holding a reaction that holds the entire `Router` object in memory.

(cherry picked from commit 3867cd8554)
2026-02-03 12:25:02 -08:00
Angular Robot 6505a26ee0 docs: update cross-repo adev docs
Updated Angular adev cross repo docs files.
2026-02-02 15:11:22 -08:00
Shahar Har-Shuv 96095f435e docs: Rename Field directive -> FormField in form-logic.md
(cherry picked from commit f29fcd882a)
2026-02-02 14:41:03 -08:00
Alex Rickabaugh 2b254bc050 fix(core): linkedSignal.update should propagate errors
Unlike a normal `signal()`, a `linkedSignal()` can be in an error state when
its computation fails. Currently, there's a bug where `linkedSignal.update`
does not account for this error state, and will pass the internal `ERRORED`
`Symbol` as the current value to the updater function.

This commit fixes the issue by having `update()` check and throw the error
instead of calling the updater function.

(cherry picked from commit aff9e36a98)
2026-02-02 12:21:36 -08:00
Kristiyan Kostadinov e5110b4fa1 fix(core): export DirectiveWithBindings
Exports the `DirectiveWithBindings` interface since it's part of the public API of `createComponent`.

Fixes #66851.

(cherry picked from commit 8ab433abdd)
2026-02-02 11:08:45 -08:00
SkyZeroZx f1e4446071 feat(docs-infra): Implements select component using Angular Aria
Replaces the native select element with a custom combobox implementation for improved accessibility and styling.

(cherry picked from commit 70615117a2)
2026-02-02 11:07:58 -08:00
AleksanderBodurri 79519409cd feat(devtools): promote router tree to stable
Previous the router tree was an opt-in feature that required manual enablement in settings.

Now the router tree is enabled by default whenever the application supports it and routes are detected.

(cherry picked from commit 35046d3dba)
2026-02-02 11:06:45 -08:00
SkyZeroZx 4729e804ac docs(docs-infra): Fix border color issue on aria select when closing on outside click
Prevents incorrect border color from appearing on close triggered by an outside click

(cherry picked from commit cdbb957334)
2026-02-02 11:04:48 -08:00
dominicbachmann 575f8a39c7 docs(animations): fix small typo in animations migrations docs
(cherry picked from commit a64a90dbbe)
2026-02-02 10:18:10 -08:00
Jaime Burgos f80e6c2f77 docs: remove component suffix router guide
(cherry picked from commit bd27aa2cf3)
2026-02-02 10:17:41 -08:00
SkyZeroZx bbd5cf82b1 test(forms): migrate reactive forms and value accessors to zoneless
Migrates reactive forms, template-driven forms, and value accessors to zoneless tests.

(cherry picked from commit 4aae3379c2)
2026-02-02 10:17:03 -08:00
SkyZeroZx c64db1d0f3 docs: update llms.txt
(cherry picked from commit 825122b6d2)
2026-02-02 10:14:07 -08:00
kirjs 5301711b4e docs: rename agents.md to AGENTS.md
(cherry picked from commit 19aa1eb95e)
2026-02-02 10:10:45 -08:00
kirjs 92ac00d507 docs: add PR section to agents.md
(cherry picked from commit a8d0155303)
2026-02-02 10:10:45 -08:00
kirjs fdd7a4deb5 docs: add agent configuration guide
Adds agents.md to the root directory to provide context and instructions for AI agents working in this repository.

(cherry picked from commit 9306abe883)
2026-02-02 10:10:45 -08:00
SkyZeroZx df7bf134fe docs(docs-infra): ensure code preview copy preserves spaces
Preserve whitespace when copying code examples from the docs. Fixes the copy handler so copied snippets keep original spacing.

Fixes #66790

(cherry picked from commit 522c5ba868)
2026-02-02 10:09:39 -08:00
Jaime Burgos 665b33ecdc docs: update zoneless guide
(cherry picked from commit 3d09d8e831)
2026-02-02 10:05:26 -08:00
Angular Robot eb2803237b build: update cross-repo angular dependencies
See associated pull request for more information.
2026-02-02 09:59:35 -08:00
SkyZeroZx 6f75b6e3f6 fix(forms): Resolves debounce promise on abort in debounceForDuration
Ensures the promise returned by the debouncer resolves
when aborted, preventing potential hangs for awaiting consumers.
Fixes #66646

(cherry picked from commit b1bf535f8e)
2026-01-30 09:19:47 -08:00
Charles Lyding efb64bf9fd build(language-service): remove local development build script
The standalone build.sh script for the language service is no longer
required as the vscode-ng-language-service repository has been merged
into this monorepo. Local development and testing of the extension
can now be handled via the integrated build system.

(cherry picked from commit f9bcccc2b9)
2026-01-29 13:16:53 -08:00
Matthieu Riegler e0a260a425 docs(docs-infra): wrap getTextOfJSDocComment
This commits adds a wrapper around `ts.getTextOfJSDocComment` because of bugs that won't be fixed by the TS team (see microsoft/TypeScript#63027)

(cherry picked from commit 72dfb4d92a)
2026-01-29 13:16:05 -08:00
Angular Robot 8dfbb8b5d5 build: update cross-repo angular dependencies
See associated pull request for more information.
2026-01-29 12:30:49 -08:00
Angular Robot 3845f7e930 build: update github/codeql-action action to v4.32.0
See associated pull request for more information.
2026-01-29 12:29:18 -08:00
Shuaib Hasan Akib cc9a58a2ae feat(docs-infra): increase table-of-contents width for large screens
Add media query overrides to expand the table-of-contents width on extra-large desktops.

fixes: #66823
(cherry picked from commit 6990f88d97)
2026-01-29 12:24:04 -08:00
Angular Robot e3681b7b5f build: update dependency tar.bzl to v0.8.1
See associated pull request for more information.
2026-01-29 12:23:31 -08:00
Jessica Janiuk 70a5b651be fix(core): prevent element duplication with dynamic components
When dynamic components are rapidly added and removed with animate.leave and animate.enter, a leave animation might fire before the enter animation could, causing an element to be retained. This fix prevents that from occuring by clearing the enter animations in this case.

fixes: #66794
(cherry picked from commit c66a19f0de)
2026-01-29 12:18:05 -08:00
Charles Lyding 4c7126d23b fix(localize): add support for unit-test builder in ng-add schematic
This commit updates the @angular/localize ng-add schematic to support
the @angular/build:unit-test builder. It ensures that @angular/localize
is added to the types array in the TypeScript configuration file
associated with the unit-test target. If no tsConfig is specified in
the target options, it defaults to tsconfig.spec.json in the project root.

(cherry picked from commit 1c3b1cf18d)
2026-01-29 12:17:19 -08:00
Andrew Scott d6268c0bbb fix(router): limit UrlParser recursion depth to prevent stack overflow
Deeply nested parentheses in URLs (e.g. `(a/(b/(c...)))`) trigger recursive calls in `UrlParser`, which can lead to a `RangeError: Maximum call stack size exceeded`. While such errors are generally caught by the framework, relying on the runtime's stack limit is unpredictable across different environments and engine states (e.g. varying stack sizes in different browsers or Node.js versions).

The deeply nested parentheses  can cause a stack overflow. While such URLs can be valid (e.g., `(a/(b/(c...)))`) and serialize to simple paths (e.g., /a/b/c), excessive nesting is unreasonable and likely malicious or accidental.

Linear paths (e.g. /a/b/c/d) are parsed iteratively and do NOT trigger recursion. Only parentheses trigger recursion.

This commit introduces a recursion depth limit of 50. If parsing exceeds this depth, the router will now throw a specific `UNPARSABLE_URL` error with the message "URL is too deep". This ensures a deterministic failure mode that is easier for applications to handle than a crash or generic RangeError.

The limit of 50 is chosen as it should accommodate any reasonable application URL structure (including complex named outlets) while providing a safe upper bound against abusive payloads.

This is essentially a refactor of the error state:

* Before: RangeError (System says "I'm out of stack memory")
* After: RuntimeError (Validator says "Input is invalid")

This provides:

* Semantic Correctness: The error now correctly blames the input ("URL too deep"), not the environment ("Stack full").
* Cross-Platform Consistency: The limit is the same in Chrome, Firefox, Node, and Deno, regardless of their internal recursion limits.
* Fast Failure: We stop at depth 50 instead of depth ~15,000, saving those cycles (though CPU cost is negligible either way).

"wide" URLs are now theoretically more expensive than "deep" URLs (because deep ones fail fast), but both are well within safe bounds for any reasonable input size.

(cherry picked from commit 458bc4a2c8)
2026-01-29 12:15:25 -08:00
SkyZeroZx 0a4c647ef0 refactor(core): Remove unsued properties in differ factories
Simplifies differ factories by removing unnecessary constructors and properties.

Also removes the formatError function as it is no longer used.

(cherry picked from commit 0c2efc0d46)
2026-01-29 12:06:37 -08:00
JakobDev b9b934363a docs: Add missing link in HostListener documentation
(cherry picked from commit 0e04233a7c)
2026-01-29 11:56:48 -08:00
SkyZeroZx cfe7340270 refactor(core): remove unused restriction parameter
Removes the `restriction` parameter from `registerAppScopedDispatcher` and `registerGlobalDispatcher`.

(cherry picked from commit d072791f13)
2026-01-28 20:54:49 +00:00
Andrew Scott 4f0d29d92a release: cut the v21.1.2 release v21.1.2 2026-01-28 20:36:08 +00:00
Angular Robot 290b2814e1 build: update cross-repo angular dependencies
See associated pull request for more information.
2026-01-28 19:28:34 +00:00
Leon Senft 9f99b14882 fix(forms): only touch visible, interactive fields on submit
Don't touch hidden, disabled, or readonly fields on submit, since they
don't contribute to form validity. This also prevents errors from
appearing immediately if they're later made interactive.

Fix #66344

(cherry picked from commit e682e53113)
2026-01-28 18:56:06 +00:00
Angular Robot 3de87e1eda build: update pnpm to v10.28.2
See associated pull request for more information.
2026-01-28 18:36:21 +00:00
Angular Robot affd2362eb build: lock file maintenance
See associated pull request for more information.
2026-01-28 18:27:17 +00:00
Angular Robot 11657fb0b1 docs: update cross-repo adev docs
Updated Angular adev cross repo docs files.
2026-01-28 18:23:34 +00:00