diff --git a/src/App.svelte b/src/App.svelte index 16eecd7..40c9d3e 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -37,12 +37,18 @@ root = document.documentElement; SharkGame.Settings.subscribe((settings) => { - root.classList.toggle("no-theme", !settings.enableThemes.current); - settings.theme.options.forEach((theme) => { - root.classList.toggle(theme, theme === settings.theme.current); + root.classList.toggle( + "no-theme", + !settings.appearance.enableThemes.current + ); + settings.appearance.theme.options.forEach((theme) => { + root.classList.toggle( + theme, + theme === settings.appearance.theme.current + ); }); - if (settings.updateCheck.current && updateInterval === undefined) { + if (settings.other.updateCheck.current && updateInterval === undefined) { updateInterval = setInterval(async () => { if ( CURRENT_HASH !== undefined && @@ -52,7 +58,7 @@ } }, 6 * 60 * 1000); } else if ( - !settings.updateCheck.current && + !settings.other.updateCheck.current && updateInterval !== undefined ) { clearInterval(updateInterval); diff --git a/src/components/Modals/BaseModal.svelte b/src/components/Modals/BaseModal.svelte index 332fda2..2f577c2 100644 --- a/src/components/Modals/BaseModal.svelte +++ b/src/components/Modals/BaseModal.svelte @@ -53,6 +53,11 @@ padding: 16px; background: var(--color-darker); pointer-events: auto; + + max-width: 80%; + max-height: 80%; + + overflow-y: auto; } } diff --git a/src/components/Modals/SettingsModal.svelte b/src/components/Modals/SettingsModal.svelte index 0db4e58..5b3538a 100644 --- a/src/components/Modals/SettingsModal.svelte +++ b/src/components/Modals/SettingsModal.svelte @@ -1,75 +1,82 @@ - - - - - - - {#each Object.entries($usableSettings) as [settingName, setting] (settingName)} - - - {setting.name} - ({setting.description}) - - {#each setting.options as option} - + {#each Object.entries($settings) as [categoryName, categorySettings]} + {categoryName.toUpperCase()} + + {#each Object.entries(categorySettings) as [settingId, setting] (settingId)} + + + {setting.name} + ({setting.description}) + + {#each setting.options as option} { setting.current = option; }}>{option} - {/each} - - {/each} - + > + {/each} + + {/each} + + {/each} +