diff options
author | Luke Bennett <lukeeeebennettplus@gmail.com> | 2018-06-05 10:47:43 +0100 |
---|---|---|
committer | Luke Bennett <lukeeeebennettplus@gmail.com> | 2018-06-05 10:47:43 +0100 |
commit | 7e36fa398b6f2e0304d852b7c77ef30d83e62ed4 (patch) | |
tree | db6326dc53cbf5e5be5350dcf0389f43eed9b8a1 /app/views/shared/_label.html.haml | |
parent | 9b9cdc984cb785ceee4ed1902625c65492640621 (diff) | |
download | gitlab-ce-7e36fa398b6f2e0304d852b7c77ef30d83e62ed4.tar.gz |
FE review changes
Diffstat (limited to 'app/views/shared/_label.html.haml')
-rw-r--r-- | app/views/shared/_label.html.haml | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/app/views/shared/_label.html.haml b/app/views/shared/_label.html.haml index 391021a7665..658d546a4a4 100644 --- a/app/views/shared/_label.html.haml +++ b/app/views/shared/_label.html.haml @@ -11,22 +11,22 @@ %li.label-list-item{ id: label_css_id, data: { id: label.id } } = render "shared/label_row", label: label, subject: subject, force_priority: force_priority %ul.label-actions-list - - if controller.is_a?(Projects::LabelsController) + - if @project %li.inline .label-badge.label-badge-gray= label.model_name.human.capitalize - if can?(current_user, :admin_label, @project) %li.inline.js-toggle-priority{ data: { url: remove_priority_project_label_path(@project, label), dom_id: dom_id(label), type: label.type } } - %button.label-action.add-priority.btn.btn-transparent.has-tooltip{ title: _('Prioritize'), type: 'button', :'data-placement' => 'top' } + %button.label-action.add-priority.btn.btn-transparent.has-tooltip{ title: _('Prioritize'), type: 'button', data: { placement: 'top' }, aria_label: _('Prioritize label') } = sprite_icon('star-o') - %button.label-action.remove-priority.btn.btn-transparent.has-tooltip{ title: _('Remove priority'), type: 'button', :'data-placement' => 'top' } + %button.label-action.remove-priority.btn.btn-transparent.has-tooltip{ title: _('Remove priority'), type: 'button', data: { placement: 'top' }, aria_label: _('Deprioritize label') } = sprite_icon('star') %li.inline - = link_to edit_label_path(label), class: 'btn btn-transparent label-action' do + = link_to edit_label_path(label), class: 'btn btn-transparent label-action', aria_label: 'Edit label' do = sprite_icon('pencil') %li.inline .dropdown - %button{ type: 'button', class: 'btn btn-transparent js-label-options-dropdown label-action', data: { toggle: 'dropdown' } } + %button{ type: 'button', class: 'btn btn-transparent js-label-options-dropdown label-action', data: { toggle: 'dropdown' }, aria_label: _('Label actions dropdown') } = sprite_icon('ellipsis_v') .dropdown-menu.dropdown-open-left %ul @@ -44,7 +44,7 @@ = _('Promote to group label') %li %span{ data: { toggle: 'modal', target: "#modal-delete-label-#{label.id}" } } - = button_tag 'Delete', type: 'button', class: 'text-danger remove-row' + %button.text-danger.remove-row{ type: 'button' }= _('Delete') - if current_user %li.inline.label-subscription - if can_subscribe_to_label_in_different_levels?(label) |