From bb0058a148078fad0d4d96f124a38eede6de5448 Mon Sep 17 00:00:00 2001 From: Alicia Sykes Date: Fri, 24 Oct 2025 07:58:57 +0100 Subject: [PATCH] Implemented settings backup/restore --- src/lib/components/furniture/Header.svelte | 4 +- .../components/furniture/SettingsPanel.svelte | 177 +++++++++++++++++- src/lib/config/customizable-settings.ts | 45 +++++ src/lib/constants/site.ts | 2 +- src/routes/about/+page.svelte | 15 +- src/styles/pages.scss | 2 +- 6 files changed, 231 insertions(+), 14 deletions(-) diff --git a/src/lib/components/furniture/Header.svelte b/src/lib/components/furniture/Header.svelte index 9927da8..5421038 100644 --- a/src/lib/components/furniture/Header.svelte +++ b/src/lib/components/furniture/Header.svelte @@ -1,6 +1,6 @@ {#snippet validationMessages(errors: string[], warnings: string[])} @@ -515,6 +560,55 @@ {/if} + + {#if standalone} +
+

Syncing Settings and Backup/Restore

+

+ Your settings are saved in your browser's local storage, and so they will be retained even after you quit the + app. +

+

+ Since we don't require login/signup to use the app, there is currently no way to automatically sync your + settings across devices. But if you're self-hosting Networking Toolbox, you can apply settings in your config, + by including the following environment variables. This way, you're settings will be applied to all users across + all devices. +

+ + {#if showExportSettings} +
+
+

Environment Variables

+ +
+

+ Current environment variable values. Copy and paste into your config file for self-hosted instances. +

+ +
{envVarsString}
+ + +
+ {/if} +
+ {/if} + {#if !standalone}