Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Long press on menu item cause detach and the item is not selected #16

Open
hakib opened this issue Dec 13, 2014 · 1 comment
Open

Long press on menu item cause detach and the item is not selected #16

hakib opened this issue Dec 13, 2014 · 1 comment

Comments

@hakib
Copy link
Owner

hakib commented Dec 13, 2014

This is happening when the press is longer the debounce_blur.

The input losses focus which triggers detach. Since the item is pressed the click event does not invoke apply_selection. The apply selection does not regain focus back to the input field so detach considers it as if the input just lost focus and clears everything. When the click is finally invoking apply_selection the item is already detached and the selection is ignored.

This can be possibly be solved by using on-mousedown instead of ng-click but it needs to be tested on touch devices and there might be a usability issue as well.

Haki.

@robert-king
Copy link

My quick fix is to increase the debounce_blur.. fingers crossed:

<span mass-autocomplete="{debounce_blur:700}">
            <input ng-model="dirty.value"
                   mass-autocomplete-item="autocomplete_options"
                    placeholder="University or Domain">
          </span>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants