init: me-web 个人简历前端

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
Superuser
2026-05-18 20:10:54 +08:00
commit ff98547dbb
116 changed files with 9460 additions and 0 deletions
+13
View File
@@ -0,0 +1,13 @@
export const Session = {
cookieName: "admin_sid",
maxAgeMs: 365 * 24 * 60 * 60 * 1000,
} as const;
export const ErrorMessages = {
unauthenticated: "Authentication required",
insufficientRole: "Insufficient permissions",
} as const;
export const Paths = {
login: "/login",
} as const;
+15
View File
@@ -0,0 +1,15 @@
type AppError = { tag: "app_error"; status: number; message: string };
function appError(status: number, message: string): AppError {
return { tag: "app_error", status, message };
}
export const Errors = {
badRequest: (msg: string) => appError(400, msg),
unauthorized: (msg: string) => appError(401, msg),
forbidden: (msg: string) => appError(403, msg),
notFound: (msg: string) => appError(404, msg),
internal: (msg: string) => appError(500, msg),
} as const;
export type { AppError };
+2
View File
@@ -0,0 +1,2 @@
export type * from "../db/schema";
export * from "./errors";