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

Can no longer search (AJAX generated?) forms in version 2 #207

Open
tpaine opened this issue Jul 28, 2015 · 3 comments
Open

Can no longer search (AJAX generated?) forms in version 2 #207

tpaine opened this issue Jul 28, 2015 · 3 comments

Comments

@tpaine
Copy link

tpaine commented Jul 28, 2015

Since upgrading to version 2 earlier this week I can no longer search forms properly. Findbar will highlight the text within an input or textarea field but it won't move the cursor when I hit the "next" arrow or when I hit in the search box. Instead it remains stuck on the first one it found (eg "1 of 4 matches"). This is a deal breaker for me as I'm constantly search very large forms in my work.

I would be happy to help debug the issue with you, just let me know what you need.

@Quicksaver
Copy link
Owner

It seems to search fine for me in form fields. Can you please try beta version 2.0.2b1 and see if it still has that issue? You can find it at https://github.com/Quicksaver/FindBar-Tweak/releases/tag/v2.0.2b1

@tpaine
Copy link
Author

tpaine commented Jul 28, 2015

Still seeing the same issue with the beta version. The forms I'm searching are very complex and generated with ajax. There is also a big scrolling div and some fancy scrollbar hiding stuff going on. I tried saving the html but the error went away which makes me think it's related to the ajax.

@Quicksaver
Copy link
Owner

That may be it, if all the form contents are re-generated on each AJAX call, that means the findbar loses the references to the previous text selection (while the text might be the same, the physical nodes - or references or whatever those are actually called - are not the same).

This causes the findbar to think "Hmm, something changed as I can't find the text where I was previously." So it searches again through the whole page.

In some cases the add-on already detects that the text hasn't actually changed, and tries to "continue" from where it was. But this is far from perfect as it is, and could definitely use some improvements, unfortunately this has to be done on a case-by-case basis. I don't suppose you're able to link me to a live example of this? Without actually seeing what's happening, there's not much I can do.

@Quicksaver Quicksaver changed the title Can no longer search forms in version 2 Can no longer search (AJAX generated?) forms in version 2 Jul 29, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants