 kd             = require 'kd'
+globals        = require 'globals'
 nick           = require 'app/util/nick'
 getReferralUrl = require 'app/util/getReferralUrl'
 CustomViews    = require 'app/commonviews/customviews'


      container = @views.container 'share-box'

      @addTo container,
        text_title    : title
        text_subtitle : subtitle

          partial     : getReferralUrl nick()
          cssClass    : "text link"
          tooltip     :
            title     : "#{firstKeyChar.toUpperCase()} + #{secondKeyChar} to copy"
            placement : "above"
          click       : ->
            referralUrl = @getElement()
            @utils.selectText referralUrl
            @tooltip.show()
            

      return container

