Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add notices for unreleased/out of date docs.
  • Loading branch information
Fizzadar committed Nov 26, 2020
1 parent a778f18 commit 1bfe0c9
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
13 changes: 13 additions & 0 deletions guzzle_sphinx_theme/guzzle_sphinx_theme/layout.html
Expand Up @@ -128,6 +128,19 @@
{%- block document_wrapper %}
{%- block document %}
<div id="right-column">
{% if version != theme_primary_doc_version %}
{% if version == theme_latest_doc_version %}
<div class="admonition important">
<p class="first admonition-title">Documentation may contain unreleased features!</p>
<p>You are reading most recent documentation which may not have been released yet. <a href="/{{ language }}/{{ theme_primary_doc_version }}"><strong>{{ theme_primary_doc_version }}</strong></a> is the latest release version available.</p>
</div>
{% else %}
<div class="admonition important">
<p class="first admonition-title">Documentation may be out of date!</p>
<p>You are not reading the most recent version the documentation. <a href="/{{ language }}/{{ theme_primary_doc_version }}"><strong>{{ theme_primary_doc_version }}</strong></a> is the latest release version available.</p>
</div>
{% endif %}
{% endif %}
<div class="document clearer body" role="main">
{% block body %} {% endblock %}
</div>
Expand Down
10 changes: 10 additions & 0 deletions guzzle_sphinx_theme/guzzle_sphinx_theme/theme.conf
Expand Up @@ -33,7 +33,17 @@ globaltoc_collapse = true
# If true, the global TOC tree will also contain hidden entries
globaltoc_includehidden = true

# Angolia docsearch
docsearch_api_key =
docsearch_index_name =

# Plausible tracking
plausible_domain =
plausible_stats_domain =

# Documentation versions
doc_versions =
# Primary doc version, ie tracking latest version/similar
primary_doc_version =
# Latest doc version, ie tracking latest commit
latest_doc_version = latest

0 comments on commit 1bfe0c9

Please sign in to comment.