Start theme

master
Marko Semet 2019-05-11 13:50:39 +02:00
parent df8c30f5b4
commit 76fcfbd447
5 changed files with 139 additions and 0 deletions

View File

@ -0,0 +1,17 @@
/* Main colors */
body {
color: #110;
}
body > * {
background: #110;
color: #EEF;
}
.main1 {
background: #DDE;
color: #110;
}
.main2 {
background: #FFF;
}

View File

@ -0,0 +1,23 @@
/* Main structure */
html, body {
margin: 0;
padding: 0;
border: 0;
height: 100%;
}
body {
display: grid;
grid-template-rows: auto 1fr auto;
}
body > * {
padding: 0 10%;
}
.main2 {
height: 100%;
}
.main3 {
display: inline-block;
}

View File

@ -0,0 +1,69 @@
<!DOCTYPE html>
<html lang="{% block html_lang %}{{ DEFAULT_LANG }}{% endblock html_lang %}">
<head>
{% block head %}
<title>{% block title %}{{ SITENAME }}{% endblock title %}</title>
<meta charset="utf-8" />
{% if FEED_ALL_ATOM %}
<link href="{{ FEED_DOMAIN }}/{% if FEED_ALL_ATOM_URL %}{{ FEED_ALL_ATOM_URL }}{% else %}{{ FEED_ALL_ATOM }}{% endif %}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Full Atom Feed" />
{% endif %}
{% if FEED_ALL_RSS %}
<link href="{{ FEED_DOMAIN }}/{% if FEED_ALL_RSS_URL %}{{ FEED_ALL_RSS_URL }}{% else %}{{ FEED_ALL_RSS }}{% endif %}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} Full RSS Feed" />
{% endif %}
{% if FEED_ATOM %}
<link href="{{ FEED_DOMAIN }}/{%if FEED_ATOM_URL %}{{ FEED_ATOM_URL }}{% else %}{{ FEED_ATOM }}{% endif %}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Atom Feed" />
{% endif %}
{% if FEED_RSS %}
<link href="{{ FEED_DOMAIN }}/{% if FEED_RSS_URL %}{{ FEED_RSS_URL }}{% else %}{{ FEED_RSS }}{% endif %}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} RSS Feed" />
{% endif %}
{% if CATEGORY_FEED_ATOM and category %}
<link href="{{ FEED_DOMAIN }}/{% if CATEGORY_FEED_ATOM_URL %}{{ CATEGORY_FEED_ATOM_URL.format(slug=category.slug) }}{% else %}{{ CATEGORY_FEED_ATOM.format(slug=category.slug) }}{% endif %}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Categories Atom Feed" />
{% endif %}
{% if CATEGORY_FEED_RSS and category %}
<link href="{{ FEED_DOMAIN }}/{% if CATEGORY_FEED_RSS_URL %}{{ CATEGORY_FEED_RSS_URL.format(slug=category.slug) }}{% else %}{{ CATEGORY_FEED_RSS.format(slug=category.slug) }}{% endif %}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} Categories RSS Feed" />
{% endif %}
{% if TAG_FEED_ATOM and tag %}
<link href="{{ FEED_DOMAIN }}/{% if TAG_FEED_ATOM_URL %}{{ TAG_FEED_ATOM_URL.format(slug=tag.slug) }}{% else %}{{ TAG_FEED_ATOM.format(slug=tag.slug) }}{% endif %}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Tags Atom Feed" />
{% endif %}
{% if TAG_FEED_RSS and tag %}
<link href="{{ FEED_DOMAIN }}/{% if TAG_FEED_RSS_URL %}{{ TAG_FEED_RSS_URL.format(slug=tag.slug) }}{% else %}{{ TAG_FEED_RSS.format(slug=tag.slug) }}{% endif %}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} Tags RSS Feed" />
{% endif %}
{% endblock head %}
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/theme/css/main.css" />
<link rel="stylesheet" type="text/css" href="{{ SITEURL }}/theme/css/light.css" />
</head>
<body>
<header>
<h1><a href="{{ SITEURL }}/">{{ SITENAME }} <strong>{{ SITESUBTITLE }}</strong></a></h1>
<nav>
<ul>
{% for title, link in MENUITEMS %}
<li>
<a href="{{ link }}">{{ title }}</a>
</li>
{% endfor %}
{% if DISPLAY_PAGES_ON_MENU %}
{% for p in pages %}
<li{% if p == page %} class="active"{% endif %}>
<a href="{{ SITEURL }}/{{ p.url }}">{{ p.title }}</a>
</li>{% endfor %}{% endif %}{% if DISPLAY_CATEGORIES_ON_MENU %}{% for cat, null in categories %}
<li{% if cat == category %} class="active"{% endif %}>
<a href="{{ SITEURL }}/{{ cat.url }}">{{ cat }}</a>
</li>
{% endfor %}
{% endif %}
</ul>
</nav>
</header>
<div class="main1">
<div class="main2">
<div class="main3">{% block content %}{% endblock %}</div>
</div>
</div>
<footer>
<div class="note">
Generated by <a href="http://getpelican.com/">Pelican</a>
</div>
</footer>
</body>
</html>

View File

@ -0,0 +1,23 @@
{% extends "base.html" %}
{% block content %}
<section id="content_index">
{% block content_title %}<div>Alle Artikel</div>{% endblock content_title %}
<ul id="post_list">
{% for article in articles_page.object_list %}
<li>
<article class="article_index">
<div class="title"><a href="{{ SITEURL }}/{{ article.url }}" rel="bookmark" title="{{ article.title|striptags }}">{{ article.title }}</a></div>
<div class="post-info">
<span class="published" datetime="{{ article.date.isoformat() }}">{{ article.locale_date }}</span>
<span class="authors">By{% for author in article.authors %} <a class="url fn" href="{{ SITEURL }}/{{ author.url }}">{{ author }}</a>{% endfor %}</span>
</div>
<div class="summary">{{ article.summary }}</div>
</article>
</li>
{% endfor %}
</ul>
{% if articles_page.has_other_pages() %}
{% include 'pagination.html' %}
{% endif %}
</section>
{% endblock content %}

View File

@ -0,0 +1,7 @@
{% if DEFAULT_PAGINATION %}
<p class="paginator">{% if articles_page.has_previous() %}
<a href="{{ SITEURL }}/{{ articles_previous_page.url }}">&laquo;</a>{% endif %}
Page {{ articles_page.number }} / {{ articles_paginator.num_pages }}{% if articles_page.has_next() %}
<a href="{{ SITEURL }}/{{ articles_next_page.url }}">&raquo;</a>{% endif %}
</p>
{% endif %}