Files
cozsweet-frontend-nextjs/src/data/schemas/metrics/pwa_event.ts
T

17 lines
455 B
TypeScript

/**
* PWA 事件上报请求
* 原始 Dart: PwaEvent (lib/data/models/metrics/pwa_event.dart)
*/
import { z } from "zod";
export const PwaEventSchema = z.object({
deviceId: z.string(),
deviceType: z.string(),
timestamp: z.number(),
pwaInstalled: z.boolean().default(false),
pwaSupported: z.boolean().default(false),
});
export type PwaEventInput = z.input<typeof PwaEventSchema>;
export type PwaEventData = z.output<typeof PwaEventSchema>;