mirror of
https://github.com/angular/angular.git
synced 2026-11-23 07:05:14 -05:00
docs: use uppercase alert prefixes so the callouts render
The alert tokenizer builds its matcher from the all-caps AlertSeverityLevel keys with only the `s` flag, so `Tip:` and `Note:` never match and render as ordinary body text instead of a callout: guide/routing/define-routes.md:45, :143 Tip: guide/routing/route-guards.md:65 Tip: guide/forms/signals/validation.md:143 Note: tools/devtools/router.md:24 Note: Intent is clear from the surrounding files, which already use the correct casing: route-guards.md has two other TIP:/NOTE: alerts and validation.md has five.
This commit is contained in:
@@ -140,7 +140,7 @@ registrationForm = form(this.registrationModel, (schemaPath) => {
|
||||
|
||||
The validation rule only runs when the `when` function returns `true`.
|
||||
|
||||
Note: `required` treats an empty array as present (valid), so use [`minLength()`](#minlength-and-maxlength) to enforce a minimum number of array items.
|
||||
NOTE: `required` treats an empty array as present (valid), so use [`minLength()`](#minlength-and-maxlength) to enforce a minimum number of array items.
|
||||
|
||||
### email()
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ export const routes: Routes = [
|
||||
];
|
||||
```
|
||||
|
||||
Tip: If you generated a project with Angular CLI, your routes are defined in `src/app/app.routes.ts`.
|
||||
TIP: If you generated a project with Angular CLI, your routes are defined in `src/app/app.routes.ts`.
|
||||
|
||||
### Adding the router to your application
|
||||
|
||||
@@ -140,7 +140,7 @@ const routes: Routes = [
|
||||
|
||||
In this routes array, the app displays the `NotFound` component when the user visits any path outside of `home` and `user/:id`.
|
||||
|
||||
Tip: Wildcard routes are typically placed at the end of a routes array.
|
||||
TIP: Wildcard routes are typically placed at the end of a routes array.
|
||||
|
||||
## How Angular matches URLs
|
||||
|
||||
|
||||
@@ -62,7 +62,7 @@ export const authGuard: CanActivateFn = (
|
||||
};
|
||||
```
|
||||
|
||||
Tip: If you need to redirect the user, return a [`URLTree`](api/router/UrlTree) or [`RedirectCommand`](api/router/RedirectCommand). Do **not** return `false` and then programmatically `navigate` the user.
|
||||
TIP: If you need to redirect the user, return a [`URLTree`](api/router/UrlTree) or [`RedirectCommand`](api/router/RedirectCommand). Do **not** return `false` and then programmatically `navigate` the user.
|
||||
|
||||
For more information, check out the [API docs for CanActivateFn](api/router/CanActivateFn).
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ When you select a specific route in the tree, Angular DevTools displays its prop
|
||||
- **Auxiliary**: Indicates if the route is an auxiliary route (e.g., in a named outlet).
|
||||
- **Lazy**: Indicates if the route is lazily loaded.
|
||||
|
||||
Note: Properties like Path Match, Data, Resolvers, Guards, Providers, Title, and RunGuardsAndResolvers only appear in the sidebar when they are configured on the selected route.
|
||||
NOTE: Properties like Path Match, Data, Resolvers, Guards, Providers, Title, and RunGuardsAndResolvers only appear in the sidebar when they are configured on the selected route.
|
||||
|
||||
### Navigate to a specific route
|
||||
|
||||
|
||||
Reference in New Issue
Block a user