       img _.extend
         alt: @props.achievement.name
         className: 'badge-achievement__image'
-        'data-tooltip-target': tooltipId
         onMouseOver: @onMouseOver
         osu.src2x @iconUrl()
 

    "/images/badges/user-achievements/#{@props.achievement.slug}.png"

  render: =>
    tooltipId = "#{@props.achievement.slug}-#{Math.floor(Math.random() * 1000000)}"

    badgeClasses = 'badge-achievement'
    badgeClasses += ' badge-achievement--locked' if !@props.userAchievement?

class ProfilePage.AchievementBadge extends React.Component
  onMouseOver: (event) =>
    el = event.currentTarget

    return if el._loadedTooltipId == @tooltipId

    content = $(@refs[@tooltipId]).clone()

    if el._loadedTooltipId?
      el._loadedTooltipId = @tooltipId
      $(el).qtip 'set', 'content.text': content
      return

    el._loadedTooltipId = @tooltipId
    classes = 'qtip tooltip-achievement'
    classes += ' tooltip-achievement--locked' if !@props.userAchievement?

