@timardex/cluemart-shared 1.5.549 → 1.5.551

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.
Files changed (48) hide show
  1. package/dist/{chunk-LOABFNIJ.mjs → chunk-5LODYRBR.mjs} +10 -16
  2. package/dist/chunk-5LODYRBR.mjs.map +1 -0
  3. package/dist/{chunk-Z3JWNX2U.mjs → chunk-DYUATO2Z.mjs} +12 -6
  4. package/dist/chunk-DYUATO2Z.mjs.map +1 -0
  5. package/dist/{chunk-L47NQHZ6.mjs → chunk-OVEYADVZ.mjs} +2 -2
  6. package/dist/{chunk-UBAAAYJY.mjs → chunk-SUCEE4LU.mjs} +15 -7
  7. package/dist/{chunk-UBAAAYJY.mjs.map → chunk-SUCEE4LU.mjs.map} +1 -1
  8. package/dist/{chunk-FICQ3PR5.mjs → chunk-ZOPHRV6M.mjs} +12 -2
  9. package/dist/chunk-ZOPHRV6M.mjs.map +1 -0
  10. package/dist/{game-1CSiEjlf.d.ts → dailyClue-CvOPk6am.d.mts} +12 -56
  11. package/dist/{game-BPtE3yaQ.d.mts → dailyClue-CvOPk6am.d.ts} +12 -56
  12. package/dist/formFields/index.cjs +4 -1
  13. package/dist/formFields/index.cjs.map +1 -1
  14. package/dist/formFields/index.mjs +3 -3
  15. package/dist/graphql/index.cjs +14 -6
  16. package/dist/graphql/index.cjs.map +1 -1
  17. package/dist/graphql/index.d.mts +2 -2
  18. package/dist/graphql/index.d.ts +2 -2
  19. package/dist/graphql/index.mjs +1 -1
  20. package/dist/hooks/index.cjs +25 -8
  21. package/dist/hooks/index.cjs.map +1 -1
  22. package/dist/hooks/index.d.mts +2 -2
  23. package/dist/hooks/index.d.ts +2 -2
  24. package/dist/hooks/index.mjs +10 -6
  25. package/dist/hooks/index.mjs.map +1 -1
  26. package/dist/index.cjs +45 -22
  27. package/dist/index.cjs.map +1 -1
  28. package/dist/index.d.mts +24 -13
  29. package/dist/index.d.ts +24 -13
  30. package/dist/index.mjs +43 -22
  31. package/dist/index.mjs.map +1 -1
  32. package/dist/{post-Lc5PrxY6.d.ts → post-B941IgWP.d.ts} +54 -4
  33. package/dist/{post-CY53UsA7.d.mts → post-C3L-bejc.d.mts} +54 -4
  34. package/dist/types/index.cjs +16 -12
  35. package/dist/types/index.cjs.map +1 -1
  36. package/dist/types/index.d.mts +2 -2
  37. package/dist/types/index.d.ts +2 -2
  38. package/dist/types/index.mjs +3 -3
  39. package/dist/utils/index.cjs +15 -4
  40. package/dist/utils/index.cjs.map +1 -1
  41. package/dist/utils/index.d.mts +5 -2
  42. package/dist/utils/index.d.ts +5 -2
  43. package/dist/utils/index.mjs +6 -2
  44. package/package.json +1 -1
  45. package/dist/chunk-FICQ3PR5.mjs.map +0 -1
  46. package/dist/chunk-LOABFNIJ.mjs.map +0 -1
  47. package/dist/chunk-Z3JWNX2U.mjs.map +0 -1
  48. /package/dist/{chunk-L47NQHZ6.mjs.map → chunk-OVEYADVZ.mjs.map} +0 -0
@@ -1,7 +1,7 @@
1
1
  import { EnumOSPlatform, EnumUserRole, EnumSubscriptionStatus, EnumUserLicence, EnumResourceType, EnumPartnerType } from './enums/index.js';
2
- import { A as AssociateType, W as ResourceImageType, h as UserLicenceType, J as PromoCodeType, _ as TermsAgreement, D as DateTimeType, s as CreateFormData, r as BaseResourceType, L as LocationType, B as BaseResourceTypeFormData, Q as ResourceContactDetailsType, X as SocialMediaType, y as OwnerType } from './global-CDqmjLH1.js';
2
+ import { A as AssociateType, W as ResourceImageType, h as UserLicenceType, J as PromoCodeType, _ as TermsAgreement, D as DateTimeType, s as CreateFormData, r as BaseResourceType, L as LocationType, B as BaseResourceTypeFormData, y as OwnerType, Q as ResourceContactDetailsType, X as SocialMediaType } from './global-CDqmjLH1.js';
3
3
  import { PosterAssetId } from './images/index.js';
4
- import { B as BaseGame } from './game-1CSiEjlf.js';
4
+ import { E as EnumGameType, a as DailyClueGameData, G as GameDate, D as DailyClueBaseGame } from './dailyClue-CvOPk6am.js';
5
5
 
6
6
  type UserFormData = {
7
7
  _id?: string;
@@ -140,6 +140,56 @@ type AppSettingsType = AppSettingsFormData & {
140
140
  updatedAt: Date | null;
141
141
  };
142
142
 
143
+ type BaseGameMap = {
144
+ [EnumGameType.DAILY_CLUE]: DailyClueBaseGame;
145
+ };
146
+ type BaseGameType = {
147
+ [K in keyof BaseGameMap]: BaseGameMap[K] | null;
148
+ };
149
+ declare enum EnumGameStatus {
150
+ GAME_COMPLETED = "GAME_COMPLETED",
151
+ GAME_IN_PROGRESS = "GAME_IN_PROGRESS",
152
+ GAME_LEFT = "GAME_LEFT",
153
+ GAME_STARTED = "GAME_STARTED"
154
+ }
155
+ type GameHistory = {
156
+ createdAt: Date;
157
+ gameDate: GameDate;
158
+ gameStatus: EnumGameStatus;
159
+ gameType: EnumGameType;
160
+ pointsEarned: number;
161
+ };
162
+ type GameDataMap = {
163
+ [EnumGameType.DAILY_CLUE]: DailyClueGameData;
164
+ };
165
+ type GameDataType = {
166
+ [K in keyof GameDataMap]?: GameDataMap[K] | null;
167
+ };
168
+ type GameType = {
169
+ _id: string;
170
+ active: boolean;
171
+ createdAt: Date;
172
+ gameData: GameDataType;
173
+ gameHistory: GameHistory[] | null;
174
+ gameType: EnumGameType;
175
+ updatedAt: Date | null;
176
+ };
177
+ type GameDocType = {
178
+ _id: string;
179
+ active: boolean;
180
+ createdAt: Date;
181
+ deletedAt: Date | null;
182
+ games: GameType[] | null;
183
+ owner: OwnerType;
184
+ points: number;
185
+ updatedAt: Date | null;
186
+ };
187
+ type GameLeaderboard = {
188
+ gameHistory: GameHistory[] | null;
189
+ overallPoints: number;
190
+ owner: OwnerType;
191
+ };
192
+
143
193
  interface PosterInputType {
144
194
  description: string;
145
195
  posterName: PosterAssetId;
@@ -268,7 +318,7 @@ type PostContentList = {
268
318
  };
269
319
  };
270
320
  type PostContentGame = {
271
- game: BaseGame;
321
+ game: BaseGameType;
272
322
  };
273
323
  type PostContentData = PostContentGame | PostContentTextarea | PostContentImage | PostContentVideo | PostContentList;
274
324
  type PostContentFormData = {
@@ -303,4 +353,4 @@ type PostType = Omit<PostFormData, "content" | "coverUpload"> & {
303
353
  updatedAt: Date | null;
304
354
  };
305
355
 
306
- export { type AdType as A, type PostContentList as B, type CreateUserFormData as C, type PostContentTextarea as D, EnumAdStatus as E, type PostContentType as F, type PostContentVideo as G, type PostFileInput as H, type PosterInputType as I, type SchoolRegisteredUserType as J, type StripeSubscription as K, type SubscriptionPlanData as L, type MarketingMaterialRequestInputType as M, type SubscriptionPricingData as N, type UserActivity as O, type PartnerType as P, type UserActivityEvent as Q, type ResourceByUser as R, type SubscriptionPlansResponse as S, type UserType as U, type SubscriptionStatusData as a, type PostType as b, EnumPostType as c, type AppSettingsType as d, type SchoolReturnType as e, type SchoolType as f, type UserFormData as g, type PartnerFormData as h, type AdFormData as i, type CreateAdFormData as j, type CreatePartnerFormData as k, type PostFormData as l, type CreatePostFormData as m, type AppSettingsFormData as n, type CreateAppSettingsFormData as o, type SchoolFormData as p, type CreateSchoolFormData as q, type AdResource as r, EnumAdShowOn as s, EnumAdStyle as t, EnumAdType as u, EnumPostContentType as v, type PostContentData as w, type PostContentFormData as x, type PostContentGame as y, type PostContentImage as z };
356
+ export { type AdType as A, type BaseGameMap as B, type CreateUserFormData as C, type GameType as D, EnumAdStatus as E, type PostContentData as F, type GameDocType as G, type PostContentFormData as H, type PostContentGame as I, type PostContentImage as J, type PostContentList as K, type PostContentTextarea as L, type MarketingMaterialRequestInputType as M, type PostContentType as N, type PostContentVideo as O, type PartnerType as P, type PostFileInput as Q, type ResourceByUser as R, type SubscriptionPlansResponse as S, type PosterInputType as T, type UserType as U, type SchoolRegisteredUserType as V, type StripeSubscription as W, type SubscriptionPlanData as X, type SubscriptionPricingData as Y, type UserActivity as Z, type UserActivityEvent as _, type SubscriptionStatusData as a, type PostType as b, EnumPostType as c, type AppSettingsType as d, type GameLeaderboard as e, type SchoolReturnType as f, type SchoolType as g, type UserFormData as h, type PartnerFormData as i, type AdFormData as j, type CreateAdFormData as k, type CreatePartnerFormData as l, type PostFormData as m, type CreatePostFormData as n, type AppSettingsFormData as o, type CreateAppSettingsFormData as p, type SchoolFormData as q, type CreateSchoolFormData as r, type AdResource as s, type BaseGameType as t, EnumAdShowOn as u, EnumAdStyle as v, EnumAdType as w, EnumGameStatus as x, EnumPostContentType as y, type GameHistory as z };
@@ -1,7 +1,7 @@
1
1
  import { EnumOSPlatform, EnumUserRole, EnumSubscriptionStatus, EnumUserLicence, EnumResourceType, EnumPartnerType } from './enums/index.mjs';
2
- import { A as AssociateType, W as ResourceImageType, h as UserLicenceType, J as PromoCodeType, _ as TermsAgreement, D as DateTimeType, s as CreateFormData, r as BaseResourceType, L as LocationType, B as BaseResourceTypeFormData, Q as ResourceContactDetailsType, X as SocialMediaType, y as OwnerType } from './global-ClbRuePq.mjs';
2
+ import { A as AssociateType, W as ResourceImageType, h as UserLicenceType, J as PromoCodeType, _ as TermsAgreement, D as DateTimeType, s as CreateFormData, r as BaseResourceType, L as LocationType, B as BaseResourceTypeFormData, y as OwnerType, Q as ResourceContactDetailsType, X as SocialMediaType } from './global-ClbRuePq.mjs';
3
3
  import { PosterAssetId } from './images/index.mjs';
4
- import { B as BaseGame } from './game-BPtE3yaQ.mjs';
4
+ import { E as EnumGameType, a as DailyClueGameData, G as GameDate, D as DailyClueBaseGame } from './dailyClue-CvOPk6am.mjs';
5
5
 
6
6
  type UserFormData = {
7
7
  _id?: string;
@@ -140,6 +140,56 @@ type AppSettingsType = AppSettingsFormData & {
140
140
  updatedAt: Date | null;
141
141
  };
142
142
 
143
+ type BaseGameMap = {
144
+ [EnumGameType.DAILY_CLUE]: DailyClueBaseGame;
145
+ };
146
+ type BaseGameType = {
147
+ [K in keyof BaseGameMap]: BaseGameMap[K] | null;
148
+ };
149
+ declare enum EnumGameStatus {
150
+ GAME_COMPLETED = "GAME_COMPLETED",
151
+ GAME_IN_PROGRESS = "GAME_IN_PROGRESS",
152
+ GAME_LEFT = "GAME_LEFT",
153
+ GAME_STARTED = "GAME_STARTED"
154
+ }
155
+ type GameHistory = {
156
+ createdAt: Date;
157
+ gameDate: GameDate;
158
+ gameStatus: EnumGameStatus;
159
+ gameType: EnumGameType;
160
+ pointsEarned: number;
161
+ };
162
+ type GameDataMap = {
163
+ [EnumGameType.DAILY_CLUE]: DailyClueGameData;
164
+ };
165
+ type GameDataType = {
166
+ [K in keyof GameDataMap]?: GameDataMap[K] | null;
167
+ };
168
+ type GameType = {
169
+ _id: string;
170
+ active: boolean;
171
+ createdAt: Date;
172
+ gameData: GameDataType;
173
+ gameHistory: GameHistory[] | null;
174
+ gameType: EnumGameType;
175
+ updatedAt: Date | null;
176
+ };
177
+ type GameDocType = {
178
+ _id: string;
179
+ active: boolean;
180
+ createdAt: Date;
181
+ deletedAt: Date | null;
182
+ games: GameType[] | null;
183
+ owner: OwnerType;
184
+ points: number;
185
+ updatedAt: Date | null;
186
+ };
187
+ type GameLeaderboard = {
188
+ gameHistory: GameHistory[] | null;
189
+ overallPoints: number;
190
+ owner: OwnerType;
191
+ };
192
+
143
193
  interface PosterInputType {
144
194
  description: string;
145
195
  posterName: PosterAssetId;
@@ -268,7 +318,7 @@ type PostContentList = {
268
318
  };
269
319
  };
270
320
  type PostContentGame = {
271
- game: BaseGame;
321
+ game: BaseGameType;
272
322
  };
273
323
  type PostContentData = PostContentGame | PostContentTextarea | PostContentImage | PostContentVideo | PostContentList;
274
324
  type PostContentFormData = {
@@ -303,4 +353,4 @@ type PostType = Omit<PostFormData, "content" | "coverUpload"> & {
303
353
  updatedAt: Date | null;
304
354
  };
305
355
 
306
- export { type AdType as A, type PostContentList as B, type CreateUserFormData as C, type PostContentTextarea as D, EnumAdStatus as E, type PostContentType as F, type PostContentVideo as G, type PostFileInput as H, type PosterInputType as I, type SchoolRegisteredUserType as J, type StripeSubscription as K, type SubscriptionPlanData as L, type MarketingMaterialRequestInputType as M, type SubscriptionPricingData as N, type UserActivity as O, type PartnerType as P, type UserActivityEvent as Q, type ResourceByUser as R, type SubscriptionPlansResponse as S, type UserType as U, type SubscriptionStatusData as a, type PostType as b, EnumPostType as c, type AppSettingsType as d, type SchoolReturnType as e, type SchoolType as f, type UserFormData as g, type PartnerFormData as h, type AdFormData as i, type CreateAdFormData as j, type CreatePartnerFormData as k, type PostFormData as l, type CreatePostFormData as m, type AppSettingsFormData as n, type CreateAppSettingsFormData as o, type SchoolFormData as p, type CreateSchoolFormData as q, type AdResource as r, EnumAdShowOn as s, EnumAdStyle as t, EnumAdType as u, EnumPostContentType as v, type PostContentData as w, type PostContentFormData as x, type PostContentGame as y, type PostContentImage as z };
356
+ export { type AdType as A, type BaseGameMap as B, type CreateUserFormData as C, type GameType as D, EnumAdStatus as E, type PostContentData as F, type GameDocType as G, type PostContentFormData as H, type PostContentGame as I, type PostContentImage as J, type PostContentList as K, type PostContentTextarea as L, type MarketingMaterialRequestInputType as M, type PostContentType as N, type PostContentVideo as O, type PartnerType as P, type PostFileInput as Q, type ResourceByUser as R, type SubscriptionPlansResponse as S, type PosterInputType as T, type UserType as U, type SchoolRegisteredUserType as V, type StripeSubscription as W, type SubscriptionPlanData as X, type SubscriptionPricingData as Y, type UserActivity as Z, type UserActivityEvent as _, type SubscriptionStatusData as a, type PostType as b, EnumPostType as c, type AppSettingsType as d, type GameLeaderboard as e, type SchoolReturnType as f, type SchoolType as g, type UserFormData as h, type PartnerFormData as i, type AdFormData as j, type CreateAdFormData as k, type CreatePartnerFormData as l, type PostFormData as m, type CreatePostFormData as n, type AppSettingsFormData as o, type CreateAppSettingsFormData as p, type SchoolFormData as q, type CreateSchoolFormData as r, type AdResource as s, type BaseGameType as t, EnumAdShowOn as u, EnumAdStyle as v, EnumAdType as w, EnumGameStatus as x, EnumPostContentType as y, type GameHistory as z };
@@ -97,7 +97,22 @@ var EnumPostContentType = /* @__PURE__ */ ((EnumPostContentType2) => {
97
97
  return EnumPostContentType2;
98
98
  })(EnumPostContentType || {});
99
99
 
100
- // src/types/game.ts
100
+ // src/types/game/index.ts
101
+ var EnumGameStatus = /* @__PURE__ */ ((EnumGameStatus2) => {
102
+ EnumGameStatus2["GAME_COMPLETED"] = "GAME_COMPLETED";
103
+ EnumGameStatus2["GAME_IN_PROGRESS"] = "GAME_IN_PROGRESS";
104
+ EnumGameStatus2["GAME_LEFT"] = "GAME_LEFT";
105
+ EnumGameStatus2["GAME_STARTED"] = "GAME_STARTED";
106
+ return EnumGameStatus2;
107
+ })(EnumGameStatus || {});
108
+
109
+ // src/types/game/global.ts
110
+ var EnumGameType = /* @__PURE__ */ ((EnumGameType2) => {
111
+ EnumGameType2["DAILY_CLUE"] = "dailyClue";
112
+ return EnumGameType2;
113
+ })(EnumGameType || {});
114
+
115
+ // src/types/game/dailyClue.ts
101
116
  var OBJECT_ID_PATH_SEGMENT = "[a-f0-9]{24}";
102
117
  var OBJECT_ID_PATH_SEGMENT_END = `${OBJECT_ID_PATH_SEGMENT}$`;
103
118
  var gameScreenIdentifierList = [
@@ -192,20 +207,9 @@ var gameScreenIdentifierList = [
192
207
  match: "/visitors"
193
208
  }
194
209
  ];
195
- var EnumGameType = /* @__PURE__ */ ((EnumGameType2) => {
196
- EnumGameType2["DAILY_CLUE"] = "dailyClue";
197
- return EnumGameType2;
198
- })(EnumGameType || {});
199
210
  var gameTypeToDisplayName = {
200
211
  ["dailyClue" /* DAILY_CLUE */]: "Daily Clue"
201
212
  };
202
- var EnumGameStatus = /* @__PURE__ */ ((EnumGameStatus2) => {
203
- EnumGameStatus2["GAME_COMPLETED"] = "GAME_COMPLETED";
204
- EnumGameStatus2["GAME_IN_PROGRESS"] = "GAME_IN_PROGRESS";
205
- EnumGameStatus2["GAME_LEFT"] = "GAME_LEFT";
206
- EnumGameStatus2["GAME_STARTED"] = "GAME_STARTED";
207
- return EnumGameStatus2;
208
- })(EnumGameStatus || {});
209
213
  // Annotate the CommonJS export names for ESM import in node:
210
214
  0 && (module.exports = {
211
215
  EnumActivity,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/types/index.ts","../../src/types/auth.ts","../../src/types/global.ts","../../src/types/ad.ts","../../src/types/resourceActivities.ts","../../src/types/post.ts","../../src/types/game.ts"],"sourcesContent":["export * from \"./admin\";\nexport * from \"./auth\";\nexport * from \"./chat\";\nexport * from \"./contactUs\";\nexport * from \"./global\";\nexport * from \"./event\";\nexport * from \"./notification\";\nexport * from \"./poster\";\nexport * from \"./relation\";\nexport * from \"./vendor\";\nexport * from \"./user\";\nexport * from \"./ad\";\nexport * from \"./resourceActivities\";\nexport * from \"./partner\";\nexport * from \"./post\";\nexport * from \"./appSettings\";\nexport * from \"./googleImportedMarket\";\nexport * from \"./game\";\nexport * from \"./school\";\n","import {\n CreateFormData,\n EnumOSPlatform,\n PromoCodeType,\n TermsAgreement,\n} from \"src\";\n\nexport enum EnumVerificationType {\n REGISTER = \"register\",\n RESET_PASSWORD = \"resetPassword\",\n}\n\nexport type LoginFormData = {\n email: string;\n isAdminPage?: boolean;\n password: string;\n platform?: EnumOSPlatform;\n};\n\nexport type CreateLoginFormData = CreateFormData<LoginFormData>;\n\nexport type RegisterFormData = {\n email: string;\n firstName: string;\n lastName: string;\n password: string;\n platform?: EnumOSPlatform;\n preferredRegion: string;\n promoCode?: PromoCodeType | null;\n termsAgreement?: TermsAgreement | null;\n};\n\nexport type CreateRegisterFormData = CreateFormData<RegisterFormData>;\n\nexport type RequestPasswordResetFormData = {\n email: string;\n};\n\nexport type CreateRequestPasswordResetFormData =\n CreateFormData<RequestPasswordResetFormData>;\n\nexport type ResetPasswordFormData = {\n confirmPassword: string;\n email: string;\n password: string;\n};\n\nexport type CreateResetPasswordFormData = CreateFormData<ResetPasswordFormData>;\n\nexport type ValidateVerificationTokenFormData = {\n email: string;\n verificationToken: string;\n verificationType?: EnumVerificationType;\n};\n\nexport type CreateValidateVerificationTokenFormData =\n CreateFormData<ValidateVerificationTokenFormData>;\n","import {\n Control,\n FieldValues,\n FormState,\n UseFormHandleSubmit,\n UseFormReset,\n UseFormSetValue,\n UseFormWatch,\n} from \"react-hook-form\";\n\nimport {\n EnumEventDateStatus,\n EnumEventType,\n EnumResourceType,\n EnumSocialMedia,\n EnumUserLicence,\n} from \"../enums\";\n\nimport { EventListItemType } from \"./event\";\nimport { VendorType } from \"./vendor\";\n\nexport const PROMO_CODE_PREFIX = \"CM-\";\n\nexport type PromoCodeType = `${typeof PROMO_CODE_PREFIX}${string}`;\n\nexport type Nullable<T> = {\n [K in keyof T]: T[K] | null | undefined;\n};\n\nexport type DeviceInfo = {\n appBuildNumber: string;\n appId: string;\n appVersion: string;\n brand: string;\n deviceName: string;\n installationId: string;\n manufacturer: string;\n modelName: string;\n osName: string;\n osVersion: string;\n timestamp: string;\n};\n\nexport type TermsAgreement = DeviceInfo & {\n termVersion: string;\n};\n\nexport type ResourceContactDetailsType = {\n email?: string | null;\n landlinePhone?: string | null;\n mobilePhone?: string | null;\n};\n\nexport type ResourceImageType = {\n active?: boolean | null;\n source: string;\n title: string;\n};\n\nexport type SocialMediaType = {\n name?: EnumSocialMedia;\n link?: string;\n};\n\nexport type UserLicenceType = {\n expiryDate: Date;\n issuedDate: Date;\n licenceType: EnumUserLicence;\n prevLicenceType?: EnumUserLicence | null;\n};\n\nexport type AssociateType = {\n email: string;\n resourceId: string;\n resourceType: EnumResourceType;\n licence: UserLicenceType;\n};\n\nexport type OwnerType = {\n email: string;\n userId: string;\n};\n\nexport interface BaseResourceTypeFormData {\n _id?: string;\n active: boolean;\n associates: AssociateType[] | null;\n contactDetails: ResourceContactDetailsType | null;\n cover: ResourceImageType;\n coverUpload?: ResourceImageType | null;\n description: string;\n images?: ResourceImageType[] | null;\n imagesUpload?: ResourceImageType[] | null;\n logo?: ResourceImageType | null;\n logoUpload?: ResourceImageType | null;\n name: string;\n owner?: OwnerType | null;\n promoCodes?: PromoCodeType[] | null;\n region: string;\n socialMedia: SocialMediaType[] | null;\n termsAgreement?: TermsAgreement | null;\n}\n\nexport type PosterUsageType = {\n month: string;\n count: number;\n};\n\nexport type BaseResourceType = Omit<\n BaseResourceTypeFormData,\n \"_id\" | \"coverUpload\" | \"imagesUpload\" | \"logoUpload\"\n> & {\n _id: string;\n adIds?: string[] | null;\n createdAt: Date;\n deletedAt: Date | null;\n posterUsage?: PosterUsageType | null;\n rating?: number | null;\n reviewCount?: number | null;\n updatedAt: Date | null;\n};\n\nexport type LocationGeoType = {\n coordinates: number[]; // [longitude, latitude]\n type: \"Point\"; // Mongoose GeoJSON type\n};\n\nexport type LocationType = {\n city: string;\n country: string;\n fullAddress: string;\n geo: LocationGeoType;\n latitude: number;\n longitude: number;\n region: string;\n};\n\nexport type DateTimeType = {\n dateStatus: EnumEventDateStatus;\n endDate: string;\n endTime: string;\n startDate: string;\n startTime: string;\n};\n\nexport type Region = {\n latitude: number;\n latitudeDelta: number;\n longitude: number;\n longitudeDelta: number;\n};\n\nexport type ResourceDetails = {\n dateTime: DateTimeType[] | null;\n description: string | null;\n eventStatus?: EventStatusType | null;\n location: LocationType | null;\n resourceCover: ResourceImageType | null;\n resourceId: string;\n resourceLogo: ResourceImageType | null;\n resourceName: string;\n resourceType: EnumResourceType;\n};\n\nexport type GeocodeLocation = Pick<LocationType, \"latitude\" | \"longitude\">;\n\nexport type EventStatusType = {\n claimed: boolean;\n eventType: EnumEventType;\n googlePlaceId?: string | null;\n};\n\nexport interface FormField {\n disabled?: boolean;\n helperText?: string;\n isTextArea?: boolean;\n keyboardType?:\n | \"default\"\n | \"email-address\"\n | \"number-pad\"\n | \"url\"\n | \"decimal-pad\"\n | \"phone-pad\";\n name: string;\n placeholder: string;\n required?: boolean;\n secureTextEntry?: boolean;\n}\n\nexport interface FormDateField {\n dateMode: \"date\" | \"time\";\n helperText?: string;\n name: \"endDate\" | \"endTime\" | \"startDate\" | \"startTime\";\n placeholder: string;\n}\n\nexport interface SubcategoryItems {\n id: string;\n name: string;\n description?: string | null;\n}\n\nexport interface Subcategory {\n id: string;\n name: string;\n items?: SubcategoryItems[] | null;\n}\n\nexport interface Category {\n color?: string | null;\n description?: string | null;\n id: string;\n name: string;\n subcategories: Subcategory[];\n}\n\nexport type OptionItem = {\n value: string;\n label: string;\n};\n\nexport type ImageObjectType = {\n uri: string;\n type: string;\n name: string;\n};\n\nexport interface ResourceConnectionsType {\n events: EventListItemType[] | null;\n vendors: VendorType[] | null;\n}\n\nexport interface CreateFormData<T extends FieldValues> {\n control: Control<T, any>;\n fields: T;\n formState: FormState<T>;\n handleSubmit: UseFormHandleSubmit<T, any>;\n reset: UseFormReset<T>;\n setValue: UseFormSetValue<T>;\n watch: UseFormWatch<T>;\n}\n","import { EnumResourceType } from \"src/enums\";\n\nimport { CreateFormData, SocialMediaType } from \"./global\";\n\nexport enum EnumAdShowOn {\n EVENTS_PAGE = \"Events_page\",\n FRONT_PAGE = \"Front_page\",\n PARTNERS_PAGE = \"Partners_page\",\n VENDORS_PAGE = \"Vendors_page\",\n}\n\nexport enum EnumAdStatus {\n ACTIVE = \"Active\",\n PAUSED = \"Paused\",\n EXPIRED = \"Expired\",\n}\n\nexport enum EnumAdType {\n SPONSORED = \"Sponsored\",\n FREE = \"Free\",\n}\n\nexport enum EnumAdStyle {\n BLOOM = \"Bloom\",\n RISE = \"Rise\",\n}\n\nexport type AdResource = {\n adDescription: string | null;\n adImage: string | null;\n adStyle: EnumAdStyle | null;\n adTitle: string | null;\n adType: EnumAdType | null;\n resourceId: string | null;\n resourceName: string | null;\n resourceRegion: string | null;\n resourceType: EnumResourceType | null;\n};\n\nexport interface AdFormData {\n active: boolean;\n end: Date; // ISO date string\n resource: AdResource;\n showOn: EnumAdShowOn[];\n start?: Date; // ISO date string\n status: EnumAdStatus;\n targetRegion: string[];\n}\n\nexport type CreateAdFormData = CreateFormData<AdFormData>;\n\nexport interface AdType extends AdFormData {\n _id: string;\n clicks?: number; // How many times the ad was clicked\n createdAt: Date;\n impressions?: number; // How often the ad was seen\n start: Date; // ISO date string\n updatedAt: Date | null;\n}\n","import {\n EnumEventDateStatus,\n EnumOSPlatform,\n EnumResourceType,\n} from \"src/enums\";\n\nimport { LocationGeoType } from \"./global\";\n\nexport enum EnumActivity {\n FAVORITE = \"FAVORITE\",\n GOING = \"GOING\",\n INTERESTED = \"INTERESTED\",\n PRESENT = \"PRESENT\",\n VIEW = \"VIEW\",\n}\n\nexport type ResourceActivityEntry = {\n activityType: EnumActivity;\n location: LocationGeoType | null;\n dateStatus?: EnumEventDateStatus | null;\n startDate?: string | null;\n startTime?: string | null;\n timestamp: Date;\n userAgent: EnumOSPlatform;\n userId?: string | null;\n};\n\nexport type ResourceActivityType = {\n _id: string;\n resourceType: EnumResourceType;\n resourceId: string;\n activity: ResourceActivityEntry[];\n};\n\nexport type ResourceActivityInputType = {\n resourceId: string;\n resourceType: EnumResourceType;\n activity: Omit<ResourceActivityEntry, \"timestamp\">;\n};\n","import { EnumResourceType } from \"src/enums\";\n\nimport { BaseGame } from \"./game\";\nimport { CreateFormData, ResourceImageType } from \"./global\";\n\nexport enum EnumPostType {\n DAILY_MEETS = \"daily_meets\",\n DAILY_TIPS = \"daily_tips\",\n DAILY_GAMES = \"daily_games\",\n}\n\nexport enum EnumPostContentType {\n GAME = \"game\",\n IMAGE = \"image\",\n LIST = \"list\",\n TEXTAREA = \"textarea\",\n VIDEO = \"video\",\n}\n\nexport type PostFileInput = {\n source: File;\n title?: string;\n};\n\nexport type PostContentTextarea = {\n textarea: {\n title?: string;\n data: string;\n };\n};\n\nexport type PostContentImage = {\n images: ResourceImageType[] | null;\n imagesUpload?: PostFileInput[] | null;\n};\n\nexport type PostContentVideo = {\n video: {\n source: string;\n title?: string;\n };\n};\n\nexport type PostContentList = {\n list: {\n title?: string;\n items: {\n text: string;\n }[];\n };\n};\n\nexport type PostContentGame = {\n game: BaseGame;\n};\n\nexport type PostContentData =\n | PostContentGame\n | PostContentTextarea\n | PostContentImage\n | PostContentVideo\n | PostContentList;\n\nexport type PostContentFormData = {\n contentData?: PostContentData | null;\n contentOrder?: number | null;\n contentType?: EnumPostContentType | null;\n};\n\nexport interface PostFormData {\n active: boolean;\n caption: string;\n content: PostContentFormData[];\n cover?: ResourceImageType | null;\n coverUpload?: PostFileInput | null;\n postType: EnumPostType;\n resource?: {\n resourceId: string;\n resourceType: EnumResourceType;\n resourceRegion: string;\n } | null;\n tags?: string[] | null;\n title: string;\n}\n\nexport type CreatePostFormData = CreateFormData<PostFormData>;\n\nexport type PostContentType = Omit<PostContentFormData, \"contentData\"> & {\n contentData: Omit<PostContentData, \"imagesUpload\">;\n};\n\nexport type PostType = Omit<PostFormData, \"content\" | \"coverUpload\"> & {\n _id: string;\n content: PostContentType[];\n createdAt: Date;\n deletedAt: Date | null;\n updatedAt: Date | null;\n};\n","import { OwnerType } from \"./global\";\n\nconst OBJECT_ID_PATH_SEGMENT = \"[a-f0-9]{24}\";\nconst OBJECT_ID_PATH_SEGMENT_END = `${OBJECT_ID_PATH_SEGMENT}$`;\n\nexport const gameScreenIdentifierList = [\n {\n clue: \"Where your actions turn into a timeline.\",\n id: \"activities\",\n match: \"/profile/activities\",\n },\n {\n clue: \"Where conversations happen without speaking.\",\n id: \"chat\",\n match: \"/profile/chat\",\n },\n {\n clue: \"The place to redefine who you are.\",\n id: \"edit-profile\",\n match: \"/profile/edit-profile\",\n },\n {\n clue: \"A single moment worth showing up for.\",\n id: \"single-event\",\n match: new RegExp(`^/events/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"What’s happening around you, right now.\",\n id: \"events-near-me\",\n match: \"/events/events-near-me\",\n },\n {\n clue: \"A collection of things worth attending.\",\n id: \"events\",\n match: \"/events\",\n },\n {\n clue: \"What’s happening in a wider area — not just nearby.\",\n id: \"events-region\",\n match: /^\\/events\\/region\\/[^/]+$/,\n },\n {\n clue: \"Where fun becomes a challenge.\",\n id: \"games\",\n match: \"/games\",\n },\n {\n clue: \"Your starting point for everything.\",\n id: \"home\",\n match: \"/\",\n },\n {\n clue: \"Where the app whispers what you shouldn’t miss.\",\n id: \"notifications\",\n match: \"/notifications\",\n },\n {\n clue: \"Where you fine-tune your experience.\",\n id: \"options\",\n match: \"/options\",\n },\n {\n clue: \"An organisation or creator supporting the community.\",\n id: \"single-partner\",\n match: new RegExp(`^/partners/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Organisations and creators supporting the community.\",\n id: \"partners\",\n match: \"/partners\",\n },\n {\n clue: \"A single published post in full view.\",\n id: \"single-visitor-post\",\n match: new RegExp(`^/visitors/post/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Your identity, on display.\",\n id: \"profile\",\n match: \"/profile\",\n },\n {\n clue: \"One stallholder offering something valuable.\",\n id: \"single-vendor\",\n match: new RegExp(`^/vendors/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Where every stallholder waits under the right category.\",\n id: \"vendors\",\n match: \"/vendors\",\n },\n {\n clue: \"Where you browse articles and posts from around the platform.\",\n id: \"visitors\",\n match: \"/visitors\",\n },\n] as const;\n\nexport type GamePlacement = (typeof gameScreenIdentifierList)[number][\"id\"];\nexport type GamePlacementClue =\n (typeof gameScreenIdentifierList)[number][\"clue\"];\n\nexport enum EnumGameType {\n DAILY_CLUE = \"dailyClue\",\n}\n\nexport const gameTypeToDisplayName: Record<EnumGameType, string> = {\n [EnumGameType.DAILY_CLUE]: \"Daily Clue\",\n};\n\nexport type GameDate = {\n startDate: Date;\n endDate: Date;\n};\n\nexport type BaseGame = {\n gameDate: GameDate;\n gameSolution: string;\n gameType: EnumGameType;\n};\n\nexport type DailyClueGameData = {\n gameFields: BaseGame;\n lastFoundDate: Date | null;\n points: number;\n letterInfo: {\n collected: string[] | null; // The letters the user has found, e.g. [\"C\", \"L\", \"U\"]\n shuffled: string[]; // The letters of the solution, but shuffled, e.g. [\"L\", \"C\", \"U\"]\n todaysLetter: string | null; // The letter the user has to find today, e.g. \"C\"\n todaysClue: GamePlacementClue | null; // The clue for user to find the letter, e.g. related to {todaysPlacement}\n todaysPlacement: GamePlacement | null; // The screen where the user has to find the clue, e.g. \"HomeScreen\"\n };\n // User has found the clue 3 days in a row, this is incrementing if the user finds the clue and decrements if user misses a day\n streak: number;\n};\n\nexport enum EnumGameStatus {\n GAME_COMPLETED = \"GAME_COMPLETED\",\n GAME_IN_PROGRESS = \"GAME_IN_PROGRESS\",\n GAME_LEFT = \"GAME_LEFT\",\n GAME_STARTED = \"GAME_STARTED\",\n}\n\nexport type GameHistory = {\n createdAt: Date;\n gameDate: GameDate;\n gameStatus: EnumGameStatus;\n gameType: EnumGameType;\n pointsEarned: number;\n};\n\ntype GameDataMap = {\n [EnumGameType.DAILY_CLUE]: DailyClueGameData;\n};\ntype GameDataType = {\n [K in keyof GameDataMap]?: GameDataMap[K] | null;\n};\n\nexport type GameType = {\n _id: string;\n active: boolean;\n createdAt: Date;\n gameData: GameDataType;\n gameHistory: GameHistory[] | null;\n gameType: EnumGameType;\n updatedAt: Date | null;\n};\n\nexport type GameDocType = {\n _id: string;\n active: boolean;\n createdAt: Date;\n deletedAt: Date | null;\n games: GameType[] | null;\n owner: OwnerType;\n points: number;\n updatedAt: Date | null;\n};\n\nexport type GameLeaderboard = {\n gameHistory: GameHistory[] | null;\n overallPoints: number;\n owner: OwnerType;\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACOO,IAAK,uBAAL,kBAAKA,0BAAL;AACL,EAAAA,sBAAA,cAAW;AACX,EAAAA,sBAAA,oBAAiB;AAFP,SAAAA;AAAA,GAAA;;;ACcL,IAAM,oBAAoB;;;ACjB1B,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,iBAAc;AACd,EAAAA,cAAA,gBAAa;AACb,EAAAA,cAAA,mBAAgB;AAChB,EAAAA,cAAA,kBAAe;AAJL,SAAAA;AAAA,GAAA;AAOL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,YAAS;AACT,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AAuB,GAAG;AAC7B;AA4BO,IAAK,iBAAL,kBAAKC,oBAAL;AACL,EAAAA,gBAAA,oBAAiB;AACjB,EAAAA,gBAAA,sBAAmB;AACnB,EAAAA,gBAAA,eAAY;AACZ,EAAAA,gBAAA,kBAAe;AAJL,SAAAA;AAAA,GAAA;","names":["EnumVerificationType","EnumAdShowOn","EnumAdStatus","EnumAdType","EnumAdStyle","EnumActivity","EnumPostType","EnumPostContentType","EnumGameType","EnumGameStatus"]}
1
+ {"version":3,"sources":["../../src/types/index.ts","../../src/types/auth.ts","../../src/types/global.ts","../../src/types/ad.ts","../../src/types/resourceActivities.ts","../../src/types/post.ts","../../src/types/game/index.ts","../../src/types/game/global.ts","../../src/types/game/dailyClue.ts"],"sourcesContent":["export * from \"./admin\";\nexport * from \"./auth\";\nexport * from \"./chat\";\nexport * from \"./contactUs\";\nexport * from \"./global\";\nexport * from \"./event\";\nexport * from \"./notification\";\nexport * from \"./poster\";\nexport * from \"./relation\";\nexport * from \"./vendor\";\nexport * from \"./user\";\nexport * from \"./ad\";\nexport * from \"./resourceActivities\";\nexport * from \"./partner\";\nexport * from \"./post\";\nexport * from \"./appSettings\";\nexport * from \"./googleImportedMarket\";\nexport * from \"./game\";\nexport * from \"./game/dailyClue\";\nexport * from \"./game/global\";\nexport * from \"./school\";\n","import {\n CreateFormData,\n EnumOSPlatform,\n PromoCodeType,\n TermsAgreement,\n} from \"src\";\n\nexport enum EnumVerificationType {\n REGISTER = \"register\",\n RESET_PASSWORD = \"resetPassword\",\n}\n\nexport type LoginFormData = {\n email: string;\n isAdminPage?: boolean;\n password: string;\n platform?: EnumOSPlatform;\n};\n\nexport type CreateLoginFormData = CreateFormData<LoginFormData>;\n\nexport type RegisterFormData = {\n email: string;\n firstName: string;\n lastName: string;\n password: string;\n platform?: EnumOSPlatform;\n preferredRegion: string;\n promoCode?: PromoCodeType | null;\n termsAgreement?: TermsAgreement | null;\n};\n\nexport type CreateRegisterFormData = CreateFormData<RegisterFormData>;\n\nexport type RequestPasswordResetFormData = {\n email: string;\n};\n\nexport type CreateRequestPasswordResetFormData =\n CreateFormData<RequestPasswordResetFormData>;\n\nexport type ResetPasswordFormData = {\n confirmPassword: string;\n email: string;\n password: string;\n};\n\nexport type CreateResetPasswordFormData = CreateFormData<ResetPasswordFormData>;\n\nexport type ValidateVerificationTokenFormData = {\n email: string;\n verificationToken: string;\n verificationType?: EnumVerificationType;\n};\n\nexport type CreateValidateVerificationTokenFormData =\n CreateFormData<ValidateVerificationTokenFormData>;\n","import {\n Control,\n FieldValues,\n FormState,\n UseFormHandleSubmit,\n UseFormReset,\n UseFormSetValue,\n UseFormWatch,\n} from \"react-hook-form\";\n\nimport {\n EnumEventDateStatus,\n EnumEventType,\n EnumResourceType,\n EnumSocialMedia,\n EnumUserLicence,\n} from \"../enums\";\n\nimport { EventListItemType } from \"./event\";\nimport { VendorType } from \"./vendor\";\n\nexport const PROMO_CODE_PREFIX = \"CM-\";\n\nexport type PromoCodeType = `${typeof PROMO_CODE_PREFIX}${string}`;\n\nexport type Nullable<T> = {\n [K in keyof T]: T[K] | null | undefined;\n};\n\nexport type DeviceInfo = {\n appBuildNumber: string;\n appId: string;\n appVersion: string;\n brand: string;\n deviceName: string;\n installationId: string;\n manufacturer: string;\n modelName: string;\n osName: string;\n osVersion: string;\n timestamp: string;\n};\n\nexport type TermsAgreement = DeviceInfo & {\n termVersion: string;\n};\n\nexport type ResourceContactDetailsType = {\n email?: string | null;\n landlinePhone?: string | null;\n mobilePhone?: string | null;\n};\n\nexport type ResourceImageType = {\n active?: boolean | null;\n source: string;\n title: string;\n};\n\nexport type SocialMediaType = {\n name?: EnumSocialMedia;\n link?: string;\n};\n\nexport type UserLicenceType = {\n expiryDate: Date;\n issuedDate: Date;\n licenceType: EnumUserLicence;\n prevLicenceType?: EnumUserLicence | null;\n};\n\nexport type AssociateType = {\n email: string;\n resourceId: string;\n resourceType: EnumResourceType;\n licence: UserLicenceType;\n};\n\nexport type OwnerType = {\n email: string;\n userId: string;\n};\n\nexport interface BaseResourceTypeFormData {\n _id?: string;\n active: boolean;\n associates: AssociateType[] | null;\n contactDetails: ResourceContactDetailsType | null;\n cover: ResourceImageType;\n coverUpload?: ResourceImageType | null;\n description: string;\n images?: ResourceImageType[] | null;\n imagesUpload?: ResourceImageType[] | null;\n logo?: ResourceImageType | null;\n logoUpload?: ResourceImageType | null;\n name: string;\n owner?: OwnerType | null;\n promoCodes?: PromoCodeType[] | null;\n region: string;\n socialMedia: SocialMediaType[] | null;\n termsAgreement?: TermsAgreement | null;\n}\n\nexport type PosterUsageType = {\n month: string;\n count: number;\n};\n\nexport type BaseResourceType = Omit<\n BaseResourceTypeFormData,\n \"_id\" | \"coverUpload\" | \"imagesUpload\" | \"logoUpload\"\n> & {\n _id: string;\n adIds?: string[] | null;\n createdAt: Date;\n deletedAt: Date | null;\n posterUsage?: PosterUsageType | null;\n rating?: number | null;\n reviewCount?: number | null;\n updatedAt: Date | null;\n};\n\nexport type LocationGeoType = {\n coordinates: number[]; // [longitude, latitude]\n type: \"Point\"; // Mongoose GeoJSON type\n};\n\nexport type LocationType = {\n city: string;\n country: string;\n fullAddress: string;\n geo: LocationGeoType;\n latitude: number;\n longitude: number;\n region: string;\n};\n\nexport type DateTimeType = {\n dateStatus: EnumEventDateStatus;\n endDate: string;\n endTime: string;\n startDate: string;\n startTime: string;\n};\n\nexport type Region = {\n latitude: number;\n latitudeDelta: number;\n longitude: number;\n longitudeDelta: number;\n};\n\nexport type ResourceDetails = {\n dateTime: DateTimeType[] | null;\n description: string | null;\n eventStatus?: EventStatusType | null;\n location: LocationType | null;\n resourceCover: ResourceImageType | null;\n resourceId: string;\n resourceLogo: ResourceImageType | null;\n resourceName: string;\n resourceType: EnumResourceType;\n};\n\nexport type GeocodeLocation = Pick<LocationType, \"latitude\" | \"longitude\">;\n\nexport type EventStatusType = {\n claimed: boolean;\n eventType: EnumEventType;\n googlePlaceId?: string | null;\n};\n\nexport interface FormField {\n disabled?: boolean;\n helperText?: string;\n isTextArea?: boolean;\n keyboardType?:\n | \"default\"\n | \"email-address\"\n | \"number-pad\"\n | \"url\"\n | \"decimal-pad\"\n | \"phone-pad\";\n name: string;\n placeholder: string;\n required?: boolean;\n secureTextEntry?: boolean;\n}\n\nexport interface FormDateField {\n dateMode: \"date\" | \"time\";\n helperText?: string;\n name: \"endDate\" | \"endTime\" | \"startDate\" | \"startTime\";\n placeholder: string;\n}\n\nexport interface SubcategoryItems {\n id: string;\n name: string;\n description?: string | null;\n}\n\nexport interface Subcategory {\n id: string;\n name: string;\n items?: SubcategoryItems[] | null;\n}\n\nexport interface Category {\n color?: string | null;\n description?: string | null;\n id: string;\n name: string;\n subcategories: Subcategory[];\n}\n\nexport type OptionItem = {\n value: string;\n label: string;\n};\n\nexport type ImageObjectType = {\n uri: string;\n type: string;\n name: string;\n};\n\nexport interface ResourceConnectionsType {\n events: EventListItemType[] | null;\n vendors: VendorType[] | null;\n}\n\nexport interface CreateFormData<T extends FieldValues> {\n control: Control<T, any>;\n fields: T;\n formState: FormState<T>;\n handleSubmit: UseFormHandleSubmit<T, any>;\n reset: UseFormReset<T>;\n setValue: UseFormSetValue<T>;\n watch: UseFormWatch<T>;\n}\n","import { EnumResourceType } from \"src/enums\";\n\nimport { CreateFormData, SocialMediaType } from \"./global\";\n\nexport enum EnumAdShowOn {\n EVENTS_PAGE = \"Events_page\",\n FRONT_PAGE = \"Front_page\",\n PARTNERS_PAGE = \"Partners_page\",\n VENDORS_PAGE = \"Vendors_page\",\n}\n\nexport enum EnumAdStatus {\n ACTIVE = \"Active\",\n PAUSED = \"Paused\",\n EXPIRED = \"Expired\",\n}\n\nexport enum EnumAdType {\n SPONSORED = \"Sponsored\",\n FREE = \"Free\",\n}\n\nexport enum EnumAdStyle {\n BLOOM = \"Bloom\",\n RISE = \"Rise\",\n}\n\nexport type AdResource = {\n adDescription: string | null;\n adImage: string | null;\n adStyle: EnumAdStyle | null;\n adTitle: string | null;\n adType: EnumAdType | null;\n resourceId: string | null;\n resourceName: string | null;\n resourceRegion: string | null;\n resourceType: EnumResourceType | null;\n};\n\nexport interface AdFormData {\n active: boolean;\n end: Date; // ISO date string\n resource: AdResource;\n showOn: EnumAdShowOn[];\n start?: Date; // ISO date string\n status: EnumAdStatus;\n targetRegion: string[];\n}\n\nexport type CreateAdFormData = CreateFormData<AdFormData>;\n\nexport interface AdType extends AdFormData {\n _id: string;\n clicks?: number; // How many times the ad was clicked\n createdAt: Date;\n impressions?: number; // How often the ad was seen\n start: Date; // ISO date string\n updatedAt: Date | null;\n}\n","import {\n EnumEventDateStatus,\n EnumOSPlatform,\n EnumResourceType,\n} from \"src/enums\";\n\nimport { LocationGeoType } from \"./global\";\n\nexport enum EnumActivity {\n FAVORITE = \"FAVORITE\",\n GOING = \"GOING\",\n INTERESTED = \"INTERESTED\",\n PRESENT = \"PRESENT\",\n VIEW = \"VIEW\",\n}\n\nexport type ResourceActivityEntry = {\n activityType: EnumActivity;\n location: LocationGeoType | null;\n dateStatus?: EnumEventDateStatus | null;\n startDate?: string | null;\n startTime?: string | null;\n timestamp: Date;\n userAgent: EnumOSPlatform;\n userId?: string | null;\n};\n\nexport type ResourceActivityType = {\n _id: string;\n resourceType: EnumResourceType;\n resourceId: string;\n activity: ResourceActivityEntry[];\n};\n\nexport type ResourceActivityInputType = {\n resourceId: string;\n resourceType: EnumResourceType;\n activity: Omit<ResourceActivityEntry, \"timestamp\">;\n};\n","import { EnumResourceType } from \"src/enums\";\n\nimport { BaseGameType } from \"./game\";\nimport { CreateFormData, ResourceImageType } from \"./global\";\n\nexport enum EnumPostType {\n DAILY_MEETS = \"daily_meets\",\n DAILY_TIPS = \"daily_tips\",\n DAILY_GAMES = \"daily_games\",\n}\n\nexport enum EnumPostContentType {\n GAME = \"game\",\n IMAGE = \"image\",\n LIST = \"list\",\n TEXTAREA = \"textarea\",\n VIDEO = \"video\",\n}\n\nexport type PostFileInput = {\n source: File;\n title?: string;\n};\n\nexport type PostContentTextarea = {\n textarea: {\n title?: string;\n data: string;\n };\n};\n\nexport type PostContentImage = {\n images: ResourceImageType[] | null;\n imagesUpload?: PostFileInput[] | null;\n};\n\nexport type PostContentVideo = {\n video: {\n source: string;\n title?: string;\n };\n};\n\nexport type PostContentList = {\n list: {\n title?: string;\n items: {\n text: string;\n }[];\n };\n};\n\nexport type PostContentGame = {\n game: BaseGameType;\n};\n\nexport type PostContentData =\n | PostContentGame\n | PostContentTextarea\n | PostContentImage\n | PostContentVideo\n | PostContentList;\n\nexport type PostContentFormData = {\n contentData?: PostContentData | null;\n contentOrder?: number | null;\n contentType?: EnumPostContentType | null;\n};\n\nexport interface PostFormData {\n active: boolean;\n caption: string;\n content: PostContentFormData[];\n cover?: ResourceImageType | null;\n coverUpload?: PostFileInput | null;\n postType: EnumPostType;\n resource?: {\n resourceId: string;\n resourceType: EnumResourceType;\n resourceRegion: string;\n } | null;\n tags?: string[] | null;\n title: string;\n}\n\nexport type CreatePostFormData = CreateFormData<PostFormData>;\n\nexport type PostContentType = Omit<PostContentFormData, \"contentData\"> & {\n contentData: Omit<PostContentData, \"imagesUpload\">;\n};\n\nexport type PostType = Omit<PostFormData, \"content\" | \"coverUpload\"> & {\n _id: string;\n content: PostContentType[];\n createdAt: Date;\n deletedAt: Date | null;\n updatedAt: Date | null;\n};\n","import { OwnerType } from \"../global\";\n\nimport { DailyClueBaseGame, DailyClueGameData } from \"./dailyClue\";\nimport { EnumGameType, GameDate } from \"./global\";\n\nexport type BaseGameMap = {\n [EnumGameType.DAILY_CLUE]: DailyClueBaseGame;\n};\n\nexport type BaseGameType = {\n [K in keyof BaseGameMap]: BaseGameMap[K] | null;\n};\n\nexport enum EnumGameStatus {\n GAME_COMPLETED = \"GAME_COMPLETED\",\n GAME_IN_PROGRESS = \"GAME_IN_PROGRESS\",\n GAME_LEFT = \"GAME_LEFT\",\n GAME_STARTED = \"GAME_STARTED\",\n}\n\nexport type GameHistory = {\n createdAt: Date;\n gameDate: GameDate;\n gameStatus: EnumGameStatus;\n gameType: EnumGameType;\n pointsEarned: number;\n};\n\ntype GameDataMap = {\n [EnumGameType.DAILY_CLUE]: DailyClueGameData;\n};\ntype GameDataType = {\n [K in keyof GameDataMap]?: GameDataMap[K] | null;\n};\n\nexport type GameType = {\n _id: string;\n active: boolean;\n createdAt: Date;\n gameData: GameDataType;\n gameHistory: GameHistory[] | null;\n gameType: EnumGameType;\n updatedAt: Date | null;\n};\n\nexport type GameDocType = {\n _id: string;\n active: boolean;\n createdAt: Date;\n deletedAt: Date | null;\n games: GameType[] | null;\n owner: OwnerType;\n points: number;\n updatedAt: Date | null;\n};\n\nexport type GameLeaderboard = {\n gameHistory: GameHistory[] | null;\n overallPoints: number;\n owner: OwnerType;\n};\n","export enum EnumGameType {\n DAILY_CLUE = \"dailyClue\",\n}\n\nexport type GameDate = {\n startDate: Date;\n endDate: Date;\n};\n","import { EnumGameType, GameDate } from \"./global\";\n\nconst OBJECT_ID_PATH_SEGMENT = \"[a-f0-9]{24}\";\nconst OBJECT_ID_PATH_SEGMENT_END = `${OBJECT_ID_PATH_SEGMENT}$`;\n\nexport const gameScreenIdentifierList = [\n {\n clue: \"Where your actions turn into a timeline.\",\n id: \"activities\",\n match: \"/profile/activities\",\n },\n {\n clue: \"Where conversations happen without speaking.\",\n id: \"chat\",\n match: \"/profile/chat\",\n },\n {\n clue: \"The place to redefine who you are.\",\n id: \"edit-profile\",\n match: \"/profile/edit-profile\",\n },\n {\n clue: \"A single moment worth showing up for.\",\n id: \"single-event\",\n match: new RegExp(`^/events/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"What’s happening around you, right now.\",\n id: \"events-near-me\",\n match: \"/events/events-near-me\",\n },\n {\n clue: \"A collection of things worth attending.\",\n id: \"events\",\n match: \"/events\",\n },\n {\n clue: \"What’s happening in a wider area — not just nearby.\",\n id: \"events-region\",\n match: /^\\/events\\/region\\/[^/]+$/,\n },\n {\n clue: \"Where fun becomes a challenge.\",\n id: \"games\",\n match: \"/games\",\n },\n {\n clue: \"Your starting point for everything.\",\n id: \"home\",\n match: \"/\",\n },\n {\n clue: \"Where the app whispers what you shouldn’t miss.\",\n id: \"notifications\",\n match: \"/notifications\",\n },\n {\n clue: \"Where you fine-tune your experience.\",\n id: \"options\",\n match: \"/options\",\n },\n {\n clue: \"An organisation or creator supporting the community.\",\n id: \"single-partner\",\n match: new RegExp(`^/partners/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Organisations and creators supporting the community.\",\n id: \"partners\",\n match: \"/partners\",\n },\n {\n clue: \"A single published post in full view.\",\n id: \"single-visitor-post\",\n match: new RegExp(`^/visitors/post/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Your identity, on display.\",\n id: \"profile\",\n match: \"/profile\",\n },\n {\n clue: \"One stallholder offering something valuable.\",\n id: \"single-vendor\",\n match: new RegExp(`^/vendors/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Where every stallholder waits under the right category.\",\n id: \"vendors\",\n match: \"/vendors\",\n },\n {\n clue: \"Where you browse articles and posts from around the platform.\",\n id: \"visitors\",\n match: \"/visitors\",\n },\n] as const;\n\nexport type GamePlacement = (typeof gameScreenIdentifierList)[number][\"id\"];\nexport type GamePlacementClue =\n (typeof gameScreenIdentifierList)[number][\"clue\"];\n\nexport const gameTypeToDisplayName: Record<EnumGameType, string> = {\n [EnumGameType.DAILY_CLUE]: \"Daily Clue\",\n};\n\nexport type DailyClueBaseGame = {\n gameDate: GameDate;\n gameSolution: string;\n gameType: EnumGameType;\n};\n\nexport type DailyClueGameData = {\n gameFields: DailyClueBaseGame;\n lastFoundDate: Date | null;\n points: number;\n letterInfo: {\n collected: string[] | null; // The letters the user has found, e.g. [\"C\", \"L\", \"U\"]\n solutionShuffled: string[]; // The letters of the solution, but shuffled, e.g. [\"L\", \"C\", \"U\"]\n todaysClue: GamePlacementClue | null; // The clue for user to find the letter, e.g. related to {todaysPlacement}\n todaysLetter: string | null; // The letter the user has to find today, e.g. \"C\"\n todaysPlacement: GamePlacement | null; // The screen where the user has to find the clue, e.g. \"HomeScreen\"\n };\n // User has found the clue 3 days in a row, this is incrementing if the user finds the clue and decrements if user misses a day\n streak: number;\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACOO,IAAK,uBAAL,kBAAKA,0BAAL;AACL,EAAAA,sBAAA,cAAW;AACX,EAAAA,sBAAA,oBAAiB;AAFP,SAAAA;AAAA,GAAA;;;ACcL,IAAM,oBAAoB;;;ACjB1B,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,iBAAc;AACd,EAAAA,cAAA,gBAAa;AACb,EAAAA,cAAA,mBAAgB;AAChB,EAAAA,cAAA,kBAAe;AAJL,SAAAA;AAAA,GAAA;AAOL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,YAAS;AACT,EAAAA,cAAA,YAAS;AACT,EAAAA,cAAA,aAAU;AAHA,SAAAA;AAAA,GAAA;AAML,IAAK,aAAL,kBAAKC,gBAAL;AACL,EAAAA,YAAA,eAAY;AACZ,EAAAA,YAAA,UAAO;AAFG,SAAAA;AAAA,GAAA;AAKL,IAAK,cAAL,kBAAKC,iBAAL;AACL,EAAAA,aAAA,WAAQ;AACR,EAAAA,aAAA,UAAO;AAFG,SAAAA;AAAA,GAAA;;;ACdL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,cAAW;AACX,EAAAA,cAAA,WAAQ;AACR,EAAAA,cAAA,gBAAa;AACb,EAAAA,cAAA,aAAU;AACV,EAAAA,cAAA,UAAO;AALG,SAAAA;AAAA,GAAA;;;ACHL,IAAK,eAAL,kBAAKC,kBAAL;AACL,EAAAA,cAAA,iBAAc;AACd,EAAAA,cAAA,gBAAa;AACb,EAAAA,cAAA,iBAAc;AAHJ,SAAAA;AAA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AAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO,IAAI,OAAO,cAAc,0BAA0B,EAAE;AAAA,EAC9D;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO,IAAI,OAAO,mBAAmB,0BAA0B,EAAE;AAAA,EACnE;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO,IAAI,OAAO,aAAa,0BAA0B,EAAE;AAAA,EAC7D;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AACF;AAMO,IAAM,wBAAsD;AAAA,EACjE,6BAAwB,GAAG;AAC7B;","names":["EnumVerificationType","EnumAdShowOn","EnumAdStatus","EnumAdType","EnumAdStyle","EnumActivity","EnumPostType","EnumPostContentType","EnumGameStatus","EnumGameType"]}
@@ -3,8 +3,8 @@ export { e as ContactUsFormData, f as CreateContactUsFormData, C as CreateLoginF
3
3
  export { c as ChatMessageInput, d as ChatMessageReaction, e as ChatMessageReplyPreview, f as ChatMessageSeen, g as ChatMessageType, C as ChatType, h as CreateBulkNotificationInput, E as EnumActivity, N as NotificationCount, i as NotificationDataType, a as NotificationType, P as ParticipantType, R as ReportChatUser, j as ResourceActivityEntry, k as ResourceActivityInputType, b as ResourceActivityType } from '../resourceActivities-B8dshdq5.mjs';
4
4
  import { c as EventListItemType } from '../global-ClbRuePq.mjs';
5
5
  export { A as AssociateType, r as BaseResourceType, B as BaseResourceTypeFormData, C as Category, n as CreateEventFormData, p as CreateEventInfoFormData, s as CreateFormData, t as CreateUnregisteredVendorFormData, j as CreateVendorFormData, l as CreateVendorInfoFormData, D as DateTimeType, u as DateTimeWithPriceType, v as DeviceInfo, m as EventFormData, o as EventInfoFormData, d as EventInfoType, w as EventStatusType, E as EventType, a as FormDateField, F as FormField, G as GeocodeLocation, I as ImageObjectType, x as LocationGeoType, L as LocationType, N as Nullable, O as OptionItem, y as OwnerType, P as PROMO_CODE_PREFIX, z as PaymentInfoType, H as PosterUsageType, J as PromoCodeType, R as RefundPolicy, K as Region, M as RelationDate, e as RelationType, b as Requirement, f as ResourceConnectionsType, Q as ResourceContactDetailsType, T as ResourceDetails, W as ResourceImageType, X as SocialMediaType, S as StallType, Y as Subcategory, Z as SubcategoryItems, _ as TermsAgreement, q as UnregisteredVendorFormData, $ as UnregisteredVendorInvitationType, U as UnregisteredVendorType, h as UserLicenceType, a0 as VendorAttributes, a1 as VendorCalendarData, i as VendorFormData, k as VendorInfoFormData, g as VendorInfoType, a2 as VendorProductList, V as VendorType } from '../global-ClbRuePq.mjs';
6
- export { i as AdFormData, r as AdResource, A as AdType, n as AppSettingsFormData, d as AppSettingsType, j as CreateAdFormData, o as CreateAppSettingsFormData, k as CreatePartnerFormData, m as CreatePostFormData, q as CreateSchoolFormData, C as CreateUserFormData, s as EnumAdShowOn, E as EnumAdStatus, t as EnumAdStyle, u as EnumAdType, v as EnumPostContentType, c as EnumPostType, M as MarketingMaterialRequestInputType, h as PartnerFormData, P as PartnerType, w as PostContentData, x as PostContentFormData, y as PostContentGame, z as PostContentImage, B as PostContentList, D as PostContentTextarea, F as PostContentType, G as PostContentVideo, H as PostFileInput, l as PostFormData, b as PostType, I as PosterInputType, R as ResourceByUser, p as SchoolFormData, J as SchoolRegisteredUserType, e as SchoolReturnType, f as SchoolType, K as StripeSubscription, L as SubscriptionPlanData, S as SubscriptionPlansResponse, N as SubscriptionPricingData, a as SubscriptionStatusData, O as UserActivity, Q as UserActivityEvent, g as UserFormData, U as UserType } from '../post-CY53UsA7.mjs';
7
- export { B as BaseGame, D as DailyClueGameData, E as EnumGameStatus, b as EnumGameType, c as GameDate, G as GameDocType, d as GameHistory, a as GameLeaderboard, e as GamePlacement, f as GamePlacementClue, g as GameType, h as gameScreenIdentifierList, i as gameTypeToDisplayName } from '../game-BPtE3yaQ.mjs';
6
+ export { j as AdFormData, s as AdResource, A as AdType, o as AppSettingsFormData, d as AppSettingsType, B as BaseGameMap, t as BaseGameType, k as CreateAdFormData, p as CreateAppSettingsFormData, l as CreatePartnerFormData, n as CreatePostFormData, r as CreateSchoolFormData, C as CreateUserFormData, u as EnumAdShowOn, E as EnumAdStatus, v as EnumAdStyle, w as EnumAdType, x as EnumGameStatus, y as EnumPostContentType, c as EnumPostType, G as GameDocType, z as GameHistory, e as GameLeaderboard, D as GameType, M as MarketingMaterialRequestInputType, i as PartnerFormData, P as PartnerType, F as PostContentData, H as PostContentFormData, I as PostContentGame, J as PostContentImage, K as PostContentList, L as PostContentTextarea, N as PostContentType, O as PostContentVideo, Q as PostFileInput, m as PostFormData, b as PostType, T as PosterInputType, R as ResourceByUser, q as SchoolFormData, V as SchoolRegisteredUserType, f as SchoolReturnType, g as SchoolType, W as StripeSubscription, X as SubscriptionPlanData, S as SubscriptionPlansResponse, Y as SubscriptionPricingData, a as SubscriptionStatusData, Z as UserActivity, _ as UserActivityEvent, h as UserFormData, U as UserType } from '../post-C3L-bejc.mjs';
7
+ export { D as DailyClueBaseGame, a as DailyClueGameData, E as EnumGameType, G as GameDate, b as GamePlacement, c as GamePlacementClue, g as gameScreenIdentifierList, d as gameTypeToDisplayName } from '../dailyClue-CvOPk6am.mjs';
8
8
  import 'react-hook-form';
9
9
  import '../images/index.mjs';
10
10
 
@@ -3,8 +3,8 @@ export { e as ContactUsFormData, f as CreateContactUsFormData, C as CreateLoginF
3
3
  export { c as ChatMessageInput, d as ChatMessageReaction, e as ChatMessageReplyPreview, f as ChatMessageSeen, g as ChatMessageType, C as ChatType, h as CreateBulkNotificationInput, E as EnumActivity, N as NotificationCount, i as NotificationDataType, a as NotificationType, P as ParticipantType, R as ReportChatUser, j as ResourceActivityEntry, k as ResourceActivityInputType, b as ResourceActivityType } from '../resourceActivities-BXsZrzFC.js';
4
4
  import { c as EventListItemType } from '../global-CDqmjLH1.js';
5
5
  export { A as AssociateType, r as BaseResourceType, B as BaseResourceTypeFormData, C as Category, n as CreateEventFormData, p as CreateEventInfoFormData, s as CreateFormData, t as CreateUnregisteredVendorFormData, j as CreateVendorFormData, l as CreateVendorInfoFormData, D as DateTimeType, u as DateTimeWithPriceType, v as DeviceInfo, m as EventFormData, o as EventInfoFormData, d as EventInfoType, w as EventStatusType, E as EventType, a as FormDateField, F as FormField, G as GeocodeLocation, I as ImageObjectType, x as LocationGeoType, L as LocationType, N as Nullable, O as OptionItem, y as OwnerType, P as PROMO_CODE_PREFIX, z as PaymentInfoType, H as PosterUsageType, J as PromoCodeType, R as RefundPolicy, K as Region, M as RelationDate, e as RelationType, b as Requirement, f as ResourceConnectionsType, Q as ResourceContactDetailsType, T as ResourceDetails, W as ResourceImageType, X as SocialMediaType, S as StallType, Y as Subcategory, Z as SubcategoryItems, _ as TermsAgreement, q as UnregisteredVendorFormData, $ as UnregisteredVendorInvitationType, U as UnregisteredVendorType, h as UserLicenceType, a0 as VendorAttributes, a1 as VendorCalendarData, i as VendorFormData, k as VendorInfoFormData, g as VendorInfoType, a2 as VendorProductList, V as VendorType } from '../global-CDqmjLH1.js';
6
- export { i as AdFormData, r as AdResource, A as AdType, n as AppSettingsFormData, d as AppSettingsType, j as CreateAdFormData, o as CreateAppSettingsFormData, k as CreatePartnerFormData, m as CreatePostFormData, q as CreateSchoolFormData, C as CreateUserFormData, s as EnumAdShowOn, E as EnumAdStatus, t as EnumAdStyle, u as EnumAdType, v as EnumPostContentType, c as EnumPostType, M as MarketingMaterialRequestInputType, h as PartnerFormData, P as PartnerType, w as PostContentData, x as PostContentFormData, y as PostContentGame, z as PostContentImage, B as PostContentList, D as PostContentTextarea, F as PostContentType, G as PostContentVideo, H as PostFileInput, l as PostFormData, b as PostType, I as PosterInputType, R as ResourceByUser, p as SchoolFormData, J as SchoolRegisteredUserType, e as SchoolReturnType, f as SchoolType, K as StripeSubscription, L as SubscriptionPlanData, S as SubscriptionPlansResponse, N as SubscriptionPricingData, a as SubscriptionStatusData, O as UserActivity, Q as UserActivityEvent, g as UserFormData, U as UserType } from '../post-Lc5PrxY6.js';
7
- export { B as BaseGame, D as DailyClueGameData, E as EnumGameStatus, b as EnumGameType, c as GameDate, G as GameDocType, d as GameHistory, a as GameLeaderboard, e as GamePlacement, f as GamePlacementClue, g as GameType, h as gameScreenIdentifierList, i as gameTypeToDisplayName } from '../game-1CSiEjlf.js';
6
+ export { j as AdFormData, s as AdResource, A as AdType, o as AppSettingsFormData, d as AppSettingsType, B as BaseGameMap, t as BaseGameType, k as CreateAdFormData, p as CreateAppSettingsFormData, l as CreatePartnerFormData, n as CreatePostFormData, r as CreateSchoolFormData, C as CreateUserFormData, u as EnumAdShowOn, E as EnumAdStatus, v as EnumAdStyle, w as EnumAdType, x as EnumGameStatus, y as EnumPostContentType, c as EnumPostType, G as GameDocType, z as GameHistory, e as GameLeaderboard, D as GameType, M as MarketingMaterialRequestInputType, i as PartnerFormData, P as PartnerType, F as PostContentData, H as PostContentFormData, I as PostContentGame, J as PostContentImage, K as PostContentList, L as PostContentTextarea, N as PostContentType, O as PostContentVideo, Q as PostFileInput, m as PostFormData, b as PostType, T as PosterInputType, R as ResourceByUser, q as SchoolFormData, V as SchoolRegisteredUserType, f as SchoolReturnType, g as SchoolType, W as StripeSubscription, X as SubscriptionPlanData, S as SubscriptionPlansResponse, Y as SubscriptionPricingData, a as SubscriptionStatusData, Z as UserActivity, _ as UserActivityEvent, h as UserFormData, U as UserType } from '../post-B941IgWP.js';
7
+ export { D as DailyClueBaseGame, a as DailyClueGameData, E as EnumGameType, G as GameDate, b as GamePlacement, c as GamePlacementClue, g as gameScreenIdentifierList, d as gameTypeToDisplayName } from '../dailyClue-CvOPk6am.js';
8
8
  import 'react-hook-form';
9
9
  import '../images/index.js';
10
10
 
@@ -4,17 +4,17 @@ import {
4
4
  EnumAdStatus,
5
5
  EnumAdStyle,
6
6
  EnumAdType,
7
+ EnumGameStatus,
7
8
  EnumPostContentType,
8
9
  EnumPostType,
9
10
  EnumVerificationType,
10
11
  PROMO_CODE_PREFIX
11
- } from "../chunk-FICQ3PR5.mjs";
12
+ } from "../chunk-ZOPHRV6M.mjs";
12
13
  import {
13
- EnumGameStatus,
14
14
  EnumGameType,
15
15
  gameScreenIdentifierList,
16
16
  gameTypeToDisplayName
17
- } from "../chunk-LOABFNIJ.mjs";
17
+ } from "../chunk-5LODYRBR.mjs";
18
18
  export {
19
19
  EnumActivity,
20
20
  EnumAdShowOn,
@@ -32,6 +32,8 @@ var utils_exports = {};
32
32
  __export(utils_exports, {
33
33
  ANDROID_URL: () => ANDROID_URL,
34
34
  IOS_URL: () => IOS_URL,
35
+ SCHOOL_MAX_STUDENT_COUNT: () => SCHOOL_MAX_STUDENT_COUNT,
36
+ SCHOOL_MIN_STUDENT_COUNT: () => SCHOOL_MIN_STUDENT_COUNT,
35
37
  availableRegionOptions: () => availableRegionOptions,
36
38
  availableRegionTypes: () => availableRegionTypes,
37
39
  capitalizeFirstLetter: () => capitalizeFirstLetter,
@@ -58,7 +60,7 @@ __export(utils_exports, {
58
60
  });
59
61
  module.exports = __toCommonJS(utils_exports);
60
62
 
61
- // src/types/game.ts
63
+ // src/types/game/dailyClue.ts
62
64
  var OBJECT_ID_PATH_SEGMENT = "[a-f0-9]{24}";
63
65
  var OBJECT_ID_PATH_SEGMENT_END = `${OBJECT_ID_PATH_SEGMENT}$`;
64
66
  var gameScreenIdentifierList = [
@@ -153,6 +155,9 @@ var gameScreenIdentifierList = [
153
155
  match: "/visitors"
154
156
  }
155
157
  ];
158
+ var gameTypeToDisplayName = {
159
+ ["dailyClue" /* DAILY_CLUE */]: "Daily Clue"
160
+ };
156
161
 
157
162
  // src/utils/date.ts
158
163
  var import_dayjs = __toESM(require("dayjs"));
@@ -262,7 +267,7 @@ function getDayIndex(start, today) {
262
267
  }
263
268
  function computeDailyClueState(dailyClue) {
264
269
  const { startDate, endDate } = dailyClue.gameFields.gameDate;
265
- const { shuffled, collected } = dailyClue.letterInfo;
270
+ const { solutionShuffled, collected } = dailyClue.letterInfo;
266
271
  const today = nzStartOfDay();
267
272
  const start = nzStartOfDay(startDate);
268
273
  const end = nzStartOfDay(endDate);
@@ -281,10 +286,10 @@ function computeDailyClueState(dailyClue) {
281
286
  todaysPlacement: null
282
287
  };
283
288
  }
284
- if (index < 0 || index >= shuffled.length || index >= shuffledPlacements.length) {
289
+ if (index < 0 || index >= solutionShuffled.length || index >= shuffledPlacements.length) {
285
290
  return null;
286
291
  }
287
- const letterToday = shuffled[index];
292
+ const letterToday = solutionShuffled[index];
288
293
  const placement = shuffledPlacements[index];
289
294
  if (!letterToday || !placement) return null;
290
295
  const alreadyCollectedToday = (collected ?? []).includes(letterToday);
@@ -418,10 +423,16 @@ var cluemartSocialMedia = [
418
423
  ];
419
424
  var IOS_URL = "https://apps.apple.com/nz/app/cluemart/id6747251008";
420
425
  var ANDROID_URL = "https://play.google.com/store/apps/details?id=com.timardex.cluemart";
426
+
427
+ // src/utils/school.ts
428
+ var SCHOOL_MIN_STUDENT_COUNT = 300;
429
+ var SCHOOL_MAX_STUDENT_COUNT = 0;
421
430
  // Annotate the CommonJS export names for ESM import in node:
422
431
  0 && (module.exports = {
423
432
  ANDROID_URL,
424
433
  IOS_URL,
434
+ SCHOOL_MAX_STUDENT_COUNT,
435
+ SCHOOL_MIN_STUDENT_COUNT,
425
436
  availableRegionOptions,
426
437
  availableRegionTypes,
427
438
  capitalizeFirstLetter,
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/utils/index.ts","../../src/types/game.ts","../../src/utils/date.ts","../../src/utils/dailyClueGame.ts","../../src/enums/index.ts","../../src/utils/utils.ts"],"sourcesContent":["export { computeDailyClueState, seededShuffle } from \"./dailyClueGame\";\nexport {\n toNZTime,\n nzStartOfDay,\n formatDate,\n getCurrentAndFutureDates,\n isFutureDatesBeforeThreshold,\n formatTimestamp,\n isIsoDateString,\n sortDatesChronologically,\n timeFormat,\n dateFormat,\n} from \"./date\";\n\nexport {\n removeTypename,\n truncateText,\n mapArrayToOptions,\n capitalizeFirstLetter,\n statusOptions,\n availableRegionTypes,\n availableRegionOptions,\n paymentMethodOptions,\n normalizeUrl,\n licenseNiceNames,\n cluemartSocialMedia,\n IOS_URL,\n ANDROID_URL,\n} from \"./utils\";\n","import { OwnerType } from \"./global\";\n\nconst OBJECT_ID_PATH_SEGMENT = \"[a-f0-9]{24}\";\nconst OBJECT_ID_PATH_SEGMENT_END = `${OBJECT_ID_PATH_SEGMENT}$`;\n\nexport const gameScreenIdentifierList = [\n {\n clue: \"Where your actions turn into a timeline.\",\n id: \"activities\",\n match: \"/profile/activities\",\n },\n {\n clue: \"Where conversations happen without speaking.\",\n id: \"chat\",\n match: \"/profile/chat\",\n },\n {\n clue: \"The place to redefine who you are.\",\n id: \"edit-profile\",\n match: \"/profile/edit-profile\",\n },\n {\n clue: \"A single moment worth showing up for.\",\n id: \"single-event\",\n match: new RegExp(`^/events/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"What’s happening around you, right now.\",\n id: \"events-near-me\",\n match: \"/events/events-near-me\",\n },\n {\n clue: \"A collection of things worth attending.\",\n id: \"events\",\n match: \"/events\",\n },\n {\n clue: \"What’s happening in a wider area — not just nearby.\",\n id: \"events-region\",\n match: /^\\/events\\/region\\/[^/]+$/,\n },\n {\n clue: \"Where fun becomes a challenge.\",\n id: \"games\",\n match: \"/games\",\n },\n {\n clue: \"Your starting point for everything.\",\n id: \"home\",\n match: \"/\",\n },\n {\n clue: \"Where the app whispers what you shouldn’t miss.\",\n id: \"notifications\",\n match: \"/notifications\",\n },\n {\n clue: \"Where you fine-tune your experience.\",\n id: \"options\",\n match: \"/options\",\n },\n {\n clue: \"An organisation or creator supporting the community.\",\n id: \"single-partner\",\n match: new RegExp(`^/partners/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Organisations and creators supporting the community.\",\n id: \"partners\",\n match: \"/partners\",\n },\n {\n clue: \"A single published post in full view.\",\n id: \"single-visitor-post\",\n match: new RegExp(`^/visitors/post/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Your identity, on display.\",\n id: \"profile\",\n match: \"/profile\",\n },\n {\n clue: \"One stallholder offering something valuable.\",\n id: \"single-vendor\",\n match: new RegExp(`^/vendors/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Where every stallholder waits under the right category.\",\n id: \"vendors\",\n match: \"/vendors\",\n },\n {\n clue: \"Where you browse articles and posts from around the platform.\",\n id: \"visitors\",\n match: \"/visitors\",\n },\n] as const;\n\nexport type GamePlacement = (typeof gameScreenIdentifierList)[number][\"id\"];\nexport type GamePlacementClue =\n (typeof gameScreenIdentifierList)[number][\"clue\"];\n\nexport enum EnumGameType {\n DAILY_CLUE = \"dailyClue\",\n}\n\nexport const gameTypeToDisplayName: Record<EnumGameType, string> = {\n [EnumGameType.DAILY_CLUE]: \"Daily Clue\",\n};\n\nexport type GameDate = {\n startDate: Date;\n endDate: Date;\n};\n\nexport type BaseGame = {\n gameDate: GameDate;\n gameSolution: string;\n gameType: EnumGameType;\n};\n\nexport type DailyClueGameData = {\n gameFields: BaseGame;\n lastFoundDate: Date | null;\n points: number;\n letterInfo: {\n collected: string[] | null; // The letters the user has found, e.g. [\"C\", \"L\", \"U\"]\n shuffled: string[]; // The letters of the solution, but shuffled, e.g. [\"L\", \"C\", \"U\"]\n todaysLetter: string | null; // The letter the user has to find today, e.g. \"C\"\n todaysClue: GamePlacementClue | null; // The clue for user to find the letter, e.g. related to {todaysPlacement}\n todaysPlacement: GamePlacement | null; // The screen where the user has to find the clue, e.g. \"HomeScreen\"\n };\n // User has found the clue 3 days in a row, this is incrementing if the user finds the clue and decrements if user misses a day\n streak: number;\n};\n\nexport enum EnumGameStatus {\n GAME_COMPLETED = \"GAME_COMPLETED\",\n GAME_IN_PROGRESS = \"GAME_IN_PROGRESS\",\n GAME_LEFT = \"GAME_LEFT\",\n GAME_STARTED = \"GAME_STARTED\",\n}\n\nexport type GameHistory = {\n createdAt: Date;\n gameDate: GameDate;\n gameStatus: EnumGameStatus;\n gameType: EnumGameType;\n pointsEarned: number;\n};\n\ntype GameDataMap = {\n [EnumGameType.DAILY_CLUE]: DailyClueGameData;\n};\ntype GameDataType = {\n [K in keyof GameDataMap]?: GameDataMap[K] | null;\n};\n\nexport type GameType = {\n _id: string;\n active: boolean;\n createdAt: Date;\n gameData: GameDataType;\n gameHistory: GameHistory[] | null;\n gameType: EnumGameType;\n updatedAt: Date | null;\n};\n\nexport type GameDocType = {\n _id: string;\n active: boolean;\n createdAt: Date;\n deletedAt: Date | null;\n games: GameType[] | null;\n owner: OwnerType;\n points: number;\n updatedAt: Date | null;\n};\n\nexport type GameLeaderboard = {\n gameHistory: GameHistory[] | null;\n overallPoints: number;\n owner: OwnerType;\n};\n","import dayjs from \"dayjs\";\nimport customParseFormat from \"dayjs/plugin/customParseFormat.js\";\nimport isSameOrAfter from \"dayjs/plugin/isSameOrAfter.js\";\nimport timezone from \"dayjs/plugin/timezone.js\";\nimport utc from \"dayjs/plugin/utc.js\";\n\nexport const dateFormat = \"DD-MM-YYYY\";\nexport const timeFormat = \"HH:mm\";\n\n// Enable custom format parsing\ndayjs.extend(customParseFormat);\ndayjs.extend(utc);\ndayjs.extend(timezone);\ndayjs.extend(isSameOrAfter);\n\nconst NZ_TZ = \"Pacific/Auckland\";\n\nexport function toNZTime(date?: Date | string) {\n return date ? dayjs(date).tz(NZ_TZ) : dayjs().tz(NZ_TZ);\n}\n\n/** Start of the calendar day in Pacific/Auckland (daily games, streaks, etc.). */\nexport function nzStartOfDay(\n input?: Date | string | number | null,\n): dayjs.Dayjs {\n if (input == null) {\n return dayjs().tz(NZ_TZ).startOf(\"day\");\n }\n return dayjs.tz(input, NZ_TZ).startOf(\"day\");\n}\n\ntype DateFormat = \"date\" | \"time\" | \"datetime\";\n\n/**\n * Format a date string to a more readable format.\n * @param dateStr - the date string\n * @param timeStr - optional time string\n * @param display - 'date' | 'time' | 'datetime'\n * @returns formatted string based on display option\n */\nexport const formatDate = (\n dateStr: string,\n display: DateFormat = \"datetime\",\n timeStr?: string,\n) => {\n // Combine date and time into a single string if time is provided\n const dateTimeStr = timeStr ? `${dateStr} ${timeStr}` : dateStr;\n\n // Parse with formats\n const dateTime = timeStr\n ? dayjs(dateTimeStr, `${dateFormat} ${timeFormat}`)\n : dayjs(dateStr, dateFormat);\n\n // Format parts\n const formattedDate = dateTime.format(\"dddd, D MMMM, YYYY\");\n const formattedTime = dateTime.format(\"h:mm a\");\n\n // Return based on display option\n switch (display) {\n case \"date\":\n return formattedDate;\n case \"time\":\n return formattedTime;\n case \"datetime\":\n return `${formattedDate} at ${formattedTime}`;\n default:\n return formattedDate;\n }\n};\n\nexport const getCurrentAndFutureDates = <\n T extends { startDate: string; startTime: string },\n>(\n dates: T[],\n): T[] => {\n const now = dayjs(); // current date and time\n\n return dates.filter((dateObj) => {\n const dateTime = dayjs(\n `${dateObj.startDate} ${dateObj.startTime}`,\n `${dateFormat} ${timeFormat}`,\n );\n return dateTime.isSameOrAfter(now);\n });\n};\n\nexport const isFutureDatesBeforeThreshold = (\n date: {\n startDate: string;\n startTime: string;\n },\n minHoursFromNow: number,\n): boolean => {\n const threshold = minHoursFromNow\n ? dayjs().add(minHoursFromNow, \"hour\")\n : dayjs().startOf(\"day\");\n\n const dateTime = dayjs(\n `${date.startDate} ${date.startTime}`,\n `${dateFormat} ${timeFormat}`,\n );\n\n return dateTime.isSameOrAfter(threshold);\n};\n\nexport const formatTimestamp = (timestamp: string) => {\n const formattedDate = toNZTime(timestamp).format(dateFormat);\n\n return formatDate(formattedDate, \"date\");\n};\n\nexport const isIsoDateString = (value: unknown): value is string => {\n return typeof value === \"string\" && !isNaN(Date.parse(value));\n};\n\n/**\n * Sort an array of date strings by their proximity to the current date.\n * @param dates - The array of date strings to sort.\n * @returns - The sorted array of date strings.\n */\nexport function sortDatesChronologically<\n T extends { startDate: string; startTime: string },\n>(dates: T[]): T[] {\n if (!dates || !dates.length) {\n return [];\n }\n\n return [...dates].sort((a, b) => {\n const dateTimeFormat = `${dateFormat} ${timeFormat}`;\n const dateA = dayjs(`${a.startDate} ${a.startTime}`, dateTimeFormat);\n const dateB = dayjs(`${b.startDate} ${b.startTime}`, dateTimeFormat);\n return dateA.valueOf() - dateB.valueOf(); // chronological order\n });\n}\n","import type { Dayjs } from \"dayjs\";\n\nimport {\n DailyClueGameData,\n EnumGameStatus,\n GameHistory,\n GamePlacement,\n GamePlacementClue,\n gameScreenIdentifierList,\n} from \"../types/game\";\n\nimport { nzStartOfDay } from \"./date\";\n\nfunction createSeededRng(seed: number) {\n let t = seed >>> 0;\n\n return function random() {\n t += 0x6d2b79f5;\n let x = t;\n\n x = Math.imul(x ^ (x >>> 15), x | 1);\n x ^= x + Math.imul(x ^ (x >>> 7), x | 61);\n\n return ((x ^ (x >>> 14)) >>> 0) / 4294967296;\n };\n}\n\nfunction hashStringToNumber(seed: string): number {\n let hash = 2166136261;\n\n for (let i = 0; i < seed.length; i++) {\n hash ^= seed.codePointAt(i) ?? 0;\n hash = Math.imul(hash, 16777619);\n }\n\n return hash >>> 0;\n}\n\n/** Seeded shuffle so all players see the same letter order / placements for a game. */\nexport function seededShuffle<T>(array: readonly T[], seed: string): T[] {\n const rng = createSeededRng(hashStringToNumber(seed));\n const result = [...array];\n\n for (let i = result.length - 1; i > 0; i--) {\n const j = Math.floor(rng() * (i + 1));\n [result[i], result[j]] = [result[j], result[i]];\n }\n\n return result;\n}\n\nfunction getDayIndex(start: Dayjs, today: Dayjs): number {\n return today.diff(start, \"day\");\n}\n\nexport function computeDailyClueState(dailyClue: DailyClueGameData): {\n todaysClue: GamePlacementClue | null;\n\n todaysLetter: string | null;\n\n todaysPlacement: GamePlacement | null;\n} | null {\n const { startDate, endDate } = dailyClue.gameFields.gameDate;\n const { shuffled, collected } = dailyClue.letterInfo;\n\n const today = nzStartOfDay();\n const start = nzStartOfDay(startDate);\n const end = nzStartOfDay(endDate);\n\n // Before game starts\n if (today.isBefore(start)) {\n return null;\n }\n\n const shuffledPlacements = seededShuffle(\n gameScreenIdentifierList,\n start.toISOString(),\n );\n\n const index = getDayIndex(start, today);\n\n // After game ends\n if (today.isAfter(end)) {\n return {\n todaysClue: null,\n todaysLetter: null,\n todaysPlacement: null,\n };\n }\n\n // Safety: index must exist in BOTH arrays\n if (\n index < 0 ||\n index >= shuffled.length ||\n index >= shuffledPlacements.length\n ) {\n return null;\n }\n\n const letterToday = shuffled[index];\n const placement = shuffledPlacements[index];\n\n if (!letterToday || !placement) return null;\n\n const alreadyCollectedToday = (collected ?? []).includes(letterToday);\n\n // Already completed today\n if (alreadyCollectedToday) {\n return {\n todaysClue: null,\n todaysLetter: null,\n todaysPlacement: null,\n };\n }\n\n // Active state\n return {\n todaysClue: placement.clue,\n todaysLetter: letterToday,\n todaysPlacement: placement.id,\n };\n}\n","export enum EnumInviteStatus {\n ACCEPTED = \"Accepted\",\n COMPLETED = \"Completed\",\n EXPIRED = \"Expired\",\n NO_STATUS = \"No_Status\",\n PENDING = \"Pending\",\n REJECTED = \"Rejected\",\n UNAVAILABLE = \"Unavailable\",\n}\n\nexport enum EnumChatReportReason {\n INAPPROPRIATE_CONTENT = \"Inappropriate_Content\",\n HARASSMENT_OR_BULLYING = \"Harassment_or_Bullying\",\n HATE_SPEECH = \"Hate_Speech\",\n SPAM_OR_SCAM = \"Spam_or_Scam\",\n VIOLENCE_OR_DANGEROUS_BEHAVIOR = \"Violence_or_Dangerous_Behavior\",\n OTHER = \"Other\",\n}\n\nexport enum EnumChatType {\n GROUP = \"group\",\n PRIVATE = \"private\",\n RELATION = \"relation\",\n}\n\nexport enum EnumPaymentMethod {\n CASH = \"cash\",\n EFTPOS = \"eftpos\",\n BANK_TRANSFER = \"bank_transfer\",\n PAYPAL = \"paypal\",\n STRIPE = \"stripe\",\n}\n\nexport enum EnumFoodFlavor {\n SALTY = \"Salty\",\n SAVOURY = \"Savoury\",\n SPICY = \"Spicy\",\n SWEET = \"Sweet\",\n OTHER = \"Not_Applicable\",\n}\n\nexport enum EnumFoodType {\n ADDITIVE_FREE = \"Additive_Free\",\n AIR_FRIED = \"Air_Fried\",\n ALLERGEN_FRIENDLY = \"Allergen_Friendly\",\n ATHLETE_FRIENDLY = \"Athlete_Friendly\",\n BAKED = \"Baked\",\n DAIRY_FREE = \"Dairy_Free\",\n DIABETIC_FRIENDLY = \"Diabetic_Friendly\",\n EGG_FREE = \"Egg_Free\",\n FRESH = \"Fresh\",\n GLUTEN_FREE = \"Gluten_Free\",\n GRILLED = \"Grilled\",\n HALAL = \"Halal\",\n HEART_HEALTHY = \"Heart_Healthy\",\n HIGH_FIBER = \"High_Fiber\",\n HIGH_PROTEIN = \"High_Protein\",\n KETO = \"Keto\",\n KOSHER = \"Kosher\",\n LACTOSE_FREE = \"Lactose_Free\",\n LOW_CALORIE = \"Low_Calorie\",\n LOW_CARB = \"Low_Carb\",\n LOW_FAT = \"Low_Fat\",\n LOW_SODIUM = \"Low_Sodium\",\n NO_ADDED_SUGAR = \"No_Added_Sugar\",\n NO_PRESERVATIVES = \"No_Preservatives\",\n NON_GMO = \"Non_GMO\",\n NUT_FREE = \"Nut_Free\",\n ORGANIC = \"Organic\",\n PALEO = \"Paleo\",\n PLANT_BASED = \"Plant_Based\",\n RAW = \"Raw\",\n SMOKED = \"Smoked\",\n SOY_FREE = \"Soy_Free\",\n SUGAR_FREE = \"Sugar_Free\",\n VEGAN = \"Vegan\",\n VEGETARIAN = \"Vegetarian\",\n}\n\nexport enum EnumResourceType {\n EVENT = \"event\",\n VENDOR = \"vendor\",\n PARTNER = \"partner\",\n}\n\nexport enum EnumEventType {\n MARKET = \"Market\",\n EXPO = \"Expo\",\n FAIR = \"Fair\",\n FESTIVAL = \"Festival\",\n}\n\nexport enum EnumVendorType {\n STALLHOLDER = \"Stallholder\",\n SHOP = \"Shop\",\n}\n\nexport enum EnumPartnerType {\n CHARITY_PARTNER = \"Charity_Partner\",\n MEDIA_PARTNER = \"Media_Partner\",\n SUPPORTING_PARTNER = \"Supporting_Partner\",\n}\n\nexport enum EnumOSPlatform {\n ANDROID = \"android\",\n IOS = \"ios\",\n WEB = \"web\",\n}\n\nexport enum EnumRelationResource {\n EVENT_INVITE_VENDOR = \"event_invite_vendor\",\n VENDOR_APPLICATION_TO_EVENT = \"vendor_application_to_event\",\n}\n\nexport enum EnumNotificationResourceType {\n ADDED_AS_ASSOCIATE_EVENT = \"added_as_associate_event\",\n ADDED_AS_ASSOCIATE_PARTNER = \"added_as_associate_partner\",\n ADDED_AS_ASSOCIATE_VENDOR = \"added_as_associate_vendor\",\n APPROVED_EVENT = \"approved_event\",\n APPROVED_PARTNER = \"approved_partner\",\n APPROVED_VENDOR = \"approved_vendor\",\n CREATED_EVENT = \"created_event\",\n CREATED_PARTNER = \"created_partner\",\n CREATED_VENDOR = \"created_vendor\",\n DAILY_CLUE_GAME = \"daily_clue_game\",\n DEACTIVATED_EVENT = \"deactivated_event\",\n DEACTIVATED_PARTNER = \"deactivated_partner\",\n DEACTIVATED_VENDOR = \"deactivated_vendor\",\n DECLINED_EVENT = \"declined_event\",\n DECLINED_PARTNER = \"declined_partner\",\n DECLINED_VENDOR = \"declined_vendor\",\n DOWNGRADED_EVENT = \"downgraded_event\",\n DOWNGRADED_PARTNER = \"downgraded_partner\",\n DOWNGRADED_VENDOR = \"downgraded_vendor\",\n EVENT_INVITE_VENDOR = EnumRelationResource.EVENT_INVITE_VENDOR,\n EVENT_STARTING_SOON = \"event_starting_soon\",\n EXPIRATION_REMINDER_EVENT = \"expiration_reminder_event\",\n EXPIRATION_REMINDER_PARTNER = \"expiration_reminder_partner\",\n EXPIRATION_REMINDER_VENDOR = \"expiration_reminder_vendor\",\n NEW_CHAT_MESSAGE = \"new_chat_message\",\n NEW_POST_CREATED = \"new_post_created\",\n REGISTERED_USER_BY_SCHOOL_CODE = \"registered_user_by_school_code\",\n SYSTEM_ALERT = \"system_alert\",\n VENDOR_APPLICATION_TO_EVENT = EnumRelationResource.VENDOR_APPLICATION_TO_EVENT,\n}\n\nexport enum EnumNotificationType {\n CHAT = \"chat\",\n EVENT = EnumResourceType.EVENT,\n RELATION = \"relation\",\n SYSTEM = \"system\",\n VENDOR = EnumResourceType.VENDOR,\n}\n\nexport enum EnumRegions {\n All = \"All Regions\",\n Auckland = \"Auckland\",\n BayOfPlentyGisborne = \"Bay of Plenty & Gisborne\",\n CanterburyWestCoast = \"Canterbury & West Coast\",\n HawkesBay = \"Hawke's Bay\",\n ManawatuWanganui = \"Manawatu-Wanganui\",\n MarlboroughNelsonTasman = \"Marlborough & Nelson & Tasman\",\n Northland = \"Northland\",\n Otago = \"Otago\",\n Southland = \"Southland\",\n Taranaki = \"Taranaki\",\n Waikato = \"Waikato\",\n Wellington = \"Wellington\",\n}\n\nexport enum ImageTypeEnum {\n AVATAR = \"avatar\",\n COVER = \"cover\",\n IMAGE = \"image\",\n LOGO = \"logo\",\n}\n\nexport enum EnumUserLicence {\n PRO_EVENT = \"pro_event\",\n PRO_PLUS_EVENT = \"pro_plus_event\",\n PRO_PLUS_VENDOR = \"pro_plus_vendor\",\n PRO_VENDOR = \"pro_vendor\",\n STANDARD_EVENT = \"standard_event\",\n STANDARD_VENDOR = \"standard_vendor\",\n STANDARD_PARTNER = \"standard_partner\",\n}\n\nexport enum EnumUserRole {\n ADMIN = \"admin\",\n CUSTOMER = \"customer\",\n MARKETING = \"marketing\",\n MODERATOR = \"moderator\",\n SUPPORT = \"support\",\n}\n\nexport enum EnumSocialMedia {\n FACEBOOK = \"facebook\",\n INSTAGRAM = \"instagram\",\n TIKTOK = \"tiktok\",\n TWITTER = \"twitter\",\n WEBSITE = \"website\",\n YOUTUBE = \"youtube\",\n}\n\nexport enum EnumEventDateStatus {\n STARTING_SOON = \"Starting_Soon\",\n STARTED = \"Started\",\n TODAY = \"Today\",\n TOMORROW = \"Tomorrow\",\n THIS_WEEK = \"This_Week\",\n NEXT_WEEK = \"Next_Week\",\n UPCOMING = \"Upcoming\",\n ENDED = \"Ended\",\n RE_SCHEDULED = \"Rescheduled\",\n CANCELED = \"Canceled\",\n}\n\nexport enum EnumSubscriptionStatus {\n ACTIVE = \"active\",\n INACTIVE = \"inactive\",\n CANCELLED = \"cancelled\",\n NO_SUBSCRIPTION = \"no_subscription\",\n PAST_DUE = \"past_due\",\n TRIALING = \"trialing\",\n}\n\nexport enum EnumBillingPeriod {\n MONTHLY_CANCEL_ANYTIME = \"monthly_cancel_anytime\",\n YEARLY_ANNUAL_BILLED = \"yearly_annual_billed\",\n YEARLY_MONTHLY_BILLED = \"yearly_monthly_billed\",\n}\n","import {\n EnumInviteStatus,\n EnumPaymentMethod,\n EnumRegions,\n EnumSocialMedia,\n EnumUserLicence,\n} from \"src/enums\";\nimport { OptionItem, SocialMediaType } from \"src/types\";\n\nimport { isIsoDateString } from \"./date\";\n\nexport const removeTypename = (obj: any): any => {\n // Preserve Date objects\n if (obj instanceof Date) {\n return obj;\n }\n\n // Preserve File objects (for apollo-upload-client)\n if (obj instanceof File) {\n return obj;\n }\n\n // Preserve ISO date strings\n if (isIsoDateString(obj)) {\n return obj;\n }\n\n // Handle arrays\n if (Array.isArray(obj)) {\n return obj.map(removeTypename);\n }\n\n // Handle plain objects only\n if (obj !== null && typeof obj === \"object\") {\n const { __typename, ...cleanedObj } = obj;\n\n return Object.keys(cleanedObj).reduce((acc: any, key) => {\n acc[key] = removeTypename(cleanedObj[key]);\n return acc;\n }, {});\n }\n\n // Primitives\n return obj;\n};\n\n/**\n * Truncate text to a specified length and append ellipsis if necessary.\n * @param text\n * @param maxLength\n * @returns\n */\nexport const truncateText = (text: string, maxLength: number = 30): string => {\n return text.length > maxLength ? text.substring(0, maxLength) + \"...\" : text;\n};\n\n/**\n * Convert an array of strings to an array of objects with label and value properties.\n * @param items - The array of strings to convert.\n * @returns - The converted array of objects.\n */\nexport const mapArrayToOptions = (items: string[]): OptionItem[] =>\n items.map((item) => ({\n label: item,\n value: item,\n }));\n\nexport const capitalizeFirstLetter = (str: string): string => {\n return str\n .split(\" \")\n .map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase())\n .join(\" \");\n};\n\nexport const statusOptions = [\n ...Object.values(EnumInviteStatus)\n .map((status) => ({\n label: status,\n value: status,\n }))\n .sort((a, b) => a.label.localeCompare(b.label)), // Sort the options alphabetically\n];\n\nexport const availableRegionTypes = Object.values(EnumRegions);\nexport const availableRegionOptions: OptionItem[] =\n mapArrayToOptions(availableRegionTypes);\n\nexport const paymentMethodOptions: OptionItem[] = mapArrayToOptions(\n Object.values(EnumPaymentMethod),\n);\n\nexport function normalizeUrl(url: string): string {\n if (!url.startsWith(\"http://\") && !url.startsWith(\"https://\")) {\n return `https://${url}`;\n }\n return url;\n}\n\nexport const licenseNiceNames: Record<EnumUserLicence, string> = {\n [EnumUserLicence.PRO_EVENT]: \"Pro Event\",\n [EnumUserLicence.PRO_VENDOR]: \"Pro Stallholder\",\n [EnumUserLicence.STANDARD_EVENT]: \"Standard Event\",\n [EnumUserLicence.STANDARD_VENDOR]: \"Standard Stallholder\",\n [EnumUserLicence.PRO_PLUS_EVENT]: \"Pro+Ads Event\",\n [EnumUserLicence.PRO_PLUS_VENDOR]: \"Pro+Ads Stallholder\",\n [EnumUserLicence.STANDARD_PARTNER]: \"Partner\",\n};\n\nexport const cluemartSocialMedia: SocialMediaType[] = [\n {\n link: \"https://www.facebook.com/ClueMartApp\",\n name: EnumSocialMedia.FACEBOOK,\n },\n {\n link: \"https://www.instagram.com/cluemart_app\",\n name: EnumSocialMedia.INSTAGRAM,\n },\n {\n link: \"https://www.tiktok.com/@cluemart\",\n name: EnumSocialMedia.TIKTOK,\n },\n {\n link: \"https://www.youtube.com/@ClueMart-App-NZ\",\n name: EnumSocialMedia.YOUTUBE,\n },\n];\n\nexport const IOS_URL = \"https://apps.apple.com/nz/app/cluemart/id6747251008\";\nexport const ANDROID_URL =\n \"https://play.google.com/store/apps/details?id=com.timardex.cluemart\";\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACEA,IAAM,yBAAyB;AAC/B,IAAM,6BAA6B,GAAG,sBAAsB;AAErD,IAAM,2BAA2B;AAAA,EACtC;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO,IAAI,OAAO,YAAY,0BAA0B,EAAE;AAAA,EAC5D;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AAAA,IACJ,OAAO;AAAA,EACT;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN,IAAI;AA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C,wCAAgC,GAAG;AAAA,EACnC,0CAAiC,GAAG;AACtC;AAEO,IAAM,sBAAyC;AAAA,EACpD;AAAA,IACE,MAAM;AAAA,IACN;AAAA,EACF;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN;AAAA,EACF;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN;AAAA,EACF;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN;AAAA,EACF;AACF;AAEO,IAAM,UAAU;AAChB,IAAM,cACX;","names":["dayjs","customParseFormat","utc","timezone","isSameOrAfter","EnumInviteStatus","EnumPaymentMethod","EnumRegions"]}
1
+ {"version":3,"sources":["../../src/utils/index.ts","../../src/types/game/dailyClue.ts","../../src/utils/date.ts","../../src/utils/dailyClueGame.ts","../../src/enums/index.ts","../../src/utils/utils.ts","../../src/utils/school.ts"],"sourcesContent":["export { computeDailyClueState, seededShuffle } from \"./dailyClueGame\";\nexport {\n toNZTime,\n nzStartOfDay,\n formatDate,\n getCurrentAndFutureDates,\n isFutureDatesBeforeThreshold,\n formatTimestamp,\n isIsoDateString,\n sortDatesChronologically,\n timeFormat,\n dateFormat,\n} from \"./date\";\n\nexport {\n removeTypename,\n truncateText,\n mapArrayToOptions,\n capitalizeFirstLetter,\n statusOptions,\n availableRegionTypes,\n availableRegionOptions,\n paymentMethodOptions,\n normalizeUrl,\n licenseNiceNames,\n cluemartSocialMedia,\n IOS_URL,\n ANDROID_URL,\n} from \"./utils\";\n\nexport { SCHOOL_MIN_STUDENT_COUNT, SCHOOL_MAX_STUDENT_COUNT } from \"./school\";\n","import { EnumGameType, GameDate } from \"./global\";\n\nconst OBJECT_ID_PATH_SEGMENT = \"[a-f0-9]{24}\";\nconst OBJECT_ID_PATH_SEGMENT_END = `${OBJECT_ID_PATH_SEGMENT}$`;\n\nexport const gameScreenIdentifierList = [\n {\n clue: \"Where your actions turn into a timeline.\",\n id: \"activities\",\n match: \"/profile/activities\",\n },\n {\n clue: \"Where conversations happen without speaking.\",\n id: \"chat\",\n match: \"/profile/chat\",\n },\n {\n clue: \"The place to redefine who you are.\",\n id: \"edit-profile\",\n match: \"/profile/edit-profile\",\n },\n {\n clue: \"A single moment worth showing up for.\",\n id: \"single-event\",\n match: new RegExp(`^/events/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"What’s happening around you, right now.\",\n id: \"events-near-me\",\n match: \"/events/events-near-me\",\n },\n {\n clue: \"A collection of things worth attending.\",\n id: \"events\",\n match: \"/events\",\n },\n {\n clue: \"What’s happening in a wider area — not just nearby.\",\n id: \"events-region\",\n match: /^\\/events\\/region\\/[^/]+$/,\n },\n {\n clue: \"Where fun becomes a challenge.\",\n id: \"games\",\n match: \"/games\",\n },\n {\n clue: \"Your starting point for everything.\",\n id: \"home\",\n match: \"/\",\n },\n {\n clue: \"Where the app whispers what you shouldn’t miss.\",\n id: \"notifications\",\n match: \"/notifications\",\n },\n {\n clue: \"Where you fine-tune your experience.\",\n id: \"options\",\n match: \"/options\",\n },\n {\n clue: \"An organisation or creator supporting the community.\",\n id: \"single-partner\",\n match: new RegExp(`^/partners/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Organisations and creators supporting the community.\",\n id: \"partners\",\n match: \"/partners\",\n },\n {\n clue: \"A single published post in full view.\",\n id: \"single-visitor-post\",\n match: new RegExp(`^/visitors/post/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Your identity, on display.\",\n id: \"profile\",\n match: \"/profile\",\n },\n {\n clue: \"One stallholder offering something valuable.\",\n id: \"single-vendor\",\n match: new RegExp(`^/vendors/${OBJECT_ID_PATH_SEGMENT_END}`),\n },\n {\n clue: \"Where every stallholder waits under the right category.\",\n id: \"vendors\",\n match: \"/vendors\",\n },\n {\n clue: \"Where you browse articles and posts from around the platform.\",\n id: \"visitors\",\n match: \"/visitors\",\n },\n] as const;\n\nexport type GamePlacement = (typeof gameScreenIdentifierList)[number][\"id\"];\nexport type GamePlacementClue =\n (typeof gameScreenIdentifierList)[number][\"clue\"];\n\nexport const gameTypeToDisplayName: Record<EnumGameType, string> = {\n [EnumGameType.DAILY_CLUE]: \"Daily Clue\",\n};\n\nexport type DailyClueBaseGame = {\n gameDate: GameDate;\n gameSolution: string;\n gameType: EnumGameType;\n};\n\nexport type DailyClueGameData = {\n gameFields: DailyClueBaseGame;\n lastFoundDate: Date | null;\n points: number;\n letterInfo: {\n collected: string[] | null; // The letters the user has found, e.g. [\"C\", \"L\", \"U\"]\n solutionShuffled: string[]; // The letters of the solution, but shuffled, e.g. [\"L\", \"C\", \"U\"]\n todaysClue: GamePlacementClue | null; // The clue for user to find the letter, e.g. related to {todaysPlacement}\n todaysLetter: string | null; // The letter the user has to find today, e.g. \"C\"\n todaysPlacement: GamePlacement | null; // The screen where the user has to find the clue, e.g. \"HomeScreen\"\n };\n // User has found the clue 3 days in a row, this is incrementing if the user finds the clue and decrements if user misses a day\n streak: number;\n};\n","import dayjs from \"dayjs\";\nimport customParseFormat from \"dayjs/plugin/customParseFormat.js\";\nimport isSameOrAfter from \"dayjs/plugin/isSameOrAfter.js\";\nimport timezone from \"dayjs/plugin/timezone.js\";\nimport utc from \"dayjs/plugin/utc.js\";\n\nexport const dateFormat = \"DD-MM-YYYY\";\nexport const timeFormat = \"HH:mm\";\n\n// Enable custom format parsing\ndayjs.extend(customParseFormat);\ndayjs.extend(utc);\ndayjs.extend(timezone);\ndayjs.extend(isSameOrAfter);\n\nconst NZ_TZ = \"Pacific/Auckland\";\n\nexport function toNZTime(date?: Date | string) {\n return date ? dayjs(date).tz(NZ_TZ) : dayjs().tz(NZ_TZ);\n}\n\n/** Start of the calendar day in Pacific/Auckland (daily games, streaks, etc.). */\nexport function nzStartOfDay(\n input?: Date | string | number | null,\n): dayjs.Dayjs {\n if (input == null) {\n return dayjs().tz(NZ_TZ).startOf(\"day\");\n }\n return dayjs.tz(input, NZ_TZ).startOf(\"day\");\n}\n\ntype DateFormat = \"date\" | \"time\" | \"datetime\";\n\n/**\n * Format a date string to a more readable format.\n * @param dateStr - the date string\n * @param timeStr - optional time string\n * @param display - 'date' | 'time' | 'datetime'\n * @returns formatted string based on display option\n */\nexport const formatDate = (\n dateStr: string,\n display: DateFormat = \"datetime\",\n timeStr?: string,\n) => {\n // Combine date and time into a single string if time is provided\n const dateTimeStr = timeStr ? `${dateStr} ${timeStr}` : dateStr;\n\n // Parse with formats\n const dateTime = timeStr\n ? dayjs(dateTimeStr, `${dateFormat} ${timeFormat}`)\n : dayjs(dateStr, dateFormat);\n\n // Format parts\n const formattedDate = dateTime.format(\"dddd, D MMMM, YYYY\");\n const formattedTime = dateTime.format(\"h:mm a\");\n\n // Return based on display option\n switch (display) {\n case \"date\":\n return formattedDate;\n case \"time\":\n return formattedTime;\n case \"datetime\":\n return `${formattedDate} at ${formattedTime}`;\n default:\n return formattedDate;\n }\n};\n\nexport const getCurrentAndFutureDates = <\n T extends { startDate: string; startTime: string },\n>(\n dates: T[],\n): T[] => {\n const now = dayjs(); // current date and time\n\n return dates.filter((dateObj) => {\n const dateTime = dayjs(\n `${dateObj.startDate} ${dateObj.startTime}`,\n `${dateFormat} ${timeFormat}`,\n );\n return dateTime.isSameOrAfter(now);\n });\n};\n\nexport const isFutureDatesBeforeThreshold = (\n date: {\n startDate: string;\n startTime: string;\n },\n minHoursFromNow: number,\n): boolean => {\n const threshold = minHoursFromNow\n ? dayjs().add(minHoursFromNow, \"hour\")\n : dayjs().startOf(\"day\");\n\n const dateTime = dayjs(\n `${date.startDate} ${date.startTime}`,\n `${dateFormat} ${timeFormat}`,\n );\n\n return dateTime.isSameOrAfter(threshold);\n};\n\nexport const formatTimestamp = (timestamp: string) => {\n const formattedDate = toNZTime(timestamp).format(dateFormat);\n\n return formatDate(formattedDate, \"date\");\n};\n\nexport const isIsoDateString = (value: unknown): value is string => {\n return typeof value === \"string\" && !isNaN(Date.parse(value));\n};\n\n/**\n * Sort an array of date strings by their proximity to the current date.\n * @param dates - The array of date strings to sort.\n * @returns - The sorted array of date strings.\n */\nexport function sortDatesChronologically<\n T extends { startDate: string; startTime: string },\n>(dates: T[]): T[] {\n if (!dates || !dates.length) {\n return [];\n }\n\n return [...dates].sort((a, b) => {\n const dateTimeFormat = `${dateFormat} ${timeFormat}`;\n const dateA = dayjs(`${a.startDate} ${a.startTime}`, dateTimeFormat);\n const dateB = dayjs(`${b.startDate} ${b.startTime}`, dateTimeFormat);\n return dateA.valueOf() - dateB.valueOf(); // chronological order\n });\n}\n","import type { Dayjs } from \"dayjs\";\n\nimport {\n DailyClueGameData,\n GamePlacement,\n GamePlacementClue,\n gameScreenIdentifierList,\n} from \"../types/game/dailyClue\";\n\nimport { nzStartOfDay } from \"./date\";\n\nfunction createSeededRng(seed: number) {\n let t = seed >>> 0;\n\n return function random() {\n t += 0x6d2b79f5;\n let x = t;\n\n x = Math.imul(x ^ (x >>> 15), x | 1);\n x ^= x + Math.imul(x ^ (x >>> 7), x | 61);\n\n return ((x ^ (x >>> 14)) >>> 0) / 4294967296;\n };\n}\n\nfunction hashStringToNumber(seed: string): number {\n let hash = 2166136261;\n\n for (let i = 0; i < seed.length; i++) {\n hash ^= seed.codePointAt(i) ?? 0;\n hash = Math.imul(hash, 16777619);\n }\n\n return hash >>> 0;\n}\n\n/** Seeded shuffle so all players see the same letter order / placements for a game. */\nexport function seededShuffle<T>(array: readonly T[], seed: string): T[] {\n const rng = createSeededRng(hashStringToNumber(seed));\n const result = [...array];\n\n for (let i = result.length - 1; i > 0; i--) {\n const j = Math.floor(rng() * (i + 1));\n [result[i], result[j]] = [result[j], result[i]];\n }\n\n return result;\n}\n\nfunction getDayIndex(start: Dayjs, today: Dayjs): number {\n return today.diff(start, \"day\");\n}\n\nexport function computeDailyClueState(dailyClue: DailyClueGameData): {\n todaysClue: GamePlacementClue | null;\n todaysLetter: string | null;\n todaysPlacement: GamePlacement | null;\n} | null {\n const { startDate, endDate } = dailyClue.gameFields.gameDate;\n const { solutionShuffled, collected } = dailyClue.letterInfo;\n\n const today = nzStartOfDay();\n const start = nzStartOfDay(startDate);\n const end = nzStartOfDay(endDate);\n\n // Before game starts\n if (today.isBefore(start)) {\n return null;\n }\n\n const shuffledPlacements = seededShuffle(\n gameScreenIdentifierList,\n start.toISOString(),\n );\n\n const index = getDayIndex(start, today);\n\n // After game ends\n if (today.isAfter(end)) {\n return {\n todaysClue: null,\n todaysLetter: null,\n todaysPlacement: null,\n };\n }\n\n // Safety: index must exist in BOTH arrays\n if (\n index < 0 ||\n index >= solutionShuffled.length ||\n index >= shuffledPlacements.length\n ) {\n return null;\n }\n\n const letterToday = solutionShuffled[index];\n const placement = shuffledPlacements[index];\n\n if (!letterToday || !placement) return null;\n\n const alreadyCollectedToday = (collected ?? []).includes(letterToday);\n\n // Already completed today\n if (alreadyCollectedToday) {\n return {\n todaysClue: null,\n todaysLetter: null,\n todaysPlacement: null,\n };\n }\n\n // Active state\n return {\n todaysClue: placement.clue,\n todaysLetter: letterToday,\n todaysPlacement: placement.id,\n };\n}\n","export enum EnumInviteStatus {\n ACCEPTED = \"Accepted\",\n COMPLETED = \"Completed\",\n EXPIRED = \"Expired\",\n NO_STATUS = \"No_Status\",\n PENDING = \"Pending\",\n REJECTED = \"Rejected\",\n UNAVAILABLE = \"Unavailable\",\n}\n\nexport enum EnumChatReportReason {\n INAPPROPRIATE_CONTENT = \"Inappropriate_Content\",\n HARASSMENT_OR_BULLYING = \"Harassment_or_Bullying\",\n HATE_SPEECH = \"Hate_Speech\",\n SPAM_OR_SCAM = \"Spam_or_Scam\",\n VIOLENCE_OR_DANGEROUS_BEHAVIOR = \"Violence_or_Dangerous_Behavior\",\n OTHER = \"Other\",\n}\n\nexport enum EnumChatType {\n GROUP = \"group\",\n PRIVATE = \"private\",\n RELATION = \"relation\",\n}\n\nexport enum EnumPaymentMethod {\n CASH = \"cash\",\n EFTPOS = \"eftpos\",\n BANK_TRANSFER = \"bank_transfer\",\n PAYPAL = \"paypal\",\n STRIPE = \"stripe\",\n}\n\nexport enum EnumFoodFlavor {\n SALTY = \"Salty\",\n SAVOURY = \"Savoury\",\n SPICY = \"Spicy\",\n SWEET = \"Sweet\",\n OTHER = \"Not_Applicable\",\n}\n\nexport enum EnumFoodType {\n ADDITIVE_FREE = \"Additive_Free\",\n AIR_FRIED = \"Air_Fried\",\n ALLERGEN_FRIENDLY = \"Allergen_Friendly\",\n ATHLETE_FRIENDLY = \"Athlete_Friendly\",\n BAKED = \"Baked\",\n DAIRY_FREE = \"Dairy_Free\",\n DIABETIC_FRIENDLY = \"Diabetic_Friendly\",\n EGG_FREE = \"Egg_Free\",\n FRESH = \"Fresh\",\n GLUTEN_FREE = \"Gluten_Free\",\n GRILLED = \"Grilled\",\n HALAL = \"Halal\",\n HEART_HEALTHY = \"Heart_Healthy\",\n HIGH_FIBER = \"High_Fiber\",\n HIGH_PROTEIN = \"High_Protein\",\n KETO = \"Keto\",\n KOSHER = \"Kosher\",\n LACTOSE_FREE = \"Lactose_Free\",\n LOW_CALORIE = \"Low_Calorie\",\n LOW_CARB = \"Low_Carb\",\n LOW_FAT = \"Low_Fat\",\n LOW_SODIUM = \"Low_Sodium\",\n NO_ADDED_SUGAR = \"No_Added_Sugar\",\n NO_PRESERVATIVES = \"No_Preservatives\",\n NON_GMO = \"Non_GMO\",\n NUT_FREE = \"Nut_Free\",\n ORGANIC = \"Organic\",\n PALEO = \"Paleo\",\n PLANT_BASED = \"Plant_Based\",\n RAW = \"Raw\",\n SMOKED = \"Smoked\",\n SOY_FREE = \"Soy_Free\",\n SUGAR_FREE = \"Sugar_Free\",\n VEGAN = \"Vegan\",\n VEGETARIAN = \"Vegetarian\",\n}\n\nexport enum EnumResourceType {\n EVENT = \"event\",\n VENDOR = \"vendor\",\n PARTNER = \"partner\",\n}\n\nexport enum EnumEventType {\n MARKET = \"Market\",\n EXPO = \"Expo\",\n FAIR = \"Fair\",\n FESTIVAL = \"Festival\",\n}\n\nexport enum EnumVendorType {\n STALLHOLDER = \"Stallholder\",\n SHOP = \"Shop\",\n}\n\nexport enum EnumPartnerType {\n CHARITY_PARTNER = \"Charity_Partner\",\n MEDIA_PARTNER = \"Media_Partner\",\n SUPPORTING_PARTNER = \"Supporting_Partner\",\n}\n\nexport enum EnumOSPlatform {\n ANDROID = \"android\",\n IOS = \"ios\",\n WEB = \"web\",\n}\n\nexport enum EnumRelationResource {\n EVENT_INVITE_VENDOR = \"event_invite_vendor\",\n VENDOR_APPLICATION_TO_EVENT = \"vendor_application_to_event\",\n}\n\nexport enum EnumNotificationResourceType {\n ADDED_AS_ASSOCIATE_EVENT = \"added_as_associate_event\",\n ADDED_AS_ASSOCIATE_PARTNER = \"added_as_associate_partner\",\n ADDED_AS_ASSOCIATE_VENDOR = \"added_as_associate_vendor\",\n APPROVED_EVENT = \"approved_event\",\n APPROVED_PARTNER = \"approved_partner\",\n APPROVED_VENDOR = \"approved_vendor\",\n CREATED_EVENT = \"created_event\",\n CREATED_PARTNER = \"created_partner\",\n CREATED_VENDOR = \"created_vendor\",\n DAILY_CLUE_GAME = \"daily_clue_game\",\n DEACTIVATED_EVENT = \"deactivated_event\",\n DEACTIVATED_PARTNER = \"deactivated_partner\",\n DEACTIVATED_VENDOR = \"deactivated_vendor\",\n DECLINED_EVENT = \"declined_event\",\n DECLINED_PARTNER = \"declined_partner\",\n DECLINED_VENDOR = \"declined_vendor\",\n DOWNGRADED_EVENT = \"downgraded_event\",\n DOWNGRADED_PARTNER = \"downgraded_partner\",\n DOWNGRADED_VENDOR = \"downgraded_vendor\",\n EVENT_INVITE_VENDOR = EnumRelationResource.EVENT_INVITE_VENDOR,\n EVENT_STARTING_SOON = \"event_starting_soon\",\n EXPIRATION_REMINDER_EVENT = \"expiration_reminder_event\",\n EXPIRATION_REMINDER_PARTNER = \"expiration_reminder_partner\",\n EXPIRATION_REMINDER_VENDOR = \"expiration_reminder_vendor\",\n NEW_CHAT_MESSAGE = \"new_chat_message\",\n NEW_POST_CREATED = \"new_post_created\",\n REGISTERED_USER_BY_SCHOOL_CODE = \"registered_user_by_school_code\",\n SYSTEM_ALERT = \"system_alert\",\n VENDOR_APPLICATION_TO_EVENT = EnumRelationResource.VENDOR_APPLICATION_TO_EVENT,\n}\n\nexport enum EnumNotificationType {\n CHAT = \"chat\",\n EVENT = EnumResourceType.EVENT,\n RELATION = \"relation\",\n SYSTEM = \"system\",\n VENDOR = EnumResourceType.VENDOR,\n}\n\nexport enum EnumRegions {\n All = \"All Regions\",\n Auckland = \"Auckland\",\n BayOfPlentyGisborne = \"Bay of Plenty & Gisborne\",\n CanterburyWestCoast = \"Canterbury & West Coast\",\n HawkesBay = \"Hawke's Bay\",\n ManawatuWanganui = \"Manawatu-Wanganui\",\n MarlboroughNelsonTasman = \"Marlborough & Nelson & Tasman\",\n Northland = \"Northland\",\n Otago = \"Otago\",\n Southland = \"Southland\",\n Taranaki = \"Taranaki\",\n Waikato = \"Waikato\",\n Wellington = \"Wellington\",\n}\n\nexport enum ImageTypeEnum {\n AVATAR = \"avatar\",\n COVER = \"cover\",\n IMAGE = \"image\",\n LOGO = \"logo\",\n}\n\nexport enum EnumUserLicence {\n PRO_EVENT = \"pro_event\",\n PRO_PLUS_EVENT = \"pro_plus_event\",\n PRO_PLUS_VENDOR = \"pro_plus_vendor\",\n PRO_VENDOR = \"pro_vendor\",\n STANDARD_EVENT = \"standard_event\",\n STANDARD_VENDOR = \"standard_vendor\",\n STANDARD_PARTNER = \"standard_partner\",\n}\n\nexport enum EnumUserRole {\n ADMIN = \"admin\",\n CUSTOMER = \"customer\",\n MARKETING = \"marketing\",\n MODERATOR = \"moderator\",\n SUPPORT = \"support\",\n}\n\nexport enum EnumSocialMedia {\n FACEBOOK = \"facebook\",\n INSTAGRAM = \"instagram\",\n TIKTOK = \"tiktok\",\n TWITTER = \"twitter\",\n WEBSITE = \"website\",\n YOUTUBE = \"youtube\",\n}\n\nexport enum EnumEventDateStatus {\n STARTING_SOON = \"Starting_Soon\",\n STARTED = \"Started\",\n TODAY = \"Today\",\n TOMORROW = \"Tomorrow\",\n THIS_WEEK = \"This_Week\",\n NEXT_WEEK = \"Next_Week\",\n UPCOMING = \"Upcoming\",\n ENDED = \"Ended\",\n RE_SCHEDULED = \"Rescheduled\",\n CANCELED = \"Canceled\",\n}\n\nexport enum EnumSubscriptionStatus {\n ACTIVE = \"active\",\n INACTIVE = \"inactive\",\n CANCELLED = \"cancelled\",\n NO_SUBSCRIPTION = \"no_subscription\",\n PAST_DUE = \"past_due\",\n TRIALING = \"trialing\",\n}\n\nexport enum EnumBillingPeriod {\n MONTHLY_CANCEL_ANYTIME = \"monthly_cancel_anytime\",\n YEARLY_ANNUAL_BILLED = \"yearly_annual_billed\",\n YEARLY_MONTHLY_BILLED = \"yearly_monthly_billed\",\n}\n","import {\n EnumInviteStatus,\n EnumPaymentMethod,\n EnumRegions,\n EnumSocialMedia,\n EnumUserLicence,\n} from \"src/enums\";\nimport { OptionItem, SocialMediaType } from \"src/types\";\n\nimport { isIsoDateString } from \"./date\";\n\nexport const removeTypename = (obj: any): any => {\n // Preserve Date objects\n if (obj instanceof Date) {\n return obj;\n }\n\n // Preserve File objects (for apollo-upload-client)\n if (obj instanceof File) {\n return obj;\n }\n\n // Preserve ISO date strings\n if (isIsoDateString(obj)) {\n return obj;\n }\n\n // Handle arrays\n if (Array.isArray(obj)) {\n return obj.map(removeTypename);\n }\n\n // Handle plain objects only\n if (obj !== null && typeof obj === \"object\") {\n const { __typename, ...cleanedObj } = obj;\n\n return Object.keys(cleanedObj).reduce((acc: any, key) => {\n acc[key] = removeTypename(cleanedObj[key]);\n return acc;\n }, {});\n }\n\n // Primitives\n return obj;\n};\n\n/**\n * Truncate text to a specified length and append ellipsis if necessary.\n * @param text\n * @param maxLength\n * @returns\n */\nexport const truncateText = (text: string, maxLength: number = 30): string => {\n return text.length > maxLength ? text.substring(0, maxLength) + \"...\" : text;\n};\n\n/**\n * Convert an array of strings to an array of objects with label and value properties.\n * @param items - The array of strings to convert.\n * @returns - The converted array of objects.\n */\nexport const mapArrayToOptions = (items: string[]): OptionItem[] =>\n items.map((item) => ({\n label: item,\n value: item,\n }));\n\nexport const capitalizeFirstLetter = (str: string): string => {\n return str\n .split(\" \")\n .map((word) => word.charAt(0).toUpperCase() + word.slice(1).toLowerCase())\n .join(\" \");\n};\n\nexport const statusOptions = [\n ...Object.values(EnumInviteStatus)\n .map((status) => ({\n label: status,\n value: status,\n }))\n .sort((a, b) => a.label.localeCompare(b.label)), // Sort the options alphabetically\n];\n\nexport const availableRegionTypes = Object.values(EnumRegions);\nexport const availableRegionOptions: OptionItem[] =\n mapArrayToOptions(availableRegionTypes);\n\nexport const paymentMethodOptions: OptionItem[] = mapArrayToOptions(\n Object.values(EnumPaymentMethod),\n);\n\nexport function normalizeUrl(url: string): string {\n if (!url.startsWith(\"http://\") && !url.startsWith(\"https://\")) {\n return `https://${url}`;\n }\n return url;\n}\n\nexport const licenseNiceNames: Record<EnumUserLicence, string> = {\n [EnumUserLicence.PRO_EVENT]: \"Pro Event\",\n [EnumUserLicence.PRO_VENDOR]: \"Pro Stallholder\",\n [EnumUserLicence.STANDARD_EVENT]: \"Standard Event\",\n [EnumUserLicence.STANDARD_VENDOR]: \"Standard Stallholder\",\n [EnumUserLicence.PRO_PLUS_EVENT]: \"Pro+Ads Event\",\n [EnumUserLicence.PRO_PLUS_VENDOR]: \"Pro+Ads Stallholder\",\n [EnumUserLicence.STANDARD_PARTNER]: \"Partner\",\n};\n\nexport const cluemartSocialMedia: SocialMediaType[] = [\n {\n link: \"https://www.facebook.com/ClueMartApp\",\n name: EnumSocialMedia.FACEBOOK,\n },\n {\n link: \"https://www.instagram.com/cluemart_app\",\n name: EnumSocialMedia.INSTAGRAM,\n },\n {\n link: \"https://www.tiktok.com/@cluemart\",\n name: EnumSocialMedia.TIKTOK,\n },\n {\n link: \"https://www.youtube.com/@ClueMart-App-NZ\",\n name: EnumSocialMedia.YOUTUBE,\n },\n];\n\nexport const IOS_URL = \"https://apps.apple.com/nz/app/cluemart/id6747251008\";\nexport const ANDROID_URL =\n \"https://play.google.com/store/apps/details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AM;AAAA,IACN;AAAA,EACF;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN;AAAA,EACF;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN;AAAA,EACF;AAAA,EACA;AAAA,IACE,MAAM;AAAA,IACN;AAAA,EACF;AACF;AAEO,IAAM,UAAU;AAChB,IAAM,cACX;;;ACjIK,IAAM,2BAA2B;AACjC,IAAM,2BAA2B;","names":["dayjs","customParseFormat","utc","timezone","isSameOrAfter","EnumInviteStatus","EnumPaymentMethod","EnumRegions"]}