mirror of
https://github.com/SteamDeckHomebrew/decky-loader.git
synced 2026-06-13 04:05:04 +03:00
Simplify the typing of the plugin URL for users (#769)
Builder Win / Build PluginLoader for Win (push) Has been cancelled
Builder / Build PluginLoader (push) Has been cancelled
Push Updated Plugin Stub to Template / copy-stub (push) Has been cancelled
Lint / Run linters (push) Has been cancelled
Type Check / Run type checkers (push) Has been cancelled
Builder Win / Build PluginLoader for Win (push) Has been cancelled
Builder / Build PluginLoader (push) Has been cancelled
Push Updated Plugin Stub to Template / copy-stub (push) Has been cancelled
Lint / Run linters (push) Has been cancelled
Type Check / Run type checkers (push) Has been cancelled
* Simplify the typing of the plugin URL for the user. Make the http/https prefix optional. * Fixed the formatting using prettier --write
This commit is contained in:
@@ -72,7 +72,16 @@ export default function DeveloperSettings() {
|
|||||||
}
|
}
|
||||||
icon={<FaLink style={{ display: 'block' }} />}
|
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')}
|
{t('SettingsDeveloperIndex.third_party_plugins.button_install')}
|
||||||
</DialogButton>
|
</DialogButton>
|
||||||
</Field>
|
</Field>
|
||||||
|
|||||||
Reference in New Issue
Block a user