-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* start to new front page * node.authors with test * home tweaks * added fixtures, padding, sizing * Update node.rb * Add files via upload * Delete IMG_20191021_100218_039.jpg * Add files via upload * move missing.png * authors length fix * alternating color rows * hiding people until that features is completed * Update home.html.erb * Update home_controller.rb * Update style.css * Update home.html.erb * Update home_controller.rb
- Loading branch information
Showing
8 changed files
with
147 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,119 @@ | ||
<div class="container"> | ||
|
||
<% cache('feature_home-intro', skip_digest: true) do %> | ||
<%= feature("home-intro") %> | ||
<% end %> | ||
|
||
<div class="dashboard"> | ||
<% cache('home-blog', expires_in: 60.minutes, skip_digest: true) do %> | ||
<div class="tab-pane active" id="notes"> | ||
<% unless @notes.nil? || @notes.length == 0 %> | ||
<%= render partial: "notes/notes", locals: { paginated: false } %> | ||
<p><center><a class="btn btn-outline-secondary" href="/blog">Read more</a></center></p> | ||
<div class="container"> | ||
|
||
<div class="projects"> | ||
<% #cache('home-blog', expires_in: 60.minutes, skip_digest: true) do %> | ||
<% unless @projects.nil? || @projects.length == 0 %> | ||
<% @projects.each_with_index do |project, index| %> | ||
<div class="row px-lg-5<%= " odd" if index.odd? %>"> | ||
<div class="col-6 col-xs-12 project-image <%= index.odd? ? " odd pr-lg-5 order-2" : " pl-lg-5" %>"> | ||
<a href="<%= project.path %>"><img src="<%= project.main_image %>" /</a> | ||
</div> | ||
<div class="col-6 col-xs-12<%= index.odd? ? " pl-lg-5" : " pr-lg-5" %>"> | ||
<h3><a href="<%= project.path %>"><%= project.title %></a></h3> | ||
<p><%= project.summary %></p> | ||
<p><a href="<%= project.path %>">Read more »</a></p> | ||
<div class="people"> | ||
<!-- people most associated with it? editors? pinnable? --> | ||
<!-- replace authors with 'featured people' or something? --> | ||
<!-- | ||
<% project.authors[0..2].each do |author| %> | ||
<% if author.photo %> | ||
<a class="person" href="/profile/<%= author.username %>"> | ||
<img class="person-image" src="<%= author.photo %>" /> | ||
</a> | ||
<% end %> | ||
<% end %> | ||
<% if project.authors.length > 2 %> | ||
<span class="person person-text"> | ||
<span class="text"><%= [project.authors.length - 2, 1].max %> more</span> | ||
</span> | ||
<% end %> | ||
--> | ||
</div> | ||
</div> | ||
</div> | ||
<% end %> | ||
</div> | ||
<% end %> | ||
<p><center><a class="btn btn-outline-secondary" href="/projects">More projects</a></center></p> | ||
<% end %> | ||
<% # end %> | ||
</div> | ||
</div> | ||
<style> | ||
.projects { | ||
width: 100%; | ||
position: absolute; | ||
left: 0; | ||
padding: 40px 20px; | ||
} | ||
.projects .row { | ||
padding: 50px 20px; | ||
color: #222; | ||
background: #ffe8c8; | ||
} | ||
.projects .row.odd { | ||
background: white; | ||
} | ||
.projects .row .project-image img { | ||
background: #ccc; | ||
} | ||
.projects .row h3 { | ||
color: #333; | ||
padding-bottom: 10px; | ||
} | ||
.projects .row h3 a { | ||
color: #333; | ||
text-decoration: none; | ||
} | ||
.projects .row a { | ||
color: #333; | ||
text-decoration: underline; | ||
} | ||
.projects .person { | ||
background: #efc997; | ||
float: left; | ||
display: inline-block; | ||
border-radius: 20px; | ||
min-width: 40px; | ||
height: 40px; | ||
margin-right: 5px; | ||
} | ||
.projects .person-image { | ||
border-radius: 20px; | ||
height: 40px; | ||
width: 40px; | ||
} | ||
.projects .person-text { | ||
padding: 5px; | ||
} | ||
.projects .person .text { | ||
color: #884d05; | ||
padding: 3px 8px; | ||
display: inline-block; | ||
} | ||
</style> | ||
<% cache('feature_home-footer', skip_digest: true) do %> | ||
<%= feature("home-footer") %> | ||
<% end %> | ||
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -107,3 +107,7 @@ balloon: | |
place: | ||
tid: 27 | ||
name: place | ||
|
||
project: | ||
tid: 28 | ||
name: project |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters