2015-12-23 16:56:27 -05:00
|
|
|
- page_title @user.name
|
|
|
|
- page_description @user.bio
|
|
|
|
- header_title @user.name, user_path(@user)
|
2016-01-13 10:26:40 -05:00
|
|
|
- @no_container = true
|
2015-05-01 05:33:54 -04:00
|
|
|
|
2015-04-21 10:31:40 -04:00
|
|
|
= content_for :meta_tags do
|
2015-04-21 11:03:23 -04:00
|
|
|
= auto_discovery_link_tag(:atom, user_url(@user, format: :atom), title: "#{@user.name} activity")
|
2015-04-21 10:31:40 -04:00
|
|
|
|
2015-04-26 18:43:02 -04:00
|
|
|
= render 'shared/show_aside'
|
|
|
|
|
2015-10-16 07:24:28 -04:00
|
|
|
.cover-block
|
2016-01-13 10:26:40 -05:00
|
|
|
.cover-controls
|
|
|
|
- if @user == current_user
|
|
|
|
= link_to profile_path, class: 'btn btn-gray' do
|
|
|
|
= icon('pencil')
|
|
|
|
- elsif current_user
|
|
|
|
%span.report-abuse
|
|
|
|
- if @user.abuse_report
|
|
|
|
%button.btn.btn-danger{ title: 'Already reported for abuse',
|
|
|
|
data: { toggle: 'tooltip', placement: 'left', container: 'body' }}
|
|
|
|
= icon('exclamation-circle')
|
|
|
|
- else
|
2016-01-12 14:15:59 -05:00
|
|
|
= link_to new_abuse_report_path(user_id: @user.id, ref_url: request.referrer), class: 'btn btn-gray',
|
2016-01-13 10:26:40 -05:00
|
|
|
title: 'Report abuse', data: {toggle: 'tooltip', placement: 'left', container: 'body'} do
|
|
|
|
= icon('exclamation-circle')
|
|
|
|
- if current_user
|
|
|
|
|
|
|
|
= link_to user_path(@user, :atom, { private_token: current_user.private_token }), class: 'btn btn-gray' do
|
|
|
|
= icon('rss')
|
|
|
|
|
2015-10-16 07:24:28 -04:00
|
|
|
.avatar-holder
|
|
|
|
= link_to avatar_icon(@user, 400), target: '_blank' do
|
|
|
|
= image_tag avatar_icon(@user, 90), class: "avatar s90", alt: ''
|
|
|
|
.cover-title
|
|
|
|
= @user.name
|
|
|
|
|
|
|
|
.cover-desc
|
2016-02-23 14:39:53 -05:00
|
|
|
%span.middle-dot-divider
|
|
|
|
@#{@user.username}
|
|
|
|
%span.middle-dot-divider
|
2016-01-06 17:27:56 -05:00
|
|
|
Member since #{@user.created_at.to_s(:medium)}
|
2016-02-23 14:39:53 -05:00
|
|
|
|
|
|
|
- if @user.bio.present?
|
|
|
|
.cover-desc
|
|
|
|
%p.profile-user-bio
|
|
|
|
= @user.bio
|
2015-10-16 07:24:28 -04:00
|
|
|
|
|
|
|
.cover-desc
|
|
|
|
- unless @user.public_email.blank?
|
2016-02-23 14:39:53 -05:00
|
|
|
.profile-link-holder.middle-dot-divider
|
2015-11-03 08:00:41 -05:00
|
|
|
= link_to @user.public_email, "mailto:#{@user.public_email}"
|
2015-10-16 07:24:28 -04:00
|
|
|
- unless @user.skype.blank?
|
2016-02-23 14:39:53 -05:00
|
|
|
.profile-link-holder.middle-dot-divider
|
2015-11-03 08:00:41 -05:00
|
|
|
= link_to "skype:#{@user.skype}", title: "Skype" do
|
|
|
|
= icon('skype')
|
2015-10-16 07:24:28 -04:00
|
|
|
- unless @user.linkedin.blank?
|
2016-02-23 14:39:53 -05:00
|
|
|
.profile-link-holder.middle-dot-divider
|
2015-11-16 05:01:26 -05:00
|
|
|
= link_to "https://www.linkedin.com/in/#{@user.linkedin}", title: "LinkedIn" do
|
2015-11-03 08:00:41 -05:00
|
|
|
= icon('linkedin-square')
|
2015-10-16 07:24:28 -04:00
|
|
|
- unless @user.twitter.blank?
|
2016-02-23 14:39:53 -05:00
|
|
|
.profile-link-holder.middle-dot-divider
|
2015-11-16 05:01:26 -05:00
|
|
|
= link_to "https://twitter.com/#{@user.twitter}", title: "Twitter" do
|
2015-11-03 08:00:41 -05:00
|
|
|
= icon('twitter-square')
|
2015-10-16 07:24:28 -04:00
|
|
|
- unless @user.website_url.blank?
|
2016-02-23 14:39:53 -05:00
|
|
|
.profile-link-holder.middle-dot-divider
|
2015-11-03 08:00:41 -05:00
|
|
|
= link_to @user.short_website_url, @user.full_website_url
|
2015-10-16 07:24:28 -04:00
|
|
|
- unless @user.location.blank?
|
2016-02-23 14:39:53 -05:00
|
|
|
.profile-link-holder.middle-dot-divider
|
2015-11-03 08:00:41 -05:00
|
|
|
= icon('map-marker')
|
|
|
|
= @user.location
|
2015-08-06 08:03:27 -04:00
|
|
|
|
2016-01-13 10:26:40 -05:00
|
|
|
%ul.nav-links.center
|
|
|
|
%li.active
|
|
|
|
= link_to "#activity", 'data-toggle' => 'tab' do
|
|
|
|
Activity
|
|
|
|
- if @groups.any?
|
|
|
|
%li
|
|
|
|
= link_to "#groups", 'data-toggle' => 'tab' do
|
|
|
|
Groups
|
|
|
|
- if @contributed_projects.present?
|
|
|
|
%li
|
|
|
|
= link_to "#contributed", 'data-toggle' => 'tab' do
|
|
|
|
Contributed projects
|
|
|
|
- if @projects.present?
|
|
|
|
%li
|
|
|
|
= link_to "#personal", 'data-toggle' => 'tab' do
|
|
|
|
Personal projects
|
2015-03-20 23:10:05 -04:00
|
|
|
|
2016-01-13 10:26:40 -05:00
|
|
|
%div{ class: container_class }
|
|
|
|
.tab-content
|
|
|
|
.tab-pane.active#activity
|
|
|
|
.gray-content-block.white.second-block
|
|
|
|
%div{ class: container_class }
|
|
|
|
.user-calendar
|
|
|
|
%h4.center.light
|
|
|
|
%i.fa.fa-spinner.fa-spin
|
|
|
|
.user-calendar-activities
|
2015-10-16 07:24:28 -04:00
|
|
|
|
2014-12-04 14:49:19 -05:00
|
|
|
|
2016-01-13 10:26:40 -05:00
|
|
|
.content_list
|
|
|
|
= spinner
|
2015-11-03 09:32:40 -05:00
|
|
|
|
2016-01-13 10:26:40 -05:00
|
|
|
- if @groups.any?
|
|
|
|
.tab-pane#groups
|
|
|
|
%ul.content-list
|
|
|
|
- @groups.each do |group|
|
|
|
|
= render 'shared/groups/group', group: group
|
2015-11-03 09:32:40 -05:00
|
|
|
|
2016-01-13 10:26:40 -05:00
|
|
|
- if @contributed_projects.present?
|
|
|
|
.tab-pane#contributed
|
|
|
|
.contributed-projects
|
|
|
|
= render 'shared/projects/list',
|
|
|
|
projects: @contributed_projects.sort_by(&:star_count).reverse,
|
|
|
|
projects_limit: 10, stars: true, avatar: true
|
2015-11-03 09:32:40 -05:00
|
|
|
|
2016-01-13 10:26:40 -05:00
|
|
|
- if @projects.present?
|
|
|
|
.tab-pane#personal
|
|
|
|
.personal-projects
|
|
|
|
= render 'shared/projects/list',
|
|
|
|
projects: @projects.sort_by(&:star_count).reverse,
|
|
|
|
projects_limit: 10, stars: true, avatar: true
|
2015-01-29 04:20:17 -05:00
|
|
|
|
2015-11-10 06:17:37 -05:00
|
|
|
:javascript
|
|
|
|
$(".user-calendar").load("#{user_calendar_path}");
|