bump next, fix background color flash

This commit is contained in:
Max Leiter 2022-11-11 16:33:43 -08:00
parent 8b0b172f7d
commit 68570b3bb7
7 changed files with 10 additions and 12 deletions

View file

@ -1,5 +1,4 @@
import Auth from "@components/auth" import Auth from "@components/auth"
import config from "@lib/config"
import { getRequiresPasscode } from "pages/api/auth/requires-passcode" import { getRequiresPasscode } from "pages/api/auth/requires-passcode"
const getPasscode = async () => { const getPasscode = async () => {

View file

@ -3,12 +3,10 @@ import { notFound, useRouter } from "next/navigation"
import { cookies } from "next/headers" import { cookies } from "next/headers"
import { getPostsByUser } from "app/prisma" import { getPostsByUser } from "app/prisma"
import PostList from "@components/post-list" import PostList from "@components/post-list"
export default async function Mine() { export default async function Mine() {
// TODO: fix router usage
// const router = useRouter()
const userId = cookies().get(USER_COOKIE_NAME)?.value const userId = cookies().get(USER_COOKIE_NAME)?.value
if (!userId) { if (!userId) {
// return router.push("/signin")
return notFound() return notFound()
} }

View file

@ -9,9 +9,10 @@ interface RootLayoutProps {
export default function RootLayout({ children }: RootLayoutProps) { export default function RootLayout({ children }: RootLayoutProps) {
return ( return (
<ServerThemeProvider <ServerThemeProvider
disableTransitionOnChange
cookieName="drift-theme" cookieName="drift-theme"
// disableTransitionOnChange
attribute="data-theme" attribute="data-theme"
enableColorScheme
> >
<html lang="en"> <html lang="en">
<head> <head>

View file

@ -27,10 +27,10 @@ export function LayoutWrapper({ children }: { children: React.ReactNode }) {
warning: "var(--warning)" warning: "var(--warning)"
}, },
expressiveness: { expressiveness: {
dropdownBoxShadow: "0 0 0 1px var(--light-gray)", dropdownBoxShadow: "0 0 0 1px var(--lighter-gray)",
shadowSmall: "0 0 0 1px var(--light-gray)", shadowSmall: "0 0 0 1px var(--lighter-gray)",
shadowLarge: "0 0 0 1px var(--light-gray)", shadowLarge: "0 0 0 1px var(--lighter-gray)",
shadowMedium: "0 0 0 1px var(--light-gray)" shadowMedium: "0 0 0 1px var(--lighter-gray)",
}, },
layout: { layout: {
gap: "var(--gap)", gap: "var(--gap)",

View file

@ -68,7 +68,7 @@ renderer.listitem = (text, task, checked) => {
) )
} }
return `<li>${text}</li>` return <li>{text}</li>
} }
//@ts-ignore //@ts-ignore

View file

@ -8,8 +8,6 @@ export const getWelcomeContent = async () => {
const introContent = config.welcome_content const introContent = config.welcome_content
const introTitle = config.welcome_title const introTitle = config.welcome_title
console.log(renderMarkdown(introContent))
return { return {
title: introTitle, title: introTitle,
content: introContent, content: introContent,

View file

@ -99,6 +99,8 @@ body {
font-family: var(--font-sans); font-family: var(--font-sans);
display: flex; display: flex;
flex-direction: column; flex-direction: column;
/* TODO: this should be unnecessary. Overides the browser background for color-scheme while geist-ui catches up */
background: var(--bg);
} }
p { p {