@@ -7,6 +7,7 @@ specially-crafted graphics.
77Assets committed to this repo and pushed to GitHub are immediately
88available for linking and reference.
99
10+
1011## URL structure
1112
1213Reference the assets with this URL structure:
@@ -20,6 +21,7 @@ material library would go in the `assets/material/` directory and be at
2021All asset files should be under the ` assets ` directory in an appropriate
2122subdirectory.
2223
24+
2325## Generation
2426
2527Images must be code-generated.
@@ -38,7 +40,7 @@ bin/generate.sh -c cupertino,material
3840bin/generate.sh -n basic_material_app,blend_mode
3941```
4042
41- ` bin/generate.sh -h ` lists available arguments.
43+ ` bin/generate.sh --help ` lists available arguments.
4244
4345### Prerequisites
4446
@@ -57,6 +59,7 @@ in a directory in the `PATH` environment variable. (e.g. PATH=~/<path_to_flutter
5759When using an Android device, be sure that the ` adb ` command is the same as the one running
5860as a server (which is often started by your IDE, so use the same ` adb ` the IDE is running).
5961
62+
6063## Optimization
6164
6265Please consider optimization tools for assets.
@@ -73,6 +76,20 @@ the `assets/tests` directory should not be optimized.
7376The automatic generation tool will automatically apply optimization to
7477the assets it generates.
7578
79+
80+ ## Creating new diagrams
81+
82+ To create a new diagram:
83+
84+ 1 . Add a new file to ` packages/diagrams/lib/src/ ` , and put the tests in there.
85+
86+ 2 . Export that file from ` packages/diagrams/lib/diagrams.dart ` .
87+
88+ 3 . Add your new class to the list in ` assets-for-api-docs/utils/diagram_generator/lib/main.dart ` .
89+
90+ 4 . Run ` generate.sh --name xxx ` where 'xxx' is the name of your diagram.
91+
92+
7693## Origin of third-party content
7794
7895* ` /assets/videos/bee.mp4 ` : CC0 Creative Commons, from [ https://pixabay.com/en/videos/honey-bee-insect-bee-flower-flying-211/ ] ( https://pixabay.com/en/videos/honey-bee-insect-bee-flower-flying-211/ )
0 commit comments