import "./styles.css"; import Link from "next/link"; import { getSession } from "@/lib/auth"; import { db } from "@/lib/db"; export const metadata = { title: "Mebbling", description: "聚合朋友公開筆記的 Memos Hub", alternates: { types: { "application/rss+xml": [{ url: "/rss.xml", title: "Mebbling RSS" }], "application/atom+xml": [{ url: "/atom.xml", title: "Mebbling Atom" }] } }, openGraph: { title: "Mebbling", description: "聚合朋友公開筆記的 Memos Hub", type: "website" } }; export default async function RootLayout({ children }: { children: React.ReactNode }) { const user = await getSession(); const unread = user ? Number((db.prepare("SELECT count(*) count FROM notifications WHERE user_id=? AND read_at IS NULL").get(user.id) as { count: number }).count) : 0; return
Mebbling
{children}
; }