60 lines
2.2 KiB
Text
60 lines
2.2 KiB
Text
- empty_repo = @project.empty_repo?
|
|
.project-home-panel.cover-block.clearfix{:class => ("empty-project" if empty_repo)}
|
|
.project-identicon-holder
|
|
= project_icon(@project, alt: '', class: 'project-avatar avatar s90')
|
|
.cover-title.project-home-desc
|
|
%h1
|
|
= @project.name
|
|
%span.visibility-icon.has-tooltip{data: { container: 'body' }, title: visibility_icon_description(@project)}
|
|
= visibility_level_icon(@project.visibility_level, fw: false)
|
|
|
|
- if @project.description.present?
|
|
.cover-desc.project-home-desc
|
|
= markdown(@project.description, pipeline: :description)
|
|
|
|
- if forked_from_project = @project.forked_from_project
|
|
.cover-desc
|
|
Forked from
|
|
= link_to project_path(forked_from_project) do
|
|
= forked_from_project.namespace.try(:name)
|
|
|
|
.cover-controls
|
|
- if current_user
|
|
= link_to namespace_project_path(@project.namespace, @project, format: :atom, private_token: current_user.private_token), class: 'btn btn-gray' do
|
|
= icon('rss')
|
|
- access = user_max_access_in_project(current_user.id, @project)
|
|
- can_edit = can?(current_user, :admin_project, @project)
|
|
- if access || can_edit
|
|
%span.dropdown.project-settings-dropdown
|
|
%a.dropdown-new.btn.btn-gray#project-settings-button{href: '#', 'data-toggle' => 'dropdown'}
|
|
= icon('cog')
|
|
= icon('angle-down')
|
|
%ul.dropdown-menu.dropdown-menu-right
|
|
- if can_edit
|
|
%li
|
|
= link_to edit_project_path(@project) do
|
|
Edit Project
|
|
- if access
|
|
%li
|
|
= link_to leave_namespace_project_project_members_path(@project.namespace, @project),
|
|
data: { confirm: leave_project_message(@project) }, method: :delete, title: 'Leave project' do
|
|
Leave Project
|
|
|
|
.project-repo-buttons
|
|
.split-one.count-buttons
|
|
= render 'projects/buttons/star'
|
|
= render 'projects/buttons/fork'
|
|
|
|
.clone-row
|
|
.project-clone-holder
|
|
= render "shared/clone_panel"
|
|
|
|
.split-repo-buttons
|
|
.btn-group.pull-left
|
|
= render "projects/buttons/download"
|
|
= render 'projects/buttons/dropdown'
|
|
|
|
= render 'projects/buttons/notifications'
|
|
|
|
:javascript
|
|
new Star();
|