diff --git a/templates/article.html b/templates/article.html index 07c62e9..19806c1 100644 --- a/templates/article.html +++ b/templates/article.html @@ -12,126 +12,8 @@ {%- endif -%}
- {%- if page.extra.banner -%} - - {%- endif -%} - -
- {%- if page.date -%} -

- - - {%- if page.updated -%} - {{ config.extra.separator | default(value="•") }} - - {%- endif -%} - -

- {%- endif -%} - -

{{ page.title }}

- - {%- if page.authors or config.extra.show_reading_time -%} -

- - {%- if page.authors -%} - {% include "partials/authors.html" -%} - {%- if config.extra.show_reading_time -%} - {{ config.extra.separator | default(value="•") }} - {%- endif -%} - {%- endif -%} - - {%- if config.extra.show_reading_time -%} - {{ macros_translate::translate(key="minutes_read", number=page.reading_time, default="$NUMBER minute read", language_strings=language_strings) }} - {%- if page.taxonomies -%} - {{ config.extra.separator | default(value="•") }} - {%- endif -%} - {%- endif -%} - -

- {%- endif -%} - - {%- if page.taxonomies -%} - {%- for name, taxon in page.taxonomies %} - - {%- endfor -%} - {%- endif %} -
- -
- {%- if page.extra.toc and page.toc | length > 0 -%} -
- -
- {{ macros_translate::translate(key="table_of_contents", default="Table of Contents", language_strings=language_strings) }} -
- <{{ list_element }}> - {%- for h1 in page.toc -%} -
  • - {{ h1.title }} - {%- if h1.children -%} - <{{ list_element }}> - {%- for h2 in h1.children -%} -
  • - {{ h2.title }} -
  • - {%- endfor -%} - - {%- endif -%} - - {%- endfor -%} - -
    -
    -
    - {%- endif -%} - {%- if config.extra.show_backlinks and page.backlinks | length > 0 -%} - - {%- endif -%} - - {%- if config.extra.show_share_button -%} - - {%- endif -%} - {%- if config.extra.issues_url -%} - - {%- endif -%} -
    - - {%- include "partials/statements.html" -%} - - {%- if page.extra.toc_inline -%} - {%- include "partials/toc.html" -%} - {%- elif config.extra.toc_inline -%} - {%- include "partials/toc.html" -%} - {%- endif -%} - - {{ page.content | safe }} + {% include "partials/banner.html" %} + {% include "partials/article_content.html" %}
    {%- if page.extra.comments.id -%} diff --git a/templates/article_list.html b/templates/article_list.html index a623199..559b707 100644 --- a/templates/article_list.html +++ b/templates/article_list.html @@ -43,24 +43,6 @@

    {% include "partials/articles.html" %} +{% include "partials/paginator.html" %} -{%- if paginator.pages -%} - -{%- endif -%} {% endblock content %} diff --git a/templates/documentation_page.html b/templates/documentation_page.html index 6b2878a..bea4b00 100644 --- a/templates/documentation_page.html +++ b/templates/documentation_page.html @@ -19,103 +19,7 @@ expand-main {% include "partials/docs_toc.html" %}
    -
    - -

    {{ page.title }}

    - - {%- if page.authors or config.extra.show_reading_time -%} -

    - - {%- if page.authors -%} - {% include "partials/authors.html" -%} - {%- if config.extra.show_reading_time -%} - {{ config.extra.separator | default(value="•") }} - {%- endif -%} - {%- endif -%} - - {%- if config.extra.show_reading_time -%} - {{ macros_translate::translate(key="minutes_read", number=page.reading_time, default="$NUMBER minute read", language_strings=language_strings) }} - {%- if page.taxonomies -%} - {{ config.extra.separator | default(value="•") }} - {%- endif -%} - {%- endif -%} - -

    - {%- endif -%} - - {%- if page.taxonomies -%} - {%- for name, taxon in page.taxonomies %} - - {%- endfor -%} - {%- endif %} -
    - -
    - {%- if page.extra.toc and page.toc | length > 0 -%} -
    - -
    - {{ macros_translate::translate(key="table_of_contents", default="Table of Contents", language_strings=language_strings) }} -
    - <{{ list_element }}> - {%- for h1 in page.toc -%} -
  • - {{ h1.title }} - {%- if h1.children -%} - <{{ list_element }}> - {%- for h2 in h1.children -%} -
  • - {{ h2.title }} -
  • - {%- endfor -%} - - {%- endif -%} - - {%- endfor -%} - -
    -
    -
    - {%- endif -%} - {%- if config.extra.show_backlinks and page.backlinks | length > 0 -%} - - {%- endif -%} - - {%- if config.extra.show_share_button -%} - - {%- endif -%} - {%- if config.extra.issues_url -%} - - {%- endif -%} -
    - - {%- include "partials/statements.html" -%} - - {%- if page.extra.toc_inline -%} - {%- include "partials/toc.html" -%} - {%- elif config.extra.toc_inline -%} - {%- include "partials/toc.html" -%} - {%- endif -%} - - {{ page.content | safe }} + {% include "partials/article_content.html" %}
    diff --git a/templates/partials/article_content.html b/templates/partials/article_content.html new file mode 100644 index 0000000..9bccb27 --- /dev/null +++ b/templates/partials/article_content.html @@ -0,0 +1,114 @@ +
    + {%- if page.date -%} +

    + + + {%- if page.updated -%} + {{ config.extra.separator | default(value="•") }} + + {%- endif -%} + +

    + {%- endif -%} + +

    {{ page.title }}

    + + {%- if page.authors or config.extra.show_reading_time -%} +

    + + {%- if page.authors -%} + {% include "partials/authors.html" -%} + {%- if config.extra.show_reading_time -%} + {{ config.extra.separator | default(value="•") }} + {%- endif -%} + {%- endif -%} + + {%- if config.extra.show_reading_time -%} + {{ macros_translate::translate(key="minutes_read", number=page.reading_time, default="$NUMBER minute read", language_strings=language_strings) }} + {%- if page.taxonomies -%} + {{ config.extra.separator | default(value="•") }} + {%- endif -%} + {%- endif -%} + +

    + {%- endif -%} + + {%- if page.taxonomies -%} + {%- for name, taxon in page.taxonomies %} + + {%- endfor -%} + {%- endif %} +
    + +
    + {%- if page.extra.toc and page.toc | length > 0 -%} +
    + +
    + {{ macros_translate::translate(key="table_of_contents", default="Table of Contents", language_strings=language_strings) }} +
    + <{{ list_element }}> + {%- for h1 in page.toc -%} +
  • + {{ h1.title }} + {%- if h1.children -%} + <{{ list_element }}> + {%- for h2 in h1.children -%} +
  • + {{ h2.title }} +
  • + {%- endfor -%} + + {%- endif -%} + + {%- endfor -%} + +
    +
    +
    + {%- endif -%} + {%- if config.extra.show_backlinks and page.backlinks | length > 0 -%} + + {%- endif -%} + + {%- if config.extra.show_share_button -%} + + {%- endif -%} + {%- if config.extra.issues_url -%} + + {%- endif -%} +
    + +{%- include "partials/statements.html" -%} + +{%- if page.extra.toc_inline -%} + {%- include "partials/toc.html" -%} +{%- elif config.extra.toc_inline -%} + {%- include "partials/toc.html" -%} +{%- endif -%} + +{{ page.content | safe }} diff --git a/templates/partials/banner.html b/templates/partials/banner.html new file mode 100644 index 0000000..f69d726 --- /dev/null +++ b/templates/partials/banner.html @@ -0,0 +1,5 @@ +{%- if page.extra.banner -%} + +{%- endif -%} diff --git a/templates/partials/paginator.html b/templates/partials/paginator.html new file mode 100644 index 0000000..a55f792 --- /dev/null +++ b/templates/partials/paginator.html @@ -0,0 +1,19 @@ +{%- if paginator.pages -%} + +{%- endif -%} diff --git a/templates/subproject.html b/templates/subproject.html index e932137..cc0f3a4 100644 --- a/templates/subproject.html +++ b/templates/subproject.html @@ -12,109 +12,8 @@ {%- set section = get_section(path=page.ancestors | last) -%}
    - {%- if page.extra.banner -%} - - {%- endif -%} - -
    - -

    {{ page.title }}

    - - {%- if page.authors or config.extra.show_reading_time -%} -

    - - {%- if page.authors -%} - {% include "partials/authors.html" -%} - {%- if config.extra.show_reading_time -%} - {{ config.extra.separator | default(value="•") }} - {%- endif -%} - {%- endif -%} - - {%- if config.extra.show_reading_time -%} - {{ macros_translate::translate(key="minutes_read", number=page.reading_time, default="$NUMBER minute read", language_strings=language_strings) }} - {%- if page.taxonomies -%} - {{ config.extra.separator | default(value="•") }} - {%- endif -%} - {%- endif -%} - -

    - {%- endif -%} - - {%- if page.taxonomies -%} - {%- for name, taxon in page.taxonomies %} -
      - {%-for item in taxon -%} -
    • {{ item }}
    • - {%- endfor %} -
    - {%- endfor -%} - {%- endif %} -
    - -
    - {%- if page.extra.toc and page.toc | length > 0 -%} -
    - -
    - {{ macros_translate::translate(key="table_of_contents", default="Table of Contents", language_strings=language_strings) }} -
    - <{{ list_element }}> - {%- for h1 in page.toc -%} -
  • - {{ h1.title }} - {%- if h1.children -%} - <{{ list_element }}> - {%- for h2 in h1.children -%} -
  • - {{ h2.title }} -
  • - {%- endfor -%} - - {%- endif -%} - - {%- endfor -%} - -
    -
    -
    - {%- endif -%} - {%- if config.extra.show_backlinks and page.backlinks | length > 0 -%} - - {%- endif -%} - - {%- if config.extra.show_share_button -%} - - {%- endif -%} - {%- if config.extra.issues_url -%} - - {%- endif -%} -
    - - {%- include "partials/statements.html" -%} - - {%- if page.extra.toc_inline -%} - {%- include "partials/toc.html" -%} - {%- elif config.extra.toc_inline -%} - {%- include "partials/toc.html" -%} - {%- endif -%} - - {{ page.content | safe }} + {% include "partials/banner.html" %} + {% include "partials/article_content.html" %}
    {%- if page.extra.comments.id -%} diff --git a/templates/subproject_list.html b/templates/subproject_list.html index cbe2155..67920e3 100644 --- a/templates/subproject_list.html +++ b/templates/subproject_list.html @@ -43,24 +43,6 @@

    {% include "partials/subprojects.html" %} +{% include "partials/paginator.html" %} -{%- if paginator.pages -%} - -{%- endif -%} {% endblock content %}