summaryrefslogtreecommitdiff
path: root/app/views/admin/projects/_projects.html.haml
blob: df1653cdd719acae5b36f826599239534cd19f32 (plain)
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
32
33
34
35
.js-projects-list-holder
  - if @projects.any?
    %ul.content-list
      - @projects.each do |project|
        %li.project-row.gl-align-items-center{ class: 'gl-display-flex!' }
          = render Pajamas::AvatarComponent.new(project, size: 32, alt: '')
          .gl-min-w-0.gl-flex-grow-1.gl-ml-3
            .title
              = link_to(admin_project_path(project)) do
                %span.project-full-name
                  %span.namespace-name
                    - if project.namespace
                      = project.namespace.human_name
                      \/
                  %span.project-name
                    = project.name

            - if project.description.present?
              .description
                = markdown_field(project, :description)
          .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_if_exists 'admin/projects/archived', project: project

          .controls.gl-flex-shrink-0.gl-ml-5
            = render Pajamas::ButtonComponent.new(href: edit_admin_namespace_project_path({ id: project.to_param, namespace_id: project.namespace.to_param }), button_options: { id: dom_id(project) }) do
              = _('Edit')
            = render Pajamas::ButtonComponent.new(variant: :danger, button_options: { class: 'delete-project-button', data: { delete_project_url: admin_project_path(project), project_name: project.name } }) do
              = s_('AdminProjects|Delete')

    = paginate @projects, theme: 'gitlab'
  - else
    .nothing-here-block= _('No projects found')

  #delete-project-modal