36609 Commits

Author SHA1 Message Date
SkyZeroZx 4544135b1e docs: update tutorials with self-closing tags, standalone router directives, and fix syntax highlighting 2025-11-12 13:13:22 -08:00
Jan Martin 48d395402d release: bump Angular DevTools version to 1.6.0 2025-11-12 11:59:07 -08:00
Angular Robot 3b51b0174c build: update cross-repo angular dependencies
See associated pull request for more information.
2025-11-12 11:51:33 -08:00
SkyZeroZx a48029b810 docs: correct example for RouteReuseStrategy getRouteKey
Update the example to properly demonstrate the getRouteKey method usage fixes #65021
2025-11-12 11:49:03 -08:00
Angular Robot fc5710bb7f docs: update cross-repo adev docs
Updated Angular adev cross repo docs files.
2025-11-12 11:43:32 -08:00
SkyZeroZx 05ef2a5ca9 docs: correct code block language in error handling and signals interop 2025-11-12 11:35:09 -08:00
Angular Robot 78b1a2e0cc build: update cross-repo angular dependencies
See associated pull request for more information.
2025-11-12 11:33:08 -08:00
Angular Robot 8e81d0a9e8 build: update pnpm to v10.21.0
See associated pull request for more information.
2025-11-12 09:42:28 -08:00
Angular Robot 42454b428b build: update bazel dependencies
See associated pull request for more information.
2025-11-12 09:41:05 -08:00
Angular Robot 76a5246943 build: update all non-major dependencies
See associated pull request for more information.
2025-11-12 09:39:55 -08:00
Alan Agius 46099910c0 build: allow any version of @angular/* packages for peer dependencies
This change configures pnpm to allow any version of  `@angular/*` packages to satisfy peer dependencies. This is necessary because `@angular/*` packages are managed within this monorepo, and this rule prevents issues with peer dependency resolution when different versions might be present during development or testing.
2025-11-12 09:35:58 -08:00
Joey Perrott 7d6235f3fb build: use mjs files for ng-dev configuration
In preperation for ng-dev requiring mjs files for configuration, switch over our usage
2025-11-12 09:35:19 -08:00
Alan Agius 0835bd815f build: improve dependency management for local packages
Refactor .pnpmfile.cjs to use a Set for localAngularPackages for better performance.
Adjust typescript dependency handling in compiler-cli to correctly use devDependencies.
Promote rxjs and zone.js from peer dependencies to regular dependencies for local packages.
These changes streamline dependency resolution and align with pnpm's behavior for workspace dependencies.
2025-11-12 09:34:27 -08:00
Alan Agius c51b42f1ce build: remove extra deps
Most of these deps are either unused or are in `adev`
2025-11-12 09:34:27 -08:00
Andrew Kushnir cc095d447c docs: release notes for the v21.0.0-rc.2 release 2025-11-12 08:41:32 -08:00
Andrew Kushnir 1f6de175c9 docs: release notes for the v20.3.11 release 2025-11-12 08:26:29 -08:00
Danny Koppenhagen c3e82fb2d5 refactor(core): render additional WAI-ARIA 1.3 property bindings as attributes
Support additional ARIA properties from Accessible Rich Internet Applications (WAI-ARIA) version 1.3.

| attribute | property |
|-----------|----------|
| `aria-activedescendant`           | `ariaActiveDescendantElement` |
| `aria-colindextext`           | `ariaColIndexText` |
| `aria-controls`           | `ariaControlsElements ` |
| `aria-describeyby`           | `ariaDescribedByElements ` |
| `aria-description`           | `ariaDescription` |
| `aria-details`           | `ariaDetailsElements ` |
| `aria-errormessage`           | `ariaErrorMessageElements ` |
| `aria-flowto`           | `ariaFlowToElements ` |
| `aria-labelledby`           | `ariaLabelledByElements ` |
| `aria-owns`           | `ariaOwnsElements ` |
| `aria-rowindextext`           | `ariaRowIndexText ` |

closes #64847
2025-11-11 14:08:58 -08:00
Matthew Beck 24cfd5a0ed fix(compiler): support complex selectors in :nth-child()
:nth-child() (and its siblings) support complex expressions, e.g.
`:nth-child(2n of :is(.foo, .bar))`. Previously we'd choke because of
the `:is()`. Now, we reuse the `_parenSuffix` subexpression to match
nested parentheses the same way we do for :host() and :host-context().
Note that we only support 3 levels of nesting, so a selector like
`:nth-child(n of :is(:has(:not(.foo))))` will still break.

I'll say yet again that we really should add a proper parser so we stop
getting bug reports like this :)

Fixes #64913
2025-11-11 14:03:32 -08:00
Alan Agius 4ed8781301 refactor(core): improve resource loading with async/await
Refactor  to use async/await for clearer asynchronous operations and enhanced error handling.
Simplify resource caching and streamline the resolution of component templates and styles.
Update  in the router to align with the new async resource resolution.
2025-11-11 12:50:16 -08:00
Andrew Scott 4af408afcb Revert "feat(service-worker): notify clients about version failures (#62718)"
This reverts commit 6d011687ec.

issue #63500 reproduces at head on the main branch in the dev app.
Reverting this change along resolves it.

fixes https://github.com/angular/angular/issues/63500
2025-11-11 12:48:45 -08:00
Leon Senft d337cfb68f feat(forms): add debounce() rule for signal forms
The `debounce()` rule allows developers to control when changes to a
form control are synchronized to the form model.

This feature necessitated some changes to `FieldState`:

  * `controlValue` is a new signal property that represents the current
    value of a form field as it appears in its corresponding control.

  * `value` conceptually remains unchanged; however, its value may lag
    behind that of `controlValue` if a `debounce()` rule is applied.

The `debounce()` rule essentially manages when changes to `controlValue` are
synchronized to `value`. The intent is that an expensive or slow
validation rule can react to the debounced `value`, rather than a more
frequently changing `controlValue`.

Directly updating `value` immediately updates `controlValue`, and cancels any
pending debounced updates.

When multiple `debounce()` rules are applied to the same field, the last
currently active rule is used to debounce an update. These rules are
applied to child fields as well, unless they override them with their
own rule.
2025-11-11 12:00:09 -08:00
Leon Senft 8866934334 refactor(forms): do not infer accumulated metadata type from initial value
This removes the need to specify type arguments for
`reducedMetadataKey()` when the value returned from the `getIntial`
callback is a subtype of the accumulated type.
2025-11-11 12:00:09 -08:00
Angular Robot 631cf977a8 build: update cross-repo angular dependencies
See associated pull request for more information.
2025-11-11 11:51:05 -08:00
Alan Agius 74dca6eccd build: lock file maintenance
See associated pull request for more information.
2025-11-11 10:50:09 -08:00
Angular Robot 3b1fbf00da build: update cross-repo angular dependencies
See associated pull request for more information.
2025-11-11 10:19:24 -08:00
Doug Parker 490435bf76 fix(core): skip Angular formatting when formatting signals recursively
The flag `skipFormatting` got renamed to `ngSkipFormatting` during review of https://github.com/angular/angular/pull/64000, but a couple usages got missed, causing some unfortunate UI recursion.
2025-11-11 10:14:30 -08:00
Kristiyan Kostadinov 8277906455 refactor(compiler): remove unused code
The `fullInheritane` flag from the metadata and the `CopyDefinitionFeature` that it controls appear to no longer be used since `fullInheritance` is always false. The feature appears to have been there to support ngcc which was removed some time ago.
2025-11-11 10:04:29 -08:00
Angular Robot 75dd600570 build: lock file maintenance
See associated pull request for more information.
2025-11-11 08:48:00 -08:00
SkyZeroZx d999667b57 docs: add reference to Built-in Pipes in multiple pipe files 2025-11-11 08:47:07 -08:00
Matthieu Riegler 21ca49cf62 refactor(core): rename ExperimentalIsolatedShadowDom to IsolatedShadowDom
This API is still experimental
2025-11-11 08:46:06 -08:00
Matthieu Riegler 16e61f5dd0 docs(docs-infra): Add support for experimental enum entries 2025-11-11 08:46:06 -08:00
RobinReinecke 07703875b5 docs: correct mermaid code block formatting 2025-11-11 08:33:27 -08:00
SkyZeroZx dde18c2303 docs: improve discoverability in service worker documentation 2025-11-11 08:32:14 -08:00
cexbrayat 800b01f5a1 docs: remove error mentions in signal forms docs
`error` no longer exists and is called `validate`
2025-11-11 08:30:08 -08:00
Doug Parker ec9dc94cee feat(platform-browser): add context to createApplication
This is necessary to use SSR safely with `createApplication` and avoid constraining users to `bootstrapApplication`. It is one more step towards feature parity between `createApplication` and `bootstrapApplication`.
2025-11-10 14:18:29 -08:00
Doug Parker ab67988d2e feat(platform-browser): resolve JIT resources in createApplication
Previously, `createApplication` didn't work with JIT components. This commit brings it closer to feature parity with `bootstrapApplication`.
2025-11-10 14:18:29 -08:00
Devin Chasanoff 5af33724a4 docs: add links to SDUI example and livestream 2025-11-10 14:16:18 -08:00
arturovt feb86e3fde fix(common): remove placeholder image listeners once view is removed
Prior to this commit, attempting to resolve a `ChangeDetectorRef` after views or app have been destroyed would result in an error. In this commit, we clean up listeners once the view is destroyed, before the placeholder loads or fails to load.
2025-11-10 12:05:20 -08:00
Shuaib Hasan Akib b0b834d7f1 refactor(router): add ngDevMode guards to InjectionToken names and cleanup imports
Wraps InjectionToken names with `typeof ngDevMode !== 'undefined' && ngDevMode`
checks to enable tree-shaking of descriptive token names in production builds.
This ensures debug-only strings are removed from production bundles, reducing size.

Also removes unused imports found during refactor.
2025-11-10 12:04:31 -08:00
arturovt d3f67f6ca8 refactor(core): mark VERSION as @__PURE__ for better tree-shaking
Annotate the `new Version(...)` call with `/* @__PURE__ */` to signal to optimizers that the constructor is side-effect free.

Without this hint, bundlers such as Terser or ESBuild may conservatively retain the `VERSION` instantiation even when unused. With the annotation, the constant can be tree-shaken away in production builds if not referenced, reducing bundle size.
2025-11-10 12:04:04 -08:00
Alan Agius d42f9ce3a9 docs: use markdown code fences in service worker docs
Replaces the <docs-code> component with standard markdown code fences in the service worker documentation. This improves the readability and maintainability of the documentation.
2025-11-10 12:03:31 -08:00
Angular Robot 4ff6348c0b docs: update cross-repo adev docs
Updated Angular adev cross repo docs files.
2025-11-10 10:34:39 -08:00
AleksanderBodurri cfb26f5999 feat(devtools): use router state for active route detection
Replace URL-based active route detection with direct traversal of the ActivatedRoute tree.

This solution is more reliable than the previous approach because it directly compares router tree configuration objects against the active router instance state with router.routerState.
2025-11-10 09:50:08 -08:00
SkyZeroZx 55be477979 refactor(http): migrate XSRF classes to use inject() function
Remove constructor injection in favor of inject() calls
2025-11-10 09:49:09 -08:00
arturovt 7724a9460d refactor(router): replace Optional with inject() flags
Replace `@Optional() link: RouterLink` constructor parameter with
`link = inject(RouterLink, {optional: true})` to enable tree-shaking
of the `Optional` decorator and its factory scaffolding.

Bundle size reduction: `Optional` is a runtime value created by
`makeParamDecorator()`. Even in production builds, ESBuild and other
bundlers must keep their factory code because it is referenced via
`Optional`. With `inject()`, this class is no longer referenced,
allowing it and the `makeParamDecorator` scaffolding to be tree-shaken
when unused elsewhere.

Note: This updates the constructor signature but should not be
considered a breaking change. Angular's official guidance is that
directives, components, and pipes should be instantiated by the
framework, not by user code. Directly calling `new RouterLinkActive(...)`
is an unsupported pattern that goes against Angular's design principles.
2025-11-10 09:48:32 -08:00
Angular Robot e5cc6d55e8 build: update all non-major dependencies
See associated pull request for more information.
2025-11-10 09:47:41 -08:00
Angular Robot 050c475b51 build: update cross-repo angular dependencies
See associated pull request for more information.
2025-11-10 08:23:57 -08:00
Andrew Scott 2db8f2ee75 refactor(router): Add handling of abort event on signal of NavigateEvent
This adds handling of the abort event on the signal of the
`NavigateEvent`, allowing us to cancel the Router's ongoing navigation
transition when its related navigation was aborted.
2025-11-10 08:02:43 -08:00
Shuaib Hasan Akib 27d54654e3 docs: add shell language to CLI installation examples
Added `language="shell"` to installation command examples to display
the shell prompt `$` icon consistently across npm, pnpm, yarn, and bun
code blocks.
2025-11-10 08:01:29 -08:00
Shuaib Hasan Akib e0a4bdd72b docs(docs-infra): simplify file headers in <docs-code> blocks
Removed redundant "src/app/" prefix from file headers (e.g.,
"src/app/open-close.component.ts" → "open-close.component.ts")
to make code examples cleaner and more focused.
2025-11-10 08:00:33 -08:00