-
-
Notifications
You must be signed in to change notification settings - Fork 274
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
feature: replicate default webui copy name / hash context menu functions #277
Comments
@WDaan, I just tested this on the new version, and it doesn't work(i.e. clicking on copy and then any of the three options didn't copy anything onto my clipboard). System: Arch Linux, |
Which browser are you using? I only tested on chrome because I thought it was standardised functionality |
|
I also tried it on |
Tested on Chrome, Safari and Firefox & didn't notice any issues. |
I also tested it on Firefox, and it doesn't work. Opening the Firefox console, I noticed this:
And then I thought of also looking at Chromium's console:
|
Thank you for this! It means for some reason the clipboard API is not supported for both your browsers 😮😮 The compatibility list is shown here, it should be globaly supported 🤔🤔 |
But I installed and tested on stock Firefox(!) |
I believe you 😅 you don't have to convince me. |
Sorry I thought by both browsers you meant the chromium-based ones I mentioned earlier. Maybe this is relevant, since I don't use https on the server and the linked issue mentions that: |
I tried the latest release and it works for me. However it only works for a single torrent selected. The qbit webui allows multiple torrents to be selected and you can still copy the name, hash, and url. Select multiple torrents and copy the name, it will put each name on a single line, so when you paste you have a list of torrent names. Please make this work with multiple torrents are selected. Right now the copy menu isn't an option when multiple torrents are selected. Thank you for the quick turn around and quick implementation! |
Just out of curiosity... When do you actually need to copy the name/hash/magnet of multiple torrents? What is the use case? |
I have a script that copies my torrents and renames them. I paste the names of the torrents (which matches the download location). The script knows where the torrents are, adds the torrent name to the path, copies the downloaded torrent files and processes them. I need the names because I need to control what torrents to process. Also the torrent client is not accessible (and I don't want it to be) to the processing server. So it's useful for me when using 2 machines to do different tasks. It's a slightly manual process but it works. I also used that in cases where I want to compare the list of torrents in my client to another list. Sure, I could find a way to automate it by working with the client API or something but the manual process of copying the names hasn't bothered me that much yet. As for magnets, I could see the use case for quickly copying torrents from one client to another. |
Thanks for the explanation! |
@WDaan unfortunately, the latest versions of Edge, it no longer copies to the clipboard. I recommend looking at the copy button that github now has. (Could be a feature preview, so check that if you don't see it below). Hover over my code block below to see it. This type of button would be very nice for the Show Info panel details as well.
You should be able to view the source and dig in to find the JS code they are using to copy to the clipboard and use that in VueTorrent. |
OK, looks like they are using this NPM package: https://www.npmjs.com/package/clipboard-copy |
This is a permissions issue. The Clipboard API is only available in secure contexts, meaning pages served over HTTPS, localhost or 127.0.0.1. If you want to bypass this for a chromium browser you can head to Better would of course be to reverse proxy your site with something like ✨ caddy ✨ or nginx. |
Thanks for the analysis! My proxy of choice is NginxManager 🙃 |
I select torrents and use the context menu to copy the torrent names with the default webui, can't do it with vuetorrent.
Also can't select to copy any text in the info panel.
The text was updated successfully, but these errors were encountered: