From c828c5e1229265bf9a35747873fc296c4d7d3435 Mon Sep 17 00:00:00 2001 From: Mathias Rav Date: Sat, 30 Jun 2018 12:18:26 +0200 Subject: [PATCH] Update documentation for WIKI_MARKDOWN_KWARGS Also remove unused entry in default MARKDOWN_KWARGS. --- src/wiki/conf/settings.py | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/src/wiki/conf/settings.py b/src/wiki/conf/settings.py index 69c6a97a..23c110b3 100644 --- a/src/wiki/conf/settings.py +++ b/src/wiki/conf/settings.py @@ -28,11 +28,16 @@ MARKDOWN_SANITIZE_HTML = getattr( #: Arguments for the Markdown instance, for instance a list of extensions to #: use. -#: See: https://pythonhosted.org/Markdown/extensions/index.html +#: See: https://python-markdown.github.io/extensions/ #: -#: To set a custom title for TOC's:: +#: To set a custom title for table of contents, specify the following in your +#: Django project settings:: #: -#: WIKI_MARKDOWN_KWARGS = {'extension_configs': {'toc': _('Contents of this article')}} +#: WIKI_MARKDOWN_KWARGS = { +#: 'extension_configs': { +#: 'wiki.plugins.macros.mdx.toc': {'title': 'Contents of this article'}, +#: }, +#: } MARKDOWN_KWARGS = { 'extensions': [ 'markdown.extensions.footnotes', @@ -45,9 +50,6 @@ MARKDOWN_KWARGS = { 'markdown.extensions.abbr', 'markdown.extensions.sane_lists', ], - 'extension_configs': { - 'toc': { - 'title': _('Table of Contents')}}, } MARKDOWN_KWARGS.update(getattr(django_settings, 'WIKI_MARKDOWN_KWARGS', {})) -- 2.45.2