fix wrong theme class when logged out if default theme is changed ()

If you don't use the `auto` theme as the default, the `<html>` tag has
`theme-auto` as it's class when users are logged out. This PR changes it
to use the correct theme class for the default theme when logged out.
archive/2023-02-24/v1.18/crystal
crystal 2 years ago
parent c33747394d
commit 0ef0b182af
No known key found for this signature in database
GPG Key ID: 1122054731F7CC43

@ -1,5 +1,5 @@
<!DOCTYPE html>
<html lang="{{.locale.Lang}}" class="theme-{{if .SignedUser.Theme}}{{.SignedUser.Theme}}{{else}}auto{{end}}">
<html lang="{{.locale.Lang}}" class="theme-{{if .SignedUser.Theme}}{{.SignedUser.Theme}}{{else}}{{DefaultTheme}}{{end}}">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">

Loading…
Cancel
Save