From 6b82e84b7b5a605b055ed282ae5f1df81623ec06 Mon Sep 17 00:00:00 2001 From: llama Date: Fri, 24 Oct 2025 19:43:56 +0800 Subject: [PATCH] implement uninstall screen --- qt/launcher-gui/src/routes/Uninstall.svelte | 118 ++++++++++++++++++-- 1 file changed, 107 insertions(+), 11 deletions(-) diff --git a/qt/launcher-gui/src/routes/Uninstall.svelte b/qt/launcher-gui/src/routes/Uninstall.svelte index 8ec9714aa..7e9089f09 100644 --- a/qt/launcher-gui/src/routes/Uninstall.svelte +++ b/qt/launcher-gui/src/routes/Uninstall.svelte @@ -4,25 +4,121 @@ License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html --> -
-
TODO: Uninstall
-
+{#await uninstallPromise} + + + +{:then res} + {#if !res} +
+ + + {$tr.launcherRemoveAllProfilesConfirm()} + + + {#if deleteBaseFolder} + + {/if} + + + +
+ {:else} + {@const kind = res.actionNeeded?.case} + {#if !kind} + + + + {:else} + + + + {#if kind === "unixScript"} + + {$tr.launcherUninstallUnix({ path: res.actionNeeded.value })} + + {:else if kind === "macManual"} + + {$tr.launcherUninstallMac()} + + {:else if kind === "windowsInstallerNotFound"} + + {$tr.launcherUninstallWinNotFound()} + + + {$tr.launcherUninstallWinNotFoundExtra()} + + {:else} + {@const { error, path } = res.actionNeeded.value} + + {$tr.launcherUninstallWinFailed()} + + + {$tr.launcherUninstallWinFailedExtra({ path })} + + +
{error}
+
+ {/if} + {/if} + {/if} +{:catch e} + + +
{e.message}
+
+{/await}