2015-09-11 14:41:01 +05:30
|
|
|
- if current_user
|
2016-06-16 23:09:34 +05:30
|
|
|
= link_to toggle_star_namespace_project_path(@project.namespace, @project), { class: 'btn star-btn toggle-star has-tooltip', method: :post, remote: true, title: current_user.starred?(@project) ? 'Unstar project' : 'Star project' } do
|
2016-01-14 18:37:52 +05:30
|
|
|
- if current_user.starred?(@project)
|
|
|
|
= icon('star fw')
|
|
|
|
%span.starred Unstar
|
|
|
|
- else
|
|
|
|
= icon('star-o fw')
|
|
|
|
%span Star
|
|
|
|
%div.count-with-arrow
|
|
|
|
%span.arrow
|
|
|
|
%span.count.star-count
|
2015-09-11 14:41:01 +05:30
|
|
|
= @project.star_count
|
|
|
|
|
|
|
|
- else
|
2016-06-02 11:05:42 +05:30
|
|
|
= link_to new_user_session_path, class: 'btn has-tooltip star-btn', title: 'You must sign in to star a project' do
|
2015-09-11 14:41:01 +05:30
|
|
|
= icon('star fw')
|
2016-01-14 18:37:52 +05:30
|
|
|
Star
|
|
|
|
%div.count-with-arrow
|
|
|
|
%span.arrow
|
2015-09-11 14:41:01 +05:30
|
|
|
%span.count
|
|
|
|
= @project.star_count
|