Skip to content

Commit 98c6fb5

Browse files
committed
Use space's theme colour in index
1 parent 2d59650 commit 98c6fb5

1 file changed

Lines changed: 5 additions & 4 deletions

File tree

app/views/spaces/_space.html.erb

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1+
<% theme_colour = TeSS::Config.themes[space.theme]&.dig('primary') %>
12
<% cache(space, expires_in: 6.hours) do %>
2-
<li class="masonry-brick media-item block-item">
3-
<%= link_to space, class: 'link-overlay' do %>
4-
<%# image_tag get_image_url_for(space), class: "media-image listing_image pull-right" %>
5-
<h4 class="mb-2 mt-3">
3+
<li class="masonry-brick media-item long">
4+
<%= link_to space, class: 'link-overlay', style: (theme_colour ? "border-color: #{theme_colour}" : nil) do %>
5+
<%= image_tag get_image_url_for(space), class: "media-image listing_image pull-right" %>
6+
<h4 class="mb-2 mt-3" style="<%= theme_colour ? "color: #{theme_colour}" : ''-%>">
67
<%= space.title %>
78
</h4>
89

0 commit comments

Comments
 (0)