Verified Commit a161dc2f authored by Roberto Bochet's avatar Roberto Bochet
Browse files

JS removed from coding gym page

parent 26ebbae8
......@@ -27,6 +27,7 @@ $black: #111;
// Custom colors
$poul_yellow: #ffc500;
$coding_gym_blue: #47c1c7;
// Background colors
$bg_black: black;
......
......@@ -45,8 +45,8 @@
height: 2px;
border: 0;
margin: 0;
color: #fff;
background-color: #fff;
color: $white;
background-color: $white;
}
a {
......@@ -65,7 +65,7 @@
}
&.new {
background: #47c1c7;
background: $coding_gym_blue;
}
.time, .room, .registration_url {
......
......@@ -2,18 +2,6 @@
layout: default
title: Coding Gym
---
<script>
(() => {
"use strict";
document.addEventListener("DOMContentLoaded", () => {
document.querySelectorAll('.session').forEach(x => {
if (Date.now() < new Date(x.getAttribute("data-date")))
x.classList.add("new");
});
});
})();
</script>
<div class="codinggym-info">
<div class="container">
<img src="{{ '/assets/img/coding_gym_logo.svg' | relative_url }}" alt="Coding Gym logo"/>
......@@ -33,10 +21,16 @@ title: Coding Gym
</div>
</div>
{% capture now_date %}{{'now' | date: '%s'}}{% endcapture %}
{% assign sessions = site.data.coding_gym | values | sort: "date" | reverse %}
<div class="codinggym-sessions bg-blueish-gray">
{% assign sessions = site.data.coding_gym | values | sort: "date" | reverse %}
{% for session in sessions %}
<div class="session bg-darker" data-date="{{ session.date }}">
{% capture session_date %}{{session.date | date: '%s'}}{% endcapture %}
{% if now_date < session_date %}
<div class="session new">
{% else %}
<div class="session bg-darker">
{% endif %}
<div class="date">
<div>{{ session.date | date: "%b %d" | upcase }}</div>
<div class="year">{{ session.date | date: "%Y" }}</div>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment