diff options
author | Rydkin Maxim <maks.rydkin@gmail.com> | 2017-03-19 21:04:45 +0300 |
---|---|---|
committer | Rydkin Maxim <maks.rydkin@gmail.com> | 2017-04-04 21:11:24 +0300 |
commit | 2d7bc6959606bc9af5144463433507685f81a9a0 (patch) | |
tree | 67226d852da376ed2d8c6ad7c1f37179c153a890 /app/views/ci | |
parent | aa4a9b9b1a28d487f231d438c9410529eb69ce4f (diff) |
adds tooltips into several places
Diffstat (limited to 'app/views/ci')
-rw-r--r-- | app/views/ci/status/_badge.html.haml | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/app/views/ci/status/_badge.html.haml b/app/views/ci/status/_badge.html.haml index c00c7f7407e..c4ff1b5bdc9 100644 --- a/app/views/ci/status/_badge.html.haml +++ b/app/views/ci/status/_badge.html.haml @@ -1,12 +1,13 @@ - status = local_assigns.fetch(:status) -- link = local_assigns.fetch(:link, true) -- css_classes = "ci-status ci-#{status.group}" +- link = local_assigns.fetch(:link, true) +- title = local_assigns.fetch(:title, nil) +- css_classes = "ci-status ci-#{status.group} #{'has-tooltip' if title.present? }" - if link && status.has_details? - = link_to status.details_path, class: css_classes do + = link_to status.details_path, class: css_classes, title: title do = custom_icon(status.icon) = status.text - else - %span{ class: css_classes } + %span{ class: css_classes, title: title } = custom_icon(status.icon) = status.text |