Commit 02302c82 authored by Kushal Pandya's avatar Kushal Pandya

Use label dropdown helper for rendering contextual string

parent 55734453
- subject = @project || @group
.dropdown-page-two.dropdown-new-label .dropdown-page-two.dropdown-new-label
= dropdown_title("Create new label", options: { back: true }) = dropdown_title(create_label_title(subject), options: { back: true })
= dropdown_content do = dropdown_content do
.dropdown-labels-error.js-label-error .dropdown-labels-error.js-label-error
%input#new_label_name.default-dropdown-input{ type: "text", placeholder: _('Name new label') } %input#new_label_name.default-dropdown-input{ type: "text", placeholder: _('Name new label') }
......
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
- show_footer = local_assigns.fetch(:show_footer, true) - show_footer = local_assigns.fetch(:show_footer, true)
- filter_placeholder = local_assigns.fetch(:filter_placeholder, 'Search') - filter_placeholder = local_assigns.fetch(:filter_placeholder, 'Search')
- show_boards_content = local_assigns.fetch(:show_boards_content, false) - show_boards_content = local_assigns.fetch(:show_boards_content, false)
- subject = @project || @group
.dropdown-page-one .dropdown-page-one
= dropdown_title(title) = dropdown_title(title)
- if show_boards_content - if show_boards_content
...@@ -17,11 +18,11 @@ ...@@ -17,11 +18,11 @@
- if can?(current_user, :admin_label, current_board_parent) - if can?(current_user, :admin_label, current_board_parent)
%li %li
%a.dropdown-toggle-page{ href: "#" } %a.dropdown-toggle-page{ href: "#" }
= _('Create new label') = create_label_title(subject)
%li %li
= link_to labels_path, :"data-is-link" => true do = link_to labels_path, :"data-is-link" => true do
- if show_create && can?(current_user, :admin_label, current_board_parent) - if show_create && can?(current_user, :admin_label, current_board_parent)
= _('Manage labels') = manage_labels_title(subject)
- else - else
= _('View labels') = view_labels_title(subject)
= dropdown_loading = dropdown_loading
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment