Add Nord theme option to theme selection dropdown in Navbar.svelte

This commit is contained in:
Sean Morley
2024-04-17 00:20:56 +00:00
parent 5efb2912c0
commit f0eb5441f0
4 changed files with 13 additions and 4 deletions

View File

@@ -31,7 +31,7 @@ export const actions: Actions = {
setTheme: async ( { url, cookies }) => {
const theme = url.searchParams.get("theme");
// change the theme only if it is one of the allowed themes
if (theme && ["light", "dark", "night", "retro", "forest"].includes(theme)) {
if (theme && ["light", "dark", "night", "retro", "forest", "nord"].includes(theme)) {
cookies.set("colortheme", theme, {
path: "/",
maxAge: 60 * 60 * 24 * 365,