/ ‘pelicanconf.py’

/ ‘theme/templates/analytics.html’
/ ‘theme/templates/archives.html’
/ ‘theme/templates/base.html’
/ ‘theme/templates/category.html’
/ ‘theme/templates/index.html’
/ ‘theme/templates/page.html’
/ ‘theme/templates/pagination.html’
/ ‘theme/templates/piwik.html’
/ ‘theme/templates/tags.html’
/ ‘theme/templates/translations.html’
/ ‘theme/templates/twitter.html’
This commit is contained in:
Dooho Yi 2020-05-05 20:19:48 +09:00
parent c34a5ec7dd
commit bb108f8602
12 changed files with 76 additions and 57 deletions

View file

@ -35,7 +35,8 @@ LINKS = (('Pelican', 'http://getpelican.com/'),
SOCIAL = (('You can add links in your config file', '#'), SOCIAL = (('You can add links in your config file', '#'),
('Another social link', '#'),) ('Another social link', '#'),)
DEFAULT_PAGINATION = 5 DEFAULT_PAGINATION = 20
PAGINATED_TEMPLATES = {'index': None, 'tag': None, 'category': None, 'author': None}
# Uncomment following line if you want document-relative URLs when developing # Uncomment following line if you want document-relative URLs when developing
#RELATIVE_URLS = True #RELATIVE_URLS = True

View file

@ -7,5 +7,6 @@
try { try {
var pageTracker = _gat._getTracker("{{GOOGLE_ANALYTICS}}"); var pageTracker = _gat._getTracker("{{GOOGLE_ANALYTICS}}");
pageTracker._trackPageview(); pageTracker._trackPageview();
} catch(err) {}</script> } catch(err) {}
</script>
{% endif %} {% endif %}

View file

@ -1,13 +1,18 @@
{% extends "base.html" %} {% extends "base.html" %}
{% block content %}
<section id="content" class="body">
<h1>Archives for {{ SITENAME }}</h1>
{% block content_title %}
<div class="fl o-50" style="font-size:0.4em;">@rchives<br/> {{ SITENAME }}</div>
<a class="fr o-10 pr1" style="font-size:0.8em;" href="{{ SITEURL }}">{{ SITENAME }}</a>
{% endblock %}
{% block content %}
<dl> <dl>
{% for article in dates %} {% for article in dates %}
<dt>{{ article.locale_date }}</dt> <dt>
<dd><a href='{{ SITEURL }}/{{ article.url }}'>{{ article.title }}</a></dd> <a class="archives" href='{{ SITEURL }}/{{ article.url }}'>
{{ article.date.isoformat() }} - {{ article.title }}
</a>
</dt>
{% endfor %} {% endfor %}
</dl> </dl>
</section>
{% endblock %} {% endblock %}

View file

@ -17,6 +17,10 @@
text-decoration: none; text-decoration: none;
} }
a.archives:hover {
background-color: rgba(0, 0, 0, 0.1);
}
p { p {
margin: 0; margin: 0;
} }

View file

@ -6,7 +6,7 @@
{% endblock %} {% endblock %}
{% block content %} {% block content %}
{% for article in articles %} {% for article in articles_page.object_list %}
<article class="title"> <article class="title">
<a href="{{ SITEURL }}/{{ article.url }}" class="db b pb2 o-50"> <a href="{{ SITEURL }}/{{ article.url }}" class="db b pb2 o-50">
@ -26,4 +26,6 @@
{% endfor %} {% endfor %}
{% include 'pagination.html' %}
{% endblock %} {% endblock %}

View file

@ -5,10 +5,7 @@
{% endblock %} {% endblock %}
{% block content %} {% block content %}
{% for category, articles in categories %} {% for article in articles_page.object_list | selectattr('category', '==', 'notes') %}
{% if category.name == 'notes' %}
{% for article in articles %}
<article class="title"> <article class="title">
<a href="{{ SITEURL }}/{{ article.url }}" class="db b pb2 o-50"> <a href="{{ SITEURL }}/{{ article.url }}" class="db b pb2 o-50">
{{ article.title }} {{ article.title }}
@ -24,7 +21,6 @@
{% endif %} {% endif %}
{% endfor %} {% endfor %}
{% endif %} {% include 'pagination.html' %}
{% endfor %}
{% endblock %} {% endblock %}

View file

@ -1,10 +1,21 @@
{% extends "base.html" %} {% extends "base.html" %}
{% block title %}{{ page.title }}{% endblock %}
{% block title %}
{{ page.title }}
{% endblock %}
{% block content %} {% block content %}
<header> <header>
<h1><a href="{{ SITEURL }}" id="site-title">{# {{ SITENAME }} #} {% if SITESUBTITLE %} <strong>{{ SITESUBTITLE }}</strong>{% endif %}</a> {#:#} <h1>
<a href="{{ SITEURL }}/{{ page.url }}" id="page-title">{{ page.title }}</a></h1> <a href="{{ SITEURL }}" id="site-title">
{# {{ SITENAME }} #} {% if SITESUBTITLE %} <strong>{{ SITESUBTITLE }}</strong>{% endif %}
</a> {#:#}
<a href="{{ SITEURL }}/{{ page.url }}" id="page-title">
{{ page.title }}
</a>
</h1>
</header> </header>
<article> <article>
{{ page.content }} {{ page.content }}
</article> </article>

View file

@ -7,7 +7,7 @@
<a href="{{ SITEURL }}/{{ page_name }}{{ articles_page.previous_page_number() }}.html">&laquo;</a> <a href="{{ SITEURL }}/{{ page_name }}{{ articles_page.previous_page_number() }}.html">&laquo;</a>
{% endif %} {% endif %}
{% endif %} {% endif %}
Page {{ articles_page.number }} / {{ articles_paginator.num_pages }} {{ articles_page.number }} / {{ articles_paginator.num_pages }}
{% if articles_page.has_next() %} {% if articles_page.has_next() %}
<a href="{{ SITEURL }}/{{ page_name }}{{ articles_page.next_page_number() }}.html">&raquo;</a> <a href="{{ SITEURL }}/{{ page_name }}{{ articles_page.next_page_number() }}.html">&raquo;</a>
{% endif %} {% endif %}

View file

@ -6,4 +6,3 @@
{% endfor %} {% endfor %}
</ul> </ul>
{% endblock %} {% endblock %}