-
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.
- Loading branch information
1 parent
7e2ebf0
commit cd3a7ed
Showing
2 changed files
with
48 additions
and
42 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,49 +1,53 @@ | ||
<div class = "recent-card"> | ||
<% @questions.limit(3).each_with_index do |node,i| %> | ||
<div class="row"> | ||
<div class="image"> | ||
<img src="<%= node.author.profile_image %>" width="25" height="25"/> | ||
</div> | ||
<div class= "recent-questions"> | ||
<h5><a class = "questions"<% if @widget %>target="_blank"<% end %> href="<%= node.path(:question) %>"><%= node.title %></a></h5> | ||
</div> | ||
<div class="by-author"> | ||
by <a href="/profile/<%= node.author.name %>">@<%= node.author.name %></a> | ||
</div> | ||
<div class="row justify-content-center"> | ||
<div class = "card col-md-9" style="padding:1em;"> | ||
<% @questions.limit(3).each_with_index do |node,i| %> | ||
<span class="parent"> | ||
<span class="image mr-md-3 child"> | ||
<img class="img" src="<%= node.author.profile_image %>" width="25" height="25"/> | ||
</span> | ||
<span class= "recent-questions child"> | ||
<h5><a class = "questions"<% if @widget %>target="_blank"<% end %> href="<%= node.path(:question) %>"><%= node.title %></a></h5> | ||
</span> | ||
<span class="ml-md-3 by-author child"> | ||
by <a href="/profile/<%= node.author.name %>">@<%= node.author.name %></a> | ||
</span> | ||
</span> | ||
<% end %> | ||
</div> | ||
<% end %> | ||
</div> | ||
<style> | ||
.recent-card{ | ||
background-color: #fff; | ||
border: 1px solid; | ||
border-color: #D3D3D3; | ||
border-radius: 6px; | ||
width : 70%; | ||
margin-left: 10em; | ||
align-items: center; | ||
padding: 20px; | ||
} | ||
|
||
.questions{ | ||
font-size: 15px; | ||
color: black; | ||
margin-left: 6px; | ||
} | ||
.card { | ||
background-color: #fff; | ||
border: 1px solid; | ||
border-color: #D3D3D3; | ||
border-radius: 6px; | ||
} | ||
|
||
.image{ | ||
border-radius: 50%; | ||
margin-left: 10px; | ||
} | ||
.parent { | ||
overflow-x: auto; | ||
padding: 0.4em; | ||
} | ||
|
||
.by-author{ | ||
color: #A9A9A9; | ||
font-size: 13px; | ||
margin-left: 6px; | ||
margin-top: 4px; | ||
} | ||
.child { | ||
display: inline-block; | ||
} | ||
|
||
.questions{ | ||
font-size: 15px; | ||
color: black; | ||
} | ||
.img{ | ||
border-color:#555; | ||
border-radius: 50%; | ||
margin-left: 10px; | ||
} | ||
.by-author{ | ||
color: #A9A9A9; | ||
font-size: 13px; | ||
} | ||
.by-author a{ | ||
color: #A9A9A9; | ||
} | ||
|
||
.by-author a{ | ||
color: #A9A9A9; | ||
} | ||
</style> |
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