diff options
| author | metamuffin <metamuffin@disroot.org> | 2026-02-23 23:47:38 +0100 |
|---|---|---|
| committer | metamuffin <metamuffin@disroot.org> | 2026-02-23 23:47:38 +0100 |
| commit | e7ed6eecbd9ccce486b34454fe77d71a22d1bfe2 (patch) | |
| tree | b0ec495626fac645c3065ea6e26c51a5eb006315 /ui/src/components/user.rs | |
| parent | 71b221e3e4df1190aa87331091a89243358e98c6 (diff) | |
| download | jellything-e7ed6eecbd9ccce486b34454fe77d71a22d1bfe2.tar jellything-e7ed6eecbd9ccce486b34454fe77d71a22d1bfe2.tar.bz2 jellything-e7ed6eecbd9ccce486b34454fe77d71a22d1bfe2.tar.zst | |
ui theme
Diffstat (limited to 'ui/src/components/user.rs')
| -rw-r--r-- | ui/src/components/user.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/ui/src/components/user.rs b/ui/src/components/user.rs index 600af22..cf1c123 100644 --- a/ui/src/components/user.rs +++ b/ui/src/components/user.rs @@ -30,6 +30,17 @@ markup::define! { input[type="password", id="password", name="password"]; input[type="submit", value=tr(ri.lang, "settings.update")]; } + form[method="POST", action=u_account_settings()] { + fieldset { + legend { @tr(ri.lang, "tag.Utpr") } + @for preset in [THEME_DARK, THEME_LIGHT] { + label { input[type="radio", name="theme_preset", value=preset.to_string(), checked=user.get(USER_THEME_PRESET) == Some(preset)]; @tr(ri.lang, &format!("tag.Utpr.{preset}")) } br; + } + } + label[for="accent"] { @tr(ri.lang, "tag.Utac") } + input[type="range", id="accent", name="theme_accent", min=0, max=360, step=1, value=user.get(USER_THEME_ACCENT)]; + input[type="submit", value=tr(ri.lang, "settings.update")]; + } // h2 { @tr(ri.lang, "settings.appearance") } // form[method="POST", action=u_account_settings()] { |