aboutsummaryrefslogtreecommitdiffstats
path: root/app/views/shared/_sidebar_users.html.haml
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/shared/_sidebar_users.html.haml')
-rw-r--r--app/views/shared/_sidebar_users.html.haml38
1 files changed, 38 insertions, 0 deletions
diff --git a/app/views/shared/_sidebar_users.html.haml b/app/views/shared/_sidebar_users.html.haml
new file mode 100644
index 0000000..bfd4b4d
--- /dev/null
+++ b/app/views/shared/_sidebar_users.html.haml
@@ -0,0 +1,38 @@
+.sidebar
+ .avatar= link_to (image_tag @user.profile_image_url_original, :alt => @user.screen_name, :width => 64, :height => 64, :class => "icon img-rounded"), :controller => "users", :action => "best", :screen_name => @user.screen_name
+ .screen_name= link_to "@#{@user.screen_name}", :controller => "users", :action => "best", :screen_name => @user.screen_name
+ - if @user.registered?
+ %table.table.table-condensed.records
+ %tr
+ %td favorited
+ %td.data= @user.stats[:favorited_count]
+ %tr
+ %td retweeted
+ %td.data= @user.stats[:retweeted_count]
+ %tr
+ %td avg. fav
+ %td.data= ((@user.stats[:favorited_count] + 0.0) / @user.stats[:tweets_count]).round(2)
+ - else
+ .alert.alert-info
+ = "@#{@user.screen_name} has never signed in to aclog"
+ .user_nav
+ %ul.nav.nav-tabs.nav-stacked
+ - if @user.registered?
+ %li
+ = link_to "info", :controller => "users", :action => "info", :screen_name => @user.screen_name
+ %li
+ = link_to "best", :controller => "users", :action => "best", :screen_name => @user.screen_name
+ %li
+ = link_to "recent", :controller => "users", :action => "recent", :screen_name => @user.screen_name
+ %li
+ = link_to "timeline", :controller => "users", :action => "timeline", :screen_name => @user.screen_name
+ %li
+ = link_to "discovered", :controller => "users", :action => "discovered", :screen_name => @user.screen_name
+ %li
+ = link_to "favorited by", :controller => "users", :action => "favorited_by", :screen_name => @user.screen_name
+ %li
+ = link_to "retweted by", :controller => "users", :action => "retweeted_by", :screen_name => @user.screen_name
+ %li
+ = link_to "given favorites", :controller => "users", :action => "given_favorites_to", :screen_name => @user.screen_name
+ %li
+ = link_to "given retweets", :controller => "users", :action => "given_retweets_to", :screen_name => @user.screen_name