@timardex/cluemart-shared 1.5.598 → 1.5.600
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/{chunk-YV2JDG4R.mjs → chunk-3VUHAHP7.mjs} +5 -86
- package/dist/chunk-3VUHAHP7.mjs.map +1 -0
- package/dist/{chunk-YOWTDF2C.mjs → chunk-GSOSJNID.mjs} +22 -25
- package/dist/chunk-GSOSJNID.mjs.map +1 -0
- package/dist/chunk-X4VPNOHX.mjs +88 -0
- package/dist/chunk-X4VPNOHX.mjs.map +1 -0
- package/dist/{chunk-2NQUR2AV.mjs → chunk-ZDDWPO5Y.mjs} +2 -2
- package/dist/formFields/index.mjs +3 -2
- package/dist/hooks/index.mjs +8 -6
- package/dist/hooks/index.mjs.map +1 -1
- package/dist/index.cjs +22 -24
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +24 -10
- package/dist/index.d.ts +24 -10
- package/dist/index.mjs +17 -24
- package/dist/index.mjs.map +1 -1
- package/dist/sharing/index.cjs +63 -26
- package/dist/sharing/index.cjs.map +1 -1
- package/dist/sharing/index.d.mts +24 -10
- package/dist/sharing/index.d.ts +24 -10
- package/dist/sharing/index.mjs +14 -3
- package/dist/utils/index.mjs +13 -11
- package/package.json +1 -1
- package/dist/chunk-YOWTDF2C.mjs.map +0 -1
- package/dist/chunk-YV2JDG4R.mjs.map +0 -1
- /package/dist/{chunk-2NQUR2AV.mjs.map → chunk-ZDDWPO5Y.mjs.map} +0 -0
package/dist/index.d.mts
CHANGED
|
@@ -2686,6 +2686,8 @@ type ShareVendorInfoForApplication = {
|
|
|
2686
2686
|
};
|
|
2687
2687
|
};
|
|
2688
2688
|
|
|
2689
|
+
/** Formats event `startDate` (`DD-MM-YYYY`) for share copy — same as share preview UI. */
|
|
2690
|
+
declare function formatShareMarketDate(dateStr: string): string;
|
|
2689
2691
|
declare function formatStallCapacityLabel(stallCapacity: number): string;
|
|
2690
2692
|
declare function buildInvitationShareDescription(event: ShareEventForInvitation, eventInfo: ShareEventInfoForInvitation | null | undefined): string;
|
|
2691
2693
|
declare function buildApplicationShareDescription(vendor: ShareVendorForApplication, vendorInfo: ShareVendorInfoForApplication | null | undefined): string;
|
|
@@ -2724,10 +2726,18 @@ declare function formatCategoryLabel(category: ShareVendorCategory): string;
|
|
|
2724
2726
|
declare const SHARE_DESCRIPTION_SECTION_SEPARATOR = " \u00B7 ";
|
|
2725
2727
|
/** Blank line between share sections — title, address, dates, URL, etc. */
|
|
2726
2728
|
declare const SHARE_DESCRIPTION_SECTION_BREAK = "\n\n";
|
|
2729
|
+
/**
|
|
2730
|
+
* Line break for `og:description` meta content. Use instead of `\n` — Next.js
|
|
2731
|
+
* HTML serialisation collapses literal newlines to spaces; Facebook reads ` `.
|
|
2732
|
+
*/
|
|
2733
|
+
declare const OG_DESCRIPTION_LINE_BREAK = " ";
|
|
2734
|
+
/** Joins OG description sections for Facebook link cards (and Twitter). */
|
|
2735
|
+
declare function joinShareOgDescriptionSections(sections: ReadonlyArray<string | false | null | undefined>): string;
|
|
2727
2736
|
declare function joinShareDescriptionSections(sections: ReadonlyArray<string | false | null | undefined>): string;
|
|
2728
2737
|
|
|
2738
|
+
declare function splitShareDescriptionSections(value: string): string[];
|
|
2729
2739
|
/**
|
|
2730
|
-
* Share copy with a blank line between each section (
|
|
2740
|
+
* Share copy with a blank line between each section (share sheet message, previews).
|
|
2731
2741
|
*/
|
|
2732
2742
|
declare function formatShareSectionsForMultilineDisplay(value: string): string;
|
|
2733
2743
|
/**
|
|
@@ -2735,21 +2745,25 @@ declare function formatShareSectionsForMultilineDisplay(value: string): string;
|
|
|
2735
2745
|
*/
|
|
2736
2746
|
declare function formatShareSectionsForCompactDisplay(value: string): string;
|
|
2737
2747
|
/**
|
|
2738
|
-
* Formats share descriptions for Open Graph / Twitter meta tags
|
|
2739
|
-
*
|
|
2748
|
+
* Formats share descriptions for Open Graph / Twitter meta tags.
|
|
2749
|
+
* Sections are joined with {@link OG_DESCRIPTION_LINE_BREAK} (` `).
|
|
2740
2750
|
*/
|
|
2741
2751
|
declare function normalizeShareOgDescription(value: string): string;
|
|
2742
2752
|
/**
|
|
2743
|
-
* Quote text for Facebook ShareDialog on iOS.
|
|
2753
|
+
* Quote text for Facebook ShareDialog on iOS (`ShareLinkContent.quote`).
|
|
2744
2754
|
*
|
|
2745
|
-
*
|
|
2746
|
-
*
|
|
2747
|
-
* paragraph breaks on facebook.com; a body-only quote tended to render as one
|
|
2748
|
-
* chunk in the browser.
|
|
2755
|
+
* Title + blank lines + body sections. URL is omitted — `contentUrl` supplies
|
|
2756
|
+
* the link card (OG on `/share/*` controls card title/image).
|
|
2749
2757
|
*/
|
|
2750
2758
|
declare function buildFacebookShareQuote(title: string, description: string): string | undefined;
|
|
2751
2759
|
/**
|
|
2752
|
-
* Open Graph / Twitter description
|
|
2760
|
+
* Open Graph / Twitter description from pre-built section strings.
|
|
2761
|
+
* Prefer {@link joinShareOgDescriptionSections} when sections are already known.
|
|
2762
|
+
*/
|
|
2763
|
+
declare function buildShareOgDescriptionFromSections(sections: ReadonlyArray<string | false | null | undefined>): string;
|
|
2764
|
+
/**
|
|
2765
|
+
* Open Graph / Twitter description — body sections only (`og:title` is separate).
|
|
2766
|
+
* Multiline / legacy ` · ` input is split into sections, then joined with ` `.
|
|
2753
2767
|
*/
|
|
2754
2768
|
declare function buildShareOgDescription(_title: string, description: string): string;
|
|
2755
2769
|
|
|
@@ -2872,4 +2886,4 @@ declare const ANDROID_URL = "https://play.google.com/store/apps/details?id=com.t
|
|
|
2872
2886
|
declare const SCHOOL_MIN_STUDENT_COUNT = 300;
|
|
2873
2887
|
declare const SCHOOL_MAX_STUDENT_COUNT = 0;
|
|
2874
2888
|
|
|
2875
|
-
export { ANDROID_URL, type AdFormData, type AdResource, type AdType, type AdminUpdateResourceType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, 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_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, 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, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventStatusType, type EventType, type FormDateField, type FormField, 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, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type MiniQuizAnswer, type MiniQuizAnsweredQuestion, type MiniQuizBaseGame, type MiniQuizGameData, type MiniQuizQuestion, type NotificationCount, type NotificationDataType, type NotificationType, type Nullable, 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 PlacePrediction, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostShareResourceType, type PostType, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, RESOURCE_SHARE_TYPES_FOR_URL, type RefundPolicy, type Region, type RegisterFormData, type RelationDate, type RelationSharePathType, type RelationShareResourceType, type 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_DESCRIPTION_SECTION_BREAK, SHARE_DESCRIPTION_SECTION_SEPARATOR, SHARE_RESOURCE_LABEL, SHARE_SITE_URL, SHARE_TYPE_PATH_REGEX, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventDateTime, type ShareEventForInvitation, type ShareEventInfoForInvitation, type ShareResourceType, type ShareStallType, type ShareType, type ShareVendorCategory, type ShareVendorForApplication, type ShareVendorInfoForApplication, type SocialMediaType, type StallType, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, type TermsAgreement, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetEventsByRegionOptions, 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, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildFacebookShareQuote, buildInvitationShareDescription, buildShareOgDescription, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, companyContactFields, computeDailyClueState, contactUsFields, darkColors, dateFormat, defaultEventFormValues, defaultEventInfoFormValues, defaultLocation, defaultPartnerFormValues, defaultUnregisteredVendorFormValues, defaultVendorFormValues, defaultVendorInfoFormValues, emailField, eventBasicInfoFields, eventEndDateFields, eventInfo, eventInfoPaymentInfo, eventStartDateFields, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareSectionsForCompactDisplay, formatShareSectionsForMultilineDisplay, formatStallCapacityLabel, formatTimestamp, gameScreenIdentifierList, gameTypeToDisplayName, getCurrentAndFutureDates, globalDefaultValues, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, joinShareDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, mapBaseResourceTypeToFormData, normalizeShareOgDescription, normalizeShareRouteId, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, seededShuffle, socialMediaFields, sortDatesChronologically, stallTypeOptions, statusOptions, tagOptions, timeFormat, toNZTime, truncateText, useAdForm, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useAppSettingsForm, useCancelSubscription, useContactUs, useContactUsForm, 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, useEventForm, useEventInfoForm, 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, useLocationSearch, useLogin, useLoginForm, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, usePartnerForm, usePostForm, useRefreshToken, useRegister, useRegisterForm, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useRequestPasswordResetForm, useResetPassword, useResetPasswordForm, useSchoolForm, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUnregisteredVendorForm, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdateMiniQuizGame, useUpdatePartner, useUpdatePost, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useUserForm, useValidateVerificationToken, useValidateVerificationTokenForm, useVendorForm, useVendorInfoForm, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
|
|
2889
|
+
export { ANDROID_URL, type AdFormData, type AdResource, type AdType, type AdminUpdateResourceType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, 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_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, 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, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventStatusType, type EventType, type FormDateField, type FormField, 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, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type MiniQuizAnswer, type MiniQuizAnsweredQuestion, type MiniQuizBaseGame, type MiniQuizGameData, type MiniQuizQuestion, 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 PlacePrediction, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostShareResourceType, type PostType, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, RESOURCE_SHARE_TYPES_FOR_URL, type RefundPolicy, type Region, type RegisterFormData, type RelationDate, type RelationSharePathType, type RelationShareResourceType, type 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_DESCRIPTION_SECTION_BREAK, SHARE_DESCRIPTION_SECTION_SEPARATOR, SHARE_RESOURCE_LABEL, SHARE_SITE_URL, SHARE_TYPE_PATH_REGEX, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventDateTime, type ShareEventForInvitation, type ShareEventInfoForInvitation, type ShareResourceType, type ShareStallType, type ShareType, type ShareVendorCategory, type ShareVendorForApplication, type ShareVendorInfoForApplication, type SocialMediaType, type StallType, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, type TermsAgreement, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetEventsByRegionOptions, 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, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildFacebookShareQuote, buildInvitationShareDescription, buildShareOgDescription, buildShareOgDescriptionFromSections, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, companyContactFields, computeDailyClueState, contactUsFields, darkColors, dateFormat, defaultEventFormValues, defaultEventInfoFormValues, defaultLocation, defaultPartnerFormValues, defaultUnregisteredVendorFormValues, defaultVendorFormValues, defaultVendorInfoFormValues, emailField, eventBasicInfoFields, eventEndDateFields, eventInfo, eventInfoPaymentInfo, eventStartDateFields, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareMarketDate, formatShareSectionsForCompactDisplay, formatShareSectionsForMultilineDisplay, formatStallCapacityLabel, formatTimestamp, gameScreenIdentifierList, gameTypeToDisplayName, getCurrentAndFutureDates, globalDefaultValues, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, joinShareDescriptionSections, joinShareOgDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, mapBaseResourceTypeToFormData, normalizeShareOgDescription, normalizeShareRouteId, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, seededShuffle, socialMediaFields, sortDatesChronologically, splitShareDescriptionSections, stallTypeOptions, statusOptions, tagOptions, timeFormat, toNZTime, truncateText, useAdForm, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useAppSettingsForm, useCancelSubscription, useContactUs, useContactUsForm, 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, useEventForm, useEventInfoForm, 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, useLocationSearch, useLogin, useLoginForm, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, usePartnerForm, usePostForm, useRefreshToken, useRegister, useRegisterForm, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useRequestPasswordResetForm, useResetPassword, useResetPasswordForm, useSchoolForm, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUnregisteredVendorForm, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdateMiniQuizGame, useUpdatePartner, useUpdatePost, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useUserForm, useValidateVerificationToken, useValidateVerificationTokenForm, useVendorForm, useVendorInfoForm, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
|
package/dist/index.d.ts
CHANGED
|
@@ -2686,6 +2686,8 @@ type ShareVendorInfoForApplication = {
|
|
|
2686
2686
|
};
|
|
2687
2687
|
};
|
|
2688
2688
|
|
|
2689
|
+
/** Formats event `startDate` (`DD-MM-YYYY`) for share copy — same as share preview UI. */
|
|
2690
|
+
declare function formatShareMarketDate(dateStr: string): string;
|
|
2689
2691
|
declare function formatStallCapacityLabel(stallCapacity: number): string;
|
|
2690
2692
|
declare function buildInvitationShareDescription(event: ShareEventForInvitation, eventInfo: ShareEventInfoForInvitation | null | undefined): string;
|
|
2691
2693
|
declare function buildApplicationShareDescription(vendor: ShareVendorForApplication, vendorInfo: ShareVendorInfoForApplication | null | undefined): string;
|
|
@@ -2724,10 +2726,18 @@ declare function formatCategoryLabel(category: ShareVendorCategory): string;
|
|
|
2724
2726
|
declare const SHARE_DESCRIPTION_SECTION_SEPARATOR = " \u00B7 ";
|
|
2725
2727
|
/** Blank line between share sections — title, address, dates, URL, etc. */
|
|
2726
2728
|
declare const SHARE_DESCRIPTION_SECTION_BREAK = "\n\n";
|
|
2729
|
+
/**
|
|
2730
|
+
* Line break for `og:description` meta content. Use instead of `\n` — Next.js
|
|
2731
|
+
* HTML serialisation collapses literal newlines to spaces; Facebook reads ` `.
|
|
2732
|
+
*/
|
|
2733
|
+
declare const OG_DESCRIPTION_LINE_BREAK = " ";
|
|
2734
|
+
/** Joins OG description sections for Facebook link cards (and Twitter). */
|
|
2735
|
+
declare function joinShareOgDescriptionSections(sections: ReadonlyArray<string | false | null | undefined>): string;
|
|
2727
2736
|
declare function joinShareDescriptionSections(sections: ReadonlyArray<string | false | null | undefined>): string;
|
|
2728
2737
|
|
|
2738
|
+
declare function splitShareDescriptionSections(value: string): string[];
|
|
2729
2739
|
/**
|
|
2730
|
-
* Share copy with a blank line between each section (
|
|
2740
|
+
* Share copy with a blank line between each section (share sheet message, previews).
|
|
2731
2741
|
*/
|
|
2732
2742
|
declare function formatShareSectionsForMultilineDisplay(value: string): string;
|
|
2733
2743
|
/**
|
|
@@ -2735,21 +2745,25 @@ declare function formatShareSectionsForMultilineDisplay(value: string): string;
|
|
|
2735
2745
|
*/
|
|
2736
2746
|
declare function formatShareSectionsForCompactDisplay(value: string): string;
|
|
2737
2747
|
/**
|
|
2738
|
-
* Formats share descriptions for Open Graph / Twitter meta tags
|
|
2739
|
-
*
|
|
2748
|
+
* Formats share descriptions for Open Graph / Twitter meta tags.
|
|
2749
|
+
* Sections are joined with {@link OG_DESCRIPTION_LINE_BREAK} (` `).
|
|
2740
2750
|
*/
|
|
2741
2751
|
declare function normalizeShareOgDescription(value: string): string;
|
|
2742
2752
|
/**
|
|
2743
|
-
* Quote text for Facebook ShareDialog on iOS.
|
|
2753
|
+
* Quote text for Facebook ShareDialog on iOS (`ShareLinkContent.quote`).
|
|
2744
2754
|
*
|
|
2745
|
-
*
|
|
2746
|
-
*
|
|
2747
|
-
* paragraph breaks on facebook.com; a body-only quote tended to render as one
|
|
2748
|
-
* chunk in the browser.
|
|
2755
|
+
* Title + blank lines + body sections. URL is omitted — `contentUrl` supplies
|
|
2756
|
+
* the link card (OG on `/share/*` controls card title/image).
|
|
2749
2757
|
*/
|
|
2750
2758
|
declare function buildFacebookShareQuote(title: string, description: string): string | undefined;
|
|
2751
2759
|
/**
|
|
2752
|
-
* Open Graph / Twitter description
|
|
2760
|
+
* Open Graph / Twitter description from pre-built section strings.
|
|
2761
|
+
* Prefer {@link joinShareOgDescriptionSections} when sections are already known.
|
|
2762
|
+
*/
|
|
2763
|
+
declare function buildShareOgDescriptionFromSections(sections: ReadonlyArray<string | false | null | undefined>): string;
|
|
2764
|
+
/**
|
|
2765
|
+
* Open Graph / Twitter description — body sections only (`og:title` is separate).
|
|
2766
|
+
* Multiline / legacy ` · ` input is split into sections, then joined with ` `.
|
|
2753
2767
|
*/
|
|
2754
2768
|
declare function buildShareOgDescription(_title: string, description: string): string;
|
|
2755
2769
|
|
|
@@ -2872,4 +2886,4 @@ declare const ANDROID_URL = "https://play.google.com/store/apps/details?id=com.t
|
|
|
2872
2886
|
declare const SCHOOL_MIN_STUDENT_COUNT = 300;
|
|
2873
2887
|
declare const SCHOOL_MAX_STUDENT_COUNT = 0;
|
|
2874
2888
|
|
|
2875
|
-
export { ANDROID_URL, type AdFormData, type AdResource, type AdType, type AdminUpdateResourceType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, 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_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, 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, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventStatusType, type EventType, type FormDateField, type FormField, 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, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type MiniQuizAnswer, type MiniQuizAnsweredQuestion, type MiniQuizBaseGame, type MiniQuizGameData, type MiniQuizQuestion, type NotificationCount, type NotificationDataType, type NotificationType, type Nullable, 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 PlacePrediction, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostShareResourceType, type PostType, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, RESOURCE_SHARE_TYPES_FOR_URL, type RefundPolicy, type Region, type RegisterFormData, type RelationDate, type RelationSharePathType, type RelationShareResourceType, type 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_DESCRIPTION_SECTION_BREAK, SHARE_DESCRIPTION_SECTION_SEPARATOR, SHARE_RESOURCE_LABEL, SHARE_SITE_URL, SHARE_TYPE_PATH_REGEX, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventDateTime, type ShareEventForInvitation, type ShareEventInfoForInvitation, type ShareResourceType, type ShareStallType, type ShareType, type ShareVendorCategory, type ShareVendorForApplication, type ShareVendorInfoForApplication, type SocialMediaType, type StallType, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, type TermsAgreement, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetEventsByRegionOptions, 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, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildFacebookShareQuote, buildInvitationShareDescription, buildShareOgDescription, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, companyContactFields, computeDailyClueState, contactUsFields, darkColors, dateFormat, defaultEventFormValues, defaultEventInfoFormValues, defaultLocation, defaultPartnerFormValues, defaultUnregisteredVendorFormValues, defaultVendorFormValues, defaultVendorInfoFormValues, emailField, eventBasicInfoFields, eventEndDateFields, eventInfo, eventInfoPaymentInfo, eventStartDateFields, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareSectionsForCompactDisplay, formatShareSectionsForMultilineDisplay, formatStallCapacityLabel, formatTimestamp, gameScreenIdentifierList, gameTypeToDisplayName, getCurrentAndFutureDates, globalDefaultValues, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, joinShareDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, mapBaseResourceTypeToFormData, normalizeShareOgDescription, normalizeShareRouteId, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, seededShuffle, socialMediaFields, sortDatesChronologically, stallTypeOptions, statusOptions, tagOptions, timeFormat, toNZTime, truncateText, useAdForm, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useAppSettingsForm, useCancelSubscription, useContactUs, useContactUsForm, 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, useEventForm, useEventInfoForm, 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, useLocationSearch, useLogin, useLoginForm, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, usePartnerForm, usePostForm, useRefreshToken, useRegister, useRegisterForm, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useRequestPasswordResetForm, useResetPassword, useResetPasswordForm, useSchoolForm, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUnregisteredVendorForm, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdateMiniQuizGame, useUpdatePartner, useUpdatePost, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useUserForm, useValidateVerificationToken, useValidateVerificationTokenForm, useVendorForm, useVendorInfoForm, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
|
|
2889
|
+
export { ANDROID_URL, type AdFormData, type AdResource, type AdType, type AdminUpdateResourceType, type AppSettingsFormData, type AppSettingsType, type AssociateType, type BadgeBasename, type BadgeId, type BaseGameMap, type BaseGameType, type BaseResourceType, type BaseResourceTypeFormData, type Category, type ChatMessageInput, type ChatMessageReaction, type ChatMessageReplyPreview, type ChatMessageSeen, type ChatMessageType, type ChatType, type CluiImageBasename, type CluiImageId, type ContactUsFormData, type CreateAdFormData, 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_SHARE_OG_IMAGE, type DailyClueBaseGame, type DailyClueGameData, type DateTimeType, type DateTimeWithPriceType, type DeviceInfo, 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, EnumSocialMedia, EnumSubscriptionStatus, EnumUserLicence, EnumUserRole, EnumVendorType, EnumVerificationType, type EventFormData, type EventInfoFormData, type EventInfoType, type EventListItemType, type EventStatusType, type EventType, type FormDateField, type FormField, 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, type LocationGeoType, type LocationType, type LoginFormData, type LogoBasename, type LogoId, type MarketingMaterialRequestInputType, type MiniQuizAnswer, type MiniQuizAnsweredQuestion, type MiniQuizBaseGame, type MiniQuizGameData, type MiniQuizQuestion, 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 PlacePrediction, type PostContentData, type PostContentFormData, type PostContentGame, type PostContentImage, type PostContentList, type PostContentTextarea, type PostContentType, type PostContentVideo, type PostFileInput, type PostFormData, type PostShareResourceType, type PostType, type PosterAssetId, type PosterImageBasename, type PosterInputType, type PosterUsageType, type PromoCodeType, type PublicSharePathType, RELATION_SHARE_APPLICATION, RELATION_SHARE_INVITATION, RELATION_SHARE_RESOURCE_TYPES, RESOURCE_SHARE_TYPES, RESOURCE_SHARE_TYPES_FOR_URL, type RefundPolicy, type Region, type RegisterFormData, type RelationDate, type RelationSharePathType, type RelationShareResourceType, type 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_DESCRIPTION_SECTION_BREAK, SHARE_DESCRIPTION_SECTION_SEPARATOR, SHARE_RESOURCE_LABEL, SHARE_SITE_URL, SHARE_TYPE_PATH_REGEX, type SchoolCampaignType, type SchoolFormData, type SchoolRegisteredUserType, type SchoolReturnType, type SchoolType, type ShareEventDateTime, type ShareEventForInvitation, type ShareEventInfoForInvitation, type ShareResourceType, type ShareStallType, type ShareType, type ShareVendorCategory, type ShareVendorForApplication, type ShareVendorInfoForApplication, type SocialMediaType, type StallType, type StripeSubscription, type Subcategory, type SubcategoryItems, type SubscriptionPlanData, type SubscriptionPlansResponse, type SubscriptionPricingData, type SubscriptionStatusData, type TermsAgreement, USER_STORAGE_KEY, type UnregisteredVendorFormData, type UnregisteredVendorInvitationType, type UnregisteredVendorType, type UseGetEventsByRegionOptions, 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, availableCategories, availableRegionOptions, availableRegionTypes, availableTagTypes, badgeFiles, badgeIds, badges, buildApplicationShareDescription, buildFacebookShareQuote, buildInvitationShareDescription, buildShareOgDescription, buildShareOgDescriptionFromSections, buildSharePagePath, buildShareUrl, capitalizeFirstLetter, categoryColors, cluemartSocialMedia, cluiFiles, cluiIds, cluiImages, companyContactFields, computeDailyClueState, contactUsFields, darkColors, dateFormat, defaultEventFormValues, defaultEventInfoFormValues, defaultLocation, defaultPartnerFormValues, defaultUnregisteredVendorFormValues, defaultVendorFormValues, defaultVendorInfoFormValues, emailField, eventBasicInfoFields, eventEndDateFields, eventInfo, eventInfoPaymentInfo, eventStartDateFields, fonts, foodFlavourOptions, formatCategoryLabel, formatDate, formatShareMarketDate, formatShareSectionsForCompactDisplay, formatShareSectionsForMultilineDisplay, formatStallCapacityLabel, formatTimestamp, gameScreenIdentifierList, gameTypeToDisplayName, getCurrentAndFutureDates, globalDefaultValues, iconFiles, iconIds, icons, isFutureDatesBeforeThreshold, isIsoDateString, isPostShareResourceType, isRelationShareResourceType, joinShareDescriptionSections, joinShareOgDescriptionSections, licenseNiceNames, lightColors, loginFields, logoFiles, logoIds, logos, mapArrayToOptions, mapBaseResourceTypeToFormData, normalizeShareOgDescription, normalizeShareRouteId, normalizeUrl, nzStartOfDay, otherImages, otherImagesFiles, otherImagesIds, packagingOptions, partnerBasicInfoFields, paymentMethodOptions, posterFiles, posterIds, posters, priceUnits, producedIngOptions, productLabelGroups, profileFields, refundPolicyOptions, registerFields, removeTypename, requestPasswordResetFields, requirementsOptions, resetPasswordFields, seededShuffle, socialMediaFields, sortDatesChronologically, splitShareDescriptionSections, stallTypeOptions, statusOptions, tagOptions, timeFormat, toNZTime, truncateText, useAdForm, useAddParticipantToChat, useAddUserFavouriteResource, useAddUserGoingResource, useAddUserInterestResource, useAddUserPresentResource, useAdminPermanentlyDeleteResource, useAdminResendUserVerificationEmail, useAdminUpdateResourceType, useAppSettingsForm, useCancelSubscription, useContactUs, useContactUsForm, 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, useEventForm, useEventInfoForm, 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, useLocationSearch, useLogin, useLoginForm, useLogout, useMarkAllNotificationsRead, useMarkChatMessagesSeen, useMarkNotificationRead, usePartnerForm, usePostForm, useRefreshToken, useRegister, useRegisterForm, useRemoveParticipantFromChat, useRemoveUserFavouriteResource, useRemoveUserGoingResource, useRemoveUserInterestResource, useRemoveUserPresentResource, useReportChatUser, useRequestMarketingMaterial, useRequestPasswordReset, useRequestPasswordResetForm, useResetPassword, useResetPasswordForm, useSchoolForm, useSearchEvents, useSearchPartners, useSearchVendors, useSelectPackage, useSelectStandardPackage, useSendChatMessage, useStartGame, useToggleChatMessageLike, useUnlinkUnregisteredVendorByInviterId, useUnregisteredVendorForm, useUpdateAd, useUpdateAppSettings, useUpdateDailyClueGame, useUpdateEvent, useUpdateEventInfo, useUpdateGoogleImportedMarkets, useUpdateMiniQuizGame, useUpdatePartner, useUpdatePost, useUpdateRelation, useUpdateSchool, useUpdateSubscriptionPlan, useUpdateUnregisteredVendor, useUpdateUser, useUpdateVendor, useUpdateVendorInfo, useUserForm, useValidateVerificationToken, useValidateVerificationTokenForm, useVendorForm, useVendorInfoForm, validateVerificationTokenFields, vendorAvailability, vendorBasicInfoFields, vendorCompliance, vendorElectricity, vendorEndDateFields, vendorFoodFlavour, vendorFullAddress, vendorGazebo, vendorLocationDescription, vendorMenuFields, vendorPackaging, vendorPriceRange, vendorProducedIn, vendorStallSize, vendorStartDateFields, vendorTable };
|
package/dist/index.mjs
CHANGED
|
@@ -8482,21 +8482,17 @@ function formatCategoryLabel(category) {
|
|
|
8482
8482
|
// src/sharing/joinShareDescriptionSections.ts
|
|
8483
8483
|
var SHARE_DESCRIPTION_SECTION_SEPARATOR = " \xB7 ";
|
|
8484
8484
|
var SHARE_DESCRIPTION_SECTION_BREAK = "\n\n";
|
|
8485
|
+
var OG_DESCRIPTION_LINE_BREAK = " ";
|
|
8486
|
+
function joinShareOgDescriptionSections(sections) {
|
|
8487
|
+
return sections.map((section) => typeof section === "string" ? section.trim() : "").filter((section) => section.length > 0).join(OG_DESCRIPTION_LINE_BREAK);
|
|
8488
|
+
}
|
|
8485
8489
|
function joinShareDescriptionSections(sections) {
|
|
8486
8490
|
return sections.filter((section) => Boolean(section)).join(SHARE_DESCRIPTION_SECTION_BREAK);
|
|
8487
8491
|
}
|
|
8488
8492
|
|
|
8489
8493
|
// src/sharing/buildRelationShareDescription.ts
|
|
8490
|
-
function
|
|
8491
|
-
|
|
8492
|
-
return new Intl.DateTimeFormat("en-NZ", {
|
|
8493
|
-
day: "numeric",
|
|
8494
|
-
month: "short",
|
|
8495
|
-
year: "numeric"
|
|
8496
|
-
}).format(new Date(isoDate));
|
|
8497
|
-
} catch {
|
|
8498
|
-
return isoDate;
|
|
8499
|
-
}
|
|
8494
|
+
function formatShareMarketDate(dateStr) {
|
|
8495
|
+
return formatDate(dateStr, "date");
|
|
8500
8496
|
}
|
|
8501
8497
|
function formatStallCapacityLabel(stallCapacity) {
|
|
8502
8498
|
return stallCapacity > 0 ? ` (${stallCapacity} spaces available)` : " - Full";
|
|
@@ -8510,7 +8506,7 @@ function buildInvitationShareDescription(event, eventInfo2) {
|
|
|
8510
8506
|
const sections = [
|
|
8511
8507
|
event.location.fullAddress,
|
|
8512
8508
|
...event.dateTime.map((date3) => {
|
|
8513
|
-
const start =
|
|
8509
|
+
const start = formatShareMarketDate(date3.startDate);
|
|
8514
8510
|
return `Market date: ${start}`;
|
|
8515
8511
|
}),
|
|
8516
8512
|
`Application deadline: vendors must apply at least ${eventInfo2.applicationDeadlineHours} hours before each market date.`,
|
|
@@ -8642,14 +8638,7 @@ function formatShareSectionsForCompactDisplay(value) {
|
|
|
8642
8638
|
);
|
|
8643
8639
|
}
|
|
8644
8640
|
function normalizeShareOgDescription(value) {
|
|
8645
|
-
|
|
8646
|
-
if (!trimmed) {
|
|
8647
|
-
return "";
|
|
8648
|
-
}
|
|
8649
|
-
if (/\n\n/.test(trimmed) || trimmed.includes(SHARE_DESCRIPTION_SECTION_SEPARATOR)) {
|
|
8650
|
-
return formatShareSectionsForCompactDisplay(trimmed);
|
|
8651
|
-
}
|
|
8652
|
-
return trimmed.replace(/\s+/g, " ").trim();
|
|
8641
|
+
return joinShareOgDescriptionSections(splitShareDescriptionSections(value));
|
|
8653
8642
|
}
|
|
8654
8643
|
function buildFacebookShareQuote(title, description) {
|
|
8655
8644
|
const titleSection = normalizeShareSection(title);
|
|
@@ -8660,12 +8649,11 @@ function buildFacebookShareQuote(title, description) {
|
|
|
8660
8649
|
const quote = sections.join(SHARE_DESCRIPTION_SECTION_BREAK).trim();
|
|
8661
8650
|
return quote.length > 0 ? quote : void 0;
|
|
8662
8651
|
}
|
|
8652
|
+
function buildShareOgDescriptionFromSections(sections) {
|
|
8653
|
+
return joinShareOgDescriptionSections(sections);
|
|
8654
|
+
}
|
|
8663
8655
|
function buildShareOgDescription(_title, description) {
|
|
8664
|
-
|
|
8665
|
-
if (multiline) {
|
|
8666
|
-
return multiline;
|
|
8667
|
-
}
|
|
8668
|
-
return normalizeShareOgDescription(description);
|
|
8656
|
+
return joinShareOgDescriptionSections(splitShareDescriptionSections(description));
|
|
8669
8657
|
}
|
|
8670
8658
|
|
|
8671
8659
|
// src/sharing/normalizeShareRouteId.ts
|
|
@@ -8805,6 +8793,7 @@ export {
|
|
|
8805
8793
|
IMAGE_EXTENSION,
|
|
8806
8794
|
IOS_URL,
|
|
8807
8795
|
ImageTypeEnum,
|
|
8796
|
+
OG_DESCRIPTION_LINE_BREAK,
|
|
8808
8797
|
POST_SHARE_RESOURCE_TYPES,
|
|
8809
8798
|
PROMO_CODE_PREFIX,
|
|
8810
8799
|
PUBLIC_SHARE_PATH_TYPES,
|
|
@@ -8836,6 +8825,7 @@ export {
|
|
|
8836
8825
|
buildFacebookShareQuote,
|
|
8837
8826
|
buildInvitationShareDescription,
|
|
8838
8827
|
buildShareOgDescription,
|
|
8828
|
+
buildShareOgDescriptionFromSections,
|
|
8839
8829
|
buildSharePagePath,
|
|
8840
8830
|
buildShareUrl,
|
|
8841
8831
|
capitalizeFirstLetter,
|
|
@@ -8866,6 +8856,7 @@ export {
|
|
|
8866
8856
|
foodFlavourOptions,
|
|
8867
8857
|
formatCategoryLabel,
|
|
8868
8858
|
formatDate,
|
|
8859
|
+
formatShareMarketDate,
|
|
8869
8860
|
formatShareSectionsForCompactDisplay,
|
|
8870
8861
|
formatShareSectionsForMultilineDisplay,
|
|
8871
8862
|
formatStallCapacityLabel,
|
|
@@ -8882,6 +8873,7 @@ export {
|
|
|
8882
8873
|
isPostShareResourceType,
|
|
8883
8874
|
isRelationShareResourceType,
|
|
8884
8875
|
joinShareDescriptionSections,
|
|
8876
|
+
joinShareOgDescriptionSections,
|
|
8885
8877
|
licenseNiceNames,
|
|
8886
8878
|
lightColors,
|
|
8887
8879
|
loginFields,
|
|
@@ -8916,6 +8908,7 @@ export {
|
|
|
8916
8908
|
seededShuffle,
|
|
8917
8909
|
socialMediaFields,
|
|
8918
8910
|
sortDatesChronologically,
|
|
8911
|
+
splitShareDescriptionSections,
|
|
8919
8912
|
stallTypeOptions,
|
|
8920
8913
|
statusOptions,
|
|
8921
8914
|
tagOptions,
|