@@ -104,6 +104,7 @@ class PythonHandler(BaseHandler):
104104 "show_docstring_yields" : True ,
105105 "show_source" : True ,
106106 "show_bases" : True ,
107+ "show_inheritance_diagram" : False ,
107108 "show_submodules" : False ,
108109 "group_by_category" : True ,
109110 "heading_level" : 2 ,
@@ -119,13 +120,15 @@ class PythonHandler(BaseHandler):
119120 "show_labels" : True ,
120121 "unwrap_annotated" : False ,
121122 "parameter_headings" : False ,
123+ "modernize_annotations" : False ,
122124 }
123125 """Default handler configuration.
124126
125127 Attributes: General options:
126128 find_stubs_package (bool): Whether to load stubs package (package-stubs) when extracting docstrings. Default `False`.
127129 allow_inspection (bool): Whether to allow inspecting modules when visiting them is not possible. Default: `True`.
128130 show_bases (bool): Show the base classes of a class. Default: `True`.
131+ show_inheritance_diagram (bool): Show the inheritance diagram of a class using Mermaid. Default: `False`.
129132 show_source (bool): Show the source code of this object. Default: `True`.
130133 preload_modules (list[str] | None): Pre-load modules that are
131134 not specified directly in autodoc instructions (`::: identifier`).
@@ -200,6 +203,7 @@ class PythonHandler(BaseHandler):
200203 separate_signature (bool): Whether to put the whole signature in a code block below the heading.
201204 If Black is installed, the signature is also formatted using it. Default: `False`.
202205 unwrap_annotated (bool): Whether to unwrap `Annotated` types to show only the type without the annotations. Default: `False`.
206+ modernize_annotations (bool): Whether to modernize annotations, for example `Optional[str]` into `str | None`. Default: `False`.
203207 """
204208
205209 def __init__ (
@@ -274,7 +278,7 @@ def load_inventory(
274278 ) -> Iterator [tuple [str , str ]]:
275279 """Yield items and their URLs from an inventory file streamed from `in_file`.
276280
277- This implements mkdocstrings' `load_inventory` "protocol" (see [`mkdocstrings.plugin`][mkdocstrings.plugin ]).
281+ This implements mkdocstrings' `load_inventory` "protocol" (see [`mkdocstrings.plugin`][]).
278282
279283 Arguments:
280284 in_file: The binary file-like object to read the inventory from.
0 commit comments