diff options
author | Simon Knox <simon@gitlab.com> | 2018-01-17 17:09:59 +0300 |
---|---|---|
committer | Douwe Maan <douwe@gitlab.com> | 2018-01-17 17:09:59 +0300 |
commit | bfdde96f4870bf0e7f1e19541ffc884a97fd29f8 (patch) | |
tree | 8957d96322200f7092615509c229158719689d14 /app/helpers/todos_helper.rb | |
parent | f2b7da8afb9f6309135738960ebf20d2afe4bec9 (diff) |
Resolve "Closed issue label in todo's styling is difficult to read"
Diffstat (limited to 'app/helpers/todos_helper.rb')
-rw-r--r-- | app/helpers/todos_helper.rb | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/app/helpers/todos_helper.rb b/app/helpers/todos_helper.rb index e7c953e749e..ddb48371c79 100644 --- a/app/helpers/todos_helper.rb +++ b/app/helpers/todos_helper.rb @@ -54,8 +54,16 @@ module TodosHelper def todo_target_state_pill(todo) return unless show_todo_state?(todo) + type = + case todo.target + when MergeRequest + 'mr' + when Issue + 'issue' + end + content_tag(:span, nil, class: 'target-status') do - content_tag(:span, nil, class: "status-box status-box-#{todo.target.state.dasherize}") do + content_tag(:span, nil, class: "status-box status-box-#{type}-#{todo.target.state.dasherize}") do todo.target.state.capitalize end end |