@timardex/cluemart-shared 1.5.770 → 1.5.772

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 (50) hide show
  1. package/dist/{ad-6PrFQe2t.d.ts → ad-CVkVX_z5.d.ts} +3 -7
  2. package/dist/{ad-B8ZWiTsv.d.mts → ad-DA9ECAhK.d.mts} +3 -7
  3. package/dist/affiliate-1RtkLnLP.d.ts +35 -0
  4. package/dist/affiliate-Cos2Syz5.d.mts +35 -0
  5. package/dist/{chunk-VO2WRHJV.mjs → chunk-KJZFJ3LH.mjs} +95 -12
  6. package/dist/chunk-KJZFJ3LH.mjs.map +1 -0
  7. package/dist/{chunk-HASLOIIM.mjs → chunk-MVQ3CFQR.mjs} +11 -2
  8. package/dist/chunk-MVQ3CFQR.mjs.map +1 -0
  9. package/dist/{chunk-UJ7L64JJ.mjs → chunk-RKIRWZCH.mjs} +2 -2
  10. package/dist/{chunk-HCOZUNCK.mjs → chunk-TAECMXM4.mjs} +37 -2
  11. package/dist/chunk-TAECMXM4.mjs.map +1 -0
  12. package/dist/{chunk-CXXQBRXS.mjs → chunk-ZZJSCYJK.mjs} +2 -2
  13. package/dist/formFields/index.cjs +21 -0
  14. package/dist/formFields/index.cjs.map +1 -1
  15. package/dist/formFields/index.mjs +3 -3
  16. package/dist/graphql/index.cjs +95 -10
  17. package/dist/graphql/index.cjs.map +1 -1
  18. package/dist/graphql/index.d.mts +20 -2
  19. package/dist/graphql/index.d.ts +20 -2
  20. package/dist/graphql/index.mjs +5 -1
  21. package/dist/hooks/index.cjs +84 -10
  22. package/dist/hooks/index.cjs.map +1 -1
  23. package/dist/hooks/index.d.mts +1 -1
  24. package/dist/hooks/index.d.ts +1 -1
  25. package/dist/hooks/index.mjs +5 -5
  26. package/dist/index.cjs +143 -10
  27. package/dist/index.cjs.map +1 -1
  28. package/dist/index.d.mts +78 -6
  29. package/dist/index.d.ts +78 -6
  30. package/dist/index.mjs +136 -10
  31. package/dist/index.mjs.map +1 -1
  32. package/dist/sharing/index.cjs +21 -0
  33. package/dist/sharing/index.cjs.map +1 -1
  34. package/dist/sharing/index.mjs +3 -3
  35. package/dist/types/index.cjs +10 -0
  36. package/dist/types/index.cjs.map +1 -1
  37. package/dist/types/index.d.mts +2 -1
  38. package/dist/types/index.d.ts +2 -1
  39. package/dist/types/index.mjs +3 -1
  40. package/dist/utils/index.cjs +41 -0
  41. package/dist/utils/index.cjs.map +1 -1
  42. package/dist/utils/index.d.mts +30 -1
  43. package/dist/utils/index.d.ts +30 -1
  44. package/dist/utils/index.mjs +10 -2
  45. package/package.json +1 -1
  46. package/dist/chunk-HASLOIIM.mjs.map +0 -1
  47. package/dist/chunk-HCOZUNCK.mjs.map +0 -1
  48. package/dist/chunk-VO2WRHJV.mjs.map +0 -1
  49. /package/dist/{chunk-UJ7L64JJ.mjs.map → chunk-RKIRWZCH.mjs.map} +0 -0
  50. /package/dist/{chunk-CXXQBRXS.mjs.map → chunk-ZZJSCYJK.mjs.map} +0 -0
package/dist/index.d.mts CHANGED
@@ -1031,13 +1031,9 @@ type RedeemedReward = {
1031
1031
  pointsUsed: number;
1032
1032
  redeemedAt: Date;
1033
1033
  };
1034
- type AffiliateType = {
1035
- affiliateCode: PromoCodeType;
1036
- pointsAvailable: number;
1037
- };
1038
1034
  type UserType = Omit<UserFormData, "confirmPassword" | "avatarUpload" | "_id"> & {
1039
1035
  _id: string;
1040
- affiliate?: AffiliateType | null;
1036
+ affiliate?: string | null;
1041
1037
  associates?: AssociateType[] | null;
1042
1038
  createdAt: Date;
1043
1039
  deletedAt: Date | null;
@@ -1458,6 +1454,37 @@ declare const TIER_DISPLAY_LABELS: Record<Tier, string>;
1458
1454
  /** Maps licence enums to their canonical tier key. */
1459
1455
  declare const TIER_FROM_LICENCE: Record<EnumUserLicence, Tier>;
1460
1456
 
1457
+ declare enum EnumAffiliateRewardType {
1458
+ NEW_EVENT_REGISTRATION = "NEW_EVENT_REGISTRATION",
1459
+ NEW_VENDOR_REGISTRATION = "NEW_VENDOR_REGISTRATION",
1460
+ NEW_PARTNER_REGISTRATION = "NEW_PARTNER_REGISTRATION"
1461
+ }
1462
+ type AffiliateReward = {
1463
+ createdAt: Date;
1464
+ deletedAt: Date | null;
1465
+ redeemedAt: Date | null;
1466
+ rewardDescription: string;
1467
+ rewardType: EnumAffiliateRewardType;
1468
+ rewardValue: number;
1469
+ updatedAt: Date | null;
1470
+ };
1471
+ type AffiliateResourceType = {
1472
+ resourceActive: boolean;
1473
+ resourceId: string;
1474
+ resourceType: EnumResourceType;
1475
+ rewards: AffiliateReward[];
1476
+ };
1477
+ type AffiliateType = {
1478
+ _id: string;
1479
+ affiliateCode: PromoCodeType;
1480
+ affiliateResources: AffiliateResourceType[];
1481
+ createdAt: Date;
1482
+ deletedAt: Date | null;
1483
+ overallPoints: number;
1484
+ owner: OwnerType;
1485
+ updatedAt: Date | null;
1486
+ };
1487
+
1461
1488
  declare const vendorElectricity: {
1462
1489
  details: FormField;
1463
1490
  isRequired: FormField;
@@ -2677,6 +2704,23 @@ declare const useGetSchool: (_id: string) => {
2677
2704
  school: SchoolReturnType | null;
2678
2705
  };
2679
2706
 
2707
+ declare const useGetAffiliate: (_id: string) => {
2708
+ affiliate: AffiliateType | undefined;
2709
+ error: _apollo_client.ApolloError | undefined;
2710
+ loading: boolean;
2711
+ refetch: (variables?: Partial<_apollo_client.OperationVariables> | undefined) => Promise<_apollo_client.ApolloQueryResult<{
2712
+ affiliate: AffiliateType;
2713
+ }>>;
2714
+ };
2715
+ declare const useGetAffiliates: () => {
2716
+ affiliates: AffiliateType[];
2717
+ error: _apollo_client.ApolloError | undefined;
2718
+ loading: boolean;
2719
+ refetch: (variables?: Partial<_apollo_client.OperationVariables> | undefined) => Promise<_apollo_client.ApolloQueryResult<{
2720
+ affiliates: AffiliateType[];
2721
+ }>>;
2722
+ };
2723
+
2680
2724
  /** Minimal event fields for public (market) share copy — matches in-app preview. */
2681
2725
  type ShareEventForPublic = {
2682
2726
  description?: string | null;
@@ -2980,6 +3024,34 @@ declare const rewardNiceNames: Record<EnumReward, {
2980
3024
  points: number;
2981
3025
  }>;
2982
3026
  declare const PostTypeLabels: Record<EnumPostType, string>;
3027
+ /** Hardcoded promo; compared to trimmed + uppercased registration input. */
3028
+ declare const CM_SCHOOL_PROMO_CODE = "CM-SCHOOL";
3029
+ declare const CM_AFFILIATE_PROMO_CODE = "CM-AFFILIATE";
3030
+
3031
+ declare const AFFILIATE_REWARDS: {
3032
+ NEW_EVENT_REGISTRATION: {
3033
+ description: string;
3034
+ value: number;
3035
+ };
3036
+ NEW_VENDOR_REGISTRATION: {
3037
+ description: string;
3038
+ value: number;
3039
+ };
3040
+ NEW_PARTNER_REGISTRATION: {
3041
+ description: string;
3042
+ value: number;
3043
+ };
3044
+ };
3045
+ /**
3046
+ * Create an affiliate reward
3047
+ * @param rewardType - The type of reward
3048
+ * @param receivedAt - The date the reward was received
3049
+ * @returns The affiliate reward
3050
+ * @example
3051
+ * const reward = createAffiliateReward(EnumAffiliateRewardType.NEW_EVENT_REGISTRATION, new Date());
3052
+ * console.log(reward);
3053
+ */
3054
+ declare function createAffiliateReward(rewardType: EnumAffiliateRewardType, createdAt: Date): AffiliateReward;
2983
3055
 
2984
3056
  /**
2985
3057
  * Loose input shape for normalization helpers. Callers often pass partial or legacy
@@ -3064,4 +3136,4 @@ declare function getVendorEventRelationStartDates(events: EventListItemType[] |
3064
3136
  declare function getVendorEventRelationDateOptions(events: EventListItemType[] | null | undefined): StallholderFilterOption[];
3065
3137
  declare function getVendorEventsEmptyMessage(): string;
3066
3138
 
3067
- export { ANDROID_URL, type AdFormData, type AdFormState, type AdResource, type AdType, type AdminUpdateResourceType, type AffiliateType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type AuthPayloadType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, CLUEMART_MAIN_DOMAIN_URL, type CalendarSheetContentData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, type CreateAdFormState, type CreateAppSettingsFormData, type CreateBulkNotificationInput, type CreateContactUsFormData, type CreateEventFormData, type CreateEventInfoFormData, type CreateFormData, type CreateLoginFormData, type CreatePartnerFormData, type CreatePostFormData, type CreateRegisterFormData, type CreateRequestPasswordResetFormData, type CreateResetPasswordFormData, type CreateSchoolFormData, type CreateUnregisteredVendorFormData, type CreateUserFormData, type CreateValidateVerificationTokenFormData, type CreateVendorFormData, type CreateVendorInfoFormData, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, EVENT_DATE_STATUS_PERIOD_MAP, EnumActivity, EnumAdShowOn, EnumAdStatus, EnumAdStyle, EnumAdType, EnumBillingPeriod, EnumChatReportReason, EnumChatType, EnumEventDateStatus, EnumEventType, EnumFoodFlavor, EnumFoodType, EnumGameStatus, EnumGameType, EnumInviteStatus, EnumNotificationResourceType, EnumNotificationType, EnumOSPlatform, EnumPartnerType, EnumPaymentMethod, EnumPostContentType, EnumPostType, EnumRegions, EnumRelationResource, EnumResourceType, EnumReward, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStatusType, type EventType, type FormDateField, type FormField, GET_EVENT, GET_EVENT_BY_SLUG, GET_EVENT_INFO, GET_PARTNER, GET_PARTNER_BY_SLUG, GET_POST, GET_POST_BY_SLUG, GET_RESOURCE_CONNECTIONS, GET_VENDOR, GET_VENDOR_BY_SLUG, GET_VENDOR_INFO, type GameDate, type GameDocType, type GameHistory, type GameLeaderboard, type GamePlacement, type GamePlacementClue, type GameType, type GeocodeLocation, type GlobalGameData, type GoogleAddressComponent, type GoogleImportedMarket, IMAGE_EXTENSION, IOS_URL, type IconBasename, type IconId, type ImageObjectType, ImageTypeEnum, KNOWN_EVENT_SCHEDULE_STATUSES, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type NotificationCount, type NotificationDataType, type NotificationType, type Nullable, OG_DESCRIPTION_LINE_BREAK, type OptionItem, type OtherImagesBasename, type OtherImagesId, type OwnerType, POST_SHARE_RESOURCE_TYPES, PROMO_CODE_PREFIX, PUBLIC_SHARE_PATH_TYPES, type ParticipantType, type PartnerFormData, type PartnerType, type PaymentInfoType, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostResource, type PostShareResourceType, type PostType, PostTypeLabels, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, type PushTokenType, type PuzzleAnswer, type PuzzleAnsweredQuestion, type PuzzleBaseGame, type PuzzleGameData, type PuzzleQuestion, RELATION_OVERLAY_LAYOUT_VERSION, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, type RedeemRewardInput, type RedeemRewardResponse, type RedeemedReward, type RefreshTokenPayloadType, type RefundPolicy, type Region, type RegisterFormData, type RelatedPostType, type RelationDate, type RelationInputType, type RelationSharePathType, type RelationShareResourceType, type RelationType$1 as RelationType, type ReportChatUser, type RequestPasswordResetFormData, type Requirement, type ResetPasswordFormData, type ResourceActivityEntry, type ResourceActivityInputType, type ResourceActivityType, type ResourceByUser, type ResourceConnectionsType, type ResourceContactDetailsType, type ResourceDetails, type ResourceImageType, type ResourceShareType, SAVED_EMAIL_KEY, SAVED_PASSWORD_KEY, SAVED_REFRESH_TOKEN_KEY, SAVED_TOKEN_KEY, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, SHARE_APPLICATION_DEADLINE_PREFIX, SHARE_CALENDAR_ICON, SHARE_CATEGORIES_SECTION_HEADING, SHARE_CATEGORY_ICON, SHARE_CHECKMARK_ICON, SHARE_CLOCK_ICON, SHARE_COMPLIANCE_PREFIX, SHARE_DESCRIPTION_SECTION_BREAK, SHARE_DOLLAR_ICON, SHARE_FOOD_TRUCK_LINE, SHARE_INFO_ICON, SHARE_MARKET_DATES_SECTION_HEADING, SHARE_MORE_INFO_LINE, SHARE_PRICE_RANGE_PREFIX, SHARE_RAIN_OR_SHINE_LINE, SHARE_REQUIREMENTS_SECTION_HEADING, SHARE_RESOURCE_LABEL, SHARE_RULER_ICON, SHARE_SITE_URL, SHARE_STALL_SIZE_PREFIX, SHARE_TAGS_SECTION_HEADING, SHARE_TYPE_PATH_REGEX, SOCIAL_IMAGE_HEIGHT, SOCIAL_IMAGE_WIDTH, type SafeUserType, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventForInvitation, type ShareEventForPublic, type ShareEventInfoForInvitation, type ShareMessageFooterPlacement, type ShareResourceType, type ShareSlugResource, type ShareType, type ShareVendorForApplication, type ShareVendorForPublic, type ShareVendorInfoForApplication, type SocialMediaType, type SocialShareResourceType, type StallType, type StallholderFilterOption, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, TIERS_BY_PRIORITY, TIER_DISPLAY_LABELS, TIER_FROM_LICENCE, type TermsAgreement, type Tier, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetResourcesByRegionOptions, type UserActivity, type UserActivityEvent, type UserFormData, type UserLicenceType, type UserType, type ValidateVerificationTokenFormData, type VendorAttributes, type VendorCalendarData, type VendorFormData, type VendorInfoFormData, type VendorInfoType, type VendorProductList, type VendorType, appendShareMoreInfoLine, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildCalendarSheetContentData, buildFacebookShareQuote, buildInvitationShareDescription, buildPublicEventShareDescription, buildPublicVendorShareDescription, buildShareMessageSections, buildShareOgDescription, buildShareOgDescriptionFromSections, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, collectStallholderStartDates, collectVendorEventRelationDateTimes, companyContactFields, computeDailyClueState, contactUsFields, darkColors, dateFormat, emailField, eventBasicInfoFields, eventEndDateFields, eventHasSelectedDate, eventInfo, eventInfoPaymentInfo, eventMatchesDateStatusPeriod, eventStartDateFields, eventStartDatesSet, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareApplicationCategoriesSection, formatShareApplicationComplianceSection, formatShareApplicationPriceRangeLine, formatShareApplicationStallSizeLine, formatShareInvitationApplicationDeadlineLine, formatShareInvitationMarketDatesSection, formatShareInvitationRequirementsSection, formatShareIsFoodTrueLine, formatShareMarketDate, formatShareRainOrShineLine, formatShareStallLine, formatShareTagsSection, formatStallCapacityLabel, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, gameScreenIdentifierList, gameTypeToDisplayName, getAllowedEventDateStatuses, getCurrentAndFutureDates, getEventCalendarIsoDates, getEventDatesWithStallholders, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsEmptyMessage, hasMatchingEventDate, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, isResourceImageActive, joinShareDescriptionSections, joinShareOgDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeResourceImage, normalizeShareOgDescription, normalizeShareRouteId, normalizeShareText, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, relationHasSelectedDate, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, resolveResourceImageActive, rewardNiceNames, seededShuffle, shareMessageFooterPlacementForType, shareSlugResourceId, shouldShowEventActionsWithWeather, socialMediaFields, sortDatesChronologically, splitShareDescriptionSections, stallTypeOptions, statusOptions, tagOptions, timeFormat, toCalendarIsoDate, toGraphqlQueryString, toNZTime, truncateText, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useCancelSubscription, useContactUs, useCrawlGoogleMarkets, useCreateAd, useCreateBulkNotifications, useCreateCheckoutSession, useCreateCustomerPortal, useCreateEvent, useCreateEventInfo, useCreatePartner, useCreatePost, useCreatePoster, useCreatePrivateChat, useCreatePushToken, useCreateRelation, useCreateResourceActivity, useCreateSchool, useCreateUnregisteredVendor, useCreateUser, useCreateVendor, useCreateVendorInfo, useDeleteAd, useDeleteAllNotifications, useDeleteChat, useDeleteEvent, useDeleteNotification, useDeletePartner, useDeletePost, useDeleteRelation, useDeleteSchool, useDeleteUnregisteredVendor, useDeleteUser, useDeleteVendor, useGetAd, useGetAds, useGetAdsByRegion, useGetAppSettings, useGetChat, useGetChatSubscription, useGetChatsByRegion, useGetEvent, useGetEventByPlaceId, useGetEventInfo, useGetEventRelations, useGetEvents, useGetEventsByRegion, useGetEventsNearMe, useGetGame, useGetGameLeaderboard, useGetGames, useGetNotificationCount, useGetNotificationCountSubscription, useGetPartner, useGetPartners, useGetPartnersByRegion, useGetPost, useGetPosts, useGetPostsByType, useGetRelation, useGetRelationByEventAndVendor, useGetReportedChatUsers, useGetResourceActivity, useGetResourceConnections, useGetSchool, useGetSchools, useGetSubscriptionPlans, useGetSubscriptionStatus, useGetUnregisteredVendor, useGetUnregisteredVendors, useGetUnregisteredVendorsByInviterId, useGetUser, useGetUserActivities, useGetUserChats, useGetUserEvents, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserPartners, useGetUserResources, useGetUserVendors, useGetUsers, useGetVendor, useGetVendorInfo, useGetVendorRelations, useGetVendors, useGetVendorsByRegion, useLeaveGame, useLogin, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, useRedeemReward, useRefreshToken, useRegister, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useResetPassword, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdatePartner, useUpdatePost, useUpdatePuzzleGame, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useValidateVerificationToken, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
3139
+ export { AFFILIATE_REWARDS, ANDROID_URL, type AdFormData, type AdFormState, type AdResource, type AdType, type AdminUpdateResourceType, type AffiliateResourceType, type AffiliateReward, type AffiliateType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type AuthPayloadType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, CLUEMART_MAIN_DOMAIN_URL, CM_AFFILIATE_PROMO_CODE, CM_SCHOOL_PROMO_CODE, type CalendarSheetContentData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, type CreateAdFormState, type CreateAppSettingsFormData, type CreateBulkNotificationInput, type CreateContactUsFormData, type CreateEventFormData, type CreateEventInfoFormData, type CreateFormData, type CreateLoginFormData, type CreatePartnerFormData, type CreatePostFormData, type CreateRegisterFormData, type CreateRequestPasswordResetFormData, type CreateResetPasswordFormData, type CreateSchoolFormData, type CreateUnregisteredVendorFormData, type CreateUserFormData, type CreateValidateVerificationTokenFormData, type CreateVendorFormData, type CreateVendorInfoFormData, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, EVENT_DATE_STATUS_PERIOD_MAP, EnumActivity, EnumAdShowOn, EnumAdStatus, EnumAdStyle, EnumAdType, EnumAffiliateRewardType, EnumBillingPeriod, EnumChatReportReason, EnumChatType, EnumEventDateStatus, EnumEventType, EnumFoodFlavor, EnumFoodType, EnumGameStatus, EnumGameType, EnumInviteStatus, EnumNotificationResourceType, EnumNotificationType, EnumOSPlatform, EnumPartnerType, EnumPaymentMethod, EnumPostContentType, EnumPostType, EnumRegions, EnumRelationResource, EnumResourceType, EnumReward, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStatusType, type EventType, type FormDateField, type FormField, GET_EVENT, GET_EVENT_BY_SLUG, GET_EVENT_INFO, GET_PARTNER, GET_PARTNER_BY_SLUG, GET_POST, GET_POST_BY_SLUG, GET_RESOURCE_CONNECTIONS, GET_VENDOR, GET_VENDOR_BY_SLUG, GET_VENDOR_INFO, type GameDate, type GameDocType, type GameHistory, type GameLeaderboard, type GamePlacement, type GamePlacementClue, type GameType, type GeocodeLocation, type GlobalGameData, type GoogleAddressComponent, type GoogleImportedMarket, IMAGE_EXTENSION, IOS_URL, type IconBasename, type IconId, type ImageObjectType, ImageTypeEnum, KNOWN_EVENT_SCHEDULE_STATUSES, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type NotificationCount, type NotificationDataType, type NotificationType, type Nullable, OG_DESCRIPTION_LINE_BREAK, type OptionItem, type OtherImagesBasename, type OtherImagesId, type OwnerType, POST_SHARE_RESOURCE_TYPES, PROMO_CODE_PREFIX, PUBLIC_SHARE_PATH_TYPES, type ParticipantType, type PartnerFormData, type PartnerType, type PaymentInfoType, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostResource, type PostShareResourceType, type PostType, PostTypeLabels, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, type PushTokenType, type PuzzleAnswer, type PuzzleAnsweredQuestion, type PuzzleBaseGame, type PuzzleGameData, type PuzzleQuestion, RELATION_OVERLAY_LAYOUT_VERSION, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, type RedeemRewardInput, type RedeemRewardResponse, type RedeemedReward, type RefreshTokenPayloadType, type RefundPolicy, type Region, type RegisterFormData, type RelatedPostType, type RelationDate, type RelationInputType, type RelationSharePathType, type RelationShareResourceType, type RelationType$1 as RelationType, type ReportChatUser, type RequestPasswordResetFormData, type Requirement, type ResetPasswordFormData, type ResourceActivityEntry, type ResourceActivityInputType, type ResourceActivityType, type ResourceByUser, type ResourceConnectionsType, type ResourceContactDetailsType, type ResourceDetails, type ResourceImageType, type ResourceShareType, SAVED_EMAIL_KEY, SAVED_PASSWORD_KEY, SAVED_REFRESH_TOKEN_KEY, SAVED_TOKEN_KEY, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, SHARE_APPLICATION_DEADLINE_PREFIX, SHARE_CALENDAR_ICON, SHARE_CATEGORIES_SECTION_HEADING, SHARE_CATEGORY_ICON, SHARE_CHECKMARK_ICON, SHARE_CLOCK_ICON, SHARE_COMPLIANCE_PREFIX, SHARE_DESCRIPTION_SECTION_BREAK, SHARE_DOLLAR_ICON, SHARE_FOOD_TRUCK_LINE, SHARE_INFO_ICON, SHARE_MARKET_DATES_SECTION_HEADING, SHARE_MORE_INFO_LINE, SHARE_PRICE_RANGE_PREFIX, SHARE_RAIN_OR_SHINE_LINE, SHARE_REQUIREMENTS_SECTION_HEADING, SHARE_RESOURCE_LABEL, SHARE_RULER_ICON, SHARE_SITE_URL, SHARE_STALL_SIZE_PREFIX, SHARE_TAGS_SECTION_HEADING, SHARE_TYPE_PATH_REGEX, SOCIAL_IMAGE_HEIGHT, SOCIAL_IMAGE_WIDTH, type SafeUserType, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventForInvitation, type ShareEventForPublic, type ShareEventInfoForInvitation, type ShareMessageFooterPlacement, type ShareResourceType, type ShareSlugResource, type ShareType, type ShareVendorForApplication, type ShareVendorForPublic, type ShareVendorInfoForApplication, type SocialMediaType, type SocialShareResourceType, type StallType, type StallholderFilterOption, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, TIERS_BY_PRIORITY, TIER_DISPLAY_LABELS, TIER_FROM_LICENCE, type TermsAgreement, type Tier, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetResourcesByRegionOptions, type UserActivity, type UserActivityEvent, type UserFormData, type UserLicenceType, type UserType, type ValidateVerificationTokenFormData, type VendorAttributes, type VendorCalendarData, type VendorFormData, type VendorInfoFormData, type VendorInfoType, type VendorProductList, type VendorType, appendShareMoreInfoLine, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildCalendarSheetContentData, buildFacebookShareQuote, buildInvitationShareDescription, buildPublicEventShareDescription, buildPublicVendorShareDescription, buildShareMessageSections, buildShareOgDescription, buildShareOgDescriptionFromSections, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, collectStallholderStartDates, collectVendorEventRelationDateTimes, companyContactFields, computeDailyClueState, contactUsFields, createAffiliateReward, darkColors, dateFormat, emailField, eventBasicInfoFields, eventEndDateFields, eventHasSelectedDate, eventInfo, eventInfoPaymentInfo, eventMatchesDateStatusPeriod, eventStartDateFields, eventStartDatesSet, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareApplicationCategoriesSection, formatShareApplicationComplianceSection, formatShareApplicationPriceRangeLine, formatShareApplicationStallSizeLine, formatShareInvitationApplicationDeadlineLine, formatShareInvitationMarketDatesSection, formatShareInvitationRequirementsSection, formatShareIsFoodTrueLine, formatShareMarketDate, formatShareRainOrShineLine, formatShareStallLine, formatShareTagsSection, formatStallCapacityLabel, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, gameScreenIdentifierList, gameTypeToDisplayName, getAllowedEventDateStatuses, getCurrentAndFutureDates, getEventCalendarIsoDates, getEventDatesWithStallholders, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsEmptyMessage, hasMatchingEventDate, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, isResourceImageActive, joinShareDescriptionSections, joinShareOgDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeResourceImage, normalizeShareOgDescription, normalizeShareRouteId, normalizeShareText, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, relationHasSelectedDate, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, resolveResourceImageActive, rewardNiceNames, seededShuffle, shareMessageFooterPlacementForType, shareSlugResourceId, shouldShowEventActionsWithWeather, socialMediaFields, sortDatesChronologically, splitShareDescriptionSections, stallTypeOptions, statusOptions, tagOptions, timeFormat, toCalendarIsoDate, toGraphqlQueryString, toNZTime, truncateText, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useCancelSubscription, useContactUs, useCrawlGoogleMarkets, useCreateAd, useCreateBulkNotifications, useCreateCheckoutSession, useCreateCustomerPortal, useCreateEvent, useCreateEventInfo, useCreatePartner, useCreatePost, useCreatePoster, useCreatePrivateChat, useCreatePushToken, useCreateRelation, useCreateResourceActivity, useCreateSchool, useCreateUnregisteredVendor, useCreateUser, useCreateVendor, useCreateVendorInfo, useDeleteAd, useDeleteAllNotifications, useDeleteChat, useDeleteEvent, useDeleteNotification, useDeletePartner, useDeletePost, useDeleteRelation, useDeleteSchool, useDeleteUnregisteredVendor, useDeleteUser, useDeleteVendor, useGetAd, useGetAds, useGetAdsByRegion, useGetAffiliate, useGetAffiliates, useGetAppSettings, useGetChat, useGetChatSubscription, useGetChatsByRegion, useGetEvent, useGetEventByPlaceId, useGetEventInfo, useGetEventRelations, useGetEvents, useGetEventsByRegion, useGetEventsNearMe, useGetGame, useGetGameLeaderboard, useGetGames, useGetNotificationCount, useGetNotificationCountSubscription, useGetPartner, useGetPartners, useGetPartnersByRegion, useGetPost, useGetPosts, useGetPostsByType, useGetRelation, useGetRelationByEventAndVendor, useGetReportedChatUsers, useGetResourceActivity, useGetResourceConnections, useGetSchool, useGetSchools, useGetSubscriptionPlans, useGetSubscriptionStatus, useGetUnregisteredVendor, useGetUnregisteredVendors, useGetUnregisteredVendorsByInviterId, useGetUser, useGetUserActivities, useGetUserChats, useGetUserEvents, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserPartners, useGetUserResources, useGetUserVendors, useGetUsers, useGetVendor, useGetVendorInfo, useGetVendorRelations, useGetVendors, useGetVendorsByRegion, useLeaveGame, useLogin, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, useRedeemReward, useRefreshToken, useRegister, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useResetPassword, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdatePartner, useUpdatePost, useUpdatePuzzleGame, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useValidateVerificationToken, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
package/dist/index.d.ts CHANGED
@@ -1031,13 +1031,9 @@ type RedeemedReward = {
1031
1031
  pointsUsed: number;
1032
1032
  redeemedAt: Date;
1033
1033
  };
1034
- type AffiliateType = {
1035
- affiliateCode: PromoCodeType;
1036
- pointsAvailable: number;
1037
- };
1038
1034
  type UserType = Omit<UserFormData, "confirmPassword" | "avatarUpload" | "_id"> & {
1039
1035
  _id: string;
1040
- affiliate?: AffiliateType | null;
1036
+ affiliate?: string | null;
1041
1037
  associates?: AssociateType[] | null;
1042
1038
  createdAt: Date;
1043
1039
  deletedAt: Date | null;
@@ -1458,6 +1454,37 @@ declare const TIER_DISPLAY_LABELS: Record<Tier, string>;
1458
1454
  /** Maps licence enums to their canonical tier key. */
1459
1455
  declare const TIER_FROM_LICENCE: Record<EnumUserLicence, Tier>;
1460
1456
 
1457
+ declare enum EnumAffiliateRewardType {
1458
+ NEW_EVENT_REGISTRATION = "NEW_EVENT_REGISTRATION",
1459
+ NEW_VENDOR_REGISTRATION = "NEW_VENDOR_REGISTRATION",
1460
+ NEW_PARTNER_REGISTRATION = "NEW_PARTNER_REGISTRATION"
1461
+ }
1462
+ type AffiliateReward = {
1463
+ createdAt: Date;
1464
+ deletedAt: Date | null;
1465
+ redeemedAt: Date | null;
1466
+ rewardDescription: string;
1467
+ rewardType: EnumAffiliateRewardType;
1468
+ rewardValue: number;
1469
+ updatedAt: Date | null;
1470
+ };
1471
+ type AffiliateResourceType = {
1472
+ resourceActive: boolean;
1473
+ resourceId: string;
1474
+ resourceType: EnumResourceType;
1475
+ rewards: AffiliateReward[];
1476
+ };
1477
+ type AffiliateType = {
1478
+ _id: string;
1479
+ affiliateCode: PromoCodeType;
1480
+ affiliateResources: AffiliateResourceType[];
1481
+ createdAt: Date;
1482
+ deletedAt: Date | null;
1483
+ overallPoints: number;
1484
+ owner: OwnerType;
1485
+ updatedAt: Date | null;
1486
+ };
1487
+
1461
1488
  declare const vendorElectricity: {
1462
1489
  details: FormField;
1463
1490
  isRequired: FormField;
@@ -2677,6 +2704,23 @@ declare const useGetSchool: (_id: string) => {
2677
2704
  school: SchoolReturnType | null;
2678
2705
  };
2679
2706
 
2707
+ declare const useGetAffiliate: (_id: string) => {
2708
+ affiliate: AffiliateType | undefined;
2709
+ error: _apollo_client.ApolloError | undefined;
2710
+ loading: boolean;
2711
+ refetch: (variables?: Partial<_apollo_client.OperationVariables> | undefined) => Promise<_apollo_client.ApolloQueryResult<{
2712
+ affiliate: AffiliateType;
2713
+ }>>;
2714
+ };
2715
+ declare const useGetAffiliates: () => {
2716
+ affiliates: AffiliateType[];
2717
+ error: _apollo_client.ApolloError | undefined;
2718
+ loading: boolean;
2719
+ refetch: (variables?: Partial<_apollo_client.OperationVariables> | undefined) => Promise<_apollo_client.ApolloQueryResult<{
2720
+ affiliates: AffiliateType[];
2721
+ }>>;
2722
+ };
2723
+
2680
2724
  /** Minimal event fields for public (market) share copy — matches in-app preview. */
2681
2725
  type ShareEventForPublic = {
2682
2726
  description?: string | null;
@@ -2980,6 +3024,34 @@ declare const rewardNiceNames: Record<EnumReward, {
2980
3024
  points: number;
2981
3025
  }>;
2982
3026
  declare const PostTypeLabels: Record<EnumPostType, string>;
3027
+ /** Hardcoded promo; compared to trimmed + uppercased registration input. */
3028
+ declare const CM_SCHOOL_PROMO_CODE = "CM-SCHOOL";
3029
+ declare const CM_AFFILIATE_PROMO_CODE = "CM-AFFILIATE";
3030
+
3031
+ declare const AFFILIATE_REWARDS: {
3032
+ NEW_EVENT_REGISTRATION: {
3033
+ description: string;
3034
+ value: number;
3035
+ };
3036
+ NEW_VENDOR_REGISTRATION: {
3037
+ description: string;
3038
+ value: number;
3039
+ };
3040
+ NEW_PARTNER_REGISTRATION: {
3041
+ description: string;
3042
+ value: number;
3043
+ };
3044
+ };
3045
+ /**
3046
+ * Create an affiliate reward
3047
+ * @param rewardType - The type of reward
3048
+ * @param receivedAt - The date the reward was received
3049
+ * @returns The affiliate reward
3050
+ * @example
3051
+ * const reward = createAffiliateReward(EnumAffiliateRewardType.NEW_EVENT_REGISTRATION, new Date());
3052
+ * console.log(reward);
3053
+ */
3054
+ declare function createAffiliateReward(rewardType: EnumAffiliateRewardType, createdAt: Date): AffiliateReward;
2983
3055
 
2984
3056
  /**
2985
3057
  * Loose input shape for normalization helpers. Callers often pass partial or legacy
@@ -3064,4 +3136,4 @@ declare function getVendorEventRelationStartDates(events: EventListItemType[] |
3064
3136
  declare function getVendorEventRelationDateOptions(events: EventListItemType[] | null | undefined): StallholderFilterOption[];
3065
3137
  declare function getVendorEventsEmptyMessage(): string;
3066
3138
 
3067
- export { ANDROID_URL, type AdFormData, type AdFormState, type AdResource, type AdType, type AdminUpdateResourceType, type AffiliateType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type AuthPayloadType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, CLUEMART_MAIN_DOMAIN_URL, type CalendarSheetContentData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, type CreateAdFormState, type CreateAppSettingsFormData, type CreateBulkNotificationInput, type CreateContactUsFormData, type CreateEventFormData, type CreateEventInfoFormData, type CreateFormData, type CreateLoginFormData, type CreatePartnerFormData, type CreatePostFormData, type CreateRegisterFormData, type CreateRequestPasswordResetFormData, type CreateResetPasswordFormData, type CreateSchoolFormData, type CreateUnregisteredVendorFormData, type CreateUserFormData, type CreateValidateVerificationTokenFormData, type CreateVendorFormData, type CreateVendorInfoFormData, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, EVENT_DATE_STATUS_PERIOD_MAP, EnumActivity, EnumAdShowOn, EnumAdStatus, EnumAdStyle, EnumAdType, EnumBillingPeriod, EnumChatReportReason, EnumChatType, EnumEventDateStatus, EnumEventType, EnumFoodFlavor, EnumFoodType, EnumGameStatus, EnumGameType, EnumInviteStatus, EnumNotificationResourceType, EnumNotificationType, EnumOSPlatform, EnumPartnerType, EnumPaymentMethod, EnumPostContentType, EnumPostType, EnumRegions, EnumRelationResource, EnumResourceType, EnumReward, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStatusType, type EventType, type FormDateField, type FormField, GET_EVENT, GET_EVENT_BY_SLUG, GET_EVENT_INFO, GET_PARTNER, GET_PARTNER_BY_SLUG, GET_POST, GET_POST_BY_SLUG, GET_RESOURCE_CONNECTIONS, GET_VENDOR, GET_VENDOR_BY_SLUG, GET_VENDOR_INFO, type GameDate, type GameDocType, type GameHistory, type GameLeaderboard, type GamePlacement, type GamePlacementClue, type GameType, type GeocodeLocation, type GlobalGameData, type GoogleAddressComponent, type GoogleImportedMarket, IMAGE_EXTENSION, IOS_URL, type IconBasename, type IconId, type ImageObjectType, ImageTypeEnum, KNOWN_EVENT_SCHEDULE_STATUSES, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type NotificationCount, type NotificationDataType, type NotificationType, type Nullable, OG_DESCRIPTION_LINE_BREAK, type OptionItem, type OtherImagesBasename, type OtherImagesId, type OwnerType, POST_SHARE_RESOURCE_TYPES, PROMO_CODE_PREFIX, PUBLIC_SHARE_PATH_TYPES, type ParticipantType, type PartnerFormData, type PartnerType, type PaymentInfoType, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostResource, type PostShareResourceType, type PostType, PostTypeLabels, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, type PushTokenType, type PuzzleAnswer, type PuzzleAnsweredQuestion, type PuzzleBaseGame, type PuzzleGameData, type PuzzleQuestion, RELATION_OVERLAY_LAYOUT_VERSION, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, type RedeemRewardInput, type RedeemRewardResponse, type RedeemedReward, type RefreshTokenPayloadType, type RefundPolicy, type Region, type RegisterFormData, type RelatedPostType, type RelationDate, type RelationInputType, type RelationSharePathType, type RelationShareResourceType, type RelationType$1 as RelationType, type ReportChatUser, type RequestPasswordResetFormData, type Requirement, type ResetPasswordFormData, type ResourceActivityEntry, type ResourceActivityInputType, type ResourceActivityType, type ResourceByUser, type ResourceConnectionsType, type ResourceContactDetailsType, type ResourceDetails, type ResourceImageType, type ResourceShareType, SAVED_EMAIL_KEY, SAVED_PASSWORD_KEY, SAVED_REFRESH_TOKEN_KEY, SAVED_TOKEN_KEY, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, SHARE_APPLICATION_DEADLINE_PREFIX, SHARE_CALENDAR_ICON, SHARE_CATEGORIES_SECTION_HEADING, SHARE_CATEGORY_ICON, SHARE_CHECKMARK_ICON, SHARE_CLOCK_ICON, SHARE_COMPLIANCE_PREFIX, SHARE_DESCRIPTION_SECTION_BREAK, SHARE_DOLLAR_ICON, SHARE_FOOD_TRUCK_LINE, SHARE_INFO_ICON, SHARE_MARKET_DATES_SECTION_HEADING, SHARE_MORE_INFO_LINE, SHARE_PRICE_RANGE_PREFIX, SHARE_RAIN_OR_SHINE_LINE, SHARE_REQUIREMENTS_SECTION_HEADING, SHARE_RESOURCE_LABEL, SHARE_RULER_ICON, SHARE_SITE_URL, SHARE_STALL_SIZE_PREFIX, SHARE_TAGS_SECTION_HEADING, SHARE_TYPE_PATH_REGEX, SOCIAL_IMAGE_HEIGHT, SOCIAL_IMAGE_WIDTH, type SafeUserType, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventForInvitation, type ShareEventForPublic, type ShareEventInfoForInvitation, type ShareMessageFooterPlacement, type ShareResourceType, type ShareSlugResource, type ShareType, type ShareVendorForApplication, type ShareVendorForPublic, type ShareVendorInfoForApplication, type SocialMediaType, type SocialShareResourceType, type StallType, type StallholderFilterOption, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, TIERS_BY_PRIORITY, TIER_DISPLAY_LABELS, TIER_FROM_LICENCE, type TermsAgreement, type Tier, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetResourcesByRegionOptions, type UserActivity, type UserActivityEvent, type UserFormData, type UserLicenceType, type UserType, type ValidateVerificationTokenFormData, type VendorAttributes, type VendorCalendarData, type VendorFormData, type VendorInfoFormData, type VendorInfoType, type VendorProductList, type VendorType, appendShareMoreInfoLine, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildCalendarSheetContentData, buildFacebookShareQuote, buildInvitationShareDescription, buildPublicEventShareDescription, buildPublicVendorShareDescription, buildShareMessageSections, buildShareOgDescription, buildShareOgDescriptionFromSections, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, collectStallholderStartDates, collectVendorEventRelationDateTimes, companyContactFields, computeDailyClueState, contactUsFields, darkColors, dateFormat, emailField, eventBasicInfoFields, eventEndDateFields, eventHasSelectedDate, eventInfo, eventInfoPaymentInfo, eventMatchesDateStatusPeriod, eventStartDateFields, eventStartDatesSet, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareApplicationCategoriesSection, formatShareApplicationComplianceSection, formatShareApplicationPriceRangeLine, formatShareApplicationStallSizeLine, formatShareInvitationApplicationDeadlineLine, formatShareInvitationMarketDatesSection, formatShareInvitationRequirementsSection, formatShareIsFoodTrueLine, formatShareMarketDate, formatShareRainOrShineLine, formatShareStallLine, formatShareTagsSection, formatStallCapacityLabel, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, gameScreenIdentifierList, gameTypeToDisplayName, getAllowedEventDateStatuses, getCurrentAndFutureDates, getEventCalendarIsoDates, getEventDatesWithStallholders, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsEmptyMessage, hasMatchingEventDate, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, isResourceImageActive, joinShareDescriptionSections, joinShareOgDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeResourceImage, normalizeShareOgDescription, normalizeShareRouteId, normalizeShareText, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, relationHasSelectedDate, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, resolveResourceImageActive, rewardNiceNames, seededShuffle, shareMessageFooterPlacementForType, shareSlugResourceId, shouldShowEventActionsWithWeather, socialMediaFields, sortDatesChronologically, splitShareDescriptionSections, stallTypeOptions, statusOptions, tagOptions, timeFormat, toCalendarIsoDate, toGraphqlQueryString, toNZTime, truncateText, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useCancelSubscription, useContactUs, useCrawlGoogleMarkets, useCreateAd, useCreateBulkNotifications, useCreateCheckoutSession, useCreateCustomerPortal, useCreateEvent, useCreateEventInfo, useCreatePartner, useCreatePost, useCreatePoster, useCreatePrivateChat, useCreatePushToken, useCreateRelation, useCreateResourceActivity, useCreateSchool, useCreateUnregisteredVendor, useCreateUser, useCreateVendor, useCreateVendorInfo, useDeleteAd, useDeleteAllNotifications, useDeleteChat, useDeleteEvent, useDeleteNotification, useDeletePartner, useDeletePost, useDeleteRelation, useDeleteSchool, useDeleteUnregisteredVendor, useDeleteUser, useDeleteVendor, useGetAd, useGetAds, useGetAdsByRegion, useGetAppSettings, useGetChat, useGetChatSubscription, useGetChatsByRegion, useGetEvent, useGetEventByPlaceId, useGetEventInfo, useGetEventRelations, useGetEvents, useGetEventsByRegion, useGetEventsNearMe, useGetGame, useGetGameLeaderboard, useGetGames, useGetNotificationCount, useGetNotificationCountSubscription, useGetPartner, useGetPartners, useGetPartnersByRegion, useGetPost, useGetPosts, useGetPostsByType, useGetRelation, useGetRelationByEventAndVendor, useGetReportedChatUsers, useGetResourceActivity, useGetResourceConnections, useGetSchool, useGetSchools, useGetSubscriptionPlans, useGetSubscriptionStatus, useGetUnregisteredVendor, useGetUnregisteredVendors, useGetUnregisteredVendorsByInviterId, useGetUser, useGetUserActivities, useGetUserChats, useGetUserEvents, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserPartners, useGetUserResources, useGetUserVendors, useGetUsers, useGetVendor, useGetVendorInfo, useGetVendorRelations, useGetVendors, useGetVendorsByRegion, useLeaveGame, useLogin, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, useRedeemReward, useRefreshToken, useRegister, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useResetPassword, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdatePartner, useUpdatePost, useUpdatePuzzleGame, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useValidateVerificationToken, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
3139
+ export { AFFILIATE_REWARDS, ANDROID_URL, type AdFormData, type AdFormState, type AdResource, type AdType, type AdminUpdateResourceType, type AffiliateResourceType, type AffiliateReward, type AffiliateType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type AuthPayloadType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, CLUEMART_MAIN_DOMAIN_URL, CM_AFFILIATE_PROMO_CODE, CM_SCHOOL_PROMO_CODE, type CalendarSheetContentData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, type CreateAdFormState, type CreateAppSettingsFormData, type CreateBulkNotificationInput, type CreateContactUsFormData, type CreateEventFormData, type CreateEventInfoFormData, type CreateFormData, type CreateLoginFormData, type CreatePartnerFormData, type CreatePostFormData, type CreateRegisterFormData, type CreateRequestPasswordResetFormData, type CreateResetPasswordFormData, type CreateSchoolFormData, type CreateUnregisteredVendorFormData, type CreateUserFormData, type CreateValidateVerificationTokenFormData, type CreateVendorFormData, type CreateVendorInfoFormData, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, EVENT_DATE_STATUS_PERIOD_MAP, EnumActivity, EnumAdShowOn, EnumAdStatus, EnumAdStyle, EnumAdType, EnumAffiliateRewardType, EnumBillingPeriod, EnumChatReportReason, EnumChatType, EnumEventDateStatus, EnumEventType, EnumFoodFlavor, EnumFoodType, EnumGameStatus, EnumGameType, EnumInviteStatus, EnumNotificationResourceType, EnumNotificationType, EnumOSPlatform, EnumPartnerType, EnumPaymentMethod, EnumPostContentType, EnumPostType, EnumRegions, EnumRelationResource, EnumResourceType, EnumReward, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStatusType, type EventType, type FormDateField, type FormField, GET_EVENT, GET_EVENT_BY_SLUG, GET_EVENT_INFO, GET_PARTNER, GET_PARTNER_BY_SLUG, GET_POST, GET_POST_BY_SLUG, GET_RESOURCE_CONNECTIONS, GET_VENDOR, GET_VENDOR_BY_SLUG, GET_VENDOR_INFO, type GameDate, type GameDocType, type GameHistory, type GameLeaderboard, type GamePlacement, type GamePlacementClue, type GameType, type GeocodeLocation, type GlobalGameData, type GoogleAddressComponent, type GoogleImportedMarket, IMAGE_EXTENSION, IOS_URL, type IconBasename, type IconId, type ImageObjectType, ImageTypeEnum, KNOWN_EVENT_SCHEDULE_STATUSES, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type NotificationCount, type NotificationDataType, type NotificationType, type Nullable, OG_DESCRIPTION_LINE_BREAK, type OptionItem, type OtherImagesBasename, type OtherImagesId, type OwnerType, POST_SHARE_RESOURCE_TYPES, PROMO_CODE_PREFIX, PUBLIC_SHARE_PATH_TYPES, type ParticipantType, type PartnerFormData, type PartnerType, type PaymentInfoType, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostResource, type PostShareResourceType, type PostType, PostTypeLabels, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, type PushTokenType, type PuzzleAnswer, type PuzzleAnsweredQuestion, type PuzzleBaseGame, type PuzzleGameData, type PuzzleQuestion, RELATION_OVERLAY_LAYOUT_VERSION, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, type RedeemRewardInput, type RedeemRewardResponse, type RedeemedReward, type RefreshTokenPayloadType, type RefundPolicy, type Region, type RegisterFormData, type RelatedPostType, type RelationDate, type RelationInputType, type RelationSharePathType, type RelationShareResourceType, type RelationType$1 as RelationType, type ReportChatUser, type RequestPasswordResetFormData, type Requirement, type ResetPasswordFormData, type ResourceActivityEntry, type ResourceActivityInputType, type ResourceActivityType, type ResourceByUser, type ResourceConnectionsType, type ResourceContactDetailsType, type ResourceDetails, type ResourceImageType, type ResourceShareType, SAVED_EMAIL_KEY, SAVED_PASSWORD_KEY, SAVED_REFRESH_TOKEN_KEY, SAVED_TOKEN_KEY, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, SHARE_APPLICATION_DEADLINE_PREFIX, SHARE_CALENDAR_ICON, SHARE_CATEGORIES_SECTION_HEADING, SHARE_CATEGORY_ICON, SHARE_CHECKMARK_ICON, SHARE_CLOCK_ICON, SHARE_COMPLIANCE_PREFIX, SHARE_DESCRIPTION_SECTION_BREAK, SHARE_DOLLAR_ICON, SHARE_FOOD_TRUCK_LINE, SHARE_INFO_ICON, SHARE_MARKET_DATES_SECTION_HEADING, SHARE_MORE_INFO_LINE, SHARE_PRICE_RANGE_PREFIX, SHARE_RAIN_OR_SHINE_LINE, SHARE_REQUIREMENTS_SECTION_HEADING, SHARE_RESOURCE_LABEL, SHARE_RULER_ICON, SHARE_SITE_URL, SHARE_STALL_SIZE_PREFIX, SHARE_TAGS_SECTION_HEADING, SHARE_TYPE_PATH_REGEX, SOCIAL_IMAGE_HEIGHT, SOCIAL_IMAGE_WIDTH, type SafeUserType, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventForInvitation, type ShareEventForPublic, type ShareEventInfoForInvitation, type ShareMessageFooterPlacement, type ShareResourceType, type ShareSlugResource, type ShareType, type ShareVendorForApplication, type ShareVendorForPublic, type ShareVendorInfoForApplication, type SocialMediaType, type SocialShareResourceType, type StallType, type StallholderFilterOption, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, TIERS_BY_PRIORITY, TIER_DISPLAY_LABELS, TIER_FROM_LICENCE, type TermsAgreement, type Tier, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetResourcesByRegionOptions, type UserActivity, type UserActivityEvent, type UserFormData, type UserLicenceType, type UserType, type ValidateVerificationTokenFormData, type VendorAttributes, type VendorCalendarData, type VendorFormData, type VendorInfoFormData, type VendorInfoType, type VendorProductList, type VendorType, appendShareMoreInfoLine, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildCalendarSheetContentData, buildFacebookShareQuote, buildInvitationShareDescription, buildPublicEventShareDescription, buildPublicVendorShareDescription, buildShareMessageSections, buildShareOgDescription, buildShareOgDescriptionFromSections, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, collectStallholderStartDates, collectVendorEventRelationDateTimes, companyContactFields, computeDailyClueState, contactUsFields, createAffiliateReward, darkColors, dateFormat, emailField, eventBasicInfoFields, eventEndDateFields, eventHasSelectedDate, eventInfo, eventInfoPaymentInfo, eventMatchesDateStatusPeriod, eventStartDateFields, eventStartDatesSet, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareApplicationCategoriesSection, formatShareApplicationComplianceSection, formatShareApplicationPriceRangeLine, formatShareApplicationStallSizeLine, formatShareInvitationApplicationDeadlineLine, formatShareInvitationMarketDatesSection, formatShareInvitationRequirementsSection, formatShareIsFoodTrueLine, formatShareMarketDate, formatShareRainOrShineLine, formatShareStallLine, formatShareTagsSection, formatStallCapacityLabel, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, gameScreenIdentifierList, gameTypeToDisplayName, getAllowedEventDateStatuses, getCurrentAndFutureDates, getEventCalendarIsoDates, getEventDatesWithStallholders, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsEmptyMessage, hasMatchingEventDate, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, isResourceImageActive, joinShareDescriptionSections, joinShareOgDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeResourceImage, normalizeShareOgDescription, normalizeShareRouteId, normalizeShareText, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, relationHasSelectedDate, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, resolveResourceImageActive, rewardNiceNames, seededShuffle, shareMessageFooterPlacementForType, shareSlugResourceId, shouldShowEventActionsWithWeather, socialMediaFields, sortDatesChronologically, splitShareDescriptionSections, stallTypeOptions, statusOptions, tagOptions, timeFormat, toCalendarIsoDate, toGraphqlQueryString, toNZTime, truncateText, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useCancelSubscription, useContactUs, useCrawlGoogleMarkets, useCreateAd, useCreateBulkNotifications, useCreateCheckoutSession, useCreateCustomerPortal, useCreateEvent, useCreateEventInfo, useCreatePartner, useCreatePost, useCreatePoster, useCreatePrivateChat, useCreatePushToken, useCreateRelation, useCreateResourceActivity, useCreateSchool, useCreateUnregisteredVendor, useCreateUser, useCreateVendor, useCreateVendorInfo, useDeleteAd, useDeleteAllNotifications, useDeleteChat, useDeleteEvent, useDeleteNotification, useDeletePartner, useDeletePost, useDeleteRelation, useDeleteSchool, useDeleteUnregisteredVendor, useDeleteUser, useDeleteVendor, useGetAd, useGetAds, useGetAdsByRegion, useGetAffiliate, useGetAffiliates, useGetAppSettings, useGetChat, useGetChatSubscription, useGetChatsByRegion, useGetEvent, useGetEventByPlaceId, useGetEventInfo, useGetEventRelations, useGetEvents, useGetEventsByRegion, useGetEventsNearMe, useGetGame, useGetGameLeaderboard, useGetGames, useGetNotificationCount, useGetNotificationCountSubscription, useGetPartner, useGetPartners, useGetPartnersByRegion, useGetPost, useGetPosts, useGetPostsByType, useGetRelation, useGetRelationByEventAndVendor, useGetReportedChatUsers, useGetResourceActivity, useGetResourceConnections, useGetSchool, useGetSchools, useGetSubscriptionPlans, useGetSubscriptionStatus, useGetUnregisteredVendor, useGetUnregisteredVendors, useGetUnregisteredVendorsByInviterId, useGetUser, useGetUserActivities, useGetUserChats, useGetUserEvents, useGetUserNotifications, useGetUserNotificationsSubscription, useGetUserPartners, useGetUserResources, useGetUserVendors, useGetUsers, useGetVendor, useGetVendorInfo, useGetVendorRelations, useGetVendors, useGetVendorsByRegion, useLeaveGame, useLogin, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, useRedeemReward, useRefreshToken, useRegister, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useResetPassword, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdatePartner, useUpdatePost, useUpdatePuzzleGame, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useValidateVerificationToken, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
package/dist/index.mjs CHANGED
@@ -656,6 +656,14 @@ var TIER_FROM_LICENCE = {
656
656
  ["standard_vendor" /* STANDARD_VENDOR */]: "standard"
657
657
  };
658
658
 
659
+ // src/types/affiliate.ts
660
+ var EnumAffiliateRewardType = /* @__PURE__ */ ((EnumAffiliateRewardType2) => {
661
+ EnumAffiliateRewardType2["NEW_EVENT_REGISTRATION"] = "NEW_EVENT_REGISTRATION";
662
+ EnumAffiliateRewardType2["NEW_VENDOR_REGISTRATION"] = "NEW_VENDOR_REGISTRATION";
663
+ EnumAffiliateRewardType2["NEW_PARTNER_REGISTRATION"] = "NEW_PARTNER_REGISTRATION";
664
+ return EnumAffiliateRewardType2;
665
+ })(EnumAffiliateRewardType || {});
666
+
659
667
  // src/utils/utils.ts
660
668
  var removeTypename = (obj) => {
661
669
  if (obj instanceof Date) {
@@ -758,6 +766,8 @@ var PostTypeLabels = {
758
766
  ["clue_bites" /* CLUE_BITES */]: "Clue Bites",
759
767
  ["play_and_win" /* PLAY_AND_WIN */]: "Play & Win"
760
768
  };
769
+ var CM_SCHOOL_PROMO_CODE = `${PROMO_CODE_PREFIX}SCHOOL`;
770
+ var CM_AFFILIATE_PROMO_CODE = `${PROMO_CODE_PREFIX}AFFILIATE`;
761
771
 
762
772
  // src/utils/date.ts
763
773
  var dateFormat = "DD-MM-YYYY";
@@ -910,6 +920,34 @@ function computeDailyClueState(dailyClue) {
910
920
  };
911
921
  }
912
922
 
923
+ // src/utils/affiliate.ts
924
+ var AFFILIATE_REWARDS = {
925
+ ["NEW_EVENT_REGISTRATION" /* NEW_EVENT_REGISTRATION */]: {
926
+ description: "10 points for new event registration (one-time reward)",
927
+ value: 10
928
+ },
929
+ ["NEW_VENDOR_REGISTRATION" /* NEW_VENDOR_REGISTRATION */]: {
930
+ description: "5 points for new vendor registration (one-time reward)",
931
+ value: 5
932
+ },
933
+ ["NEW_PARTNER_REGISTRATION" /* NEW_PARTNER_REGISTRATION */]: {
934
+ description: "",
935
+ value: 0
936
+ }
937
+ };
938
+ function createAffiliateReward(rewardType, createdAt) {
939
+ const reward = AFFILIATE_REWARDS[rewardType];
940
+ return {
941
+ createdAt,
942
+ deletedAt: null,
943
+ redeemedAt: null,
944
+ rewardDescription: reward.description,
945
+ rewardType,
946
+ rewardValue: reward.value,
947
+ updatedAt: null
948
+ };
949
+ }
950
+
913
951
  // src/utils/resourceImage.ts
914
952
  function resolveResourceImageActive(image) {
915
953
  if (image?.active != null) {
@@ -3046,12 +3084,6 @@ var REDEEMED_REWARD_FIELDS_FRAGMENT = gql`
3046
3084
  redeemedAt
3047
3085
  }
3048
3086
  `;
3049
- var AFFILIATE_FIELDS_FRAGMENT = gql`
3050
- fragment AffiliateFields on AffiliateType {
3051
- affiliateCode
3052
- pointsAvailable
3053
- }
3054
- `;
3055
3087
  var USER_FIELDS_FRAGMENT = gql`
3056
3088
  fragment UserFields on UserType {
3057
3089
  _id
@@ -3059,9 +3091,7 @@ var USER_FIELDS_FRAGMENT = gql`
3059
3091
  associates {
3060
3092
  ...AssociatesFields
3061
3093
  }
3062
- affiliate {
3063
- ...AffiliateFields
3064
- }
3094
+ affiliate
3065
3095
  avatar {
3066
3096
  ...ResourceImageFields
3067
3097
  }
@@ -3105,7 +3135,6 @@ var USER_FIELDS_FRAGMENT = gql`
3105
3135
  ${LICENCE_FIELDS_FRAGMENT}
3106
3136
  ${LOCATION_FIELDS_FRAGMENT}
3107
3137
  ${REDEEMED_REWARD_FIELDS_FRAGMENT}
3108
- ${AFFILIATE_FIELDS_FRAGMENT}
3109
3138
  `;
3110
3139
  var STALL_TYPE_FIELDS_FRAGMENT = gql`
3111
3140
  fragment StallTypeFields on StallTypeType {
@@ -7974,6 +8003,96 @@ var useGetSchool = (_id) => {
7974
8003
  };
7975
8004
  };
7976
8005
 
8006
+ // src/graphql/hooks/affiliate/hooksQuery.ts
8007
+ import { useQuery as useQuery15 } from "@apollo/client";
8008
+
8009
+ // src/graphql/queries/affiliate.ts
8010
+ import { gql as gql40 } from "@apollo/client";
8011
+ var AFFILIATE_REWARD_FIELDS_FRAGMENT = gql40`
8012
+ fragment AffiliateRewardFields on AffiliateRewardType {
8013
+ createdAt
8014
+ deletedAt
8015
+ redeemedAt
8016
+ rewardDescription
8017
+ rewardType
8018
+ rewardValue
8019
+ updatedAt
8020
+ }
8021
+ `;
8022
+ var AFFILIATE_RESOURCE_FIELDS_FRAGMENT = gql40`
8023
+ fragment AffiliateResourceFields on AffiliateResourceType {
8024
+ resourceActive
8025
+ resourceId
8026
+ resourceType
8027
+ rewards {
8028
+ ...AffiliateRewardFields
8029
+ }
8030
+ }
8031
+ ${AFFILIATE_REWARD_FIELDS_FRAGMENT}
8032
+ `;
8033
+ var AFFILIATE_FIELDS_FRAGMENT = gql40`
8034
+ fragment AffiliateFields on AffiliateType {
8035
+ _id
8036
+ affiliateCode
8037
+ affiliateResources {
8038
+ ...AffiliateResourceFields
8039
+ }
8040
+ createdAt
8041
+ deletedAt
8042
+ overallPoints
8043
+ owner {
8044
+ ...OwnerFields
8045
+ }
8046
+ updatedAt
8047
+ }
8048
+ ${AFFILIATE_RESOURCE_FIELDS_FRAGMENT}
8049
+ ${OWNER_FIELDS_FRAGMENT}
8050
+ `;
8051
+ var GET_AFFILIATE = gql40`
8052
+ query getAffiliate($_id: ID!) {
8053
+ affiliate(_id: $_id) {
8054
+ ...AffiliateFields
8055
+ }
8056
+ }
8057
+ ${AFFILIATE_FIELDS_FRAGMENT}
8058
+ `;
8059
+ var GET_AFFILIATES = gql40`
8060
+ query getAffiliates {
8061
+ affiliates {
8062
+ ...AffiliateFields
8063
+ }
8064
+ }
8065
+ ${AFFILIATE_FIELDS_FRAGMENT}
8066
+ `;
8067
+
8068
+ // src/graphql/hooks/affiliate/hooksQuery.ts
8069
+ var useGetAffiliate = (_id) => {
8070
+ const { data, loading, error, refetch } = useQuery15(GET_AFFILIATE, {
8071
+ fetchPolicy: "network-only",
8072
+ skip: !_id || _id === "",
8073
+ variables: { _id }
8074
+ });
8075
+ const affiliate = data?.affiliate;
8076
+ return {
8077
+ affiliate,
8078
+ error,
8079
+ loading,
8080
+ refetch
8081
+ };
8082
+ };
8083
+ var useGetAffiliates = () => {
8084
+ const { data, loading, error, refetch } = useQuery15(GET_AFFILIATES, {
8085
+ fetchPolicy: "network-only"
8086
+ });
8087
+ const affiliates = data?.affiliates || [];
8088
+ return {
8089
+ affiliates,
8090
+ error,
8091
+ loading,
8092
+ refetch
8093
+ };
8094
+ };
8095
+
7977
8096
  // src/images/index.ts
7978
8097
  var PKG = "@timardex/cluemart-shared";
7979
8098
  var IMAGE_EXTENSION = ".webp";
@@ -8402,8 +8521,11 @@ var fonts = {
8402
8521
  }
8403
8522
  };
8404
8523
  export {
8524
+ AFFILIATE_REWARDS,
8405
8525
  ANDROID_URL,
8406
8526
  CLUEMART_MAIN_DOMAIN_URL,
8527
+ CM_AFFILIATE_PROMO_CODE,
8528
+ CM_SCHOOL_PROMO_CODE,
8407
8529
  DEFAULT_RESOURCES_RETURN_LIMIT,
8408
8530
  DEFAULT_RESOURCES_RETURN_OFFSET,
8409
8531
  DEFAULT_SHARE_OG_IMAGE,
@@ -8413,6 +8535,7 @@ export {
8413
8535
  EnumAdStatus,
8414
8536
  EnumAdStyle,
8415
8537
  EnumAdType,
8538
+ EnumAffiliateRewardType,
8416
8539
  EnumBillingPeriod,
8417
8540
  EnumChatReportReason,
8418
8541
  EnumChatType,
@@ -8529,6 +8652,7 @@ export {
8529
8652
  companyContactFields,
8530
8653
  computeDailyClueState,
8531
8654
  contactUsFields,
8655
+ createAffiliateReward,
8532
8656
  darkColors,
8533
8657
  dateFormat,
8534
8658
  emailField,
@@ -8693,6 +8817,8 @@ export {
8693
8817
  useGetAd,
8694
8818
  useGetAds,
8695
8819
  useGetAdsByRegion,
8820
+ useGetAffiliate,
8821
+ useGetAffiliates,
8696
8822
  useGetAppSettings,
8697
8823
  useGetChat,
8698
8824
  useGetChatSubscription,