I’m trying to customize my instance (or maybe publish a plugin)
about support of magnet:? uri scheme and webtorrent p2p sharing.
For example, if anyone want to try, in my instance this test-toots:
Open Inspector -> JS Console -> paste
document.body.innerHTML = document.body.innerHTML.replace(/magnet:\?([^<\s\b]+)/g, "<iframe allowfullscreen allowtransparency='true' style='width:100%;height:20em;' src='https://search-id.org/?magnet:?$1'></iframe>");
It match magnet:? urls and replace with an iframe.
How i can automate this JS injection in my instance? It’s even possible to write a plugin?
Thx for any feedback.