import { z } from 'zod';

export const loginSchema = z.object({
  username: z.string().min(3).max(50).trim(),
  password: z.string().min(6).max(200),
});
export type LoginInput = z.infer<typeof loginSchema>;

export const changePasswordSchema = z.object({
  oldPassword: z.string().min(6).max(200),
  newPassword: z.string().min(8).max(200),
});
export type ChangePasswordInput = z.infer<typeof changePasswordSchema>;

export interface AuthUser {
  userId: number;
  cityId: number | null;
  username: string;
  fullName: string;
  phone: string;
  homeLocalityId: number | null;
  isCaptain: boolean;
  isVolunteer: boolean;
  isSuperAdmin: boolean;
}
