/**
 * PWA 事件上报请求
 * 
 */
import { z } from "zod";

import {
  booleanOrFalse,
  numberOrZero,
  stringOrEmpty,
} from "../../nullable-defaults";

export const PwaEventSchema = z.object({
  deviceId: stringOrEmpty,
  deviceType: stringOrEmpty,
  timestamp: numberOrZero,
  pwaInstalled: booleanOrFalse,
  pwaSupported: booleanOrFalse,
});

export type PwaEventInput = z.input<typeof PwaEventSchema>;
export type PwaEventData = z.output<typeof PwaEventSchema>;
