web/settings/advanced: hide reset settings button if there are no settings

This commit is contained in:
wukko 2024-07-31 13:53:34 +06:00
parent d1930c1dbc
commit 585ebd9cb4
No known key found for this signature in database
GPG key ID: 3E30B3F26C7B4AA2
2 changed files with 7 additions and 4 deletions

View file

@ -5,6 +5,7 @@
import SettingsToggle from "$components/buttons/SettingsToggle.svelte";
import ResetSettingsButton from "$components/buttons/ResetSettingsButton.svelte";
import TransferSettings from "$components/settings/TransferSettings.svelte";
import { storedSettings } from "$lib/state/settings";
</script>
<SettingsCategory sectionId="debug" title={$t("settings.advanced.debug")}>
@ -18,5 +19,7 @@
<SettingsCategory sectionId="data" title={$t("settings.advanced.data")}>
<TransferSettings />
{#if $storedSettings.schemaVersion}
<ResetSettingsButton />
{/if}
</SettingsCategory>