debian-mirror-gitlab/app/views/shared/_issuable_meta_data.html.haml

26 lines
1.2 KiB
Text
Raw Normal View History

2019-07-07 11:18:12 +05:30
- note_count = @issuable_meta_data[issuable.id].user_notes_count
2017-08-17 22:00:37 +05:30
- issue_votes = @issuable_meta_data[issuable.id]
- upvotes, downvotes = issue_votes.upvotes, issue_votes.downvotes
2019-10-12 21:52:04 +05:30
- issuable_path = issuable_path(issuable, anchor: 'notes')
2020-07-28 23:09:34 +05:30
- issuable_mr = @issuable_meta_data[issuable.id].merge_requests_count
2017-08-17 22:00:37 +05:30
- if issuable_mr > 0
2018-11-08 19:23:39 +05:30
%li.issuable-mr.d-none.d-sm-block.has-tooltip{ title: _('Related merge requests') }
2017-08-17 22:00:37 +05:30
= image_tag('icon-merge-request-unmerged.svg', class: 'icon-merge-request-unmerged')
= issuable_mr
- if upvotes > 0
2018-11-08 19:23:39 +05:30
%li.issuable-upvotes.d-none.d-sm-block.has-tooltip{ title: _('Upvotes') }
2020-07-28 23:09:34 +05:30
= sprite_icon('thumb-up', size: 16, css_class: "vertical-align-middle")
2017-08-17 22:00:37 +05:30
= upvotes
- if downvotes > 0
2018-11-08 19:23:39 +05:30
%li.issuable-downvotes.d-none.d-sm-block.has-tooltip{ title: _('Downvotes') }
2020-07-28 23:09:34 +05:30
= sprite_icon('thumb-down', size: 16, css_class: "vertical-align-middle")
2017-08-17 22:00:37 +05:30
= downvotes
2018-11-08 19:23:39 +05:30
%li.issuable-comments.d-none.d-sm-block
2019-10-12 21:52:04 +05:30
= link_to issuable_path, class: ['has-tooltip', ('no-comments' if note_count.zero?)], title: _('Comments') do
2020-07-28 23:09:34 +05:30
= sprite_icon('comments', size: 16, css_class: 'gl-vertical-align-text-bottom')
2017-08-17 22:00:37 +05:30
= note_count