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

Filterable inside custom select: data-filtertext is ignored #7677

Closed
slavap opened this Issue Sep 17, 2014 · 6 comments

Comments

Projects
None yet
4 participants
@slavap

slavap commented Sep 17, 2014

Listview li items must be created with data-filtertext attributes copied from options.
Test: http://jsbin.com/huvoraba/130/edit

@gabrielschulhof

This comment has been minimized.

Show comment
Hide comment
@gabrielschulhof

gabrielschulhof Sep 18, 2014

Contributor

@slavap I've updated the demo to take into account the filtertext. The updated demo should appear in the next version of jQuery Mobile.

Note that the updated demo also fixes another issue I accidentally introduced, whereby, once a select menu opens as a dialog, the text input doing the filtering is not returned to the popup afterwards. So, if the menu opens as a dialog even once and later opens as a popup, then the popup will not have the text input, because the text input stays with the dialog.

Contributor

gabrielschulhof commented Sep 18, 2014

@slavap I've updated the demo to take into account the filtertext. The updated demo should appear in the next version of jQuery Mobile.

Note that the updated demo also fixes another issue I accidentally introduced, whereby, once a select menu opens as a dialog, the text input doing the filtering is not returned to the popup afterwards. So, if the menu opens as a dialog even once and later opens as a popup, then the popup will not have the text input, because the text input stays with the dialog.

@slavap

This comment has been minimized.

Show comment
Hide comment
@slavap

slavap Sep 18, 2014

@gabrielschulhof
Thanks! But your fix is not completely proper. When data-filtertext is defined, original content should be ignored, but in your demo both orange and florida are working.

slavap commented Sep 18, 2014

@gabrielschulhof
Thanks! But your fix is not completely proper. When data-filtertext is defined, original content should be ignored, but in your demo both orange and florida are working.

@gabrielschulhof

This comment has been minimized.

Show comment
Hide comment
@gabrielschulhof

gabrielschulhof Sep 18, 2014

Contributor

Nono ... "Orange" doesn't work. "Or" works because of Fl​OR​ida. If you type "Ora", you get no hits.

Contributor

gabrielschulhof commented Sep 18, 2014

Nono ... "Orange" doesn't work. "Or" works because of Fl​OR​ida. If you type "Ora", you get no hits.

@slavap

This comment has been minimized.

Show comment
Hide comment
@slavap

slavap Sep 18, 2014

Sorry, my mistake, thanks again!

slavap commented Sep 18, 2014

Sorry, my mistake, thanks again!

@Sanafan

This comment has been minimized.

Show comment
Hide comment
@Sanafan

Sanafan Sep 18, 2014

Hey Guys,
what about this?

flori gives me the result orange
flora gives me no result

why?

Sanafan commented Sep 18, 2014

Hey Guys,
what about this?

flori gives me the result orange
flora gives me no result

why?

@jaspermdegroot jaspermdegroot modified the milestones: 1.4.5, 1.5.0 Sep 18, 2014

@slavap

This comment has been minimized.

Show comment
Hide comment
@slavap

slavap Sep 18, 2014

@Sanafan
Orange is just display value, but search value for it is Florida. That's why flori gives you orange, and flora gives you nothing.

slavap commented Sep 18, 2014

@Sanafan
Orange is just display value, but search value for it is Florida. That's why flori gives you orange, and flora gives you nothing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment