feat: full site build — Project/Melody schema (Option A), admin CRUD, public sections, uploads, email+SMTP, internal analytics, legal pages, docs
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
import { z } from "zod";
|
||||
|
||||
export const analyticsEventTypeSchema = z.enum([
|
||||
"PAGE_VIEW",
|
||||
"PROJECT_OPEN",
|
||||
"MELODY_PLAY",
|
||||
"PROJECT_LINK_CLICK",
|
||||
"CONTACT_SUBMITTED",
|
||||
]);
|
||||
|
||||
export const analyticsEventSchema = z.object({
|
||||
type: analyticsEventTypeSchema,
|
||||
path: z.string().trim().max(2048).optional(),
|
||||
entityId: z.string().cuid().optional(),
|
||||
});
|
||||
|
||||
export type AnalyticsEventInput = z.infer<typeof analyticsEventSchema>;
|
||||
Reference in New Issue
Block a user