We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7ce9d89 commit 9bcb260Copy full SHA for 9bcb260
1 file changed
src/sphinxnotes/project/templates/autoconfval.rst
@@ -1,11 +1,23 @@
1
{% set opt = load_extra('env').config.values[name] %}
2
+{% set default = opt.default | string %}
3
4
.. role:: py(code)
5
:language: Python
6
7
.. confval:: {{ name }}
8
:type: {{ opt.valid_types | autoconfval_types | join(', ') }}
- :default: :py:`{{ opt.default | pprint }}`
9
+ {% if '\n' not in default %}:default: :py:`{{ opt.default | pprint }}`{% endif %}
10
+
11
+ ..
12
13
+ {% if '\n' in default %}
14
+ :default:
15
+ .. code-block::
16
17
+ {% for _line in default.split('\n') -%}
18
+ {{ _line }}
19
+ {% endfor %}
20
+ {% endif %}
21
22
{%- for line in opt.description.split('\n') %}
23
{{ line }}
0 commit comments