lydell / LinkHints

A browser extension that lets you click with your keyboard.
https://lydell.github.io/LinkHints
MIT License
146 stars 7 forks source link

Unable to copy content from an element with one letter hint in Selection Mode #85

Open brainwo opened 1 year ago

brainwo commented 1 year ago

Steps to reproduce

  1. Go to https://en.wikipedia.org/wiki/Style_sheet_language
  2. Press Alt+Shift+L
  3. Hold Alt
  4. Find a hint with just one letter and press it
  5. The text of the element doesn't copy

Screen shot

https://github.com/lydell/LinkHints/assets/45139213/db68315f-622a-4416-b9a0-08ffeac353ed

Description

Video above shows copying from elements with two-letter hints, one letter, then two letters. Both two letters works, one letter doesn't copy anything.

Side note: apparently the video can't be played in Firefox, not sure why. I tried it on Chrome and it works just fine. Downloading also works.

Debug info

Debug info ```json { "version": "1.3.1", "browser": "firefox", "userAgent": "Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/116.0", "browserInfo": { "name": "Firefox", "vendor": "Mozilla", "version": "116.0.3", "buildID": "20230816233310" }, "platformInfo": { "os": "linux", "arch": "x86-64" }, "storage.sync": { "css": ".root {\n font: menu;\n}\n\n.hint {\n font-size: 12px;\n padding: 2px;\n color: black;\n background-color: #ffffff;\n border: solid 1px rgba(0, 0, 0, 0.5);\n text-transform: uppercase;\n font-weight: bold;\n line-height: 1;\n white-space: nowrap;\n}\n\n.highlighted {\n background-color: #fb5d72;\ncolor: white;\n\n}\n\n.matchedChars {\n opacity: 0.3;\n}\n\n.matchedText {\n border-bottom: 2px solid #ef0fff;\n box-sizing: border-box;\n}\n\n.status {\n font-size: 14px;\n padding: 4px 6px;\n color: white;\n background-color: black;\n box-shadow: 0 0 1px 0 rgba(255, 255, 255, 0.5);\n bottom: 0;\n right: 0;\n line-height: 1;\n}\n\n.peek .hint:not(.hasMatchedChars):not(.highlighted) {\n opacity: 0.2;\n}\n\n.mixedCase {\n text-transform: none;\n}\n\n.hidden,\n.hint:not(.hidden) ~ .shruggie,\n.status:empty {\n opacity: 0 !important;\n}" }, "storage.local": { "tutorialShown": true }, "language": "en-US" } ```
lydell commented 1 month ago

Tried reproducing this today. Basically, it seems to be the same thing as https://github.com/lydell/LinkHints/issues/92#issuecomment-2295189424 – Firefox is overly twitchy with its “protection” :(