deathau / markdownload

A Firefox and Google Chrome extension to clip websites and download them into a readable markdown file.
Apache License 2.0
2.91k stars 226 forks source link

Better Android support: add "copy selected text to clipboard" option #300

Open rubcap opened 8 months ago

rubcap commented 8 months ago

Hi there!

I love your extension and would like to use it more in Firefox for Android (Fenix).

In Firefox on desktop, you can set a keyboard shortcut to copy selected text, as Markdown, to the clipboard. I would like to do the same thing on Android: copying text, as Markdown, to the clipboard, without integrating the extension with the Obsidian app or the need to download and import a Markdown file (to keep things as simple as possible). I tried to copy the text in the browserAction panel on Android, but that turned out to be nearly impossible.

The best option would be to be able to add an item to the Android browser's context menu. But seeing that extensions aren't able to add items there yet (https://bugzilla.mozilla.org/show_bug.cgi?id=1595822), I think a convenient and quick temporary solution would be to add a big "Copy to clipboard" button above the current "Download" button.

This would also benefit desktop users that pressed the toolbar button in order to download a Markdown file, but make a split-second decision not to download, but to copy the Markdown. For Android users, copying selected text would be greatly simplified.

I made a simple mock-up to visualize how the browserAction interface could be changed.

Thanks for considering this change!

MarkDownload_browserAction_interface_mockup

rubcap commented 8 months ago

See also https://github.com/deathau/markdownload/issues/301 to scale the interface on Android.