summaryrefslogtreecommitdiff
path: root/frontend/src/components/settings/pages/developer
diff options
context:
space:
mode:
authorAAGaming <aagaming@riseup.net>2023-12-30 21:32:23 -0500
committerAAGaming <aagaming@riseup.net>2023-12-30 21:32:23 -0500
commit40c7c1b515abf4abcecd6480afb28f27fb71d0f0 (patch)
tree576399085651b6e7cb0c37876ed6c2b3d0452dd7 /frontend/src/components/settings/pages/developer
parent70104065e2145e9a04fef4ae28ec9875a6114e2d (diff)
downloaddecky-loader-40c7c1b515abf4abcecd6480afb28f27fb71d0f0.tar.gz
decky-loader-40c7c1b515abf4abcecd6480afb28f27fb71d0f0.zip
port updater to ws, also small refactoring
Diffstat (limited to 'frontend/src/components/settings/pages/developer')
-rw-r--r--frontend/src/components/settings/pages/developer/index.tsx26
1 files changed, 8 insertions, 18 deletions
diff --git a/frontend/src/components/settings/pages/developer/index.tsx b/frontend/src/components/settings/pages/developer/index.tsx
index 36d3b5c0..9c8504e7 100644
--- a/frontend/src/components/settings/pages/developer/index.tsx
+++ b/frontend/src/components/settings/pages/developer/index.tsx
@@ -28,20 +28,13 @@ const installFromZip = async () => {
logger.error('The default path has not been found!');
return;
}
- window.DeckyPluginLoader.openFilePickerV2(
- FileSelectionType.FILE,
- path,
- true,
- true,
- undefined,
- ['zip'],
- false,
- false,
- ).then((val) => {
- const url = `file://${val.path}`;
- console.log(`Installing plugin locally from ${url}`);
- installFromURL(url);
- });
+ DeckyPluginLoader.openFilePickerV2(FileSelectionType.FILE, path, true, true, undefined, ['zip'], false, false).then(
+ (val) => {
+ const url = `file://${val.path}`;
+ console.log(`Installing plugin locally from ${url}`);
+ installFromURL(url);
+ },
+ );
};
export default function DeveloperSettings() {
@@ -92,10 +85,7 @@ export default function DeveloperSettings() {
<DialogButton
onClick={async () => {
try {
- let tabId = await window.DeckyBackend.call<[name: string], string>(
- 'utilities/get_tab_id',
- 'SharedJSContext',
- );
+ let tabId = await DeckyBackend.call<[name: string], string>('utilities/get_tab_id', 'SharedJSContext');
Navigation.NavigateToExternalWeb(
'localhost:8080/devtools/inspector.html?ws=localhost:8080/devtools/page/' + tabId,
);