@timardex/cluemart-shared 1.5.740 → 1.5.742
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ad-CqfSmtG_.d.ts → ad-DTOtubs3.d.ts} +1 -1
- package/dist/{ad-sgD-lSbO.d.mts → ad-DpwV6VZX.d.mts} +1 -1
- package/dist/{chunk-6OBMKN7F.mjs → chunk-64ZADXXH.mjs} +2 -2
- package/dist/{chunk-XWFE6U3E.mjs → chunk-K5OWNJY5.mjs} +131 -119
- package/dist/chunk-K5OWNJY5.mjs.map +1 -0
- package/dist/{chunk-6YISZ3OD.mjs → chunk-KXQLOILF.mjs} +2 -2
- package/dist/{chunk-7VNXO63T.mjs → chunk-LNIT5OS3.mjs} +1 -1
- package/dist/chunk-LNIT5OS3.mjs.map +1 -0
- package/dist/{chunk-3AI2ROPT.mjs → chunk-TIXEG66V.mjs} +19 -1
- package/dist/chunk-TIXEG66V.mjs.map +1 -0
- package/dist/{contactUs-DA3p41Uq.d.ts → contactUs-BK5MKYPx.d.ts} +1 -1
- package/dist/{contactUs-B6lQQq-x.d.mts → contactUs-CRypzI-A.d.mts} +1 -1
- package/dist/formFields/index.cjs +28 -4
- package/dist/formFields/index.cjs.map +1 -1
- package/dist/formFields/index.d.mts +1 -1
- package/dist/formFields/index.d.ts +1 -1
- package/dist/formFields/index.mjs +3 -3
- package/dist/{global-BEUzBSyY.d.mts → global-q9JjONd1.d.mts} +280 -1
- package/dist/{global-585slmSH.d.ts → global-vWzQNI8w.d.ts} +280 -1
- package/dist/graphql/index.cjs +18 -0
- package/dist/graphql/index.cjs.map +1 -1
- package/dist/graphql/index.d.mts +3 -4
- package/dist/graphql/index.d.ts +3 -4
- package/dist/graphql/index.mjs +1 -1
- package/dist/hooks/index.cjs +34 -6
- package/dist/hooks/index.cjs.map +1 -1
- package/dist/hooks/index.d.mts +3 -4
- package/dist/hooks/index.d.ts +3 -4
- package/dist/hooks/index.mjs +5 -5
- package/dist/index.cjs +171 -141
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +922 -914
- package/dist/index.d.ts +922 -914
- package/dist/index.mjs +170 -141
- package/dist/index.mjs.map +1 -1
- package/dist/{resourceActivities-CZqXBve8.d.mts → resourceActivities-CpjJeH23.d.mts} +1 -1
- package/dist/{resourceActivities-CjJdhVR7.d.ts → resourceActivities-DtxRUlrT.d.ts} +1 -1
- package/dist/sharing/index.cjs +82 -58
- package/dist/sharing/index.cjs.map +1 -1
- package/dist/sharing/index.d.mts +1 -1
- package/dist/sharing/index.d.ts +1 -1
- package/dist/sharing/index.mjs +3 -3
- package/dist/types/index.cjs.map +1 -1
- package/dist/types/index.d.mts +5 -6
- package/dist/types/index.d.ts +5 -6
- package/dist/types/index.mjs +1 -1
- package/dist/utils/index.cjs +167 -141
- package/dist/utils/index.cjs.map +1 -1
- package/dist/utils/index.d.mts +6 -3
- package/dist/utils/index.d.ts +6 -3
- package/dist/utils/index.mjs +4 -2
- package/package.json +1 -1
- package/dist/chunk-3AI2ROPT.mjs.map +0 -1
- package/dist/chunk-7VNXO63T.mjs.map +0 -1
- package/dist/chunk-XWFE6U3E.mjs.map +0 -1
- package/dist/post-CdLrXuH1.d.mts +0 -279
- package/dist/post-D6n4Vszs.d.ts +0 -279
- /package/dist/{chunk-6OBMKN7F.mjs.map → chunk-64ZADXXH.mjs.map} +0 -0
- /package/dist/{chunk-6YISZ3OD.mjs.map → chunk-KXQLOILF.mjs.map} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-
|
|
1
|
+
import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-q9JjONd1.mjs';
|
|
2
2
|
import 'react-hook-form';
|
|
3
3
|
import '../enums/index.mjs';
|
|
4
4
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-
|
|
1
|
+
import { O as OptionItem, F as FormField, a as FormDateField, R as RefundPolicy, b as Requirement, S as StallType, C as Category } from '../global-vWzQNI8w.js';
|
|
2
2
|
import 'react-hook-form';
|
|
3
3
|
import '../enums/index.js';
|
|
4
4
|
|
|
@@ -43,9 +43,9 @@ import {
|
|
|
43
43
|
vendorStallSize,
|
|
44
44
|
vendorStartDateFields,
|
|
45
45
|
vendorTable
|
|
46
|
-
} from "../chunk-
|
|
47
|
-
import "../chunk-
|
|
48
|
-
import "../chunk-
|
|
46
|
+
} from "../chunk-KXQLOILF.mjs";
|
|
47
|
+
import "../chunk-K5OWNJY5.mjs";
|
|
48
|
+
import "../chunk-LNIT5OS3.mjs";
|
|
49
49
|
import "../chunk-4SNW63TJ.mjs";
|
|
50
50
|
export {
|
|
51
51
|
availableCategories,
|
|
@@ -100,6 +100,281 @@ type EventInfoType = Omit<EventInfoFormData, "_id"> & {
|
|
|
100
100
|
active?: boolean;
|
|
101
101
|
};
|
|
102
102
|
|
|
103
|
+
declare enum EnumGameType {
|
|
104
|
+
DAILY_CLUE = "dailyClue",
|
|
105
|
+
MINI_QUIZ = "miniQuiz",
|
|
106
|
+
ODD_ONE_OUT = "oddOneOut"
|
|
107
|
+
}
|
|
108
|
+
type GameDate = {
|
|
109
|
+
startDate: Date;
|
|
110
|
+
endDate: Date;
|
|
111
|
+
};
|
|
112
|
+
declare const gameTypeToDisplayName: Record<EnumGameType, string>;
|
|
113
|
+
type GlobalGameData = {
|
|
114
|
+
points: number;
|
|
115
|
+
streak: number;
|
|
116
|
+
};
|
|
117
|
+
|
|
118
|
+
declare const gameScreenIdentifierList: readonly [{
|
|
119
|
+
readonly clue: "Where your actions turn into a timeline.";
|
|
120
|
+
readonly id: "activities";
|
|
121
|
+
readonly match: "/profile/activities";
|
|
122
|
+
}, {
|
|
123
|
+
readonly clue: "Where conversations happen without speaking.";
|
|
124
|
+
readonly id: "chat";
|
|
125
|
+
readonly match: "/profile/chat";
|
|
126
|
+
}, {
|
|
127
|
+
readonly clue: "The place to redefine who you are.";
|
|
128
|
+
readonly id: "edit-profile";
|
|
129
|
+
readonly match: "/profile/edit-profile";
|
|
130
|
+
}, {
|
|
131
|
+
readonly clue: "A single moment worth showing up for.";
|
|
132
|
+
readonly id: "single-event";
|
|
133
|
+
readonly match: RegExp;
|
|
134
|
+
}, {
|
|
135
|
+
readonly clue: "What’s happening around you, right now.";
|
|
136
|
+
readonly id: "events-near-me";
|
|
137
|
+
readonly match: "/events/events-near-me";
|
|
138
|
+
}, {
|
|
139
|
+
readonly clue: "Where events appear as pins on a map.";
|
|
140
|
+
readonly id: "events-map";
|
|
141
|
+
readonly match: "/events/events-map";
|
|
142
|
+
}, {
|
|
143
|
+
readonly clue: "A collection of events worth attending.";
|
|
144
|
+
readonly id: "events";
|
|
145
|
+
readonly match: "/events";
|
|
146
|
+
}, {
|
|
147
|
+
readonly clue: "What’s happening in a wider area — not just nearby.";
|
|
148
|
+
readonly id: "events-region";
|
|
149
|
+
readonly match: RegExp;
|
|
150
|
+
}, {
|
|
151
|
+
readonly clue: "Where fun becomes a challenge.";
|
|
152
|
+
readonly id: "games";
|
|
153
|
+
readonly match: "/games";
|
|
154
|
+
}, {
|
|
155
|
+
readonly clue: "Your starting point for everything.";
|
|
156
|
+
readonly id: "home";
|
|
157
|
+
readonly match: "/";
|
|
158
|
+
}, {
|
|
159
|
+
readonly clue: "Where the app whispers what you shouldn’t miss.";
|
|
160
|
+
readonly id: "notifications";
|
|
161
|
+
readonly match: "/notifications";
|
|
162
|
+
}, {
|
|
163
|
+
readonly clue: "Where you fine-tune your experience.";
|
|
164
|
+
readonly id: "options";
|
|
165
|
+
readonly match: "/options";
|
|
166
|
+
}, {
|
|
167
|
+
readonly clue: "An organisation or creator supporting the community.";
|
|
168
|
+
readonly id: "single-partner";
|
|
169
|
+
readonly match: RegExp;
|
|
170
|
+
}, {
|
|
171
|
+
readonly clue: "Organisations and creators supporting the community.";
|
|
172
|
+
readonly id: "partners";
|
|
173
|
+
readonly match: "/partners";
|
|
174
|
+
}, {
|
|
175
|
+
readonly clue: "A single published post in full view.";
|
|
176
|
+
readonly id: "single-visitor-post";
|
|
177
|
+
readonly match: RegExp;
|
|
178
|
+
}, {
|
|
179
|
+
readonly clue: "Your identity, on display.";
|
|
180
|
+
readonly id: "profile";
|
|
181
|
+
readonly match: "/profile";
|
|
182
|
+
}, {
|
|
183
|
+
readonly clue: "One stallholder offering something valuable.";
|
|
184
|
+
readonly id: "single-vendor";
|
|
185
|
+
readonly match: RegExp;
|
|
186
|
+
}, {
|
|
187
|
+
readonly clue: "Where every stallholder waits under the right category.";
|
|
188
|
+
readonly id: "vendors";
|
|
189
|
+
readonly match: "/vendors";
|
|
190
|
+
}, {
|
|
191
|
+
readonly clue: "Where you browse articles and posts from around the platform.";
|
|
192
|
+
readonly id: "visitors";
|
|
193
|
+
readonly match: "/visitors";
|
|
194
|
+
}];
|
|
195
|
+
type GamePlacement = (typeof gameScreenIdentifierList)[number]["id"];
|
|
196
|
+
type GamePlacementClue = (typeof gameScreenIdentifierList)[number]["clue"];
|
|
197
|
+
type DailyClueBaseGame = {
|
|
198
|
+
gameDate: GameDate;
|
|
199
|
+
gameSolution: string;
|
|
200
|
+
};
|
|
201
|
+
type DailyClueGameData = GlobalGameData & {
|
|
202
|
+
gameFields: DailyClueBaseGame;
|
|
203
|
+
lastFoundDate: Date | null;
|
|
204
|
+
letterInfo: {
|
|
205
|
+
collected: string[] | null;
|
|
206
|
+
solutionShuffled: string[];
|
|
207
|
+
todaysClue: GamePlacementClue | null;
|
|
208
|
+
todaysLetter: string | null;
|
|
209
|
+
todaysPlacement: GamePlacement | null;
|
|
210
|
+
};
|
|
211
|
+
};
|
|
212
|
+
|
|
213
|
+
type PuzzleAnswer = {
|
|
214
|
+
answerId: string;
|
|
215
|
+
answer: string;
|
|
216
|
+
correct: boolean;
|
|
217
|
+
};
|
|
218
|
+
type PuzzleQuestion = {
|
|
219
|
+
answers: PuzzleAnswer[];
|
|
220
|
+
question: string;
|
|
221
|
+
questionId: string;
|
|
222
|
+
};
|
|
223
|
+
/**
|
|
224
|
+
* Stores only the answerId and the questionId of the selected answer.
|
|
225
|
+
*/
|
|
226
|
+
type PuzzleAnsweredQuestion = {
|
|
227
|
+
selectedAnswerId: string;
|
|
228
|
+
questionId: string;
|
|
229
|
+
};
|
|
230
|
+
type PuzzleBaseGame = {
|
|
231
|
+
questions: PuzzleQuestion[];
|
|
232
|
+
};
|
|
233
|
+
type PuzzleGameData = GlobalGameData & {
|
|
234
|
+
gameFields: PuzzleBaseGame;
|
|
235
|
+
/**
|
|
236
|
+
* Stores user answers only.
|
|
237
|
+
* Never store correctness from client.
|
|
238
|
+
*/
|
|
239
|
+
answeredQuestions: PuzzleAnsweredQuestion[];
|
|
240
|
+
};
|
|
241
|
+
|
|
242
|
+
type BaseGameMap = {
|
|
243
|
+
[EnumGameType.DAILY_CLUE]: DailyClueBaseGame;
|
|
244
|
+
[EnumGameType.MINI_QUIZ]: PuzzleBaseGame;
|
|
245
|
+
[EnumGameType.ODD_ONE_OUT]: PuzzleBaseGame;
|
|
246
|
+
};
|
|
247
|
+
type BaseGameType = {
|
|
248
|
+
gameType: EnumGameType;
|
|
249
|
+
gameTypeId: string;
|
|
250
|
+
gameTitle: string;
|
|
251
|
+
} & {
|
|
252
|
+
[K in keyof BaseGameMap]?: BaseGameMap[K] | null;
|
|
253
|
+
};
|
|
254
|
+
declare enum EnumGameStatus {
|
|
255
|
+
GAME_COMPLETED = "GAME_COMPLETED",
|
|
256
|
+
GAME_IN_PROGRESS = "GAME_IN_PROGRESS",
|
|
257
|
+
GAME_LEFT = "GAME_LEFT",
|
|
258
|
+
GAME_STARTED = "GAME_STARTED"
|
|
259
|
+
}
|
|
260
|
+
type GameHistory = Pick<BaseGameType, "gameTitle" | "gameType" | "gameTypeId"> & {
|
|
261
|
+
createdAt: Date;
|
|
262
|
+
gameDate: GameDate;
|
|
263
|
+
gameStatus: EnumGameStatus;
|
|
264
|
+
/** Per-event delta. Not persisted for overallGamePoints (computed at read time). */
|
|
265
|
+
pointsEarned: number;
|
|
266
|
+
/** Running total for this game instance; computed at read time, not stored in Mongo. */
|
|
267
|
+
overallGamePoints?: number;
|
|
268
|
+
};
|
|
269
|
+
type GameDataMap = {
|
|
270
|
+
[EnumGameType.DAILY_CLUE]: DailyClueGameData;
|
|
271
|
+
[EnumGameType.MINI_QUIZ]: PuzzleGameData;
|
|
272
|
+
[EnumGameType.ODD_ONE_OUT]: PuzzleGameData;
|
|
273
|
+
};
|
|
274
|
+
type GameDataType = {
|
|
275
|
+
[K in keyof GameDataMap]?: GameDataMap[K] | null;
|
|
276
|
+
};
|
|
277
|
+
type GameType = Pick<BaseGameType, "gameTitle" | "gameType" | "gameTypeId"> & {
|
|
278
|
+
_id: string;
|
|
279
|
+
active: boolean;
|
|
280
|
+
createdAt: Date;
|
|
281
|
+
gameData: GameDataType;
|
|
282
|
+
gameHistory: GameHistory[] | null;
|
|
283
|
+
updatedAt: Date | null;
|
|
284
|
+
};
|
|
285
|
+
type GameDocType = {
|
|
286
|
+
_id: string;
|
|
287
|
+
active: boolean;
|
|
288
|
+
createdAt: Date;
|
|
289
|
+
deletedAt: Date | null;
|
|
290
|
+
games: GameType[] | null;
|
|
291
|
+
owner: OwnerType;
|
|
292
|
+
points: number;
|
|
293
|
+
updatedAt: Date | null;
|
|
294
|
+
};
|
|
295
|
+
type GameLeaderboard = {
|
|
296
|
+
gameHistory: GameHistory[] | null;
|
|
297
|
+
overallPoints: number;
|
|
298
|
+
owner: OwnerType;
|
|
299
|
+
};
|
|
300
|
+
|
|
301
|
+
declare enum EnumPostType {
|
|
302
|
+
MARKET_FACES = "market_faces",
|
|
303
|
+
CLUE_BITES = "clue_bites",
|
|
304
|
+
PLAY_AND_WIN = "play_and_win"
|
|
305
|
+
}
|
|
306
|
+
declare enum EnumPostContentType {
|
|
307
|
+
GAME = "game",
|
|
308
|
+
IMAGE = "image",
|
|
309
|
+
LIST = "list",
|
|
310
|
+
TEXTAREA = "textarea",
|
|
311
|
+
VIDEO = "video"
|
|
312
|
+
}
|
|
313
|
+
type PostFileInput = {
|
|
314
|
+
source: File;
|
|
315
|
+
title?: string;
|
|
316
|
+
};
|
|
317
|
+
type PostContentTextarea = {
|
|
318
|
+
textarea: {
|
|
319
|
+
title?: string;
|
|
320
|
+
data: string;
|
|
321
|
+
};
|
|
322
|
+
};
|
|
323
|
+
type PostContentImage = {
|
|
324
|
+
images: ResourceImageType[] | null;
|
|
325
|
+
imagesUpload?: PostFileInput[] | null;
|
|
326
|
+
};
|
|
327
|
+
type PostContentVideo = {
|
|
328
|
+
video: {
|
|
329
|
+
source: string;
|
|
330
|
+
title?: string;
|
|
331
|
+
};
|
|
332
|
+
};
|
|
333
|
+
type PostContentList = {
|
|
334
|
+
list: {
|
|
335
|
+
title?: string;
|
|
336
|
+
items: {
|
|
337
|
+
text: string;
|
|
338
|
+
}[];
|
|
339
|
+
};
|
|
340
|
+
};
|
|
341
|
+
type PostContentGame = {
|
|
342
|
+
game: BaseGameType;
|
|
343
|
+
};
|
|
344
|
+
type PostContentData = PostContentGame | PostContentTextarea | PostContentImage | PostContentVideo | PostContentList;
|
|
345
|
+
type PostContentFormData = {
|
|
346
|
+
contentData?: PostContentData | null;
|
|
347
|
+
contentOrder?: number | null;
|
|
348
|
+
contentType?: EnumPostContentType | null;
|
|
349
|
+
};
|
|
350
|
+
interface PostFormData {
|
|
351
|
+
active: boolean;
|
|
352
|
+
caption: string;
|
|
353
|
+
content: PostContentFormData[];
|
|
354
|
+
cover?: ResourceImageType | null;
|
|
355
|
+
coverUpload?: PostFileInput | null;
|
|
356
|
+
postType: EnumPostType;
|
|
357
|
+
resource?: {
|
|
358
|
+
resourceId: string;
|
|
359
|
+
resourceType: EnumResourceType;
|
|
360
|
+
resourceRegion: string;
|
|
361
|
+
} | null;
|
|
362
|
+
tags?: string[] | null;
|
|
363
|
+
title: string;
|
|
364
|
+
notifyUsers?: boolean | null;
|
|
365
|
+
}
|
|
366
|
+
type CreatePostFormData = CreateFormData<PostFormData>;
|
|
367
|
+
type PostContentType = Omit<PostContentFormData, "contentData"> & {
|
|
368
|
+
contentData: Omit<PostContentData, "imagesUpload">;
|
|
369
|
+
};
|
|
370
|
+
type PostType = Omit<PostFormData, "content" | "coverUpload"> & {
|
|
371
|
+
_id: string;
|
|
372
|
+
content: PostContentType[];
|
|
373
|
+
createdAt: Date;
|
|
374
|
+
deletedAt: Date | null;
|
|
375
|
+
updatedAt: Date | null;
|
|
376
|
+
};
|
|
377
|
+
|
|
103
378
|
type VendorCalendarData = Omit<ResourceDetails, "dateTime" | "eventStatus"> & {
|
|
104
379
|
dateTime: DateTimeType;
|
|
105
380
|
};
|
|
@@ -294,6 +569,10 @@ type BaseResourceType = Omit<BaseResourceTypeFormData, "_id" | "coverUpload" | "
|
|
|
294
569
|
rating?: number | null;
|
|
295
570
|
reviewCount?: number | null;
|
|
296
571
|
updatedAt: Date | null;
|
|
572
|
+
relatedPost?: {
|
|
573
|
+
postId: string;
|
|
574
|
+
postType: EnumPostType;
|
|
575
|
+
} | null;
|
|
297
576
|
};
|
|
298
577
|
type LocationGeoType = {
|
|
299
578
|
coordinates: number[];
|
|
@@ -400,4 +679,4 @@ interface UseGetResourcesByRegionOptions {
|
|
|
400
679
|
offset?: number;
|
|
401
680
|
}
|
|
402
681
|
|
|
403
|
-
export { type
|
|
682
|
+
export { type GameType as $, type AssociateType as A, type BaseResourceTypeFormData as B, type Category as C, type CreateFormData as D, type EventType as E, type FormField as F, type GameDocType as G, type DailyClueBaseGame as H, type DailyClueGameData as I, type DateTimeType as J, type DateTimeWithPriceType as K, type LocationType as L, type DeviceInfo as M, EnumGameStatus as N, type OptionItem as O, type PostType as P, EnumGameType as Q, type RefundPolicy as R, type StallType as S, EnumPostContentType as T, type UseGetResourcesByRegionOptions as U, type VendorType as V, type EventStatusType as W, type GameDate as X, type GameHistory as Y, type GamePlacement as Z, type GamePlacementClue as _, type FormDateField as a, type GeocodeLocation as a0, type GlobalGameData as a1, type ImageObjectType as a2, type LocationGeoType as a3, type Nullable as a4, type OwnerType as a5, PROMO_CODE_PREFIX as a6, type PaymentInfoType as a7, type PostContentData as a8, type PostContentFormData as a9, type VendorCalendarData as aA, type VendorProductList as aB, gameScreenIdentifierList as aC, gameTypeToDisplayName as aD, type PostContentGame as aa, type PostContentImage as ab, type PostContentList as ac, type PostContentTextarea as ad, type PostContentType as ae, type PostContentVideo as af, type PostFileInput as ag, type PosterUsageType as ah, type PromoCodeType as ai, type PuzzleAnswer as aj, type PuzzleAnsweredQuestion as ak, type PuzzleBaseGame as al, type PuzzleGameData as am, type PuzzleQuestion as an, type Region as ao, type RelationDate as ap, type RelationInputType as aq, type ResourceContactDetailsType as ar, type ResourceDetails as as, type ResourceImageType as at, type SocialMediaType as au, type Subcategory as av, type SubcategoryItems as aw, type TermsAgreement as ax, type UnregisteredVendorInvitationType as ay, type VendorAttributes as az, type Requirement as b, type EventListItemType as c, type EventInfoType as d, type RelationType as e, type ResourceConnectionsType as f, type UnregisteredVendorType as g, type VendorInfoType as h, type UserLicenceType as i, EnumPostType as j, type GameLeaderboard as k, type VendorFormData as l, type CreateVendorFormData as m, type VendorInfoFormData as n, type CreateVendorInfoFormData as o, type UnregisteredVendorFormData as p, type CreateUnregisteredVendorFormData as q, type EventFormData as r, type CreateEventFormData as s, type EventInfoFormData as t, type CreateEventInfoFormData as u, type PostFormData as v, type CreatePostFormData as w, type BaseGameMap as x, type BaseGameType as y, type BaseResourceType as z };
|
|
@@ -100,6 +100,281 @@ type EventInfoType = Omit<EventInfoFormData, "_id"> & {
|
|
|
100
100
|
active?: boolean;
|
|
101
101
|
};
|
|
102
102
|
|
|
103
|
+
declare enum EnumGameType {
|
|
104
|
+
DAILY_CLUE = "dailyClue",
|
|
105
|
+
MINI_QUIZ = "miniQuiz",
|
|
106
|
+
ODD_ONE_OUT = "oddOneOut"
|
|
107
|
+
}
|
|
108
|
+
type GameDate = {
|
|
109
|
+
startDate: Date;
|
|
110
|
+
endDate: Date;
|
|
111
|
+
};
|
|
112
|
+
declare const gameTypeToDisplayName: Record<EnumGameType, string>;
|
|
113
|
+
type GlobalGameData = {
|
|
114
|
+
points: number;
|
|
115
|
+
streak: number;
|
|
116
|
+
};
|
|
117
|
+
|
|
118
|
+
declare const gameScreenIdentifierList: readonly [{
|
|
119
|
+
readonly clue: "Where your actions turn into a timeline.";
|
|
120
|
+
readonly id: "activities";
|
|
121
|
+
readonly match: "/profile/activities";
|
|
122
|
+
}, {
|
|
123
|
+
readonly clue: "Where conversations happen without speaking.";
|
|
124
|
+
readonly id: "chat";
|
|
125
|
+
readonly match: "/profile/chat";
|
|
126
|
+
}, {
|
|
127
|
+
readonly clue: "The place to redefine who you are.";
|
|
128
|
+
readonly id: "edit-profile";
|
|
129
|
+
readonly match: "/profile/edit-profile";
|
|
130
|
+
}, {
|
|
131
|
+
readonly clue: "A single moment worth showing up for.";
|
|
132
|
+
readonly id: "single-event";
|
|
133
|
+
readonly match: RegExp;
|
|
134
|
+
}, {
|
|
135
|
+
readonly clue: "What’s happening around you, right now.";
|
|
136
|
+
readonly id: "events-near-me";
|
|
137
|
+
readonly match: "/events/events-near-me";
|
|
138
|
+
}, {
|
|
139
|
+
readonly clue: "Where events appear as pins on a map.";
|
|
140
|
+
readonly id: "events-map";
|
|
141
|
+
readonly match: "/events/events-map";
|
|
142
|
+
}, {
|
|
143
|
+
readonly clue: "A collection of events worth attending.";
|
|
144
|
+
readonly id: "events";
|
|
145
|
+
readonly match: "/events";
|
|
146
|
+
}, {
|
|
147
|
+
readonly clue: "What’s happening in a wider area — not just nearby.";
|
|
148
|
+
readonly id: "events-region";
|
|
149
|
+
readonly match: RegExp;
|
|
150
|
+
}, {
|
|
151
|
+
readonly clue: "Where fun becomes a challenge.";
|
|
152
|
+
readonly id: "games";
|
|
153
|
+
readonly match: "/games";
|
|
154
|
+
}, {
|
|
155
|
+
readonly clue: "Your starting point for everything.";
|
|
156
|
+
readonly id: "home";
|
|
157
|
+
readonly match: "/";
|
|
158
|
+
}, {
|
|
159
|
+
readonly clue: "Where the app whispers what you shouldn’t miss.";
|
|
160
|
+
readonly id: "notifications";
|
|
161
|
+
readonly match: "/notifications";
|
|
162
|
+
}, {
|
|
163
|
+
readonly clue: "Where you fine-tune your experience.";
|
|
164
|
+
readonly id: "options";
|
|
165
|
+
readonly match: "/options";
|
|
166
|
+
}, {
|
|
167
|
+
readonly clue: "An organisation or creator supporting the community.";
|
|
168
|
+
readonly id: "single-partner";
|
|
169
|
+
readonly match: RegExp;
|
|
170
|
+
}, {
|
|
171
|
+
readonly clue: "Organisations and creators supporting the community.";
|
|
172
|
+
readonly id: "partners";
|
|
173
|
+
readonly match: "/partners";
|
|
174
|
+
}, {
|
|
175
|
+
readonly clue: "A single published post in full view.";
|
|
176
|
+
readonly id: "single-visitor-post";
|
|
177
|
+
readonly match: RegExp;
|
|
178
|
+
}, {
|
|
179
|
+
readonly clue: "Your identity, on display.";
|
|
180
|
+
readonly id: "profile";
|
|
181
|
+
readonly match: "/profile";
|
|
182
|
+
}, {
|
|
183
|
+
readonly clue: "One stallholder offering something valuable.";
|
|
184
|
+
readonly id: "single-vendor";
|
|
185
|
+
readonly match: RegExp;
|
|
186
|
+
}, {
|
|
187
|
+
readonly clue: "Where every stallholder waits under the right category.";
|
|
188
|
+
readonly id: "vendors";
|
|
189
|
+
readonly match: "/vendors";
|
|
190
|
+
}, {
|
|
191
|
+
readonly clue: "Where you browse articles and posts from around the platform.";
|
|
192
|
+
readonly id: "visitors";
|
|
193
|
+
readonly match: "/visitors";
|
|
194
|
+
}];
|
|
195
|
+
type GamePlacement = (typeof gameScreenIdentifierList)[number]["id"];
|
|
196
|
+
type GamePlacementClue = (typeof gameScreenIdentifierList)[number]["clue"];
|
|
197
|
+
type DailyClueBaseGame = {
|
|
198
|
+
gameDate: GameDate;
|
|
199
|
+
gameSolution: string;
|
|
200
|
+
};
|
|
201
|
+
type DailyClueGameData = GlobalGameData & {
|
|
202
|
+
gameFields: DailyClueBaseGame;
|
|
203
|
+
lastFoundDate: Date | null;
|
|
204
|
+
letterInfo: {
|
|
205
|
+
collected: string[] | null;
|
|
206
|
+
solutionShuffled: string[];
|
|
207
|
+
todaysClue: GamePlacementClue | null;
|
|
208
|
+
todaysLetter: string | null;
|
|
209
|
+
todaysPlacement: GamePlacement | null;
|
|
210
|
+
};
|
|
211
|
+
};
|
|
212
|
+
|
|
213
|
+
type PuzzleAnswer = {
|
|
214
|
+
answerId: string;
|
|
215
|
+
answer: string;
|
|
216
|
+
correct: boolean;
|
|
217
|
+
};
|
|
218
|
+
type PuzzleQuestion = {
|
|
219
|
+
answers: PuzzleAnswer[];
|
|
220
|
+
question: string;
|
|
221
|
+
questionId: string;
|
|
222
|
+
};
|
|
223
|
+
/**
|
|
224
|
+
* Stores only the answerId and the questionId of the selected answer.
|
|
225
|
+
*/
|
|
226
|
+
type PuzzleAnsweredQuestion = {
|
|
227
|
+
selectedAnswerId: string;
|
|
228
|
+
questionId: string;
|
|
229
|
+
};
|
|
230
|
+
type PuzzleBaseGame = {
|
|
231
|
+
questions: PuzzleQuestion[];
|
|
232
|
+
};
|
|
233
|
+
type PuzzleGameData = GlobalGameData & {
|
|
234
|
+
gameFields: PuzzleBaseGame;
|
|
235
|
+
/**
|
|
236
|
+
* Stores user answers only.
|
|
237
|
+
* Never store correctness from client.
|
|
238
|
+
*/
|
|
239
|
+
answeredQuestions: PuzzleAnsweredQuestion[];
|
|
240
|
+
};
|
|
241
|
+
|
|
242
|
+
type BaseGameMap = {
|
|
243
|
+
[EnumGameType.DAILY_CLUE]: DailyClueBaseGame;
|
|
244
|
+
[EnumGameType.MINI_QUIZ]: PuzzleBaseGame;
|
|
245
|
+
[EnumGameType.ODD_ONE_OUT]: PuzzleBaseGame;
|
|
246
|
+
};
|
|
247
|
+
type BaseGameType = {
|
|
248
|
+
gameType: EnumGameType;
|
|
249
|
+
gameTypeId: string;
|
|
250
|
+
gameTitle: string;
|
|
251
|
+
} & {
|
|
252
|
+
[K in keyof BaseGameMap]?: BaseGameMap[K] | null;
|
|
253
|
+
};
|
|
254
|
+
declare enum EnumGameStatus {
|
|
255
|
+
GAME_COMPLETED = "GAME_COMPLETED",
|
|
256
|
+
GAME_IN_PROGRESS = "GAME_IN_PROGRESS",
|
|
257
|
+
GAME_LEFT = "GAME_LEFT",
|
|
258
|
+
GAME_STARTED = "GAME_STARTED"
|
|
259
|
+
}
|
|
260
|
+
type GameHistory = Pick<BaseGameType, "gameTitle" | "gameType" | "gameTypeId"> & {
|
|
261
|
+
createdAt: Date;
|
|
262
|
+
gameDate: GameDate;
|
|
263
|
+
gameStatus: EnumGameStatus;
|
|
264
|
+
/** Per-event delta. Not persisted for overallGamePoints (computed at read time). */
|
|
265
|
+
pointsEarned: number;
|
|
266
|
+
/** Running total for this game instance; computed at read time, not stored in Mongo. */
|
|
267
|
+
overallGamePoints?: number;
|
|
268
|
+
};
|
|
269
|
+
type GameDataMap = {
|
|
270
|
+
[EnumGameType.DAILY_CLUE]: DailyClueGameData;
|
|
271
|
+
[EnumGameType.MINI_QUIZ]: PuzzleGameData;
|
|
272
|
+
[EnumGameType.ODD_ONE_OUT]: PuzzleGameData;
|
|
273
|
+
};
|
|
274
|
+
type GameDataType = {
|
|
275
|
+
[K in keyof GameDataMap]?: GameDataMap[K] | null;
|
|
276
|
+
};
|
|
277
|
+
type GameType = Pick<BaseGameType, "gameTitle" | "gameType" | "gameTypeId"> & {
|
|
278
|
+
_id: string;
|
|
279
|
+
active: boolean;
|
|
280
|
+
createdAt: Date;
|
|
281
|
+
gameData: GameDataType;
|
|
282
|
+
gameHistory: GameHistory[] | null;
|
|
283
|
+
updatedAt: Date | null;
|
|
284
|
+
};
|
|
285
|
+
type GameDocType = {
|
|
286
|
+
_id: string;
|
|
287
|
+
active: boolean;
|
|
288
|
+
createdAt: Date;
|
|
289
|
+
deletedAt: Date | null;
|
|
290
|
+
games: GameType[] | null;
|
|
291
|
+
owner: OwnerType;
|
|
292
|
+
points: number;
|
|
293
|
+
updatedAt: Date | null;
|
|
294
|
+
};
|
|
295
|
+
type GameLeaderboard = {
|
|
296
|
+
gameHistory: GameHistory[] | null;
|
|
297
|
+
overallPoints: number;
|
|
298
|
+
owner: OwnerType;
|
|
299
|
+
};
|
|
300
|
+
|
|
301
|
+
declare enum EnumPostType {
|
|
302
|
+
MARKET_FACES = "market_faces",
|
|
303
|
+
CLUE_BITES = "clue_bites",
|
|
304
|
+
PLAY_AND_WIN = "play_and_win"
|
|
305
|
+
}
|
|
306
|
+
declare enum EnumPostContentType {
|
|
307
|
+
GAME = "game",
|
|
308
|
+
IMAGE = "image",
|
|
309
|
+
LIST = "list",
|
|
310
|
+
TEXTAREA = "textarea",
|
|
311
|
+
VIDEO = "video"
|
|
312
|
+
}
|
|
313
|
+
type PostFileInput = {
|
|
314
|
+
source: File;
|
|
315
|
+
title?: string;
|
|
316
|
+
};
|
|
317
|
+
type PostContentTextarea = {
|
|
318
|
+
textarea: {
|
|
319
|
+
title?: string;
|
|
320
|
+
data: string;
|
|
321
|
+
};
|
|
322
|
+
};
|
|
323
|
+
type PostContentImage = {
|
|
324
|
+
images: ResourceImageType[] | null;
|
|
325
|
+
imagesUpload?: PostFileInput[] | null;
|
|
326
|
+
};
|
|
327
|
+
type PostContentVideo = {
|
|
328
|
+
video: {
|
|
329
|
+
source: string;
|
|
330
|
+
title?: string;
|
|
331
|
+
};
|
|
332
|
+
};
|
|
333
|
+
type PostContentList = {
|
|
334
|
+
list: {
|
|
335
|
+
title?: string;
|
|
336
|
+
items: {
|
|
337
|
+
text: string;
|
|
338
|
+
}[];
|
|
339
|
+
};
|
|
340
|
+
};
|
|
341
|
+
type PostContentGame = {
|
|
342
|
+
game: BaseGameType;
|
|
343
|
+
};
|
|
344
|
+
type PostContentData = PostContentGame | PostContentTextarea | PostContentImage | PostContentVideo | PostContentList;
|
|
345
|
+
type PostContentFormData = {
|
|
346
|
+
contentData?: PostContentData | null;
|
|
347
|
+
contentOrder?: number | null;
|
|
348
|
+
contentType?: EnumPostContentType | null;
|
|
349
|
+
};
|
|
350
|
+
interface PostFormData {
|
|
351
|
+
active: boolean;
|
|
352
|
+
caption: string;
|
|
353
|
+
content: PostContentFormData[];
|
|
354
|
+
cover?: ResourceImageType | null;
|
|
355
|
+
coverUpload?: PostFileInput | null;
|
|
356
|
+
postType: EnumPostType;
|
|
357
|
+
resource?: {
|
|
358
|
+
resourceId: string;
|
|
359
|
+
resourceType: EnumResourceType;
|
|
360
|
+
resourceRegion: string;
|
|
361
|
+
} | null;
|
|
362
|
+
tags?: string[] | null;
|
|
363
|
+
title: string;
|
|
364
|
+
notifyUsers?: boolean | null;
|
|
365
|
+
}
|
|
366
|
+
type CreatePostFormData = CreateFormData<PostFormData>;
|
|
367
|
+
type PostContentType = Omit<PostContentFormData, "contentData"> & {
|
|
368
|
+
contentData: Omit<PostContentData, "imagesUpload">;
|
|
369
|
+
};
|
|
370
|
+
type PostType = Omit<PostFormData, "content" | "coverUpload"> & {
|
|
371
|
+
_id: string;
|
|
372
|
+
content: PostContentType[];
|
|
373
|
+
createdAt: Date;
|
|
374
|
+
deletedAt: Date | null;
|
|
375
|
+
updatedAt: Date | null;
|
|
376
|
+
};
|
|
377
|
+
|
|
103
378
|
type VendorCalendarData = Omit<ResourceDetails, "dateTime" | "eventStatus"> & {
|
|
104
379
|
dateTime: DateTimeType;
|
|
105
380
|
};
|
|
@@ -294,6 +569,10 @@ type BaseResourceType = Omit<BaseResourceTypeFormData, "_id" | "coverUpload" | "
|
|
|
294
569
|
rating?: number | null;
|
|
295
570
|
reviewCount?: number | null;
|
|
296
571
|
updatedAt: Date | null;
|
|
572
|
+
relatedPost?: {
|
|
573
|
+
postId: string;
|
|
574
|
+
postType: EnumPostType;
|
|
575
|
+
} | null;
|
|
297
576
|
};
|
|
298
577
|
type LocationGeoType = {
|
|
299
578
|
coordinates: number[];
|
|
@@ -400,4 +679,4 @@ interface UseGetResourcesByRegionOptions {
|
|
|
400
679
|
offset?: number;
|
|
401
680
|
}
|
|
402
681
|
|
|
403
|
-
export { type
|
|
682
|
+
export { type GameType as $, type AssociateType as A, type BaseResourceTypeFormData as B, type Category as C, type CreateFormData as D, type EventType as E, type FormField as F, type GameDocType as G, type DailyClueBaseGame as H, type DailyClueGameData as I, type DateTimeType as J, type DateTimeWithPriceType as K, type LocationType as L, type DeviceInfo as M, EnumGameStatus as N, type OptionItem as O, type PostType as P, EnumGameType as Q, type RefundPolicy as R, type StallType as S, EnumPostContentType as T, type UseGetResourcesByRegionOptions as U, type VendorType as V, type EventStatusType as W, type GameDate as X, type GameHistory as Y, type GamePlacement as Z, type GamePlacementClue as _, type FormDateField as a, type GeocodeLocation as a0, type GlobalGameData as a1, type ImageObjectType as a2, type LocationGeoType as a3, type Nullable as a4, type OwnerType as a5, PROMO_CODE_PREFIX as a6, type PaymentInfoType as a7, type PostContentData as a8, type PostContentFormData as a9, type VendorCalendarData as aA, type VendorProductList as aB, gameScreenIdentifierList as aC, gameTypeToDisplayName as aD, type PostContentGame as aa, type PostContentImage as ab, type PostContentList as ac, type PostContentTextarea as ad, type PostContentType as ae, type PostContentVideo as af, type PostFileInput as ag, type PosterUsageType as ah, type PromoCodeType as ai, type PuzzleAnswer as aj, type PuzzleAnsweredQuestion as ak, type PuzzleBaseGame as al, type PuzzleGameData as am, type PuzzleQuestion as an, type Region as ao, type RelationDate as ap, type RelationInputType as aq, type ResourceContactDetailsType as ar, type ResourceDetails as as, type ResourceImageType as at, type SocialMediaType as au, type Subcategory as av, type SubcategoryItems as aw, type TermsAgreement as ax, type UnregisteredVendorInvitationType as ay, type VendorAttributes as az, type Requirement as b, type EventListItemType as c, type EventInfoType as d, type RelationType as e, type ResourceConnectionsType as f, type UnregisteredVendorType as g, type VendorInfoType as h, type UserLicenceType as i, EnumPostType as j, type GameLeaderboard as k, type VendorFormData as l, type CreateVendorFormData as m, type VendorInfoFormData as n, type CreateVendorInfoFormData as o, type UnregisteredVendorFormData as p, type CreateUnregisteredVendorFormData as q, type EventFormData as r, type CreateEventFormData as s, type EventInfoFormData as t, type CreateEventInfoFormData as u, type PostFormData as v, type CreatePostFormData as w, type BaseGameMap as x, type BaseGameType as y, type BaseResourceType as z };
|