more ruby-esque stuff
This commit is contained in:
parent
907874f4d3
commit
15ab0113c9
2 changed files with 8 additions and 8 deletions
|
@ -122,5 +122,5 @@ a.box {
|
||||||
}
|
}
|
||||||
|
|
||||||
.backgroundimg{
|
.backgroundimg{
|
||||||
Background-position: center;
|
background-position: center;
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,20 +36,20 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="tile">
|
<div class="tile">
|
||||||
<div class="tile is-vertical">
|
<div class="tile is-vertical">
|
||||||
<% for i in [0,1,2] do event = upcoming_events[1+i] || all_events[-2-i] %>
|
<% all_events.reverse[1..3].each do |event| %>
|
||||||
<div class="tile is-parent ">
|
<div class="tile is-parent ">
|
||||||
<%= render '/partials/_tile.*',
|
<%= render '/partials/_tile.*',
|
||||||
article: event,
|
article: event,
|
||||||
small_text: if upcoming_events[1] then "Upcoming event" else "Past event" end,
|
small_text: upcoming_events.include?(event) ? "Upcoming event" : "Past event",
|
||||||
htmlclass:"highlighted"%>
|
htmlclass:"highlighted" %>
|
||||||
</div>
|
</div>
|
||||||
<%end%>
|
<%end%>
|
||||||
</div>
|
</div>
|
||||||
<div class="tile is-vertical">
|
<div class="tile is-vertical">
|
||||||
<% for i in [1,2,3] do post = sorted_articles[i] %>
|
<% sorted_articles[1..3].each do |post| %>
|
||||||
<div class="tile is-parent ">
|
<div class="tile is-parent ">
|
||||||
<%= render '/partials/_tile.*',
|
<%= render '/partials/_tile.*',
|
||||||
article: post,
|
article: post,
|
||||||
small_text: "blogpost"%>
|
small_text: "blogpost"%>
|
||||||
</div>
|
</div>
|
||||||
<%end%>
|
<%end%>
|
||||||
|
@ -60,7 +60,7 @@
|
||||||
</div>
|
</div>
|
||||||
<%= asset :js, :gamification %>
|
<%= asset :js, :gamification %>
|
||||||
<%= asset :js, :quote %>
|
<%= asset :js, :quote %>
|
||||||
<!--
|
<!--
|
||||||
|
|
||||||
<div class="tile is-parent is-2">
|
<div class="tile is-parent is-2">
|
||||||
<a class="tile box is-child imgcenter project-tile" href="/projects/#12urenloop">
|
<a class="tile box is-child imgcenter project-tile" href="/projects/#12urenloop">
|
||||||
|
|
Loading…
Reference in a new issue