From: Michael Tremer Date: Thu, 14 Dec 2023 15:19:45 +0000 (+0000) Subject: docs: Refactor the file listing page X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=300cd067719db1de942ef0b6bafe051e190a6f76;p=ipfire.org.git docs: Refactor the file listing page Signed-off-by: Michael Tremer --- diff --git a/src/templates/docs/files/index.html b/src/templates/docs/files/index.html index 70f8ce1f..ca01a431 100644 --- a/src/templates/docs/files/index.html +++ b/src/templates/docs/files/index.html @@ -6,36 +6,37 @@ {% if files %}
-

{{ _("Files") }}

- -
+
{% for f in files %} - {% if f.is_image() %} -
- - {{ f.filename }} -

{{ f.filename }}

-
-
- {% end %} - {% end %} -
+
+
+
+ {% if f.is_image() %} + +
+ {{ f.filename }} +
+
+ {% elif "pdf" in f.mimetype %} + + + + {% else %} + + + + {% end %} +
-
    - {% for f in files %} - {% if not f.is_image() %} -
  • - {% if "pdf" in f.mimetype %} - - {% else %} - - {% end %} - - {{ f.filename }} -
  • - {% end %} + +
+
{% end %} - +
{% end %}