diff --git a/_templates/page.html b/_templates/page.html new file mode 100644 index 00000000000..9236eb85d68 --- /dev/null +++ b/_templates/page.html @@ -0,0 +1,40 @@ +{% extends "!page.html" %} +{% block header %} + +{% endblock %} +{% block body %} +{% if current_version and latest_version and current_version != latest_version %} +

+ + {% if current_version.name|string() in eol_versions %} + You're reading the documentation for a version of ROS 2 that has reached its EOL (end-of-life), and is no longer officially supported. + If you want up-to-date information, please have a look at {{latest_version.name | title }}. + {% elif current_version.is_released %} + You're reading the documentation for an older, but still supported, version of ROS 2. + For information on the latest version, please have a look at {{latest_version.name | title }}. + {% else %} + You're reading the documentation for a development version. + For the latest released version, please have a look at {{latest_version.name | title }}. + {% endif %} + +

+{% endif %} +{{ super() }} +{% endblock %}% diff --git a/_templates/versions.html b/_templates/versions.html index ba167ae12ec..faafdff558e 100644 --- a/_templates/versions.html +++ b/_templates/versions.html @@ -6,17 +6,11 @@
-
-
In Development
- {%- for item in versions.in_development|sort(reverse=True) %} -
{{ item.name|title }} (latest)
- {%- endfor %} -
Releases
{%- for item in versions.releases|sort(reverse=True) %} {%- if item.name == latest_version.name %} -
{{ item.name|title }} (recommended)

+
{{ item.name|title }} (latest)

{%- elif item.name in eol_versions %}
{{ item.name|title }} (EOL)

{% else %} @@ -24,6 +18,12 @@ {%- endif %} {%- endfor %}
+
+
In Development
+ {%- for item in versions.in_development|sort(reverse=True) %} +
{{ item.name|title }}
+ {%- endfor %} +
-{%- endif %} \ No newline at end of file +{%- endif %}