diff options
| author | Alexander Maslov <30986874+steam3d@users.noreply.github.com> | 2025-04-23 17:21:49 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-23 10:21:49 -0400 |
| commit | 0b738820122ad859182e4403af29ae4dacb06084 (patch) | |
| tree | 77ee8c434caef1fdec20d4d0743d6d1bdf2bc60e /frontend/src | |
| parent | b15392b5f260123e75cf5606b7d507838f1fb77d (diff) | |
| download | decky-loader-0b738820122ad859182e4403af29ae4dacb06084.tar.gz decky-loader-0b738820122ad859182e4403af29ae4dacb06084.zip | |
Simplify the typing of the plugin URL for users (#769)
* Simplify the typing of the plugin URL for the user. Make the http/https prefix optional.
* Fixed the formatting using prettier --write
Diffstat (limited to 'frontend/src')
| -rw-r--r-- | frontend/src/components/settings/pages/developer/index.tsx | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/frontend/src/components/settings/pages/developer/index.tsx b/frontend/src/components/settings/pages/developer/index.tsx index 099f2610..05989806 100644 --- a/frontend/src/components/settings/pages/developer/index.tsx +++ b/frontend/src/components/settings/pages/developer/index.tsx @@ -72,7 +72,16 @@ export default function DeveloperSettings() { } icon={<FaLink style={{ display: 'block' }} />} > - <DialogButton disabled={pluginURL.length == 0} onClick={() => installFromURL(pluginURL)}> + <DialogButton + disabled={pluginURL.length == 0} + onClick={() => { + if (/^https?:\/\//.test(pluginURL)) { + installFromURL(pluginURL); + } else { + installFromURL('https://' + pluginURL); + } + }} + > {t('SettingsDeveloperIndex.third_party_plugins.button_install')} </DialogButton> </Field> |
