Render small avatars for inline events
This commit is contained in:
parent
9174020f14
commit
25e629e460
|
@ -35,6 +35,13 @@
|
|||
padding-top: 0;
|
||||
}
|
||||
|
||||
&.event-inline {
|
||||
.avatar {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
}
|
||||
|
||||
padding: 14px 0px;
|
||||
border-bottom: 1px solid #eee;
|
||||
.event-title {
|
||||
|
|
|
@ -291,4 +291,14 @@ class Event < ActiveRecord::Base
|
|||
"Wall"
|
||||
end.downcase
|
||||
end
|
||||
|
||||
def body?
|
||||
if push?
|
||||
push_with_commits?
|
||||
elsif note?
|
||||
true
|
||||
else
|
||||
target.respond_to? :title
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
- if event.proper?
|
||||
%div.event-item
|
||||
.event-item{class: "#{event.body? ? "event-block" : "event-inline" }"}
|
||||
%span.cgray.pull-right
|
||||
#{time_ago_in_words(event.created_at)} ago.
|
||||
|
||||
|
|
Loading…
Reference in New Issue