potentiele oplossing grouped events
This commit is contained in:
parent
7d74313176
commit
5fb12c99fc
4 changed files with 41 additions and 12 deletions
|
@ -33,6 +33,7 @@
|
||||||
.info {
|
.info {
|
||||||
margin: 1.5em;
|
margin: 1.5em;
|
||||||
box-shadow : none;
|
box-shadow : none;
|
||||||
|
width: 60%;
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
font-size: 1.7em;
|
font-size: 1.7em;
|
||||||
|
@ -64,9 +65,22 @@
|
||||||
font-size: 1.6em;
|
font-size: 1.6em;
|
||||||
font-weight: 400;
|
font-weight: 400;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.subevent {
|
.main-event {
|
||||||
margin-left: 20px;
|
border-left: 1px solid gray;
|
||||||
|
border-radius: 0px;
|
||||||
|
box-shadow: none;
|
||||||
|
height: 8em;
|
||||||
|
// display: flex;
|
||||||
|
// align-items: center;
|
||||||
|
|
||||||
|
ul {
|
||||||
|
padding-left: .7em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.active {
|
||||||
|
color: #FF7F00;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,7 @@ title: Events
|
||||||
<%= render '/partials/_event_preview.*', event: event %>
|
<%= render '/partials/_event_preview.*', event: event %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<% sub_events(event).each do |sub_event| %>
|
<% sub_events(event).each do |sub_event| %>
|
||||||
<%= render '/partials/_event_preview.*', event: sub_event %>
|
<%= render '/partials/_event_preview.*', event: sub_event, main_event: event %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
6
content/events/15-16/bottlebats/test.md
Normal file
6
content/events/15-16/bottlebats/test.md
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
title: test
|
||||||
|
time: 12-3-16
|
||||||
|
location: Grace Hopper
|
||||||
|
description: Dit is een description!
|
||||||
|
---
|
|
@ -5,8 +5,8 @@
|
||||||
|
|
||||||
<div class="box info">
|
<div class="box info">
|
||||||
<div class="title">
|
<div class="title">
|
||||||
<a href="<%= relative_path_to(@event) %>">
|
<a href="<%= relative_path_to(event) %>">
|
||||||
<%= @event[:title] %>
|
<%= event[:title] %>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="location">
|
<div class="location">
|
||||||
|
@ -23,12 +23,21 @@
|
||||||
<%= event[:time] %>
|
<%= event[:time] %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<% sub_events(event).each do |sub_event| %>
|
</div>
|
||||||
<div class="subevent">
|
|
||||||
<a href="<%= relative_path_to(sub_event) %>">
|
<% if @main_event %>
|
||||||
|
<div class="box main-event">
|
||||||
|
<p>
|
||||||
|
<%= main_event[:title] %>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<ul>
|
||||||
|
<% sub_events(main_event).each do |sub_event| %>
|
||||||
|
<li class="<%= "active" if sub_event[:title] == (event[:title])%>" >
|
||||||
<%= sub_event[:title] %>
|
<%= sub_event[:title] %>
|
||||||
</a>
|
</li>
|
||||||
|
<% end %>
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
Loading…
Reference in a new issue