@jlandis1/guessphrase-shared 1.0.35 → 1.0.36

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/src/auth.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- export const username = z.string().min(1, 'Username is required').max(30, 'Username cannot be more than 30 characters');
2
+ export const username = z.string().min(1, 'Username is required').max(20, 'Username cannot be more than 20 characters');
3
3
  const email = z
4
4
  .string()
5
5
  .email('Email is invalid')
@@ -7,7 +7,7 @@ const phrase = z.preprocess((v) => (typeof v === 'string' ? v.toLowerCase().trim
7
7
  .max(150, 'Phrase cannot be more than 150 characters')
8
8
  .regex(/^[A-Za-z]+( [A-Za-z]+)*$/, 'Only letters and single spaces are allowed')
9
9
  .refine((v) => v.split(' ').every((word) => word.length <= 15), { message: 'Each word must be 15 characters or less' }));
10
- const hint = z.string().max(50, 'Hint cannot be more than 50 characters').nullable();
10
+ const hint = z.string().max(200, 'Hint cannot be more than 200 characters').nullable();
11
11
  const date = z.string().regex(/^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01])$/, {
12
12
  message: 'Date must be in format YYYY-MM-DD'
13
13
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jlandis1/guessphrase-shared",
3
- "version": "1.0.35",
3
+ "version": "1.0.36",
4
4
  "type": "module",
5
5
  "description": "Shared library between Frontend and Backend for GuessPhrase",
6
6
  "main": "dist/index.js",