Support Ctrl+C/Command+C for copying the current URL to clipboard #164
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
First of all, thanks for creating this project! I use it regularly for browsing through image subreddits to find things to share with friends. That usually involves me pressing 'i' to open the image in a new tab, then copying the image URL (which now involves using the context menu for Reddit) so I can paste it into a Discord channel. I wanted something simpler so I added support for handling Ctrl+C / Command+C to copy the current URL to the clipboard.
I was not sufficiently motivated to check the browser platform so as to handle the correct keyboard shortcut per platform. That wouldn't be much additional work, though.
An alternate approach would be to handle the copy event and set the clipboard data there. I'm not sure there'd be much functional difference, except that the browser would handle the keyboard shortcuts for us.