       collection   = $parse(match[8])
       modelValue   = match[1].replace(match[5] + '.','')
       viewValue    = if match[2] then match[2].replace(match[5] + '.','') else modelValue
-      template     = angular.element("<ul> </ul>")
-      search       = angular.element "<input type='search' placeholder='Search'>"
-      tempHolder   = angular.element("<div class='filtered-select' ></div>")
       viewValueFn  = $parse(viewValue || modelValue)
       modelValueFn = $parse(modelValue || viewValue)
-      tempHolder.addClass('bottom') if element.hasClass('bottom')
-      template.bind 'mousewheel DOMMouseScroll', (event)->
-        delta = event.wheelDelta or event.originalEvent and event.originalEvent.wheelDelta or -event.detail
-        bottomOverflow = template[0].scrollTop + template.outerHeight() - template[0].scrollHeight >= 0
-        topOverflow = template[0].scrollTop <= 0
-        if delta < 0 and bottomOverflow or delta > 0 and topOverflow
-          event.preventDefault()
-      scrollStart = null
-      scrollTop   = null
-      template.bind 'touchstart', (event)->
-        event.stopPropagation()
-        scrollStart = event.originalEvent.touches[0].clientY
-      template.bind 'touchmove', (event) ->
-        event.stopPropagation()
-        scroll = event.originalEvent.touches[0].clientY
-        scrollStart = scroll unless scrollStart
-        if scroll > scrollStart
-          event.preventDefault() if template.scrollTop() == 0
-        else if scroll < scrollStart
-          newScrollTop = template.scrollTop()
-          event.preventDefault() if scrollTop == newScrollTop
-          scrollTop = newScrollTop
-        scrollStart = scroll
-        return true
-      template.bind 'touchend', ->
-        event.stopPropagation()
-        scrollStart = null
-      body = angular.element('body')
-      body.bind 'keydown', (event) ->
-        tempHolder.removeClass('active') if event.keyCode == 27
-      tempHolder.append search
-      tempHolder.append template
-      body.append tempHolder
+      template     = angular.element("<ul> </ul>")
+      if isMobile = typeof attrs.ngMobile != 'undefined'
+        search       = angular.element "<input type='search' placeholder='Search'>"
+        tempHolder   = angular.element("<div class='filtered-select' ></div>")
+        tempHolder.addClass('bottom') if element.hasClass('bottom')
+        body = angular.element(document.body)
+        body.bind 'keydown', (event) ->
+          tempHolder.removeClass('active') if event.keyCode == 27
+        tempHolder.append search
+        tempHolder.append template
+        body.append tempHolder
+      else
+        span         = angular.element "<span></span>"
+        search       = angular.element "<input class='autocomplete' type='search' placeholder='" + attrs.placeholder + "'>"
+        tempHolder   = angular.element "<div class='autocomplete menu md-whiteframe-z1'>"
+        span.append search
+        span.append tempHolder
+        element.append span
+        tempHolder.append template
+
       ulHeight = ->
         full = window.innerHeight
         full = full/3 if element.hasClass('bottom')
         full - search[0].offsetHeight + 'px'
-      template.css('height',ulHeight())
-      scope.$watch collection, (newVal,oldVal) ->
+      template.css('height',ulHeight()) if isMobile
+      scope.$watchCollection collection, (newVal,oldVal) ->
         return if newVal == oldVal
         setInitialValue()
         buildTemplate()

          [filterType,value] = filter.replace(/\s+/,'').split(':')
          filteredList = $filter(filterType)(filteredList, value)
        for item in filteredList
          li = angular.element '<li ng-model-value="' + modelValueFn(item) + '">' + viewValueFn(item) + '</li>'
          li.bind 'mousedown', ($event)->
            updateValue($event.target.attributes['ng-model-value'].value)
          list.push li
        template.empty()
        template.append(list)
      setInitialValue = ->
        unless model = ngModel.$modelValue
          view = attrs.placeholder
          element.css('color','rgba(0,0,0,0.4)')
        else
          element.css('color','')
          obj = {}
          obj[modelValue] = model
          list = $filter('filter')(collection(scope), obj)
          viewScope = list[0] if list
          view = if viewScope then viewValueFn(viewScope) else attrs.placeholder
        element.html('')
        element.html(view)
      setInitialValue()
      buildTemplate()
      updateValue = (model) ->
        ngModel.$setViewValue(model)
        tempHolder.removeClass('active')
      done = false
      fieldset = element
      until done

      search.bind 'input', ->
        buildTemplate()
      buildTemplate = ->
        template.empty()
        obj={}
        obj[viewValue] = search.val() || ''
        return unless collection(scope)
