style: tidy settings layout

This commit is contained in:
Jones Jankovic committed 2026-11-03 17:52:02 +10:30
1 parent f0abb8f6f3
commit 9acebab94b
2 files changed
+15 -20

No files matched your search

@@ -5,7 +5,6 @@
import Slider from "@/interface/components/Slider.svelte";
import Select from "@/interface/components/Select.svelte";
import HotkeyInput from "@/interface/components/HotkeyInput.svelte";
import SettingRow from "./SettingRow.svelte";
import { settingsState } from "@/seqta/utils/listeners/SettingsState";
import { cloudAuth } from "@/seqta/utils/CloudAuth";
import {
@@ -23,7 +22,6 @@
pluginSettingsStore,
type PluginSettingsEntry,
} from "./pluginSettingsState.svelte";
import { toMountableComponent } from "@/types/mountableComponent";
let {
section,
@@ -73,10 +71,10 @@
{#each visiblePlugins as plugin (plugin.pluginId)}
{@const perfPaused = pluginPerfPaused(plugin.pluginId)}
<SettingsCard class="{!(plugin as PluginSettingsEntry & { disableToggle?: boolean }).disableToggle && Object.keys(plugin.settings).length === 0 ? 'hidden' : ''} {perfPaused ? 'opacity-60' : ''}">
<SettingsCard class="divide-y divide-zinc-200/60 dark:divide-zinc-700/40 {!plugin.disableToggle && Object.keys(plugin.settings).length === 0 ? 'hidden' : ''} {perfPaused ? 'opacity-60' : ''}">
{#if perfPaused}
<div
class="flex justify-between items-center px-5 py-3 border-b border-amber-200/60 dark:border-amber-900/40 bg-amber-50/80 dark:bg-amber-950/20"
class="flex justify-between items-center px-4 py-3 rounded-lg bg-amber-50/80 dark:bg-amber-950/20"
>
<p class="text-sm text-amber-800 dark:text-amber-200">
Paused by Performance Mode — enable anyway
@@ -183,18 +181,5 @@
{/if}
{/each}
{/if}
{#if plugin.pluginId === "global-search"}
<SettingRow
title="Theme of the Month"
description="Show the monthly featured theme popup when a new entry is available"
id={15}
Component={toMountableComponent(Switch)}
{searchQuery}
props={{
state: !($settingsState.themeOfTheMonthDisabled ?? false),
onChange: (isOn: boolean) => (settingsState.themeOfTheMonthDisabled = !isOn),
}}
/>
{/if}
</SettingsCard>
{/each}
@@ -21,7 +21,7 @@
const isEngage = isSeqtaEngageExperience();
</script>
{#if matchesSearch(searchQuery, "Custom Theme Colour", "Interface Font", "Customise the overall theme colour of SEQTA Learn", "Choose the typeface used across SEQTA Learn")}
{#if matchesSearch(searchQuery, "Custom Theme Colour", "Interface Font", "Theme of the Month", "Customise the overall theme colour of SEQTA Learn", "Choose the typeface used across SEQTA Learn", "Show the monthly featured theme popup when a new entry is available")}
<SettingsCard class="divide-y divide-zinc-200/60 dark:divide-zinc-700/40">
{#each (
[
@@ -39,6 +39,16 @@
Component: Button,
props: { onClick: showFontPicker, text: "Change" },
},
{
title: "Theme of the Month",
description: "Show the monthly featured theme popup when a new entry is available",
id: 15,
Component: Switch,
props: {
state: !($settingsState.themeOfTheMonthDisabled ?? false),
onChange: (isOn: boolean) => (settingsState.themeOfTheMonthDisabled = !isOn),
},
},
] as unknown as SettingsList[]
) as option (option.id)}
<SettingRow {...option} {searchQuery} />
@@ -50,7 +60,7 @@
<SidebarAppearance {searchQuery} />
{/if}
{#if matchesSearch(searchQuery, "Adaptive Theme Colour", "Soft Gradient", "Smooth colour transition")}
{#if matchesSearch(searchQuery, "Adaptive Theme Colour", "Soft Gradient", "Smooth Colour Transition")}
<SettingsCard>
<div class="flex justify-between items-center px-4 py-3">
<div class="pr-4">
@@ -88,7 +98,7 @@
class="flex justify-between items-center px-4 py-3 pl-6 border-t border-zinc-100 dark:border-zinc-700/50"
>
<div class="pr-4">
<h2 class="text-sm font-bold">Smooth colour transition</h2>
<h2 class="text-sm font-bold">Smooth Colour Transition</h2>
<p class="text-xs text-zinc-600 dark:text-zinc-300">
Ease between class/subject colours when navigating instead of switching instantly
</p>