-
Notifications
You must be signed in to change notification settings - Fork 8
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
Firefox: Copying elements sometimes don’t work when holding alt (ctrl on macOS) the whole time without releasing it #92
Comments
Hi! I had difficulty following a long in the video, unfortunately. Can you describe with words what you do, what happens, and what you expected to happen? |
sure, sorry. :) in the tutorial, I hit alt-shift-l which I understand means "select link", then i hit alt-j to copy the URL of the Note that i can properly copy selected text with alt-shift-l on other places. Like if I do alt-shift-l then c, this text gets selected:
and I can hit control-c to copy it to my clipboard. But that doesn't work to copy the link. |
alt-shift-l does not mean “select link” – it means “select element”. Basically, it lets you select the text of any element. On top of that, there’s one more thing. If you hold alt while typing the last hint character of an element, that element is copied in a “do what I mean” fashion. It usually means that the text of the element is copied, but for links it means that the link URL is copied. |
On 2024-03-21 09:39:07, Simon Lydell wrote:
[...] It usually means that the text of the element is copied, but for links it means that the link URL is copied.
Right, so this is what this bug report is about: copying link URLs
doesn't work. :)
|
As in, nothing at all is copied? Also – it’s not about links, right? The same problem happens if you try to copy element text by holding alt during the last hint character? |
On 2024-03-21 11:44:10, Simon Lydell wrote:
As in, nothing at all is copied?
correct.
Also – it’s not about links, right? The same problem happens if you try to copy element text by holding alt during the last hint character?
no! i *can* copy text elements by doing that.
in fact, interestingly, it works for *some* links. for example, in:
https://lydell.github.io/LinkHints/tutorial.html#step-7
i can copy the "home" link but not the "Almost there" link - maybe it's
because it's a button?
|
Ah, then it sounds like you’re encountering this bug: #85 If you can’t copy elements with just one hint letter, then it’s that bug. |
aaaah that could explain it then, thanks! Let's close this one and i'll reopen if i can find a case where it doesn't work with two letters. :) (is there a a workaround? forcing two characters everywhere maybe? :) (one thing i was hoping this could do would be to pop open the right-click menu on a link, that way i would have access to all sorts of other things as well...) |
Unfortunately not. But luckily Link Hints is finally at the top of my todo list again, so hopefully I can fix it somewhat soon.
That would be awesome. It was possible in Firefox back in the day, but since they switched to “Web Extensions” it is sadly not possible anymore. However, you can still use alt-shift-l to focus elements and then press the right-click key on your keyboard (if it has one – if not, you can probably solve that since you’re on Linux). |
just a quick note here to mention that i thought i had reproduced this here (failure with two-letter hints) but i think what happened is i held alt while typing both letters. it works if i type alt-shift-l then the first letter of the hint, then hold alt while I type the second letter, which is a bit confusing... also, maybe that could explain why it doesn't work with a single letter? |
Sorry, I didn’t quite following along. What was confusing exactly?
That’s called solving the bug 😉 |
Maybe I misunderstand, but if I type alt-shift-l then hold alt while typing the two letters for a hint, the copying doesn't work. If I type the first letter, then hold alt then type the second letter, it works. I find that confusing because I would expect I could just hold alt the whole time and it would work, releasing alt feels counter-intuitive. |
Oh, yeah, that’s weird. Looks like you found another bug. |
Tried to debug it today. When the bug happens, this is printed in the console:
Browsers only allow certain actions to be done “during a user activation”, such as during a key press. We are doing it during a key press, so it should be fine, but Firefox seems a bit twitchy. Things I learned:
Not sure what to do about this, leaving it for another time. |
Yup, I'm encountering this same bug. Thought this was by design—works (text copied) when pressing Alt just before the last letter, but not before the entire hint. Bummer, holding Alt the whole time seems more natural to me than remembering to press it before the last letter. Didn't test much, but seems to be happening 100% of time for me. Actually, what is confusing is first saying it's the bug #85, then saying it's "another bug", then commenting in #85 that it is actually the same thing as #92. 😁 Ok, last update. To be completely clear, both statements are correct for me 100% of the time. I'm on Windows with Waterfox, which is based on ESR.
So yeah, looks like the same thing to me: |
URL
https://lydell.github.io/LinkHints/tutorial.html#step-7
Screen shot
Here's a screenshot of the tutorial before selecting the link:
Here's a video of the procedure. Note that control-shift-v in the terminal pastes from the
CLIPBOARD
selection, but thePRIMARY
selection is also not correct.recording_proxy.mp4
Description
Copying links doesn't work in Firefox 115.8.0esr on Debian 12 "bookworm", running under Sway.
Debug info
The text was updated successfully, but these errors were encountered: