From 7cce0052f852129a722a2e16d5054d6c64f22da0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gr=C3=A9goire=20Delattre?= Date: Thu, 9 Apr 2020 11:01:59 +0200 Subject: [PATCH] Add the torrent URL in the torrent button This allows us to copy the link without clicking on the button. --- frontend/js/components/buttons/torrents.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/frontend/js/components/buttons/torrents.js b/frontend/js/components/buttons/torrents.js index 97af697..08c09de 100644 --- a/frontend/js/components/buttons/torrents.js +++ b/frontend/js/components/buttons/torrents.js @@ -109,7 +109,11 @@ export const TorrentsButton = ({ torrents, search, searching, url }) => { return ( dispatch(addTorrent(e.torrent))} + href={e.torrent.url} + onClick={(event) => { + event.preventDefault(); + dispatch(addTorrent(e.torrent)); + }} > {e.quality} {e.size !== 0 && (