Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
2ae0d34
chore: update origin to 4e4df4a
lacolaco Oct 25, 2026
9291494
fix: migrate untranslated files
lacolaco Oct 25, 2026
4c1942a
fix(app): apply upstream changes to translated strings in src/app/fea…
lacolaco Oct 25, 2026
6482826
fix(app): mirror upstream code changes in src/app/features/update
lacolaco Oct 25, 2026
afbafa9
fix(app): apply upstream changes to translated strings in src/app/fea…
lacolaco Oct 25, 2026
7434eef
fix(app): apply upstream changes to translated strings in src/app/rou…
lacolaco Oct 25, 2026
5234ff8
fix(docs): apply upstream wording changes in src/content/ai
lacolaco Oct 25, 2026
c068c70
fix(docs): apply upstream wording changes in src/content/guide
lacolaco Oct 25, 2026
8ce6502
fix(docs): retranslate updated sections in src/content/guide
lacolaco Oct 25, 2026
36ad144
fix(docs): apply upstream wording changes in src/content/guide/animat…
lacolaco Oct 25, 2026
e632bb4
fix(docs): apply upstream wording changes in src/content/guide/aria
lacolaco Oct 25, 2026
f920282
fix(docs): retranslate updated sections in src/content/guide/aria
lacolaco Oct 25, 2026
07b3e6e
fix(docs): mirror upstream code and link changes in src/content/guide…
lacolaco Oct 25, 2026
65b583e
fix(docs): apply upstream wording changes in src/content/guide/compon…
lacolaco Oct 25, 2026
7521b3e
fix(docs): retranslate updated sections in src/content/guide/di
lacolaco Oct 25, 2026
732232f
fix(docs): apply upstream wording changes in src/content/guide/forms
lacolaco Oct 25, 2026
41508cb
fix(docs): apply upstream wording changes in src/content/guide/forms/…
lacolaco Oct 25, 2026
2a33adb
fix(docs): retranslate updated sections in src/content/guide/forms/si…
lacolaco Oct 25, 2026
acf0799
chore(docs): insert new upstream sections untranslated in src/content…
lacolaco Oct 25, 2026
39cb331
fix(docs): mirror upstream code and link changes in src/content/guide…
lacolaco Oct 25, 2026
0f9ea79
fix(docs): retranslate updated sections in src/content/guide/http
lacolaco Oct 25, 2026
a47571b
fix(docs): mirror upstream code and link changes in src/content/guide…
lacolaco Oct 25, 2026
ab58730
fix(docs): apply upstream wording changes in src/content/guide/routing
lacolaco Oct 25, 2026
30b543a
fix(docs): retranslate updated sections in src/content/guide/routing
lacolaco Oct 25, 2026
eaf54a7
fix(docs): retranslate updated sections in src/content/guide/signals
lacolaco Oct 25, 2026
6c49a22
fix(docs): apply upstream wording changes in src/content/guide/templates
lacolaco Oct 25, 2026
f689942
fix(docs): retranslate updated sections in src/content/guide/templates
lacolaco Oct 25, 2026
dfb1290
fix(docs): mirror upstream code and link changes in src/content/guide…
lacolaco Oct 25, 2026
da68871
fix(docs): apply upstream wording changes in src/content/guide/testing
lacolaco Oct 25, 2026
4806425
fix(docs): retranslate updated sections in src/content/guide/testing
lacolaco Oct 25, 2026
b669826
fix(docs): mirror upstream code and link changes in src/content/intro…
lacolaco Oct 25, 2026
1a94a00
fix(docs): apply upstream wording changes in src/content/reference/er…
lacolaco Oct 25, 2026
8ea904d
fix(docs): retranslate updated sections in src/content/tools/cli
lacolaco Oct 25, 2026
3dfaf07
fix(docs): apply upstream wording changes in src/content/tools/devtools
lacolaco Oct 25, 2026
648fcc3
fix(docs): apply upstream wording changes in src/content/tutorials/fi…
lacolaco Oct 25, 2026
03d6de9
fix(docs): retranslate updated sections in src/content/tutorials/firs…
lacolaco Oct 25, 2026
233830f
fix(docs): apply upstream wording changes in src/content/tutorials/fi…
lacolaco Oct 25, 2026
053db0c
fix(docs): apply upstream wording changes in src/content/tutorials/fi…
lacolaco Oct 25, 2026
e1bc7eb
fix(docs): apply upstream wording changes in src/content/tutorials/fi…
lacolaco Oct 25, 2026
d835cac
fix(docs): mirror upstream code and link changes in src/content/tutor…
lacolaco Oct 25, 2026
69c777a
fix(docs): apply upstream wording changes in src/content/tutorials/le…
lacolaco Oct 25, 2026
8c65733
fix(docs): mirror upstream code and link changes in src/content/tutor…
lacolaco Oct 25, 2026
bc75350
fix(docs): apply upstream wording changes in src/content/tutorials/le…
lacolaco Oct 25, 2026
4f89247
fix(docs): apply upstream wording changes in src/content/tutorials/le…
lacolaco Oct 25, 2026
415eeb9
fix(docs): apply upstream wording changes in src/content/tutorials/le…
lacolaco Oct 25, 2026
8febac7
fix(docs): retranslate updated sections in src/content/tutorials/lear…
lacolaco Oct 25, 2026
d83e9f0
fix(docs): apply upstream wording changes in src/content/tutorials/si…
lacolaco Oct 25, 2026
1c5b11f
fix(docs): apply upstream wording changes in src/content/tutorials/si…
lacolaco Oct 25, 2026
e350207
fix(docs): apply upstream wording changes in src/content/tutorials/si…
lacolaco Oct 25, 2026
82077ee
fix(docs): mirror upstream code and link changes in src/content/tutor…
lacolaco Oct 25, 2026
a92c444
fix(docs): add anchor IDs to all headings in expression-syntax.md
lacolaco Oct 25, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion adev-ja/src/app/features/home/home.component.en.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ <h1 tabindex="-1">Angular v22 is here!</h1>
</div>
</div>

@if (!isUwu) {
@if (!uwu()) {
<div class="title">
<h2>Productivity<br />Meets scalability</h2>
<h3>The framework for building scalable web apps with confidence</h3>
Expand Down
2 changes: 1 addition & 1 deletion adev-ja/src/app/features/home/home.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ <h1 tabindex="-1">Angular v22がリリースされました!</h1>
</div>
</div>

@if (!isUwu) {
@if (!uwu()) {
<div class="title">
<h2>Productivity<br />Meets scalability</h2>
<h3>スケーラブルなWebアプリを確信を持って構築できるフレームワーク</h3>
Expand Down
35 changes: 16 additions & 19 deletions adev-ja/src/app/features/update/update.component.en.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ <h3>Angular versions</h3>
From v.

<button type="button" [cdkMenuTriggerFor]="templatesMenuFrom">
<span>{{ from.name }}</span>
<span>{{ from().name }}</span>
<docs-icon>expand_more</docs-icon>
</button>

<ng-template #templatesMenuFrom>
<ul class="adev-template-dropdown" cdkMenu>
@for (version of versions; track $index) {
<li>
<button cdkMenuItem type="button" (click)="from = version; showUpdatePath()">
<button cdkMenuItem type="button" (click)="from.set(version); showUpdatePath()">
<span>{{ version.name }}</span>
</button>
</li>
Expand All @@ -32,15 +32,15 @@ <h3>Angular versions</h3>
<span class="adev-template-select">
To v.
<button type="button" [cdkMenuTriggerFor]="templatesMenuTo">
<span>{{ to.name }}</span>
<span>{{ to().name }}</span>
<docs-icon>expand_more</docs-icon>
</button>

<ng-template #templatesMenuTo>
<ul class="adev-template-dropdown" cdkMenu>
@for (version of versions; track $index) {
<li>
<button cdkMenuItem type="button" (click)="to = version; showUpdatePath()">
<button cdkMenuItem type="button" (click)="to.set(version); showUpdatePath()">
<span>{{ version.name }}</span>
</button>
</li>
Expand All @@ -51,7 +51,7 @@ <h3>Angular versions</h3>
</span>
</div>

@if (from.number >= futureVersion || to.number >= futureVersion) {
@if (from().number >= futureVersion || to().number >= futureVersion) {
<div class="docs-alert docs-alert-critical">
<p>
<strong>Warning:</strong>
Expand All @@ -61,7 +61,7 @@ <h3>Angular versions</h3>
</div>
}

@if (from.number > to.number) {
@if (from().number > to().number) {
<div class="docs-alert docs-alert-critical">
<p>
<strong>Warning:</strong>
Expand All @@ -70,7 +70,7 @@ <h3>Angular versions</h3>
</div>
}

@if (to.number - from.number > 150 && from.number > 240) {
@if (to().number - from().number > 150 && from().number > 240) {
<div class="docs-alert docs-alert-critical">
<p>
<strong>Warning:</strong>
Expand All @@ -84,19 +84,19 @@ <h3>Angular versions</h3>

<h3>Application complexity</h3>
<mat-button-toggle-group
(change)="level = $event.value; showUpdatePath()"
[value]="level"
(change)="level.set($event.value); showUpdatePath()"
[value]="level()"
style="margin-bottom: 16px"
>
<mat-button-toggle [value]="1">Basic</mat-button-toggle>
<mat-button-toggle [value]="2">Medium</mat-button-toggle>
<mat-button-toggle [value]="3">Advanced</mat-button-toggle>
</mat-button-toggle-group>
@if (level === 1) {
@if (level() === 1) {
<p>Shows information for all Angular developers.</p>
} @else if (level === 2) {
} @else if (level() === 2) {
<p>Shows information that's of interest to more advanced Angular developers.</p>
} @else if (level === 3) {
} @else if (level() === 3) {
<p>Shows all the information we have about this update.</p>
}

Expand All @@ -111,7 +111,7 @@ <h3>Other dependencies</h3>
</div>
}

@if (from.number < 600) {
@if (from().number < 600) {
<h4>Package Manager</h4>
<mat-button-toggle-group
(change)="packageManager = $event.value; showUpdatePath()"
Expand Down Expand Up @@ -159,8 +159,7 @@ <h3>Before you update</h3>
</span>
</div>
</div>
}
@if (beforeRecommendations.length <= 0) {
} @empty {
<div>
<em>You don't need to do anything before moving between these versions.</em>
</div>
Expand All @@ -187,8 +186,7 @@ <h3>Update to the new version</h3>
</span>
</div>
</div>
}
@if (duringRecommendations.length <= 0) {
} @empty {
<div>
<em>There aren't any recommendations for moving between these versions.</em>
</div>
Expand All @@ -209,8 +207,7 @@ <h3>After you update</h3>
</span>
</div>
</div>
}
@if (afterRecommendations.length <= 0) {
} @empty {
<div>
<em>You don't need to do anything after moving between these versions.</em>
</div>
Expand Down
73 changes: 45 additions & 28 deletions adev-ja/src/app/features/update/update.component.en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

import {Clipboard} from '@angular/cdk/clipboard';
import {CdkMenu, CdkMenuItem, CdkMenuTrigger} from '@angular/cdk/menu';
import {Component, inject, signal} from '@angular/core';
import {afterNextRender, Component, inject, input, linkedSignal, signal} from '@angular/core';
import {IconComponent} from '@angular/docs';
import {MatButtonToggle, MatButtonToggleGroup} from '@angular/material/button-toggle';
import {MatCheckbox} from '@angular/material/checkbox';
Expand Down Expand Up @@ -39,6 +39,10 @@ interface Option {

const isWindows = typeof window !== 'undefined' && window.navigator.userAgent.includes('Windows');

/** Versions selected when the URL doesn't specify any. */
const DEFAULT_FROM_VERSION = '21.0';
const DEFAULT_TO_VERSION = '22.0';

@Component({
selector: 'adev-update-guide',
templateUrl: './update.component.html',
Expand All @@ -61,7 +65,8 @@ export default class UpdateComponent {

protected title = signal('');

protected level = 1;
/** The application complexity level, initialized from the `l` query param. */
protected readonly level = linkedSignal(() => parseInt(this.levelParam() ?? '', 10) || 1);
protected options: Record<string, boolean> = {
ngUpgrade: false,
material: false,
Expand Down Expand Up @@ -120,8 +125,17 @@ export default class UpdateComponent {
{name: '2.1', number: 201},
{name: '2.0', number: 200},
];
protected from = this.versions.find((version) => version.name === '21.0')!;
protected to = this.versions.find((version) => version.name === '22.0')!;
/** The versions to update from and to, initialized from the `v` query param. */
protected readonly from = linkedSignal(
() =>
this.findVersion(this.versionsParam()?.split('-')[0]) ??
this.findVersion(DEFAULT_FROM_VERSION)!,
);
protected readonly to = linkedSignal(
() =>
this.findVersion(this.versionsParam()?.split('-')[1]) ??
this.findVersion(DEFAULT_TO_VERSION)!,
);
protected futureVersion = 2300;

protected readonly steps: Step[] = RECOMMENDATIONS;
Expand All @@ -130,19 +144,22 @@ export default class UpdateComponent {
private readonly router = inject(Router);
private readonly activatedRoute = inject(ActivatedRoute);

/** Bound from the `v` query param, in the `<from>-<to>` format (e.g. `21.0-22.0`). */
readonly versionsParam = input<string>(undefined, {alias: 'v'});
/** Bound from the `l` query param, the application complexity level. */
readonly levelParam = input<string>(undefined, {alias: 'l'});

constructor() {
const queryMap = this.activatedRoute.snapshot.queryParamMap;
// Detect settings in URL
this.level = parseInt(queryMap.get('l')!, 10) || this.level;

// Detect versions of from and to
const versions = queryMap.get('v');
if (versions) {
const [from, to] = versions.split('-');
this.from = this.versions.find((version) => version.name === from)!;
this.to = this.versions.find((version) => version.name === to)!;
this.showUpdatePath();
}
// Show the update path right away when the versions are provided in the URL.
afterNextRender(() => {
if (this.versionsParam()) {
this.showUpdatePath();
}
});
}

private findVersion(name: string | undefined) {
return this.versions.find((version) => version.name === name);
}

copyCode(event: Event) {
Expand Down Expand Up @@ -172,7 +189,7 @@ export default class UpdateComponent {
this.afterRecommendations = [];

// Refuse to generate recommendations for downgrades
if (this.to.number < this.from.number) {
if (this.to().number < this.from().number) {
alert('We do not support downgrading versions of Angular.');
return;
}
Expand All @@ -182,13 +199,13 @@ export default class UpdateComponent {
const labelMedium = 'medium applications';
const labelAdvanced = 'advanced applications';

this.title.set(`${labelTitle} v${this.from.name} -> v${this.to.name}
this.title.set(`${labelTitle} v${this.from().name} -> v${this.to().name}
for
${this.level < 2 ? labelBasic : this.level < 3 ? labelMedium : labelAdvanced}`);
${this.level() < 2 ? labelBasic : this.level() < 3 ? labelMedium : labelAdvanced}`);

// Find applicable steps and organize them into before, during, and after upgrade
for (const step of this.steps) {
if (step.level <= this.level && step.necessaryAsOf > this.from.number) {
if (step.level <= this.level() && step.necessaryAsOf > this.from().number) {
// Check Options
// Only show steps that don't have a required option
// Or when the user has a matching option selected
Expand All @@ -213,12 +230,12 @@ export default class UpdateComponent {
step.renderedStep = await marked(this.replaceVariables(step.action));

// If you could do it before now, but didn't have to finish it before now
if (step.possibleIn <= this.from.number && step.necessaryAsOf >= this.from.number) {
if (step.possibleIn <= this.from().number && step.necessaryAsOf >= this.from().number) {
this.beforeRecommendations.push(step);
// If you couldn't do it before now, and you must do it now
} else if (step.possibleIn > this.from.number && step.necessaryAsOf <= this.to.number) {
} else if (step.possibleIn > this.from().number && step.necessaryAsOf <= this.to().number) {
this.duringRecommendations.push(step);
} else if (step.possibleIn <= this.to.number) {
} else if (step.possibleIn <= this.to().number) {
this.afterRecommendations.push(step);
}
}
Expand All @@ -227,7 +244,7 @@ export default class UpdateComponent {
// Update the URL so users can link to this transition
this.router.navigate([], {
relativeTo: this.activatedRoute,
queryParams: {v: `${this.from.name}-${this.to.name}`, l: this.level},
queryParams: {v: `${this.from().name}-${this.to().name}`, l: this.level()},
queryParamsHandling: 'merge',
});

Expand Down Expand Up @@ -257,8 +274,8 @@ export default class UpdateComponent {

private async renderPreV6Instructions(): Promise<void> {
let upgradeStep: Step;
const additionalDeps = this.getAdditionalDependencies(this.to.number);
const angularVersion = this.getAngularVersion(this.to.number);
const additionalDeps = this.getAdditionalDependencies(this.to().number);
const angularVersion = this.getAngularVersion(this.to().number);
const angularPackages = [
'animations',
'common',
Expand All @@ -274,7 +291,7 @@ export default class UpdateComponent {
];

// Provide npm/yarn instructions for versions before 6
if (this.to.number < 600) {
if (this.to().number < 600) {
const actionMessage = `Update all of your dependencies to the latest Angular and the right version of TypeScript.`;

if (isWindows) {
Expand Down Expand Up @@ -305,7 +322,7 @@ export default class UpdateComponent {

// Npm installs typescript wrong in v5, let's manually specify
// https://github.com/npm/npm/issues/16813
if (this.packageManager === 'npm install' && this.to.number === 500) {
if (this.packageManager === 'npm install' && this.to().number === 500) {
upgradeStep.action += `

\`npm install typescript@2.4.2 --save-exact\``;
Expand Down
Loading
Loading