Skip to content

Commit 2c8528b

Browse files
authored
Apply suggestions from code review
1 parent e2a17fc commit 2c8528b

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

docs/usage/configuration/headings.md

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,9 @@ plugins:
6262
- **:octicons-package-24: Type [`str`][] :material-equal: `""`{ title="default value" }**
6363
<!-- - **:octicons-project-template-24: Template :material-null:** (N/A) -->
6464

65-
A custom string to use as the heading of the root of the object (i.e. the object specfied directly after the identifier `:::`). This will override the default heading generated by the plugin.
65+
A custom string to use as the heading of the root object (i.e. the object specified directly after the identifier `:::`). This will override the default heading generated by the plugin.
6666

67-
!!! warning "Not advised to be used as a general configuration option"
68-
This option is not advised to be used as a general configuration option, as it will override the default heading for all objects. It is recommended to use it only in specific cases where you want to override the heading for a specific object.
67+
WARNING: **Not advised to be used as a global configuration option.** This option is not advised to be used as a global configuration option, as it will override the default heading for all objects. It is recommended to use it only in specific cases where you want to override the heading for a specific object.
6968

7069
```md title="in docs/some_page.md (local configuration)"
7170
::: path.to.module
@@ -80,11 +79,9 @@ A custom string to use as the heading of the root of the object (i.e. the object
8079

8180
A custom string to use as the label in the Table of Contents for the root object (i.e. the one specified directly after the identifier `:::`). This will override the default label generated by the plugin.
8281

83-
!!! warning "Not advised to be used as a general configuration option"
84-
This option is not advised to be used as a general configuration option, as it will override the default label for all objects. It is recommended to use it only in specific cases where you want to override the label for a specific object.
82+
WARNING: **Not advised to be used as a global configuration option.** This option is not advised to be used as a global configuration option, as it will override the default label for all objects. It is recommended to use it only in specific cases where you want to override the label for a specific object.
8583

86-
!!! note "Use with/without `heading`"
87-
If you use this option without specifying a custom `heading`, the default heading will be used in the page, but the label in the Table of Contents will be the one you specified. By providing both an option for `heading` and `toc_label`, we leave the customization entirely up to you.
84+
NOTE: **Use with/without `heading`.** If you use this option without specifying a custom `heading`, the default heading will be used in the page, but the label in the Table of Contents will be the one you specified. By providing both an option for `heading` and `toc_label`, we leave the customization entirely up to you.
8885

8986
```md title="in docs/some_page.md (local configuration)"
9087
::: path.to.module

src/mkdocstrings_handlers/python/handler.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,8 +145,8 @@ class PythonHandler(BaseHandler):
145145
The modules must be listed as an array of strings. Default: `None`.
146146
147147
Attributes: Headings options:
148-
heading (str): A custom string to override the autogenerated heading of the root object
149-
toc_label (str): A custom string to override the autogenerated toc label of the root object
148+
heading (str): A custom string to override the autogenerated heading of the root object.
149+
toc_label (str): A custom string to override the autogenerated toc label of the root object.
150150
heading_level (int): The initial heading level to use. Default: `2`.
151151
parameter_headings (bool): Whether to render headings for parameters (therefore showing parameters in the ToC). Default: `False`.
152152
show_root_heading (bool): Show the heading of the object at the root of the documentation tree

0 commit comments

Comments
 (0)