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

autocomplete text appearing in the top-left #174

Open
SylvainMartel opened this issue Oct 16, 2016 · 3 comments
Open

autocomplete text appearing in the top-left #174

SylvainMartel opened this issue Oct 16, 2016 · 3 comments

Comments

@SylvainMartel
Copy link

I'm updating an app from django 1.9 to django 1.10 and I got a weird behavior with django-selectable and django 1.10.1. In django 9, on the html page, when you type the autocomplete box with the result will correctly appear under the stringfield, but in django 10 it will appear in the top left corner of the browser. Bug?

@SylvainMartel SylvainMartel changed the title Text appearing in the top-left autocomplete text appearing in the top-left Oct 16, 2016
@mlavin
Copy link
Owner

mlavin commented Oct 17, 2016

Is this behavior in your own form/front-end or in the admin (or both)?

@SylvainMartel
Copy link
Author

SylvainMartel commented Oct 17, 2016

Good point as this reminded me that I also started using django-crispy-forms in the updated version. The problem happens in the front-end form, and that form is built using the crispy tag{% crispy form form.helper %}. The form.helper is there to give custom <div> tags to the different form fields. I was doing the same thing in the previous version, but I was using django-boostrap3 tags instead.

I'm not using django-selectable in the admin section.

@SylvainMartel
Copy link
Author

SylvainMartel commented Oct 22, 2016

Ok, found the problem. Jquery 3.1.1 and JQuery UI 1.11.4 have problems together. I was getting a "f.getClientRects is not a function". Supposedly that this is fixed with jquery UI 1.12.x but dj-selectable doesn't seem to play nice with that one(give a zIndex error) So I had to add jquery-migrate 3.0 to the template fir jquery ui 1.11.4 to work correctly and it's working ok once more now, the autocomplete text appear correctly under the field.

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