1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
.gray-content-block.top-block.clearfix.white
.pull-left
- public_count = @public_forks.size
- protected_count = @protected_forks.size
- full_count_title = ["#{public_count} public", "#{protected_count} protected"].join(' and ')
== #{pluralize(@all_forks.size, 'fork')}: #{full_count_title}
.pull-right
.projects-search-form
= search_field_tag :filter_projects, nil, placeholder: 'Search forks', class: 'projects-list-filter form-control',
spellcheck: false, data: { 'filter-selector' => 'span.namespace-name' }
- if current_user.already_forked?(@project) && current_user.manageable_namespaces.size < 2
= link_to namespace_project_path(current_user, current_user.fork_of(@project)), title: 'Go to your fork', class: 'pull-right btn btn-new' do
= icon('code-fork fw')
Fork
- else
= link_to new_namespace_project_fork_path(@project.namespace, @project), title: "Fork project", class: 'pull-right btn btn-new' do
= icon('code-fork fw')
Fork
.projects-list-holder
= render 'shared/projects/list', projects: @public_forks, use_creator_avatar: true,
forks: true
- if protected_count > 0
%ul.projects-list
%li.project-row
%strong= pluralize(protected_count, 'protected fork')
%span you have no access to.
|