Added logo, reduced event width, moved month detection to backend
This commit is contained in:
parent
3cf532072d
commit
d94d060ca4
4 changed files with 10 additions and 2 deletions
|
@ -60,3 +60,6 @@ class Event:
|
|||
return (self._dtend.time() == datetime.time.min \
|
||||
and self._dtend - self._dtstart <= datetime.timedelta(days=1)) \
|
||||
or self._dtend.date() == self._dtstart.date()
|
||||
|
||||
def is_one_month(self):
|
||||
return self._dtend.month == self._dtstart.month
|
||||
|
|
|
@ -15,6 +15,7 @@ body > h1 {
|
|||
|
||||
body > #events {
|
||||
margin: 2rem;
|
||||
max-width: 30rem;
|
||||
}
|
||||
|
||||
@media (max-width: 672px) {
|
||||
|
|
|
@ -36,6 +36,10 @@ h1 {
|
|||
line-height: 4rem;
|
||||
font-feature-settings: 'ss01', 'ss02', 'ss03', 'cv11';
|
||||
}
|
||||
h1 > img {
|
||||
height: 4rem;
|
||||
vertical-align: bottom;
|
||||
}
|
||||
|
||||
a {
|
||||
color: var(--link-01);
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
<h1>Saturn</h1>
|
||||
<h1><img src="/static/svg/logo.svg" /> Saturn</h1>
|
||||
|
||||
<div id="events">
|
||||
{% for event in events %}
|
||||
|
@ -38,7 +38,7 @@
|
|||
<span class="day">
|
||||
{{ event.dtend.strftime('%d') }}
|
||||
</span>
|
||||
{% if event.dtend.month != event.dtstart.month %}
|
||||
{% if event.is_one_month() %}
|
||||
<span class="month">
|
||||
{{ event.dtend.strftime('%B').capitalize() }}
|
||||
</span>
|
||||
|
|
Reference in a new issue