mirror of
https://github.com/Textualize/textual.git
synced 2025-10-17 02:38:12 +03:00
Add template files for consistency.
This commit is contained in:
39
docs/snippets/type_syntax/_template.md
Normal file
39
docs/snippets/type_syntax/_template.md
Normal file
@@ -0,0 +1,39 @@
|
||||
<!--
|
||||
This is the template file for a syntax snippet of a Textual CSS type.
|
||||
The comments below illustrate some common patterns.
|
||||
-->
|
||||
|
||||
<!--
|
||||
For a simple type like <integer>:
|
||||
|
||||
Describe the type in a short paragraph with an absolute link to the type page.
|
||||
E.g., “The [`<my-type>`](/css_types/my_type) type is such and such with sprinkles on top.”
|
||||
-->
|
||||
|
||||
<!--
|
||||
For a type with many different values like <color>:
|
||||
|
||||
Introduce the type with a link to [`<my-type>`](/css_types/my_type).
|
||||
Then, a bullet list with the variants accepted:
|
||||
|
||||
- you can create this type with X Y Z;
|
||||
- you can also do A B C; and
|
||||
- also use D E F.
|
||||
|
||||
Consider ending with a link to the code/API that serves as ground truth for what values are accepted.
|
||||
-->
|
||||
|
||||
<!--
|
||||
For a type that accepts specific options like <border>:
|
||||
|
||||
Add a sentence and a table. Consider ordering values in alphabetical order if there is no other obvious ordering. See below:
|
||||
|
||||
The [`<my-type>`](/css_types/my_type) type can take any of the following values:
|
||||
|
||||
| Value | Description |
|
||||
|---------------|-----------------------------------------------|
|
||||
| `abc` | Describe here. |
|
||||
| `other val` | Describe this one also. |
|
||||
| `value three` | Please use full stops. |
|
||||
| `zyx` | Describe the value without assuming any rule. |
|
||||
-->
|
||||
Reference in New Issue
Block a user