dlowe-net / linksnip

A browser extension for copying a shortened URL for the address of the current page.
Other
0 stars 3 forks source link

Add shortened link copy to right-click popup #3

Open dlowe-net opened 3 years ago

dlowe-net commented 3 years ago

Right now, Linksnip can only copy the address in the current tab. It'd be nice if it could copy shortened links without having to navigate to them beforehand.

dlowe-net commented 3 years ago

I have a branch that does this, but it requires the "Can modify all web pages" permission, because you have to handle a context menu in a service worker, but the clipboard (pointlessly imho) can't be modified from a service worker. Instead a content script is injected into the website (hence the permission), and then they asynchronously communicate.

This will change when I can find a better way or I decide that requesting the scary looking permission is worth it.