Skip to content
Snippets Groups Projects
Commit 3fac0ac4 authored by Lukas Ruge's avatar Lukas Ruge
Browse files

preview nicer

parent 3e9ffca3
No related branches found
No related tags found
No related merge requests found
Pipeline #8955 passed
......@@ -72,12 +72,14 @@ function spaceopen() {
function nextevent() {
if($("#nextevent").text().trim().length) {
$("#event_soon").css( "border", "3px solid orange");
$("#event_soon").css( "border", "3px solid #E94E1B");
$("#event_soon").append("<div style='text-align: right;'><a href='https://chaotikum.org/events/' target='_blank' style='color: #EAEAEA;'>Kalender</a></div>");
} else {
$("event_soon").hide();
}
if($("#nextevent_mobile").text().trim().length) {
$("#event_soon_mobile").css( "border", "3px solid orange");
$("#event_soon_mobile").css( "border", "3px solid #E94E1B");
$("#event_soon_mobile").append("<div style='text-align: right;'><a href='https://chaotikum.org/events/' target='_blank' style='color: #EAEAEA;'>Kalender</a></div>");
} else {
$("event_soon_mobile").hide();
}
......
......@@ -5,7 +5,7 @@
{% capture nowunix %}{{'now' | date: '%s'}}{% endcapture -%}
<b>Demnächst:</b>
{% for e in site.events -%}
{% capture event_start_plus %}{{e.eventdate | date: '%s' | minus: 86400 }}{% endcapture -%}
{% capture event_start_plus %}{{e.eventdate | date: '%s' | minus: 259200 }}{% endcapture -%}
{% capture event_start %}{{e.eventdate | date: '%s' }}{% endcapture -%}
{% if event_start_plus < nowunix and event_start > nowunix -%}
<p id="nextevent_mobile"> {{ e.eventdate | date: "%d.%m.%Y %H:%M" }}: {{e.title}}</p>
......
<div id="event_soon" style="margin-top: 5px;">
{% capture nowunix %}{{'now' | date: '%s'}}{% endcapture -%}
<b>Demnächst:</b>
{% for e in site.events -%}
{% capture event_start_plus %}{{e.eventdate | date: '%s' | minus: 86400 }}{% endcapture -%}
{% capture event_start %}{{e.eventdate | date: '%s' }}{% endcapture -%}
{% if event_start_plus < nowunix and event_start > nowunix -%}
<p id="nextevent"> {{ e.eventdate | date: "%d.%m.%Y %H:%M" }}: {{e.title}}</p>
{% endif -%}
{% endfor -%}
{%- capture nowunix %}{{'now' | date: '%s'}}{% endcapture -%}
{%- assign show_event = 2 -%}
{%- for e in site.events -%}
{%- capture event_start_plus %}{{e.eventdate | date: '%s' | minus: 259200 }}{% endcapture -%}
{%- capture event_start %}{{e.eventdate | date: '%s' }}{% endcapture -%}
{%- if event_start_plus < nowunix and event_start > nowunix and show_event > 1 -%}
<b>Demnächst:</b>
{%- assign show_event = 0 - %}<p id="nextevent"> {{ e.eventdate | date: "%d.%m.%Y %H:%M" }}: {{e.title}}</p>{% endif -%}
{%- endfor -%}
</div>
<div id="spaceopen" class="chaotikum-about">
Ob der Nobreakspace offen ist siehst du <a href='https://status.nobreakspace.org' target='_blank'>hier</a><p>Oder aktiviere Javascript</p>
......
......@@ -192,6 +192,20 @@ figcaption {
text-align: center;
}
#event_soon_mobile {
background-color: #fafafa;
padding: 2%;
text-align: center;
margin-top: 2px;
}
#event_soon {
background-color: #fafafa;
padding: 2%;
text-align: center;
margin-top: 2px;
}
#spaceopen:a {
background-color: #ff0000;
text-align: left;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment