From 21d521fb601e7f60ef357b20bc0e6ce1ed5f69ef Mon Sep 17 00:00:00 2001 From: Dan <14043624+delivrance@users.noreply.github.com> Date: Mon, 8 Jan 2018 05:17:55 +0100 Subject: [PATCH] Update docs --- compiler/docs/compiler.py | 3 ++ docs/source/_templates/footer.html | 60 ++++++++++++++++++++++++++++++ docs/source/conf.py | 16 +++++--- 3 files changed, 73 insertions(+), 6 deletions(-) create mode 100644 docs/source/_templates/footer.html diff --git a/compiler/docs/compiler.py b/compiler/docs/compiler.py index af9d1315..63d41a00 100644 --- a/compiler/docs/compiler.py +++ b/compiler/docs/compiler.py @@ -95,6 +95,9 @@ def generate(source_path, base): module = "pyrogram.api.{}".format(base) with open(destination + "/" + inner_path, "w") as f: + # if k == base: + # f.write(":tocdepth: 1\n\n") + f.write( toctree.format( title=k.title(), diff --git a/docs/source/_templates/footer.html b/docs/source/_templates/footer.html new file mode 100644 index 00000000..54924f63 --- /dev/null +++ b/docs/source/_templates/footer.html @@ -0,0 +1,60 @@ + diff --git a/docs/source/conf.py b/docs/source/conf.py index 439c0a1a..75b2474e 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -84,27 +84,31 @@ language = None exclude_patterns = [] # The name of the Pygments (syntax highlighting) style to use. -pygments_style = 'sphinx' +pygments_style = 'tango' # If true, `todo` and `todoList` produce output, else they produce nothing. todo_include_todos = False # -- Options for HTML output ---------------------------------------------- +# Overridden by template +html_show_copyright = False + # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. # html_theme = 'sphinx_rtd_theme' -html_theme_options = { - 'collapse_navigation': False -} - # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the # documentation. # -# html_theme_options = {} +html_theme_options = { + 'canonical_url': "https://docs.pyrogram.ml/", + 'collapse_navigation': False, + 'sticky_navigation': False, + 'logo_only': True +} # The name of an image file (relative to this directory) to place at the top # of the sidebar.