AI Implementation feature(857): Authenticated Shell: Header, Quick Tabs and Change Password (#14)

This commit was merged in pull request #14.
This commit is contained in:
2026-07-21 22:26:47 +00:00
parent 8dc8cee769
commit b6dbfcc511
46 changed files with 2705 additions and 211 deletions
+22 -1
View File
@@ -37,4 +37,25 @@ export interface LoginResponse {
refreshToken: string;
expiresIn: number;
user: { id: string; username: string; role: 'admin' | 'player' };
}
}
export const ChangePasswordDtoSchema = z
.object({
oldPassword: z.string().min(1).max(256),
newPassword: z.string().min(1).max(256),
confirmNewPassword: z.string().min(1).max(256),
})
.refine((d) => d.newPassword === d.confirmNewPassword, {
path: ['confirmNewPassword'],
message: 'Passwords do not match',
});
export type ChangePasswordDto = z.infer<typeof ChangePasswordDtoSchema>;
export const MeResponseDtoSchema = z.object({
id: z.string(),
username: z.string(),
role: z.enum(['admin', 'player']),
rank: z.number().int().nullable(),
points: z.number().int(),
});
export type MeResponseDto = z.infer<typeof MeResponseDtoSchema>;