mkdocstrings-python 2.0.0__py3-none-any.whl → 2.0.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -139,7 +139,7 @@ class PythonHandler(BaseHandler):
139
139
  ) -> Iterator[tuple[str, str]]:
140
140
  """Yield items and their URLs from an inventory file streamed from `in_file`.
141
141
 
142
- This implements mkdocstrings' `load_inventory` "protocol" (see [`mkdocstrings.plugin`][]).
142
+ This implements mkdocstrings' `load_inventory` "protocol" (see [`mkdocstrings.BaseHandler.load_inventory`][]).
143
143
 
144
144
  Arguments:
145
145
  in_file: The binary file-like object to read the inventory from.
@@ -19,6 +19,9 @@ Context:
19
19
  {{ log.debug("Rendering children of " + obj.path) }}
20
20
  {% endblock logs %}
21
21
 
22
+ {% import "language.html.jinja" as lang with context %}
23
+ {#- Language module providing the `t` translation method. -#}
24
+
22
25
  <div class="doc doc-children">
23
26
 
24
27
  {% if root_members %}
@@ -45,7 +48,7 @@ Context:
45
48
  ) %}
46
49
  {% if attributes %}
47
50
  {% if config.show_category_heading %}
48
- {% filter heading(heading_level, id=html_id ~ "-attributes", skip_inventory=config.skip_local_inventory) %}Attributes{% endfilter %}
51
+ {% filter heading(heading_level, id=html_id ~ "-attributes", skip_inventory=config.skip_local_inventory) %}{{ lang.t("Attributes") }}{% endfilter %}
49
52
  {% endif %}
50
53
  {% with heading_level = heading_level + extra_level %}
51
54
  {% for attribute in attributes|order_members(config.members_order, members_list) %}
@@ -65,7 +68,7 @@ Context:
65
68
  ) %}
66
69
  {% if type_aliases %}
67
70
  {% if config.show_category_heading %}
68
- {% filter heading(heading_level, id=html_id ~ "-type_aliases") %}Type Aliases{% endfilter %}
71
+ {% filter heading(heading_level, id=html_id ~ "-type_aliases") %}{{ lang.t("Type Aliases") }}{% endfilter %}
69
72
  {% endif %}
70
73
  {% with heading_level = heading_level + extra_level %}
71
74
  {% for type_alias in type_aliases|order_members(config.members_order, members_list) %}
@@ -85,7 +88,7 @@ Context:
85
88
  ) %}
86
89
  {% if classes %}
87
90
  {% if config.show_category_heading %}
88
- {% filter heading(heading_level, id=html_id ~ "-classes", skip_inventory=config.skip_local_inventory) %}Classes{% endfilter %}
91
+ {% filter heading(heading_level, id=html_id ~ "-classes", skip_inventory=config.skip_local_inventory) %}{{ lang.t("Classes") }}{% endfilter %}
89
92
  {% endif %}
90
93
  {% with heading_level = heading_level + extra_level %}
91
94
  {% for class in classes|order_members(config.members_order, members_list) %}
@@ -105,7 +108,7 @@ Context:
105
108
  ) %}
106
109
  {% if functions %}
107
110
  {% if config.show_category_heading %}
108
- {% filter heading(heading_level, id=html_id ~ "-functions", skip_inventory=config.skip_local_inventory) %}Functions{% endfilter %}
111
+ {% filter heading(heading_level, id=html_id ~ "-functions", skip_inventory=config.skip_local_inventory) %}{{ lang.t("Functions") }}{% endfilter %}
109
112
  {% endif %}
110
113
  {% with heading_level = heading_level + extra_level %}
111
114
  {% for function in functions|order_members(config.members_order, members_list) %}
@@ -128,7 +131,7 @@ Context:
128
131
  ) %}
129
132
  {% if modules %}
130
133
  {% if config.show_category_heading %}
131
- {% filter heading(heading_level, id=html_id ~ "-modules", skip_inventory=config.skip_local_inventory) %}Modules{% endfilter %}
134
+ {% filter heading(heading_level, id=html_id ~ "-modules", skip_inventory=config.skip_local_inventory) %}{{ lang.t("Modules") }}{% endfilter %}
132
135
  {% endif %}
133
136
  {% with heading_level = heading_level + extra_level %}
134
137
  {% for module in modules|order_members("alphabetical", members_list) %}
@@ -157,7 +160,7 @@ Context:
157
160
 
158
161
  {% if not (obj.is_class and child.name == "__init__" and config.merge_init_into_class) %}
159
162
 
160
- {% if config.filters == "public" or members_list is not none or child.is_public %}
163
+ {% if config.filters == "public" or members_list is not none or (not child.is_imported or child.is_public) %}
161
164
  {% if child.is_attribute %}
162
165
  {% with attribute = child %}
163
166
  {% include attribute|get_template with context %}
@@ -17,6 +17,9 @@ Context:
17
17
  {{ log.debug("Rendering " + class.path) }}
18
18
  {% endblock logs %}
19
19
 
20
+ {% import "language.html.jinja" as lang with context %}
21
+ {#- Language module providing the `t` translation method. -#}
22
+
20
23
  <div class="doc doc-object doc-class">
21
24
  {% with obj = class, html_id = class.path, all_members = class.all_members %}
22
25
 
@@ -246,7 +249,7 @@ Context:
246
249
  {% if "__init__" in all_members and all_members["__init__"].source %}
247
250
  {% with init = all_members["__init__"] %}
248
251
  <details class="mkdocstrings-source">
249
- <summary>Source code in <code>
252
+ <summary>{{ lang.t("Source code in") }} <code>
250
253
  {%- if init.relative_filepath.is_absolute() -%}
251
254
  {{ init.relative_package_filepath }}
252
255
  {%- else -%}
@@ -259,7 +262,7 @@ Context:
259
262
  {% endif %}
260
263
  {% elif class.source %}
261
264
  <details class="mkdocstrings-source">
262
- <summary>Source code in <code>
265
+ <summary>{{ lang.t("Source code in") }} <code>
263
266
  {%- if class.relative_filepath.is_absolute() -%}
264
267
  {{ class.relative_package_filepath }}
265
268
  {%- else -%}
@@ -93,7 +93,7 @@ Context:
93
93
  <p>
94
94
  {% if attribute.annotation %}
95
95
  <span class="doc-attribute-annotation">
96
- <b>TYPE:</b>
96
+ <b>{{ lang.t("TYPE:") }}</b>
97
97
  {% with expression = attribute.annotation %}
98
98
  <code>{% include "expression.html.jinja" with context %}</code>
99
99
  {% endwith %}
@@ -9,9 +9,11 @@
9
9
 
10
10
  {% macro t(key) %}{{ {
11
11
  "ATTRIBUTE": "ATTRIBUTE",
12
+ "Attributes": "Attributes",
12
13
  "Attributes:": "Attributes:",
13
14
  "BOUND:": "BOUND:",
14
15
  "Bound or Constraints": "Bound or Constraints",
16
+ "Classes": "Classes",
15
17
  "Classes:": "Classes:",
16
18
  "Class Type Parameters:": "Class Type Parameters:",
17
19
  "CLASS TYPE PARAMETER": "CLASS TYPE PARAMETER",
@@ -23,12 +25,14 @@
23
25
  "DESCRIPTION": "DESCRIPTION",
24
26
  "Description": "Description",
25
27
  "Examples:": "Examples:",
28
+ "Functions": "Functions",
26
29
  "Functions:": "Functions:",
27
30
  "FUNCTION": "FUNCTION",
28
31
  "Init Type Parameters:": "Init Type Parameters:",
29
32
  "INIT TYPE PARAMETER": "INIT TYPE PARAMETER",
30
33
  "Methods:": "Methods:",
31
34
  "METHOD": "METHOD",
35
+ "Modules": "Modules",
32
36
  "Modules:": "Modules:",
33
37
  "MODULE": "MODULE",
34
38
  "Name": "Name",
@@ -45,6 +49,7 @@
45
49
  "Source code in": "Source code in",
46
50
  "TYPE:": "TYPE:",
47
51
  "Type": "Type",
52
+ "Type Aliases": "Type Aliases",
48
53
  "Type Aliases:": "Type Aliases:",
49
54
  "TYPE ALIAS": "TYPE ALIAS",
50
55
  "Type Parameters:": "Type Parameters:",
@@ -9,26 +9,30 @@
9
9
 
10
10
  {% macro t(key) %}{{ {
11
11
  "ATTRIBUTE": "属性",
12
+ "Attributes": "属性",
12
13
  "Attributes:": "属性:",
13
- "BOUND:": "BOUND:",
14
- "Bound or Constraints": "Bound or Constraints",
14
+ "BOUND:": "境界:",
15
+ "Bound or Constraints": "境界や制約",
16
+ "Classes": "クラス",
15
17
  "Classes:": "クラス:",
16
18
  "Class Type Parameters:": "Class Type Parameters:",
17
19
  "CLASS TYPE PARAMETER": "CLASS TYPE PARAMETER",
18
- "CLASS": "CLASS",
19
- "CONSTRAINTS:": "CONSTRAINTS:",
20
+ "CLASS": "クラス",
21
+ "CONSTRAINTS:": "制約:",
20
22
  "DEFAULT:": "デフォルト:",
21
23
  "Default": "デフォルト",
22
24
  "default:": "デフォルト:",
23
25
  "DESCRIPTION": "デスクリプション",
24
26
  "Description": "デスクリプション",
25
27
  "Examples:": "例:",
28
+ "Functions": "関数",
26
29
  "Functions:": "関数:",
27
30
  "FUNCTION": "関数",
28
31
  "Init Type Parameters:": "Init Type Parameters:",
29
32
  "INIT TYPE PARAMETER": "INIT TYPE PARAMETER",
30
33
  "Methods:": "メソッド:",
31
34
  "METHOD": "メソッド",
35
+ "Modules": "モジュール",
32
36
  "Modules:": "モジュール:",
33
37
  "MODULE": "モジュール",
34
38
  "Name": "名前",
@@ -45,10 +49,11 @@
45
49
  "Source code in": "ソースコード位置:",
46
50
  "TYPE:": "タイプ:",
47
51
  "Type": "タイプ",
48
- "Type Aliases:": "Type Aliases:",
49
- "TYPE ALIAS": "TYPE ALIAS",
50
- "Type Parameters:": "Type Parameters:",
51
- "TYPE PARAMETER": "TYPE PARAMETER",
52
+ "Type Aliases": "型エイリアス",
53
+ "Type Aliases:": "型エイリアス:",
54
+ "TYPE ALIAS": "型エイリアス",
55
+ "Type Parameters:": "型パラメータ:",
56
+ "TYPE PARAMETER": "型パラメータ",
52
57
  "WARNS": "警告",
53
58
  "Warns:": "警告:",
54
59
  "YIELDS": "返す",
@@ -9,26 +9,30 @@
9
9
 
10
10
  {% macro t(key) %}{{ {
11
11
  "ATTRIBUTE": "属性",
12
+ "Attributes": "属性",
12
13
  "Attributes:": "属性:",
13
- "BOUND:": "BOUND:",
14
- "Bound or Constraints": "Bound or Constraints",
14
+ "BOUND:": "边界:",
15
+ "Bound or Constraints": "边界或约束",
16
+ "Classes": "类",
15
17
  "Classes:": "类:",
16
18
  "Class Type Parameters:": "Class Type Parameters:",
17
19
  "CLASS TYPE PARAMETER": "CLASS TYPE PARAMETER",
18
- "CLASS": "CLASS",
19
- "CONSTRAINTS:": "CONSTRAINTS:",
20
+ "CLASS": "",
21
+ "CONSTRAINTS:": "约束:",
20
22
  "DEFAULT:": "默认:",
21
23
  "Default": "默认",
22
24
  "default:": "默认:",
23
25
  "DESCRIPTION": "描述",
24
26
  "Description": "描述",
25
27
  "Examples:": "示例:",
28
+ "Functions": "函数",
26
29
  "Functions:": "函数:",
27
30
  "FUNCTION": "函数",
28
31
  "Init Type Parameters:": "Init Type Parameters:",
29
32
  "INIT TYPE PARAMETER": "INIT TYPE PARAMETER",
30
33
  "Methods:": "方法:",
31
34
  "METHOD": "方法",
35
+ "Modules": "模块",
32
36
  "Modules:": "模块:",
33
37
  "MODULE": "模块",
34
38
  "Name": "名称",
@@ -45,10 +49,11 @@
45
49
  "Source code in": "源代码位于:",
46
50
  "TYPE:": "类型:",
47
51
  "Type": "类型",
48
- "Type Aliases:": "Type Aliases:",
49
- "TYPE ALIAS": "TYPE ALIAS",
50
- "Type Parameters:": "Type Parameters:",
51
- "TYPE PARAMETER": "TYPE PARAMETER",
52
+ "Type Aliases": "类型别名",
53
+ "Type Aliases:": "类型别名:",
54
+ "TYPE ALIAS": "类型别名",
55
+ "Type Parameters:": "类型形参:",
56
+ "TYPE PARAMETER": "类型形参",
52
57
  "Warns:": "警告:",
53
58
  "WARNS": "警告",
54
59
  "YIELDS": "产生",
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mkdocstrings-python
3
- Version: 2.0.0
3
+ Version: 2.0.1
4
4
  Summary: A Python handler for mkdocstrings.
5
5
  Author-Email: =?utf-8?q?Timoth=C3=A9e_Mazzucotelli?= <dev@pawamoy.fr>
6
6
  License-Expression: ISC
@@ -2,16 +2,16 @@ mkdocstrings_handlers/python/__init__.py,sha256=Kxy1zA4JJy0aWxUa2_xl5PfYV2-mrBKJ
2
2
  mkdocstrings_handlers/python/_internal/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
3
  mkdocstrings_handlers/python/_internal/config.py,sha256=DzPjS4rqrCw_C6xQ5ThpFI6iM3nF7hPsAG370bPVICg,35271
4
4
  mkdocstrings_handlers/python/_internal/debug.py,sha256=A6B3w6LWN22kYtvvbmz7vnh8Pr5hzvtrHhM3-Es8Isg,2882
5
- mkdocstrings_handlers/python/_internal/handler.py,sha256=WMFgIJxW9Ww3zPyKsQ7dcbvDBfm_fO-5J_SITmjQX68,15635
5
+ mkdocstrings_handlers/python/_internal/handler.py,sha256=ukqik2XjIbeUj3T1pyVhcVk-gU_DtbK8tSwhiaYgxqQ,15655
6
6
  mkdocstrings_handlers/python/_internal/rendering.py,sha256=9h8mF2r41dx9Gaef-3W7zpIuU7m_3lUtbGCitL23uSY,28642
7
7
  mkdocstrings_handlers/python/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
8
8
  mkdocstrings_handlers/python/templates/material/_base/attribute.html.jinja,sha256=ajtKaGxs9-VJzPNiXbQTYTO6ADq8Ck9M9x2BfXakG0g,4838
9
9
  mkdocstrings_handlers/python/templates/material/_base/backlinks.html.jinja,sha256=k8eX0lyQmmooaEotjYngdXO8RJldjixvZW30S5jGXOA,2109
10
- mkdocstrings_handlers/python/templates/material/_base/children.html.jinja,sha256=zPORhI3jnTmZRDDQ7LymGmgpDD31v7j6L9gsrx9U55g,7882
11
- mkdocstrings_handlers/python/templates/material/_base/class.html.jinja,sha256=8e84CW4_vWn5lMtKWp7IZjJEsJObIpShAKK82-W8yvs,12002
10
+ mkdocstrings_handlers/python/templates/material/_base/children.html.jinja,sha256=nzWeNjIgVSZgBD3IDaaoxRtxUA1zkSYGQMfDjGahl4g,8112
11
+ mkdocstrings_handlers/python/templates/material/_base/class.html.jinja,sha256=Wo_g0ag5P7d3rolVRYxtJMIT2U1KC9h7rh8yQFcuprQ,12153
12
12
  mkdocstrings_handlers/python/templates/material/_base/docstring.html.jinja,sha256=iKi-31JKoHwG7-w3S88A9YTu9kuV6-c9gwKb8bUtXuw,3440
13
13
  mkdocstrings_handlers/python/templates/material/_base/docstring/admonition.html.jinja,sha256=VFwImgb1toxkjWqyhTNFQbyYE3d11yXI___3vpIu2u0,687
14
- mkdocstrings_handlers/python/templates/material/_base/docstring/attributes.html.jinja,sha256=L8SNxn5M1pt1NmDFhJ6ZXM9k_ajv1ENOpjzYKQLLv7g,4179
14
+ mkdocstrings_handlers/python/templates/material/_base/docstring/attributes.html.jinja,sha256=r5xPFwDwyzkGF8aNi66kRD3BRqcr_msDgZyrOOc6rSQ,4195
15
15
  mkdocstrings_handlers/python/templates/material/_base/docstring/classes.html.jinja,sha256=WQW2f6iNgMObPF7X44hXIw_5vTfQeKFhdmlsVX6iUVY,3152
16
16
  mkdocstrings_handlers/python/templates/material/_base/docstring/examples.html.jinja,sha256=CxkEQ5bThOv0jq-zpkz7ZPMuHohd-6DEpor_Ojr7t-4,967
17
17
  mkdocstrings_handlers/python/templates/material/_base/docstring/functions.html.jinja,sha256=UrdJTx_mcfkp7z3rGVh_5vFHwNTh4oFh_wPpB8pR0qs,3691
@@ -29,9 +29,9 @@ mkdocstrings_handlers/python/templates/material/_base/expression.html.jinja,sha2
29
29
  mkdocstrings_handlers/python/templates/material/_base/function.html.jinja,sha256=AljcQjr1e6laOEpp4LRPKjnQNkN99zcPISxbXeEqPf4,6239
30
30
  mkdocstrings_handlers/python/templates/material/_base/labels.html.jinja,sha256=mue5CMl2WQpagj3aYqbUiAQX0P72aLCgY3MX_zEpE8s,786
31
31
  mkdocstrings_handlers/python/templates/material/_base/language.html.jinja,sha256=7gyknTiapqCM8TjUHdXkQgZMmYwcuy6Ze0pkntE7g8s,617
32
- mkdocstrings_handlers/python/templates/material/_base/languages/en.html.jinja,sha256=3Uq6sZocqwk6LZTV0ht3tBo2iBDCzABuEcrehZzAhQY,1591
33
- mkdocstrings_handlers/python/templates/material/_base/languages/ja.html.jinja,sha256=Ee01TL-nz5vK9PJXAqGhqPgyWsB2xc877XUCcVSbkac,1701
34
- mkdocstrings_handlers/python/templates/material/_base/languages/zh.html.jinja,sha256=IgoNgHvSpkfBu54fh2Af_nPbmdwEYuuu455P8BFp8NU,1583
32
+ mkdocstrings_handlers/python/templates/material/_base/languages/en.html.jinja,sha256=tzS9C3l1c5liALvpYl7dHOGhtoFpRQwMgm_gAVKcv_Y,1731
33
+ mkdocstrings_handlers/python/templates/material/_base/languages/ja.html.jinja,sha256=UUxdQrbwgRISh0qL8OkjRi7L6gjbGIg1ot-pg0OdyJk,1874
34
+ mkdocstrings_handlers/python/templates/material/_base/languages/zh.html.jinja,sha256=uWvh_jTzUb9kpmM72tOdPi5u40_-_4VcHpUau1R9-A8,1705
35
35
  mkdocstrings_handlers/python/templates/material/_base/module.html.jinja,sha256=1_9zC61tvsPKlaRRSMpZDXhssefWMurqY_KY4AWqr1M,4425
36
36
  mkdocstrings_handlers/python/templates/material/_base/signature.html.jinja,sha256=D8GkrfnZv-ap4i2pOs-QGKW585iKTQyfe4kANK42O_8,5115
37
37
  mkdocstrings_handlers/python/templates/material/_base/summary.html.jinja,sha256=jZSNC5ECuwm_W_I3P6_R8VHMEe_s8VJKTxixS1zTY3g,841
@@ -114,8 +114,8 @@ mkdocstrings_handlers/python/templates/readthedocs/languages/en.html.jinja,sha25
114
114
  mkdocstrings_handlers/python/templates/readthedocs/languages/ja.html.jinja,sha256=e_DPZvMvaaJm0QyjTxW8SkBEbhMXBgBiMrLJ1osAwZc,46
115
115
  mkdocstrings_handlers/python/templates/readthedocs/languages/zh.html.jinja,sha256=OuvrkorxuL0gKZNYneann1bwd1Z2i5bBY7SbC496HDw,46
116
116
  mkdocstrings_handlers/python/templates/readthedocs/style.css,sha256=Ds8vF1rSxc2B0c4P10osx4cqXHWMntcSCxmRfX-nfzw,971
117
- mkdocstrings_python-2.0.0.dist-info/METADATA,sha256=3yPFgpe-lhA8lYUd-EZaOpcuV8jYzgZhELjqIsGGYGY,13889
118
- mkdocstrings_python-2.0.0.dist-info/WHEEL,sha256=tsUv_t7BDeJeRHaSrczbGeuK-TtDpGsWi_JfpzD255I,90
119
- mkdocstrings_python-2.0.0.dist-info/entry_points.txt,sha256=6OYgBcLyFCUgeqLgnvMyOJxPCWzgy7se4rLPKtNonMs,34
120
- mkdocstrings_python-2.0.0.dist-info/licenses/LICENSE,sha256=JGb4pdPEM8TTjjhr-uNCO7oXkiVrwG5Pz0JamcjNF_s,754
121
- mkdocstrings_python-2.0.0.dist-info/RECORD,,
117
+ mkdocstrings_python-2.0.1.dist-info/METADATA,sha256=kYesKsPbLsxLk6k3YcLCvmG-Bw8HYQZEyssnMpii_g0,13889
118
+ mkdocstrings_python-2.0.1.dist-info/WHEEL,sha256=tsUv_t7BDeJeRHaSrczbGeuK-TtDpGsWi_JfpzD255I,90
119
+ mkdocstrings_python-2.0.1.dist-info/entry_points.txt,sha256=6OYgBcLyFCUgeqLgnvMyOJxPCWzgy7se4rLPKtNonMs,34
120
+ mkdocstrings_python-2.0.1.dist-info/licenses/LICENSE,sha256=JGb4pdPEM8TTjjhr-uNCO7oXkiVrwG5Pz0JamcjNF_s,754
121
+ mkdocstrings_python-2.0.1.dist-info/RECORD,,