feat: use grid based layout instead
This commit is contained in:
1 parent
8733b9da6d
commit
c5d1a992f2
6 files changed
+29
-6
No files matched your search
@@ -51,6 +51,7 @@ interface Settings {
|
||||
randomPlaceholders: boolean
|
||||
modlogCardView: boolean | undefined
|
||||
debugInfo: boolean
|
||||
systemUI: boolean
|
||||
}
|
||||
|
||||
export const defaultSettings: Settings = {
|
||||
@@ -89,6 +90,7 @@ export const defaultSettings: Settings = {
|
||||
randomPlaceholders: toBool(env.PUBLIC_RANDOM_PLACEHOLDERS) ?? true,
|
||||
modlogCardView: toBool(env.PUBLIC_MODLOG_CARD_VIEW) ?? undefined,
|
||||
debugInfo: false,
|
||||
systemUI: true,
|
||||
}
|
||||
|
||||
export const userSettings = writable(defaultSettings)
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
import { pwaInfo } from 'virtual:pwa-info'
|
||||
import PwaReload from '$lib/PwaReload.svelte'
|
||||
import { inDarkTheme } from '$lib/ui/colors.js'
|
||||
import { userSettings } from '$lib/settings.js'
|
||||
|
||||
nProgress.configure({
|
||||
minimum: 0.4,
|
||||
@@ -42,11 +43,19 @@
|
||||
{@html webManifest}
|
||||
</svelte:head>
|
||||
|
||||
<div class="flex flex-col min-h-screen">
|
||||
<Navbar />
|
||||
<div
|
||||
class="grid grid-cols-12 grid-rows-6 min-h-screen {$userSettings.systemUI
|
||||
? 'font-system'
|
||||
: 'font-sans'}"
|
||||
>
|
||||
<div class="w-full col-span-12 row-span-full">
|
||||
<Navbar />
|
||||
</div>
|
||||
<ToastContainer />
|
||||
<Moderation />
|
||||
<div class="flex flex-row h-full w-full max-w-full flex-1">
|
||||
<div
|
||||
class="flex flex-row h-full w-full max-w-full flex-1 row-span-5 col-span-full"
|
||||
>
|
||||
<Sidebar />
|
||||
<main
|
||||
class="p-3 sm:p-6 min-w-0 w-full flex-[3] sm:rounded-tl-lg
|
||||
|
||||
@@ -201,6 +201,15 @@
|
||||
</Setting>
|
||||
|
||||
<SectionTitle class="mt-4">Other</SectionTitle>
|
||||
<Setting>
|
||||
<span slot="title">Font</span>
|
||||
<span slot="description">What font Photon should use.</span>
|
||||
<MultiSelect
|
||||
options={[true, false]}
|
||||
optionNames={['System UI', 'Browser Font']}
|
||||
bind:selected={$userSettings.systemUI}
|
||||
/>
|
||||
</Setting>
|
||||
<Setting>
|
||||
<Checkbox bind:checked={$userSettings.debugInfo} slot="title">
|
||||
Debug Info
|
||||
|
||||
+1
-1
@@ -6,7 +6,7 @@ body {
|
||||
@apply bg-slate-50 text-slate-900 dark:bg-zinc-950 dark:text-zinc-100 accent-slate-950 dark:accent-zinc-50;
|
||||
}
|
||||
|
||||
.dark > body {
|
||||
.dark {
|
||||
color-scheme: dark;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user