feat: complete v0.3 reading and discovery experience

This commit is contained in:
2026-07-19 03:16:18 +08:00
parent 5b5129fad5
commit 9ab09159e3
23 changed files with 1829 additions and 26 deletions
+6
View File
@@ -0,0 +1,6 @@
import { db } from "@/lib/db";
export function notify(userId: number, actorId: number, postId: number, type: "comment" | "reaction", message: string) {
if (userId === actorId) return;
db.prepare("INSERT INTO notifications(user_id,actor_id,post_id,type,message) VALUES(?,?,?,?,?)").run(userId, actorId, postId, type, message);
}