Skip to content

Commit e0d59f7

Browse files
committed
Revert "fix(docs-infra): process mermaid code blocks (angular#54434)" (angular#54448)
This reverts commit 925c86a. Reason for revert: broken CI after merging to main, see https://github.com/angular/angular/actions/runs/7908845750/job/21588824548. PR Close angular#54448
1 parent da7fbb4 commit e0d59f7

File tree

14 files changed

+43
-478
lines changed

14 files changed

+43
-478
lines changed

adev/src/content/best-practices/runtime-performance/BUILD.bazel

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,5 @@ generate_guides(
55
srcs = glob([
66
"*.md",
77
]),
8-
mermaid_blocks = True,
98
visibility = ["//adev:__subpackages__"],
109
)

adev/src/content/best-practices/runtime-performance/skipping-subtrees.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,8 @@ If Angular handles an event within a component without `OnPush` strategy, the fr
3333

3434
As an example, if we set the change detection strategy of `MainComponent` to `OnPush` and the user interacts with a component outside the subtree with root `MainComponent`, Angular will check all the green components from the diagram below (`AppComponent`, `HeaderComponent`, `SearchComponent`, `ButtonComponent`) unless `MainComponent` receives new inputs:
3535

36-
```mermaid
36+
<!-- TODO(josephperrott): enable this mermaid chart -->
37+
```
3738
graph TD;
3839
app[AppComponent] --- header[HeaderComponent];
3940
app --- main["MainComponent (OnPush)"];
@@ -61,7 +62,8 @@ As an example, if Angular handles an event within `MainComponent`, the framework
6162

6263
<img alt="Change detection propagation from OnPush component" src="assets/content/images/best-practices/runtime-performance/on-push-trigger.svg">
6364

64-
```mermaid
65+
<!-- TODO(josephperrott): enable this mermaid chart -->
66+
```
6567
graph TD;
6668
app[AppComponent] --- header[HeaderComponent];
6769
app --- main["MainComponent (OnPush)"];
@@ -87,7 +89,8 @@ If Angular handles an event in a component with OnPush, the framework will execu
8789

8890
As an example, in the diagram below, Angular handles an event in `LoginComponent` which uses OnPush. Angular will invoke change detection in the entire component subtree including `MainComponent` (`LoginComponent`’s parent), even though `MainComponent` has `OnPush` as well. Angular checks `MainComponent` as well because `LoginComponent` is part of its view.
8991

90-
```mermaid
92+
<!-- TODO(josephperrott): enable this mermaid chart -->
93+
```
9194
graph TD;
9295
app[AppComponent] --- header[HeaderComponent];
9396
app --- main["MainComponent (OnPush)"];
@@ -112,7 +115,8 @@ Angular will run change detection within a child component with `OnPush` when se
112115

113116
For example, in the diagram below, `AppComponent` passes a new input to `MainComponent`, which has `OnPush`. Angular will run change detection in `MainComponent` but will not run change detection in `LoginComponent`, which also has `OnPush`, unless it receives new inputs as well.
114117

115-
```mermaid
118+
<!-- TODO(josephperrott): enable this mermaid chart -->
119+
```
116120
graph TD;
117121
app[AppComponent] --- header[HeaderComponent];
118122
app --- main["MainComponent (OnPush)"];

adev/src/content/guide/components/BUILD.bazel

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,5 @@ generate_guides(
88
data = [
99
"//adev/src/assets/images:components.svg",
1010
],
11-
mermaid_blocks = True,
1211
visibility = ["//adev:__subpackages__"],
1312
)

adev/src/content/guide/components/anatomy-of-components.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,8 @@ component's **view**.
8787

8888
In composing components in this way, **you can think of your Angular application as a tree of components**.
8989

90-
```mermaid
90+
<!-- TODO(josephperrott): enable this mermaid chart -->
91+
```
9192
flowchart TD
9293
A[AccountSettings]-->B
9394
A-->C

adev/src/content/guide/components/lifecycle.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,8 @@ The following diagrams show the execution order of Angular's lifecycle hooks.
302302

303303
### During initialization
304304

305-
```mermaid
305+
<!-- TODO(josephperrott): enable this mermaid chart -->
306+
```
306307
graph TD;
307308
id[constructor]-->CHANGE;
308309
subgraph CHANGE [Change detection]
@@ -319,7 +320,8 @@ CHANGE--Rendering-->afterRender
319320

320321
### Subsequent updates
321322

322-
```mermaid
323+
<!-- TODO(josephperrott): enable this mermaid chart -->
324+
```
323325
graph TD;
324326
subgraph CHANGE [Change detection]
325327
direction TB

adev/src/content/guide/di/BUILD.bazel

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,5 @@ generate_guides(
99
"//adev/src/assets/images:dependency_injection.svg",
1010
"//adev/src/content/examples/resolution-modifiers:src/app/self/self.component.ts",
1111
],
12-
mermaid_blocks = True,
1312
visibility = ["//adev:__subpackages__"],
1413
)

adev/src/content/guide/di/dependency-injection.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,8 @@ When Angular discovers that a component depends on a service, it first checks if
119119

120120
When all requested services have been resolved and returned, Angular can call the component's constructor with those services as arguments.
121121

122-
```mermaid
122+
<!-- TODO(josephperrott): enable this mermaid chart -->
123+
```
123124
graph TD;
124125
subgraph Injector
125126
serviceA[Service A]

adev/src/content/guide/di/hierarchical-dependency-injection.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,8 @@ For more information on `@Optional()`, see the [`@Optional()` section](#optional
9292

9393
The following diagram represents the relationship between the `root` `ModuleInjector` and its parent injectors as the previous paragraphs describe.
9494

95-
```mermaid
95+
<!-- TODO(josephperrott): enable this mermaid chart -->
96+
```
9697
stateDiagram-v2
9798
elementInjector: EnvironmentInjector\n(configured by Angular)\nhas special things like DomSanitizer => providedIn 'platform'
9899
rootInjector: root EnvironmentInjector\n(configured by AppConfig)\nhas things for your app => bootstrapApplication(..., AppConfig)
@@ -1111,6 +1112,7 @@ The root injector, marked as (A), uses _generic_ providers for details about `Ca
11111112

11121113
3. Child component (C) as a child of Component (B). Component (C) defines its own, even _more specialized_ provider for `CarService`.
11131114

1115+
<!-- TODO(josephperrott): enable this mermaid chart -->
11141116
```
11151117
graph TD;
11161118
subgraph COMPONENT_A[Component A]
@@ -1134,6 +1136,7 @@ When you resolve an instance of `Car` at the deepest component (C), its injector
11341136
* An `Engine` resolved by injector (B)
11351137
* Its `Tires` resolved by the root injector (A).
11361138

1139+
<!-- TODO(josephperrott): enable this mermaid chart -->
11371140
```
11381141
graph BT;
11391142

adev/src/content/guide/forms/BUILD.bazel

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,5 @@ generate_guides(
4949
"//adev/src/content/examples/reactive-forms:src/app/profile-editor/profile-editor.component.html",
5050
"//adev/src/content/examples/reactive-forms:src/app/profile-editor/profile-editor.component.ts",
5151
],
52-
mermaid_blocks = True,
5352
visibility = ["//adev:__subpackages__"],
5453
)

adev/src/content/guide/forms/overview.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,8 @@ The view-to-model diagram shows how data flows when an input field's value is ch
107107
1. The `FormControl` instance emits the new value through the `valueChanges` observable.
108108
1. Any subscribers to the `valueChanges` observable receive the new value.
109109

110-
```mermaid
110+
<!-- TODO(josephperrott): enable this mermaid chart -->
111+
```
111112
flowchart TB
112113
U{User}
113114
I("&lt;input&gt;")
@@ -127,7 +128,8 @@ The model-to-view diagram shows how a programmatic change to the model is propag
127128
1. Any subscribers to the `valueChanges` observable receive the new value.
128129
1. The control value accessor on the form input element updates the element with the new value.
129130

130-
```mermaid
131+
<!-- TODO(josephperrott): enable this mermaid chart -->
132+
```
131133
flowchart TB
132134
U{User}
133135
I(&lt;input&gt;)
@@ -154,7 +156,8 @@ The view-to-model diagram shows how data flows when an input field's value is ch
154156
1. The control value accessor also calls the `NgModel.viewToModelUpdate()` method which emits an `ngModelChange` event.
155157
1. Because the component template uses two-way data binding for the `favoriteColor` property, the `favoriteColor` property in the component is updated to the value emitted by the `ngModelChange` event \(*Blue*\).
156158

157-
```mermaid
159+
<!-- TODO(josephperrott): enable this mermaid chart -->
160+
```
158161
flowchart TB
159162
U{User}
160163
I(&lt;input&gt;)
@@ -185,7 +188,8 @@ The model-to-view diagram shows how data flows from model to view when the `favo
185188
1. Any subscribers to the `valueChanges` observable receive the new value.
186189
1. The control value accessor updates the form input element in the view with the latest `favoriteColor` value.
187190

188-
```mermaid
191+
<!-- TODO(josephperrott): enable this mermaid chart -->
192+
```
189193
flowchart TB
190194
C(Component)
191195
P(Property bound to NgModel)

0 commit comments

Comments
 (0)