@nyig/models 0.4.18 → 0.5.0

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/index.d.mts CHANGED
@@ -418,7 +418,7 @@ type AttendanceResponse = z.infer<typeof zAttendanceResponse>;
418
418
 
419
419
  declare const zBCampTracker: z.ZodObject<{
420
420
  course: z.ZodString;
421
- teacher: z.ZodString;
421
+ teacher: z.ZodArray<z.ZodString, "many">;
422
422
  semester: z.ZodString;
423
423
  /**
424
424
  * occurrences are tracked by week for camps
@@ -484,7 +484,7 @@ declare const zBCampTracker: z.ZodObject<{
484
484
  notes: z.ZodOptional<z.ZodString>;
485
485
  }, "strip", z.ZodTypeAny, {
486
486
  course: string;
487
- teacher: string;
487
+ teacher: string[];
488
488
  semester: string;
489
489
  occurrences: string[];
490
490
  attendances: {
@@ -507,7 +507,7 @@ declare const zBCampTracker: z.ZodObject<{
507
507
  isNonPublic?: boolean | undefined;
508
508
  }, {
509
509
  course: string;
510
- teacher: string;
510
+ teacher: string[];
511
511
  semester: string;
512
512
  occurrences: string[];
513
513
  attendances: {
@@ -531,7 +531,7 @@ declare const zBCampTracker: z.ZodObject<{
531
531
  }>;
532
532
  declare const zCampTracker: z.ZodObject<{
533
533
  course: z.ZodString;
534
- teacher: z.ZodString;
534
+ teacher: z.ZodArray<z.ZodString, "many">;
535
535
  semester: z.ZodString;
536
536
  /**
537
537
  * occurrences are tracked by week for camps
@@ -603,7 +603,7 @@ declare const zCampTracker: z.ZodObject<{
603
603
  }, z.UnknownKeysParam, z.ZodTypeAny, {
604
604
  _id: string;
605
605
  course: string;
606
- teacher: string;
606
+ teacher: string[];
607
607
  semester: string;
608
608
  occurrences: string[];
609
609
  attendances: {
@@ -630,7 +630,7 @@ declare const zCampTracker: z.ZodObject<{
630
630
  }, {
631
631
  _id: string;
632
632
  course: string;
633
- teacher: string;
633
+ teacher: string[];
634
634
  semester: string;
635
635
  occurrences: string[];
636
636
  attendances: {
@@ -712,7 +712,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
712
712
  fullCampTuition?: number | undefined;
713
713
  superadminOnly?: boolean | undefined;
714
714
  }>;
715
- teacher: z.ZodObject<{
715
+ teacher: z.ZodArray<z.ZodObject<{
716
716
  name: z.ZodString;
717
717
  username: z.ZodOptional<z.ZodString>;
718
718
  password: z.ZodOptional<z.ZodString>;
@@ -800,7 +800,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
800
800
  bio?: string | undefined;
801
801
  imageUrl?: string | undefined;
802
802
  available?: number[][][] | undefined;
803
- }>;
803
+ }>, "many">;
804
804
  semester: z.ZodObject<{
805
805
  season: z.ZodNativeEnum<typeof Season>;
806
806
  year: z.ZodNumber;
@@ -1047,7 +1047,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
1047
1047
  bio?: string | undefined;
1048
1048
  imageUrl?: string | undefined;
1049
1049
  available?: number[][][] | undefined;
1050
- };
1050
+ }[];
1051
1051
  semester: {
1052
1052
  _id: string;
1053
1053
  season: Season;
@@ -1147,7 +1147,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
1147
1147
  bio?: string | undefined;
1148
1148
  imageUrl?: string | undefined;
1149
1149
  available?: number[][][] | undefined;
1150
- };
1150
+ }[];
1151
1151
  semester: {
1152
1152
  _id: string;
1153
1153
  season: Season;
package/index.d.ts CHANGED
@@ -418,7 +418,7 @@ type AttendanceResponse = z.infer<typeof zAttendanceResponse>;
418
418
 
419
419
  declare const zBCampTracker: z.ZodObject<{
420
420
  course: z.ZodString;
421
- teacher: z.ZodString;
421
+ teacher: z.ZodArray<z.ZodString, "many">;
422
422
  semester: z.ZodString;
423
423
  /**
424
424
  * occurrences are tracked by week for camps
@@ -484,7 +484,7 @@ declare const zBCampTracker: z.ZodObject<{
484
484
  notes: z.ZodOptional<z.ZodString>;
485
485
  }, "strip", z.ZodTypeAny, {
486
486
  course: string;
487
- teacher: string;
487
+ teacher: string[];
488
488
  semester: string;
489
489
  occurrences: string[];
490
490
  attendances: {
@@ -507,7 +507,7 @@ declare const zBCampTracker: z.ZodObject<{
507
507
  isNonPublic?: boolean | undefined;
508
508
  }, {
509
509
  course: string;
510
- teacher: string;
510
+ teacher: string[];
511
511
  semester: string;
512
512
  occurrences: string[];
513
513
  attendances: {
@@ -531,7 +531,7 @@ declare const zBCampTracker: z.ZodObject<{
531
531
  }>;
532
532
  declare const zCampTracker: z.ZodObject<{
533
533
  course: z.ZodString;
534
- teacher: z.ZodString;
534
+ teacher: z.ZodArray<z.ZodString, "many">;
535
535
  semester: z.ZodString;
536
536
  /**
537
537
  * occurrences are tracked by week for camps
@@ -603,7 +603,7 @@ declare const zCampTracker: z.ZodObject<{
603
603
  }, z.UnknownKeysParam, z.ZodTypeAny, {
604
604
  _id: string;
605
605
  course: string;
606
- teacher: string;
606
+ teacher: string[];
607
607
  semester: string;
608
608
  occurrences: string[];
609
609
  attendances: {
@@ -630,7 +630,7 @@ declare const zCampTracker: z.ZodObject<{
630
630
  }, {
631
631
  _id: string;
632
632
  course: string;
633
- teacher: string;
633
+ teacher: string[];
634
634
  semester: string;
635
635
  occurrences: string[];
636
636
  attendances: {
@@ -712,7 +712,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
712
712
  fullCampTuition?: number | undefined;
713
713
  superadminOnly?: boolean | undefined;
714
714
  }>;
715
- teacher: z.ZodObject<{
715
+ teacher: z.ZodArray<z.ZodObject<{
716
716
  name: z.ZodString;
717
717
  username: z.ZodOptional<z.ZodString>;
718
718
  password: z.ZodOptional<z.ZodString>;
@@ -800,7 +800,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
800
800
  bio?: string | undefined;
801
801
  imageUrl?: string | undefined;
802
802
  available?: number[][][] | undefined;
803
- }>;
803
+ }>, "many">;
804
804
  semester: z.ZodObject<{
805
805
  season: z.ZodNativeEnum<typeof Season>;
806
806
  year: z.ZodNumber;
@@ -1047,7 +1047,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
1047
1047
  bio?: string | undefined;
1048
1048
  imageUrl?: string | undefined;
1049
1049
  available?: number[][][] | undefined;
1050
- };
1050
+ }[];
1051
1051
  semester: {
1052
1052
  _id: string;
1053
1053
  season: Season;
@@ -1147,7 +1147,7 @@ declare const zCampTrackerResponse: z.ZodObject<{
1147
1147
  bio?: string | undefined;
1148
1148
  imageUrl?: string | undefined;
1149
1149
  available?: number[][][] | undefined;
1150
- };
1150
+ }[];
1151
1151
  semester: {
1152
1152
  _id: string;
1153
1153
  season: Season;
package/index.js CHANGED
@@ -480,9 +480,10 @@ var zBSemester = import_zod12.z.object({
480
480
  var zSemester = addAutoProps(zBSemester);
481
481
 
482
482
  // src/interface/tracking/campTracker.ts
483
+ var MAX_TEACHERS = 10;
483
484
  var zBCampTracker = import_zod13.z.object({
484
485
  course: import_zod13.z.string(),
485
- teacher: import_zod13.z.string(),
486
+ teacher: import_zod13.z.array(import_zod13.z.string()).min(1, "Camp must have at least 1 teacher").max(MAX_TEACHERS, `Camp can have at most ${MAX_TEACHERS} teachers`),
486
487
  semester: import_zod13.z.string(),
487
488
  /**
488
489
  * occurrences are tracked by week for camps
@@ -499,7 +500,7 @@ var zBCampTracker = import_zod13.z.object({
499
500
  var zCampTracker = addAutoProps(zBCampTracker);
500
501
  var zCampTrackerResponse = zCampTracker.extend({
501
502
  course: zCourse,
502
- teacher: zTeacher,
503
+ teacher: import_zod13.z.array(zTeacher).min(1, "Camp must have at least 1 teacher").max(MAX_TEACHERS, `Camp can have at most ${MAX_TEACHERS} teachers`),
503
504
  semester: zSemester,
504
505
  attendances: import_zod13.z.array(zAttendanceResponse)
505
506
  });
@@ -821,11 +822,11 @@ var zBEventConfig = import_zod29.z.object({
821
822
  /**
822
823
  * Full name of the tournament
823
824
  */
824
- title: import_zod29.z.string(),
825
+ title: import_zod29.z.string().min(5),
825
826
  /**
826
827
  * Abbreviated title of the tournament
827
828
  */
828
- shortTitle: import_zod29.z.string(),
829
+ shortTitle: import_zod29.z.string().min(2),
829
830
  /**
830
831
  * Tournament start date and time
831
832
  */
@@ -837,11 +838,11 @@ var zBEventConfig = import_zod29.z.object({
837
838
  /**
838
839
  * Short description for tournament card
839
840
  */
840
- shortDescription: import_zod29.z.string(),
841
+ shortDescription: import_zod29.z.string().min(5),
841
842
  /**
842
843
  * Full description
843
844
  */
844
- description: import_zod29.z.string(),
845
+ description: import_zod29.z.string().min(5),
845
846
  /**
846
847
  * Defines the tournament details table with 2 columns
847
848
  * typically Time and Event
package/index.mjs CHANGED
@@ -372,9 +372,10 @@ var zBSemester = z12.object({
372
372
  var zSemester = addAutoProps(zBSemester);
373
373
 
374
374
  // src/interface/tracking/campTracker.ts
375
+ var MAX_TEACHERS = 10;
375
376
  var zBCampTracker = z13.object({
376
377
  course: z13.string(),
377
- teacher: z13.string(),
378
+ teacher: z13.array(z13.string()).min(1, "Camp must have at least 1 teacher").max(MAX_TEACHERS, `Camp can have at most ${MAX_TEACHERS} teachers`),
378
379
  semester: z13.string(),
379
380
  /**
380
381
  * occurrences are tracked by week for camps
@@ -391,7 +392,7 @@ var zBCampTracker = z13.object({
391
392
  var zCampTracker = addAutoProps(zBCampTracker);
392
393
  var zCampTrackerResponse = zCampTracker.extend({
393
394
  course: zCourse,
394
- teacher: zTeacher,
395
+ teacher: z13.array(zTeacher).min(1, "Camp must have at least 1 teacher").max(MAX_TEACHERS, `Camp can have at most ${MAX_TEACHERS} teachers`),
395
396
  semester: zSemester,
396
397
  attendances: z13.array(zAttendanceResponse)
397
398
  });
@@ -713,11 +714,11 @@ var zBEventConfig = z29.object({
713
714
  /**
714
715
  * Full name of the tournament
715
716
  */
716
- title: z29.string(),
717
+ title: z29.string().min(5),
717
718
  /**
718
719
  * Abbreviated title of the tournament
719
720
  */
720
- shortTitle: z29.string(),
721
+ shortTitle: z29.string().min(2),
721
722
  /**
722
723
  * Tournament start date and time
723
724
  */
@@ -729,11 +730,11 @@ var zBEventConfig = z29.object({
729
730
  /**
730
731
  * Short description for tournament card
731
732
  */
732
- shortDescription: z29.string(),
733
+ shortDescription: z29.string().min(5),
733
734
  /**
734
735
  * Full description
735
736
  */
736
- description: z29.string(),
737
+ description: z29.string().min(5),
737
738
  /**
738
739
  * Defines the tournament details table with 2 columns
739
740
  * typically Time and Event
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nyig/models",
3
- "version": "0.4.18",
3
+ "version": "0.5.0",
4
4
  "license": "MIT",
5
5
  "main": "index.js",
6
6
  "module": "index.mjs",