debian-mirror-gitlab/app/views/groups/projects.html.haml

51 lines
2.8 KiB
Text
Raw Normal View History

2020-07-28 23:09:34 +05:30
- breadcrumb_title _("Projects")
- page_title _("Projects")
2015-09-25 12:07:36 +05:30
2022-11-25 23:54:43 +05:30
= render Pajamas::CardComponent.new(card_options: { class: 'gl-mt-3 js-search-settings-section' }, header_options: { class: 'gl-display-flex' }, body_options: { class: 'gl-py-0' }) do |c|
- c.header do
.gl-flex-grow-1
= html_escape(_("%{strong_open}%{group_name}%{strong_close} projects:")) % { strong_open: '<strong>'.html_safe, group_name: @group.name, strong_close: '</strong>'.html_safe }
2015-04-26 12:48:37 +05:30
- if can? current_user, :admin_group, @group
2016-04-02 18:10:28 +05:30
.controls
2022-11-25 23:54:43 +05:30
= render Pajamas::ButtonComponent.new(href: new_project_path(namespace_id: @group.id), size: :small, variant: :confirm) do
= _("New project")
- c.body do
%ul.content-list
2023-03-04 22:38:38 +05:30
- @projects.each_with_index do |project, idx|
%li.project-row.gl-align-items-center{ class: 'gl-display-flex!', data: { qa_selector: 'project_row_container', qa_index: idx } }
2022-11-25 23:54:43 +05:30
.avatar-container.rect-avatar.s40.gl-flex-shrink-0
= project_icon(project, alt: '', class: 'avatar project-avatar s40', width: 40, height: 40)
.gl-min-w-0.gl-flex-grow-1
.title
= link_to project_path(project), class: 'js-prefetch-document' do
2023-03-04 22:38:38 +05:30
%span.project-full-name{ data: { qa_selector: 'project_fullname_content' } }
%span.namespace-name{ data: { qa_selector: 'project_namespace_content' } }
2022-11-25 23:54:43 +05:30
- if project.namespace
= project.namespace.human_name
\/
2023-03-04 22:38:38 +05:30
%span.project-name{ data: { qa_selector: 'project_name_content', qa_project_name: project.name } }
2022-11-25 23:54:43 +05:30
= project.name
%span{ class: visibility_level_color(project.visibility_level) }
= visibility_level_icon(project.visibility_level)
2019-12-21 20:55:43 +05:30
2022-11-25 23:54:43 +05:30
- if project.description.present?
.description
= markdown_field(project, :description)
2019-12-21 20:55:43 +05:30
2022-11-25 23:54:43 +05:30
.stats.gl-text-gray-500.gl-flex-shrink-0.gl-display-none.gl-sm-display-flex
= gl_badge_tag storage_counter(project.statistics&.storage_size)
= render 'project_badges', project: project
2019-12-21 20:55:43 +05:30
2022-11-25 23:54:43 +05:30
.controls.gl-flex-shrink-0.gl-ml-5
2023-04-23 21:23:45 +05:30
= render Pajamas::ButtonComponent.new(href: project_project_members_path(project),
button_options: { data: { qa_selector: 'project_members_button' } }) do
= _('Members')
= render Pajamas::ButtonComponent.new(href: edit_project_path(project),
button_options: { data: { qa_selector: 'project_edit_button' } }) do
= _('Edit')
2023-03-04 22:38:38 +05:30
= render 'delete_project_button', project: project, data: { qa_selector: 'project_delete_button' }
2022-11-25 23:54:43 +05:30
- if @projects.blank?
.nothing-here-block= _("This group has no projects yet")
2014-09-02 18:07:02 +05:30
2015-04-26 12:48:37 +05:30
= paginate @projects, theme: "gitlab"