From 859013673ffbd0a189acb774680d500552a0e5ab Mon Sep 17 00:00:00 2001 From: heymarcin Date: Thu, 2 Jan 2025 19:14:02 +0000 Subject: [PATCH] added _layouts --- _layouts/archives.html | 34 ++++++++ _layouts/post.html | 179 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 213 insertions(+) create mode 100644 _layouts/archives.html create mode 100644 _layouts/post.html diff --git a/_layouts/archives.html b/_layouts/archives.html new file mode 100644 index 0000000..3c1bda2 --- /dev/null +++ b/_layouts/archives.html @@ -0,0 +1,34 @@ +--- +layout: page +# The Archives of posts. +--- +{% include lang.html %} + +{% assign df_strftime_m = site.data.locales[lang].df.archives.strftime | default: '/ %m' %} +{% assign df_dayjs_m = site.data.locales[lang].df.archives.dayjs | default: '/ MM' %} + +
+ {% for post in site.posts %} + {% assign cur_year = post.date | date: '%Y' %} + + {% if cur_year != last_year %} + {% unless forloop.first %}{% endunless %} + + + {{ '{% endif %} + {% endfor %} +
diff --git a/_layouts/post.html b/_layouts/post.html new file mode 100644 index 0000000..e0fe200 --- /dev/null +++ b/_layouts/post.html @@ -0,0 +1,179 @@ +--- +layout: default +refactor: true +panel_includes: + - toc +tail_includes: + - related-posts + - post-nav +script_includes: + - comment +--- +{% include lang.html %} + +{% include toc-status.html %} + +
+
+

{{ page.title }}

+ {% if page.description %} +

{{ page.description }}

+ {% endif %} + + +
+ + {% if enable_toc %} + + + + + +
+
{{- page.title -}}
+ +
+
+
+ {% endif %} + +
+ {{ content }} +
+ +
+ + {% if page.categories.size > 0 %} + + {% endif %} + + + {% if page.tags.size > 0 %} + + {% endif %} + +
+
+ {% if site.data.locales[lang].copyright.license.template %} + {% capture _replacement %} + + {{ site.data.locales[lang].copyright.license.name }} + + {% endcapture %} + + {{ site.data.locales[lang].copyright.license.template | replace: ':LICENSE_NAME', _replacement }} + {% endif %} +
+ + {% include post-sharing.html lang=lang %} +
+ +
+ +