feat: the rest of the owl

This commit is contained in:
Mythie
2024-02-29 13:22:21 +11:00
parent e3e2cfbcfd
commit ecc9dc63ea
36 changed files with 828 additions and 528 deletions

View File

@ -17,7 +17,14 @@ export const ZUpdateProfileMutationSchema = z.object({
});
export const ZUpdatePublicProfileMutationSchema = z.object({
url: z.string().min(1),
url: z
.string()
.trim()
.toLowerCase()
.min(1, { message: 'Please enter a valid username.' })
.regex(/^[a-z0-9-]+$/, {
message: 'Username can only container alphanumeric characters and dashes.',
}),
});
export const ZUpdatePasswordMutationSchema = z.object({