Add a download card for use in articles

This commit is contained in:
Yuri Sizov
2023-10-25 17:58:01 +02:00
parent 6a43e5ce7b
commit 9863552ad6
12 changed files with 255 additions and 54 deletions

View File

@@ -0,0 +1,19 @@
{% unless page.no_outdated_notice %}
{% unless page.categories contains "release" or page.categories contains "pre-release" or page.categories contains "showcase" %}
{% comment %}
`site.outdated_article_threshold` is generated by `_plugins/outdated_article_threshold.rb`.
{% endcomment %}
{% if page.date < site.outdated_article_threshold %}
<div class="card card-warning">
<p>
{% if page.outdated_notice_text %}
{{ page.outdated_notice_text }}
{% else %}
This article is from <strong>{{ page.date | date: "%B %Y" }}</strong>, some of its contents might be outdated and no longer accurate.<br>
You can find up-to-date information about the engine in the <a href="https://docs.godotengine.org/en/stable/">official documentation</a>.
{% endif %}
</p>
</div>
{% endif %}
{% endunless %}
{% endunless %}