stremio-web
stremio-web copied to clipboard
Addon Settings
We've been discussing addon settings and how they should be implemented.
There are 2 cases:
- an addon can have settings, yet also be installed without any settings
- an addon requires settings, and cannot be installed without configuring it
For these purpose, we will have 2 behaviorHints in the addon manifest:
manifest {
behaviorHints: {
configurable: true,
configurationRequired: true
}
}
When both behaviorHints.configurable and behaviorHints.configurationRequired are true, then the "Install" button of the addon should read "Configure" and serve as an external URL to the /configure path of the addon's URL. (presuming the addon manifest URL is https://this.addon.url/manifest.json, then this external URL should point to https://this.addon.url/configure)
When behaviorHints.configurable is true and behaviorHints.configurationRequired is falsey, then the "Install" button of the addon should stay the same, and a configure button (small, with a gear icon) that serves as an external URL to the /configure path should be visible on the left side of the "Install" button.
Visual goal of this task in the Desktop app:

This has now been implemented in the Desktop version of Stremio: https://github.com/Stremio/stremio/pull/899
A decision has been made to add the settings button to the addon install pop-up too. (in the case of loading an addon from URL directly)
Example addons for this feature are now available at: https://jaruba.github.io/addon-settings-test/
More images for this feature (as an example) are now available from the Desktop app implementation:




I think it would also be good to have the configuration button in the installed addons page, so you could reconfigure the addon. It could take to https://addon.com/:configuration/configure instead of .../manifest.json
@TheBeastLT I believe it will do so, as it is the responsibility of the addon developer to continue setting manifest.behaviorHints.configurable: true or not to the manifest of the already installed addon also.
But if the addon is reconfigured, it will result in installing yet another addon with the new configuration, and we can't really do anything about this behaviour.
Newest desktop stremio version has the configure button for community addons, but it seems for installed addons there's no configure button, only an uninstall button.
@TheBeastLT Although I did notice this myself and consider it bad UX, I still think we shouldn't add the configuration button for installed addons. Because after configuring, it will result in a whole new addon installed, as installed addons are not really configurable by design, so adding such a button there might confuse users more then help them.
@jaruba On the contrary, I think that it would improve the experience. It would allow users to reconfigure addons using previous configuration values, as filling some of them each time could get tedious (like API keys) when you want to change some single value. Also it would allow users to see their current configuration and maybe spot some mistakes, as putting every configured value in description is overkill (also as descriptions are not updated).
Because after configuring, it will result in a whole new addon installed
In a sense I agree, but in my view it's a new variation/version, but not a new addon in itself. Also In this case the addon ids would match and when installing there would be the Upgrade option, which replaces the old entry, which I would see as a perfect use case for.
@TheBeastLT you win, we will add a settings button for the already installed addons too