Can't switch from search drop down to user menu when text selected on Chrome

AI-generated summary

Don reported an issue where selecting text in the search drop-down panel prevents switching to the user menu on Chrome. Canapin moved the issue to the bug category.

JammyDodger and Canapin exchanged steps to reproduce the issue, but JammyDodger couldn’t replicate it until Lilly clarified the steps, noting the issue occurs when the text is selected (highlighted).

The issue seems to be browser-related, specifically occurring on Windows desktop Chrome, as confirmed by Canapin and JammyDodger. Lilly further narrowed it down to Windows desktop Chrome only, with no issues on Safari, Chrome on iOS, or mobile devices. nizar9 also reported the issue on Edge and Opera, citing their Chromium-based nature.

nizar9 summarized the issue, describing it as not urgent and platform-specific to desktop Windows on Chromium-based browsers (Edge, Chrome, and Opera).

The issue is expected to be fixed via a pull request (https://github.com/discourse/discourse/pull/21202), as explained by pmusaraj.

Hello,

I noticed when the drop down search panel contains a selected text can’t switch to the drop down user menu.

It happens mostly when you previously type something in search after it when you open search the input field text will auto selected.

Repro:

Apr-17-2023 10-45-52

Thank you :slightly_smiling_face:

3 Likes

I move this to Contribute > Bug. Even if it’s a small one and kind of an edge case, it still prevents a regular action from working, even if it can easily be circumvented. :slight_smile:

Good catch :fishing_pole_and_fish:

2 Likes

I can’t replicate this. What do I have to do?

  • Open search pop-up (on topic list, or in topic)
  • Type in ‘hello’
  • Close search by clicking outside the box
  • Open search, previous ‘hello’ entry still present and autoselected
  • Click on avatar

Doing that opens the avatar menu for me?

  1. Open the search box

  2. Type something

  3. Select the text

  4. Click the avatar → It does nothing when it should be opening the user menu :slight_smile:

Hmmm :thinking: This also opens the user menu for me as well.

i’ve replicated this on desktop. the text has to be selected (highlighted).

i actually noticed this a while back on meta but didn’t think anything of it at the time. the search field retains your last search and often the text is selected by default. if you click the search icon instead of the avatar by mistake, it’s noticeable when you have previous search there that you have to close it before opening the avatar menu.

It seems to be browser-related. It doesn’t happen on Firefox but it does on Chrome.

2 Likes

Ding ding ding. :slight_smile: I’ve just tried in Chrome and I can replicate :+1:

2 Likes

heh i was just going to try safari. yes the bug seems to be windows desktop chrome only. can’t replicate in safari or chrome on iOS desktop or mobile. seems to be a strictly windows desktop chrome thing.

Hey,

It happens on Edge & Opera as well (I think that they’re both Chromium-based, so that explains the behavior).

Priority/Severity:
Not urgent

Platform:
Desktop Windows on Chromium-based browsers (Edge, Chrome and Opera so far).

Description:
The drop down user menu doesn’t show up after using the search box and highlighting a suggestion.

Reproducible steps:

  1. Type a keyword in the search box.
  2. Hover one of the suggestions.
  3. Click on the profile icon/image.
1 Like

Thanks, this should be fixed via:

There’s a long-ish explanation in the PR description, the short version is that we were previously skipping the clickOutside event for the search menu when there was text selected. But we auto-select the search menu input text, so this switches to a different technique.

4 Likes

This topic was automatically closed after 2 days. New replies are no longer allowed.