swift-selection-search icon indicating copy to clipboard operation
swift-selection-search copied to clipboard

Pop up doesn't appear if I right click them

Open crazyyzarc opened this issue 4 years ago • 1 comments
trafficstars

Describe the problem When I right click on links, such as https://google.fr , the sss context menu is not displayed. Only if I select the link (text)

How to reproduce the problem SEE 2020-12-15 09_59_59-Amazon URL isn't cleared (#720) · Issues · Kevin R  _ ClearURLs · GitLab

only if select the text: 2020-12-15 10_00_15-Amazon URL isn't cleared (#720) · Issues · Kevin R  _ ClearURLs · GitLab

Anything else you'd like to include A function that detect links and intact with them

System info:

  • Browser: Firefox
  • Browser version: 78.5.0esr
  • System: Windows 10 x64 20H1

crazyyzarc avatar Dec 15 '20 10:12 crazyyzarc

Hi, this is actually in #120 and #179, although your description is clearer due to the images.

SSS actually has code for working on links too, but there's a really dumb reason why I disabled it, which is a bit hard to explain.

By default SSS uses Search for “%s” in the context menu, where %s is the selected text (you can change this default, but 95% of users probably won't touch this setting). Firefox controls this, so it automatically fills %s with the selected text. Keyword being "selected". :)

  1. If you had a text selection somewhere in the page but right clicked a link, it would show the selected text in the context menu, not the link's text. To make sense, the search would respect that as well, searching for the selected text, not the link's. Not completely obvious to the user, but acceptable.
  2. If you had NOTHING selected it would search using the link's text, but the text displayed on the menu would be the literal Search for “%s”, with the %s, which feels really strange and looks like a bug, so I'd get reports about it without being able to fix it.

Since I haven't found a solution for this, I never ended up adding this feature. Maybe there's a way to fix this, but I don't know it right now. :(

CanisLupus avatar Dec 15 '20 22:12 CanisLupus