@timardex/cluemart-shared 1.5.514 → 1.5.516

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/index.d.mts CHANGED
@@ -1223,6 +1223,7 @@ interface SchoolFormData {
1223
1223
  name: string;
1224
1224
  region: string;
1225
1225
  studentCount: number;
1226
+ socialMedia: SocialMediaType[] | null;
1226
1227
  termsAgreement?: TermsAgreement | null;
1227
1228
  }
1228
1229
  type CreateSchoolFormData = CreateFormData<SchoolFormData>;
@@ -1230,7 +1231,9 @@ type SchoolType = Omit<SchoolFormData, "logoUpload"> & {
1230
1231
  _id: string;
1231
1232
  createdAt: Date;
1232
1233
  deletedAt: Date | null;
1234
+ overallPoints: number | null;
1233
1235
  owner: OwnerType | null;
1236
+ schoolCode: string;
1234
1237
  updatedAt: Date | null;
1235
1238
  };
1236
1239
 
package/dist/index.d.ts CHANGED
@@ -1223,6 +1223,7 @@ interface SchoolFormData {
1223
1223
  name: string;
1224
1224
  region: string;
1225
1225
  studentCount: number;
1226
+ socialMedia: SocialMediaType[] | null;
1226
1227
  termsAgreement?: TermsAgreement | null;
1227
1228
  }
1228
1229
  type CreateSchoolFormData = CreateFormData<SchoolFormData>;
@@ -1230,7 +1231,9 @@ type SchoolType = Omit<SchoolFormData, "logoUpload"> & {
1230
1231
  _id: string;
1231
1232
  createdAt: Date;
1232
1233
  deletedAt: Date | null;
1234
+ overallPoints: number | null;
1233
1235
  owner: OwnerType | null;
1236
+ schoolCode: string;
1234
1237
  updatedAt: Date | null;
1235
1238
  };
1236
1239
 
package/dist/index.mjs CHANGED
@@ -640,9 +640,9 @@ function hashStringToNumber(seed) {
640
640
  }
641
641
  return hash >>> 0;
642
642
  }
643
- function seededShuffle(array6, seed) {
643
+ function seededShuffle(array7, seed) {
644
644
  const rng = createSeededRng(hashStringToNumber(seed));
645
- const result = [...array6];
645
+ const result = [...array7];
646
646
  for (let i = result.length - 1; i > 0; i--) {
647
647
  const j = Math.floor(rng() * (i + 1));
648
648
  [result[i], result[j]] = [result[j], result[i]];
@@ -6162,8 +6162,13 @@ var SCHOOL = gql35`
6162
6162
  owner {
6163
6163
  ...OwnerFields
6164
6164
  }
6165
+ overallPoints
6165
6166
  region
6166
6167
  studentCount
6168
+ schoolCode
6169
+ socialMedia {
6170
+ ...SocialMediaFields
6171
+ }
6167
6172
  termsAgreement {
6168
6173
  ...TermsAgreementFields
6169
6174
  }
@@ -6174,6 +6179,7 @@ var SCHOOL = gql35`
6174
6179
  ${RESOURCE_IMAGE_FIELDS_FRAGMENT}
6175
6180
  ${CONTACT_DETAILS_FIELDS_FRAGMENT}
6176
6181
  ${TERMS_AGREEMENT_FIELDS_FRAGMENT}
6182
+ ${SOCIAL_MEDIA_FIELDS_FRAGMENT}
6177
6183
  `;
6178
6184
  var GET_SCHOOL = gql35`
6179
6185
  query getSchool($_id: ID!) {
@@ -8047,6 +8053,7 @@ var schoolSchema = yup11.object().shape({
8047
8053
  location: locationSchema,
8048
8054
  name: yup11.string().trim().required("Name is required"),
8049
8055
  region: yup11.string().trim().required("Region is required"),
8056
+ socialMedia: yup11.array().of(socialMediaSchema).nullable().default(null),
8050
8057
  studentCount: yup11.number().label("Student Count").min(0, "Student count cannot be negative").required("Student count is required").test("no-leading-zeros", "", noLeadingZeros("Student Count"))
8051
8058
  });
8052
8059
 
@@ -8059,6 +8066,7 @@ var defaultSchoolFormValues = {
8059
8066
  logoUpload: null,
8060
8067
  name: "",
8061
8068
  region: "",
8069
+ socialMedia: [],
8062
8070
  studentCount: 0,
8063
8071
  termsAgreement: null
8064
8072
  };
@@ -8085,6 +8093,7 @@ function useSchoolForm(data) {
8085
8093
  logoUpload: data.logoUpload,
8086
8094
  name: data.name,
8087
8095
  region: data.region,
8096
+ socialMedia: data.socialMedia,
8088
8097
  studentCount: data.studentCount,
8089
8098
  termsAgreement: data.termsAgreement
8090
8099
  });
@@ -8093,6 +8102,7 @@ function useSchoolForm(data) {
8093
8102
  }
8094
8103
  }, [data]);
8095
8104
  const {
8105
+ socialMedia: socialMedia2,
8096
8106
  active,
8097
8107
  contactDetails,
8098
8108
  location,
@@ -8113,6 +8123,7 @@ function useSchoolForm(data) {
8113
8123
  logoUpload,
8114
8124
  name,
8115
8125
  region,
8126
+ socialMedia: socialMedia2,
8116
8127
  studentCount,
8117
8128
  termsAgreement
8118
8129
  },