@timardex/cluemart-shared 2.5.1 → 2.5.2
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-NEOBS55J.mjs → chunk-T736WX7J.mjs} +5 -5
- package/dist/{chunk-NEOBS55J.mjs.map → chunk-T736WX7J.mjs.map} +1 -1
- package/dist/{chunk-4CQLKIQ6.mjs → chunk-TGEYOSSX.mjs} +24 -2
- package/dist/chunk-TGEYOSSX.mjs.map +1 -0
- package/dist/{chunk-H6HM2FOZ.mjs → chunk-WRYRBSRZ.mjs} +2 -2
- package/dist/{chunk-CQ26N3W6.mjs → chunk-YJJUTHBX.mjs} +2 -2
- package/dist/formFields/index.cjs.map +1 -1
- package/dist/formFields/index.mjs +3 -3
- package/dist/hooks/index.cjs.map +1 -1
- package/dist/hooks/index.mjs +4 -4
- package/dist/index.cjs +27 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +17 -1
- package/dist/index.d.ts +17 -1
- package/dist/index.mjs +25 -3
- package/dist/index.mjs.map +1 -1
- package/dist/sharing/index.cjs +2 -1
- package/dist/sharing/index.cjs.map +1 -1
- package/dist/sharing/index.mjs +2 -2
- package/dist/utils/index.cjs +27 -3
- package/dist/utils/index.cjs.map +1 -1
- package/dist/utils/index.d.mts +17 -1
- package/dist/utils/index.d.ts +17 -1
- package/dist/utils/index.mjs +6 -2
- package/package.json +1 -1
- package/dist/chunk-4CQLKIQ6.mjs.map +0 -1
- /package/dist/{chunk-H6HM2FOZ.mjs.map → chunk-WRYRBSRZ.mjs.map} +0 -0
- /package/dist/{chunk-CQ26N3W6.mjs.map → chunk-YJJUTHBX.mjs.map} +0 -0
package/dist/utils/index.d.mts
CHANGED
|
@@ -95,6 +95,22 @@ type DateFormat = "date" | "time" | "datetime";
|
|
|
95
95
|
* @returns formatted string based on display option
|
|
96
96
|
*/
|
|
97
97
|
declare const formatDate: (dateStr: string, display?: DateFormat, timeStr?: string) => string;
|
|
98
|
+
/**
|
|
99
|
+
* True when a `dd-mm-yyyy` date falls before today's calendar day in
|
|
100
|
+
* `Pacific/Auckland`. The current day counts as not past, and values that do not
|
|
101
|
+
* parse as a date are never treated as past.
|
|
102
|
+
*/
|
|
103
|
+
declare function isPastDate(dateStr: string): boolean;
|
|
104
|
+
/**
|
|
105
|
+
* Date-option label: the long-form date text, marked `(Past)` when the slot has
|
|
106
|
+
* already happened. Used for the event/vendor date filter pills, which also list
|
|
107
|
+
* historical relation dates.
|
|
108
|
+
*
|
|
109
|
+
* The label and the marker come from the same strict parse, so an impossible or
|
|
110
|
+
* malformed date is returned verbatim rather than being rolled over into a real
|
|
111
|
+
* date that would then contradict the `(Past)` decision.
|
|
112
|
+
*/
|
|
113
|
+
declare function formatDateOptionLabel(dateStr: string): string;
|
|
98
114
|
declare const getCurrentAndFutureDates: <T extends {
|
|
99
115
|
startDate?: string;
|
|
100
116
|
startTime?: string;
|
|
@@ -522,4 +538,4 @@ declare function toUserFacingErrorMessage(error: string | null | undefined, fall
|
|
|
522
538
|
/** Extracts and sanitizes an unknown catch/Apollo error for toasts and alerts. */
|
|
523
539
|
declare function getErrorMessage(error: unknown, fallback?: string): string;
|
|
524
540
|
|
|
525
|
-
export { AD_METRIC_IMPRESSION_RETRY_DELAY_MS, AD_METRIC_ROTATION_INTERVAL_MS, AFFILIATE_PARTICIPANT_TYPE_LABELS, AFFILIATE_REWARDS, ANDROID_URL, BILLING_CATALOG_CURRENCY, BILLING_CATALOG_DEFINITIONS, BILLING_CATALOG_KEYS, CLUEMART_MAIN_DOMAIN_URL, CM_AFFILIATE_PROMO_CODE, CM_SCHOOL_PROMO_CODE, type CalendarSheetContentData, DEFAULT_PAGE_SIZE, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_USER_FACING_ERROR, EVENT_DATE_STATUS_LABELS, EVENT_DATE_STATUS_PERIOD_MAP, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStallholderDateOption, type EventStallholdersData, FUTURE_EVENT_DATE_STATUSES, type GetEventStallholdersDataInput, type GetVendorEventsDataInput, INITIAL_BILLING_CATALOG, IOS_URL, MANUAL_DATE_STATUSES, NETWORK_USER_FACING_ERROR, NZ_TZ, PRESERVED_RELATION_DATE_STATUSES, PostTypeLabels, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, type StallholderFilterOption, type VendorEventDateOption, type VendorEventsData, accumulateItems, availableRegionOptions, availableRegionTypes, billingCatalogDefinitionMatches, buildAdMetricSlotKey, buildCalendarSheetContentData, buildRelationEligibleEventSchedule, capitalizeFirstLetter, cluemartSocialMedia, collectStallholderDateTimes, collectVendorEventRelationDateTimes, computeDailyClueState, computeHasMore, countLetterOccurrences, countLetterOccurrencesUpTo, createAffiliateReward, dateFormat, defaultGetId, eventHasSelectedDate, eventMatchesDateStatusPeriod, eventStartDatesSet, filterDatesByFutureStatus, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, formatDate, formatDistance, formatIrdNumber, formatNZBankAccount, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, generateAdClickId, getAdMetricRotationIndex, getAdMetricRotationSlot, getAllowedEventDateStatuses, getBillingCatalogKeyForSelection, getCurrentAndFutureDates, getDailyClueDayIndex, getDistanceInKilometers, getDistanceInMeters, getErrorMessage, getEventCalendarIsoDates, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getEventStallholdersData, getFutureEventStatus, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUniqueStallholderStartDates, getUniqueStartDates, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsData, getVendorEventsEmptyMessage, hasMatchingEventDate, isFutureDatesBeforeThreshold, isFutureEventDateStatus, isFutureStartDate, isInternalErrorMessage, isIsoDateString, isResourceImageActive, isTransientNetworkError, isUtcMidnight, isValidIrdNumber, isoDateFormat, licenseNiceNames, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeIrdNumber, normalizeResourceImage, normalizeUrl, nzDayKey, nzStartOfDay, paymentMethodOptions, relationHasSelectedDate, removeTypename, resolveResourceImageActive, rewardNiceNames, seededShuffle, shouldShowEventActionsWithWeather, sortDatesChronologically, statusOptions, sumUserOverallPoints, timeFormat, toCalendarIsoDate, toNZTime, toUserFacingErrorMessage, truncateText, updateSingleDateTimeStatus, vendorLicences };
|
|
541
|
+
export { AD_METRIC_IMPRESSION_RETRY_DELAY_MS, AD_METRIC_ROTATION_INTERVAL_MS, AFFILIATE_PARTICIPANT_TYPE_LABELS, AFFILIATE_REWARDS, ANDROID_URL, BILLING_CATALOG_CURRENCY, BILLING_CATALOG_DEFINITIONS, BILLING_CATALOG_KEYS, CLUEMART_MAIN_DOMAIN_URL, CM_AFFILIATE_PROMO_CODE, CM_SCHOOL_PROMO_CODE, type CalendarSheetContentData, DEFAULT_PAGE_SIZE, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_USER_FACING_ERROR, EVENT_DATE_STATUS_LABELS, EVENT_DATE_STATUS_PERIOD_MAP, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStallholderDateOption, type EventStallholdersData, FUTURE_EVENT_DATE_STATUSES, type GetEventStallholdersDataInput, type GetVendorEventsDataInput, INITIAL_BILLING_CATALOG, IOS_URL, MANUAL_DATE_STATUSES, NETWORK_USER_FACING_ERROR, NZ_TZ, PRESERVED_RELATION_DATE_STATUSES, PostTypeLabels, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, type StallholderFilterOption, type VendorEventDateOption, type VendorEventsData, accumulateItems, availableRegionOptions, availableRegionTypes, billingCatalogDefinitionMatches, buildAdMetricSlotKey, buildCalendarSheetContentData, buildRelationEligibleEventSchedule, capitalizeFirstLetter, cluemartSocialMedia, collectStallholderDateTimes, collectVendorEventRelationDateTimes, computeDailyClueState, computeHasMore, countLetterOccurrences, countLetterOccurrencesUpTo, createAffiliateReward, dateFormat, defaultGetId, eventHasSelectedDate, eventMatchesDateStatusPeriod, eventStartDatesSet, filterDatesByFutureStatus, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, formatDate, formatDateOptionLabel, formatDistance, formatIrdNumber, formatNZBankAccount, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, generateAdClickId, getAdMetricRotationIndex, getAdMetricRotationSlot, getAllowedEventDateStatuses, getBillingCatalogKeyForSelection, getCurrentAndFutureDates, getDailyClueDayIndex, getDistanceInKilometers, getDistanceInMeters, getErrorMessage, getEventCalendarIsoDates, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getEventStallholdersData, getFutureEventStatus, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUniqueStallholderStartDates, getUniqueStartDates, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsData, getVendorEventsEmptyMessage, hasMatchingEventDate, isFutureDatesBeforeThreshold, isFutureEventDateStatus, isFutureStartDate, isInternalErrorMessage, isIsoDateString, isPastDate, isResourceImageActive, isTransientNetworkError, isUtcMidnight, isValidIrdNumber, isoDateFormat, licenseNiceNames, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeIrdNumber, normalizeResourceImage, normalizeUrl, nzDayKey, nzStartOfDay, paymentMethodOptions, relationHasSelectedDate, removeTypename, resolveResourceImageActive, rewardNiceNames, seededShuffle, shouldShowEventActionsWithWeather, sortDatesChronologically, statusOptions, sumUserOverallPoints, timeFormat, toCalendarIsoDate, toNZTime, toUserFacingErrorMessage, truncateText, updateSingleDateTimeStatus, vendorLicences };
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -95,6 +95,22 @@ type DateFormat = "date" | "time" | "datetime";
|
|
|
95
95
|
* @returns formatted string based on display option
|
|
96
96
|
*/
|
|
97
97
|
declare const formatDate: (dateStr: string, display?: DateFormat, timeStr?: string) => string;
|
|
98
|
+
/**
|
|
99
|
+
* True when a `dd-mm-yyyy` date falls before today's calendar day in
|
|
100
|
+
* `Pacific/Auckland`. The current day counts as not past, and values that do not
|
|
101
|
+
* parse as a date are never treated as past.
|
|
102
|
+
*/
|
|
103
|
+
declare function isPastDate(dateStr: string): boolean;
|
|
104
|
+
/**
|
|
105
|
+
* Date-option label: the long-form date text, marked `(Past)` when the slot has
|
|
106
|
+
* already happened. Used for the event/vendor date filter pills, which also list
|
|
107
|
+
* historical relation dates.
|
|
108
|
+
*
|
|
109
|
+
* The label and the marker come from the same strict parse, so an impossible or
|
|
110
|
+
* malformed date is returned verbatim rather than being rolled over into a real
|
|
111
|
+
* date that would then contradict the `(Past)` decision.
|
|
112
|
+
*/
|
|
113
|
+
declare function formatDateOptionLabel(dateStr: string): string;
|
|
98
114
|
declare const getCurrentAndFutureDates: <T extends {
|
|
99
115
|
startDate?: string;
|
|
100
116
|
startTime?: string;
|
|
@@ -522,4 +538,4 @@ declare function toUserFacingErrorMessage(error: string | null | undefined, fall
|
|
|
522
538
|
/** Extracts and sanitizes an unknown catch/Apollo error for toasts and alerts. */
|
|
523
539
|
declare function getErrorMessage(error: unknown, fallback?: string): string;
|
|
524
540
|
|
|
525
|
-
export { AD_METRIC_IMPRESSION_RETRY_DELAY_MS, AD_METRIC_ROTATION_INTERVAL_MS, AFFILIATE_PARTICIPANT_TYPE_LABELS, AFFILIATE_REWARDS, ANDROID_URL, BILLING_CATALOG_CURRENCY, BILLING_CATALOG_DEFINITIONS, BILLING_CATALOG_KEYS, CLUEMART_MAIN_DOMAIN_URL, CM_AFFILIATE_PROMO_CODE, CM_SCHOOL_PROMO_CODE, type CalendarSheetContentData, DEFAULT_PAGE_SIZE, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_USER_FACING_ERROR, EVENT_DATE_STATUS_LABELS, EVENT_DATE_STATUS_PERIOD_MAP, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStallholderDateOption, type EventStallholdersData, FUTURE_EVENT_DATE_STATUSES, type GetEventStallholdersDataInput, type GetVendorEventsDataInput, INITIAL_BILLING_CATALOG, IOS_URL, MANUAL_DATE_STATUSES, NETWORK_USER_FACING_ERROR, NZ_TZ, PRESERVED_RELATION_DATE_STATUSES, PostTypeLabels, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, type StallholderFilterOption, type VendorEventDateOption, type VendorEventsData, accumulateItems, availableRegionOptions, availableRegionTypes, billingCatalogDefinitionMatches, buildAdMetricSlotKey, buildCalendarSheetContentData, buildRelationEligibleEventSchedule, capitalizeFirstLetter, cluemartSocialMedia, collectStallholderDateTimes, collectVendorEventRelationDateTimes, computeDailyClueState, computeHasMore, countLetterOccurrences, countLetterOccurrencesUpTo, createAffiliateReward, dateFormat, defaultGetId, eventHasSelectedDate, eventMatchesDateStatusPeriod, eventStartDatesSet, filterDatesByFutureStatus, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, formatDate, formatDistance, formatIrdNumber, formatNZBankAccount, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, generateAdClickId, getAdMetricRotationIndex, getAdMetricRotationSlot, getAllowedEventDateStatuses, getBillingCatalogKeyForSelection, getCurrentAndFutureDates, getDailyClueDayIndex, getDistanceInKilometers, getDistanceInMeters, getErrorMessage, getEventCalendarIsoDates, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getEventStallholdersData, getFutureEventStatus, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUniqueStallholderStartDates, getUniqueStartDates, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsData, getVendorEventsEmptyMessage, hasMatchingEventDate, isFutureDatesBeforeThreshold, isFutureEventDateStatus, isFutureStartDate, isInternalErrorMessage, isIsoDateString, isResourceImageActive, isTransientNetworkError, isUtcMidnight, isValidIrdNumber, isoDateFormat, licenseNiceNames, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeIrdNumber, normalizeResourceImage, normalizeUrl, nzDayKey, nzStartOfDay, paymentMethodOptions, relationHasSelectedDate, removeTypename, resolveResourceImageActive, rewardNiceNames, seededShuffle, shouldShowEventActionsWithWeather, sortDatesChronologically, statusOptions, sumUserOverallPoints, timeFormat, toCalendarIsoDate, toNZTime, toUserFacingErrorMessage, truncateText, updateSingleDateTimeStatus, vendorLicences };
|
|
541
|
+
export { AD_METRIC_IMPRESSION_RETRY_DELAY_MS, AD_METRIC_ROTATION_INTERVAL_MS, AFFILIATE_PARTICIPANT_TYPE_LABELS, AFFILIATE_REWARDS, ANDROID_URL, BILLING_CATALOG_CURRENCY, BILLING_CATALOG_DEFINITIONS, BILLING_CATALOG_KEYS, CLUEMART_MAIN_DOMAIN_URL, CM_AFFILIATE_PROMO_CODE, CM_SCHOOL_PROMO_CODE, type CalendarSheetContentData, DEFAULT_PAGE_SIZE, DEFAULT_RESOURCES_RETURN_LIMIT, DEFAULT_RESOURCES_RETURN_OFFSET, DEFAULT_USER_FACING_ERROR, EVENT_DATE_STATUS_LABELS, EVENT_DATE_STATUS_PERIOD_MAP, type EventScheduleStatusPresentation, type EventScheduleStatusTone, type EventStallholderDateOption, type EventStallholdersData, FUTURE_EVENT_DATE_STATUSES, type GetEventStallholdersDataInput, type GetVendorEventsDataInput, INITIAL_BILLING_CATALOG, IOS_URL, MANUAL_DATE_STATUSES, NETWORK_USER_FACING_ERROR, NZ_TZ, PRESERVED_RELATION_DATE_STATUSES, PostTypeLabels, SCHOOL_MAX_STUDENT_COUNT, SCHOOL_MIN_STUDENT_COUNT, type StallholderFilterOption, type VendorEventDateOption, type VendorEventsData, accumulateItems, availableRegionOptions, availableRegionTypes, billingCatalogDefinitionMatches, buildAdMetricSlotKey, buildCalendarSheetContentData, buildRelationEligibleEventSchedule, capitalizeFirstLetter, cluemartSocialMedia, collectStallholderDateTimes, collectVendorEventRelationDateTimes, computeDailyClueState, computeHasMore, countLetterOccurrences, countLetterOccurrencesUpTo, createAffiliateReward, dateFormat, defaultGetId, eventHasSelectedDate, eventMatchesDateStatusPeriod, eventStartDatesSet, filterDatesByFutureStatus, filterEventsByDateStatusPeriod, filterRegisteredVendorsByEventDatesOnly, filterRegisteredVendorsForEvent, filterUnregisteredVendorsByEventDatesOnly, filterUnregisteredVendorsForEvent, filterVendorEventsBySelectedDate, findEventDateTimeByIsoDate, formatDate, formatDateOptionLabel, formatDistance, formatIrdNumber, formatNZBankAccount, formatTimestamp, fromCalendarIsoDate, futureTimePeriods, generateAdClickId, getAdMetricRotationIndex, getAdMetricRotationSlot, getAllowedEventDateStatuses, getBillingCatalogKeyForSelection, getCurrentAndFutureDates, getDailyClueDayIndex, getDistanceInKilometers, getDistanceInMeters, getErrorMessage, getEventCalendarIsoDates, getEventScheduleStatusLabel, getEventScheduleStatusPresentation, getEventScheduleStatusTone, getEventStallholderEmptyMessage, getEventStallholdersData, getFutureEventStatus, getRegisteredVendorCategoryNames, getRegisteredVendorStartDates, getStallholderCategoryNames, getStallholderCategoryOptions, getUniqueStallholderStartDates, getUniqueStartDates, getUnregisteredVendorCategoryNames, getUnregisteredVendorStartDates, getVendorEventRelationDateOptions, getVendorEventRelationStartDates, getVendorEventsData, getVendorEventsEmptyMessage, hasMatchingEventDate, isFutureDatesBeforeThreshold, isFutureEventDateStatus, isFutureStartDate, isInternalErrorMessage, isIsoDateString, isPastDate, isResourceImageActive, isTransientNetworkError, isUtcMidnight, isValidIrdNumber, isoDateFormat, licenseNiceNames, mapArrayToOptions, matchesCategory, matchesSelectedDate, normalizeIrdNumber, normalizeResourceImage, normalizeUrl, nzDayKey, nzStartOfDay, paymentMethodOptions, relationHasSelectedDate, removeTypename, resolveResourceImageActive, rewardNiceNames, seededShuffle, shouldShowEventActionsWithWeather, sortDatesChronologically, statusOptions, sumUserOverallPoints, timeFormat, toCalendarIsoDate, toNZTime, toUserFacingErrorMessage, truncateText, updateSingleDateTimeStatus, vendorLicences };
|
package/dist/utils/index.mjs
CHANGED
|
@@ -85,7 +85,7 @@ import {
|
|
|
85
85
|
toUserFacingErrorMessage,
|
|
86
86
|
truncateText,
|
|
87
87
|
vendorLicences
|
|
88
|
-
} from "../chunk-
|
|
88
|
+
} from "../chunk-T736WX7J.mjs";
|
|
89
89
|
import {
|
|
90
90
|
formatDistance,
|
|
91
91
|
getDistanceInKilometers,
|
|
@@ -103,6 +103,7 @@ import {
|
|
|
103
103
|
filterDatesByFutureStatus,
|
|
104
104
|
filterEventsByDateStatusPeriod,
|
|
105
105
|
formatDate,
|
|
106
|
+
formatDateOptionLabel,
|
|
106
107
|
formatTimestamp,
|
|
107
108
|
futureTimePeriods,
|
|
108
109
|
getAllowedEventDateStatuses,
|
|
@@ -113,6 +114,7 @@ import {
|
|
|
113
114
|
isFutureEventDateStatus,
|
|
114
115
|
isFutureStartDate,
|
|
115
116
|
isIsoDateString,
|
|
117
|
+
isPastDate,
|
|
116
118
|
isUtcMidnight,
|
|
117
119
|
isoDateFormat,
|
|
118
120
|
nzDayKey,
|
|
@@ -121,7 +123,7 @@ import {
|
|
|
121
123
|
timeFormat,
|
|
122
124
|
toNZTime,
|
|
123
125
|
updateSingleDateTimeStatus
|
|
124
|
-
} from "../chunk-
|
|
126
|
+
} from "../chunk-TGEYOSSX.mjs";
|
|
125
127
|
import "../chunk-WWAHS5R2.mjs";
|
|
126
128
|
import {
|
|
127
129
|
isTransientNetworkError
|
|
@@ -198,6 +200,7 @@ export {
|
|
|
198
200
|
filterVendorEventsBySelectedDate,
|
|
199
201
|
findEventDateTimeByIsoDate,
|
|
200
202
|
formatDate,
|
|
203
|
+
formatDateOptionLabel,
|
|
201
204
|
formatDistance,
|
|
202
205
|
formatIrdNumber,
|
|
203
206
|
formatNZBankAccount,
|
|
@@ -239,6 +242,7 @@ export {
|
|
|
239
242
|
isFutureStartDate,
|
|
240
243
|
isInternalErrorMessage,
|
|
241
244
|
isIsoDateString,
|
|
245
|
+
isPastDate,
|
|
242
246
|
isResourceImageActive,
|
|
243
247
|
isTransientNetworkError,
|
|
244
248
|
isUtcMidnight,
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/utils/dateFormats.ts","../src/utils/eventDateStatus.ts","../src/utils/date.ts","../src/sharing/relationShareTypes.ts","../src/sharing/constants.ts","../src/sharing/joinShareDescriptionSections.ts","../src/sharing/normalizeShareDescription.ts"],"sourcesContent":["export const dateFormat = \"DD-MM-YYYY\";\nexport const timeFormat = \"HH:mm\";\n/** ISO 8601 machine/sortable format: day keys, Date construction, strict parsing, HTML date inputs. */\nexport const isoDateFormat = \"YYYY-MM-DD\";\n","import dayjs from \"dayjs\";\nimport customParseFormat from \"dayjs/plugin/customParseFormat.js\";\nimport isoWeek from \"dayjs/plugin/isoWeek.js\";\n\nimport { EnumEventDateStatus } from \"../enums\";\nimport type { DateTimeType } from \"../types/global\";\n\nimport { dateFormat, timeFormat } from \"./dateFormats\";\n\n// Enable dayjs plugins used by event date parsing/status logic\ndayjs.extend(customParseFormat);\ndayjs.extend(isoWeek);\n\n/**\n * Display label per date status. Single source of truth instead of deriving\n * the label with `replaceAll(\"_\", \" \")` / text-transform tricks, so each\n * status maps to an explicit, correctly-cased string (e.g. \"This Week\",\n * \"Starting Soon\", \"Rescheduled\"). Lives here (not in `calendar`) so both\n * `calendar/eventCalendar` and `utils/date` can consume it without a circular\n * import.\n */\nexport const EVENT_DATE_STATUS_LABELS: Record<EnumEventDateStatus, string> = {\n [EnumEventDateStatus.STARTING_SOON]: \"Starting Soon\",\n [EnumEventDateStatus.STARTED]: \"Started\",\n [EnumEventDateStatus.TODAY]: \"Today\",\n [EnumEventDateStatus.TOMORROW]: \"Tomorrow\",\n [EnumEventDateStatus.THIS_WEEK]: \"This Week\",\n [EnumEventDateStatus.NEXT_WEEK]: \"Next Week\",\n [EnumEventDateStatus.UPCOMING]: \"Upcoming\",\n [EnumEventDateStatus.ENDED]: \"Ended\",\n [EnumEventDateStatus.RE_SCHEDULED]: \"Rescheduled\",\n [EnumEventDateStatus.CANCELED]: \"Canceled\",\n [EnumEventDateStatus.INVALID]: \"Invalid\",\n};\n\nexport const EVENT_DATE_STATUS_PERIOD_MAP: Partial<\n Record<EnumEventDateStatus, EnumEventDateStatus[]>\n> = {\n [EnumEventDateStatus.TODAY]: [\n EnumEventDateStatus.STARTED,\n EnumEventDateStatus.STARTING_SOON,\n EnumEventDateStatus.TODAY,\n ],\n [EnumEventDateStatus.THIS_WEEK]: [\n EnumEventDateStatus.STARTED,\n EnumEventDateStatus.STARTING_SOON,\n EnumEventDateStatus.THIS_WEEK,\n EnumEventDateStatus.TODAY,\n EnumEventDateStatus.TOMORROW,\n ],\n};\n\nexport function getAllowedEventDateStatuses(\n period: EnumEventDateStatus,\n): EnumEventDateStatus[] {\n return EVENT_DATE_STATUS_PERIOD_MAP[period] ?? [period];\n}\n\nexport function eventMatchesDateStatusPeriod(\n dateTime: Pick<DateTimeType, \"dateStatus\">[] | null | undefined,\n period: EnumEventDateStatus,\n): boolean {\n const allowedStatuses = getAllowedEventDateStatuses(period);\n\n return (\n dateTime?.some((dt) => allowedStatuses.includes(dt.dateStatus)) ?? false\n );\n}\n\nexport function filterEventsByDateStatusPeriod<\n T extends { dateTime?: Pick<DateTimeType, \"dateStatus\">[] | null },\n>(events: T[], period: EnumEventDateStatus): T[] {\n return events.filter((event) =>\n eventMatchesDateStatusPeriod(event.dateTime, period),\n );\n}\n\n/**\n * Canonical list of date statuses whose start date/time is still in the future\n * (i.e. the slot has not started yet). `STARTED`, `ENDED`, `INVALID`,\n * `CANCELED` and `RE_SCHEDULED` are intentionally excluded.\n *\n * This is the single source of truth for \"is this slot still in the future\".\n * `futureTimePeriods` (in `utils/date.ts`) derives from this list for UI\n * filters, additionally excluding `STARTING_SOON`.\n */\nexport const FUTURE_EVENT_DATE_STATUSES: readonly EnumEventDateStatus[] = [\n EnumEventDateStatus.STARTING_SOON,\n EnumEventDateStatus.TODAY,\n EnumEventDateStatus.TOMORROW,\n EnumEventDateStatus.THIS_WEEK,\n EnumEventDateStatus.NEXT_WEEK,\n EnumEventDateStatus.UPCOMING,\n];\n\nexport function isFutureEventDateStatus(\n dateStatus: EnumEventDateStatus | null | undefined,\n): boolean {\n return Boolean(dateStatus && FUTURE_EVENT_DATE_STATUSES.includes(dateStatus));\n}\n\nexport function filterDatesByFutureStatus<\n T extends { dateStatus?: EnumEventDateStatus | null },\n>(dates: T[]): T[] {\n return dates.filter((date) => isFutureEventDateStatus(date.dateStatus));\n}\n\n/**\n * Statuses set by an explicit user action rather than derived from the\n * schedule clock. The status recomputation below must leave them untouched,\n * otherwise a canceled/rescheduled date would silently flip back to a\n * time-derived status on the next run.\n */\nexport const MANUAL_DATE_STATUSES: ReadonlySet<EnumEventDateStatus> = new Set([\n EnumEventDateStatus.CANCELED,\n EnumEventDateStatus.RE_SCHEDULED,\n]);\n\n/**\n * Builds the event schedule that relation dates should be matched against.\n *\n * Manual statuses (`MANUAL_DATE_STATUSES`: CANCELED and RE_SCHEDULED) stay on\n * the live `Event.dateTime` for visibility, but a relation date pointing at\n * them is treated as removed. Archived (ended) slots are appended separately\n * so relation dates for archived history still match instead of being wrongly\n * marked canceled.\n *\n * Shared by the event-update relation sync and the cron orphan-date cleanup so\n * both use the same archive-aware schedule.\n */\nexport function buildRelationEligibleEventSchedule<\n T extends { dateStatus?: EnumEventDateStatus | null },\n>(liveDateTime: T[], archivedDateTime: T[] = []): T[] {\n const eligible = liveDateTime.filter(\n (slot) => !slot.dateStatus || !MANUAL_DATE_STATUSES.has(slot.dateStatus),\n );\n return [...eligible, ...archivedDateTime];\n}\n\n/**\n * Determines the dateStatus for a future event date\n * @param startDateTime The start date-time of the event\n * @param now The current date-time\n * @returns The appropriate EnumEventDateStatus\n */\nexport function getFutureEventStatus(\n startDateTime: dayjs.Dayjs,\n now: dayjs.Dayjs,\n): EnumEventDateStatus {\n const hoursUntilStart = startDateTime.diff(now, \"hour\", true);\n if (hoursUntilStart > 0 && hoursUntilStart <= 4) {\n return EnumEventDateStatus.STARTING_SOON;\n }\n\n if (startDateTime.isSame(now, \"day\")) {\n return EnumEventDateStatus.TODAY;\n }\n\n if (startDateTime.isSame(now.add(1, \"day\"), \"day\")) {\n return EnumEventDateStatus.TOMORROW;\n }\n\n if (startDateTime.isSame(now, \"isoWeek\")) {\n return EnumEventDateStatus.THIS_WEEK;\n }\n\n if (startDateTime.isSame(now.add(1, \"week\"), \"isoWeek\")) {\n return EnumEventDateStatus.NEXT_WEEK;\n }\n\n return EnumEventDateStatus.UPCOMING;\n}\n\n/**\n * Updates the dateStatus field for a single DateTimeType object based on the current date/time.\n * Manual statuses (CANCELED, RE_SCHEDULED) are preserved and returned as-is.\n * @param dateTime The date-time object to update\n * @returns A new object with an updated dateStatus value, or the original\n * object when the stored status is a manual override\n */\nexport function updateSingleDateTimeStatus<T extends DateTimeType>(\n dateTime: T,\n now: dayjs.Dayjs = dayjs(),\n): T {\n if (MANUAL_DATE_STATUSES.has(dateTime.dateStatus)) {\n return dateTime;\n }\n\n // Parse start and end date-time\n const dateTimeFormat = `${dateFormat} ${timeFormat}`;\n const startDateTime = dayjs(\n `${dateTime.startDate} ${dateTime.startTime}`,\n dateTimeFormat,\n true,\n );\n const endDateTime = dayjs(\n `${dateTime.endDate} ${dateTime.endTime}`,\n dateTimeFormat,\n true,\n );\n\n // Skip if dates are invalid\n if (!startDateTime.isValid() || !endDateTime.isValid()) {\n return {\n ...dateTime,\n dateStatus: EnumEventDateStatus.INVALID,\n };\n }\n\n if (endDateTime.isBefore(startDateTime)) {\n return {\n ...dateTime,\n dateStatus: EnumEventDateStatus.INVALID,\n };\n }\n\n let dateStatus: EnumEventDateStatus;\n\n if (endDateTime.isAfter(now)) {\n if (startDateTime.isAfter(now)) {\n // Event has not started yet\n dateStatus = getFutureEventStatus(startDateTime, now);\n } else {\n // Event is in progress\n dateStatus = EnumEventDateStatus.STARTED;\n }\n } else {\n // Event has ended\n dateStatus = EnumEventDateStatus.ENDED;\n }\n\n return {\n ...dateTime,\n dateStatus,\n };\n}\n","import dayjs from \"dayjs\";\nimport customParseFormat from \"dayjs/plugin/customParseFormat.js\";\nimport isSameOrAfter from \"dayjs/plugin/isSameOrAfter.js\";\nimport timezone from \"dayjs/plugin/timezone.js\";\nimport utc from \"dayjs/plugin/utc.js\";\n\nimport { EnumEventDateStatus } from \"src/enums\";\n\nimport { dateFormat, timeFormat, isoDateFormat } from \"./dateFormats\";\nimport {\n FUTURE_EVENT_DATE_STATUSES,\n EVENT_DATE_STATUS_LABELS,\n} from \"./eventDateStatus\";\n\nexport { dateFormat, timeFormat, isoDateFormat };\n\n// Enable custom format parsing\ndayjs.extend(customParseFormat);\ndayjs.extend(utc);\ndayjs.extend(timezone);\ndayjs.extend(isSameOrAfter);\n\nexport const NZ_TZ = \"Pacific/Auckland\";\n\nexport function toNZTime(date?: Date | string) {\n return date ? dayjs(date).tz(NZ_TZ) : dayjs().tz(NZ_TZ);\n}\n\n/** Start of the calendar day in Pacific/Auckland (daily games, streaks, etc.). */\nexport function nzStartOfDay(\n input?: Date | string | number | null,\n): dayjs.Dayjs {\n if (input == null) {\n return dayjs().tz(NZ_TZ).startOf(\"day\");\n }\n return dayjs.tz(input, NZ_TZ).startOf(\"day\");\n}\n\n/**\n * UTC-midnight of the given instant's NZ calendar day (today when omitted).\n * This is the canonical \"day key\" encoding used by ad bookings and metrics:\n * stored as a UTC Date, rendered with `.toISOString().slice(0, 10)`.\n */\nexport function nzDayKey(input?: Date | string | number | null): Date {\n const day =\n input == null\n ? dayjs().tz(NZ_TZ).format(isoDateFormat)\n : dayjs.tz(input, NZ_TZ).format(isoDateFormat);\n return new Date(`${day}T00:00:00Z`);\n}\n\n/**\n * Type guard for the canonical \"day key\" encoding: a valid Date that is\n * exactly UTC midnight. Accepts `unknown` so it can validate untrusted values\n * (GraphQL/JSON inputs) without a preceding cast.\n */\nexport function isUtcMidnight(value: unknown): value is Date {\n return (\n value instanceof Date &&\n !Number.isNaN(value.getTime()) &&\n value.getUTCHours() === 0 &&\n value.getUTCMinutes() === 0 &&\n value.getUTCSeconds() === 0 &&\n value.getUTCMilliseconds() === 0\n );\n}\n\ntype DateFormat = \"date\" | \"time\" | \"datetime\";\n\n/**\n * Format a date string to a more readable format.\n * @param dateStr - the date string\n * @param timeStr - optional time string\n * @param display - 'date' | 'time' | 'datetime'\n * @returns formatted string based on display option\n */\nexport const formatDate = (\n dateStr: string,\n display: DateFormat = \"datetime\",\n timeStr?: string,\n) => {\n // Combine date and time into a single string if time is provided\n const dateTimeStr = timeStr ? `${dateStr} ${timeStr}` : dateStr;\n\n // Parse with formats\n const dateTime = timeStr\n ? dayjs(dateTimeStr, `${dateFormat} ${timeFormat}`)\n : dayjs(dateStr, dateFormat);\n\n // Format parts\n const formattedDate = dateTime.format(\"dddd, D MMMM, YYYY\");\n const formattedTime = dateTime.format(\"h:mm a\");\n\n // Return based on display option\n switch (display) {\n case \"date\":\n return formattedDate;\n case \"time\":\n return formattedTime;\n case \"datetime\":\n return `${formattedDate} at ${formattedTime}`;\n default:\n return formattedDate;\n }\n};\n\n/**\n * Formats accepted for a stored slot. The canonical writer is\n * `dayjs(...).format(`${dateFormat} ${timeFormat}`)`; the variants cover legacy\n * rows with an unpadded hour or trailing seconds. Each is parsed **strictly**, so\n * impossible values (`31-02`, `25:00`) are rejected instead of rolling over into\n * a real instant.\n */\nconst SLOT_FORMATS = [\n `${dateFormat} ${timeFormat}`,\n `${dateFormat} H:mm`,\n `${dateFormat} ${timeFormat}:ss`,\n `${dateFormat} H:mm:ss`,\n];\n\nconst parseSlot = (date: {\n startDate?: string;\n startTime?: string;\n}): dayjs.Dayjs | null => {\n if (!date.startDate || !date.startTime) {\n return null;\n }\n\n const value = `${date.startDate} ${date.startTime}`;\n\n for (const format of SLOT_FORMATS) {\n const parsed = dayjs(value, format, true);\n\n if (parsed.isValid()) {\n return parsed;\n }\n }\n\n return null;\n};\n\n/**\n * Shared \"starts now or later\" rule for `dd-mm-yyyy` + `HH:mm` slots. `now` is\n * passed in so a caller filtering a list compares every slot against the same\n * instant. A slot with a missing or unparseable date/time is never future.\n */\nconst isFutureDateTime = (\n date: { startDate?: string; startTime?: string },\n now: dayjs.Dayjs,\n): boolean => {\n const slot = parseSlot(date);\n\n return slot ? slot.isSameOrAfter(now) : false;\n};\n\nexport const getCurrentAndFutureDates = <\n T extends { startDate?: string; startTime?: string },\n>(\n dates: T[],\n): T[] => {\n const now = dayjs(); // current date and time\n\n return dates.filter((dateObj) => isFutureDateTime(dateObj, now));\n};\n\n/**\n * True when the slot starts now or later. Status-agnostic: used to hide past\n * relation dates from reads while the records stay in the database.\n */\nexport const isFutureStartDate = (date: {\n startDate?: string;\n startTime?: string;\n}): boolean => isFutureDateTime(date, dayjs());\n\nexport const isFutureDatesBeforeThreshold = (\n date: {\n startDate?: string;\n startTime?: string;\n },\n minHoursFromNow: number,\n): boolean => {\n if (!date.startDate || !date.startTime) {\n return false;\n }\n\n const threshold = minHoursFromNow\n ? dayjs().add(minHoursFromNow, \"hour\")\n : dayjs().startOf(\"day\");\n\n const dateTime = dayjs(\n `${date.startDate} ${date.startTime}`,\n `${dateFormat} ${timeFormat}`,\n );\n\n return dateTime.isSameOrAfter(threshold);\n};\n\nexport const formatTimestamp = (timestamp: string) => {\n const formattedDate = toNZTime(timestamp).format(dateFormat);\n\n return formatDate(formattedDate, \"date\");\n};\n\nexport const isIsoDateString = (value: unknown): value is string => {\n return typeof value === \"string\" && !Number.isNaN(Date.parse(value));\n};\n\n/**\n * Sort an array of date strings by their proximity to the current date.\n * @param dates - The array of date strings to sort.\n * @returns - The sorted array of date strings.\n */\nexport function sortDatesChronologically<\n T extends { startDate?: string; startTime?: string },\n>(dates: T[]): T[] {\n if (!dates?.length) {\n return [];\n }\n\n return [...dates].sort((a, b) => {\n const dateTimeFormat = `${dateFormat} ${timeFormat}`;\n const dateA =\n a.startDate && a.startTime\n ? dayjs(`${a.startDate} ${a.startTime}`, dateTimeFormat)\n : null;\n const dateB =\n b.startDate && b.startTime\n ? dayjs(`${b.startDate} ${b.startTime}`, dateTimeFormat)\n : null;\n\n if (dateA && dateB) {\n return dateA.valueOf() - dateB.valueOf();\n }\n\n if (dateA) {\n return -1;\n }\n\n if (dateB) {\n return 1;\n }\n\n return 0;\n });\n}\n\n/**\n * Start dates of the given date/time slots, chronological and de-duplicated.\n * Slots that share a `startDate` (e.g. two stall slots on the same day) collapse\n * into a single entry.\n */\nexport function getUniqueStartDates(\n dates: Array<{ startDate?: string; startTime?: string }> | null | undefined,\n): string[] {\n const seenStartDates = new Set<string>();\n const uniqueStartDates: string[] = [];\n\n for (const { startDate } of sortDatesChronologically(dates ?? [])) {\n if (!startDate || seenStartDates.has(startDate)) {\n continue;\n }\n\n seenStartDates.add(startDate);\n uniqueStartDates.push(startDate);\n }\n\n return uniqueStartDates;\n}\n\n/**\n * UI filter options for user-activity event periods. Derived from the canonical\n * {@link FUTURE_EVENT_DATE_STATUSES} list, minus `STARTING_SOON` (a presentational\n * choice: \"starting soon\" is surfaced separately rather than as a filter).\n */\nexport const futureTimePeriods = FUTURE_EVENT_DATE_STATUSES.filter(\n (status) => status !== EnumEventDateStatus.STARTING_SOON,\n).map((status) => ({\n label: EVENT_DATE_STATUS_LABELS[status],\n value: status,\n}));\n","/** Path segments for relation share URLs — must match mobile `RelationTitle` values. */\nexport const RELATION_SHARE_INVITATION = \"invitation\" as const;\nexport const RELATION_SHARE_APPLICATION = \"application\" as const;\n\n/**\n * Bump when relation overlay SVG/layout changes so og:image URLs and API ETags\n * invalidate after deploy. Facebook caches preview JPEGs by exact URL — changing\n * this value forces crawlers to fetch a fresh image after server deploy.\n */\nexport const RELATION_OVERLAY_LAYOUT_VERSION = 43;\n\nexport const RELATION_SHARE_RESOURCE_TYPES = [\n RELATION_SHARE_INVITATION,\n RELATION_SHARE_APPLICATION,\n] as const;\n\nexport type RelationShareResourceType =\n (typeof RELATION_SHARE_RESOURCE_TYPES)[number];\n\nexport function isRelationShareResourceType(\n resourceType: string,\n): resourceType is RelationShareResourceType {\n return (RELATION_SHARE_RESOURCE_TYPES as readonly string[]).includes(\n resourceType,\n );\n}\n","import {\n RELATION_SHARE_APPLICATION,\n RELATION_SHARE_INVITATION,\n type RelationShareResourceType,\n} from \"./relationShareTypes\";\n\nexport {\n RELATION_SHARE_APPLICATION,\n RELATION_SHARE_INVITATION,\n RELATION_OVERLAY_LAYOUT_VERSION,\n RELATION_SHARE_RESOURCE_TYPES,\n isRelationShareResourceType,\n type RelationShareResourceType,\n} from \"./relationShareTypes\";\n\n/** Open Graph recommended preview size (must match admin `SHARE_OG_IMAGE_*`). */\nexport const SOCIAL_IMAGE_WIDTH = 1200;\n\n/** Open Graph recommended preview size (must match admin `SHARE_OG_IMAGE_*`). */\nexport const SOCIAL_IMAGE_HEIGHT = 630;\n\n/** Keep in sync with `CLUEMART_MAIN_DOMAIN_URL` in utils (avoid utils↔sharing import cycle). */\nexport const SHARE_SITE_URL = \"https://cluemart.co.nz\";\n\n/** Calendar marker for invitation market-dates share copy (U+1F4C5 📅). */\nexport const SHARE_CALENDAR_ICON = \"\\u{1F4C5}\";\n\nexport const SHARE_MARKET_DATES_SECTION_HEADING = `${SHARE_CALENDAR_ICON} Market dates:`;\n\n/** Check mark for invitation requirements share copy (U+2705 ✅). */\nexport const SHARE_CHECKMARK_ICON = \"\\u{2705}\";\n\nexport const SHARE_REQUIREMENTS_SECTION_HEADING = `${SHARE_CHECKMARK_ICON} Requirements:`;\n\n/** Information marker for tags share copy (U+2139 ℹ️). */\nexport const SHARE_INFO_ICON = \"\\u{2139}\\u{FE0F}\";\n\nexport const SHARE_TAGS_SECTION_HEADING = `${SHARE_INFO_ICON} Tags:`;\n\n/** Standalone line when `rainOrShine` is true (invitation share + OG section parsing). */\nexport const SHARE_RAIN_OR_SHINE_LINE = \"Rain or Shine\";\n\n/** Standalone line when `foodTruck` is true (application share + OG section parsing). */\nexport const SHARE_FOOD_TRUCK_LINE = \"Food Truck\";\n\n/** Prefix for application compliance line (share text + OG section parsing). */\nexport const SHARE_COMPLIANCE_PREFIX = `${SHARE_CHECKMARK_ICON} Compliance:`;\n\n/** Label tag for application categories share copy (U+1F3F7 🏷️). */\nexport const SHARE_CATEGORY_ICON = \"\\u{1F3F7}\\u{FE0F}\";\n\nexport const SHARE_CATEGORIES_SECTION_HEADING = `${SHARE_CATEGORY_ICON} Categories:`;\n\n/** Straight ruler for application stall-size share copy (U+1F4CF 📏). */\nexport const SHARE_RULER_ICON = \"\\u{1F4CF}\";\n\n/** Prefix for application stall-size line (share text + OG section parsing). */\nexport const SHARE_STALL_SIZE_PREFIX = `${SHARE_RULER_ICON} Stall size:`;\n\n/** Dollar marker for price-range share copy (U+0024 $ — text, not emoji, so it stays black). */\nexport const SHARE_DOLLAR_ICON = \"$\";\n\n/** Prefix for application price-range line (share text + OG section parsing). */\nexport const SHARE_PRICE_RANGE_PREFIX = `${SHARE_DOLLAR_ICON} Price range:`;\n\n/** Alarm clock for invitation application-deadline share copy (U+23F0 ⏰). */\nexport const SHARE_CLOCK_ICON = \"\\u{23F0}\";\n\n/** Prefix for the invitation application-deadline sentence (share text + OG section parsing). */\nexport const SHARE_APPLICATION_DEADLINE_PREFIX = `${SHARE_CLOCK_ICON} Application deadline:`;\n\n/** First line of `og:description` (and legacy share-message text). */\nexport const SHARE_MORE_INFO_LINE = \"Shared from ClueMart\";\n\nexport const DEFAULT_SHARE_OG_IMAGE = `${SHARE_SITE_URL}/assets/logo.webp`;\n\nexport const RESOURCE_SHARE_TYPES = [\n \"market\",\n \"stallholder\",\n \"partner\",\n \"affiliate\",\n \"school\",\n] as const;\n\nexport type ResourceShareType = (typeof RESOURCE_SHARE_TYPES)[number];\n\nexport const POST_SHARE_RESOURCE_TYPES = [\n \"market_faces\",\n \"clue_bites\",\n \"play_and_win\",\n] as const;\n\nexport type PostShareResourceType = (typeof POST_SHARE_RESOURCE_TYPES)[number];\n\nexport type ShareResourceType =\n ResourceShareType | PostShareResourceType | RelationShareResourceType;\n\nexport const SHARE_RESOURCE_LABEL: Record<ShareResourceType, string> = {\n [RELATION_SHARE_APPLICATION]: \"Application\",\n [RELATION_SHARE_INVITATION]: \"Invitation\",\n affiliate: \"Affiliate\",\n clue_bites: \"Clue Bites\",\n market_faces: \"Market Faces\",\n market: \"Market\",\n partner: \"Partner\",\n play_and_win: \"Play & Win\",\n school: \"School\",\n stallholder: \"Stallholder\",\n};\n\nexport function isPostShareResourceType(\n resourceType: ShareResourceType,\n): resourceType is PostShareResourceType {\n return (POST_SHARE_RESOURCE_TYPES as readonly string[]).includes(\n resourceType,\n );\n}\n","import { SHARE_MORE_INFO_LINE } from \"./constants\";\n\n/** Blank line between share sections — title, address, dates, URL, etc. */\nexport const SHARE_DESCRIPTION_SECTION_BREAK = \"\\n\\n\";\n\n/**\n * Line break for `og:description` meta content. Use instead of `\\n` — Next.js\n * HTML serialisation collapses literal newlines to spaces; Facebook reads ` `.\n */\nexport const OG_DESCRIPTION_LINE_BREAK = \" \";\n\n/** Joins OG description sections for Facebook link cards (and Twitter). */\nexport function joinShareOgDescriptionSections(\n sections: ReadonlyArray<string | false | null | undefined>,\n): string {\n return sections\n .map((section) => (typeof section === \"string\" ? section.trim() : \"\"))\n .filter((section): section is string => section.length > 0)\n .map((section) => section.replace(/\\n/g, OG_DESCRIPTION_LINE_BREAK))\n .join(OG_DESCRIPTION_LINE_BREAK);\n}\n\nexport function joinShareDescriptionSections(\n sections: ReadonlyArray<string | false | null | undefined>,\n): string {\n return sections\n .filter((section): section is string => Boolean(section))\n .join(SHARE_DESCRIPTION_SECTION_BREAK);\n}\n\n/** Prepends the standard share branding line when assembling display text. */\nexport function appendShareMoreInfoLine(description: string): string {\n const trimmed = description.trim();\n if (trimmed.startsWith(SHARE_MORE_INFO_LINE)) {\n return trimmed;\n }\n if (trimmed.length === 0) {\n return SHARE_MORE_INFO_LINE;\n }\n return joinShareDescriptionSections([SHARE_MORE_INFO_LINE, trimmed]);\n}\n","import { joinShareOgDescriptionSections } from \"./joinShareDescriptionSections\";\n\nexport {\n joinShareOgDescriptionSections,\n OG_DESCRIPTION_LINE_BREAK,\n SHARE_DESCRIPTION_SECTION_BREAK,\n} from \"./joinShareDescriptionSections\";\n\n/** Trims share text and collapses spaces per line; preserves `\\n\\n` section breaks. */\nconst LEADING_WHITESPACE = /^[ \\t]*/;\n\nexport function normalizeShareText(value: string | null | undefined): string {\n if (value == null) {\n return \"\";\n }\n return value\n .trim()\n .split(\"\\n\")\n .map((line) => {\n const leading = LEADING_WHITESPACE.exec(line)?.[0] ?? \"\";\n const rest = line\n .slice(leading.length)\n .trim()\n .replace(/[ \\t]{2,}/g, \" \");\n return leading + rest;\n })\n .join(\"\\n\")\n .replace(/\\n{3,}/g, \"\\n\\n\");\n}\n\nexport function splitShareDescriptionSections(value: string): string[] {\n const trimmed = normalizeShareText(value);\n if (!trimmed) {\n return [];\n }\n\n if (/\\n\\n/.test(trimmed)) {\n return trimmed\n .split(/\\n\\n+/)\n .map((section) => normalizeShareText(section))\n .filter((section) => section.length > 0);\n }\n\n if (/\\n/.test(trimmed)) {\n return trimmed\n .split(/\\n+/)\n .map((section) => normalizeShareText(section))\n .filter((section) => section.length > 0);\n }\n\n return [trimmed];\n}\n\n/**\n * Formats share descriptions for Open Graph / Twitter meta tags.\n * Sections are joined with {@link OG_DESCRIPTION_LINE_BREAK} (` `).\n */\nexport function normalizeShareOgDescription(value: string): string {\n return joinShareOgDescriptionSections(splitShareDescriptionSections(value));\n}\n\n/**\n * Open Graph / Twitter description from pre-built section strings.\n * Prefer {@link joinShareOgDescriptionSections} when sections are already known.\n */\nexport function buildShareOgDescriptionFromSections(\n sections: ReadonlyArray<string | false | null | undefined>,\n): string {\n return joinShareOgDescriptionSections(sections);\n}\n\n/** Open Graph / Twitter description — body sections only (`og:title` is separate). */\nexport function buildShareOgDescription(\n _title: string,\n description: string,\n): string {\n return joinShareOgDescriptionSections(\n splitShareDescriptionSections(description),\n );\n}\n\n/**\n * Strips emoji and symbols that do not render reliably in overlay SVG fonts.\n * Keeps letters, numbers, whitespace, and common sentence punctuation.\n */\nexport function stripOverlaySubtitleSpecialChars(text: string): string {\n const regex = /[^\\p{L}\\p{M}\\p{N}\\s.,!?'\"&\\-():;/]/gu;\n const result = text\n .replace(/\\p{Extended_Pictographic}/gu, \"\")\n .replace(regex, \"\");\n return result.trim();\n}\n"],"mappings":";AAAO,IAAM,aAAa;AACnB,IAAM,aAAa;AAEnB,IAAM,gBAAgB;;;ACH7B,OAAO,WAAW;AAClB,OAAO,uBAAuB;AAC9B,OAAO,aAAa;AAQpB,MAAM,OAAO,iBAAiB;AAC9B,MAAM,OAAO,OAAO;AAUb,IAAM,2BAAgE;AAAA,EAC3E,oCAAkC,GAAG;AAAA,EACrC,wBAA4B,GAAG;AAAA,EAC/B,oBAA0B,GAAG;AAAA,EAC7B,0BAA6B,GAAG;AAAA,EAChC,4BAA8B,GAAG;AAAA,EACjC,4BAA8B,GAAG;AAAA,EACjC,0BAA6B,GAAG;AAAA,EAChC,oBAA0B,GAAG;AAAA,EAC7B,iCAAiC,GAAG;AAAA,EACpC,0BAA6B,GAAG;AAAA,EAChC,wBAA4B,GAAG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