%span.label-row
  - if can?(current_user, :admin_label, @project)
    .draggable-handler
      = icon('bars')
    .js-toggle-priority.toggle-priority{ data: { url: remove_priority_project_label_path(@project, label),
      dom_id: dom_id(label), type: label.type } }
      %button.add-priority.btn.has-tooltip{ title: 'Prioritize', type: 'button', :'data-placement' => 'top' }
        = icon('star-o')
      %button.remove-priority.btn.has-tooltip{ title: 'Remove priority', type: 'button', :'data-placement' => 'top' }
        = icon('star')
  %span.label-name
    = link_to_label(label, subject: @project, tooltip: false)
  - if defined?(@project) && @project.group.present?
    %span.label-type
      = label.model_name.human.titleize
  - if label.description
    %span.label-description
      = markdown_field(label, :description)