Settings search input loses focus while I type


(Anton) #1

I cannot reproduce this constantly, but it happens especially when I type fast, here is the recording:

I thought it might happen if there is only one result if my search, but then I tried “mode”, which gives 4 results, and if I type it fast, the search input loses the focus, so I cannot continue typing to refine my search.


(cpradio) #2

Are you on a laptop?


(Anton) #3

Yes. Windows 8.1 x64


(cpradio) #4

Are you accidentally tapping the touchpad and thus placing the cursor elsewhere? I know I have that problem all of the time with a laptop as I can’t repro this at all here on Meta.


(Anton) #5

Just tested with the touchpad turned off - the problem persists.


(Sam Saffron) #6

Can you make this happen on meta? Can you make it happen with any other browser?


(Anton) #7

Hm, I have no access to “Meta” admin panel settings.
Do I have such an access to “Try” instance?


(cpradio) #8

Okay, I’m confused, where exactly is this happening? What page, which search field?


(Anton) #9

URL:

/admin/site_settings/category/required

The input is the one that filters site settings while you type.


(cpradio) #10

Hmm… I still can’t reproduce this (on my dev machine). I wonder if there is a focus event that fires on load, and the page isn’t fully loaded yet for you when you start your search.


(Anton) #11

Unfortunately, this is not the case.
I did many tests, including when I waited 10 seconds and more to ensure the page is fully loaded.

Btw, I can now reproduce it constantly by typing “mode” into the search box quickly.


(Jeff Atwood) #12

I can easily confirm this, site settings search loses focus after you type. Can we prevent this from happening @neil?


(Sam Saffron) #13

While there, I really hate being trapped there with no back button after searching


(Anton) #14

Also, after clicking the Reset button to remove the search term, the focus is not returned back to the input.


(Neil Lalonde) #15

This is definitely new behaviour. Don’t know what changed… I’ll have a look.


(Neil Lalonde) #16

@eviltrout figured this out and fixed it!

https://github.com/discourse/discourse/commit/8366fcd78fd4427b6c0ee9019c9499b9d7a24616


(Jeff Atwood) #17