File: index.html.haml

package info (click to toggle)
gitlab 17.6.5-19
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 629,368 kB
  • sloc: ruby: 1,915,304; javascript: 557,307; sql: 60,639; xml: 6,509; sh: 4,567; makefile: 1,239; python: 406
file content (30 lines) | stat: -rw-r--r-- 1,304 bytes parent folder | download
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
- page_title _('Labels')
- can_admin_label = can?(current_user, :admin_label, @group)
- search = params[:search]
- subscribed = params[:subscribed]
- labels_or_filters = @labels.exists? || search.present? || subscribed.present?
- add_page_specific_style 'page_bundles/labels'

- if labels_or_filters
  #js-promote-label-modal
  = render 'shared/labels/nav', labels_or_filters: labels_or_filters, can_admin_label: can_admin_label

  .labels-container.gl-mt-5
    - if @labels.any?
      .gl-text-subtle.gl-mb-5
        = labels_function_introduction

      = render ::Layouts::CrudComponent.new(_('Labels'), count: number_with_delimiter(@labels.total_count), icon: 'label', options: { class: 'other-labels' }, body_options: { class: '!gl-m-0' }) do |c|
        - c.with_body do
          %ul.manage-labels-list.js-other-labels
            = render partial: 'shared/label', collection: @labels, as: :label, locals: { use_label_priority: false, subject: @group }
        - c.with_pagination do
          = paginate @labels, theme: 'gitlab'
    - elsif search.present?
      .nothing-here-block
        = _('No labels with such name or description')
    - elsif subscribed.present?
      .nothing-here-block
        = _('You do not have any subscriptions yet')
- else
  = render 'shared/empty_states/labels'