From 1bcef7aa909aec7f62b89d6416d81e547c4ff836 Mon Sep 17 00:00:00 2001 From: timvisee Date: Mon, 1 Jul 2019 17:43:22 +0200 Subject: [PATCH] Port remaining pages, custom anchor links, various style improvements --- content/_index.md | 1 + content/about.md | 3 +- content/projects.md | 1 - content/projects/bukkit.md | 4 +- content/projects/bukkit/dungeon-maze.md | 1 - themes/zenn/sass/site.scss | 21 +++ themes/zenn/templates/anchor-link.html | 5 + themes/zenn/templates/categories/list.html | 15 ++ themes/zenn/templates/categories/single.html | 10 ++ themes/zenn/templates/index.html | 147 +++---------------- themes/zenn/templates/page.html | 49 +++++++ themes/zenn/templates/site.html | 139 ++++++++++++++++++ themes/zenn/templates/tags/list.html | 13 ++ themes/zenn/templates/tags/single.html | 9 ++ 14 files changed, 281 insertions(+), 137 deletions(-) create mode 100644 themes/zenn/templates/anchor-link.html create mode 100644 themes/zenn/templates/categories/list.html create mode 100644 themes/zenn/templates/categories/single.html create mode 100644 themes/zenn/templates/page.html create mode 100644 themes/zenn/templates/site.html create mode 100644 themes/zenn/templates/tags/list.html create mode 100644 themes/zenn/templates/tags/single.html diff --git a/content/_index.md b/content/_index.md index 5ae57b8..faffb70 100644 --- a/content/_index.md +++ b/content/_index.md @@ -1,3 +1,4 @@ +++ +title = "Homepage" paginate_by = 5 +++ diff --git a/content/about.md b/content/about.md index 996b854..5547670 100644 --- a/content/about.md +++ b/content/about.md @@ -1,9 +1,8 @@ +++ -title = "About" +title = "About me" description = "About me" +++ -# About me Open-source & free software enthusiast · Linux fanatic · Rust evangelist · Git master · Vim wizard Self-educated software engineer started at 8 years old, always looking to expand my technical knowledge with challenging projects. diff --git a/content/projects.md b/content/projects.md index d1a781e..f683e5b 100644 --- a/content/projects.md +++ b/content/projects.md @@ -3,7 +3,6 @@ title = "Projects" description = "Projects index" +++ -# Projects This page lists some of the projects I've developed over time. - [Bukkit projects](/projects/bukkit) diff --git a/content/projects/bukkit.md b/content/projects/bukkit.md index 53d69d8..48f4d2c 100644 --- a/content/projects/bukkit.md +++ b/content/projects/bukkit.md @@ -1,8 +1,6 @@ +++ -name = "Bukkit projects" +title = "Bukkit projects" description = "Bukkit projects index" +++ -# Bukkit projects - - [Dungeon Maze](bukkit/dungeon-maze/) diff --git a/content/projects/bukkit/dungeon-maze.md b/content/projects/bukkit/dungeon-maze.md index 3e00fb1..15d1711 100644 --- a/content/projects/bukkit/dungeon-maze.md +++ b/content/projects/bukkit/dungeon-maze.md @@ -4,7 +4,6 @@ description = "Dungeon Maze Bukkit plugin" date = 2015-10-06 +++ -# Dungeon Maze - An epic Minecraft world generator _Current version: v0.1.5.2_ Dungeon Maze is a world generator for Minecraft, it's a CraftBukkit plugin. diff --git a/themes/zenn/sass/site.scss b/themes/zenn/sass/site.scss index 0b024eb..1fec056 100644 --- a/themes/zenn/sass/site.scss +++ b/themes/zenn/sass/site.scss @@ -294,3 +294,24 @@ content .tag { sidebar .tag { background-color: $background; } + +p { + line-height: 1.5; +} + +footer { + font-family: $font-title; +} + +.anchor { + transition: opacity 0.5s ease; + opacity: 0; + font-size: 1rem; + position: relative; + left: 0.5rem; +} +*:hover > .anchor, +.anchor:active, +.anchor:focus { + opacity: 1; +} diff --git a/themes/zenn/templates/anchor-link.html b/themes/zenn/templates/anchor-link.html new file mode 100644 index 0000000..f50fc99 --- /dev/null +++ b/themes/zenn/templates/anchor-link.html @@ -0,0 +1,5 @@ +{% if id %} + 🔗 +{% else %} + 🔗 +{% endif %} diff --git a/themes/zenn/templates/categories/list.html b/themes/zenn/templates/categories/list.html new file mode 100644 index 0000000..b55f66b --- /dev/null +++ b/themes/zenn/templates/categories/list.html @@ -0,0 +1,15 @@ +{% extends "site.html" %} + +{% block body %} +

Categories

+ + {% if terms %} + + {% endif %} +{% endblock body %} diff --git a/themes/zenn/templates/categories/single.html b/themes/zenn/templates/categories/single.html new file mode 100644 index 0000000..a89bf3e --- /dev/null +++ b/themes/zenn/templates/categories/single.html @@ -0,0 +1,10 @@ +{% extends "site.html" %} +{% import "post_macros.html" as post_macros %} + +{% block body %} +

Category: {{ term.name }}

+ + {% for page in term.pages %} + {{ post_macros::page_in_list(page=page) }} + {% endfor %} +{% endblock body %} diff --git a/themes/zenn/templates/index.html b/themes/zenn/templates/index.html index 71c5c8f..c0c6e06 100644 --- a/themes/zenn/templates/index.html +++ b/themes/zenn/templates/index.html @@ -1,133 +1,20 @@ +{% extends "site.html" %} {% import "post_macros.html" as post_macros %} - - - - - +{% block body %} + {% for page in paginator.pages %} + {{ post_macros::page_in_list(page=page) }} + {% endfor %} - - - - - - {% block title %} - {% if page.title %} - {{ page.title }} · - {% endif %} - {% if section.title %} - {{ section.title }} · - {% endif %} - {{ config.title }} - {% endblock title %} - - - {% block css %} - - - {% endblock css %} - - {% if config.generate_rss %} - - {% endif %} - - {% block extra_head %} - {% endblock extra_head %} - - - - {% if config.extra.zenn_title %} - {% block header %} -
- -
- {% endblock header %} - {% endif %} - - {% block content %} -
- - {% if section.title %} -

{{ section.title }}

- {% endif %} - - {% for page in paginator.pages %} - {{ post_macros::page_in_list(page=page) }} - {% endfor %} - - -
- - {% if config.extra.zenn_menu %} -
- -
- {% endif %} - -
-

Categories

-
- -
-
- -
-

Tags

-
- test - test - test - test - test - test - test -
-
- -

- Copyright © {{ config.title }} {{ now() | date(format="%Y") }} - {% if config.extra.zenn_source %} -
Source - {% endif %} -

-
-
- {% endblock content %} - - - + +{% endblock body %} diff --git a/themes/zenn/templates/page.html b/themes/zenn/templates/page.html new file mode 100644 index 0000000..8145b02 --- /dev/null +++ b/themes/zenn/templates/page.html @@ -0,0 +1,49 @@ +{% extends "site.html" %} + +{% block header_meta %} + {{ post_macros::meta(page=page) }} +{% endblock header_meta %} + +{% block body %} +
+ {# +
+

{{ page.title }}

+ {{ post_macros::meta(page=page) }} +
+ #} + +
+ {{ page.content | safe }} +
+
+{% endblock body %} + +{% block page_footer %} + +{% endblock page_footer %} diff --git a/themes/zenn/templates/site.html b/themes/zenn/templates/site.html new file mode 100644 index 0000000..76d15b9 --- /dev/null +++ b/themes/zenn/templates/site.html @@ -0,0 +1,139 @@ +{% import "post_macros.html" as post_macros %} + + + + + + + + + + + + + {% block title %} + {% if page.title %} + {{ page.title }} · + {% endif %} + {% if section.title %} + {{ section.title }} · + {% endif %} + {{ config.title }} + {% endblock title %} + + + {% block css %} + + + {% endblock css %} + + {% if config.generate_rss %} + + {% endif %} + + {% block extra_head %} + {% endblock extra_head %} + + + + {% if config.extra.zenn_title %} + {% block header %} +
+ +
+ {% endblock header %} + {% endif %} + + {% block main %} +
+ + {% if section.title %} +

+ {{ section.title }} + + {% if paginator %} + {% if paginator.current_index > 1 %} +  ·  Page {{ paginator.current_index }} + {% endif %} + {% endif %} + + {% include "anchor-link.html" %} +

+ {% endif %} + {% if page.title %} +

+ {{ page.title }} + + {% include "anchor-link.html" %} +

+ {% endif %} + {% block header_meta %}{% endblock header_meta %} + + {% block body %}{% endblock body %} + + {% block page_footer %}{% endblock page_footer %} +
+ + {% if config.extra.zenn_menu %} +
+ +
+ {% endif %} + +
+

Categories

+
+ +
+
+ +
+

Tags

+
+ test + test + test + test + test + test + test +
+
+ +

+ Copyright © {{ config.title }} {{ now() | date(format="%Y") }} + {% if config.extra.zenn_source %} +
Source + {% endif %} +

+
+
+ {% endblock main %} + + + diff --git a/themes/zenn/templates/tags/list.html b/themes/zenn/templates/tags/list.html new file mode 100644 index 0000000..31d1b0e --- /dev/null +++ b/themes/zenn/templates/tags/list.html @@ -0,0 +1,13 @@ +{% extends "site.html" %} + +{% block body %} +

Tags

+ + {% if terms %} + + {% endif %} +{% endblock body %} diff --git a/themes/zenn/templates/tags/single.html b/themes/zenn/templates/tags/single.html new file mode 100644 index 0000000..f2d864b --- /dev/null +++ b/themes/zenn/templates/tags/single.html @@ -0,0 +1,9 @@ +{% extends "site.html" %} + +{% block body %} +

Tag: {{ term.name }}

+ + {% for page in term.pages %} + {{ post_macros::page_in_list(page=page) }} + {% endfor %} +{% endblock body %}