diff --git a/config/mkdocs-offline.yml b/config/mkdocs-offline.yml index 384dc69fd4..431bd59afe 100644 --- a/config/mkdocs-offline.yml +++ b/config/mkdocs-offline.yml @@ -145,7 +145,6 @@ nav: - About: - 'about/index.md' - 'about/criteria.md' - - 'about/statistics.md' - 'about/notices.md' - 'about/privacy-policy.md' - Community: diff --git a/theme/main.html b/theme/main.html index 9eb5ccd7b5..cc2054da74 100644 --- a/theme/main.html +++ b/theme/main.html @@ -69,24 +69,7 @@ {{ config.site_name }} {% endif %} {% endblock %} -{% block announce %}{% if config.extra.offline %} - You're viewing an offline copy of Privacy Guides built on {{ build_date_utc }}. - - Visit privacyguides.org for the latest version. - -{% elif config.extra.context == "deploy-preview" %} - You're viewing an unreviewed preview of Privacy Guides built on {{ build_date_utc }}. - These previews are user-submitted and may not necessarily reflect the opinion of the site. - - Visit privacyguides.org for current advice. - -{% elif config.extra.context == "branch-deploy" %} - You're viewing a staging branch of Privacy Guides built on {{ build_date_utc }}. - The information on this page may be incomplete or otherwise not yet meet our editorial release standards. - - Visit privacyguides.org for current advice. - -{% else %}{% endif %}{% endblock %} + {% block extrahead %} {% if config.extra.context == "production" %} diff --git a/theme/partials/header.html b/theme/partials/header.html index 2ce3b75982..b4516c3bc6 100644 --- a/theme/partials/header.html +++ b/theme/partials/header.html @@ -21,6 +21,35 @@ IN THE SOFTWARE. --> +{% macro notice() %}{% if config.extra.offline %} + You're viewing an offline copy of Privacy Guides built on {{ build_date_utc.strftime('%B %d, %Y at %I:%M%p') }}. + + Visit privacyguides.org for the latest version. + +{% elif config.extra.context == "deploy-preview" %} + You're viewing an unreviewed preview of Privacy Guides built on {{ build_date_utc.strftime('%B %d, %Y at %I:%M%p') }}. + These previews are user-submitted and may not necessarily reflect the opinion of the site. + + Visit privacyguides.org for current advice. + +{% elif config.extra.context == "branch-deploy" %} + You're viewing a staging branch of Privacy Guides built on {{ build_date_utc.strftime('%B %d, %Y at %I:%M%p') }}. + The information on this page may be incomplete or otherwise not yet meet our editorial release standards. + + Visit privacyguides.org for current advice. + +{% else %}{% endif %}{% endmacro %} + +{% if notice() %} +
+ +
+{% endif %} + {% set class = "md-header" %} {% if "navigation.tabs.sticky" in features %}