aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans-Nikolai Viessmann2020-07-24 11:50:20 +0200
committerHans-Nikolai Viessmann2020-07-24 11:50:20 +0200
commit7d1a7134b52676ca1de92ab15e2968fcc6a2240f (patch)
tree14b578ed90c7b5ff062b88eb2fc6f45c37c1a5b7
parentc41fe3ca569253ee24c6aaf4d3a82082897d16c4 (diff)
downloadpelican-theme-edream-7d1a7134b52676ca1de92ab15e2968fcc6a2240f.tar.gz
pelican-theme-edream-7d1a7134b52676ca1de92ab15e2968fcc6a2240f.zip
completed basic outline
-rw-r--r--static/css/main.css44
-rw-r--r--templates/article.html15
-rw-r--r--templates/base.html67
-rw-r--r--templates/index.html3
-rw-r--r--templates/links.html2
-rw-r--r--templates/metadata.inc.html12
-rw-r--r--templates/page.html2
-rw-r--r--templates/projects.html2
8 files changed, 98 insertions, 49 deletions
diff --git a/static/css/main.css b/static/css/main.css
index 8d71b24..27bf5a5 100644
--- a/static/css/main.css
+++ b/static/css/main.css
@@ -1,3 +1,4 @@
+/* sticky footer (flexbox) */
.footer-sticky {
flex: none;
}
@@ -10,4 +11,47 @@
.sticky-skip {
flex: 1;
+ margin-bottom: 2rem;
+}
+
+/* override section class */
+div .section {
+ padding: 1rem 0rem;
+}
+
+/* special size */
+.aside-column {
+ width: 185px;
+ text-align: right;
+}
+
+#menu-top {
+ display: inherit;
+}
+
+header {
+ margin-top: 2rem;
+}
+
+@media screen and (min-width: 769px), print {
+ #menu-top {
+ display: none;
+ }
+}
+
+@media screen and (max-width: 768px) {
+ .aside-column {
+ width: auto;
+ text-align: left;
+ }
+ #menu-aside {
+ display: none;
+ }
+ header {
+ margin-top: 0;
+ }
+ .sticky-skip {
+ margin-left: 1rem;
+ margin-right: 1rem;
+ }
}
diff --git a/templates/article.html b/templates/article.html
index 1332097..3ff1c02 100644
--- a/templates/article.html
+++ b/templates/article.html
@@ -1,24 +1,13 @@
{% extends "base.html" %}
{% block title %}{{ article.title }} - {{ SITENAME }}{% endblock %}
+{% block page_title %}{{ article.title }}{% endblock %}
{% block extra_meta %}
<meta name="description" content="{{ article.summary|striptags }}">
{% endblock %}
{% block content %}
-<div class="level">
- <div class="level-left" style="margin-top: auto">
- <div class="level-item">
- <h1 class="title">{{ article.title }}</h1>
- </div>
- </div>
- <div class="level-right">
- <div class="level-item">
- {% include 'metadata.inc.html' %}
- </div>
- </div>
-</div>
-<hr>
+{% include 'metadata.inc.html' %}
<article class="content">
{{ article.content }}
</article>
diff --git a/templates/base.html b/templates/base.html
index 2c1dfb3..9545292 100644
--- a/templates/base.html
+++ b/templates/base.html
@@ -42,48 +42,63 @@ at the humans.txt file at https://blog.viess.mn/humans.txt for more information.
<body class="sticky">
<div class="sticky-skip">
<header>
- <nav class="navbar has-shadow" role="navigation" aria-label="main navigation">
- <div class="container">
- <div class="navbar-brand">
- <a class="navbar-item is-size-4 is-family-monospace" title="From German meaning to be deep in thought, dreaming" href="/">versonnen</a>
- <a role="button" class="navbar-burger burger" aria-label="menu" aria-expanded="false">
- <span aria-hidden="true"></span>
- <span aria-hidden="true"></span>
- <span aria-hidden="true"></span>
- </a>
- </div>
- <div class="navbar-menu">
- <div class="navbar-start">
- <a class="navbar-item" href="#">About Me</a>
- <a class="navbar-item" href="/pages/projects/">Projects</a>
- <a class="navbar-item" href="/pages/links/">Links</a>
+ <div class="container">
+ <div class="columns">
+ <div class="column is-narrow-tablet">
+ <div class="aside-column">
+ <a class="is-size-3 is-family-monospace pr-2" title="From German meaning to be deep in thought, dreaming" href="/">versonnen</a>
+ <div id="menu-top" class="menu">
+ <ul class="menu-list has-text-weight-medium">
+ <li><a href="#">About Me</a></li>
+ <li><a href="/pages/projects/">Projects</a></li>
+ <li><a href="/pages/links/">Links</a></li>
+ </ul>
+ </div>
</div>
</div>
+ <div class="column">
+ <p class="title is-italic">{% block page_title %}{% endblock %}</p>
+ </div>
</div>
- </nav>
+ </div>
</header>
- <main class="container my-5">
+ <main class="container">
+ <div class="columns">
+ <div class="column is-narrow">
+ <div class="aside-column">
+ <div id="menu-aside" class="menu">
+ <ul class="menu-list has-text-weight-medium">
+ <li><a href="#">About Me</a></li>
+ <li><a href="/pages/projects/">Projects</a></li>
+ <li><a href="/pages/links/">Links</a></li>
+ </ul>
+ </div>
+ </div>
+ </div>
+ <div class="column mt-1">
{% block content -%}
{%- endblock content %}
+ </div>
+ </div>
</main>
</div>
<footer class="footer footer-sticky">
<div class="container">
<div class="columns is-vcentered">
<div class="column">
- <div class="my-2"><span class="tag is-info is-medium has-text-weight-bold">TL;DR</span> I am a computer scientist from Germany working in the The Netherlands</div>
- <div class="my-2"><span class="tag is-info is-medium has-text-weight-bold">WORKING ON</span> My PhD thesis...</div>
- <div class="my-2"><span class="tag is-info is-medium has-text-weight-bold">CONTACT</span> Email me at <em>h<span>a</span>ns</em><span></span>@<span></span><em>vie<span></span>ss<span></span>.<span></span>m<span>n</span></em></div>
+ <div class="my-1"><span class="tag is-info has-text-weight-bold">TL;DR</span> I am a computer scientist from Germany working in the The Netherlands</div>
+ <div class="my-1"><span class="tag is-info has-text-weight-bold">WORKING ON</span> My PhD thesis...</div>
+ <div class="my-1"><span class="tag is-info has-text-weight-bold">CONTACT</span> Email me at <em>h<span>a</span>ns</em><span></span>@<span></span><em>vie<span></span>ss<span></span>.<span></span>m<span>n</span></em></div>
</div>
<div class="column" align="right">
- <div class="my-2"><a rel="author" href="/humans.txt"><img alt="Humans.txt" src="{{ SITEURL }}/theme/images/humanstxt-isolated-blank.gif"/></a></div>
- <div class="my-2"><a href="//www.w3.org/html/"><img src="//www.w3.org/html/logo/badge/html5-badge-h-css3-semantics.png" width="83" height="33" alt="HTML5 Powered with CSS3 / Styling, and Semantics" title="HTML5 Powered with CSS3 / Styling, and Semantics"></a></div>
- <div class="my-2"><a rel="license" href="//creativecommons.org/licenses/by-nc-sa/3.0/"><img alt="Creative Commons License" style="border-width:0" src="//i.creativecommons.org/l/by-nc-sa/3.0/88x31.png" /></a></div>
+ <div class="my-4">
+ <a rel="author" href="/humans.txt"><img alt="Humans.txt" src="{{ SITEURL }}/theme/images/humanstxt-isolated-blank.gif"/></a>
+ <a href="//www.w3.org/html/"><img src="//www.w3.org/html/logo/badge/html5-badge-h-css3-semantics.png" width="83" height="33" alt="HTML5 Powered with CSS3 / Styling, and Semantics" title="HTML5 Powered with CSS3 / Styling, and Semantics"></a>
+ <a rel="license" href="//creativecommons.org/licenses/by-nc-sa/3.0/"><img alt="Creative Commons License" style="border-width:0" src="//i.creativecommons.org/l/by-nc-sa/3.0/88x31.png" /></a>
+ </div>
+ <div class="my-2"><a href="{{ SITEURL }}">blog</a> &mdash; <a href="/pages/about-me/">about me</a> &mdash; <a href="/tags.html">tags</a> &mdash; <a href="/categories.html">categories</a> &mdash; <a href="/pages/projects/">projects</a> &mdash; <a href="/pages/links/">links</a> &mdash; <a href="/pages/acknowledgements/">acknowledgements</a></div>
</div>
</div>
- <div class="content has-text-centered">
- <a href="{{ SITEURL }}">blog</a> &mdash; <a href="/pages/about-me/">about me</a> &mdash; <a href="/tags.html">tags</a> &mdash; <a href="/categories.html">categories</a> &mdash; <a href="/pages/projects/">projects</a> &mdash; <a href="/pages/links/">links</a> &mdash; <a href="/pages/acknowledgements/">acknowledgements</a>
- </div>
</div>
</footer>
{% block scripts -%}
diff --git a/templates/index.html b/templates/index.html
index 3b7de1e..3e4bf9a 100644
--- a/templates/index.html
+++ b/templates/index.html
@@ -1,7 +1,8 @@
{% extends "base.html" %}
+{% block title %}Articles - {{ SITENAME }}{% endblock %}
+{% block page_title %}Articles{% endblock %}
{% block content %}
-<h1 class="title">Articles</h1>
<ul>
{% for article in articles %}
<li class="py-2">
diff --git a/templates/links.html b/templates/links.html
index a2fa798..4129fa5 100644
--- a/templates/links.html
+++ b/templates/links.html
@@ -1,6 +1,6 @@
{% extends "base.html" %}
{% block title %}Links - {{ SITENAME }}{% endblock %}
+{% block page_title %}Links{% endblock %}
{% block content %}
-<h1 class="title">Links</h1>
{% endblock %}
diff --git a/templates/metadata.inc.html b/templates/metadata.inc.html
index 85011c2..338e065 100644
--- a/templates/metadata.inc.html
+++ b/templates/metadata.inc.html
@@ -1,6 +1,6 @@
-<div>
- <div><time datetime="{{ article.date.isoformat() }}" pubdate>{{ article.locale_date }}</time></div>
- {% if article and article.modified %}<div><em>(modified <time datetime="{{ article.modified.isoformat() }}">{{ article.locale_modified }}</time>)</em></div>{% endif %}
- <div class="mb-2">Category: <a href="{{ SITEURL }}/{{ article.category.url }}">{{ article.category }}</a></div>
- {% if article.tags %}<p class="tags">{% for tag in article.tags %}<a href="{{ SITEURL }}/{{ tag.url }}" class="tag is-link">{{ tag }}</a>{% endfor %}</p>{% endif %}
-</div>
+<span class="is-size-7">
+ <time datetime="{{ article.date.isoformat() }}" pubdate>{{ article.locale_date }}</time>,
+ {% if article and article.modified %}<em>(modified <time datetime="{{ article.modified.isoformat() }}">{{ article.locale_modified }}</time>)</em>, {% endif %}
+ category <a href="{{ SITEURL }}/{{ article.category.url }}">{{ article.category }}</a>,
+ {% if article.tags %}tags: {% for tag in article.tags %}<a href="{{ SITEURL }}/{{ tag.url }}" class="is-link">{{ tag }}</a> {% endfor %}{% endif %}
+</span>
diff --git a/templates/page.html b/templates/page.html
index f020cf6..9a73367 100644
--- a/templates/page.html
+++ b/templates/page.html
@@ -1,8 +1,8 @@
{% extends "base.html" %}
{% block title %}{{ page.title }} - {{ SITENAME }}{% endblock %}
+{% block page_title %}{{ page.title }}{% endblock %}
{% block content %}
-<h1 class="title">{{ page.title }}</h1>
<div class="content">
{{ page.content }}
</div>
diff --git a/templates/projects.html b/templates/projects.html
index d227900..7b7074b 100644
--- a/templates/projects.html
+++ b/templates/projects.html
@@ -1,8 +1,8 @@
{% extends "base.html" %}
{% block title %}Projects - {{ SITENAME }}{% endblock %}
+{% block page_title %}Projects{% endblock %}
{% block content %}
-<h1 class="title">Projects</h1>
<ul>
{% for article in articles if article.category.name == 'project' %}
<li>