Files
cozsweet-frontend-nextjs/src/data/dto/user/user_view.ts
T

25 lines
626 B
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/**
* UI 侧用户模型(基于 data/dto/user/user + user_storage 重新导出 view-model
*
* 原始 Dart: lib/data/models/user/user.dart
*/
import { z } from "zod";
export const UserViewSchema = z.object({
id: z.string(),
username: z.string(),
email: z.string(),
avatarUrl: z.string(),
intimacy: z.number(),
dolBalance: z.number(),
creditBalance: z.number(),
vipExpiresAt: z.string().nullable(),
relationshipStage: z.string(),
currentMood: z.string(),
isGuest: z.boolean(),
isVip: z.boolean(),
voiceMinutesRemaining: z.number(),
});
export type UserView = z.infer<typeof UserViewSchema>;