2016-05-11 16:43:58 -04:00
|
|
|
- grouped_emojis = awardable.grouped_awards(with_thumbs: inline)
|
2016-09-04 04:51:12 -04:00
|
|
|
.awards.js-awards-block{ class: ("hidden" if !inline && grouped_emojis.empty?), data: { award_url: toggle_award_url(awardable) } }
|
2016-04-25 04:09:39 -04:00
|
|
|
- awards_sort(grouped_emojis).each do |emoji, awards|
|
2016-11-22 05:25:09 -05:00
|
|
|
%button.btn.award-control.js-emoji-btn.has-tooltip{ type: "button",
|
|
|
|
disabled: !current_user,
|
|
|
|
class: (award_active_class(awards, current_user)),
|
|
|
|
data: { placement: "bottom", title: award_user_list(awards, current_user) } }
|
2016-06-03 14:32:42 -04:00
|
|
|
= emoji_icon(emoji, sprite: false)
|
2016-04-16 15:09:08 -04:00
|
|
|
%span.award-control-text.js-counter
|
|
|
|
= awards.count
|
|
|
|
|
|
|
|
- if current_user
|
|
|
|
.award-menu-holder.js-award-holder
|
2016-05-27 11:29:27 -04:00
|
|
|
%button.btn.award-control.js-add-award{ type: "button" }
|
2016-06-01 05:23:09 -04:00
|
|
|
= icon('smile-o', class: "award-control-icon award-control-icon-normal")
|
|
|
|
= icon('spinner spin', class: "award-control-icon award-control-icon-loading")
|
2016-04-16 15:09:08 -04:00
|
|
|
%span.award-control-text
|
|
|
|
Add
|