 
     @setOptions(opts)
 
+    @on 'pick', (event)->
+      @input.value(event.link.text())
+      @emit 'complete', text: event.link.text()
+
     return @
 
   #

        @ajax = new Ajax(@options.src.replace('{search}', search), method: @options.method)
        @ajax.on 'complete', =>
          if @ajax.responseJSON
            @update(@ajax.responseJSON, search).show()
          else
            @hide()


      @update core.L(@options.src).filter (item)->
        item.toLowerCase().substr(0, search.length) is search.toLowerCase()
      , search

      @showAt(@input)

    return @

