Add widget feeds to homepage
Note there is some funkiness going on with class loadings
Had to create a `feed` and `widget_feed` table even though in this
first version the Widget::Feed includes only uses ActiveModel instead
of ActiveRecord, otherwise some specs failed
We’ll figure it out and clean up 😌
This commit is contained in:
16
app/views/welcome/_feeds.html.erb
Normal file
16
app/views/welcome/_feeds.html.erb
Normal file
@@ -0,0 +1,16 @@
|
||||
<h1>Feeds</h1>
|
||||
|
||||
<% @feeds.each do |feed| %>
|
||||
|
||||
<div>
|
||||
<strong>Most active <%= feed.kind %></strong>
|
||||
</div>
|
||||
|
||||
<% feed.items.each do |item| %>
|
||||
<div class="<%= item.class.to_s.parameterize('_') %>">
|
||||
<%= item.title %>
|
||||
</div>
|
||||
<br/>
|
||||
<% end %>
|
||||
|
||||
<% end %>
|
||||
@@ -24,6 +24,7 @@
|
||||
</div>
|
||||
|
||||
<%= render "header", header: @header %>
|
||||
<%= render "feeds" %>
|
||||
<%= render "cards" %>
|
||||
|
||||
<% if feature?("user.recommendations") && (@recommended_debates.present? || @recommended_proposals.present?) %>
|
||||
|
||||
Reference in New Issue
Block a user