Open external links with appropriate plugins
Describe your suggested feature
When browsing a source online or previously keeping track with bookmarks, the unique URL is already present, but there's no way to import it into LNReader (as far as I can tell). This means having to manually search for the novel/chapter, which is an annoying medium break, and unacceptable/impossible for sources with bad/broken search functions.
It would be useful if, given an arbitrary link presumed to lead to a novel source site (e.g. using the link share feature on iOS and Android), LNReader could automatically open the appropriate item.
Other details
On a technical level, this would mean exposing a new hook in the plugin interface, which takes a link and returns a NovelItem or a ChapterItem (or something similar) or null if the link is unrelated to the plugin. By iterating through all installed plugins, the experience is seamless. A default no-op implementation would prevent this from being a breaking change.
However, it's likely that the correct plugin isn't yet installed, or the user is even unaware that one exists. For discovery in cases like this, the site field of the plugins.json entries could be used to suggest the installation of the relevant plugin for a given link's domain, if any. It would also be useful to extend this by additional domains that may also be detected (e.g. language-specific subdomains?)
Acknowledgements
- [x] I have searched the existing issues and this is a new ticket, NOT a duplicate or related to another open or closed issue.
- [x] I have written a short but informative title.
- [x] If this is an issue with a source, I should be opening an issue in the sources repository.
- [x] I have updated the app to version 2.0.0.
- [x] I will fill out all of the requested information in this form.